[Pkg-php-commits] [php/debian-sid] Imported Upstream version 5.2.12.dfsg.1

Ondřej Surý ondrej at sury.org
Fri Jan 8 13:50:24 UTC 2010


---
 EXTENSIONS                                         |    2 +-
 Makefile.global                                    |   13 +-
 NEWS                                               |  228 +-
 Zend/tests/bug41919.phpt                           |    2 -
 Zend/tests/bug49472.phpt                           |   27 +
 Zend/tests/bug50005.phpt                           |   19 +
 Zend/tests/bug50174.phpt                           |   33 +
 Zend/tests/bug50255.phpt                           |   30 +
 Zend/tests/errmsg_025.phpt                         |    4 +-
 Zend/zend_compile.c                                |   27 +-
 Zend/zend_execute.c                                |    5 +-
 Zend/zend_execute_API.c                            |    4 +-
 Zend/zend_objects.c                                |    4 +-
 Zend/zend_operators.c                              |    8 +-
 Zend/zend_vm_def.h                                 |    5 +-
 Zend/zend_vm_execute.h                             |   28 +-
 acinclude.m4                                       |   14 +-
 aclocal.m4                                         | 1700 +-
 build/libtool.m4                                   | 1686 +-
 config.guess                                       |  100 +-
 config.sub                                         |  153 +-
 configure                                          | 7181 +++---
 configure.in                                       |   80 +-
 ext/com_dotnet/com_typeinfo.c                      |    4 +-
 ext/curl/interface.c                               |   38 +-
 ext/curl/php_curl.h                                |    4 +-
 ext/date/config0.m4                                |    4 +-
 ext/date/lib/timezonedb.h                          | 1525 +-
 ext/date/php_date.c                                |   29 +-
 .../tests/DateTimeZone_listIdentifiers_basic1.phpt | 1140 +-
 ext/date/tests/date_sunrise_variation5.phpt        |    8 +-
 ext/date/tests/date_sunset_variation5.phpt         |    6 +-
 ext/date/tests/sunfuncts.phpt                      |   44 +
 .../tests/timezone_identifiers_list_basic1.phpt    | 1140 +-
 ext/dom/document.c                                 |   14 +-
 ext/dom/documenttype.c                             |    6 +-
 ext/dom/node.c                                     |    6 +-
 ext/dom/tests/bug47848.phpt                        |   25 +
 ext/exif/exif.c                                    |    8 +-
 ext/filter/logical_filters.c                       |    4 +-
 ext/filter/tests/033.phpt                          |    2 +-
 ext/filter/tests/046.phpt                          |    4 -
 ext/filter/tests/bug50158.phpt                     |   23 +
 ext/ftp/ftp.c                                      |    4 +-
 ext/gd/gd.c                                        |    4 +-
 ext/gd/libgd/gd_gd.c                               |    3 +
 ext/gd/libgd/gdft.c                                |    1 +
 ext/gd/tests/crafted.gd2                           |  Bin 0 -> 1039 bytes
 ext/gd/tests/crafted_gd2.phpt                      |   16 +
 ext/gd/tests/image_type_to_mime_type_basic.phpt    |    5 +-
 ext/gd/tests/imagecopyresampled_basic.phpt         |    2 +-
 ext/gd/tests/imagedashedline_basic.phpt            |    2 +-
 ext/gd/tests/imagefilledpolygon_basic.phpt         |    2 +-
 ext/gmp/tests/bug50283.phpt                        |   36 +
 ext/iconv/tests/iconv_encoding_basic.phpt          |    6 +-
 ext/iconv/tests/iconv_substr_basic.phpt            |    6 +-
 ext/imap/php_imap.c                                |    3 +-
 ext/ldap/ldap.c                                    |   22 +-
 ext/ldap/tests/bug48696.phpt                       |    4 +
 ext/libxml/libxml.c                                |    5 +-
 ext/mbstring/config.m4                             |   10 +-
 ext/mbstring/libmbfl/filters/mbfilter_utf16.c      |   27 +-
 ext/mbstring/libmbfl/filters/mbfilter_utf8.c       |    2 +-
 ext/mbstring/libmbfl/mbfl/mbfilter.c               |    2 +-
 ext/mbstring/mbstring.c                            |    5 +-
 ext/mbstring/tests/bug43994.phpt                   |    2 +-
 ext/mbstring/tests/bug45722.phpt                   |    2 +
 ext/mbstring/tests/bug49354.phpt                   |   21 +
 ext/mbstring/tests/bug49528.phpt                   |   20 +
 ext/mbstring/tests/bug49536.phpt                   |   20 +
 ext/mcrypt/mcrypt.c                                |    3 +-
 ext/mcrypt/tests/bug46010.phpt                     |    2 +-
 ext/mcrypt/tests/bug49738.phpt                     |   13 +
 ext/mime_magic/mime_magic.c                        |    4 +-
 ext/mysqli/mysqli.c                                |    8 +-
 ext/mysqli/mysqli_api.c                            |    5 +-
 ext/odbc/php_odbc.c                                |   22 +-
 ext/openssl/openssl.c                              |   12 +-
 ext/openssl/tests/bug48182.phpt                    |    6 +-
 ext/pdo/pdo.c                                      |   40 +-
 ext/pdo/pdo_dbh.c                                  |   11 +-
 ext/pdo/pdo_stmt.c                                 |  122 +-
 ext/pdo/tests/pdo_005.phpt                         |    8 +-
 ext/pdo/tests/pdo_036.phpt                         |   21 +
 ext/pdo_dblib/config.m4                            |    2 +-
 ext/pdo_firebird/config.m4                         |    2 +-
 ext/pdo_firebird/pdo_firebird.c                    |    4 +-
 ext/pdo_mysql/config.m4                            |    2 +-
 ext/pdo_mysql/tests/bug_45120.phpt                 |   48 +
 ext/pdo_mysql/tests/bug_50323.phpt                 |   61 +
 ext/pdo_oci/config.m4                              |    2 +-
 ext/pdo_odbc/config.m4                             |    2 +-
 ext/pdo_pgsql/config.m4                            |    2 +-
 ext/pdo_pgsql/pdo_pgsql.c                          |    6 +-
 ext/pdo_pgsql/pgsql_driver.c                       |   31 +-
 ext/pdo_pgsql/pgsql_statement.c                    |    4 +-
 ext/pdo_pgsql/php_pdo_pgsql_int.h                  |   10 +-
 ext/pdo_pgsql/tests/bug48764.phpt                  |  134 +
 ext/pdo_pgsql/tests/bug_49985.phpt                 |   35 +
 ext/pdo_sqlite/config.m4                           |    2 +-
 ext/pdo_sqlite/tests/bug49521.phpt                 |   39 +
 ext/pgsql/pgsql.c                                  |   30 +-
 ext/posix/posix.c                                  |    7 +-
 ext/posix/tests/posix_errno_variation1.phpt        |    1 +
 ext/posix/tests/posix_errno_variation2.phpt        |    1 +
 ext/posix/tests/posix_seteuid_variation2.phpt      |    1 +
 ext/posix/tests/posix_seteuid_variation3.phpt      |    1 +
 ext/posix/tests/posix_seteuid_variation4.phpt      |    1 +
 ext/posix/tests/posix_seteuid_variation5.phpt      |    1 +
 ext/posix/tests/posix_setgid_variation2.phpt       |    3 +-
 ext/posix/tests/posix_setgid_variation3.phpt       |    1 +
 ext/posix/tests/posix_setgid_variation4.phpt       |    3 +-
 ext/posix/tests/posix_setgid_variation5.phpt       |    3 +-
 ext/posix/tests/posix_setuid_variation2.phpt       |    1 +
 ext/posix/tests/posix_setuid_variation3.phpt       |    1 +
 ext/posix/tests/posix_setuid_variation4.phpt       |    1 +
 ext/posix/tests/posix_setuid_variation5.phpt       |    1 +
 ext/posix/tests/posix_uname.phpt                   |    4 +-
 ext/posix/tests/posix_uname_basic.phpt             |    2 +-
 ext/readline/config.m4                             |    4 +-
 ext/readline/readline.c                            |    6 +-
 ext/readline/tests/readline_add_history_001.phpt   |    2 +-
 .../readline_callback_handler_install_001.phpt     |    2 +-
 .../readline_callback_handler_remove_001.phpt      |    2 +-
 ext/readline/tests/readline_list_history_001.phpt  |    2 +-
 ext/readline/tests/readline_read_history_001.phpt  |    2 +-
 ext/readline/tests/readline_write_history_001.phpt |    2 +-
 ext/reflection/php_reflection.c                    |   13 +-
 .../tests/ReflectionClass_hasProperty_001.phpt     |    2 +-
 ext/reflection/tests/bug49719.phpt                 |   30 +
 ext/session/mod_files.c                            |    6 +-
 ext/session/mod_mm.c                               |    5 +-
 ext/session/session.c                              |   22 +-
 ext/simplexml/simplexml.c                          |    4 +-
 ext/snmp/snmp.c                                    |    7 +-
 ext/soap/php_encoding.c                            |    4 +-
 ext/soap/php_http.c                                |   22 +-
 ext/soap/php_xml.c                                 |    5 +-
 ext/soap/soap.c                                    |    8 +-
 ext/sockets/tests/socket_getpeername_ipv6loop.phpt |    7 +-
 ext/sockets/tests/socket_set_option_rcvtimeo.phpt  |    2 +-
 ext/sockets/tests/socket_set_option_seolinger.phpt |    2 +-
 ext/sockets/tests/socket_set_option_sndtimeo.phpt  |    2 +-
 ext/spl/spl_iterators.c                            |    8 +-
 ext/spl/spl_observer.c                             |    4 +-
 ext/spl/tests/bug49972.phpt                        |   11 +
 ext/spl/tests/iterator_032.phpt                    |    2 +-
 ext/spl/tests/iterator_056.phpt                    |   21 +
 ext/spl/tests/iterator_057.phpt                    |   23 +
 ext/spl/tests/iterator_058.phpt                    |   26 +
 ext/spl/tests/iterator_059.phpt                    |   19 +
 ext/spl/tests/iterator_060.phpt                    |   19 +
 ext/spl/tests/iterator_061.phpt                    |   19 +
 ext/spl/tests/iterator_062.phpt                    |   20 +
 ext/spl/tests/iterator_063.phpt                    |   19 +
 ext/spl/tests/iterator_064.phpt                    |   17 +
 ext/spl/tests/iterator_065.phpt                    |   17 +
 ext/spl/tests/iterator_066.phpt                    |   17 +
 ext/spl/tests/iterator_067.phpt                    |   18 +
 ext/spl/tests/iterator_069.phpt                    |   19 +
 ext/spl/tests/iterator_070.phpt                    |   22 +
 ext/spl/tests/iterator_071.phpt                    |   34 +
 ...ursiveIteratorIterator_beginchildren_error.phpt |   38 +
 ...siveIteratorIterator_callHasChildren_error.phpt |   38 +
 ...ecursiveIteratorIterator_endchildren_error.phpt |   44 +
 ...ecursiveIteratorIterator_nextelement_error.phpt |   38 +
 ext/sqlite/config.m4                               |    2 +-
 ext/sqlite/sqlite.c                                |    6 +-
 ext/sqlite/tests/sqlitedatabase_arrayquery.phpt    |   23 +
 ext/standard/array.c                               |  116 +-
 ext/standard/basic_functions.c                     |   47 +-
 ext/standard/basic_functions.h                     |    4 +-
 ext/standard/config.m4                             |   18 +-
 ext/standard/dns.c                                 |    5 +-
 ext/standard/exec.c                                |    9 +-
 ext/standard/file.c                                |   23 +-
 ext/standard/filestat.c                            |   22 +-
 ext/standard/formatted_print.c                     |    6 +-
 ext/standard/ftp_fopen_wrapper.c                   |   15 +-
 ext/standard/html.c                                |  262 +-
 ext/standard/pageinfo.c                            |    6 +-
 ext/standard/strnatcmp.c                           |    8 +-
 ext/standard/tests/array/bug50006.phpt             |   29 +
 ext/standard/tests/array/bug50006_1.phpt           |   29 +
 ext/standard/tests/array/bug50006_2.phpt           |   29 +
 ext/standard/tests/bug49244.phpt                   |   32 +
 ext/standard/tests/file/bug26615.phpt              |    2 +-
 ext/standard/tests/general_functions/bug49692.ini  |    4 +
 ext/standard/tests/general_functions/bug49692.phpt |   20 +
 .../tests/general_functions/import_request.phpt    |   12 +-
 .../general_functions/is_callable_basic1.phpt      |    4 +-
 .../general_functions/proc_nice_variation5.phpt    |    4 +
 .../tests/general_functions/sunfuncts.phpt         |   44 -
 ext/standard/tests/mail/mail_basic2.phpt           |   14 +-
 ext/standard/tests/mail/mail_variation2.phpt       |   10 +-
 ext/standard/tests/strings/bug49785.phpt           | 4114 +++
 ext/standard/tests/strings/htmlentities02.phpt     |    2 +-
 ext/standard/tests/strings/htmlentities03.phpt     |    2 +-
 ext/standard/tests/strings/htmlentities04.phpt     |    2 +-
 ext/standard/tests/strings/htmlentities15.phpt     |    2 +-
 .../tests/strings/setlocale_variation2.phpt        |    8 +-
 ext/standard/url.c                                 |   25 +-
 ext/standard/var.c                                 |    4 +-
 ext/xml/tests/bug32001b.phpt                       |    4 +-
 ext/xmlrpc/tests/bug50282.phpt                     |   43 +
 ext/xmlrpc/tests/bug50285.phpt                     |  115 +
 ext/xmlrpc/xmlrpc-epi-php.c                        |   41 +-
 ext/xmlwriter/tests/bug48204.phpt                  |    8 +
 ext/zlib/zlib.c                                    |   27 +-
 ltmain.sh                                          |  823 +-
 main/build-defs.h.in                               |    3 +-
 main/internal_functions_nw.c                       |   22 +-
 main/main.c                                        |   22 +-
 main/network.c                                     |    4 +-
 main/output.c                                      |   10 +-
 main/php_config.h.in                               |   12 +
 main/php_globals.h                                 |    3 +-
 main/php_version.h                                 |    6 +-
 main/rfc1867.c                                     |   10 +-
 main/streams/memory.c                              |    4 +-
 main/streams/xp_socket.c                           |    4 +-
 pear/fetch.php                                     |    7 +-
 pear/install-pear-nozlib.phar                      |32107 ++++++++++----------
 php.ini-dist                                       |    3 +
 php.ini-recommended                                |    3 +
 run-tests.php                                      |    6 +-
 sapi/apache2handler/sapi_apache2.c                 |   43 +-
 sapi/cgi/cgi_main.c                                |   27 +-
 sapi/cli/php.1.in                                  |   14 +-
 sapi/cli/php_cli.c                                 |    7 +-
 sapi/cli/php_cli_readline.c                        |    6 +-
 .../interface_constant_inheritance_001.phpt        |    2 +-
 .../interface_constant_inheritance_002.phpt        |    2 +-
 .../interface_constant_inheritance_003.phpt        |    2 +-
 tests/output/ob_011.phpt                           |    3 +-
 tests/output/ob_start_basic_unerasable_005.phpt    |    4 +-
 236 files changed, 30295 insertions(+), 25067 deletions(-)
 create mode 100644 Zend/tests/bug49472.phpt
 create mode 100644 Zend/tests/bug50005.phpt
 create mode 100644 Zend/tests/bug50174.phpt
 create mode 100644 Zend/tests/bug50255.phpt
 create mode 100644 ext/date/tests/sunfuncts.phpt
 create mode 100644 ext/dom/tests/bug47848.phpt
 create mode 100644 ext/filter/tests/bug50158.phpt
 create mode 100644 ext/gd/tests/crafted.gd2
 create mode 100644 ext/gd/tests/crafted_gd2.phpt
 create mode 100644 ext/gmp/tests/bug50283.phpt
 create mode 100644 ext/mbstring/tests/bug49354.phpt
 create mode 100644 ext/mbstring/tests/bug49528.phpt
 create mode 100644 ext/mbstring/tests/bug49536.phpt
 create mode 100644 ext/mcrypt/tests/bug49738.phpt
 create mode 100644 ext/pdo/tests/pdo_036.phpt
 create mode 100644 ext/pdo_mysql/tests/bug_45120.phpt
 create mode 100644 ext/pdo_mysql/tests/bug_50323.phpt
 create mode 100644 ext/pdo_pgsql/tests/bug48764.phpt
 create mode 100644 ext/pdo_pgsql/tests/bug_49985.phpt
 create mode 100644 ext/pdo_sqlite/tests/bug49521.phpt
 create mode 100644 ext/reflection/tests/bug49719.phpt
 create mode 100755 ext/spl/tests/bug49972.phpt
 create mode 100644 ext/spl/tests/iterator_056.phpt
 create mode 100644 ext/spl/tests/iterator_057.phpt
 create mode 100644 ext/spl/tests/iterator_058.phpt
 create mode 100644 ext/spl/tests/iterator_059.phpt
 create mode 100644 ext/spl/tests/iterator_060.phpt
 create mode 100644 ext/spl/tests/iterator_061.phpt
 create mode 100644 ext/spl/tests/iterator_062.phpt
 create mode 100644 ext/spl/tests/iterator_063.phpt
 create mode 100644 ext/spl/tests/iterator_064.phpt
 create mode 100644 ext/spl/tests/iterator_065.phpt
 create mode 100644 ext/spl/tests/iterator_066.phpt
 create mode 100644 ext/spl/tests/iterator_067.phpt
 create mode 100644 ext/spl/tests/iterator_069.phpt
 create mode 100644 ext/spl/tests/iterator_070.phpt
 create mode 100644 ext/spl/tests/iterator_071.phpt
 create mode 100644 ext/spl/tests/recursiveIteratorIterator_beginchildren_error.phpt
 create mode 100644 ext/spl/tests/recursiveIteratorIterator_callHasChildren_error.phpt
 create mode 100644 ext/spl/tests/recursiveIteratorIterator_endchildren_error.phpt
 create mode 100644 ext/spl/tests/recursiveIteratorIterator_nextelement_error.phpt
 create mode 100644 ext/sqlite/tests/sqlitedatabase_arrayquery.phpt
 create mode 100644 ext/standard/tests/array/bug50006.phpt
 create mode 100644 ext/standard/tests/array/bug50006_1.phpt
 create mode 100644 ext/standard/tests/array/bug50006_2.phpt
 create mode 100644 ext/standard/tests/bug49244.phpt
 create mode 100644 ext/standard/tests/general_functions/bug49692.ini
 create mode 100644 ext/standard/tests/general_functions/bug49692.phpt
 delete mode 100644 ext/standard/tests/general_functions/sunfuncts.phpt
 create mode 100644 ext/standard/tests/strings/bug49785.phpt
 create mode 100644 ext/xmlrpc/tests/bug50282.phpt
 create mode 100644 ext/xmlrpc/tests/bug50285.phpt

diff --git a/EXTENSIONS b/EXTENSIONS
index cd852ff..e6e1344 100644
--- a/EXTENSIONS
+++ b/EXTENSIONS
@@ -206,7 +206,7 @@ STATUS:              Working
 SINCE:               5.1
 -------------------------------------------------------------------------------
 EXTENSION:           pdo_pgsql
-PRIMARY MAINTAINER:  Unknown
+PRIMARY MAINTAINER:  Ilia Alshanetsky <iliaa at php.net>
 MAINTENANCE:         Odd fixes
 STATUS:              Working
 SINCE:               5.1
diff --git a/Makefile.global b/Makefile.global
index d87f84c..c77c8fd 100644
--- a/Makefile.global
+++ b/Makefile.global
@@ -82,26 +82,21 @@ PHP_TEST_SHARED_EXTENSIONS =  ` \
 
 test: all
 	- at if test ! -z "$(PHP_EXECUTABLE)" && test -x "$(PHP_EXECUTABLE)"; then \
-		TEST_PHP_EXECUTABLE=$(PHP_EXECUTABLE) \
-		TEST_PHP_SRCDIR=$(top_srcdir) \
-		CC="$(CC)" \
-			$(PHP_EXECUTABLE) $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -d extension_dir=modules/ $(PHP_TEST_SHARED_EXTENSIONS) tests/; \
-	elif test ! -z "$(SAPI_CLI_PATH)" && test -x "$(SAPI_CLI_PATH)"; then \
-		INI_FILE=`$(top_builddir)/$(SAPI_CLI_PATH) -d 'display_errors=stderr' -r 'echo php_ini_loaded_file();' 2> /dev/null`; \
+		INI_FILE=`$(PHP_EXECUTABLE) -d 'display_errors=stderr' -r 'echo php_ini_loaded_file();' 2> /dev/null`; \
 		if test "$$INI_FILE"; then \
 			$(EGREP) -v '^(zend_)?extension(_debug)?(_ts)?[\t\ ]*=' "$$INI_FILE" > $(top_builddir)/tmp-php.ini; \
 		else \
 			echo > $(top_builddir)/tmp-php.ini; \
 		fi; \
-		INI_SCANNED_PATH=`$(top_builddir)/$(SAPI_CLI_PATH) -d 'display_errors=stderr' -r '$$a = explode(",\n", trim(php_ini_scanned_files())); echo $$a[0];' 2> /dev/null`; \
+		INI_SCANNED_PATH=`$(PHP_EXECUTABLE) -d 'display_errors=stderr' -r '$$a = explode(",\n", trim(php_ini_scanned_files())); echo $$a[0];' 2> /dev/null`; \
 		if test "$$INI_SCANNED_PATH"; then \
 			INI_SCANNED_PATH=`$(top_srcdir)/build/shtool path -d $$INI_SCANNED_PATH`; \
 			$(EGREP) -h -v '^(zend_)?extension(_debug)?(_ts)?[\t\ ]*=' "$$INI_SCANNED_PATH"/*.ini >> $(top_builddir)/tmp-php.ini; \
 		fi; \
-		TEST_PHP_EXECUTABLE=$(top_builddir)/$(SAPI_CLI_PATH) \
+		TEST_PHP_EXECUTABLE=$(PHP_EXECUTABLE) \
 		TEST_PHP_SRCDIR=$(top_srcdir) \
 		CC="$(CC)" \
-			$(top_builddir)/$(SAPI_CLI_PATH) -n -c $(top_builddir)/tmp-php.ini $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -n -c $(top_builddir)/tmp-php.ini -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \
+			$(PHP_EXECUTABLE) -n -c $(top_builddir)/tmp-php.ini $(PHP_TEST_SETTINGS) $(top_srcdir)/run-tests.php -n -c $(top_builddir)/tmp-php.ini -d extension_dir=$(top_builddir)/modules/ $(PHP_TEST_SHARED_EXTENSIONS) $(TESTS); \
 	else \
 		echo "ERROR: Cannot run tests without CLI sapi."; \
 	fi
diff --git a/NEWS b/NEWS
index 909ade6..4cb1a62 100644
--- a/NEWS
+++ b/NEWS
@@ -1,80 +1,184 @@
 PHP                                                                        NEWS
 |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
-17 Sep 2009, PHP 5.2.11
-- Fixed certificate validation inside php_openssl_apply_verification_policy.
-  (Ryan Sleevi, Ilia)
+17 Dec 2009, PHP 5.2.12
 
+- Added LIBXML_PARSEHUGE constant to overrides the maximum text size of a
+  single text node when using libxml2.7.3+. (Kalle)
+- Added protection for $_SESSION from interrupt corruption and improved
+  "session.save_path" check. (Stas)
+- Added "max_file_uploads" INI directive, which can be set to limit the
+  number of file uploads per-request to 20 by default, to prevent possible
+  DOS via temporary file exhaustion. (Ilia)
 
-10 Sep 2009, PHP 5.2.11RC3
-- Updated timezone database to version 2009.13 (2009m) (Derick)
+- Improved fix for bug #50006 (Segfault caused by uksort()). (Stas)
+- Fixed error_log() to be binary safe when using message_type 3. (Jani)
+- Fixed unnecessary invocation of setitimer when timeouts have been disabled.
+  (Arvind Srinivasan)
+- Fixed crash in com_print_typeinfo when an invalid typelib is given.
+  (Pierre)
+- Fixed a safe_mode bypass in tempnam() identified by Grzegorz Stachowiak.  
+  (Rasmus)
+- Fixed a open_basedir bypass in posix_mkfifo() identified by Grzegorz 
+  Stachowiak. (Rasmus)
+- Fixed crash in SQLiteDatabase::ArrayQuery() and SQLiteDatabase::SingleQuery()
+  when calling using Reflection. (Felipe)
+- Fixed crash when instantiating PDORow and PDOStatement through Reflection.
+  (Felipe)
+- Fixed memory leak in openssl_pkcs12_export_to_file(). (Felipe)
 
-- Fixed bug #49470 (FILTER_SANITIZE_EMAIL allows disallowed characters). (Ilia)
-- Fixed bug #49447 (php engine needs to correctly check for socket API return
-  status on windows). (Sriram Natarajan)
-- Fixed bug #48060 (pdo_pgsql - large objects are returned as empty). (Matteo)
+- Updated timezone database to version 2009.19 (2009s). (Derick)
 
+- Changed "post_max_size" php.ini directive to allow unlimited post size by
+  setting it to 0. (Rasmus)
+
+- Fixed bug #50445 (PDO-ODBC stored procedure call from Solaris 64-bit causes
+  segfault). (davbrown4 at yahoo dot com, Felipe)
+- Fixed bug #50345 (nanosleep not detected properly on some solaris versions).
+  (Jani)
+- Fixed bug #50323 (Allow use of ; in values via ;; in PDO DSN).
+  (Ilia, Pierrick)
+- Fixed bug #50285 (xmlrpc does not preserve keys in encoded indexed arrays).
+  (Felipe)
+- Fixed bug #50282 (xmlrpc_encode_request() changes object into array in 
+  calling function). (Felipe)
+- Fixed bug #50266 (conflicting types for llabs). (Jani)
+- Fixed bug #50255 (isset() and empty() silently casts array to object).
+  (Felipe)
+- Fixed bug #50219 (soap call Segmentation fault on a redirected url).
+  (Pierrick)
+- Fixed bug #50209 (Compiling with libedit cannot find readline.h).
+  (tcallawa at redhat dot com)
+- Fixed bug #50207 (segmentation fault when concatenating very large strings
+  on 64bit linux). (Ilia)
+- Fixed bug #50195 (pg_copy_to() fails when table name contains schema. (Ilia)
+- Fixed bug #50185 (ldap_get_entries() return false instead of an empty array
+  when there is no error). (Jani)
+- Fixed bug #50174 (Incorrectly matched docComment). (Felipe)
+- Fixed bug #50168 (FastCGI fails with wrong error on HEAD request to
+  non-existent file). (Dmitry)
+- Fixed bug #50162 (Memory leak when fetching timestamp column from Oracle
+  database). (Felipe)
+- Fixed bug #50158 (FILTER_VALIDATE_EMAIL fails with valid addresses
+  containing = or ?). (Pierrick)
+- Fixed bug #50073 (parse_url() incorrect when ? in fragment). (Ilia)
+- Fixed bug #50006 (Segfault caused by uksort()). (Felipe)
+- Fixed bug #50005 (Throwing through Reflection modified Exception object makes
+  segmentation fault). (Felipe)
+- Fixed bug #49990 (SNMP3 warning message about security level printed twice).
+  (Jani)
+- Fixed bug #49985 (pdo_pgsql prepare() re-use previous aborted transaction).
+  (ben dot pineau at gmail dot com, Ilia, Matteo)  
+- Fixed bug #49972 (AppendIterator undefined function crash). (Johannes)
+- Fixed bug #49921 (Curl post upload functions changed). (Ilia)
+- Fixed bug #49855 (import_request_variables() always returns NULL).
+  (Ilia, sjoerd at php dot net)
+- Fixed bug #49847 (exec() fails to return data inside 2nd parameter, given
+  output lines >4095 bytes). (Ilia)
+- Fixed bug #49809 (time_sleep_until() is not available on OpenSolaris). (Jani)
+- Fixed bug #49785 (insufficient input string validation of htmlspecialchars()).
+  (Moriyoshi, hello at iwamot dot com)
+- Fixed bug #49757 (long2ip() can return wrong value in a multi-threaded
+  applications). (Ilia, Florian Anderiasch)
+- Fixed bug #49738 (calling mcrypt() after mcrypt_generic_deinit() crashes).
+  (Sriram Natarajan)
+- Fixed bug #49719 (ReflectionClass::hasProperty returns true for a private
+  property in base class). (Felipe)
+- Fixed bug #49698 (Unexpected change in strnatcasecmp()). (Rasmus)
+- Fixed bug #49677 (ini parser crashes with apache2 and using ${something} ini
+  variables). (Jani)
+- Fixed bug #49660 (libxml 2.7.3+ limits text nodes to 10MB). (Felipe)
+- Fixed bug #49647 (DOMUserData does not exist). (Rob)
+- Fixed bug #49630 (imap_listscan() function missing). (Felipe)
+- Fixed bug #49627 (error_log to specified file does not log time according to
+  date.timezone). (Dmitry)
+- Fixed bug #49578 (make install-pear fails). (Hannes)
+- Fixed bug #49536 (mb_detect_encoding() returns incorrect results when
+  mbstring.strict_mode is turned on). (Moriyoshi)
+- Fixed bug #49531 (CURLOPT_INFILESIZE sometimes causes warning "CURLPROTO_FILE
+  cannot be set"). (Felipe)
+- Fixed bug #49528 (UTF-16 strings prefixed by BOMs wrongly converted).
+  (Moriyoshi)
+- Fixed bug #49521 (PDO fetchObject sets values before calling constructor).
+  (Pierrick)
+- Fixed bug #49517 (cURL's CURLOPT_FILE prevents file from being deleted after
+  fclose()). (Ilia)
+- Fixed bug #49472 (Constants defined in Interfaces can be overridden).
+  (Felipe)
+- Fixed bug #49354 (mb_strcut() cuts wrong length when offset is in the middle
+  of a multibyte character). (Moriyoshi)
+- Fixed bug #49332 (Build error with Snow Leopard). (Scott)
+- Fixed bug #49244 (Floating point NaN cause garbage characters). (Sjoerd)
+- Fixed bug #49174 (crash when extending PDOStatement and trying to set
+  queryString property). (Felipe)
+- Fixed bug #49098 (mysqli segfault on error). (Rasmus)
+- Fixed bug #48805 (IPv6 socket transport is not working). (Ilia)
+- Fixed bug #48764 (PDO_pgsql::query() always uses implicit prepared statements
+  if v3 proto available). (Matteo, Mark Kirkwood)
+- Fixed bug #47848 (importNode doesn't preserve attribute namespaces). (Rob)
+- Fixed bug #45120 (PDOStatement->execute() returns true then false for same
+  statement). (Pierrick)
+- Fixed bug #34852 (Failure in odbc_exec() using oracle-supplied odbc driver).
+  (tim dot tassonis at trivadis dot com)
 
-03 Sep 2009, PHP 5.2.11RC2
-- Added missing sanity checks around exif processing. (Ilia)
 
+17 Sep 2009, PHP 5.2.11
+- Fixed certificate validation inside php_openssl_apply_verification_policy.
+  (Ryan Sleevi, Ilia)
+- Updated timezone database to version 2009.13 (2009m) (Derick)
+- Added missing sanity checks around exif processing. (Ilia)
 - Fixed sanity check for the color index in imagecolortransparent. (Pierre)
 - Fixed zlib.deflate compress filter to actually accept level parameter. (Jani)
 - Fixed leak on error in popen/exec (and related functions) on Windows.
   (Pierre)
+- Fixed regression in cURL extension that prevented flush of data to output
+  defined as a file handle. (Ilia)
+- Fixed memory leak in stream_is_local(). (Felipe, Tony)
 
-- Fixed bug #49361 (wordwrap() wraps incorrectly on end of line boundaries). 
+- Fixed bug #49470 (FILTER_SANITIZE_EMAIL allows disallowed characters). (Ilia)
+- Fixed bug #49447 (php engine needs to correctly check for socket API return
+  status on windows). (Sriram Natarajan)
+- Fixed bug #49372 (segfault in php_curl_option_curl). (Pierre)
+- Fixed bug #49361 (wordwrap() wraps incorrectly on end of line boundaries).
   (Ilia, code-it at mail dot ru)
 - Fixed bug #49289 (bcmath module doesn't compile with phpize configure).
   (Jani)
 - Fixed bug #49286 (php://input (php_stream_input_read) is broken). (Jani)
-- Fixed bug #49269 (Ternary operator fails on Iterator object when used inside
-  foreach declaration). (Etienne, Dmitry)
+- Fixed bug #49269 (Ternary operator fails on Iterator object when used
+  inside foreach declaration). (Etienne, Dmitry)
 - Fixed bug #49236 (Missing PHP_SUBST(PDO_MYSQL_SHARED_LIBADD)). (Jani)
 - Fixed bug #49144 (Import of schema from different host transmits original
   authentication details). (Dmitry)
-- Fixed bug #49000 (PHP CLI in Interactive mode (php -a) crashes when including
-  files from function). (Stas)
-- Fixed bug #48696 (ldap_read() segfaults with invalid parameters). (Felipe)
-- Fixed bug #47273 (Encoding bug in SoapServer->fault). (Dmitry)
-- Fixed bug #28038 (Sent incorrect RCPT TO commands to SMTP server) (Garrett)
-
-
-13 Aug 2009, PHP 5.2.11RC1
-- Fixed regression in cURL extension that prevented flush of data to output
-  defined as a file handle. (Ilia)
-- Fixed memory leak in stream_is_local(). (Felipe, Tony)
-
-- Fixed bug #49372 (segfault in php_curl_option_curl). (Pierre)
 - Fixed bug #49132 (posix_times returns false without error).
   (phpbugs at gunnu dot us)
 - Fixed bug #49125 (Error in dba_exists C code). (jdornan at stanford dot edu)
 - Fixed bug #49095 (proc_get_status['exitcode'] fails on win32). (Felipe)
 - Fixed bug #49074 (private class static fields can be modified by using
   reflection). (Jani)
-- Fixed bug #49072 (feof never returns true for damaged file in zip). (Pierre)
+- Fixed bug #49072 (feof never returns true for damaged file in zip).
+  (Pierre)
 - Fixed bug #49052 (context option headers freed too early when using
   --with-curlwrappers). (Jani)
 - Fixed bug #49032 (SplFileObject::fscanf() variables passed by reference).
   (Jani)
 - Fixed bug #49026 (proc_open() can bypass safe_mode_protected_env_vars
   restrictions). (Ilia)
-- Fixed bug #48994 (zlib.output_compression does not output HTTP headers when
-  set to a string value). (Jani)
+- Fixed bug #49000 (PHP CLI in Interactive mode (php -a) crashes when
+  including files from function). (Stas)
+- Fixed bug #48994 (zlib.output_compression does not output HTTP headers
+  when set to a string value). (Jani)
 - Fixed bug #48980 (Crash when compiling with pdo_firebird). (Felipe)
-- Fixed bug #48962 (cURL does not upload files with specified filename).
-  (Ilia)
+- Fixed bug #48962 (cURL does not upload files with specified filename). (Ilia)
 - Fixed bug #48929 (Double \r\n after HTTP headers when "header" context
   option is an array). (David Zülke)
 - Fixed bug #48913 (Too long error code strings in pdo_odbc driver).
   (naf at altlinux dot ru, Felipe)
 - Fixed bug #48802 (printf() returns incorrect outputted length). (Jani)
 - Fixed bug #48801 (Problem with imagettfbbox). (Takeshi Abe)
-- Fixed bug #48788 (RecursiveDirectoryIterator doesn't descend into symlinked
-  directories). (Ilia)
-- Fixed bug #48774 (SIGSEGVs when using curl_copy_handle()).
-  (Sriram Natarajan)
-- Fixed bug #48763 (ZipArchive produces corrupt archive). (dani dot church at 
-  gmail dot com, Pierre)
+- Fixed bug #48788 (RecursiveDirectoryIterator doesn't descend into
+  symlinked directories). (Ilia)
+- Fixed bug #48774 (SIGSEGVs when using curl_copy_handle()). (Sriram Natarajan)
+- Fixed bug #48763 (ZipArchive produces corrupt archive).
+  (dani dot church at gmail dot com, Pierre)
 - Fixed bug #48762 (IPv6 address filter still rejects valid address). (Felipe)
 - Fixed bug #48733 (CURLOPT_WRITEHEADER|CURLOPT_FILE|CURLOPT_STDERR warns on
   files that have been opened with r+). (Ilia)
@@ -85,6 +189,7 @@ PHP                                                                        NEWS
 - Fixed bug #48709 (metaphone and 'wh'). (brettz9 at yahoo dot com, Felipe)
 - Fixed bug #48697 (mb_internal_encoding() value gets reset by parse_str()).
   (Moriyoshi)
+- Fixed bug #48696 (ldap_read() segfaults with invalid parameters). (Felipe)
 - Fixed bug #48693 (Double declaration of __lambda_func when lambda wrongly
   formatted). (peter at lvp-media dot com, Felipe)
 - Fixed bug #48661 (phpize is broken with non-bash shells). (Jani)
@@ -92,54 +197,57 @@ PHP                                                                        NEWS
   html-entities). (Moriyoshi)
 - Fixed bug #48637 ("file" fopen wrapper is overwritten when using
   --with-curlwrappers). (Jani)
-- Fixed bug #48636 (Error compiling of ext/date on netware). (guenter at
-  php.net, Ilia)
+- Fixed bug #48636 (Error compiling of ext/date on netware).
+  (guenter at php.net, Ilia)
 - Fixed bug #48629 (get_defined_constants() ignores categorize parameter).
   (Felipe)
 - Fixed bug #48619 (imap_search ALL segfaults). (Pierre)
-- Fixed bug #48608 (Invalid libreadline version not detected during configure).
-  (Jani)
-- Fixed bug #48555 (ImageFTBBox() differs from previous versions for texts
-  with new lines) (Takeshi Abe)
+- Fixed bug #48608 (Invalid libreadline version not detected during
+  configure). (Jani)
+- Fixed bug #48555 (ImageFTBBox() differs from previous versions for texts with
+  new lines) (Takeshi Abe)
 - Fixed bug #48539 (pdo_dblib fails to connect, throws empty PDOException
   "SQLSTATE[] (null)"). (Felipe)
-- Fixed bug #48465 (sys_get_temp_dir() possibly inconsistent when using
-  TMPDIR). (Ilia)
+- Fixed bug #48465 (sys_get_temp_dir() possibly inconsistent when using TMPDIR).
+  (Ilia)
 - Fixed bug #48450 (Compile failure under IRIX 6.5.30 building gd.c). (Kalle)
-- Fixed bug #48400 (imap crashes when closing stream opened with
-  OP_PROTOTYPE flag). (Jani)
+- Fixed bug #48400 (imap crashes when closing stream opened with OP_PROTOTYPE
+  flag). (Jani)
 - Fixed bug #48284 (hash "adler32" byte order is reversed). (Scott)
-- Fixed bug #48276 (date("Y") on big endian machines produces the
-  wrong result). (Scott)
+- Fixed bug #48276 (date("Y") on big endian machines produces the wrong
+  result). (Scott)
 - Fixed bug #48247 (Infinite loop and possible crash during startup with
   errors when errors are logged). (Jani)
-- Fixed bug #48116 (Fixed build with Openssl 1.0). (Pierre, 
-  Al dot Smith at aeschi dot ch dot eu dot org)
 - Fixed bug #48182 (ssl handshake fails during asynchronous socket connection).
   (Sriram Natarajan)
+- Fixed bug #48116 (Fixed build with Openssl 1.0).
+  (Pierre, Al dot Smith at aeschi dot ch dot eu dot org)
+- Fixed bug #48060 (pdo_pgsql - large objects are returned as empty). (Matteo)
 - Fixed bug #48057 (Only the date fields of the first row are fetched,
   others are empty). (info at programmiernutte dot net)
 - Fixed bug #47481 (natcasesort() does not sort extended ASCII characters
   correctly). (Herman Radtke)
 - Fixed bug #47351 (Memory leak in DateTime). (Derick, Tobias John)
+- Fixed bug #47273 (Encoding bug in SoapServer->fault). (Dmitry)
 - Fixed bug #46020 (with Sun Java System Web Server 7.0 on HPUX, #define HPUX).
   (Uwe Schindler)
 - Fixed bug #45905 (imagefilledrectangle() clipping error).
   (markril at hotmail dot com, Pierre)
-- Fixed bug #45280 (Reflection of instantiated COM classes causes PHP to crash) 
-  (Paul Richards, Kalle)
+- Fixed bug #45280 (Reflection of instantiated COM classes causes PHP to
+  crash). (Paul Richards, Kalle)
 - Fixed bug #45141 (setcookie will output expires years of >4 digits). (Ilia)
 - Fixed bug #44683 (popen crashes when an invalid mode is passed). (Pierre)
 - Fixed bug #44144 (spl_autoload_functions() should return object instance
   when appropriate). (Hannes, Etienne)
-- Fixed bug #43510 (stream_get_meta_data() does not return same mode as used
-  in fopen). (Jani)
-- Fixed bug #42434 (ImageLine w/ antialias = 1px shorter). (wojjie at gmail dot 
-  com, Kalle)
+- Fixed bug #43510 (stream_get_meta_data() does not return same mode as used in
+  fopen). (Jani)
+- Fixed bug #42434 (ImageLine w/ antialias = 1px shorter).
+  (wojjie at gmail dot com, Kalle)
+- Fixed bug #28038 (Sent incorrect RCPT TO commands to SMTP server) (Garrett)
+- Fixed bug #49572 (use of C++ style comments causes build failure).
+  (Sriram Natarajan)
 
 17 Jun 2009, PHP 5.2.10
-- Updated timezone database to version 2009.9 (2009i) (Derick)
-
 - Added "ignore_errors" option to http fopen wrapper. (David Zulke, Sara)
 - Added new CURL options CURLOPT_REDIR_PROTOCOLS, CURLOPT_PROTOCOLS,
   and CURLPROTO_* for redirect fixes in CURL 7.19.4. (Yoram Bar Haim, Stas)
diff --git a/Zend/tests/bug41919.phpt b/Zend/tests/bug41919.phpt
index 2c4f985..0ac3276 100644
--- a/Zend/tests/bug41919.phpt
+++ b/Zend/tests/bug41919.phpt
@@ -8,6 +8,4 @@ $foo[3]->bar[1] = "bang";
 echo "ok\n";
 ?>
 --EXPECTF--
-Notice: Uninitialized string offset: 3 in %s on line %d
-
 Fatal error: Cannot use string offset as an object in %sbug41919.php on line %d
diff --git a/Zend/tests/bug49472.phpt b/Zend/tests/bug49472.phpt
new file mode 100644
index 0000000..1803d18
--- /dev/null
+++ b/Zend/tests/bug49472.phpt
@@ -0,0 +1,27 @@
+--TEST--
+Bug #49472 (Constants defined in Interfaces can be overridden)
+--FILE--
+<?php
+
+interface ia {
+    const c = 'Sea';
+    const y = 2;
+}
+
+class Foo implements ia {
+}
+
+class FooBar extends Foo implements ia {
+	const x = 1;
+	const c = 'Ocean';
+	
+	public function show() {
+		return ia::c;
+	}
+}
+
+new FooBar;
+
+?>
+--EXPECTF--
+Fatal error: Cannot inherit previously-inherited or override constant c from interface ia in %s on line %d
diff --git a/Zend/tests/bug50005.phpt b/Zend/tests/bug50005.phpt
new file mode 100644
index 0000000..bf4fbbd
--- /dev/null
+++ b/Zend/tests/bug50005.phpt
@@ -0,0 +1,19 @@
+--TEST--
+Bug #50005 (Throwing through Reflection modified Exception object makes segmentation fault)
+--FILE--
+<?php
+
+class a extends exception {
+	public function __construct() {
+		$this->file = null;
+	}
+}
+
+throw new a;
+
+?>
+--EXPECTF--
+Fatal error: Uncaught exception 'a' in :%d
+Stack trace:
+#0 {main}
+  thrown in Unknown on line %d
diff --git a/Zend/tests/bug50174.phpt b/Zend/tests/bug50174.phpt
new file mode 100644
index 0000000..fef6513
--- /dev/null
+++ b/Zend/tests/bug50174.phpt
@@ -0,0 +1,33 @@
+--TEST--
+Bug #50174 (Incorrectly matched docComment)
+--SKIPIF--
+<?php if (!extension_loaded('reflection') || !extension_loaded('spl')) print "skip"; ?>
+--FILE--
+<?php
+
+class TestClass
+{
+	/** const comment */
+	const C = 0;
+
+	function x() {}
+}
+
+$rm = new ReflectionMethod('TestClass', 'x');
+var_dump($rm->getDocComment());
+
+class TestClass2
+{
+	/** const comment */
+	const C = 0;
+
+	public $x;
+}
+
+$rp = new ReflectionProperty('TestClass2', 'x');
+var_dump($rp->getDocComment());
+
+?>
+--EXPECT--
+bool(false)
+bool(false)
diff --git a/Zend/tests/bug50255.phpt b/Zend/tests/bug50255.phpt
new file mode 100644
index 0000000..9f390af
--- /dev/null
+++ b/Zend/tests/bug50255.phpt
@@ -0,0 +1,30 @@
+--TEST--
+Bug #50255 (isset() and empty() silently casts array to object)
+--FILE--
+<?php
+
+$arr = array('foo' => 'bar');
+
+print "isset\n";
+var_dump(isset($arr->foo));
+var_dump(isset($arr->bar));
+var_dump(isset($arr['foo']));
+var_dump(isset($arr['bar']));
+print "empty\n";
+var_dump(empty($arr->foo));
+var_dump(empty($arr->bar));
+var_dump(empty($arr['foo']));
+var_dump(empty($arr['bar']));
+
+?>
+--EXPECT--
+isset
+bool(false)
+bool(false)
+bool(true)
+bool(false)
+empty
+bool(true)
+bool(true)
+bool(false)
+bool(true)
diff --git a/Zend/tests/errmsg_025.phpt b/Zend/tests/errmsg_025.phpt
index d853f73..014b409 100644
--- a/Zend/tests/errmsg_025.phpt
+++ b/Zend/tests/errmsg_025.phpt
@@ -16,5 +16,5 @@ class test implements test1, test2 {
 
 echo "Done\n";
 ?>
---EXPECTF--	
-Fatal error: Cannot inherit previously-inherited constant FOO from interface test2 in %s on line %d
+--EXPECTF--
+Fatal error: Cannot inherit previously-inherited or override constant FOO from interface test2 in %s on line %d
diff --git a/Zend/zend_compile.c b/Zend/zend_compile.c
index 8a620ff..9fb1c35 100644
--- a/Zend/zend_compile.c
+++ b/Zend/zend_compile.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: zend_compile.c 280170 2009-05-08 17:50:58Z mattwil $ */
+/* $Id: zend_compile.c 291642 2009-12-03 12:34:50Z felipe $ */
 
 #include <zend_language_parser.h>
 #include "zend.h"
@@ -2333,20 +2333,28 @@ ZEND_API void zend_do_inheritance(zend_class_entry *ce, zend_class_entry *parent
 	}
 }
 
-
 static zend_bool do_inherit_constant_check(HashTable *child_constants_table, zval **parent_constant, zend_hash_key *hash_key, zend_class_entry *iface)
 {
 	zval **old_constant;
 
 	if (zend_hash_quick_find(child_constants_table, hash_key->arKey, hash_key->nKeyLength, hash_key->h, (void**)&old_constant) == SUCCESS) {
-	  if (*old_constant != *parent_constant) {
-			zend_error(E_COMPILE_ERROR, "Cannot inherit previously-inherited constant %s from interface %s", hash_key->arKey, iface->name);
+		if (*old_constant != *parent_constant) {
+			zend_error(E_COMPILE_ERROR, "Cannot inherit previously-inherited or override constant %s from interface %s", hash_key->arKey, iface->name);
 		}
 		return 0;
 	}
 	return 1;
 }
 
+static int do_interface_constant_check(zval **val, int num_args, va_list args, zend_hash_key *key) /* {{{ */
+{
+	zend_class_entry **iface = va_arg(args, zend_class_entry**);
+
+	do_inherit_constant_check(&(*iface)->constants_table, val, key, *iface);
+
+	return ZEND_HASH_APPLY_KEEP;
+}
+/* }}} */
 
 ZEND_API void zend_do_implement_interface(zend_class_entry *ce, zend_class_entry *iface TSRMLS_DC)
 {
@@ -2366,7 +2374,10 @@ ZEND_API void zend_do_implement_interface(zend_class_entry *ce, zend_class_entry
 			}
 		}
 	}
-	if (!ignore) {
+	if (ignore) {
+		/* Check for attempt to redeclare interface constants */
+		zend_hash_apply_with_arguments(&ce->constants_table, (apply_func_args_t) do_interface_constant_check, 1, &iface);
+	} else {
 		if (ce->num_interfaces >= current_iface_num) {
 			if (ce->type == ZEND_INTERNAL_CLASS) {
 				ce->interfaces = (zend_class_entry **) realloc(ce->interfaces, sizeof(zend_class_entry *) * (++current_iface_num));
@@ -3103,6 +3114,12 @@ void zend_do_declare_class_constant(znode *var_name, znode *value TSRMLS_DC)
 		zend_error(E_COMPILE_ERROR, "Cannot redefine class constant %s::%s", CG(active_class_entry)->name, var_name->u.constant.value.str.val);
 	}
 	FREE_PNODE(var_name);
+	
+	if (CG(doc_comment)) {
+		efree(CG(doc_comment));
+		CG(doc_comment) = NULL;
+		CG(doc_comment_len) = 0;
+	}
 }
 
 
diff --git a/Zend/zend_execute.c b/Zend/zend_execute.c
index c7ad61f..efea88b 100644
--- a/Zend/zend_execute.c
+++ b/Zend/zend_execute.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: zend_execute.c 278340 2009-04-06 23:56:20Z felipe $ */
+/* $Id: zend_execute.c 288525 2009-09-21 13:32:10Z dmitry $ */
 
 #define ZEND_INTENSIVE_DEBUGGING 0
 
@@ -1132,7 +1132,8 @@ static void zend_fetch_dimension_address(temp_variable *result, zval **container
 						break;
 				}
 				if (result) {
-					if (Z_LVAL_P(dim) < 0 || Z_STRLEN_P(container) <= Z_LVAL_P(dim)) {
+					if ((Z_LVAL_P(dim) < 0 || Z_STRLEN_P(container) <= Z_LVAL_P(dim)) &&
+					    (type == BP_VAR_R || type == BP_VAR_IS)) {
 						zend_error(E_NOTICE, "Uninitialized string offset: %ld", Z_LVAL_P(dim));
 					}
 					container = *container_ptr;
diff --git a/Zend/zend_execute_API.c b/Zend/zend_execute_API.c
index bceff0e..f1ecb9f 100644
--- a/Zend/zend_execute_API.c
+++ b/Zend/zend_execute_API.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: zend_execute_API.c 288345 2009-09-15 00:09:13Z moriyoshi $ */
+/* $Id: zend_execute_API.c 290231 2009-11-05 09:33:19Z dmitry $ */
 
 #include <stdio.h>
 #include <signal.h>
@@ -1511,7 +1511,7 @@ void zend_unset_timeout(TSRMLS_D)
 	}
 #else
 #	ifdef HAVE_SETITIMER
-	{
+	if (EG(timeout_seconds)) {
 		struct itimerval no_timeout;
 
 		no_timeout.it_value.tv_sec = no_timeout.it_value.tv_usec = no_timeout.it_interval.tv_sec = no_timeout.it_interval.tv_usec = 0;
diff --git a/Zend/zend_objects.c b/Zend/zend_objects.c
index c7e909b..cf386c7 100644
--- a/Zend/zend_objects.c
+++ b/Zend/zend_objects.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: zend_objects.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: zend_objects.c 289581 2009-10-12 17:09:11Z felipe $ */
 
 #include "zend.h"
 #include "zend_globals.h"
@@ -49,7 +49,7 @@ ZEND_API void zend_object_std_dtor(zend_object *object TSRMLS_DC)
 
 ZEND_API void zend_objects_destroy_object(zend_object *object, zend_object_handle handle TSRMLS_DC)
 {
-	zend_function *destructor = object->ce->destructor;
+	zend_function *destructor = object ? object->ce->destructor : NULL;
 
 	if (destructor) {
 		zval *obj;
diff --git a/Zend/zend_operators.c b/Zend/zend_operators.c
index 8c76c0d..428f9e6 100644
--- a/Zend/zend_operators.c
+++ b/Zend/zend_operators.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: zend_operators.c 276004 2009-02-17 15:15:36Z mattwil $ */
+/* $Id: zend_operators.c 291172 2009-11-23 04:12:36Z iliaa $ */
 
 #include <ctype.h>
 
@@ -1202,6 +1202,12 @@ ZEND_API int concat_function(zval *result, zval *op1, zval *op2 TSRMLS_DC)
 	}
 	if (result==op1) {	/* special case, perform operations on result */
 		uint res_len = op1->value.str.len + op2->value.str.len;
+
+		if (Z_STRLEN_P(result) < 0 || (int) (Z_STRLEN_P(op1) + Z_STRLEN_P(op2)) < 0) {
+			efree(Z_STRVAL_P(result));
+			ZVAL_EMPTY_STRING(result);
+			zend_error(E_ERROR, "String size overflow");
+		}
 		
 		result->value.str.val = erealloc(result->value.str.val, res_len+1);
 
diff --git a/Zend/zend_vm_def.h b/Zend/zend_vm_def.h
index 5e250e4..facb687 100644
--- a/Zend/zend_vm_def.h
+++ b/Zend/zend_vm_def.h
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: zend_vm_def.h 287466 2009-08-18 20:51:49Z stas $ */
+/* $Id: zend_vm_def.h 291282 2009-11-24 21:54:12Z felipe $ */
 
 /* If you change this file, please regenerate the zend_vm_execute.h and
  * zend_vm_opcodes.h files by running:
@@ -939,6 +939,7 @@ ZEND_VM_HELPER_EX(zend_fetch_var_address_helper, CONST|TMP|VAR|CV, ANY, int type
 
 	if (opline->op2.u.EA.type == ZEND_FETCH_STATIC_MEMBER) {
 		retval = zend_std_get_static_property(EX_T(opline->op2.u.var).class_entry, Z_STRVAL_P(varname), Z_STRLEN_P(varname), 0 TSRMLS_CC);
+		FREE_OP1();
 	} else {
 		target_symbol_table = zend_get_target_symbol_table(opline, EX(Ts), type, varname TSRMLS_CC);
 /*
@@ -3531,7 +3532,7 @@ ZEND_VM_HELPER_EX(zend_isset_isempty_dim_prop_obj_handler, VAR|UNUSED|CV, CONST|
 		zend_free_op free_op2;
 		zval *offset = GET_OP2_ZVAL_PTR(BP_VAR_R);
 
-		if (Z_TYPE_PP(container) == IS_ARRAY) {
+		if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) {
 			HashTable *ht;
 			int isset = 0;
 
diff --git a/Zend/zend_vm_execute.h b/Zend/zend_vm_execute.h
index f348b31..9aa59ff 100644
--- a/Zend/zend_vm_execute.h
+++ b/Zend/zend_vm_execute.h
@@ -1531,6 +1531,7 @@ static int zend_fetch_var_address_helper_SPEC_CONST(int type, ZEND_OPCODE_HANDLE
 
 	if (opline->op2.u.EA.type == ZEND_FETCH_STATIC_MEMBER) {
 		retval = zend_std_get_static_property(EX_T(opline->op2.u.var).class_entry, Z_STRVAL_P(varname), Z_STRLEN_P(varname), 0 TSRMLS_CC);
+
 	} else {
 		target_symbol_table = zend_get_target_symbol_table(opline, EX(Ts), type, varname TSRMLS_CC);
 /*
@@ -4111,6 +4112,7 @@ static int zend_fetch_var_address_helper_SPEC_TMP(int type, ZEND_OPCODE_HANDLER_
 
 	if (opline->op2.u.EA.type == ZEND_FETCH_STATIC_MEMBER) {
 		retval = zend_std_get_static_property(EX_T(opline->op2.u.var).class_entry, Z_STRVAL_P(varname), Z_STRLEN_P(varname), 0 TSRMLS_CC);
+		zval_dtor(free_op1.var);
 	} else {
 		target_symbol_table = zend_get_target_symbol_table(opline, EX(Ts), type, varname TSRMLS_CC);
 /*
@@ -7166,6 +7168,7 @@ static int zend_fetch_var_address_helper_SPEC_VAR(int type, ZEND_OPCODE_HANDLER_
 
 	if (opline->op2.u.EA.type == ZEND_FETCH_STATIC_MEMBER) {
 		retval = zend_std_get_static_property(EX_T(opline->op2.u.var).class_entry, Z_STRVAL_P(varname), Z_STRLEN_P(varname), 0 TSRMLS_CC);
+		if (free_op1.var) {zval_ptr_dtor(&free_op1.var);};
 	} else {
 		target_symbol_table = zend_get_target_symbol_table(opline, EX(Ts), type, varname TSRMLS_CC);
 /*
@@ -9747,7 +9750,7 @@ static int zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CONST(int prop_dim,
 
 		zval *offset = &opline->op2.u.constant;
 
-		if (Z_TYPE_PP(container) == IS_ARRAY) {
+		if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) {
 			HashTable *ht;
 			int isset = 0;
 
@@ -11280,7 +11283,7 @@ static int zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_TMP(int prop_dim, ZE
 		zend_free_op free_op2;
 		zval *offset = _get_zval_ptr_tmp(&opline->op2, EX(Ts), &free_op2 TSRMLS_CC);
 
-		if (Z_TYPE_PP(container) == IS_ARRAY) {
+		if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) {
 			HashTable *ht;
 			int isset = 0;
 
@@ -12861,7 +12864,7 @@ static int zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_VAR(int prop_dim, ZE
 		zend_free_op free_op2;
 		zval *offset = _get_zval_ptr_var(&opline->op2, EX(Ts), &free_op2 TSRMLS_CC);
 
-		if (Z_TYPE_PP(container) == IS_ARRAY) {
+		if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) {
 			HashTable *ht;
 			int isset = 0;
 
@@ -14887,7 +14890,7 @@ static int zend_isset_isempty_dim_prop_obj_handler_SPEC_VAR_CV(int prop_dim, ZEN
 
 		zval *offset = _get_zval_ptr_cv(&opline->op2, EX(Ts), BP_VAR_R TSRMLS_CC);
 
-		if (Z_TYPE_PP(container) == IS_ARRAY) {
+		if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) {
 			HashTable *ht;
 			int isset = 0;
 
@@ -16006,7 +16009,7 @@ static int zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CONST(int prop_di
 
 		zval *offset = &opline->op2.u.constant;
 
-		if (Z_TYPE_PP(container) == IS_ARRAY) {
+		if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) {
 			HashTable *ht;
 			int isset = 0;
 
@@ -16999,7 +17002,7 @@ static int zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_TMP(int prop_dim,
 		zend_free_op free_op2;
 		zval *offset = _get_zval_ptr_tmp(&opline->op2, EX(Ts), &free_op2 TSRMLS_CC);
 
-		if (Z_TYPE_PP(container) == IS_ARRAY) {
+		if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) {
 			HashTable *ht;
 			int isset = 0;
 
@@ -17992,7 +17995,7 @@ static int zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_VAR(int prop_dim,
 		zend_free_op free_op2;
 		zval *offset = _get_zval_ptr_var(&opline->op2, EX(Ts), &free_op2 TSRMLS_CC);
 
-		if (Z_TYPE_PP(container) == IS_ARRAY) {
+		if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) {
 			HashTable *ht;
 			int isset = 0;
 
@@ -19253,7 +19256,7 @@ static int zend_isset_isempty_dim_prop_obj_handler_SPEC_UNUSED_CV(int prop_dim,
 
 		zval *offset = _get_zval_ptr_cv(&opline->op2, EX(Ts), BP_VAR_R TSRMLS_CC);
 
-		if (Z_TYPE_PP(container) == IS_ARRAY) {
+		if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) {
 			HashTable *ht;
 			int isset = 0;
 
@@ -19600,6 +19603,7 @@ static int zend_fetch_var_address_helper_SPEC_CV(int type, ZEND_OPCODE_HANDLER_A
 
 	if (opline->op2.u.EA.type == ZEND_FETCH_STATIC_MEMBER) {
 		retval = zend_std_get_static_property(EX_T(opline->op2.u.var).class_entry, Z_STRVAL_P(varname), Z_STRLEN_P(varname), 0 TSRMLS_CC);
+
 	} else {
 		target_symbol_table = zend_get_target_symbol_table(opline, EX(Ts), type, varname TSRMLS_CC);
 /*
@@ -22014,7 +22018,7 @@ static int zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CONST(int prop_dim, Z
 
 		zval *offset = &opline->op2.u.constant;
 
-		if (Z_TYPE_PP(container) == IS_ARRAY) {
+		if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) {
 			HashTable *ht;
 			int isset = 0;
 
@@ -23539,7 +23543,7 @@ static int zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_TMP(int prop_dim, ZEN
 		zend_free_op free_op2;
 		zval *offset = _get_zval_ptr_tmp(&opline->op2, EX(Ts), &free_op2 TSRMLS_CC);
 
-		if (Z_TYPE_PP(container) == IS_ARRAY) {
+		if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) {
 			HashTable *ht;
 			int isset = 0;
 
@@ -25111,7 +25115,7 @@ static int zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_VAR(int prop_dim, ZEN
 		zend_free_op free_op2;
 		zval *offset = _get_zval_ptr_var(&opline->op2, EX(Ts), &free_op2 TSRMLS_CC);
 
-		if (Z_TYPE_PP(container) == IS_ARRAY) {
+		if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) {
 			HashTable *ht;
 			int isset = 0;
 
@@ -27127,7 +27131,7 @@ static int zend_isset_isempty_dim_prop_obj_handler_SPEC_CV_CV(int prop_dim, ZEND
 
 		zval *offset = _get_zval_ptr_cv(&opline->op2, EX(Ts), BP_VAR_R TSRMLS_CC);
 
-		if (Z_TYPE_PP(container) == IS_ARRAY) {
+		if (Z_TYPE_PP(container) == IS_ARRAY && !prop_dim) {
 			HashTable *ht;
 			int isset = 0;
 
diff --git a/acinclude.m4 b/acinclude.m4
index 46e6eb7..e54b5e3 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: acinclude.m4 287126 2009-08-11 23:45:35Z srinatar $
+dnl $Id: acinclude.m4 291414 2009-11-29 06:13:22Z rasmus $
 dnl
 dnl This file contains local autoconf functions.
 dnl
@@ -1688,7 +1688,7 @@ dnl PHP_BROKEN_GLIBC_FOPEN_APPEND
 dnl
 AC_DEFUN([PHP_BROKEN_GLIBC_FOPEN_APPEND], [
   AC_MSG_CHECKING([for broken libc stdio])
-  AC_CACHE_VAL(have_broken_glibc_fopen_append,[
+  AC_CACHE_VAL(_cv_have_broken_glibc_fopen_append,[
   AC_TRY_RUN([
 #include <stdio.h>
 int main(int argc, char *argv[])
@@ -1714,8 +1714,8 @@ int main(int argc, char *argv[])
   return 0;
 }
 ],
-[have_broken_glibc_fopen_append=no],
-[have_broken_glibc_fopen_append=yes ],
+[_cv_have_broken_glibc_fopen_append=no],
+[_cv_have_broken_glibc_fopen_append=yes ],
 AC_TRY_COMPILE([
 #include <features.h>
 ],[
@@ -1723,11 +1723,11 @@ AC_TRY_COMPILE([
 choke me
 #endif
 ],
-[have_broken_glibc_fopen_append=yes],
-[have_broken_glibc_fopen_append=no ])
+[_cv_have_broken_glibc_fopen_append=yes],
+[_cv_have_broken_glibc_fopen_append=no ])
 )])
 
-  if test "$have_broken_glibc_fopen_append" = "yes"; then
+  if test "$_cv_have_broken_glibc_fopen_append" = "yes"; then
     AC_MSG_RESULT(yes)
     AC_DEFINE(HAVE_BROKEN_GLIBC_FOPEN_APPEND,1, [Define if your glibc borks on fopen with mode a+])
   else
diff --git a/aclocal.m4 b/aclocal.m4
index 68a847c..27db09c 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: acinclude.m4 287126 2009-08-11 23:45:35Z srinatar $
+dnl $Id: acinclude.m4 291414 2009-11-29 06:13:22Z rasmus $
 dnl
 dnl This file contains local autoconf functions.
 dnl
@@ -1688,7 +1688,7 @@ dnl PHP_BROKEN_GLIBC_FOPEN_APPEND
 dnl
 AC_DEFUN([PHP_BROKEN_GLIBC_FOPEN_APPEND], [
   AC_MSG_CHECKING([for broken libc stdio])
-  AC_CACHE_VAL(have_broken_glibc_fopen_append,[
+  AC_CACHE_VAL(_cv_have_broken_glibc_fopen_append,[
   AC_TRY_RUN([
 #include <stdio.h>
 int main(int argc, char *argv[])
@@ -1714,8 +1714,8 @@ int main(int argc, char *argv[])
   return 0;
 }
 ],
-[have_broken_glibc_fopen_append=no],
-[have_broken_glibc_fopen_append=yes ],
+[_cv_have_broken_glibc_fopen_append=no],
+[_cv_have_broken_glibc_fopen_append=yes ],
 AC_TRY_COMPILE([
 #include <features.h>
 ],[
@@ -1723,11 +1723,11 @@ AC_TRY_COMPILE([
 choke me
 #endif
 ],
-[have_broken_glibc_fopen_append=yes],
-[have_broken_glibc_fopen_append=no ])
+[_cv_have_broken_glibc_fopen_append=yes],
+[_cv_have_broken_glibc_fopen_append=no ])
 )])
 
-  if test "$have_broken_glibc_fopen_append" = "yes"; then
+  if test "$_cv_have_broken_glibc_fopen_append" = "yes"; then
     AC_MSG_RESULT(yes)
     AC_DEFINE(HAVE_BROKEN_GLIBC_FOPEN_APPEND,1, [Define if your glibc borks on fopen with mode a+])
   else
@@ -2875,15 +2875,15 @@ main()
 ])
 
 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
-## Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005
-## Free Software Foundation, Inc.
+## Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007,
+## 2008  Free Software Foundation, Inc.
 ## Originally by Gordon Matzigkeit <gord at gnu.ai.mit.edu>, 1996
 ##
 ## This file is free software; the Free Software Foundation gives
 ## unlimited permission to copy and/or distribute it, with or without
 ## modifications, as long as this notice is preserved.
 
-# serial 47 AC_PROG_LIBTOOL
+# serial 52 AC_PROG_LIBTOOL
 
 ifdef([AC_ACVERSION],[
 # autoconf 2.13 compatibility
@@ -2920,30 +2920,6 @@ dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX.
     [AC_LIBTOOL_CXX],
     [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX
   ])])
-
-dnl dnl And a similar setup for Fortran 77 support
-dnl   AC_PROVIDE_IFELSE([AC_PROG_F77],
-dnl     [AC_LIBTOOL_F77],
-dnl     [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77
-dnl ])])
-
-dnl dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly.
-dnl dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run
-dnl dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both.
-dnl   AC_PROVIDE_IFELSE([AC_PROG_GCJ],
-dnl     [AC_LIBTOOL_GCJ],
-dnl     [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
-dnl       [AC_LIBTOOL_GCJ],
-dnl       [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],
-dnl 	[AC_LIBTOOL_GCJ],
-dnl       [ifdef([AC_PROG_GCJ],
-dnl 	     [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])
-dnl        ifdef([A][M_PROG_GCJ],
-dnl 	     [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])])
-dnl        ifdef([LT_AC_PROG_GCJ],
-dnl 	     [define([LT_AC_PROG_GCJ],
-dnl 		defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])])
-dnl ])
 ])# AC_PROG_LIBTOOL
 
 
@@ -2952,8 +2928,6 @@ dnl ])
 AC_DEFUN([_AC_PROG_LIBTOOL],
 [AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
 AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl
-dnl AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl
-dnl AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl
 
 # This can be used to rebuild libtool when needed
 LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
@@ -2987,7 +2961,6 @@ AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl
 AC_REQUIRE([AC_OBJEXT])dnl
 AC_REQUIRE([AC_EXEEXT])dnl
 dnl
-
 AC_LIBTOOL_SYS_MAX_CMD_LEN
 AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
 AC_LIBTOOL_OBJDIR
@@ -3049,6 +3022,7 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
 test -z "$AS" && AS=as
 test -z "$CC" && CC=cc
 test -z "$LTCC" && LTCC=$CC
+test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
 test -z "$DLLTOOL" && DLLTOOL=dlltool
 test -z "$LD" && LD=ld
 test -z "$LN_S" && LN_S="ln -s"
@@ -3061,17 +3035,17 @@ test -z "$STRIP" && STRIP=:
 test -z "$ac_objext" && ac_objext=o
 
 # Determine commands to create old-style static archives.
-old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
+old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
 old_postinstall_cmds='chmod 644 $oldlib'
 old_postuninstall_cmds=
 
 if test -n "$RANLIB"; then
   case $host_os in
   openbsd*)
-    old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
+    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
     ;;
   *)
-    old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
+    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
     ;;
   esac
   old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
@@ -3088,6 +3062,8 @@ file_magic*)
   ;;
 esac
 
+_LT_REQUIRED_DARWIN_CHECKS
+
 AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no)
 AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
 enable_win32_dll=yes, enable_win32_dll=no)
@@ -3117,6 +3093,9 @@ AC_DEFUN([_LT_AC_SYS_COMPILER],
 # If no C compiler was specified, use CC.
 LTCC=${LTCC-"$CC"}
 
+# If no C compiler flags were specified, use CFLAGS.
+LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
+
 # Allow CC to be a program name with arguments.
 compiler=$CC
 ])# _LT_AC_SYS_COMPILER
@@ -3143,9 +3122,10 @@ cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
 # Check for compiler boilerplate output or warnings with
 # the simple compiler test code.
 AC_DEFUN([_LT_COMPILER_BOILERPLATE],
-[ac_outfile=conftest.$ac_objext
-printf "$lt_simple_compile_test_code" >conftest.$ac_ext
-eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+ac_outfile=conftest.$ac_objext
+echo "$lt_simple_compile_test_code" >conftest.$ac_ext
+eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
 _lt_compiler_boilerplate=`cat conftest.err`
 $rm conftest*
 ])# _LT_COMPILER_BOILERPLATE
@@ -3156,11 +3136,12 @@ $rm conftest*
 # Check for linker boilerplate output or warnings with
 # the simple link test code.
 AC_DEFUN([_LT_LINKER_BOILERPLATE],
-[ac_outfile=conftest.$ac_objext
-printf "$lt_simple_link_test_code" >conftest.$ac_ext
-eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+ac_outfile=conftest.$ac_objext
+echo "$lt_simple_link_test_code" >conftest.$ac_ext
+eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
 _lt_linker_boilerplate=`cat conftest.err`
-$rm conftest*
+$rm -r conftest*
 ])# _LT_LINKER_BOILERPLATE
 
 
@@ -3176,7 +3157,7 @@ int main() {
 ; return 0; }
 EOF
 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
-  ifelse([$1], , :, [$1
+ ifelse([$1], , :, [$1
   rm -rf conftest*])
 else
   echo "configure: failed program was:" >&5
@@ -3187,6 +3168,75 @@ ifelse([$2], , , [$2
 fi
 rm -f conftest*])
 
+# _LT_REQUIRED_DARWIN_CHECKS
+# --------------------------
+# Check for some things on darwin
+AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS],[
+  case $host_os in
+    rhapsody* | darwin*)
+    AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
+    AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
+
+    AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
+      [lt_cv_apple_cc_single_mod=no
+      if test -z "${LT_MULTI_MODULE}"; then
+   # By default we will add the -single_module flag. You can override
+   # by either setting the environment variable LT_MULTI_MODULE
+   # non-empty at configure time, or by adding -multi_module to the
+   # link flags.
+   echo "int foo(void){return 1;}" > conftest.c
+   $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
+     -dynamiclib ${wl}-single_module conftest.c
+   if test -f libconftest.dylib; then
+     lt_cv_apple_cc_single_mod=yes
+     rm -rf libconftest.dylib*
+   fi
+   rm conftest.c
+      fi])
+    AC_CACHE_CHECK([for -exported_symbols_list linker flag],
+      [lt_cv_ld_exported_symbols_list],
+      [lt_cv_ld_exported_symbols_list=no
+      save_LDFLAGS=$LDFLAGS
+      echo "_main" > conftest.sym
+      LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
+      _LT_AC_TRY_LINK([lt_cv_ld_exported_symbols_list=yes],[lt_cv_ld_exported_symbols_list=no])
+   LDFLAGS="$save_LDFLAGS"
+    ])
+    case $host_os in
+    rhapsody* | darwin1.[[0123]])
+      _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
+    darwin1.*)
+     _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
+    darwin*)
+      # if running on 10.5 or later, the deployment target defaults
+      # to the OS version, if on x86, and 10.4, the deployment
+      # target defaults to 10.4. Don't you love it?
+      case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
+   10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
+     _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
+   10.[[012]]*)
+     _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
+   10.*)
+     _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
+      esac
+    ;;
+  esac
+    if test "$lt_cv_apple_cc_single_mod" = "yes"; then
+      _lt_dar_single_mod='$single_module'
+    fi
+    if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
+      _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
+    else
+      _lt_dar_export_syms="~$NMEDIT -s \$output_objdir/\${libname}-symbols.expsym \${lib}"
+    fi
+    if test "$DSYMUTIL" != ":"; then
+      _lt_dsymutil="~$DSYMUTIL \$lib || :"
+    else
+      _lt_dsymutil=
+    fi
+    ;;
+  esac
+])
 
 # _LT_AC_SYS_LIBPATH_AIX
 # ----------------------
@@ -3197,12 +3247,20 @@ rm -f conftest*])
 # If we don't find anything, use the default library path according
 # to the aix ld manual.
 AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX],
-[_LT_AC_TRY_LINK([
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
-}'`
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+_LT_AC_TRY_LINK([
+lt_aix_libpath_sed='
+    /Import File Strings/,/^$/ {
+	/^0/ {
+	    s/^0  *\(.*\)$/\1/
+	    p
+	}
+    }'
+aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
 # Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
-}'`; fi],[])
+if test -z "$aix_libpath"; then
+  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+fi],[])
 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 ])# _LT_AC_SYS_LIBPATH_AIX
 
@@ -3433,13 +3491,17 @@ ia64-*-hpux*)
   rm -rf conftest*
   ;;
 
-x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
+x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
+s390*-*linux*|sparc*-*linux*)
   # Find out which ABI we are using.
   echo 'int i;' > conftest.$ac_ext
   if AC_TRY_EVAL(ac_compile); then
     case `/usr/bin/file conftest.o` in
     *32-bit*)
       case $host in
+        x86_64-*kfreebsd*-gnu)
+          LD="${LD-ld} -m elf_i386_fbsd"
+          ;;
         x86_64-*linux*)
           LD="${LD-ld} -m elf_i386"
           ;;
@@ -3456,6 +3518,9 @@ x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
       ;;
     *64-bit*)
       case $host in
+        x86_64-*kfreebsd*-gnu)
+          LD="${LD-ld} -m elf_x86_64_fbsd"
+          ;;
         x86_64-*linux*)
           LD="${LD-ld} -m elf_x86_64"
           ;;
@@ -3489,6 +3554,26 @@ x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
     CFLAGS="$SAVE_CFLAGS"
   fi
   ;;
+sparc*-*solaris*)
+  # Find out which ABI we are using.
+  echo 'int i;' > conftest.$ac_ext
+  if AC_TRY_EVAL(ac_compile); then
+    case `/usr/bin/file conftest.o` in
+    *64-bit*)
+      case $lt_cv_prog_gnu_ld in
+      yes*) LD="${LD-ld} -m elf64_sparc" ;;
+      *)
+        if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
+	  LD="${LD-ld} -64"
+	fi
+	;;
+      esac
+      ;;
+    esac
+  fi
+  rm -rf conftest*
+  ;;
+
 AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
 [*-*-cygwin* | *-*-mingw* | *-*-pw32*)
   AC_CHECK_TOOL(DLLTOOL, dlltool, false)
@@ -3512,7 +3597,7 @@ AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION],
 AC_CACHE_CHECK([$1], [$2],
   [$2=no
   ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
-   printf "$lt_simple_compile_test_code" > conftest.$ac_ext
+   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
    lt_compiler_flag="$3"
    # Insert the option either (1) after the last *FLAGS variable, or
    # (2) before a word containing "conftest.", or (3) at the end.
@@ -3531,9 +3616,9 @@ AC_CACHE_CHECK([$1], [$2],
    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.
-     $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
-     $SED '/^$/d' conftest.err >conftest.er2
-     if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
+     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
+     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
+     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
        $2=yes
      fi
    fi
@@ -3553,19 +3638,20 @@ fi
 # ------------------------------------------------------------
 # Check whether the given compiler option works
 AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
-[AC_CACHE_CHECK([$1], [$2],
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+AC_CACHE_CHECK([$1], [$2],
   [$2=no
    save_LDFLAGS="$LDFLAGS"
    LDFLAGS="$LDFLAGS $3"
-   printf "$lt_simple_link_test_code" > conftest.$ac_ext
+   echo "$lt_simple_link_test_code" > conftest.$ac_ext
    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
      # The linker can only warn and ignore the option if not recognized
      # So say no if there are warnings
      if test -s conftest.err; then
        # Append any errors to the config.log.
        cat conftest.err 1>&5
-       $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp
-       $SED '/^$/d' conftest.err >conftest.er2
+       $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
+       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
        if diff conftest.exp conftest.er2 >/dev/null; then
          $2=yes
        fi
@@ -3573,7 +3659,7 @@ AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
        $2=yes
      fi
    fi
-   $rm conftest*
+   $rm -r conftest*
    LDFLAGS="$save_LDFLAGS"
 ])
 
@@ -3634,44 +3720,64 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
     elif test -x /usr/sbin/sysctl; then
       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
     else
-      lt_cv_sys_max_cmd_len=65536     # usable default for all BSDs
+      lt_cv_sys_max_cmd_len=65536	# usable default for all BSDs
     fi
     # And add a safety zone
     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
     ;;
+
+  interix*)
+    # We know the value 262144 and hardcode it with a safety zone (like BSD)
+    lt_cv_sys_max_cmd_len=196608
+    ;;
+
   osf*)
     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
     # nice to cause kernel panics so lets avoid the loop below.
     # First set a reasonable default.
     lt_cv_sys_max_cmd_len=16384
-    # 
+    #
     if test -x /sbin/sysconfig; then
       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
         *1*) lt_cv_sys_max_cmd_len=-1 ;;
       esac
     fi
     ;;
+  sco3.2v5*)
+    lt_cv_sys_max_cmd_len=102400
+    ;;
+  sysv5* | sco5v6* | sysv4.2uw2*)
+    kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
+    if test -n "$kargmax"; then
+      lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ 	]]//'`
+    else
+      lt_cv_sys_max_cmd_len=32768
+    fi
+    ;;
   *)
-    # If test is not a shell built-in, we'll probably end up computing a
-    # maximum length that is only half of the actual maximum length, but
-    # we can't tell.
-    SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
-    while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
+    lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
+    if test -n "$lt_cv_sys_max_cmd_len"; then
+      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
+      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
+    else
+      SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
+      while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
 	       = "XX$teststring") >/dev/null 2>&1 &&
-	    new_result=`expr "X$teststring" : ".*" 2>&1` &&
-	    lt_cv_sys_max_cmd_len=$new_result &&
-	    test $i != 17 # 1/2 MB should be enough
-    do
-      i=`expr $i + 1`
-      teststring=$teststring$teststring
-    done
-    teststring=
-    # Add a significant safety factor because C++ compilers can tack on massive
-    # amounts of additional arguments before passing them to the linker.
-    # It appears as though 1/2 is a usable value.
-    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
+	      new_result=`expr "X$teststring" : ".*" 2>&1` &&
+	      lt_cv_sys_max_cmd_len=$new_result &&
+	      test $i != 17 # 1/2 MB should be enough
+      do
+        i=`expr $i + 1`
+        teststring=$teststring$teststring
+      done
+      teststring=
+      # Add a significant safety factor because C++ compilers can tack on massive
+      # amounts of additional arguments before passing them to the linker.
+      # It appears as though 1/2 is a usable value.
+      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
+    fi
     ;;
   esac
 ])
@@ -3684,7 +3790,7 @@ fi
 
 
 # _LT_AC_CHECK_DLFCN
-# --------------------
+# ------------------
 AC_DEFUN([_LT_AC_CHECK_DLFCN],
 [AC_CHECK_HEADERS(dlfcn.h)dnl
 ])# _LT_AC_CHECK_DLFCN
@@ -3692,7 +3798,7 @@ AC_DEFUN([_LT_AC_CHECK_DLFCN],
 
 # _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
 #                           ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
-# ------------------------------------------------------------------
+# ---------------------------------------------------------------------
 AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
 [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
 if test "$cross_compiling" = yes; then :
@@ -3758,6 +3864,8 @@ int main ()
       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
       /* dlclose (self); */
     }
+  else
+    puts (dlerror ());
 
     exit (status);
 }]
@@ -3768,7 +3876,7 @@ EOF
     case x$lt_status in
       x$lt_dlno_uscore) $1 ;;
       x$lt_dlneed_uscore) $2 ;;
-      x$lt_unknown|x*) $3 ;;
+      x$lt_dlunknown|x*) $3 ;;
     esac
   else :
     # compilation failed
@@ -3780,7 +3888,7 @@ rm -fr conftest*
 
 
 # AC_LIBTOOL_DLOPEN_SELF
-# -------------------
+# ----------------------
 AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
 [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
 if test "x$enable_dlopen" != xyes; then
@@ -3822,7 +3930,7 @@ else
     AC_CHECK_FUNC([shl_load],
 	  [lt_cv_dlopen="shl_load"],
       [AC_CHECK_LIB([dld], [shl_load],
-	    [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"],
+	    [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
 	[AC_CHECK_FUNC([dlopen],
 	      [lt_cv_dlopen="dlopen"],
 	  [AC_CHECK_LIB([dl], [dlopen],
@@ -3830,7 +3938,7 @@ else
 	    [AC_CHECK_LIB([svld], [dlopen],
 		  [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
 	      [AC_CHECK_LIB([dld], [dld_link],
-		    [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"])
+		    [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
 	      ])
 	    ])
 	  ])
@@ -3851,7 +3959,7 @@ else
     test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
 
     save_LDFLAGS="$LDFLAGS"
-    eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
+    wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
 
     save_LIBS="$LIBS"
     LIBS="$lt_cv_dlopen_libs $LIBS"
@@ -3864,7 +3972,7 @@ else
     ])
 
     if test "x$lt_cv_dlopen_self" = xyes; then
-      LDFLAGS="$LDFLAGS $link_static_flag"
+      wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
       AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
     	  lt_cv_dlopen_self_static, [dnl
 	  _LT_AC_TRY_DLOPEN_SELF(
@@ -3896,7 +4004,8 @@ fi
 # ---------------------------------
 # Check to see if options -c and -o are simultaneously supported by compiler
 AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O],
-[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
   [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
   [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
@@ -3904,7 +4013,7 @@ AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
    mkdir conftest
    cd conftest
    mkdir out
-   printf "$lt_simple_compile_test_code" > conftest.$ac_ext
+   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
    lt_compiler_flag="-o out/conftest2.$ac_objext"
    # Insert the option either (1) after the last *FLAGS variable, or
@@ -3924,9 +4033,9 @@ AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
    then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings
-     $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp
-     $SED '/^$/d' out/conftest.err >out/conftest.er2
-     if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then
+     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
+     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
+     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
        _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
      fi
    fi
@@ -4044,6 +4153,7 @@ else
    darwin*)
        if test -n "$STRIP" ; then
          striplib="$STRIP -x"
+         old_striplib="$STRIP -S"
          AC_MSG_RESULT([yes])
        else
   AC_MSG_RESULT([no])
@@ -4061,7 +4171,8 @@ fi
 # -----------------------------
 # PORTME Fill in your ld.so characteristics
 AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER],
-[AC_MSG_CHECKING([dynamic linker characteristics])
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+AC_MSG_CHECKING([dynamic linker characteristics])
 library_names_spec=
 libname_spec='lib$name'
 soname_spec=
@@ -4075,20 +4186,58 @@ shlibpath_overrides_runpath=unknown
 version_type=none
 dynamic_linker="$host_os ld.so"
 sys_lib_dlsearch_path_spec="/lib /usr/lib"
+ifelse($1,[],[
 if test "$GCC" = yes; then
-  sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
-  if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
+  case $host_os in
+    darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
+    *) lt_awk_arg="/^libraries:/" ;;
+  esac
+  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
+  if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then
     # if the path contains ";" then we assume it to be the separator
     # otherwise default to the standard path separator (i.e. ":") - it is
     # assumed that no part of a normal pathname contains ";" but that should
     # okay in the real world where ";" in dirpaths is itself problematic.
-    sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
+    lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'`
   else
-    sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
+    lt_search_path_spec=`echo "$lt_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
   fi
+  # Ok, now we have the path, separated by spaces, we can step through it
+  # and add multilib dir if necessary.
+  lt_tmp_lt_search_path_spec=
+  lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
+  for lt_sys_path in $lt_search_path_spec; do
+    if test -d "$lt_sys_path/$lt_multi_os_dir"; then
+      lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
+    else
+      test -d "$lt_sys_path" && \
+	lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
+    fi
+  done
+  lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk '
+BEGIN {RS=" "; FS="/|\n";} {
+  lt_foo="";
+  lt_count=0;
+  for (lt_i = NF; lt_i > 0; lt_i--) {
+    if ($lt_i != "" && $lt_i != ".") {
+      if ($lt_i == "..") {
+        lt_count++;
+      } else {
+        if (lt_count == 0) {
+          lt_foo="/" $lt_i lt_foo;
+        } else {
+          lt_count--;
+        }
+      }
+    }
+  }
+  if (lt_foo != "") { lt_freq[[lt_foo]]++; }
+  if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
+}'`
+  sys_lib_search_path_spec=`echo $lt_search_path_spec`
 else
   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
-fi
+fi])
 need_lib_prefix=unknown
 hardcode_into_libs=no
 
@@ -4106,7 +4255,7 @@ aix3*)
   soname_spec='${libname}${release}${shared_ext}$major'
   ;;
 
-aix4* | aix5*)
+aix[[4-9]]*)
   version_type=linux
   need_lib_prefix=no
   need_version=no
@@ -4245,12 +4394,8 @@ darwin* | rhapsody*)
   shlibpath_overrides_runpath=yes
   shlibpath_var=DYLD_LIBRARY_PATH
   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
-  # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
-  if test "$GCC" = yes; then
-    sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"`
-  else
-    sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
-  fi
+  ifelse([$1], [],[
+  sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) 
   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
   ;;
 
@@ -4267,18 +4412,6 @@ freebsd1*)
   dynamic_linker=no
   ;;
 
-kfreebsd*-gnu)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=no
-  hardcode_into_libs=yes
-  dynamic_linker='GNU ld.so'
-  ;;
-
 freebsd* | dragonfly*)
   # DragonFly does not have aout.  When/if they implement a new
   # versioning mechanism, adjust this.
@@ -4311,10 +4444,15 @@ freebsd* | dragonfly*)
     shlibpath_overrides_runpath=yes
     hardcode_into_libs=yes
     ;;
-  *) # from 3.2 on
+  freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
+  freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
     shlibpath_overrides_runpath=no
     hardcode_into_libs=yes
     ;;
+  *) # from 4.6 on, and DragonFly
+    shlibpath_overrides_runpath=yes
+    hardcode_into_libs=yes
+    ;;
   esac
   ;;
 
@@ -4374,6 +4512,18 @@ hpux9* | hpux10* | hpux11*)
   postinstall_cmds='chmod 555 $lib'
   ;;
 
+interix[[3-9]]*)
+  version_type=linux
+  need_lib_prefix=no
+  need_version=no
+  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
+  soname_spec='${libname}${release}${shared_ext}$major'
+  dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
+  shlibpath_var=LD_LIBRARY_PATH
+  shlibpath_overrides_runpath=no
+  hardcode_into_libs=yes
+  ;;
+
 irix5* | irix6* | nonstopux*)
   case $host_os in
     nonstopux*) version_type=nonstopux ;;
@@ -4417,7 +4567,7 @@ linux*oldld* | linux*aout* | linux*coff*)
   ;;
 
 # This must be Linux ELF.
-linux*)
+linux* | k*bsd*-gnu)
   version_type=linux
   need_lib_prefix=no
   need_version=no
@@ -4431,27 +4581,10 @@ linux*)
   # before this can be enabled.
   hardcode_into_libs=yes
 
-  # find out which ABI we are using
-  libsuff=
-  case $host_cpu in
-  x86_64*|s390x*|powerpc64*)
-    echo '[#]line __oline__ "configure"' > conftest.$ac_ext
-    if AC_TRY_EVAL(ac_compile); then
-      case `/usr/bin/file conftest.$ac_objext` in
-      *64-bit*)
-        libsuff=64
-        sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
-        ;;
-      esac
-    fi
-    rm -rf conftest*
-    ;;
-  esac
-
   # Append ld.so.conf contents to the search path
   if test -f /etc/ld.so.conf; then
-    lt_ld_extra=`$SED -e 's/[:,\t]/ /g;s/=[^=]*$//;s/=[^= ]* / /g' /etc/ld.so.conf | tr '\n' ' '`
-    sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
+    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ 	]*hwcap[ 	]/d;s/[:,	]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
+    sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
   fi
 
   # We used to test for /lib/ld.so.1 and disable shared libraries on
@@ -4463,18 +4596,6 @@ linux*)
   dynamic_linker='GNU/Linux ld.so'
   ;;
 
-knetbsd*-gnu)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=no
-  hardcode_into_libs=yes
-  dynamic_linker='GNU ld.so'
-  ;;
-
 netbsd*)
   version_type=sunos
   need_lib_prefix=no
@@ -4512,6 +4633,7 @@ nto-qnx*)
 
 openbsd*)
   version_type=sunos
+  sys_lib_dlsearch_path_spec="/usr/lib"
   need_lib_prefix=no
   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
   case $host_os in
@@ -4555,11 +4677,8 @@ osf3* | osf4* | osf5*)
   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
   ;;
 
-sco3.2v5*)
-  version_type=osf
-  soname_spec='${libname}${release}${shared_ext}$major'
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-  shlibpath_var=LD_LIBRARY_PATH
+rdos*)
+  dynamic_linker=no
   ;;
 
 solaris*)
@@ -4587,7 +4706,7 @@ sunos4*)
   need_version=yes
   ;;
 
-sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
+sysv4 | sysv4.3*)
   version_type=linux
   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
   soname_spec='${libname}${release}${shared_ext}$major'
@@ -4620,6 +4739,29 @@ sysv4*MP*)
   fi
   ;;
 
+sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
+  version_type=freebsd-elf
+  need_lib_prefix=no
+  need_version=no
+  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
+  soname_spec='${libname}${release}${shared_ext}$major'
+  shlibpath_var=LD_LIBRARY_PATH
+  hardcode_into_libs=yes
+  if test "$with_gnu_ld" = yes; then
+    sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
+    shlibpath_overrides_runpath=no
+  else
+    sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
+    shlibpath_overrides_runpath=yes
+    case $host_os in
+      sco3.2v5*)
+        sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
+	;;
+    esac
+  fi
+  sys_lib_dlsearch_path_spec='/usr/lib'
+  ;;
+
 uts4*)
   version_type=linux
   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
@@ -4633,13 +4775,26 @@ uts4*)
 esac
 AC_MSG_RESULT([$dynamic_linker])
 test "$dynamic_linker" = no && can_build_shared=no
+
+AC_CACHE_VAL([lt_cv_sys_lib_search_path_spec],
+[lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec"])
+sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
+AC_CACHE_VAL([lt_cv_sys_lib_dlsearch_path_spec],
+[lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec"])
+sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
+
+variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
+if test "$GCC" = yes; then
+  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
+fi
 ])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
 
 
 # _LT_AC_TAGCONFIG
 # ----------------
 AC_DEFUN([_LT_AC_TAGCONFIG],
-[AC_ARG_WITH([tags],
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+AC_ARG_WITH([tags],
 [  --with-tags[=TAGS]      include additional configurations [automatic]
 ],
 [tagnames="$withval"])
@@ -4657,6 +4812,9 @@ if test -f "$ltmain" && test -n "$tagnames"; then
       AC_MSG_WARN([using \`LTCC=$LTCC', extracted from \`$ofile'])
     fi
   fi
+  if test -z "$LTCFLAGS"; then
+    eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`"
+  fi
 
   # Extract list of available tagged configurations in $ofile.
   # Note that this assumes the entire list is on one line.
@@ -4692,26 +4850,6 @@ if test -f "$ltmain" && test -n "$tagnames"; then
 	fi
 	;;
 
-#      F77)
-#	if test -n "$F77" && test "X$F77" != "Xno"; then
-#	  AC_LIBTOOL_LANG_F77_CONFIG
-#	else
-#	  tagname=""
-#	fi
-#	;;
-#
-#      GCJ)
-#	if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
-#	  AC_LIBTOOL_LANG_GCJ_CONFIG
-#	else
-#	  tagname=""
-#	fi
-#	;;
-#
-#      RC)
-#	AC_LIBTOOL_LANG_RC_CONFIG
-#	;;
-
       *)
 	AC_MSG_ERROR([Unsupported tag name: $tagname])
 	;;
@@ -4786,7 +4924,7 @@ changequote([, ])dnl
 
 # AC_DISABLE_SHARED
 # -----------------
-#- set the default shared flag to --disable-shared
+# set the default shared flag to --disable-shared
 AC_DEFUN([AC_DISABLE_SHARED],
 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
 AC_ENABLE_SHARED(no)
@@ -4885,8 +5023,6 @@ pic_mode=ifelse($#,1,$1,default)
 
 # AC_PROG_EGREP
 # -------------
-# This is predefined starting with Autoconf 2.54, so this conditional
-# definition can be removed once we require Autoconf 2.54 or later.
 ifdef([AC_PROG_EGREP], [], [AC_DEFUN([AC_PROG_EGREP],
 [AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
    [if echo a | (grep -E '(a|b)') >/dev/null 2>&1
@@ -4900,7 +5036,7 @@ ifdef([AC_PROG_EGREP], [], [AC_DEFUN([AC_PROG_EGREP],
 
 # AC_PATH_TOOL_PREFIX
 # -------------------
-# find a file program which can recognise shared library
+# find a file program which can recognize shared library
 AC_DEFUN([AC_PATH_TOOL_PREFIX],
 [AC_REQUIRE([AC_PROG_EGREP])dnl
 AC_MSG_CHECKING([for $1])
@@ -4963,7 +5099,7 @@ fi
 
 # AC_PATH_MAGIC
 # -------------
-# find a file program which can recognise a shared library
+# find a file program which can recognize a shared library
 AC_DEFUN([AC_PATH_MAGIC],
 [AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
 if test -z "$lt_cv_path_MAGIC_CMD"; then
@@ -5095,7 +5231,7 @@ reload_cmds='$LD$reload_flag -o $output$reload_objs'
 case $host_os in
   darwin*)
     if test "$GCC" = yes; then
-      reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs'
+      reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
     else
       reload_cmds='$LD$reload_flag -o $output$reload_objs'
     fi
@@ -5109,7 +5245,7 @@ esac
 # how to check for library dependencies
 #  -- PORTME fill in with the dynamic library characteristics
 AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
-[AC_CACHE_CHECK([how to recognise dependent libraries],
+[AC_CACHE_CHECK([how to recognize dependent libraries],
 lt_cv_deplibs_check_method,
 [lt_cv_file_magic_cmd='$MAGIC_CMD'
 lt_cv_file_magic_test_file=
@@ -5126,7 +5262,7 @@ lt_cv_deplibs_check_method='unknown'
 # whether `pass_all' will *always* work, you probably want this one.
 
 case $host_os in
-aix4* | aix5*)
+aix[[4-9]]*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
@@ -5148,16 +5284,22 @@ cygwin*)
 
 mingw* | pw32*)
   # Base MSYS/MinGW do not provide the 'file' command needed by
-  # func_win32_libid shell function, so use a weaker test based on 'objdump'.
-  lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
-  lt_cv_file_magic_cmd='$OBJDUMP -f'
+  # func_win32_libid shell function, so use a weaker test based on 'objdump',
+  # unless we find 'file', for example because we are cross-compiling.
+  if ( file / ) >/dev/null 2>&1; then
+    lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
+    lt_cv_file_magic_cmd='func_win32_libid'
+  else
+    lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
+    lt_cv_file_magic_cmd='$OBJDUMP -f'
+  fi
   ;;
 
 darwin* | rhapsody*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
-freebsd* | kfreebsd*-gnu | dragonfly*)
+freebsd* | dragonfly*)
   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
     case $host_cpu in
     i*86 )
@@ -5195,6 +5337,11 @@ hpux10.20* | hpux11*)
   esac
   ;;
 
+interix[[3-9]]*)
+  # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
+  lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
+  ;;
+
 irix5* | irix6* | nonstopux*)
   case $LD in
   *-32|*"-32 ") libmagic=32-bit;;
@@ -5206,7 +5353,7 @@ irix5* | irix6* | nonstopux*)
   ;;
 
 # This must be Linux ELF.
-linux*)
+linux* | k*bsd*-gnu)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
@@ -5240,7 +5387,7 @@ osf3* | osf4* | osf5*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
-sco3.2v5*)
+rdos*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
@@ -5248,7 +5395,7 @@ solaris*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
-sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
+sysv4 | sysv4.3*)
   case $host_vendor in
   motorola)
     lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]'
@@ -5269,10 +5416,13 @@ sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
   siemens)
     lt_cv_deplibs_check_method=pass_all
     ;;
+  pc)
+    lt_cv_deplibs_check_method=pass_all
+    ;;
   esac
   ;;
 
-sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7* | sysv4*uw2*)
+sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 esac
@@ -5292,36 +5442,43 @@ AC_DEFUN([AC_PROG_NM],
   # Let the user override the test.
   lt_cv_path_NM="$NM"
 else
-  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
-  for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
-    IFS="$lt_save_ifs"
-    test -z "$ac_dir" && ac_dir=.
-    tmp_nm="$ac_dir/${ac_tool_prefix}nm"
-    if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
-      # Check to see if the nm accepts a BSD-compat flag.
-      # Adding the `sed 1q' prevents false positives on HP-UX, which says:
-      #   nm: unknown option "B" ignored
-      # Tru64's nm complains that /dev/null is an invalid object file
-      case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
-      */dev/null* | *'Invalid file or object type'*)
-	lt_cv_path_NM="$tmp_nm -B"
-	break
-        ;;
-      *)
-	case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
-	*/dev/null*)
-	  lt_cv_path_NM="$tmp_nm -p"
+  lt_nm_to_check="${ac_tool_prefix}nm"
+  if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
+    lt_nm_to_check="$lt_nm_to_check nm"
+  fi
+  for lt_tmp_nm in $lt_nm_to_check; do
+    lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
+    for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
+      IFS="$lt_save_ifs"
+      test -z "$ac_dir" && ac_dir=.
+      tmp_nm="$ac_dir/$lt_tmp_nm"
+      if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
+	# Check to see if the nm accepts a BSD-compat flag.
+	# Adding the `sed 1q' prevents false positives on HP-UX, which says:
+	#   nm: unknown option "B" ignored
+	# Tru64's nm complains that /dev/null is an invalid object file
+	case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
+	*/dev/null* | *'Invalid file or object type'*)
+	  lt_cv_path_NM="$tmp_nm -B"
 	  break
 	  ;;
 	*)
-	  lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
-	  continue # so that we can try to find one that supports BSD flags
+	  case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
+	  */dev/null*)
+	    lt_cv_path_NM="$tmp_nm -p"
+	    break
+	    ;;
+	  *)
+	    lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
+	    continue # so that we can try to find one that supports BSD flags
+	    ;;
+	  esac
 	  ;;
 	esac
-      esac
-    fi
+      fi
+    done
+    IFS="$lt_save_ifs"
   done
-  IFS="$lt_save_ifs"
   test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
 fi])
 NM="$lt_cv_path_NM"
@@ -5427,7 +5584,7 @@ _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX])
 ])# _LT_AC_LANG_CXX
 
 # _LT_AC_PROG_CXXCPP
-# ---------------
+# ------------------
 AC_DEFUN([_LT_AC_PROG_CXXCPP],
 [
 AC_REQUIRE([AC_PROG_CXX])
@@ -5438,52 +5595,6 @@ if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
 fi
 ])# _LT_AC_PROG_CXXCPP
 
-# AC_LIBTOOL_F77
-# --------------
-# enable support for Fortran 77 libraries
-#AC_DEFUN([AC_LIBTOOL_F77],
-#[AC_REQUIRE([_LT_AC_LANG_F77])
-#])# AC_LIBTOOL_F77
-
-
-# _LT_AC_LANG_F77
-# ---------------
-#AC_DEFUN([_LT_AC_LANG_F77],
-#[AC_REQUIRE([AC_PROG_F77])
-#_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77])
-#])# _LT_AC_LANG_F77
-
-
-# AC_LIBTOOL_GCJ
-# --------------
-# enable support for GCJ libraries
-#AC_DEFUN([AC_LIBTOOL_GCJ],
-#[AC_REQUIRE([_LT_AC_LANG_GCJ])
-#])# AC_LIBTOOL_GCJ
-
-
-# _LT_AC_LANG_GCJ
-# ---------------
-#AC_DEFUN([_LT_AC_LANG_GCJ],
-#[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
-#  [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
-#    [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
-#      [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
-#	 [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
-#	   [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
-#_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ])
-#])# _LT_AC_LANG_GCJ
-
-
-# AC_LIBTOOL_RC
-# --------------
-# enable support for Windows resource files
-#AC_DEFUN([AC_LIBTOOL_RC],
-#[AC_REQUIRE([LT_AC_PROG_RC])
-#_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC])
-#])# AC_LIBTOOL_RC
-
-
 # AC_LIBTOOL_LANG_C_CONFIG
 # ------------------------
 # Ensure that the configuration vars for the C compiler are
@@ -5503,10 +5614,10 @@ objext=o
 _LT_AC_TAGVAR(objext, $1)=$objext
 
 # Code to be used in simple compile tests
-lt_simple_compile_test_code="int some_variable = 0;\n"
+lt_simple_compile_test_code="int some_variable = 0;"
 
 # Code to be used in simple link tests
-lt_simple_link_test_code='int main(){return(0);}\n'
+lt_simple_link_test_code='int main(){return(0);}'
 
 _LT_AC_SYS_COMPILER
 
@@ -5514,37 +5625,6 @@ _LT_AC_SYS_COMPILER
 _LT_COMPILER_BOILERPLATE
 _LT_LINKER_BOILERPLATE
 
-#
-# Check for any special shared library compilation flags.
-#
-_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)=
-if test "$GCC" = no; then
-  case $host_os in
-  sco3.2v5*)
-    _LT_AC_TAGVAR(lt_prog_cc_shlib, $1)='-belf'
-    ;;
-  esac
-fi
-if test -n "$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)"; then
-  AC_MSG_WARN([\`$CC' requires \`$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to build shared libraries])
-  if echo "$old_CC $old_CFLAGS " | grep "[[ 	]]$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[ 	]]" >/dev/null; then :
-  else
-    AC_MSG_WARN([add \`$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to the CC or CFLAGS env variable and reconfigure])
-    _LT_AC_TAGVAR(lt_cv_prog_cc_can_build_shared, $1)=no
-  fi
-fi
-
-
-#
-# Check to make sure the static flag actually works.
-#
-AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $_LT_AC_TAGVAR(lt_prog_compiler_static, $1) works],
-  _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1),
-  $_LT_AC_TAGVAR(lt_prog_compiler_static, $1),
-  [],
-  [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
-
-
 ## CAVEAT EMPTOR:
 ## There is no encapsulation within the following macros, do not change
 ## the running order or otherwise move them around unless you know exactly
@@ -5557,9 +5637,9 @@ AC_LIBTOOL_PROG_LD_SHLIBS($1)
 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
 AC_LIBTOOL_SYS_LIB_STRIP
-AC_LIBTOOL_DLOPEN_SELF($1)
+AC_LIBTOOL_DLOPEN_SELF
 
-# Report which librarie types wil actually be built
+# Report which library types will actually be built
 AC_MSG_CHECKING([if libtool supports shared libraries])
 AC_MSG_RESULT([$can_build_shared])
 
@@ -5577,7 +5657,7 @@ aix3*)
   fi
   ;;
 
-aix4* | aix5*)
+aix[[4-9]]*)
   if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
     test "$enable_shared" = yes && enable_static=no
   fi
@@ -5619,6 +5699,7 @@ _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
+_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
 _LT_AC_TAGVAR(module_cmds, $1)=
 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
@@ -5634,6 +5715,7 @@ _LT_AC_TAGVAR(postdep_objects, $1)=
 _LT_AC_TAGVAR(predeps, $1)=
 _LT_AC_TAGVAR(postdeps, $1)=
 _LT_AC_TAGVAR(compiler_lib_search_path, $1)=
+_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=
 
 # Source file extension for C++ test sources.
 ac_ext=cpp
@@ -5643,10 +5725,10 @@ objext=o
 _LT_AC_TAGVAR(objext, $1)=$objext
 
 # Code to be used in simple compile tests
-lt_simple_compile_test_code="int some_variable = 0;\n"
+lt_simple_compile_test_code="int some_variable = 0;"
 
 # Code to be used in simple link tests
-lt_simple_link_test_code='int main(int, char *[]) { return(0); }\n'
+lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
 
 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
 _LT_AC_SYS_COMPILER
@@ -5743,7 +5825,7 @@ case $host_os in
     # FIXME: insert proper C++ library support
     _LT_AC_TAGVAR(ld_shlibs, $1)=no
     ;;
-  aix4* | aix5*)
+  aix[[4-9]]*)
     if test "$host_cpu" = ia64; then
       # On IA64, the linker does run time linking by default, so we don't
       # have to do anything special.
@@ -5756,7 +5838,7 @@ case $host_os in
       # Test if we are trying to use run time linking or normal
       # AIX style linking. If -brtl is somewhere in LDFLAGS, we
       # need to do runtime linking.
-      case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
+      case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
 	for ld_flag in $LDFLAGS; do
 	  case $ld_flag in
 	  *-brtl*)
@@ -5765,6 +5847,7 @@ case $host_os in
 	    ;;
 	  esac
 	done
+	;;
       esac
 
       exp_sym_flag='-bexport'
@@ -5791,7 +5874,7 @@ case $host_os in
 	   strings "$collect2name" | grep resolve_lib_name >/dev/null
 	then
 	  # We have reworked collect2
-	  _LT_AC_TAGVAR(hardcode_direct, $1)=yes
+	  :
 	else
 	  # We have old collect2
 	  _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
@@ -5802,6 +5885,7 @@ case $host_os in
 	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
 	  _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
 	fi
+	;;
       esac
       shared_flag='-shared'
       if test "$aix_use_runtimelinking" = yes; then
@@ -5833,12 +5917,12 @@ case $host_os in
       _LT_AC_SYS_LIBPATH_AIX
       _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
 
-      _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
+      _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
      else
       if test "$host_cpu" = ia64; then
 	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
 	_LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
-	_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
       else
 	# Determine the default libpath from the value encoded in an empty executable.
 	_LT_AC_SYS_LIBPATH_AIX
@@ -5847,16 +5931,26 @@ case $host_os in
 	# -berok will link without error, but may produce a broken library.
 	_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
 	_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
-	# -bexpall does not export symbols beginning with underscore (_)
-	_LT_AC_TAGVAR(always_export_symbols, $1)=yes
 	# Exported symbols can be pulled into shared objects from archives
-	_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
+	_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
 	_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
 	# This is similar to how AIX traditionally builds its shared libraries.
-	_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
       fi
     fi
     ;;
+
+  beos*)
+    if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
+      _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
+      # Joseph Beckenbach <jrb3 at best.com> says some releases of gcc
+      # support --undefined.  This deserves some investigation.  FIXME
+      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+    else
+      _LT_AC_TAGVAR(ld_shlibs, $1)=no
+    fi
+    ;;
+
   chorus*)
     case $cc_basename in
       *)
@@ -5866,7 +5960,6 @@ case $host_os in
     esac
     ;;
 
-
   cygwin* | mingw* | pw32*)
     # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
     # as there is no search path for DLLs.
@@ -5876,7 +5969,7 @@ case $host_os in
     _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
 
     if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
-      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
+      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
       # If the export-symbols file already is a .def file (1st line
       # is EXPORTS), use it as is; otherwise, prepend...
       _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
@@ -5885,65 +5978,37 @@ case $host_os in
 	echo EXPORTS > $output_objdir/$soname.def;
 	cat $export_symbols >> $output_objdir/$soname.def;
       fi~
-      $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
+      $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
     else
       _LT_AC_TAGVAR(ld_shlibs, $1)=no
     fi
   ;;
       darwin* | rhapsody*)
-        case $host_os in
-        rhapsody* | darwin1.[[012]])
-         _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
-         ;;
-       *) # Darwin 1.3 on
-         if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
-           _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
-         else
-           case ${MACOSX_DEPLOYMENT_TARGET} in
-             10.[[012]])
-               _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
-               ;;
-             10.*)
-               _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
-               ;;
-           esac
-         fi
-         ;;
-        esac
       _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
       _LT_AC_TAGVAR(hardcode_direct, $1)=no
       _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
       _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
       _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
       _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
-
-    if test "$GXX" = yes ; then
-      lt_int_apple_cc_single_mod=no
+      _LT_AC_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
+      if test "$GXX" = yes ; then
       output_verbose_link_cmd='echo'
-      if $CC -dumpspecs 2>&1 | $EGREP 'single_module' >/dev/null ; then
-       lt_int_apple_cc_single_mod=yes
+      _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
+      _LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
+      _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
+      _LT_AC_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
+      if test "$lt_cv_apple_cc_single_mod" != "yes"; then
+        _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
+        _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
       fi
-      if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
-       _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
-      else
-          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
-        fi
-        _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
-        # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
-          if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
-            _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
-          else
-            _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
-          fi
-            _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
       else
       case $cc_basename in
         xlc*)
          output_verbose_link_cmd='echo'
-          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
+          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
           _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
           # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
-          _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
+          _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
           _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
           ;;
        *)
@@ -5977,7 +6042,7 @@ case $host_os in
   freebsd-elf*)
     _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
     ;;
-  freebsd* | kfreebsd*-gnu | dragonfly*)
+  freebsd* | dragonfly*)
     # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
     # conventions
     _LT_AC_TAGVAR(ld_shlibs, $1)=yes
@@ -6022,34 +6087,21 @@ case $host_os in
     ;;
   hpux10*|hpux11*)
     if test $with_gnu_ld = no; then
+      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
+      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
+
       case $host_cpu in
-      hppa*64*)
-	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
-	_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
-	_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
-        ;;
-      ia64*)
-	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-        ;;
+      hppa*64*|ia64*) ;;
       *)
-	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
-	_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 	_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
         ;;
       esac
     fi
     case $host_cpu in
-    hppa*64*)
+    hppa*64*|ia64*)
       _LT_AC_TAGVAR(hardcode_direct, $1)=no
       _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
       ;;
-    ia64*)
-      _LT_AC_TAGVAR(hardcode_direct, $1)=no
-      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
-					      # but as the default
-					      # location of the library.
-      ;;
     *)
       _LT_AC_TAGVAR(hardcode_direct, $1)=yes
       _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
@@ -6065,8 +6117,11 @@ case $host_os in
 	;;
       aCC*)
 	case $host_cpu in
-	hppa*64*|ia64*)
-	  _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
+	hppa*64*)
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+	  ;;
+	ia64*)
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 	  ;;
 	*)
 	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
@@ -6086,8 +6141,11 @@ case $host_os in
 	if test "$GXX" = yes; then
 	  if test $with_gnu_ld = no; then
 	    case $host_cpu in
-	    ia64*|hppa*64*)
-	      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
+	    hppa*64*)
+	      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+	      ;;
+	    ia64*)
+	      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 	      ;;
 	    *)
 	      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
@@ -6101,6 +6159,20 @@ case $host_os in
 	;;
     esac
     ;;
+  interix[[3-9]]*)
+    _LT_AC_TAGVAR(hardcode_direct, $1)=no
+    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
+    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
+    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
+    # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
+    # Instead, shared libraries are loaded at an image base (0x10000000 by
+    # default) and relocated if they conflict, which is a slow very memory
+    # consuming and fragmenting process.  To avoid this, we pick a random,
+    # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
+    # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
+    _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
+    _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
+    ;;
   irix5* | irix6*)
     case $cc_basename in
       CC*)
@@ -6127,7 +6199,7 @@ case $host_os in
     _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
     _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
     ;;
-  linux*)
+  linux* | k*bsd*-gnu)
     case $cc_basename in
       KCC*)
 	# Kuck and Associates, Inc. (KAI) C++ Compiler
@@ -6179,7 +6251,7 @@ case $host_os in
 	_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
 	_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
 	;;
-      pgCC*)
+      pgCC* | pgcpp*)
         # Portland Group C++ compiler
 	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
   	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
@@ -6207,6 +6279,29 @@ case $host_os in
 	# dependencies.
 	output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
 	;;
+      *)
+	case `$CC -V 2>&1 | sed 5q` in
+	*Sun\ C*)
+	  # Sun C++ 5.9
+	  _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+	  _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
+	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
+	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
+
+	  # Not sure whether something based on
+	  # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
+	  # would be better.
+	  output_verbose_link_cmd='echo'
+
+	  # Archives containing C++ object files must be created using
+	  # "CC -xar", where "CC" is the Sun C++ compiler.  This is
+	  # necessary to make sure instantiated templates are included
+	  # in the archive.
+	  _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
+	  ;;
+	esac
+	;;
     esac
     ;;
   lynxos*)
@@ -6245,16 +6340,20 @@ case $host_os in
     _LT_AC_TAGVAR(ld_shlibs, $1)=no
     ;;
   openbsd*)
-    _LT_AC_TAGVAR(hardcode_direct, $1)=yes
-    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-    _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
-    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
-    if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
-      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
-      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
-      _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
+    if test -f /usr/libexec/ld.so; then
+      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
+      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
+      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
+      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
+      if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
+	_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
+	_LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
+      fi
+      output_verbose_link_cmd='echo'
+    else
+      _LT_AC_TAGVAR(ld_shlibs, $1)=no
     fi
-    output_verbose_link_cmd='echo'
     ;;
   osf3*)
     case $cc_basename in
@@ -6383,19 +6482,6 @@ case $host_os in
     # FIXME: insert proper C++ library support
     _LT_AC_TAGVAR(ld_shlibs, $1)=no
     ;;
-  sco*)
-    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
-    case $cc_basename in
-      CC*)
-	# FIXME: insert proper C++ library support
-	_LT_AC_TAGVAR(ld_shlibs, $1)=no
-	;;
-      *)
-	# FIXME: insert proper C++ library support
-	_LT_AC_TAGVAR(ld_shlibs, $1)=no
-	;;
-    esac
-    ;;
   sunos4*)
     case $cc_basename in
       CC*)
@@ -6418,26 +6504,21 @@ case $host_os in
     case $cc_basename in
       CC*)
 	# Sun C++ 4.2, 5.x and Centerline C++
-     _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes
+        _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes
 	_LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
-	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag}  -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
-	$CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
+	$CC -G${allow_undefined_flag}  ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
 
 	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
 	_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 	case $host_os in
 	  solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
 	  *)
-	    # The C++ compiler is used as linker so we must use $wl
-	    # flag to pass the commands to the underlying system
-	    # linker. We must also pass each convience library through
-	    # to the system linker between allextract/defaultextract.
-	    # The C++ compiler will combine linker options so we
-	    # cannot just pass the convience library names through
-	    # without $wl.
+	    # The compiler driver will combine and reorder linker options,
+	    # but understands `-z linker_flag'.
 	    # Supported since Solaris 2.6 (maybe 2.5.1?)
-	    _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract'
+	    _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
 	    ;;
 	esac
 	_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
@@ -6484,12 +6565,69 @@ case $host_os in
 	  fi
 
 	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
+	  case $host_os in
+	  solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
+	  *)
+	    _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
+	    ;;
+	  esac
 	fi
 	;;
     esac
     ;;
-  sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*)
+  sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
+    _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
     _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
+    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
+    runpath_var='LD_RUN_PATH'
+
+    case $cc_basename in
+      CC*)
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	;;
+      *)
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	;;
+    esac
+    ;;
+  sysv5* | sco3.2v5* | sco5v6*)
+    # Note: We can NOT use -z defs as we might desire, because we do not
+    # link with -lc, and that would cause any symbols used from libc to
+    # always be unresolved, which means just about no library would
+    # ever link correctly.  If we're not using GNU ld we use -z text
+    # though, which does catch some bad symbols but isn't as heavy-handed
+    # as -z defs.
+    # For security reasons, it is highly recommended that you always
+    # use absolute paths for naming shared libraries, and exclude the
+    # DT_RUNPATH tag from executables and libraries.  But doing so
+    # requires that you compile everything twice, which is a pain.
+    # So that behaviour is only enabled if SCOABSPATH is set to a
+    # non-empty value in the environment.  Most likely only useful for
+    # creating official distributions of packages.
+    # This is a hack until libtool officially supports absolute path
+    # names for shared libraries.
+    _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
+    _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
+    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
+    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
+    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
+    _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
+    _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
+    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
+    runpath_var='LD_RUN_PATH'
+
+    case $cc_basename in
+      CC*)
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	;;
+      *)
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	;;
+    esac
     ;;
   tandem*)
     case $cc_basename in
@@ -6530,8 +6668,6 @@ AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
 AC_LIBTOOL_PROG_LD_SHLIBS($1)
 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
-AC_LIBTOOL_SYS_LIB_STRIP
-AC_LIBTOOL_DLOPEN_SELF($1)
 
 AC_LIBTOOL_CONFIG($1)
 
@@ -6549,12 +6685,13 @@ lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
 ])# AC_LIBTOOL_LANG_CXX_CONFIG
 
 # AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
-# ------------------------
+# ------------------------------------
 # Figure out "hidden" library dependencies from verbose
 # compiler output when linking a shared library.
 # Parse the compiler output and extract the necessary
 # objects, libraries and library flags.
-AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[
+AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
 dnl we can't use the lt_simple_compile_test_code here,
 dnl because it contains code intended for an executable,
 dnl not a library.  It's possible we should let each
@@ -6679,239 +6816,72 @@ fi
 
 $rm -f confest.$objext
 
+_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=
+if test -n "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
+  _LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_AC_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
+fi
+
 # PORTME: override above test on systems where it is broken
 ifelse([$1],[CXX],
 [case $host_os in
+interix[[3-9]]*)
+  # Interix 3.5 installs completely hosed .la files for C++, so rather than
+  # hack all around it, let's just trust "g++" to DTRT.
+  _LT_AC_TAGVAR(predep_objects,$1)=
+  _LT_AC_TAGVAR(postdep_objects,$1)=
+  _LT_AC_TAGVAR(postdeps,$1)=
+  ;;
+
+linux*)
+  case `$CC -V 2>&1 | sed 5q` in
+  *Sun\ C*)
+    # Sun C++ 5.9
+    #
+    # The more standards-conforming stlport4 library is
+    # incompatible with the Cstd library. Avoid specifying
+    # it if it's in CXXFLAGS. Ignore libCrun as
+    # -library=stlport4 depends on it.
+    case " $CXX $CXXFLAGS " in
+    *" -library=stlport4 "*)
+      solaris_use_stlport4=yes
+      ;;
+    esac
+    if test "$solaris_use_stlport4" != yes; then
+      _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
+    fi
+    ;;
+  esac
+  ;;
+
 solaris*)
   case $cc_basename in
   CC*)
+    # The more standards-conforming stlport4 library is
+    # incompatible with the Cstd library. Avoid specifying
+    # it if it's in CXXFLAGS. Ignore libCrun as
+    # -library=stlport4 depends on it.
+    case " $CXX $CXXFLAGS " in
+    *" -library=stlport4 "*)
+      solaris_use_stlport4=yes
+      ;;
+    esac
+
     # Adding this requires a known-good setup of shared libraries for
     # Sun compiler versions before 5.6, else PIC objects from an old
     # archive will be linked into the output, leading to subtle bugs.
-    _LT_AC_TAGVAR(postdeps,$1)='-lCstd -lCrun'
+    if test "$solaris_use_stlport4" != yes; then
+      _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
+    fi
     ;;
   esac
+  ;;
 esac
 ])
-
 case " $_LT_AC_TAGVAR(postdeps, $1) " in
 *" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;;
 esac
 ])# AC_LIBTOOL_POSTDEP_PREDEP
 
-# AC_LIBTOOL_LANG_F77_CONFIG
-# ------------------------
-# Ensure that the configuration vars for the C compiler are
-# suitably defined.  Those variables are subsequently used by
-# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
-#AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)])
-#AC_DEFUN([_LT_AC_LANG_F77_CONFIG],
-#[AC_REQUIRE([AC_PROG_F77])
-#AC_LANG_SAVE
-#AC_LANG_FORTRAN77
-#
-#_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
-#_LT_AC_TAGVAR(allow_undefined_flag, $1)=
-#_LT_AC_TAGVAR(always_export_symbols, $1)=no
-#_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
-#_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
-#_LT_AC_TAGVAR(hardcode_direct, $1)=no
-#_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
-#_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
-#_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
-#_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
-#_LT_AC_TAGVAR(hardcode_automatic, $1)=no
-#_LT_AC_TAGVAR(module_cmds, $1)=
-#_LT_AC_TAGVAR(module_expsym_cmds, $1)=
-#_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
-#_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
-#_LT_AC_TAGVAR(no_undefined_flag, $1)=
-#_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
-#_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
-#
-## Source file extension for f77 test sources.
-#ac_ext=f
-#
-## Object file extension for compiled f77 test sources.
-#objext=o
-#_LT_AC_TAGVAR(objext, $1)=$objext
-#
-## Code to be used in simple compile tests
-#lt_simple_compile_test_code="      subroutine t\n      return\n      end\n"
-#
-## Code to be used in simple link tests
-#lt_simple_link_test_code="      program t\n      end\n"
-#
-## ltmain only uses $CC for tagged configurations so make sure $CC is set.
-#_LT_AC_SYS_COMPILER
-#
-## save warnings/boilerplate of simple test code
-#_LT_COMPILER_BOILERPLATE
-#_LT_LINKER_BOILERPLATE
-#
-## Allow CC to be a program name with arguments.
-#lt_save_CC="$CC"
-#CC=${F77-"f77"}
-#compiler=$CC
-#_LT_AC_TAGVAR(compiler, $1)=$CC
-#_LT_CC_BASENAME([$compiler])
-#
-#AC_MSG_CHECKING([if libtool supports shared libraries])
-#AC_MSG_RESULT([$can_build_shared])
-#
-#AC_MSG_CHECKING([whether to build shared libraries])
-#test "$can_build_shared" = "no" && enable_shared=no
-#
-## On AIX, shared libraries and static libraries use the same namespace, and
-## are all built from PIC.
-#case "$host_os" in
-#aix3*)
-#  test "$enable_shared" = yes && enable_static=no
-#  if test -n "$RANLIB"; then
-#    archive_cmds="$archive_cmds~\$RANLIB \$lib"
-#    postinstall_cmds='$RANLIB $lib'
-#  fi
-#  ;;
-#aix4* | aix5*)
-#  if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
-#    test "$enable_shared" = yes && enable_static=no
-#  fi
-#  ;;
-#esac
-#AC_MSG_RESULT([$enable_shared])
-#
-#AC_MSG_CHECKING([whether to build static libraries])
-## Make sure either enable_shared or enable_static is yes.
-#test "$enable_shared" = yes || enable_static=yes
-#AC_MSG_RESULT([$enable_static])
-#
-#test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
-#
-#_LT_AC_TAGVAR(GCC, $1)="$G77"
-#_LT_AC_TAGVAR(LD, $1)="$LD"
-#
-#AC_LIBTOOL_PROG_COMPILER_PIC($1)
-#AC_LIBTOOL_PROG_CC_C_O($1)
-#AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
-#AC_LIBTOOL_PROG_LD_SHLIBS($1)
-#AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
-#AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
-#AC_LIBTOOL_SYS_LIB_STRIP
-#
-#
-#AC_LIBTOOL_CONFIG($1)
-#
-#AC_LANG_RESTORE
-#CC="$lt_save_CC"
-#])# AC_LIBTOOL_LANG_F77_CONFIG
-
-
-# AC_LIBTOOL_LANG_GCJ_CONFIG
-# --------------------------
-# Ensure that the configuration vars for the C compiler are
-# suitably defined.  Those variables are subsequently used by
-# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
-#AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
-#AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
-#[AC_LANG_SAVE
-#
-## Source file extension for Java test sources.
-#ac_ext=java
-#
-## Object file extension for compiled Java test sources.
-#objext=o
-#_LT_AC_TAGVAR(objext, $1)=$objext
-#
-## Code to be used in simple compile tests
-#lt_simple_compile_test_code="class foo {}\n"
-#
-## Code to be used in simple link tests
-#lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }\n'
-#
-## ltmain only uses $CC for tagged configurations so make sure $CC is set.
-#_LT_AC_SYS_COMPILER
-#
-## save warnings/boilerplate of simple test code
-#_LT_COMPILER_BOILERPLATE
-#_LT_LINKER_BOILERPLATE
-#
-## Allow CC to be a program name with arguments.
-#lt_save_CC="$CC"
-#CC=${GCJ-"gcj"}
-#compiler=$CC
-#_LT_AC_TAGVAR(compiler, $1)=$CC
-#_LT_CC_BASENAME([$compiler])
-#
-## GCJ did not exist at the time GCC didn't implicitly link libc in.
-#_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
-#
-#_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
-#
-### CAVEAT EMPTOR:
-### There is no encapsulation within the following macros, do not change
-### the running order or otherwise move them around unless you know exactly
-### what you are doing...
-#AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
-#AC_LIBTOOL_PROG_COMPILER_PIC($1)
-#AC_LIBTOOL_PROG_CC_C_O($1)
-#AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
-#AC_LIBTOOL_PROG_LD_SHLIBS($1)
-#AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
-#AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
-#AC_LIBTOOL_SYS_LIB_STRIP
-#AC_LIBTOOL_DLOPEN_SELF($1)
-#
-#AC_LIBTOOL_CONFIG($1)
-#
-#AC_LANG_RESTORE
-#CC="$lt_save_CC"
-#])# AC_LIBTOOL_LANG_GCJ_CONFIG
-
-
-# AC_LIBTOOL_LANG_RC_CONFIG
-# --------------------------
-# Ensure that the configuration vars for the Windows resource compiler are
-# suitably defined.  Those variables are subsequently used by
-# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
-#AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
-#AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
-#[AC_LANG_SAVE
-#
-## Source file extension for RC test sources.
-#ac_ext=rc
-#
-## Object file extension for compiled RC test sources.
-#objext=o
-#_LT_AC_TAGVAR(objext, $1)=$objext
-#
-## Code to be used in simple compile tests
-#lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
-#
-## Code to be used in simple link tests
-#lt_simple_link_test_code="$lt_simple_compile_test_code"
-#
-## ltmain only uses $CC for tagged configurations so make sure $CC is set.
-#_LT_AC_SYS_COMPILER
-#
-## save warnings/boilerplate of simple test code
-#_LT_COMPILER_BOILERPLATE
-#_LT_LINKER_BOILERPLATE
-#
-## Allow CC to be a program name with arguments.
-#lt_save_CC="$CC"
-#CC=${RC-"windres"}
-#compiler=$CC
-#_LT_AC_TAGVAR(compiler, $1)=$CC
-#_LT_CC_BASENAME([$compiler])
-#_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
-#
-#AC_LIBTOOL_CONFIG($1)
-#
-#AC_LANG_RESTORE
-#CC="$lt_save_CC"
-#])# AC_LIBTOOL_LANG_RC_CONFIG
-
-
 # AC_LIBTOOL_CONFIG([TAGNAME])
 # ----------------------------
 # If TAGNAME is not passed, then create an initial libtool script
@@ -6932,7 +6902,7 @@ if test -f "$ltmain"; then
   # Now quote all the things that may contain metacharacters while being
   # careful not to overquote the AC_SUBSTed values.  We take copies of the
   # variables and quote the copies for generation of the libtool script.
-  for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
+  for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
     SED SHELL STRIP \
     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
@@ -6959,6 +6929,7 @@ if test -f "$ltmain"; then
     _LT_AC_TAGVAR(predeps, $1) \
     _LT_AC_TAGVAR(postdeps, $1) \
     _LT_AC_TAGVAR(compiler_lib_search_path, $1) \
+    _LT_AC_TAGVAR(compiler_lib_search_dirs, $1) \
     _LT_AC_TAGVAR(archive_cmds, $1) \
     _LT_AC_TAGVAR(archive_expsym_cmds, $1) \
     _LT_AC_TAGVAR(postinstall_cmds, $1) \
@@ -6974,6 +6945,7 @@ if test -f "$ltmain"; then
     _LT_AC_TAGVAR(module_cmds, $1) \
     _LT_AC_TAGVAR(module_expsym_cmds, $1) \
     _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
+    _LT_AC_TAGVAR(fix_srcfile_path, $1) \
     _LT_AC_TAGVAR(exclude_expsyms, $1) \
     _LT_AC_TAGVAR(include_expsyms, $1); do
 
@@ -7021,7 +6993,7 @@ ifelse([$1], [],
 # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
 #
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
+# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
 # Free Software Foundation, Inc.
 #
 # This file is part of GNU Libtool:
@@ -7102,6 +7074,9 @@ AR_FLAGS=$lt_AR_FLAGS
 # A C compiler.
 LTCC=$lt_LTCC
 
+# LTCC compiler flags.
+LTCFLAGS=$lt_LTCFLAGS
+
 # A language-specific compiler.
 CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
 
@@ -7255,6 +7230,10 @@ predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1)
 # shared library.
 postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1)
 
+# The directories searched by this compiler when creating a shared
+# library
+compiler_lib_search_dirs=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)
+
 # The library search path used internally by the compiler when linking
 # a shared library.
 compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1)
@@ -7343,7 +7322,7 @@ sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
 
 # Fix the shell variable \$srcfile for the compiler.
-fix_srcfile_path="$_LT_AC_TAGVAR(fix_srcfile_path, $1)"
+fix_srcfile_path=$lt_fix_srcfile_path
 
 # Set to yes if exported symbols are required.
 always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1)
@@ -7426,6 +7405,7 @@ fi
 # ---------------------------------
 AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
 [AC_REQUIRE([AC_CANONICAL_HOST])
+AC_REQUIRE([LT_AC_PROG_SED])
 AC_REQUIRE([AC_PROG_NM])
 AC_REQUIRE([AC_OBJEXT])
 # Check for command to grab the raw symbol name followed by C symbol from nm.
@@ -7462,7 +7442,7 @@ hpux*) # Its linker distinguishes data from code symbols
   lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
   lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
   ;;
-linux*)
+linux* | k*bsd*-gnu)
   if test "$host_cpu" = ia64; then
     symcode='[[ABCDGIRSTW]]'
     lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
@@ -7475,9 +7455,18 @@ irix* | nonstopux*)
 osf*)
   symcode='[[BCDEGQRST]]'
   ;;
-solaris* | sysv5*)
+solaris*)
   symcode='[[BDRT]]'
   ;;
+sco3.2v5*)
+  symcode='[[DT]]'
+  ;;
+sysv4.2uw2*)
+  symcode='[[DT]]'
+  ;;
+sysv5* | sco5v6* | unixware* | OpenUNIX*)
+  symcode='[[ABDT]]'
+  ;;
 sysv4)
   symcode='[[DFNSTU]]'
   ;;
@@ -7594,7 +7583,7 @@ EOF
     echo "$progname: failed program was:" >&5
     cat conftest.$ac_ext >&5
   fi
-  rm -f conftest* conftst*
+  rm -rf conftest* conftst*
 
   # Do not use the global_symbol_pipe unless it works.
   if test "$pipe_works" = yes; then
@@ -7643,13 +7632,15 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       # like `-m68040'.
       _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
       ;;
-    beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
+    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
       # PIC is the default for these OSes.
       ;;
-    mingw* | os2* | pw32*)
+    mingw* | cygwin* | os2* | pw32*)
       # This hack is so that the source file can tell whether it is being
       # built for inclusion in a dll (and should export symbols for example).
-      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
+      # Although the cygwin gcc ignores -fPIC, still need this for old-style
+      # (--disable-auto-import) libraries
+	  _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
       ;;
     darwin* | rhapsody*)
       # PIC is the default on this platform
@@ -7660,6 +7651,10 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       # DJGPP does not support shared libraries at all
       _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
       ;;
+    interix[[3-9]]*)
+      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
+      # Instead, we relocate shared libraries at runtime.
+      ;;
     sysv4*MP*)
       if test -d /usr/nec; then
 	_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
@@ -7682,7 +7677,7 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
     esac
   else
     case $host_os in
-      aix4* | aix5*)
+      aix[[4-9]]*)
 	# All AIX code is PIC.
 	if test "$host_cpu" = ia64; then
 	  # AIX 5 now supports IA64 processor
@@ -7722,21 +7717,21 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
 	    ;;
 	esac
 	;;
-      freebsd* | kfreebsd*-gnu | dragonfly*)
+      freebsd* | dragonfly*)
 	# FreeBSD uses GNU C++
 	;;
       hpux9* | hpux10* | hpux11*)
 	case $cc_basename in
 	  CC*)
 	    _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
+	    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
 	    if test "$host_cpu" != ia64; then
 	      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
 	    fi
 	    ;;
 	  aCC*)
 	    _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
+	    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
 	    case $host_cpu in
 	    hppa*64*|ia64*)
 	      # +Z the default
@@ -7750,6 +7745,10 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
 	    ;;
 	esac
 	;;
+      interix*)
+	# This is c89, which is MS Visual C++ (no shared libs)
+	# Anyone wants to do a port?
+	;;
       irix5* | irix6* | nonstopux*)
 	case $cc_basename in
 	  CC*)
@@ -7761,7 +7760,7 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
 	    ;;
 	esac
 	;;
-      linux*)
+      linux* | k*bsd*-gnu)
 	case $cc_basename in
 	  KCC*)
 	    # KAI C++ Compiler
@@ -7780,7 +7779,7 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
         _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
         _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
         ;;
-	  pgCC*)
+	  pgCC* | pgcpp*)
 	    # Portland Group C++ compiler.
 	    _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 	    _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
@@ -7794,6 +7793,14 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
 	    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
 	    ;;
 	  *)
+	    case `$CC -V 2>&1 | sed 5q` in
+	    *Sun\ C*)
+	      # Sun C++ 5.9
+	      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
+	      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
+	      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
+	      ;;
+	    esac
 	    ;;
 	esac
 	;;
@@ -7835,15 +7842,6 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
 	;;
       psos*)
 	;;
-      sco*)
-	case $cc_basename in
-	  CC*)
-	    _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
-	    ;;
-	  *)
-	    ;;
-	esac
-	;;
       solaris*)
 	case $cc_basename in
 	  CC*)
@@ -7885,7 +7883,14 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
 	    ;;
 	esac
 	;;
-      unixware*)
+      sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
+	case $cc_basename in
+	  CC*)
+	    _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
+	    _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
+	    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
+	    ;;
+	esac
 	;;
       vxworks*)
 	;;
@@ -7916,14 +7921,16 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
       ;;
 
-    beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
+    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
       # PIC is the default for these OSes.
       ;;
 
-    mingw* | pw32* | os2*)
+    mingw* | cygwin* | pw32* | os2*)
       # This hack is so that the source file can tell whether it is being
       # built for inclusion in a dll (and should export symbols for example).
-      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
+      # Although the cygwin gcc ignores -fPIC, still need this for old-style
+      # (--disable-auto-import) libraries
+	  _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
       ;;
 
     darwin* | rhapsody*)
@@ -7932,6 +7939,11 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
       ;;
 
+    interix[[3-9]]*)
+      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
+      # Instead, we relocate shared libraries at runtime.
+      ;;
+
     msdosdjgpp*)
       # Just because we use GCC doesn't mean we suddenly get shared libraries
       # on systems that don't support them.
@@ -7985,10 +7997,10 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
        esac
        ;;
 
-    mingw* | pw32* | os2*)
+    mingw* | cygwin* | pw32* | os2*)
       # This hack is so that the source file can tell whether it is being
       # built for inclusion in a dll (and should export symbols for example).
-      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
+	  _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
       ;;
 
     hpux9* | hpux10* | hpux11*)
@@ -8018,7 +8030,7 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
       ;;
 
-    linux*)
+    linux* | k*bsd*-gnu)
       case $cc_basename in
       # old Intel for x86_64 which still supported -KPIC.
       ecc*)
@@ -8045,6 +8057,22 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
         # All Alpha code is PIC.
         _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
         ;;
+      *)
+        case `$CC -V 2>&1 | sed 5q` in
+	*Sun\ C*)
+	  # Sun C 5.9
+	  _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
+	  _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
+	  _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
+	  ;;
+	*Sun\ F*)
+	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
+	  _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
+	  _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
+	  _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=''
+	  ;;
+	esac
+	;;
       esac
       ;;
 
@@ -8054,9 +8082,8 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
       ;;
 
-    sco3.2v5*)
-      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kpic'
-      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-dn'
+    rdos*)
+      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
       ;;
 
     solaris*)
@@ -8076,7 +8103,7 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
       ;;
 
-    sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
+    sysv4 | sysv4.2uw2* | sysv4.3*)
       _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
       _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
       _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
@@ -8089,6 +8116,12 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       fi
       ;;
 
+    sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
+      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
+      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
+      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
+      ;;
+
     unicos*)
       _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
       _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
@@ -8112,7 +8145,7 @@ AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)])
 #
 if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then
   AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works],
-    _LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1),
+    _LT_AC_TAGVAR(lt_cv_prog_compiler_pic_works, $1),
     [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [],
     [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in
      "" | " "*) ;;
@@ -8130,6 +8163,16 @@ case $host_os in
     _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])"
     ;;
 esac
+
+#
+# Check to make sure the static flag actually works.
+#
+wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\"
+AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
+  _LT_AC_TAGVAR(lt_cv_prog_compiler_static_works, $1),
+  $lt_tmp_static_flag,
+  [],
+  [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
 ])
 
 
@@ -8137,11 +8180,12 @@ esac
 # ------------------------------------
 # See if the linker supports building shared libraries.
 AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
-[AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
 ifelse([$1],[CXX],[
   _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
   case $host_os in
-  aix4* | aix5*)
+  aix[[4-9]]*)
     # If we're using GNU nm, then we don't want the "-C" option.
     # -C means demangle to AIX nm, but means don't demangle with GNU nm
     if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
@@ -8154,12 +8198,13 @@ ifelse([$1],[CXX],[
     _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
   ;;
   cygwin* | mingw*)
-    _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/;/^.* __nm__/s/^.* __nm__\([[^ ]]*\) [[^ ]]*/\1 DATA/;/^I /d;/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
+    _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
   ;;
   *)
     _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
   ;;
   esac
+  _LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
 ],[
   runpath_var=
   _LT_AC_TAGVAR(allow_undefined_flag, $1)=
@@ -8190,12 +8235,14 @@ ifelse([$1],[CXX],[
   # it will be wrapped by ` (' and `)$', so one must not match beginning or
   # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
   # as well as any symbol that contains `d'.
-  _LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_"
+  _LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
   # platforms (ab)use it in PIC code, but their linkers get confused if
   # the symbol is explicitly referenced.  Since portable code cannot
   # rely on this symbol name, it's probably fine to never include it in
   # preloaded symbol tables.
+  # Exclude shared library initialization/finalization symbols.
+dnl Note also adjust exclude_expsyms for C++ above.
   extract_expsyms_cmds=
   # Just being paranoid about ensuring that cc_basename is set.
   _LT_CC_BASENAME([$compiler])
@@ -8208,6 +8255,10 @@ ifelse([$1],[CXX],[
       with_gnu_ld=no
     fi
     ;;
+  interix*)
+    # we just hope/assume this is gcc and not c89 (= MSVC++)
+    with_gnu_ld=yes
+    ;;
   openbsd*)
     with_gnu_ld=no
     ;;
@@ -8217,7 +8268,7 @@ ifelse([$1],[CXX],[
   if test "$with_gnu_ld" = yes; then
     # If archive_cmds runs LD, not CC, wlarc should be empty
     wlarc='${wl}'
-    
+
     # Set some defaults for GNU ld with shared library support. These
     # are reset later if shared libraries are not supported. Putting them
     # here allows them to be overridden if necessary.
@@ -8238,10 +8289,10 @@ ifelse([$1],[CXX],[
       *\ 2.11.*) ;; # other 2.11 versions
       *) supports_anon_versioning=yes ;;
     esac
-    
+
     # See if GNU ld supports shared libraries.
     case $host_os in
-    aix3* | aix4* | aix5*)
+    aix[[3-9]]*)
       # On AIX/PPC, the GNU linker is very broken
       if test "$host_cpu" != ia64; then
 	_LT_AC_TAGVAR(ld_shlibs, $1)=no
@@ -8289,10 +8340,10 @@ EOF
       _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
       _LT_AC_TAGVAR(always_export_symbols, $1)=no
       _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
-      _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
+      _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
 
       if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
-        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
+        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
 	# If the export-symbols file already is a .def file (1st line
 	# is EXPORTS), use it as is; otherwise, prepend...
 	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
@@ -8301,13 +8352,28 @@ EOF
 	  echo EXPORTS > $output_objdir/$soname.def;
 	  cat $export_symbols >> $output_objdir/$soname.def;
 	fi~
-	$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000  ${wl}--out-implib,$lib'
+	$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
       else
 	_LT_AC_TAGVAR(ld_shlibs, $1)=no
       fi
       ;;
 
-    linux*)
+    interix[[3-9]]*)
+      _LT_AC_TAGVAR(hardcode_direct, $1)=no
+      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
+      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
+      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
+      # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
+      # Instead, shared libraries are loaded at an image base (0x10000000 by
+      # default) and relocated if they conflict, which is a slow very memory
+      # consuming and fragmenting process.  To avoid this, we pick a random,
+      # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
+      # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
+      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
+      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
+      ;;
+
+    gnu* | linux* | k*bsd*-gnu)
       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
 	tmp_addflag=
 	case $cc_basename,$host_cpu in
@@ -8315,7 +8381,7 @@ EOF
 	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
 	  tmp_addflag=' $pic_flag'
 	  ;;
-	pgf77* | pgf90* | pgf95*)			# Portland Group f77 and f90 compilers
+	pgf77* | pgf90* | pgf95*)	# Portland Group f77 and f90 compilers
 	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
 	  tmp_addflag=' $pic_flag -Mnomain' ;;
 	ecc*,ia64* | icc*,ia64*)		# Intel C compiler on ia64
@@ -8325,13 +8391,22 @@ EOF
 	ifc* | ifort*)			# Intel Fortran compiler
 	  tmp_addflag=' -nofor_main' ;;
 	esac
-	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	case `$CC -V 2>&1 | sed 5q` in
+	*Sun\ C*)			# Sun C 5.9
+	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
+	  tmp_sharedflag='-G' ;;
+	*Sun\ F*)			# Sun Fortran 8.3
+	  tmp_sharedflag='-G' ;;
+	*)
+	  tmp_sharedflag='-shared' ;;
+	esac
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
 	if test $supports_anon_versioning = yes; then
 	  _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~
   cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
   $echo "local: *; };" >> $output_objdir/$libname.ver~
-	  $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
+	  $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
 	fi
       else
 	_LT_AC_TAGVAR(ld_shlibs, $1)=no
@@ -8348,7 +8423,7 @@ EOF
       fi
       ;;
 
-    solaris* | sysv5*)
+    solaris*)
       if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
 	_LT_AC_TAGVAR(ld_shlibs, $1)=no
 	cat <<EOF 1>&2
@@ -8369,6 +8444,33 @@ EOF
       fi
       ;;
 
+    sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
+      case `$LD -v 2>&1` in
+        *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
+	_LT_AC_TAGVAR(ld_shlibs, $1)=no
+	cat <<_LT_EOF 1>&2
+
+*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
+*** reliably create shared libraries on SCO systems.  Therefore, libtool
+*** is disabling shared libraries support.  We urge you to upgrade GNU
+*** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
+*** your PATH or compiler configuration so that the native linker is
+*** used, and then restart.
+
+_LT_EOF
+	;;
+	*)
+	  if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
+	    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
+	    _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
+	    _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib'
+	  else
+	    _LT_AC_TAGVAR(ld_shlibs, $1)=no
+	  fi
+	;;
+      esac
+      ;;
+
     sunos4*)
       _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
       wlarc=
@@ -8402,14 +8504,14 @@ EOF
       # Note: this linker hardcodes the directories in LIBPATH if there
       # are no directories specified by -L.
       _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
-      if test "$GCC" = yes && test -z "$link_static_flag"; then
+      if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
 	# Neither direct hardcoding nor static linking is supported with a
 	# broken collect2.
 	_LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
       fi
       ;;
 
-    aix4* | aix5*)
+    aix[[4-9]]*)
       if test "$host_cpu" = ia64; then
 	# On IA64, the linker does run time linking by default, so we don't
 	# have to do anything special.
@@ -8429,13 +8531,14 @@ EOF
 	# Test if we are trying to use run time linking or normal
 	# AIX style linking. If -brtl is somewhere in LDFLAGS, we
 	# need to do runtime linking.
-	case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
+	case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
 	  for ld_flag in $LDFLAGS; do
   	  if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
   	    aix_use_runtimelinking=yes
   	    break
   	  fi
 	  done
+	  ;;
 	esac
 
 	exp_sym_flag='-bexport'
@@ -8462,7 +8565,7 @@ EOF
   	   strings "$collect2name" | grep resolve_lib_name >/dev/null
 	  then
   	  # We have reworked collect2
-  	  _LT_AC_TAGVAR(hardcode_direct, $1)=yes
+  	  :
 	  else
   	  # We have old collect2
   	  _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
@@ -8473,6 +8576,7 @@ EOF
   	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
   	  _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
 	  fi
+	  ;;
 	esac
 	shared_flag='-shared'
 	if test "$aix_use_runtimelinking" = yes; then
@@ -8485,11 +8589,11 @@ EOF
   	# chokes on -Wl,-G. The following line is correct:
 	  shared_flag='-G'
 	else
-  	if test "$aix_use_runtimelinking" = yes; then
+	  if test "$aix_use_runtimelinking" = yes; then
 	    shared_flag='${wl}-G'
 	  else
 	    shared_flag='${wl}-bM:SRE'
-  	fi
+	  fi
 	fi
       fi
 
@@ -8503,12 +8607,12 @@ EOF
        # Determine the default libpath from the value encoded in an empty executable.
        _LT_AC_SYS_LIBPATH_AIX
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
-	_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
        else
 	if test "$host_cpu" = ia64; then
 	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
 	  _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
-	  _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
+	  _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
 	else
 	 # Determine the default libpath from the value encoded in an empty executable.
 	 _LT_AC_SYS_LIBPATH_AIX
@@ -8517,13 +8621,11 @@ EOF
 	  # -berok will link without error, but may produce a broken library.
 	  _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
 	  _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
-	  # -bexpall does not export symbols beginning with underscore (_)
-	  _LT_AC_TAGVAR(always_export_symbols, $1)=yes
 	  # Exported symbols can be pulled into shared objects from archives
-	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
+	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
 	  _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
 	  # This is similar to how AIX traditionally builds its shared libraries.
-	  _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
+	  _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
 	fi
       fi
       ;;
@@ -8556,7 +8658,7 @@ EOF
       # The linker will automatically build a .lib file if we build a DLL.
       _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
       # FIXME: Should let the user specify the lib program.
-      _LT_AC_TAGVAR(old_archive_cmds, $1)='lib /OUT:$oldlib$oldobjs$old_deplibs'
+      _LT_AC_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
       _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
       _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
       ;;
@@ -8589,19 +8691,18 @@ EOF
       _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
     if test "$GCC" = yes ; then
     	output_verbose_link_cmd='echo'
-        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
-      _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
-      # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
-      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
-      _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
+        _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
+        _LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
+        _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
+        _LT_AC_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
     else
       case $cc_basename in
         xlc*)
          output_verbose_link_cmd='echo'
-         _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
+         _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
          _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
           # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
-         _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
+         _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
           _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
           ;;
        *)
@@ -8641,7 +8742,7 @@ EOF
       ;;
 
     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
-    freebsd* | kfreebsd*-gnu | dragonfly*)
+    freebsd* | dragonfly*)
       _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
       _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
       _LT_AC_TAGVAR(hardcode_direct, $1)=yes
@@ -8664,47 +8765,62 @@ EOF
       _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
       ;;
 
-    hpux10* | hpux11*)
+    hpux10*)
+      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+      else
+	_LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
+      fi
+      if test "$with_gnu_ld" = no; then
+	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
+	_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
+
+	_LT_AC_TAGVAR(hardcode_direct, $1)=yes
+	_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
+
+	# hardcode_minus_L: Not really in the search PATH,
+	# but as the default location of the library.
+	_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
+      fi
+      ;;
+
+    hpux11*)
       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
 	case $host_cpu in
-	hppa*64*|ia64*)
+	hppa*64*)
 	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
+	ia64*)
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
+	  ;;
 	*)
 	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	esac
       else
 	case $host_cpu in
-	hppa*64*|ia64*)
-	  _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags'
+	hppa*64*)
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	  ;;
+	ia64*)
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	*)
-	  _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	esac
       fi
       if test "$with_gnu_ld" = no; then
+	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
+	_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
+
 	case $host_cpu in
-	hppa*64*)
-	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
+	hppa*64*|ia64*)
 	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
-	  _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 	  _LT_AC_TAGVAR(hardcode_direct, $1)=no
 	  _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 	  ;;
-	ia64*)
-	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-	  _LT_AC_TAGVAR(hardcode_direct, $1)=no
-	  _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-
-	  # hardcode_minus_L: Not really in the search PATH,
-	  # but as the default location of the library.
-	  _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
-	  ;;
 	*)
-	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
-	  _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 	  _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 	  _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
@@ -8748,24 +8864,28 @@ EOF
       ;;
 
     openbsd*)
-      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
-      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-      if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
-	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
-	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
-	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
-	_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
+      if test -f /usr/libexec/ld.so; then
+	_LT_AC_TAGVAR(hardcode_direct, $1)=yes
+	_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
+	if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
+	  _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
+	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
+	  _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
+	else
+	  case $host_os in
+	   openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
+	     _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
+	     _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
+	     ;;
+	   *)
+	     _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
+	     _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
+	     ;;
+	  esac
+        fi
       else
-       case $host_os in
-	 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
-	   _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
-	   _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
-	   ;;
-	 *)
-	   _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
-	   _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
-	   ;;
-       esac
+	_LT_AC_TAGVAR(ld_shlibs, $1)=no
       fi
       ;;
 
@@ -8806,14 +8926,6 @@ EOF
       _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
       ;;
 
-    sco3.2v5*)
-      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
-      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
-      runpath_var=LD_RUN_PATH
-      hardcode_runpath_var=yes
-      ;;
-
     solaris*)
       _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
       if test "$GCC" = yes; then
@@ -8832,17 +8944,16 @@ EOF
       case $host_os in
       solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
       *)
- 	# The compiler driver will combine linker options so we
- 	# cannot just pass the convience library names through
- 	# without $wl, iff we do not link with $LD.
- 	# Luckily, gcc supports the same syntax we need for Sun Studio.
+	# The compiler driver will combine and reorder linker options,
+	# but understands `-z linker_flag'.  GCC discards it without `$wl',
+	# but is careful enough not to reorder.
  	# Supported since Solaris 2.6 (maybe 2.5.1?)
- 	case $wlarc in
- 	'')
- 	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;;
- 	*)
- 	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;;
- 	esac ;;
+	if test "$GCC" = yes; then
+	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
+	else
+	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
+	fi
+	;;
       esac
       _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
       ;;
@@ -8899,36 +9010,45 @@ EOF
       fi
       ;;
 
-    sysv4.2uw2*)
-      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
-      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
-      _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
+    sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
+      _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
+      _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
       _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-      hardcode_runpath_var=yes
-      runpath_var=LD_RUN_PATH
-      ;;
+      runpath_var='LD_RUN_PATH'
 
-   sysv5OpenUNIX8* | sysv5UnixWare7* |  sysv5uw[[78]]* | unixware7*)
-      _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z ${wl}text'
       if test "$GCC" = yes; then
-	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
       else
-	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
       fi
-      runpath_var='LD_RUN_PATH'
-      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
       ;;
 
-    sysv5*)
-      _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
-      # $CC -shared without GNU ld will not create a library from C++
-      # object files and a static libstdc++, better avoid it by now
-      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
-      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
-  		$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
-      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
+    sysv5* | sco3.2v5* | sco5v6*)
+      # Note: We can NOT use -z defs as we might desire, because we do not
+      # link with -lc, and that would cause any symbols used from libc to
+      # always be unresolved, which means just about no library would
+      # ever link correctly.  If we're not using GNU ld we use -z text
+      # though, which does catch some bad symbols but isn't as heavy-handed
+      # as -z defs.
+      _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
+      _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
+      _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
       _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
+      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
+      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
+      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
+      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
       runpath_var='LD_RUN_PATH'
+
+      if test "$GCC" = yes; then
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+      else
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+      fi
       ;;
 
     uts4*)
@@ -8946,11 +9066,6 @@ EOF
 AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
 test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
 
-variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
-if test "$GCC" = yes; then
-  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
-fi
-
 #
 # Do we need to explicitly link libc?
 #
@@ -8970,7 +9085,7 @@ x|xyes)
       # to ld, don't add -lc before -lgcc.
       AC_MSG_CHECKING([whether -lc should be explicitly linked in])
       $rm conftest*
-      printf "$lt_simple_compile_test_code" > conftest.$ac_ext
+      echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
       if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
         soname=conftest
@@ -8978,6 +9093,7 @@ x|xyes)
         libobjs=conftest.$ac_objext
         deplibs=
         wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
+	pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
         compiler_flags=-v
         linker_flags=-v
         verstring=
@@ -9062,16 +9178,6 @@ AC_DEFUN([AM_PROG_NM],        [AC_PROG_NM])
 # This is just to silence aclocal about the macro not being used
 ifelse([AC_DISABLE_FAST_INSTALL])
 
-#AC_DEFUN([LT_AC_PROG_GCJ],
-#[AC_CHECK_TOOL(GCJ, gcj, no)
-#  test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
-#  AC_SUBST(GCJFLAGS)
-#])
-
-#AC_DEFUN([LT_AC_PROG_RC],
-#[AC_CHECK_TOOL(RC, windres, no)
-#])
-
 ############################################################
 # NOTE: This macro has been submitted for inclusion into   #
 #  GNU Autoconf as AC_PROG_SED.  When it is available in   #
diff --git a/build/libtool.m4 b/build/libtool.m4
index 064582c..268cad9 100644
--- a/build/libtool.m4
+++ b/build/libtool.m4
@@ -1,13 +1,13 @@
 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
-## Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005
-## Free Software Foundation, Inc.
+## Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007,
+## 2008  Free Software Foundation, Inc.
 ## Originally by Gordon Matzigkeit <gord at gnu.ai.mit.edu>, 1996
 ##
 ## This file is free software; the Free Software Foundation gives
 ## unlimited permission to copy and/or distribute it, with or without
 ## modifications, as long as this notice is preserved.
 
-# serial 47 AC_PROG_LIBTOOL
+# serial 52 AC_PROG_LIBTOOL
 
 ifdef([AC_ACVERSION],[
 # autoconf 2.13 compatibility
@@ -44,30 +44,6 @@ dnl immediately, otherwise, hook it in at the end of AC_PROG_CXX.
     [AC_LIBTOOL_CXX],
     [define([AC_PROG_CXX], defn([AC_PROG_CXX])[AC_LIBTOOL_CXX
   ])])
-
-dnl dnl And a similar setup for Fortran 77 support
-dnl   AC_PROVIDE_IFELSE([AC_PROG_F77],
-dnl     [AC_LIBTOOL_F77],
-dnl     [define([AC_PROG_F77], defn([AC_PROG_F77])[AC_LIBTOOL_F77
-dnl ])])
-
-dnl dnl Quote A][M_PROG_GCJ so that aclocal doesn't bring it in needlessly.
-dnl dnl If either AC_PROG_GCJ or A][M_PROG_GCJ have already been expanded, run
-dnl dnl AC_LIBTOOL_GCJ immediately, otherwise, hook it in at the end of both.
-dnl   AC_PROVIDE_IFELSE([AC_PROG_GCJ],
-dnl     [AC_LIBTOOL_GCJ],
-dnl     [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],
-dnl       [AC_LIBTOOL_GCJ],
-dnl       [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],
-dnl 	[AC_LIBTOOL_GCJ],
-dnl       [ifdef([AC_PROG_GCJ],
-dnl 	     [define([AC_PROG_GCJ], defn([AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])
-dnl        ifdef([A][M_PROG_GCJ],
-dnl 	     [define([A][M_PROG_GCJ], defn([A][M_PROG_GCJ])[AC_LIBTOOL_GCJ])])
-dnl        ifdef([LT_AC_PROG_GCJ],
-dnl 	     [define([LT_AC_PROG_GCJ],
-dnl 		defn([LT_AC_PROG_GCJ])[AC_LIBTOOL_GCJ])])])])
-dnl ])
 ])# AC_PROG_LIBTOOL
 
 
@@ -76,8 +52,6 @@ dnl ])
 AC_DEFUN([_AC_PROG_LIBTOOL],
 [AC_REQUIRE([AC_LIBTOOL_SETUP])dnl
 AC_BEFORE([$0],[AC_LIBTOOL_CXX])dnl
-dnl AC_BEFORE([$0],[AC_LIBTOOL_F77])dnl
-dnl AC_BEFORE([$0],[AC_LIBTOOL_GCJ])dnl
 
 # This can be used to rebuild libtool when needed
 LIBTOOL_DEPS="$ac_aux_dir/ltmain.sh"
@@ -111,7 +85,6 @@ AC_REQUIRE([AC_DEPLIBS_CHECK_METHOD])dnl
 AC_REQUIRE([AC_OBJEXT])dnl
 AC_REQUIRE([AC_EXEEXT])dnl
 dnl
-
 AC_LIBTOOL_SYS_MAX_CMD_LEN
 AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE
 AC_LIBTOOL_OBJDIR
@@ -173,6 +146,7 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
 test -z "$AS" && AS=as
 test -z "$CC" && CC=cc
 test -z "$LTCC" && LTCC=$CC
+test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
 test -z "$DLLTOOL" && DLLTOOL=dlltool
 test -z "$LD" && LD=ld
 test -z "$LN_S" && LN_S="ln -s"
@@ -185,17 +159,17 @@ test -z "$STRIP" && STRIP=:
 test -z "$ac_objext" && ac_objext=o
 
 # Determine commands to create old-style static archives.
-old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
+old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
 old_postinstall_cmds='chmod 644 $oldlib'
 old_postuninstall_cmds=
 
 if test -n "$RANLIB"; then
   case $host_os in
   openbsd*)
-    old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
+    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
     ;;
   *)
-    old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
+    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
     ;;
   esac
   old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
@@ -212,6 +186,8 @@ file_magic*)
   ;;
 esac
 
+_LT_REQUIRED_DARWIN_CHECKS
+
 AC_PROVIDE_IFELSE([AC_LIBTOOL_DLOPEN], enable_dlopen=yes, enable_dlopen=no)
 AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
 enable_win32_dll=yes, enable_win32_dll=no)
@@ -241,6 +217,9 @@ AC_DEFUN([_LT_AC_SYS_COMPILER],
 # If no C compiler was specified, use CC.
 LTCC=${LTCC-"$CC"}
 
+# If no C compiler flags were specified, use CFLAGS.
+LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
+
 # Allow CC to be a program name with arguments.
 compiler=$CC
 ])# _LT_AC_SYS_COMPILER
@@ -267,9 +246,10 @@ cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
 # Check for compiler boilerplate output or warnings with
 # the simple compiler test code.
 AC_DEFUN([_LT_COMPILER_BOILERPLATE],
-[ac_outfile=conftest.$ac_objext
-printf "$lt_simple_compile_test_code" >conftest.$ac_ext
-eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+ac_outfile=conftest.$ac_objext
+echo "$lt_simple_compile_test_code" >conftest.$ac_ext
+eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
 _lt_compiler_boilerplate=`cat conftest.err`
 $rm conftest*
 ])# _LT_COMPILER_BOILERPLATE
@@ -280,11 +260,12 @@ $rm conftest*
 # Check for linker boilerplate output or warnings with
 # the simple link test code.
 AC_DEFUN([_LT_LINKER_BOILERPLATE],
-[ac_outfile=conftest.$ac_objext
-printf "$lt_simple_link_test_code" >conftest.$ac_ext
-eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+ac_outfile=conftest.$ac_objext
+echo "$lt_simple_link_test_code" >conftest.$ac_ext
+eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
 _lt_linker_boilerplate=`cat conftest.err`
-$rm conftest*
+$rm -r conftest*
 ])# _LT_LINKER_BOILERPLATE
 
 
@@ -300,7 +281,7 @@ int main() {
 ; return 0; }
 EOF
 if AC_TRY_EVAL(ac_link) && test -s conftest${ac_exeext}; then
-  ifelse([$1], , :, [$1
+ ifelse([$1], , :, [$1
   rm -rf conftest*])
 else
   echo "configure: failed program was:" >&5
@@ -311,6 +292,75 @@ ifelse([$2], , , [$2
 fi
 rm -f conftest*])
 
+# _LT_REQUIRED_DARWIN_CHECKS
+# --------------------------
+# Check for some things on darwin
+AC_DEFUN([_LT_REQUIRED_DARWIN_CHECKS],[
+  case $host_os in
+    rhapsody* | darwin*)
+    AC_CHECK_TOOL([DSYMUTIL], [dsymutil], [:])
+    AC_CHECK_TOOL([NMEDIT], [nmedit], [:])
+
+    AC_CACHE_CHECK([for -single_module linker flag],[lt_cv_apple_cc_single_mod],
+      [lt_cv_apple_cc_single_mod=no
+      if test -z "${LT_MULTI_MODULE}"; then
+   # By default we will add the -single_module flag. You can override
+   # by either setting the environment variable LT_MULTI_MODULE
+   # non-empty at configure time, or by adding -multi_module to the
+   # link flags.
+   echo "int foo(void){return 1;}" > conftest.c
+   $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
+     -dynamiclib ${wl}-single_module conftest.c
+   if test -f libconftest.dylib; then
+     lt_cv_apple_cc_single_mod=yes
+     rm -rf libconftest.dylib*
+   fi
+   rm conftest.c
+      fi])
+    AC_CACHE_CHECK([for -exported_symbols_list linker flag],
+      [lt_cv_ld_exported_symbols_list],
+      [lt_cv_ld_exported_symbols_list=no
+      save_LDFLAGS=$LDFLAGS
+      echo "_main" > conftest.sym
+      LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
+      _LT_AC_TRY_LINK([lt_cv_ld_exported_symbols_list=yes],[lt_cv_ld_exported_symbols_list=no])
+   LDFLAGS="$save_LDFLAGS"
+    ])
+    case $host_os in
+    rhapsody* | darwin1.[[0123]])
+      _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
+    darwin1.*)
+     _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
+    darwin*)
+      # if running on 10.5 or later, the deployment target defaults
+      # to the OS version, if on x86, and 10.4, the deployment
+      # target defaults to 10.4. Don't you love it?
+      case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
+   10.0,*86*-darwin8*|10.0,*-darwin[[91]]*)
+     _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
+   10.[[012]]*)
+     _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
+   10.*)
+     _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
+      esac
+    ;;
+  esac
+    if test "$lt_cv_apple_cc_single_mod" = "yes"; then
+      _lt_dar_single_mod='$single_module'
+    fi
+    if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
+      _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
+    else
+      _lt_dar_export_syms="~$NMEDIT -s \$output_objdir/\${libname}-symbols.expsym \${lib}"
+    fi
+    if test "$DSYMUTIL" != ":"; then
+      _lt_dsymutil="~$DSYMUTIL \$lib || :"
+    else
+      _lt_dsymutil=
+    fi
+    ;;
+  esac
+])
 
 # _LT_AC_SYS_LIBPATH_AIX
 # ----------------------
@@ -321,12 +371,20 @@ rm -f conftest*])
 # If we don't find anything, use the default library path according
 # to the aix ld manual.
 AC_DEFUN([_LT_AC_SYS_LIBPATH_AIX],
-[_LT_AC_TRY_LINK([
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
-}'`
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+_LT_AC_TRY_LINK([
+lt_aix_libpath_sed='
+    /Import File Strings/,/^$/ {
+	/^0/ {
+	    s/^0  *\(.*\)$/\1/
+	    p
+	}
+    }'
+aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
 # Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
-}'`; fi],[])
+if test -z "$aix_libpath"; then
+  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+fi],[])
 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 ])# _LT_AC_SYS_LIBPATH_AIX
 
@@ -557,13 +615,17 @@ ia64-*-hpux*)
   rm -rf conftest*
   ;;
 
-x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
+x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
+s390*-*linux*|sparc*-*linux*)
   # Find out which ABI we are using.
   echo 'int i;' > conftest.$ac_ext
   if AC_TRY_EVAL(ac_compile); then
     case `/usr/bin/file conftest.o` in
     *32-bit*)
       case $host in
+        x86_64-*kfreebsd*-gnu)
+          LD="${LD-ld} -m elf_i386_fbsd"
+          ;;
         x86_64-*linux*)
           LD="${LD-ld} -m elf_i386"
           ;;
@@ -580,6 +642,9 @@ x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
       ;;
     *64-bit*)
       case $host in
+        x86_64-*kfreebsd*-gnu)
+          LD="${LD-ld} -m elf_x86_64_fbsd"
+          ;;
         x86_64-*linux*)
           LD="${LD-ld} -m elf_x86_64"
           ;;
@@ -613,6 +678,26 @@ x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
     CFLAGS="$SAVE_CFLAGS"
   fi
   ;;
+sparc*-*solaris*)
+  # Find out which ABI we are using.
+  echo 'int i;' > conftest.$ac_ext
+  if AC_TRY_EVAL(ac_compile); then
+    case `/usr/bin/file conftest.o` in
+    *64-bit*)
+      case $lt_cv_prog_gnu_ld in
+      yes*) LD="${LD-ld} -m elf64_sparc" ;;
+      *)
+        if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
+	  LD="${LD-ld} -64"
+	fi
+	;;
+      esac
+      ;;
+    esac
+  fi
+  rm -rf conftest*
+  ;;
+
 AC_PROVIDE_IFELSE([AC_LIBTOOL_WIN32_DLL],
 [*-*-cygwin* | *-*-mingw* | *-*-pw32*)
   AC_CHECK_TOOL(DLLTOOL, dlltool, false)
@@ -636,7 +721,7 @@ AC_DEFUN([AC_LIBTOOL_COMPILER_OPTION],
 AC_CACHE_CHECK([$1], [$2],
   [$2=no
   ifelse([$4], , [ac_outfile=conftest.$ac_objext], [ac_outfile=$4])
-   printf "$lt_simple_compile_test_code" > conftest.$ac_ext
+   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
    lt_compiler_flag="$3"
    # Insert the option either (1) after the last *FLAGS variable, or
    # (2) before a word containing "conftest.", or (3) at the end.
@@ -655,9 +740,9 @@ AC_CACHE_CHECK([$1], [$2],
    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.
-     $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
-     $SED '/^$/d' conftest.err >conftest.er2
-     if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
+     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
+     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
+     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
        $2=yes
      fi
    fi
@@ -677,19 +762,20 @@ fi
 # ------------------------------------------------------------
 # Check whether the given compiler option works
 AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
-[AC_CACHE_CHECK([$1], [$2],
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+AC_CACHE_CHECK([$1], [$2],
   [$2=no
    save_LDFLAGS="$LDFLAGS"
    LDFLAGS="$LDFLAGS $3"
-   printf "$lt_simple_link_test_code" > conftest.$ac_ext
+   echo "$lt_simple_link_test_code" > conftest.$ac_ext
    if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
      # The linker can only warn and ignore the option if not recognized
      # So say no if there are warnings
      if test -s conftest.err; then
        # Append any errors to the config.log.
        cat conftest.err 1>&5
-       $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp
-       $SED '/^$/d' conftest.err >conftest.er2
+       $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
+       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
        if diff conftest.exp conftest.er2 >/dev/null; then
          $2=yes
        fi
@@ -697,7 +783,7 @@ AC_DEFUN([AC_LIBTOOL_LINKER_OPTION],
        $2=yes
      fi
    fi
-   $rm conftest*
+   $rm -r conftest*
    LDFLAGS="$save_LDFLAGS"
 ])
 
@@ -758,44 +844,64 @@ AC_CACHE_VAL([lt_cv_sys_max_cmd_len], [dnl
     elif test -x /usr/sbin/sysctl; then
       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
     else
-      lt_cv_sys_max_cmd_len=65536     # usable default for all BSDs
+      lt_cv_sys_max_cmd_len=65536	# usable default for all BSDs
     fi
     # And add a safety zone
     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
     ;;
+
+  interix*)
+    # We know the value 262144 and hardcode it with a safety zone (like BSD)
+    lt_cv_sys_max_cmd_len=196608
+    ;;
+
   osf*)
     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
     # nice to cause kernel panics so lets avoid the loop below.
     # First set a reasonable default.
     lt_cv_sys_max_cmd_len=16384
-    # 
+    #
     if test -x /sbin/sysconfig; then
       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
         *1*) lt_cv_sys_max_cmd_len=-1 ;;
       esac
     fi
     ;;
+  sco3.2v5*)
+    lt_cv_sys_max_cmd_len=102400
+    ;;
+  sysv5* | sco5v6* | sysv4.2uw2*)
+    kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
+    if test -n "$kargmax"; then
+      lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[[ 	]]//'`
+    else
+      lt_cv_sys_max_cmd_len=32768
+    fi
+    ;;
   *)
-    # If test is not a shell built-in, we'll probably end up computing a
-    # maximum length that is only half of the actual maximum length, but
-    # we can't tell.
-    SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
-    while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
+    lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
+    if test -n "$lt_cv_sys_max_cmd_len"; then
+      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
+      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
+    else
+      SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
+      while (test "X"`$SHELL [$]0 --fallback-echo "X$teststring" 2>/dev/null` \
 	       = "XX$teststring") >/dev/null 2>&1 &&
-	    new_result=`expr "X$teststring" : ".*" 2>&1` &&
-	    lt_cv_sys_max_cmd_len=$new_result &&
-	    test $i != 17 # 1/2 MB should be enough
-    do
-      i=`expr $i + 1`
-      teststring=$teststring$teststring
-    done
-    teststring=
-    # Add a significant safety factor because C++ compilers can tack on massive
-    # amounts of additional arguments before passing them to the linker.
-    # It appears as though 1/2 is a usable value.
-    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
+	      new_result=`expr "X$teststring" : ".*" 2>&1` &&
+	      lt_cv_sys_max_cmd_len=$new_result &&
+	      test $i != 17 # 1/2 MB should be enough
+      do
+        i=`expr $i + 1`
+        teststring=$teststring$teststring
+      done
+      teststring=
+      # Add a significant safety factor because C++ compilers can tack on massive
+      # amounts of additional arguments before passing them to the linker.
+      # It appears as though 1/2 is a usable value.
+      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
+    fi
     ;;
   esac
 ])
@@ -808,7 +914,7 @@ fi
 
 
 # _LT_AC_CHECK_DLFCN
-# --------------------
+# ------------------
 AC_DEFUN([_LT_AC_CHECK_DLFCN],
 [AC_CHECK_HEADERS(dlfcn.h)dnl
 ])# _LT_AC_CHECK_DLFCN
@@ -816,7 +922,7 @@ AC_DEFUN([_LT_AC_CHECK_DLFCN],
 
 # _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
 #                           ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
-# ------------------------------------------------------------------
+# ---------------------------------------------------------------------
 AC_DEFUN([_LT_AC_TRY_DLOPEN_SELF],
 [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
 if test "$cross_compiling" = yes; then :
@@ -882,6 +988,8 @@ int main ()
       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
       /* dlclose (self); */
     }
+  else
+    puts (dlerror ());
 
     exit (status);
 }]
@@ -892,7 +1000,7 @@ EOF
     case x$lt_status in
       x$lt_dlno_uscore) $1 ;;
       x$lt_dlneed_uscore) $2 ;;
-      x$lt_unknown|x*) $3 ;;
+      x$lt_dlunknown|x*) $3 ;;
     esac
   else :
     # compilation failed
@@ -904,7 +1012,7 @@ rm -fr conftest*
 
 
 # AC_LIBTOOL_DLOPEN_SELF
-# -------------------
+# ----------------------
 AC_DEFUN([AC_LIBTOOL_DLOPEN_SELF],
 [AC_REQUIRE([_LT_AC_CHECK_DLFCN])dnl
 if test "x$enable_dlopen" != xyes; then
@@ -946,7 +1054,7 @@ else
     AC_CHECK_FUNC([shl_load],
 	  [lt_cv_dlopen="shl_load"],
       [AC_CHECK_LIB([dld], [shl_load],
-	    [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"],
+	    [lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"],
 	[AC_CHECK_FUNC([dlopen],
 	      [lt_cv_dlopen="dlopen"],
 	  [AC_CHECK_LIB([dl], [dlopen],
@@ -954,7 +1062,7 @@ else
 	    [AC_CHECK_LIB([svld], [dlopen],
 		  [lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"],
 	      [AC_CHECK_LIB([dld], [dld_link],
-		    [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"])
+		    [lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"])
 	      ])
 	    ])
 	  ])
@@ -975,7 +1083,7 @@ else
     test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
 
     save_LDFLAGS="$LDFLAGS"
-    eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
+    wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
 
     save_LIBS="$LIBS"
     LIBS="$lt_cv_dlopen_libs $LIBS"
@@ -988,7 +1096,7 @@ else
     ])
 
     if test "x$lt_cv_dlopen_self" = xyes; then
-      LDFLAGS="$LDFLAGS $link_static_flag"
+      wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
       AC_CACHE_CHECK([whether a statically linked program can dlopen itself],
     	  lt_cv_dlopen_self_static, [dnl
 	  _LT_AC_TRY_DLOPEN_SELF(
@@ -1020,7 +1128,8 @@ fi
 # ---------------------------------
 # Check to see if options -c and -o are simultaneously supported by compiler
 AC_DEFUN([AC_LIBTOOL_PROG_CC_C_O],
-[AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+AC_REQUIRE([_LT_AC_SYS_COMPILER])dnl
 AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
   [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)],
   [_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=no
@@ -1028,7 +1137,7 @@ AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
    mkdir conftest
    cd conftest
    mkdir out
-   printf "$lt_simple_compile_test_code" > conftest.$ac_ext
+   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
    lt_compiler_flag="-o out/conftest2.$ac_objext"
    # Insert the option either (1) after the last *FLAGS variable, or
@@ -1048,9 +1157,9 @@ AC_CACHE_CHECK([if $compiler supports -c -o file.$ac_objext],
    then
      # The compiler can only warn and ignore the option if not recognized
      # So say no if there are warnings
-     $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp
-     $SED '/^$/d' out/conftest.err >out/conftest.er2
-     if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then
+     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
+     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
+     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
        _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
      fi
    fi
@@ -1168,6 +1277,7 @@ else
    darwin*)
        if test -n "$STRIP" ; then
          striplib="$STRIP -x"
+         old_striplib="$STRIP -S"
          AC_MSG_RESULT([yes])
        else
   AC_MSG_RESULT([no])
@@ -1185,7 +1295,8 @@ fi
 # -----------------------------
 # PORTME Fill in your ld.so characteristics
 AC_DEFUN([AC_LIBTOOL_SYS_DYNAMIC_LINKER],
-[AC_MSG_CHECKING([dynamic linker characteristics])
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+AC_MSG_CHECKING([dynamic linker characteristics])
 library_names_spec=
 libname_spec='lib$name'
 soname_spec=
@@ -1199,20 +1310,58 @@ shlibpath_overrides_runpath=unknown
 version_type=none
 dynamic_linker="$host_os ld.so"
 sys_lib_dlsearch_path_spec="/lib /usr/lib"
+ifelse($1,[],[
 if test "$GCC" = yes; then
-  sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
-  if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
+  case $host_os in
+    darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
+    *) lt_awk_arg="/^libraries:/" ;;
+  esac
+  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
+  if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then
     # if the path contains ";" then we assume it to be the separator
     # otherwise default to the standard path separator (i.e. ":") - it is
     # assumed that no part of a normal pathname contains ";" but that should
     # okay in the real world where ";" in dirpaths is itself problematic.
-    sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
+    lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'`
   else
-    sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
+    lt_search_path_spec=`echo "$lt_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
   fi
+  # Ok, now we have the path, separated by spaces, we can step through it
+  # and add multilib dir if necessary.
+  lt_tmp_lt_search_path_spec=
+  lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
+  for lt_sys_path in $lt_search_path_spec; do
+    if test -d "$lt_sys_path/$lt_multi_os_dir"; then
+      lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
+    else
+      test -d "$lt_sys_path" && \
+	lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
+    fi
+  done
+  lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk '
+BEGIN {RS=" "; FS="/|\n";} {
+  lt_foo="";
+  lt_count=0;
+  for (lt_i = NF; lt_i > 0; lt_i--) {
+    if ($lt_i != "" && $lt_i != ".") {
+      if ($lt_i == "..") {
+        lt_count++;
+      } else {
+        if (lt_count == 0) {
+          lt_foo="/" $lt_i lt_foo;
+        } else {
+          lt_count--;
+        }
+      }
+    }
+  }
+  if (lt_foo != "") { lt_freq[[lt_foo]]++; }
+  if (lt_freq[[lt_foo]] == 1) { print lt_foo; }
+}'`
+  sys_lib_search_path_spec=`echo $lt_search_path_spec`
 else
   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
-fi
+fi])
 need_lib_prefix=unknown
 hardcode_into_libs=no
 
@@ -1230,7 +1379,7 @@ aix3*)
   soname_spec='${libname}${release}${shared_ext}$major'
   ;;
 
-aix4* | aix5*)
+aix[[4-9]]*)
   version_type=linux
   need_lib_prefix=no
   need_version=no
@@ -1369,12 +1518,8 @@ darwin* | rhapsody*)
   shlibpath_overrides_runpath=yes
   shlibpath_var=DYLD_LIBRARY_PATH
   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
-  # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
-  if test "$GCC" = yes; then
-    sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"`
-  else
-    sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
-  fi
+  ifelse([$1], [],[
+  sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib"]) 
   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
   ;;
 
@@ -1391,18 +1536,6 @@ freebsd1*)
   dynamic_linker=no
   ;;
 
-kfreebsd*-gnu)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=no
-  hardcode_into_libs=yes
-  dynamic_linker='GNU ld.so'
-  ;;
-
 freebsd* | dragonfly*)
   # DragonFly does not have aout.  When/if they implement a new
   # versioning mechanism, adjust this.
@@ -1435,10 +1568,15 @@ freebsd* | dragonfly*)
     shlibpath_overrides_runpath=yes
     hardcode_into_libs=yes
     ;;
-  *) # from 3.2 on
+  freebsd3.[[2-9]]* | freebsdelf3.[[2-9]]* | \
+  freebsd4.[[0-5]] | freebsdelf4.[[0-5]] | freebsd4.1.1 | freebsdelf4.1.1)
     shlibpath_overrides_runpath=no
     hardcode_into_libs=yes
     ;;
+  *) # from 4.6 on, and DragonFly
+    shlibpath_overrides_runpath=yes
+    hardcode_into_libs=yes
+    ;;
   esac
   ;;
 
@@ -1498,6 +1636,18 @@ hpux9* | hpux10* | hpux11*)
   postinstall_cmds='chmod 555 $lib'
   ;;
 
+interix[[3-9]]*)
+  version_type=linux
+  need_lib_prefix=no
+  need_version=no
+  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
+  soname_spec='${libname}${release}${shared_ext}$major'
+  dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
+  shlibpath_var=LD_LIBRARY_PATH
+  shlibpath_overrides_runpath=no
+  hardcode_into_libs=yes
+  ;;
+
 irix5* | irix6* | nonstopux*)
   case $host_os in
     nonstopux*) version_type=nonstopux ;;
@@ -1541,7 +1691,7 @@ linux*oldld* | linux*aout* | linux*coff*)
   ;;
 
 # This must be Linux ELF.
-linux*)
+linux* | k*bsd*-gnu)
   version_type=linux
   need_lib_prefix=no
   need_version=no
@@ -1555,27 +1705,10 @@ linux*)
   # before this can be enabled.
   hardcode_into_libs=yes
 
-  # find out which ABI we are using
-  libsuff=
-  case $host_cpu in
-  x86_64*|s390x*|powerpc64*)
-    echo '[#]line __oline__ "configure"' > conftest.$ac_ext
-    if AC_TRY_EVAL(ac_compile); then
-      case `/usr/bin/file conftest.$ac_objext` in
-      *64-bit*)
-        libsuff=64
-        sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
-        ;;
-      esac
-    fi
-    rm -rf conftest*
-    ;;
-  esac
-
   # Append ld.so.conf contents to the search path
   if test -f /etc/ld.so.conf; then
-    lt_ld_extra=`$SED -e 's/[:,\t]/ /g;s/=[^=]*$//;s/=[^= ]* / /g' /etc/ld.so.conf | tr '\n' ' '`
-    sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
+    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \[$]2)); skip = 1; } { if (!skip) print \[$]0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ 	]*hwcap[ 	]/d;s/[:,	]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
+    sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
   fi
 
   # We used to test for /lib/ld.so.1 and disable shared libraries on
@@ -1587,18 +1720,6 @@ linux*)
   dynamic_linker='GNU/Linux ld.so'
   ;;
 
-knetbsd*-gnu)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=no
-  hardcode_into_libs=yes
-  dynamic_linker='GNU ld.so'
-  ;;
-
 netbsd*)
   version_type=sunos
   need_lib_prefix=no
@@ -1636,6 +1757,7 @@ nto-qnx*)
 
 openbsd*)
   version_type=sunos
+  sys_lib_dlsearch_path_spec="/usr/lib"
   need_lib_prefix=no
   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
   case $host_os in
@@ -1679,11 +1801,8 @@ osf3* | osf4* | osf5*)
   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
   ;;
 
-sco3.2v5*)
-  version_type=osf
-  soname_spec='${libname}${release}${shared_ext}$major'
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-  shlibpath_var=LD_LIBRARY_PATH
+rdos*)
+  dynamic_linker=no
   ;;
 
 solaris*)
@@ -1711,7 +1830,7 @@ sunos4*)
   need_version=yes
   ;;
 
-sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
+sysv4 | sysv4.3*)
   version_type=linux
   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
   soname_spec='${libname}${release}${shared_ext}$major'
@@ -1744,6 +1863,29 @@ sysv4*MP*)
   fi
   ;;
 
+sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
+  version_type=freebsd-elf
+  need_lib_prefix=no
+  need_version=no
+  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
+  soname_spec='${libname}${release}${shared_ext}$major'
+  shlibpath_var=LD_LIBRARY_PATH
+  hardcode_into_libs=yes
+  if test "$with_gnu_ld" = yes; then
+    sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
+    shlibpath_overrides_runpath=no
+  else
+    sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
+    shlibpath_overrides_runpath=yes
+    case $host_os in
+      sco3.2v5*)
+        sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
+	;;
+    esac
+  fi
+  sys_lib_dlsearch_path_spec='/usr/lib'
+  ;;
+
 uts4*)
   version_type=linux
   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
@@ -1757,13 +1899,26 @@ uts4*)
 esac
 AC_MSG_RESULT([$dynamic_linker])
 test "$dynamic_linker" = no && can_build_shared=no
+
+AC_CACHE_VAL([lt_cv_sys_lib_search_path_spec],
+[lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec"])
+sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
+AC_CACHE_VAL([lt_cv_sys_lib_dlsearch_path_spec],
+[lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec"])
+sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
+
+variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
+if test "$GCC" = yes; then
+  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
+fi
 ])# AC_LIBTOOL_SYS_DYNAMIC_LINKER
 
 
 # _LT_AC_TAGCONFIG
 # ----------------
 AC_DEFUN([_LT_AC_TAGCONFIG],
-[AC_ARG_WITH([tags],
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+AC_ARG_WITH([tags],
 [  --with-tags[=TAGS]      include additional configurations [automatic]
 ],
 [tagnames="$withval"])
@@ -1781,6 +1936,9 @@ if test -f "$ltmain" && test -n "$tagnames"; then
       AC_MSG_WARN([using \`LTCC=$LTCC', extracted from \`$ofile'])
     fi
   fi
+  if test -z "$LTCFLAGS"; then
+    eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`"
+  fi
 
   # Extract list of available tagged configurations in $ofile.
   # Note that this assumes the entire list is on one line.
@@ -1816,26 +1974,6 @@ if test -f "$ltmain" && test -n "$tagnames"; then
 	fi
 	;;
 
-#      F77)
-#	if test -n "$F77" && test "X$F77" != "Xno"; then
-#	  AC_LIBTOOL_LANG_F77_CONFIG
-#	else
-#	  tagname=""
-#	fi
-#	;;
-#
-#      GCJ)
-#	if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
-#	  AC_LIBTOOL_LANG_GCJ_CONFIG
-#	else
-#	  tagname=""
-#	fi
-#	;;
-#
-#      RC)
-#	AC_LIBTOOL_LANG_RC_CONFIG
-#	;;
-
       *)
 	AC_MSG_ERROR([Unsupported tag name: $tagname])
 	;;
@@ -1910,7 +2048,7 @@ changequote([, ])dnl
 
 # AC_DISABLE_SHARED
 # -----------------
-#- set the default shared flag to --disable-shared
+# set the default shared flag to --disable-shared
 AC_DEFUN([AC_DISABLE_SHARED],
 [AC_BEFORE([$0],[AC_LIBTOOL_SETUP])dnl
 AC_ENABLE_SHARED(no)
@@ -2009,8 +2147,6 @@ pic_mode=ifelse($#,1,$1,default)
 
 # AC_PROG_EGREP
 # -------------
-# This is predefined starting with Autoconf 2.54, so this conditional
-# definition can be removed once we require Autoconf 2.54 or later.
 ifdef([AC_PROG_EGREP], [], [AC_DEFUN([AC_PROG_EGREP],
 [AC_CACHE_CHECK([for egrep], [ac_cv_prog_egrep],
    [if echo a | (grep -E '(a|b)') >/dev/null 2>&1
@@ -2024,7 +2160,7 @@ ifdef([AC_PROG_EGREP], [], [AC_DEFUN([AC_PROG_EGREP],
 
 # AC_PATH_TOOL_PREFIX
 # -------------------
-# find a file program which can recognise shared library
+# find a file program which can recognize shared library
 AC_DEFUN([AC_PATH_TOOL_PREFIX],
 [AC_REQUIRE([AC_PROG_EGREP])dnl
 AC_MSG_CHECKING([for $1])
@@ -2087,7 +2223,7 @@ fi
 
 # AC_PATH_MAGIC
 # -------------
-# find a file program which can recognise a shared library
+# find a file program which can recognize a shared library
 AC_DEFUN([AC_PATH_MAGIC],
 [AC_PATH_TOOL_PREFIX(${ac_tool_prefix}file, /usr/bin$PATH_SEPARATOR$PATH)
 if test -z "$lt_cv_path_MAGIC_CMD"; then
@@ -2219,7 +2355,7 @@ reload_cmds='$LD$reload_flag -o $output$reload_objs'
 case $host_os in
   darwin*)
     if test "$GCC" = yes; then
-      reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs'
+      reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
     else
       reload_cmds='$LD$reload_flag -o $output$reload_objs'
     fi
@@ -2233,7 +2369,7 @@ esac
 # how to check for library dependencies
 #  -- PORTME fill in with the dynamic library characteristics
 AC_DEFUN([AC_DEPLIBS_CHECK_METHOD],
-[AC_CACHE_CHECK([how to recognise dependent libraries],
+[AC_CACHE_CHECK([how to recognize dependent libraries],
 lt_cv_deplibs_check_method,
 [lt_cv_file_magic_cmd='$MAGIC_CMD'
 lt_cv_file_magic_test_file=
@@ -2250,7 +2386,7 @@ lt_cv_deplibs_check_method='unknown'
 # whether `pass_all' will *always* work, you probably want this one.
 
 case $host_os in
-aix4* | aix5*)
+aix[[4-9]]*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
@@ -2272,16 +2408,22 @@ cygwin*)
 
 mingw* | pw32*)
   # Base MSYS/MinGW do not provide the 'file' command needed by
-  # func_win32_libid shell function, so use a weaker test based on 'objdump'.
-  lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
-  lt_cv_file_magic_cmd='$OBJDUMP -f'
+  # func_win32_libid shell function, so use a weaker test based on 'objdump',
+  # unless we find 'file', for example because we are cross-compiling.
+  if ( file / ) >/dev/null 2>&1; then
+    lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
+    lt_cv_file_magic_cmd='func_win32_libid'
+  else
+    lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
+    lt_cv_file_magic_cmd='$OBJDUMP -f'
+  fi
   ;;
 
 darwin* | rhapsody*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
-freebsd* | kfreebsd*-gnu | dragonfly*)
+freebsd* | dragonfly*)
   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
     case $host_cpu in
     i*86 )
@@ -2319,6 +2461,11 @@ hpux10.20* | hpux11*)
   esac
   ;;
 
+interix[[3-9]]*)
+  # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
+  lt_cv_deplibs_check_method='match_pattern /lib[[^/]]+(\.so|\.a)$'
+  ;;
+
 irix5* | irix6* | nonstopux*)
   case $LD in
   *-32|*"-32 ") libmagic=32-bit;;
@@ -2330,7 +2477,7 @@ irix5* | irix6* | nonstopux*)
   ;;
 
 # This must be Linux ELF.
-linux*)
+linux* | k*bsd*-gnu)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
@@ -2364,7 +2511,7 @@ osf3* | osf4* | osf5*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
-sco3.2v5*)
+rdos*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
@@ -2372,7 +2519,7 @@ solaris*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
-sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
+sysv4 | sysv4.3*)
   case $host_vendor in
   motorola)
     lt_cv_deplibs_check_method='file_magic ELF [[0-9]][[0-9]]*-bit [[ML]]SB (shared object|dynamic lib) M[[0-9]][[0-9]]* Version [[0-9]]'
@@ -2393,10 +2540,13 @@ sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
   siemens)
     lt_cv_deplibs_check_method=pass_all
     ;;
+  pc)
+    lt_cv_deplibs_check_method=pass_all
+    ;;
   esac
   ;;
 
-sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7* | sysv4*uw2*)
+sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 esac
@@ -2416,36 +2566,43 @@ AC_DEFUN([AC_PROG_NM],
   # Let the user override the test.
   lt_cv_path_NM="$NM"
 else
-  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
-  for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
-    IFS="$lt_save_ifs"
-    test -z "$ac_dir" && ac_dir=.
-    tmp_nm="$ac_dir/${ac_tool_prefix}nm"
-    if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
-      # Check to see if the nm accepts a BSD-compat flag.
-      # Adding the `sed 1q' prevents false positives on HP-UX, which says:
-      #   nm: unknown option "B" ignored
-      # Tru64's nm complains that /dev/null is an invalid object file
-      case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
-      */dev/null* | *'Invalid file or object type'*)
-	lt_cv_path_NM="$tmp_nm -B"
-	break
-        ;;
-      *)
-	case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
-	*/dev/null*)
-	  lt_cv_path_NM="$tmp_nm -p"
+  lt_nm_to_check="${ac_tool_prefix}nm"
+  if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
+    lt_nm_to_check="$lt_nm_to_check nm"
+  fi
+  for lt_tmp_nm in $lt_nm_to_check; do
+    lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
+    for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
+      IFS="$lt_save_ifs"
+      test -z "$ac_dir" && ac_dir=.
+      tmp_nm="$ac_dir/$lt_tmp_nm"
+      if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
+	# Check to see if the nm accepts a BSD-compat flag.
+	# Adding the `sed 1q' prevents false positives on HP-UX, which says:
+	#   nm: unknown option "B" ignored
+	# Tru64's nm complains that /dev/null is an invalid object file
+	case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
+	*/dev/null* | *'Invalid file or object type'*)
+	  lt_cv_path_NM="$tmp_nm -B"
 	  break
 	  ;;
 	*)
-	  lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
-	  continue # so that we can try to find one that supports BSD flags
+	  case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
+	  */dev/null*)
+	    lt_cv_path_NM="$tmp_nm -p"
+	    break
+	    ;;
+	  *)
+	    lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
+	    continue # so that we can try to find one that supports BSD flags
+	    ;;
+	  esac
 	  ;;
 	esac
-      esac
-    fi
+      fi
+    done
+    IFS="$lt_save_ifs"
   done
-  IFS="$lt_save_ifs"
   test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
 fi])
 NM="$lt_cv_path_NM"
@@ -2551,7 +2708,7 @@ _LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}CXX])
 ])# _LT_AC_LANG_CXX
 
 # _LT_AC_PROG_CXXCPP
-# ---------------
+# ------------------
 AC_DEFUN([_LT_AC_PROG_CXXCPP],
 [
 AC_REQUIRE([AC_PROG_CXX])
@@ -2562,52 +2719,6 @@ if test -n "$CXX" && ( test "X$CXX" != "Xno" &&
 fi
 ])# _LT_AC_PROG_CXXCPP
 
-# AC_LIBTOOL_F77
-# --------------
-# enable support for Fortran 77 libraries
-#AC_DEFUN([AC_LIBTOOL_F77],
-#[AC_REQUIRE([_LT_AC_LANG_F77])
-#])# AC_LIBTOOL_F77
-
-
-# _LT_AC_LANG_F77
-# ---------------
-#AC_DEFUN([_LT_AC_LANG_F77],
-#[AC_REQUIRE([AC_PROG_F77])
-#_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77])
-#])# _LT_AC_LANG_F77
-
-
-# AC_LIBTOOL_GCJ
-# --------------
-# enable support for GCJ libraries
-#AC_DEFUN([AC_LIBTOOL_GCJ],
-#[AC_REQUIRE([_LT_AC_LANG_GCJ])
-#])# AC_LIBTOOL_GCJ
-
-
-# _LT_AC_LANG_GCJ
-# ---------------
-#AC_DEFUN([_LT_AC_LANG_GCJ],
-#[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
-#  [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
-#    [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
-#      [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
-#	 [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
-#	   [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
-#_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ])
-#])# _LT_AC_LANG_GCJ
-
-
-# AC_LIBTOOL_RC
-# --------------
-# enable support for Windows resource files
-#AC_DEFUN([AC_LIBTOOL_RC],
-#[AC_REQUIRE([LT_AC_PROG_RC])
-#_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC])
-#])# AC_LIBTOOL_RC
-
-
 # AC_LIBTOOL_LANG_C_CONFIG
 # ------------------------
 # Ensure that the configuration vars for the C compiler are
@@ -2627,10 +2738,10 @@ objext=o
 _LT_AC_TAGVAR(objext, $1)=$objext
 
 # Code to be used in simple compile tests
-lt_simple_compile_test_code="int some_variable = 0;\n"
+lt_simple_compile_test_code="int some_variable = 0;"
 
 # Code to be used in simple link tests
-lt_simple_link_test_code='int main(){return(0);}\n'
+lt_simple_link_test_code='int main(){return(0);}'
 
 _LT_AC_SYS_COMPILER
 
@@ -2638,37 +2749,6 @@ _LT_AC_SYS_COMPILER
 _LT_COMPILER_BOILERPLATE
 _LT_LINKER_BOILERPLATE
 
-#
-# Check for any special shared library compilation flags.
-#
-_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)=
-if test "$GCC" = no; then
-  case $host_os in
-  sco3.2v5*)
-    _LT_AC_TAGVAR(lt_prog_cc_shlib, $1)='-belf'
-    ;;
-  esac
-fi
-if test -n "$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)"; then
-  AC_MSG_WARN([\`$CC' requires \`$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to build shared libraries])
-  if echo "$old_CC $old_CFLAGS " | grep "[[ 	]]$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)[[ 	]]" >/dev/null; then :
-  else
-    AC_MSG_WARN([add \`$_LT_AC_TAGVAR(lt_prog_cc_shlib, $1)' to the CC or CFLAGS env variable and reconfigure])
-    _LT_AC_TAGVAR(lt_cv_prog_cc_can_build_shared, $1)=no
-  fi
-fi
-
-
-#
-# Check to make sure the static flag actually works.
-#
-AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $_LT_AC_TAGVAR(lt_prog_compiler_static, $1) works],
-  _LT_AC_TAGVAR(lt_prog_compiler_static_works, $1),
-  $_LT_AC_TAGVAR(lt_prog_compiler_static, $1),
-  [],
-  [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
-
-
 ## CAVEAT EMPTOR:
 ## There is no encapsulation within the following macros, do not change
 ## the running order or otherwise move them around unless you know exactly
@@ -2681,9 +2761,9 @@ AC_LIBTOOL_PROG_LD_SHLIBS($1)
 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
 AC_LIBTOOL_SYS_LIB_STRIP
-AC_LIBTOOL_DLOPEN_SELF($1)
+AC_LIBTOOL_DLOPEN_SELF
 
-# Report which librarie types wil actually be built
+# Report which library types will actually be built
 AC_MSG_CHECKING([if libtool supports shared libraries])
 AC_MSG_RESULT([$can_build_shared])
 
@@ -2701,7 +2781,7 @@ aix3*)
   fi
   ;;
 
-aix4* | aix5*)
+aix[[4-9]]*)
   if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
     test "$enable_shared" = yes && enable_static=no
   fi
@@ -2743,6 +2823,7 @@ _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
 _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
 _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
 _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
+_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
 _LT_AC_TAGVAR(hardcode_automatic, $1)=no
 _LT_AC_TAGVAR(module_cmds, $1)=
 _LT_AC_TAGVAR(module_expsym_cmds, $1)=
@@ -2758,6 +2839,7 @@ _LT_AC_TAGVAR(postdep_objects, $1)=
 _LT_AC_TAGVAR(predeps, $1)=
 _LT_AC_TAGVAR(postdeps, $1)=
 _LT_AC_TAGVAR(compiler_lib_search_path, $1)=
+_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=
 
 # Source file extension for C++ test sources.
 ac_ext=cpp
@@ -2767,10 +2849,10 @@ objext=o
 _LT_AC_TAGVAR(objext, $1)=$objext
 
 # Code to be used in simple compile tests
-lt_simple_compile_test_code="int some_variable = 0;\n"
+lt_simple_compile_test_code="int some_variable = 0;"
 
 # Code to be used in simple link tests
-lt_simple_link_test_code='int main(int, char *[]) { return(0); }\n'
+lt_simple_link_test_code='int main(int, char *[[]]) { return(0); }'
 
 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
 _LT_AC_SYS_COMPILER
@@ -2867,7 +2949,7 @@ case $host_os in
     # FIXME: insert proper C++ library support
     _LT_AC_TAGVAR(ld_shlibs, $1)=no
     ;;
-  aix4* | aix5*)
+  aix[[4-9]]*)
     if test "$host_cpu" = ia64; then
       # On IA64, the linker does run time linking by default, so we don't
       # have to do anything special.
@@ -2880,7 +2962,7 @@ case $host_os in
       # Test if we are trying to use run time linking or normal
       # AIX style linking. If -brtl is somewhere in LDFLAGS, we
       # need to do runtime linking.
-      case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
+      case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
 	for ld_flag in $LDFLAGS; do
 	  case $ld_flag in
 	  *-brtl*)
@@ -2889,6 +2971,7 @@ case $host_os in
 	    ;;
 	  esac
 	done
+	;;
       esac
 
       exp_sym_flag='-bexport'
@@ -2915,7 +2998,7 @@ case $host_os in
 	   strings "$collect2name" | grep resolve_lib_name >/dev/null
 	then
 	  # We have reworked collect2
-	  _LT_AC_TAGVAR(hardcode_direct, $1)=yes
+	  :
 	else
 	  # We have old collect2
 	  _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
@@ -2926,6 +3009,7 @@ case $host_os in
 	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
 	  _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
 	fi
+	;;
       esac
       shared_flag='-shared'
       if test "$aix_use_runtimelinking" = yes; then
@@ -2957,12 +3041,12 @@ case $host_os in
       _LT_AC_SYS_LIBPATH_AIX
       _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
 
-      _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
+      _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
      else
       if test "$host_cpu" = ia64; then
 	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
 	_LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
-	_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
       else
 	# Determine the default libpath from the value encoded in an empty executable.
 	_LT_AC_SYS_LIBPATH_AIX
@@ -2971,16 +3055,26 @@ case $host_os in
 	# -berok will link without error, but may produce a broken library.
 	_LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
 	_LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
-	# -bexpall does not export symbols beginning with underscore (_)
-	_LT_AC_TAGVAR(always_export_symbols, $1)=yes
 	# Exported symbols can be pulled into shared objects from archives
-	_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
+	_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
 	_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
 	# This is similar to how AIX traditionally builds its shared libraries.
-	_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
       fi
     fi
     ;;
+
+  beos*)
+    if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
+      _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
+      # Joseph Beckenbach <jrb3 at best.com> says some releases of gcc
+      # support --undefined.  This deserves some investigation.  FIXME
+      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+    else
+      _LT_AC_TAGVAR(ld_shlibs, $1)=no
+    fi
+    ;;
+
   chorus*)
     case $cc_basename in
       *)
@@ -2990,7 +3084,6 @@ case $host_os in
     esac
     ;;
 
-
   cygwin* | mingw* | pw32*)
     # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1) is actually meaningless,
     # as there is no search path for DLLs.
@@ -3000,7 +3093,7 @@ case $host_os in
     _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
 
     if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
-      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
+      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
       # If the export-symbols file already is a .def file (1st line
       # is EXPORTS), use it as is; otherwise, prepend...
       _LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
@@ -3009,65 +3102,37 @@ case $host_os in
 	echo EXPORTS > $output_objdir/$soname.def;
 	cat $export_symbols >> $output_objdir/$soname.def;
       fi~
-      $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
+      $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
     else
       _LT_AC_TAGVAR(ld_shlibs, $1)=no
     fi
   ;;
       darwin* | rhapsody*)
-        case $host_os in
-        rhapsody* | darwin1.[[012]])
-         _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}suppress'
-         ;;
-       *) # Darwin 1.3 on
-         if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
-           _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
-         else
-           case ${MACOSX_DEPLOYMENT_TARGET} in
-             10.[[012]])
-               _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
-               ;;
-             10.*)
-               _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-undefined ${wl}dynamic_lookup'
-               ;;
-           esac
-         fi
-         ;;
-        esac
       _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
       _LT_AC_TAGVAR(hardcode_direct, $1)=no
       _LT_AC_TAGVAR(hardcode_automatic, $1)=yes
       _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=unsupported
       _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=''
       _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
-
-    if test "$GXX" = yes ; then
-      lt_int_apple_cc_single_mod=no
+      _LT_AC_TAGVAR(allow_undefined_flag, $1)="$_lt_dar_allow_undefined"
+      if test "$GXX" = yes ; then
       output_verbose_link_cmd='echo'
-      if $CC -dumpspecs 2>&1 | $EGREP 'single_module' >/dev/null ; then
-       lt_int_apple_cc_single_mod=yes
+      _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
+      _LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
+      _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
+      _LT_AC_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
+      if test "$lt_cv_apple_cc_single_mod" != "yes"; then
+        _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
+        _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
       fi
-      if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
-       _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
-      else
-          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
-        fi
-        _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
-        # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
-          if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
-            _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
-          else
-            _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
-          fi
-            _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
       else
       case $cc_basename in
         xlc*)
          output_verbose_link_cmd='echo'
-          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
+          _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
           _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
           # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
-          _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
+          _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
           _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
           ;;
        *)
@@ -3101,7 +3166,7 @@ case $host_os in
   freebsd-elf*)
     _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
     ;;
-  freebsd* | kfreebsd*-gnu | dragonfly*)
+  freebsd* | dragonfly*)
     # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
     # conventions
     _LT_AC_TAGVAR(ld_shlibs, $1)=yes
@@ -3146,34 +3211,21 @@ case $host_os in
     ;;
   hpux10*|hpux11*)
     if test $with_gnu_ld = no; then
+      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
+      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
+
       case $host_cpu in
-      hppa*64*)
-	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
-	_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
-	_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
-        ;;
-      ia64*)
-	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-        ;;
+      hppa*64*|ia64*) ;;
       *)
-	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
-	_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 	_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
         ;;
       esac
     fi
     case $host_cpu in
-    hppa*64*)
+    hppa*64*|ia64*)
       _LT_AC_TAGVAR(hardcode_direct, $1)=no
       _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
       ;;
-    ia64*)
-      _LT_AC_TAGVAR(hardcode_direct, $1)=no
-      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-      _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
-					      # but as the default
-					      # location of the library.
-      ;;
     *)
       _LT_AC_TAGVAR(hardcode_direct, $1)=yes
       _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes # Not in the search PATH,
@@ -3189,8 +3241,11 @@ case $host_os in
 	;;
       aCC*)
 	case $host_cpu in
-	hppa*64*|ia64*)
-	  _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
+	hppa*64*)
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+	  ;;
+	ia64*)
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 	  ;;
 	*)
 	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
@@ -3210,8 +3265,11 @@ case $host_os in
 	if test "$GXX" = yes; then
 	  if test $with_gnu_ld = no; then
 	    case $host_cpu in
-	    ia64*|hppa*64*)
-	      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
+	    hppa*64*)
+	      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+	      ;;
+	    ia64*)
+	      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 	      ;;
 	    *)
 	      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
@@ -3225,6 +3283,20 @@ case $host_os in
 	;;
     esac
     ;;
+  interix[[3-9]]*)
+    _LT_AC_TAGVAR(hardcode_direct, $1)=no
+    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
+    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
+    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
+    # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
+    # Instead, shared libraries are loaded at an image base (0x10000000 by
+    # default) and relocated if they conflict, which is a slow very memory
+    # consuming and fragmenting process.  To avoid this, we pick a random,
+    # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
+    # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
+    _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
+    _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
+    ;;
   irix5* | irix6*)
     case $cc_basename in
       CC*)
@@ -3251,7 +3323,7 @@ case $host_os in
     _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath ${wl}$libdir'
     _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
     ;;
-  linux*)
+  linux* | k*bsd*-gnu)
     case $cc_basename in
       KCC*)
 	# Kuck and Associates, Inc. (KAI) C++ Compiler
@@ -3303,7 +3375,7 @@ case $host_os in
 	_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}--export-dynamic'
 	_LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
 	;;
-      pgCC*)
+      pgCC* | pgcpp*)
         # Portland Group C++ compiler
 	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
   	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
@@ -3331,6 +3403,29 @@ case $host_os in
 	# dependencies.
 	output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
 	;;
+      *)
+	case `$CC -V 2>&1 | sed 5q` in
+	*Sun\ C*)
+	  # Sun C++ 5.9
+	  _LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+	  _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
+	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
+	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
+
+	  # Not sure whether something based on
+	  # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
+	  # would be better.
+	  output_verbose_link_cmd='echo'
+
+	  # Archives containing C++ object files must be created using
+	  # "CC -xar", where "CC" is the Sun C++ compiler.  This is
+	  # necessary to make sure instantiated templates are included
+	  # in the archive.
+	  _LT_AC_TAGVAR(old_archive_cmds, $1)='$CC -xar -o $oldlib $oldobjs'
+	  ;;
+	esac
+	;;
     esac
     ;;
   lynxos*)
@@ -3369,16 +3464,20 @@ case $host_os in
     _LT_AC_TAGVAR(ld_shlibs, $1)=no
     ;;
   openbsd*)
-    _LT_AC_TAGVAR(hardcode_direct, $1)=yes
-    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-    _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
-    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
-    if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
-      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
-      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
-      _LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
+    if test -f /usr/libexec/ld.so; then
+      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
+      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
+      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
+      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
+      if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
+	_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
+	_LT_AC_TAGVAR(whole_archive_flag_spec, $1)="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
+      fi
+      output_verbose_link_cmd='echo'
+    else
+      _LT_AC_TAGVAR(ld_shlibs, $1)=no
     fi
-    output_verbose_link_cmd='echo'
     ;;
   osf3*)
     case $cc_basename in
@@ -3507,19 +3606,6 @@ case $host_os in
     # FIXME: insert proper C++ library support
     _LT_AC_TAGVAR(ld_shlibs, $1)=no
     ;;
-  sco*)
-    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
-    case $cc_basename in
-      CC*)
-	# FIXME: insert proper C++ library support
-	_LT_AC_TAGVAR(ld_shlibs, $1)=no
-	;;
-      *)
-	# FIXME: insert proper C++ library support
-	_LT_AC_TAGVAR(ld_shlibs, $1)=no
-	;;
-    esac
-    ;;
   sunos4*)
     case $cc_basename in
       CC*)
@@ -3542,26 +3628,21 @@ case $host_os in
     case $cc_basename in
       CC*)
 	# Sun C++ 4.2, 5.x and Centerline C++
-     _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes
+        _LT_AC_TAGVAR(archive_cmds_need_lc,$1)=yes
 	_LT_AC_TAGVAR(no_undefined_flag, $1)=' -zdefs'
-	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G${allow_undefined_flag}  -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
-	$CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
+	$CC -G${allow_undefined_flag}  ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
 
 	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
 	_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 	case $host_os in
 	  solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
 	  *)
-	    # The C++ compiler is used as linker so we must use $wl
-	    # flag to pass the commands to the underlying system
-	    # linker. We must also pass each convience library through
-	    # to the system linker between allextract/defaultextract.
-	    # The C++ compiler will combine linker options so we
-	    # cannot just pass the convience library names through
-	    # without $wl.
+	    # The compiler driver will combine and reorder linker options,
+	    # but understands `-z linker_flag'.
 	    # Supported since Solaris 2.6 (maybe 2.5.1?)
-	    _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract'
+	    _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
 	    ;;
 	esac
 	_LT_AC_TAGVAR(link_all_deplibs, $1)=yes
@@ -3608,12 +3689,69 @@ case $host_os in
 	  fi
 
 	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $wl$libdir'
+	  case $host_os in
+	  solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
+	  *)
+	    _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
+	    ;;
+	  esac
 	fi
 	;;
     esac
     ;;
-  sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[[78]]* | unixware7*)
+  sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
+    _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
     _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
+    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
+    runpath_var='LD_RUN_PATH'
+
+    case $cc_basename in
+      CC*)
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	;;
+      *)
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	;;
+    esac
+    ;;
+  sysv5* | sco3.2v5* | sco5v6*)
+    # Note: We can NOT use -z defs as we might desire, because we do not
+    # link with -lc, and that would cause any symbols used from libc to
+    # always be unresolved, which means just about no library would
+    # ever link correctly.  If we're not using GNU ld we use -z text
+    # though, which does catch some bad symbols but isn't as heavy-handed
+    # as -z defs.
+    # For security reasons, it is highly recommended that you always
+    # use absolute paths for naming shared libraries, and exclude the
+    # DT_RUNPATH tag from executables and libraries.  But doing so
+    # requires that you compile everything twice, which is a pain.
+    # So that behaviour is only enabled if SCOABSPATH is set to a
+    # non-empty value in the environment.  Most likely only useful for
+    # creating official distributions of packages.
+    # This is a hack until libtool officially supports absolute path
+    # names for shared libraries.
+    _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
+    _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
+    _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
+    _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
+    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
+    _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
+    _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
+    _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
+    runpath_var='LD_RUN_PATH'
+
+    case $cc_basename in
+      CC*)
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	;;
+      *)
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	;;
+    esac
     ;;
   tandem*)
     case $cc_basename in
@@ -3654,8 +3792,6 @@ AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
 AC_LIBTOOL_PROG_LD_SHLIBS($1)
 AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
 AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
-AC_LIBTOOL_SYS_LIB_STRIP
-AC_LIBTOOL_DLOPEN_SELF($1)
 
 AC_LIBTOOL_CONFIG($1)
 
@@ -3673,12 +3809,13 @@ lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
 ])# AC_LIBTOOL_LANG_CXX_CONFIG
 
 # AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
-# ------------------------
+# ------------------------------------
 # Figure out "hidden" library dependencies from verbose
 # compiler output when linking a shared library.
 # Parse the compiler output and extract the necessary
 # objects, libraries and library flags.
-AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],[
+AC_DEFUN([AC_LIBTOOL_POSTDEP_PREDEP],
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
 dnl we can't use the lt_simple_compile_test_code here,
 dnl because it contains code intended for an executable,
 dnl not a library.  It's possible we should let each
@@ -3803,239 +3940,72 @@ fi
 
 $rm -f confest.$objext
 
+_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=
+if test -n "$_LT_AC_TAGVAR(compiler_lib_search_path, $1)"; then
+  _LT_AC_TAGVAR(compiler_lib_search_dirs, $1)=`echo " ${_LT_AC_TAGVAR(compiler_lib_search_path, $1)}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
+fi
+
 # PORTME: override above test on systems where it is broken
 ifelse([$1],[CXX],
 [case $host_os in
+interix[[3-9]]*)
+  # Interix 3.5 installs completely hosed .la files for C++, so rather than
+  # hack all around it, let's just trust "g++" to DTRT.
+  _LT_AC_TAGVAR(predep_objects,$1)=
+  _LT_AC_TAGVAR(postdep_objects,$1)=
+  _LT_AC_TAGVAR(postdeps,$1)=
+  ;;
+
+linux*)
+  case `$CC -V 2>&1 | sed 5q` in
+  *Sun\ C*)
+    # Sun C++ 5.9
+    #
+    # The more standards-conforming stlport4 library is
+    # incompatible with the Cstd library. Avoid specifying
+    # it if it's in CXXFLAGS. Ignore libCrun as
+    # -library=stlport4 depends on it.
+    case " $CXX $CXXFLAGS " in
+    *" -library=stlport4 "*)
+      solaris_use_stlport4=yes
+      ;;
+    esac
+    if test "$solaris_use_stlport4" != yes; then
+      _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
+    fi
+    ;;
+  esac
+  ;;
+
 solaris*)
   case $cc_basename in
   CC*)
+    # The more standards-conforming stlport4 library is
+    # incompatible with the Cstd library. Avoid specifying
+    # it if it's in CXXFLAGS. Ignore libCrun as
+    # -library=stlport4 depends on it.
+    case " $CXX $CXXFLAGS " in
+    *" -library=stlport4 "*)
+      solaris_use_stlport4=yes
+      ;;
+    esac
+
     # Adding this requires a known-good setup of shared libraries for
     # Sun compiler versions before 5.6, else PIC objects from an old
     # archive will be linked into the output, leading to subtle bugs.
-    _LT_AC_TAGVAR(postdeps,$1)='-lCstd -lCrun'
+    if test "$solaris_use_stlport4" != yes; then
+      _LT_AC_TAGVAR(postdeps,$1)='-library=Cstd -library=Crun'
+    fi
     ;;
   esac
+  ;;
 esac
 ])
-
 case " $_LT_AC_TAGVAR(postdeps, $1) " in
 *" -lc "*) _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no ;;
 esac
 ])# AC_LIBTOOL_POSTDEP_PREDEP
 
-# AC_LIBTOOL_LANG_F77_CONFIG
-# ------------------------
-# Ensure that the configuration vars for the C compiler are
-# suitably defined.  Those variables are subsequently used by
-# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
-#AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)])
-#AC_DEFUN([_LT_AC_LANG_F77_CONFIG],
-#[AC_REQUIRE([AC_PROG_F77])
-#AC_LANG_SAVE
-#AC_LANG_FORTRAN77
-#
-#_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
-#_LT_AC_TAGVAR(allow_undefined_flag, $1)=
-#_LT_AC_TAGVAR(always_export_symbols, $1)=no
-#_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
-#_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
-#_LT_AC_TAGVAR(hardcode_direct, $1)=no
-#_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
-#_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
-#_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
-#_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
-#_LT_AC_TAGVAR(hardcode_automatic, $1)=no
-#_LT_AC_TAGVAR(module_cmds, $1)=
-#_LT_AC_TAGVAR(module_expsym_cmds, $1)=
-#_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
-#_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
-#_LT_AC_TAGVAR(no_undefined_flag, $1)=
-#_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
-#_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
-#
-## Source file extension for f77 test sources.
-#ac_ext=f
-#
-## Object file extension for compiled f77 test sources.
-#objext=o
-#_LT_AC_TAGVAR(objext, $1)=$objext
-#
-## Code to be used in simple compile tests
-#lt_simple_compile_test_code="      subroutine t\n      return\n      end\n"
-#
-## Code to be used in simple link tests
-#lt_simple_link_test_code="      program t\n      end\n"
-#
-## ltmain only uses $CC for tagged configurations so make sure $CC is set.
-#_LT_AC_SYS_COMPILER
-#
-## save warnings/boilerplate of simple test code
-#_LT_COMPILER_BOILERPLATE
-#_LT_LINKER_BOILERPLATE
-#
-## Allow CC to be a program name with arguments.
-#lt_save_CC="$CC"
-#CC=${F77-"f77"}
-#compiler=$CC
-#_LT_AC_TAGVAR(compiler, $1)=$CC
-#_LT_CC_BASENAME([$compiler])
-#
-#AC_MSG_CHECKING([if libtool supports shared libraries])
-#AC_MSG_RESULT([$can_build_shared])
-#
-#AC_MSG_CHECKING([whether to build shared libraries])
-#test "$can_build_shared" = "no" && enable_shared=no
-#
-## On AIX, shared libraries and static libraries use the same namespace, and
-## are all built from PIC.
-#case "$host_os" in
-#aix3*)
-#  test "$enable_shared" = yes && enable_static=no
-#  if test -n "$RANLIB"; then
-#    archive_cmds="$archive_cmds~\$RANLIB \$lib"
-#    postinstall_cmds='$RANLIB $lib'
-#  fi
-#  ;;
-#aix4* | aix5*)
-#  if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
-#    test "$enable_shared" = yes && enable_static=no
-#  fi
-#  ;;
-#esac
-#AC_MSG_RESULT([$enable_shared])
-#
-#AC_MSG_CHECKING([whether to build static libraries])
-## Make sure either enable_shared or enable_static is yes.
-#test "$enable_shared" = yes || enable_static=yes
-#AC_MSG_RESULT([$enable_static])
-#
-#test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
-#
-#_LT_AC_TAGVAR(GCC, $1)="$G77"
-#_LT_AC_TAGVAR(LD, $1)="$LD"
-#
-#AC_LIBTOOL_PROG_COMPILER_PIC($1)
-#AC_LIBTOOL_PROG_CC_C_O($1)
-#AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
-#AC_LIBTOOL_PROG_LD_SHLIBS($1)
-#AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
-#AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
-#AC_LIBTOOL_SYS_LIB_STRIP
-#
-#
-#AC_LIBTOOL_CONFIG($1)
-#
-#AC_LANG_RESTORE
-#CC="$lt_save_CC"
-#])# AC_LIBTOOL_LANG_F77_CONFIG
-
-
-# AC_LIBTOOL_LANG_GCJ_CONFIG
-# --------------------------
-# Ensure that the configuration vars for the C compiler are
-# suitably defined.  Those variables are subsequently used by
-# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
-#AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
-#AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
-#[AC_LANG_SAVE
-#
-## Source file extension for Java test sources.
-#ac_ext=java
-#
-## Object file extension for compiled Java test sources.
-#objext=o
-#_LT_AC_TAGVAR(objext, $1)=$objext
-#
-## Code to be used in simple compile tests
-#lt_simple_compile_test_code="class foo {}\n"
-#
-## Code to be used in simple link tests
-#lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }\n'
-#
-## ltmain only uses $CC for tagged configurations so make sure $CC is set.
-#_LT_AC_SYS_COMPILER
-#
-## save warnings/boilerplate of simple test code
-#_LT_COMPILER_BOILERPLATE
-#_LT_LINKER_BOILERPLATE
-#
-## Allow CC to be a program name with arguments.
-#lt_save_CC="$CC"
-#CC=${GCJ-"gcj"}
-#compiler=$CC
-#_LT_AC_TAGVAR(compiler, $1)=$CC
-#_LT_CC_BASENAME([$compiler])
-#
-## GCJ did not exist at the time GCC didn't implicitly link libc in.
-#_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
-#
-#_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
-#
-### CAVEAT EMPTOR:
-### There is no encapsulation within the following macros, do not change
-### the running order or otherwise move them around unless you know exactly
-### what you are doing...
-#AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
-#AC_LIBTOOL_PROG_COMPILER_PIC($1)
-#AC_LIBTOOL_PROG_CC_C_O($1)
-#AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
-#AC_LIBTOOL_PROG_LD_SHLIBS($1)
-#AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
-#AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
-#AC_LIBTOOL_SYS_LIB_STRIP
-#AC_LIBTOOL_DLOPEN_SELF($1)
-#
-#AC_LIBTOOL_CONFIG($1)
-#
-#AC_LANG_RESTORE
-#CC="$lt_save_CC"
-#])# AC_LIBTOOL_LANG_GCJ_CONFIG
-
-
-# AC_LIBTOOL_LANG_RC_CONFIG
-# --------------------------
-# Ensure that the configuration vars for the Windows resource compiler are
-# suitably defined.  Those variables are subsequently used by
-# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
-#AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
-#AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
-#[AC_LANG_SAVE
-#
-## Source file extension for RC test sources.
-#ac_ext=rc
-#
-## Object file extension for compiled RC test sources.
-#objext=o
-#_LT_AC_TAGVAR(objext, $1)=$objext
-#
-## Code to be used in simple compile tests
-#lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
-#
-## Code to be used in simple link tests
-#lt_simple_link_test_code="$lt_simple_compile_test_code"
-#
-## ltmain only uses $CC for tagged configurations so make sure $CC is set.
-#_LT_AC_SYS_COMPILER
-#
-## save warnings/boilerplate of simple test code
-#_LT_COMPILER_BOILERPLATE
-#_LT_LINKER_BOILERPLATE
-#
-## Allow CC to be a program name with arguments.
-#lt_save_CC="$CC"
-#CC=${RC-"windres"}
-#compiler=$CC
-#_LT_AC_TAGVAR(compiler, $1)=$CC
-#_LT_CC_BASENAME([$compiler])
-#_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
-#
-#AC_LIBTOOL_CONFIG($1)
-#
-#AC_LANG_RESTORE
-#CC="$lt_save_CC"
-#])# AC_LIBTOOL_LANG_RC_CONFIG
-
-
 # AC_LIBTOOL_CONFIG([TAGNAME])
 # ----------------------------
 # If TAGNAME is not passed, then create an initial libtool script
@@ -4056,7 +4026,7 @@ if test -f "$ltmain"; then
   # Now quote all the things that may contain metacharacters while being
   # careful not to overquote the AC_SUBSTed values.  We take copies of the
   # variables and quote the copies for generation of the libtool script.
-  for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
+  for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
     SED SHELL STRIP \
     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
@@ -4083,6 +4053,7 @@ if test -f "$ltmain"; then
     _LT_AC_TAGVAR(predeps, $1) \
     _LT_AC_TAGVAR(postdeps, $1) \
     _LT_AC_TAGVAR(compiler_lib_search_path, $1) \
+    _LT_AC_TAGVAR(compiler_lib_search_dirs, $1) \
     _LT_AC_TAGVAR(archive_cmds, $1) \
     _LT_AC_TAGVAR(archive_expsym_cmds, $1) \
     _LT_AC_TAGVAR(postinstall_cmds, $1) \
@@ -4098,6 +4069,7 @@ if test -f "$ltmain"; then
     _LT_AC_TAGVAR(module_cmds, $1) \
     _LT_AC_TAGVAR(module_expsym_cmds, $1) \
     _LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1) \
+    _LT_AC_TAGVAR(fix_srcfile_path, $1) \
     _LT_AC_TAGVAR(exclude_expsyms, $1) \
     _LT_AC_TAGVAR(include_expsyms, $1); do
 
@@ -4145,7 +4117,7 @@ ifelse([$1], [],
 # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
 #
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
+# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
 # Free Software Foundation, Inc.
 #
 # This file is part of GNU Libtool:
@@ -4226,6 +4198,9 @@ AR_FLAGS=$lt_AR_FLAGS
 # A C compiler.
 LTCC=$lt_LTCC
 
+# LTCC compiler flags.
+LTCFLAGS=$lt_LTCFLAGS
+
 # A language-specific compiler.
 CC=$lt_[]_LT_AC_TAGVAR(compiler, $1)
 
@@ -4379,6 +4354,10 @@ predeps=$lt_[]_LT_AC_TAGVAR(predeps, $1)
 # shared library.
 postdeps=$lt_[]_LT_AC_TAGVAR(postdeps, $1)
 
+# The directories searched by this compiler when creating a shared
+# library
+compiler_lib_search_dirs=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_dirs, $1)
+
 # The library search path used internally by the compiler when linking
 # a shared library.
 compiler_lib_search_path=$lt_[]_LT_AC_TAGVAR(compiler_lib_search_path, $1)
@@ -4467,7 +4446,7 @@ sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
 
 # Fix the shell variable \$srcfile for the compiler.
-fix_srcfile_path="$_LT_AC_TAGVAR(fix_srcfile_path, $1)"
+fix_srcfile_path=$lt_fix_srcfile_path
 
 # Set to yes if exported symbols are required.
 always_export_symbols=$_LT_AC_TAGVAR(always_export_symbols, $1)
@@ -4550,6 +4529,7 @@ fi
 # ---------------------------------
 AC_DEFUN([AC_LIBTOOL_SYS_GLOBAL_SYMBOL_PIPE],
 [AC_REQUIRE([AC_CANONICAL_HOST])
+AC_REQUIRE([LT_AC_PROG_SED])
 AC_REQUIRE([AC_PROG_NM])
 AC_REQUIRE([AC_OBJEXT])
 # Check for command to grab the raw symbol name followed by C symbol from nm.
@@ -4586,7 +4566,7 @@ hpux*) # Its linker distinguishes data from code symbols
   lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
   lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([[^ ]]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([[^ ]]*\) \([[^ ]]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
   ;;
-linux*)
+linux* | k*bsd*-gnu)
   if test "$host_cpu" = ia64; then
     symcode='[[ABCDGIRSTW]]'
     lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
@@ -4599,9 +4579,18 @@ irix* | nonstopux*)
 osf*)
   symcode='[[BCDEGQRST]]'
   ;;
-solaris* | sysv5*)
+solaris*)
   symcode='[[BDRT]]'
   ;;
+sco3.2v5*)
+  symcode='[[DT]]'
+  ;;
+sysv4.2uw2*)
+  symcode='[[DT]]'
+  ;;
+sysv5* | sco5v6* | unixware* | OpenUNIX*)
+  symcode='[[ABDT]]'
+  ;;
 sysv4)
   symcode='[[DFNSTU]]'
   ;;
@@ -4718,7 +4707,7 @@ EOF
     echo "$progname: failed program was:" >&5
     cat conftest.$ac_ext >&5
   fi
-  rm -f conftest* conftst*
+  rm -rf conftest* conftst*
 
   # Do not use the global_symbol_pipe unless it works.
   if test "$pipe_works" = yes; then
@@ -4767,13 +4756,15 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       # like `-m68040'.
       _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
       ;;
-    beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
+    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
       # PIC is the default for these OSes.
       ;;
-    mingw* | os2* | pw32*)
+    mingw* | cygwin* | os2* | pw32*)
       # This hack is so that the source file can tell whether it is being
       # built for inclusion in a dll (and should export symbols for example).
-      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
+      # Although the cygwin gcc ignores -fPIC, still need this for old-style
+      # (--disable-auto-import) libraries
+	  _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
       ;;
     darwin* | rhapsody*)
       # PIC is the default on this platform
@@ -4784,6 +4775,10 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       # DJGPP does not support shared libraries at all
       _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=
       ;;
+    interix[[3-9]]*)
+      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
+      # Instead, we relocate shared libraries at runtime.
+      ;;
     sysv4*MP*)
       if test -d /usr/nec; then
 	_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)=-Kconform_pic
@@ -4806,7 +4801,7 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
     esac
   else
     case $host_os in
-      aix4* | aix5*)
+      aix[[4-9]]*)
 	# All AIX code is PIC.
 	if test "$host_cpu" = ia64; then
 	  # AIX 5 now supports IA64 processor
@@ -4846,21 +4841,21 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
 	    ;;
 	esac
 	;;
-      freebsd* | kfreebsd*-gnu | dragonfly*)
+      freebsd* | dragonfly*)
 	# FreeBSD uses GNU C++
 	;;
       hpux9* | hpux10* | hpux11*)
 	case $cc_basename in
 	  CC*)
 	    _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
+	    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
 	    if test "$host_cpu" != ia64; then
 	      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='+Z'
 	    fi
 	    ;;
 	  aCC*)
 	    _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
-	    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
+	    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='${wl}-a ${wl}archive'
 	    case $host_cpu in
 	    hppa*64*|ia64*)
 	      # +Z the default
@@ -4874,6 +4869,10 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
 	    ;;
 	esac
 	;;
+      interix*)
+	# This is c89, which is MS Visual C++ (no shared libs)
+	# Anyone wants to do a port?
+	;;
       irix5* | irix6* | nonstopux*)
 	case $cc_basename in
 	  CC*)
@@ -4885,7 +4884,7 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
 	    ;;
 	esac
 	;;
-      linux*)
+      linux* | k*bsd*-gnu)
 	case $cc_basename in
 	  KCC*)
 	    # KAI C++ Compiler
@@ -4904,7 +4903,7 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
         _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
         _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-static'
         ;;
-	  pgCC*)
+	  pgCC* | pgcpp*)
 	    # Portland Group C++ compiler.
 	    _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
 	    _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fpic'
@@ -4918,6 +4917,14 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
 	    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
 	    ;;
 	  *)
+	    case `$CC -V 2>&1 | sed 5q` in
+	    *Sun\ C*)
+	      # Sun C++ 5.9
+	      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
+	      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
+	      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Qoption ld '
+	      ;;
+	    esac
 	    ;;
 	esac
 	;;
@@ -4959,15 +4966,6 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
 	;;
       psos*)
 	;;
-      sco*)
-	case $cc_basename in
-	  CC*)
-	    _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fPIC'
-	    ;;
-	  *)
-	    ;;
-	esac
-	;;
       solaris*)
 	case $cc_basename in
 	  CC*)
@@ -5009,7 +5007,14 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
 	    ;;
 	esac
 	;;
-      unixware*)
+      sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
+	case $cc_basename in
+	  CC*)
+	    _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
+	    _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
+	    _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
+	    ;;
+	esac
 	;;
       vxworks*)
 	;;
@@ -5040,14 +5045,16 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-m68020 -resident32 -malways-restore-a4'
       ;;
 
-    beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
+    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
       # PIC is the default for these OSes.
       ;;
 
-    mingw* | pw32* | os2*)
+    mingw* | cygwin* | pw32* | os2*)
       # This hack is so that the source file can tell whether it is being
       # built for inclusion in a dll (and should export symbols for example).
-      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
+      # Although the cygwin gcc ignores -fPIC, still need this for old-style
+      # (--disable-auto-import) libraries
+	  _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
       ;;
 
     darwin* | rhapsody*)
@@ -5056,6 +5063,11 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-fno-common'
       ;;
 
+    interix[[3-9]]*)
+      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
+      # Instead, we relocate shared libraries at runtime.
+      ;;
+
     msdosdjgpp*)
       # Just because we use GCC doesn't mean we suddenly get shared libraries
       # on systems that don't support them.
@@ -5109,10 +5121,10 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
        esac
        ;;
 
-    mingw* | pw32* | os2*)
+    mingw* | cygwin* | pw32* | os2*)
       # This hack is so that the source file can tell whether it is being
       # built for inclusion in a dll (and should export symbols for example).
-      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
+	  _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-DDLL_EXPORT'
       ;;
 
     hpux9* | hpux10* | hpux11*)
@@ -5142,7 +5154,7 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
       ;;
 
-    linux*)
+    linux* | k*bsd*-gnu)
       case $cc_basename in
       # old Intel for x86_64 which still supported -KPIC.
       ecc*)
@@ -5169,6 +5181,22 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
         # All Alpha code is PIC.
         _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
         ;;
+      *)
+        case `$CC -V 2>&1 | sed 5q` in
+	*Sun\ C*)
+	  # Sun C 5.9
+	  _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
+	  _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
+	  _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
+	  ;;
+	*Sun\ F*)
+	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
+	  _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
+	  _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
+	  _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)=''
+	  ;;
+	esac
+	;;
       esac
       ;;
 
@@ -5178,9 +5206,8 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
       ;;
 
-    sco3.2v5*)
-      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-Kpic'
-      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-dn'
+    rdos*)
+      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-non_shared'
       ;;
 
     solaris*)
@@ -5200,7 +5227,7 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
       ;;
 
-    sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
+    sysv4 | sysv4.2uw2* | sysv4.3*)
       _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
       _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
       _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
@@ -5213,6 +5240,12 @@ AC_MSG_CHECKING([for $compiler option to produce PIC])
       fi
       ;;
 
+    sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
+      _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
+      _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)='-KPIC'
+      _LT_AC_TAGVAR(lt_prog_compiler_static, $1)='-Bstatic'
+      ;;
+
     unicos*)
       _LT_AC_TAGVAR(lt_prog_compiler_wl, $1)='-Wl,'
       _LT_AC_TAGVAR(lt_prog_compiler_can_build_shared, $1)=no
@@ -5236,7 +5269,7 @@ AC_MSG_RESULT([$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)])
 #
 if test -n "$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)"; then
   AC_LIBTOOL_COMPILER_OPTION([if $compiler PIC flag $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) works],
-    _LT_AC_TAGVAR(lt_prog_compiler_pic_works, $1),
+    _LT_AC_TAGVAR(lt_cv_prog_compiler_pic_works, $1),
     [$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])], [],
     [case $_LT_AC_TAGVAR(lt_prog_compiler_pic, $1) in
      "" | " "*) ;;
@@ -5254,6 +5287,16 @@ case $host_os in
     _LT_AC_TAGVAR(lt_prog_compiler_pic, $1)="$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)ifelse([$1],[],[ -DPIC],[ifelse([$1],[CXX],[ -DPIC],[])])"
     ;;
 esac
+
+#
+# Check to make sure the static flag actually works.
+#
+wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1) eval lt_tmp_static_flag=\"$_LT_AC_TAGVAR(lt_prog_compiler_static, $1)\"
+AC_LIBTOOL_LINKER_OPTION([if $compiler static flag $lt_tmp_static_flag works],
+  _LT_AC_TAGVAR(lt_cv_prog_compiler_static_works, $1),
+  $lt_tmp_static_flag,
+  [],
+  [_LT_AC_TAGVAR(lt_prog_compiler_static, $1)=])
 ])
 
 
@@ -5261,11 +5304,12 @@ esac
 # ------------------------------------
 # See if the linker supports building shared libraries.
 AC_DEFUN([AC_LIBTOOL_PROG_LD_SHLIBS],
-[AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
+[AC_REQUIRE([LT_AC_PROG_SED])dnl
+AC_MSG_CHECKING([whether the $compiler linker ($LD) supports shared libraries])
 ifelse([$1],[CXX],[
   _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
   case $host_os in
-  aix4* | aix5*)
+  aix[[4-9]]*)
     # If we're using GNU nm, then we don't want the "-C" option.
     # -C means demangle to AIX nm, but means don't demangle with GNU nm
     if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
@@ -5278,12 +5322,13 @@ ifelse([$1],[CXX],[
     _LT_AC_TAGVAR(export_symbols_cmds, $1)="$ltdll_cmds"
   ;;
   cygwin* | mingw*)
-    _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/;/^.* __nm__/s/^.* __nm__\([[^ ]]*\) [[^ ]]*/\1 DATA/;/^I /d;/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
+    _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/;/^.*[[ ]]__nm__/s/^.*[[ ]]__nm__\([[^ ]]*\)[[ ]][[^ ]]*/\1 DATA/;/^I[[ ]]/d;/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
   ;;
   *)
     _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
   ;;
   esac
+  _LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
 ],[
   runpath_var=
   _LT_AC_TAGVAR(allow_undefined_flag, $1)=
@@ -5314,12 +5359,14 @@ ifelse([$1],[CXX],[
   # it will be wrapped by ` (' and `)$', so one must not match beginning or
   # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
   # as well as any symbol that contains `d'.
-  _LT_AC_TAGVAR(exclude_expsyms, $1)="_GLOBAL_OFFSET_TABLE_"
+  _LT_AC_TAGVAR(exclude_expsyms, $1)=['_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*']
   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
   # platforms (ab)use it in PIC code, but their linkers get confused if
   # the symbol is explicitly referenced.  Since portable code cannot
   # rely on this symbol name, it's probably fine to never include it in
   # preloaded symbol tables.
+  # Exclude shared library initialization/finalization symbols.
+dnl Note also adjust exclude_expsyms for C++ above.
   extract_expsyms_cmds=
   # Just being paranoid about ensuring that cc_basename is set.
   _LT_CC_BASENAME([$compiler])
@@ -5332,6 +5379,10 @@ ifelse([$1],[CXX],[
       with_gnu_ld=no
     fi
     ;;
+  interix*)
+    # we just hope/assume this is gcc and not c89 (= MSVC++)
+    with_gnu_ld=yes
+    ;;
   openbsd*)
     with_gnu_ld=no
     ;;
@@ -5341,7 +5392,7 @@ ifelse([$1],[CXX],[
   if test "$with_gnu_ld" = yes; then
     # If archive_cmds runs LD, not CC, wlarc should be empty
     wlarc='${wl}'
-    
+
     # Set some defaults for GNU ld with shared library support. These
     # are reset later if shared libraries are not supported. Putting them
     # here allows them to be overridden if necessary.
@@ -5362,10 +5413,10 @@ ifelse([$1],[CXX],[
       *\ 2.11.*) ;; # other 2.11 versions
       *) supports_anon_versioning=yes ;;
     esac
-    
+
     # See if GNU ld supports shared libraries.
     case $host_os in
-    aix3* | aix4* | aix5*)
+    aix[[3-9]]*)
       # On AIX/PPC, the GNU linker is very broken
       if test "$host_cpu" != ia64; then
 	_LT_AC_TAGVAR(ld_shlibs, $1)=no
@@ -5413,10 +5464,10 @@ EOF
       _LT_AC_TAGVAR(allow_undefined_flag, $1)=unsupported
       _LT_AC_TAGVAR(always_export_symbols, $1)=no
       _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
-      _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]] /s/.* \([[^ ]]*\)/\1 DATA/'\'' | $SED -e '\''/^[[AITW]] /s/.* //'\'' | sort | uniq > $export_symbols'
+      _LT_AC_TAGVAR(export_symbols_cmds, $1)='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[[BCDGRS]][[ ]]/s/.*[[ ]]\([[^ ]]*\)/\1 DATA/'\'' -e '\''/^[[AITW]][[ ]]/s/.*[[ ]]//'\'' | sort | uniq > $export_symbols'
 
       if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
-        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
+        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
 	# If the export-symbols file already is a .def file (1st line
 	# is EXPORTS), use it as is; otherwise, prepend...
 	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
@@ -5425,13 +5476,28 @@ EOF
 	  echo EXPORTS > $output_objdir/$soname.def;
 	  cat $export_symbols >> $output_objdir/$soname.def;
 	fi~
-	$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000  ${wl}--out-implib,$lib'
+	$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
       else
 	_LT_AC_TAGVAR(ld_shlibs, $1)=no
       fi
       ;;
 
-    linux*)
+    interix[[3-9]]*)
+      _LT_AC_TAGVAR(hardcode_direct, $1)=no
+      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
+      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
+      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
+      # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
+      # Instead, shared libraries are loaded at an image base (0x10000000 by
+      # default) and relocated if they conflict, which is a slow very memory
+      # consuming and fragmenting process.  To avoid this, we pick a random,
+      # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
+      # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
+      _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
+      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
+      ;;
+
+    gnu* | linux* | k*bsd*-gnu)
       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
 	tmp_addflag=
 	case $cc_basename,$host_cpu in
@@ -5439,7 +5505,7 @@ EOF
 	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
 	  tmp_addflag=' $pic_flag'
 	  ;;
-	pgf77* | pgf90* | pgf95*)			# Portland Group f77 and f90 compilers
+	pgf77* | pgf90* | pgf95*)	# Portland Group f77 and f90 compilers
 	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
 	  tmp_addflag=' $pic_flag -Mnomain' ;;
 	ecc*,ia64* | icc*,ia64*)		# Intel C compiler on ia64
@@ -5449,13 +5515,22 @@ EOF
 	ifc* | ifort*)			# Intel Fortran compiler
 	  tmp_addflag=' -nofor_main' ;;
 	esac
-	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	case `$CC -V 2>&1 | sed 5q` in
+	*Sun\ C*)			# Sun C 5.9
+	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
+	  tmp_sharedflag='-G' ;;
+	*Sun\ F*)			# Sun Fortran 8.3
+	  tmp_sharedflag='-G' ;;
+	*)
+	  tmp_sharedflag='-shared' ;;
+	esac
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
 	if test $supports_anon_versioning = yes; then
 	  _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $output_objdir/$libname.ver~
   cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
   $echo "local: *; };" >> $output_objdir/$libname.ver~
-	  $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
+	  $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
 	fi
       else
 	_LT_AC_TAGVAR(ld_shlibs, $1)=no
@@ -5472,7 +5547,7 @@ EOF
       fi
       ;;
 
-    solaris* | sysv5*)
+    solaris*)
       if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
 	_LT_AC_TAGVAR(ld_shlibs, $1)=no
 	cat <<EOF 1>&2
@@ -5493,6 +5568,33 @@ EOF
       fi
       ;;
 
+    sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
+      case `$LD -v 2>&1` in
+        *\ [[01]].* | *\ 2.[[0-9]].* | *\ 2.1[[0-5]].*)
+	_LT_AC_TAGVAR(ld_shlibs, $1)=no
+	cat <<_LT_EOF 1>&2
+
+*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
+*** reliably create shared libraries on SCO systems.  Therefore, libtool
+*** is disabling shared libraries support.  We urge you to upgrade GNU
+*** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
+*** your PATH or compiler configuration so that the native linker is
+*** used, and then restart.
+
+_LT_EOF
+	;;
+	*)
+	  if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
+	    _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
+	    _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
+	    _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib'
+	  else
+	    _LT_AC_TAGVAR(ld_shlibs, $1)=no
+	  fi
+	;;
+      esac
+      ;;
+
     sunos4*)
       _LT_AC_TAGVAR(archive_cmds, $1)='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
       wlarc=
@@ -5526,14 +5628,14 @@ EOF
       # Note: this linker hardcodes the directories in LIBPATH if there
       # are no directories specified by -L.
       _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
-      if test "$GCC" = yes && test -z "$link_static_flag"; then
+      if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
 	# Neither direct hardcoding nor static linking is supported with a
 	# broken collect2.
 	_LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
       fi
       ;;
 
-    aix4* | aix5*)
+    aix[[4-9]]*)
       if test "$host_cpu" = ia64; then
 	# On IA64, the linker does run time linking by default, so we don't
 	# have to do anything special.
@@ -5553,13 +5655,14 @@ EOF
 	# Test if we are trying to use run time linking or normal
 	# AIX style linking. If -brtl is somewhere in LDFLAGS, we
 	# need to do runtime linking.
-	case $host_os in aix4.[[23]]|aix4.[[23]].*|aix5*)
+	case $host_os in aix4.[[23]]|aix4.[[23]].*|aix[[5-9]]*)
 	  for ld_flag in $LDFLAGS; do
   	  if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
   	    aix_use_runtimelinking=yes
   	    break
   	  fi
 	  done
+	  ;;
 	esac
 
 	exp_sym_flag='-bexport'
@@ -5586,7 +5689,7 @@ EOF
   	   strings "$collect2name" | grep resolve_lib_name >/dev/null
 	  then
   	  # We have reworked collect2
-  	  _LT_AC_TAGVAR(hardcode_direct, $1)=yes
+  	  :
 	  else
   	  # We have old collect2
   	  _LT_AC_TAGVAR(hardcode_direct, $1)=unsupported
@@ -5597,6 +5700,7 @@ EOF
   	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
   	  _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
 	  fi
+	  ;;
 	esac
 	shared_flag='-shared'
 	if test "$aix_use_runtimelinking" = yes; then
@@ -5609,11 +5713,11 @@ EOF
   	# chokes on -Wl,-G. The following line is correct:
 	  shared_flag='-G'
 	else
-  	if test "$aix_use_runtimelinking" = yes; then
+	  if test "$aix_use_runtimelinking" = yes; then
 	    shared_flag='${wl}-G'
 	  else
 	    shared_flag='${wl}-bM:SRE'
-  	fi
+	  fi
 	fi
       fi
 
@@ -5627,12 +5731,12 @@ EOF
        # Determine the default libpath from the value encoded in an empty executable.
        _LT_AC_SYS_LIBPATH_AIX
        _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-blibpath:$libdir:'"$aix_libpath"
-	_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
        else
 	if test "$host_cpu" = ia64; then
 	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-R $libdir:/usr/lib:/lib'
 	  _LT_AC_TAGVAR(allow_undefined_flag, $1)="-z nodefs"
-	  _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
+	  _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
 	else
 	 # Determine the default libpath from the value encoded in an empty executable.
 	 _LT_AC_SYS_LIBPATH_AIX
@@ -5641,13 +5745,11 @@ EOF
 	  # -berok will link without error, but may produce a broken library.
 	  _LT_AC_TAGVAR(no_undefined_flag, $1)=' ${wl}-bernotok'
 	  _LT_AC_TAGVAR(allow_undefined_flag, $1)=' ${wl}-berok'
-	  # -bexpall does not export symbols beginning with underscore (_)
-	  _LT_AC_TAGVAR(always_export_symbols, $1)=yes
 	  # Exported symbols can be pulled into shared objects from archives
-	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)=' '
+	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='$convenience'
 	  _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=yes
 	  # This is similar to how AIX traditionally builds its shared libraries.
-	  _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
+	  _LT_AC_TAGVAR(archive_expsym_cmds, $1)="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
 	fi
       fi
       ;;
@@ -5680,7 +5782,7 @@ EOF
       # The linker will automatically build a .lib file if we build a DLL.
       _LT_AC_TAGVAR(old_archive_From_new_cmds, $1)='true'
       # FIXME: Should let the user specify the lib program.
-      _LT_AC_TAGVAR(old_archive_cmds, $1)='lib /OUT:$oldlib$oldobjs$old_deplibs'
+      _LT_AC_TAGVAR(old_archive_cmds, $1)='lib -OUT:$oldlib$oldobjs$old_deplibs'
       _LT_AC_TAGVAR(fix_srcfile_path, $1)='`cygpath -w "$srcfile"`'
       _LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=yes
       ;;
@@ -5713,19 +5815,18 @@ EOF
       _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
     if test "$GCC" = yes ; then
     	output_verbose_link_cmd='echo'
-        _LT_AC_TAGVAR(archive_cmds, $1)='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
-      _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
-      # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
-      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
-      _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
+        _LT_AC_TAGVAR(archive_cmds, $1)="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
+        _LT_AC_TAGVAR(module_cmds, $1)="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
+        _LT_AC_TAGVAR(archive_expsym_cmds, $1)="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
+        _LT_AC_TAGVAR(module_expsym_cmds, $1)="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
     else
       case $cc_basename in
         xlc*)
          output_verbose_link_cmd='echo'
-         _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
+         _LT_AC_TAGVAR(archive_cmds, $1)='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
          _LT_AC_TAGVAR(module_cmds, $1)='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
           # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
-         _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
+         _LT_AC_TAGVAR(archive_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
           _LT_AC_TAGVAR(module_expsym_cmds, $1)='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
           ;;
        *)
@@ -5765,7 +5866,7 @@ EOF
       ;;
 
     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
-    freebsd* | kfreebsd*-gnu | dragonfly*)
+    freebsd* | dragonfly*)
       _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
       _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
       _LT_AC_TAGVAR(hardcode_direct, $1)=yes
@@ -5788,47 +5889,62 @@ EOF
       _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
       ;;
 
-    hpux10* | hpux11*)
+    hpux10*)
+      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+      else
+	_LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
+      fi
+      if test "$with_gnu_ld" = no; then
+	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
+	_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
+
+	_LT_AC_TAGVAR(hardcode_direct, $1)=yes
+	_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
+
+	# hardcode_minus_L: Not really in the search PATH,
+	# but as the default location of the library.
+	_LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
+      fi
+      ;;
+
+    hpux11*)
       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
 	case $host_cpu in
-	hppa*64*|ia64*)
+	hppa*64*)
 	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
+	ia64*)
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
+	  ;;
 	*)
 	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	esac
       else
 	case $host_cpu in
-	hppa*64*|ia64*)
-	  _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags'
+	hppa*64*)
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	  ;;
+	ia64*)
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	*)
-	  _LT_AC_TAGVAR(archive_cmds, $1)='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	esac
       fi
       if test "$with_gnu_ld" = no; then
+	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
+	_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
+
 	case $host_cpu in
-	hppa*64*)
-	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
+	hppa*64*|ia64*)
 	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)='+b $libdir'
-	  _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 	  _LT_AC_TAGVAR(hardcode_direct, $1)=no
 	  _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
 	  ;;
-	ia64*)
-	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-L$libdir'
-	  _LT_AC_TAGVAR(hardcode_direct, $1)=no
-	  _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-
-	  # hardcode_minus_L: Not really in the search PATH,
-	  # but as the default location of the library.
-	  _LT_AC_TAGVAR(hardcode_minus_L, $1)=yes
-	  ;;
 	*)
-	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}+b ${wl}$libdir'
-	  _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
 	  _LT_AC_TAGVAR(hardcode_direct, $1)=yes
 	  _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
 
@@ -5872,24 +5988,28 @@ EOF
       ;;
 
     openbsd*)
-      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
-      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-      if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
-	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
-	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
-	_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
-	_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
+      if test -f /usr/libexec/ld.so; then
+	_LT_AC_TAGVAR(hardcode_direct, $1)=yes
+	_LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
+	if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
+	  _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
+	  _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
+	  _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
+	  _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-E'
+	else
+	  case $host_os in
+	   openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
+	     _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
+	     _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
+	     ;;
+	   *)
+	     _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
+	     _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
+	     ;;
+	  esac
+        fi
       else
-       case $host_os in
-	 openbsd[[01]].* | openbsd2.[[0-7]] | openbsd2.[[0-7]].*)
-	   _LT_AC_TAGVAR(archive_cmds, $1)='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
-	   _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='-R$libdir'
-	   ;;
-	 *)
-	   _LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
-	   _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='${wl}-rpath,$libdir'
-	   ;;
-       esac
+	_LT_AC_TAGVAR(ld_shlibs, $1)=no
       fi
       ;;
 
@@ -5930,14 +6050,6 @@ EOF
       _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=:
       ;;
 
-    sco3.2v5*)
-      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
-      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
-      runpath_var=LD_RUN_PATH
-      hardcode_runpath_var=yes
-      ;;
-
     solaris*)
       _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
       if test "$GCC" = yes; then
@@ -5956,17 +6068,16 @@ EOF
       case $host_os in
       solaris2.[[0-5]] | solaris2.[[0-5]].*) ;;
       *)
- 	# The compiler driver will combine linker options so we
- 	# cannot just pass the convience library names through
- 	# without $wl, iff we do not link with $LD.
- 	# Luckily, gcc supports the same syntax we need for Sun Studio.
+	# The compiler driver will combine and reorder linker options,
+	# but understands `-z linker_flag'.  GCC discards it without `$wl',
+	# but is careful enough not to reorder.
  	# Supported since Solaris 2.6 (maybe 2.5.1?)
- 	case $wlarc in
- 	'')
- 	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract' ;;
- 	*)
- 	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;;
- 	esac ;;
+	if test "$GCC" = yes; then
+	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
+	else
+	  _LT_AC_TAGVAR(whole_archive_flag_spec, $1)='-z allextract$convenience -z defaultextract'
+	fi
+	;;
       esac
       _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
       ;;
@@ -6023,36 +6134,45 @@ EOF
       fi
       ;;
 
-    sysv4.2uw2*)
-      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G -o $lib $libobjs $deplibs $linker_flags'
-      _LT_AC_TAGVAR(hardcode_direct, $1)=yes
-      _LT_AC_TAGVAR(hardcode_minus_L, $1)=no
+    sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[[01]].[[10]]* | unixware7* | sco3.2v5.0.[[024]]*)
+      _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
+      _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
       _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
-      hardcode_runpath_var=yes
-      runpath_var=LD_RUN_PATH
-      ;;
+      runpath_var='LD_RUN_PATH'
 
-   sysv5OpenUNIX8* | sysv5UnixWare7* |  sysv5uw[[78]]* | unixware7*)
-      _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z ${wl}text'
       if test "$GCC" = yes; then
-	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
       else
-	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
       fi
-      runpath_var='LD_RUN_PATH'
-      _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
       ;;
 
-    sysv5*)
-      _LT_AC_TAGVAR(no_undefined_flag, $1)=' -z text'
-      # $CC -shared without GNU ld will not create a library from C++
-      # object files and a static libstdc++, better avoid it by now
-      _LT_AC_TAGVAR(archive_cmds, $1)='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
-      _LT_AC_TAGVAR(archive_expsym_cmds, $1)='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
-  		$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
-      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
+    sysv5* | sco3.2v5* | sco5v6*)
+      # Note: We can NOT use -z defs as we might desire, because we do not
+      # link with -lc, and that would cause any symbols used from libc to
+      # always be unresolved, which means just about no library would
+      # ever link correctly.  If we're not using GNU ld we use -z text
+      # though, which does catch some bad symbols but isn't as heavy-handed
+      # as -z defs.
+      _LT_AC_TAGVAR(no_undefined_flag, $1)='${wl}-z,text'
+      _LT_AC_TAGVAR(allow_undefined_flag, $1)='${wl}-z,nodefs'
+      _LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
       _LT_AC_TAGVAR(hardcode_shlibpath_var, $1)=no
+      _LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
+      _LT_AC_TAGVAR(hardcode_libdir_separator, $1)=':'
+      _LT_AC_TAGVAR(link_all_deplibs, $1)=yes
+      _LT_AC_TAGVAR(export_dynamic_flag_spec, $1)='${wl}-Bexport'
       runpath_var='LD_RUN_PATH'
+
+      if test "$GCC" = yes; then
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+      else
+	_LT_AC_TAGVAR(archive_cmds, $1)='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	_LT_AC_TAGVAR(archive_expsym_cmds, $1)='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+      fi
       ;;
 
     uts4*)
@@ -6070,11 +6190,6 @@ EOF
 AC_MSG_RESULT([$_LT_AC_TAGVAR(ld_shlibs, $1)])
 test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
 
-variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
-if test "$GCC" = yes; then
-  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
-fi
-
 #
 # Do we need to explicitly link libc?
 #
@@ -6094,7 +6209,7 @@ x|xyes)
       # to ld, don't add -lc before -lgcc.
       AC_MSG_CHECKING([whether -lc should be explicitly linked in])
       $rm conftest*
-      printf "$lt_simple_compile_test_code" > conftest.$ac_ext
+      echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
       if AC_TRY_EVAL(ac_compile) 2>conftest.err; then
         soname=conftest
@@ -6102,6 +6217,7 @@ x|xyes)
         libobjs=conftest.$ac_objext
         deplibs=
         wl=$_LT_AC_TAGVAR(lt_prog_compiler_wl, $1)
+	pic_flag=$_LT_AC_TAGVAR(lt_prog_compiler_pic, $1)
         compiler_flags=-v
         linker_flags=-v
         verstring=
@@ -6186,16 +6302,6 @@ AC_DEFUN([AM_PROG_NM],        [AC_PROG_NM])
 # This is just to silence aclocal about the macro not being used
 ifelse([AC_DISABLE_FAST_INSTALL])
 
-#AC_DEFUN([LT_AC_PROG_GCJ],
-#[AC_CHECK_TOOL(GCJ, gcj, no)
-#  test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
-#  AC_SUBST(GCJFLAGS)
-#])
-
-#AC_DEFUN([LT_AC_PROG_RC],
-#[AC_CHECK_TOOL(RC, windres, no)
-#])
-
 ############################################################
 # NOTE: This macro has been submitted for inclusion into   #
 #  GNU Autoconf as AC_PROG_SED.  When it is available in   #
diff --git a/config.guess b/config.guess
index ad5281e..f32079a 100644
--- a/config.guess
+++ b/config.guess
@@ -1,9 +1,10 @@
 #! /bin/sh
 # Attempt to guess a canonical system name.
 #   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-#   2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
+#   2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
+#   Free Software Foundation, Inc.
 
-timestamp='2005-08-03'
+timestamp='2008-01-23'
 
 # This file is free software; you can redistribute it and/or modify it
 # under the terms of the GNU General Public License as published by
@@ -55,8 +56,8 @@ version="\
 GNU config.guess ($timestamp)
 
 Originally written by Per Bothner.
-Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
-Free Software Foundation, Inc.
+Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
+2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 This is free software; see the source for copying conditions.  There is NO
 warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
@@ -106,7 +107,7 @@ set_cc_for_build='
 trap "exitcode=\$?; (rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null) && exit \$exitcode" 0 ;
 trap "rm -f \$tmpfiles 2>/dev/null; rmdir \$tmp 2>/dev/null; exit 1" 1 2 13 15 ;
 : ${TMPDIR=/tmp} ;
- { tmp=`(umask 077 && mktemp -d -q "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
+ { tmp=`(umask 077 && mktemp -d "$TMPDIR/cgXXXXXX") 2>/dev/null` && test -n "$tmp" && test -d "$tmp" ; } ||
  { test -n "$RANDOM" && tmp=$TMPDIR/cg$$-$RANDOM && (umask 077 && mkdir $tmp) ; } ||
  { tmp=$TMPDIR/cg-$$ && (umask 077 && mkdir $tmp) && echo "Warning: creating insecure temp directory" >&2 ; } ||
  { echo "$me: cannot create a temporary directory in $TMPDIR" >&2 ; exit 1 ; } ;
@@ -160,6 +161,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
 	    arm*) machine=arm-unknown ;;
 	    sh3el) machine=shl-unknown ;;
 	    sh3eb) machine=sh-unknown ;;
+	    sh5el) machine=sh5le-unknown ;;
 	    *) machine=${UNAME_MACHINE_ARCH}-unknown ;;
 	esac
 	# The Operating System including object format, if it has switched
@@ -206,8 +208,11 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
     *:ekkoBSD:*:*)
 	echo ${UNAME_MACHINE}-unknown-ekkobsd${UNAME_RELEASE}
 	exit ;;
+    *:SolidBSD:*:*)
+	echo ${UNAME_MACHINE}-unknown-solidbsd${UNAME_RELEASE}
+	exit ;;
     macppc:MirBSD:*:*)
-	echo powerppc-unknown-mirbsd${UNAME_RELEASE}
+	echo powerpc-unknown-mirbsd${UNAME_RELEASE}
 	exit ;;
     *:MirBSD:*:*)
 	echo ${UNAME_MACHINE}-unknown-mirbsd${UNAME_RELEASE}
@@ -325,7 +330,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in
     sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*)
 	echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
 	exit ;;
-    i86pc:SunOS:5.*:*)
+    i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*)
 	echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'`
 	exit ;;
     sun4*:SunOS:6*:*)
@@ -527,7 +532,7 @@ EOF
 		echo rs6000-ibm-aix3.2
 	fi
 	exit ;;
-    *:AIX:*:[45])
+    *:AIX:*:[456])
 	IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'`
 	if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then
 		IBM_ARCH=rs6000
@@ -764,12 +769,19 @@ EOF
 	echo ${UNAME_MACHINE}-unknown-bsdi${UNAME_RELEASE}
 	exit ;;
     *:FreeBSD:*:*)
-	echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'`
+	case ${UNAME_MACHINE} in
+	    pc98)
+		echo i386-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
+	    amd64)
+		echo x86_64-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
+	    *)
+		echo ${UNAME_MACHINE}-unknown-freebsd`echo ${UNAME_RELEASE}|sed -e 's/[-(].*//'` ;;
+	esac
 	exit ;;
     i*:CYGWIN*:*)
 	echo ${UNAME_MACHINE}-pc-cygwin
 	exit ;;
-    i*:MINGW*:*)
+    *:MINGW*:*)
 	echo ${UNAME_MACHINE}-pc-mingw32
 	exit ;;
     i*:windows32*:*)
@@ -779,9 +791,18 @@ EOF
     i*:PW*:*)
 	echo ${UNAME_MACHINE}-pc-pw32
 	exit ;;
-    x86:Interix*:[34]*)
-	echo i586-pc-interix${UNAME_RELEASE}|sed -e 's/\..*//'
-	exit ;;
+    *:Interix*:[3456]*)
+    	case ${UNAME_MACHINE} in
+	    x86)
+		echo i586-pc-interix${UNAME_RELEASE}
+		exit ;;
+	    EM64T | authenticamd)
+		echo x86_64-unknown-interix${UNAME_RELEASE}
+		exit ;;
+	    IA64)
+		echo ia64-unknown-interix${UNAME_RELEASE}
+		exit ;;
+	esac ;;
     [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*)
 	echo i${UNAME_MACHINE}-pc-mks
 	exit ;;
@@ -815,6 +836,16 @@ EOF
 	echo ${UNAME_MACHINE}-pc-minix
 	exit ;;
     arm*:Linux:*:*)
+	eval $set_cc_for_build
+	if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \
+	    | grep -q __ARM_EABI__
+	then
+	    echo ${UNAME_MACHINE}-unknown-linux-gnu
+	else
+	    echo ${UNAME_MACHINE}-unknown-linux-gnueabi
+	fi
+	exit ;;
+    avr32*:Linux:*:*)
 	echo ${UNAME_MACHINE}-unknown-linux-gnu
 	exit ;;
     cris:Linux:*:*)
@@ -851,7 +882,11 @@ EOF
 	#endif
 	#endif
 EOF
-	eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
+	eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
+	    /^CPU/{
+		s: ::g
+		p
+	    }'`"
 	test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
 	;;
     mips64:Linux:*:*)
@@ -870,7 +905,11 @@ EOF
 	#endif
 	#endif
 EOF
-	eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^CPU=`
+	eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
+	    /^CPU/{
+		s: ::g
+		p
+	    }'`"
 	test x"${CPU}" != x && { echo "${CPU}-unknown-linux-gnu"; exit; }
 	;;
     or32:Linux:*:*)
@@ -919,9 +958,15 @@ EOF
     sparc:Linux:*:* | sparc64:Linux:*:*)
 	echo ${UNAME_MACHINE}-unknown-linux-gnu
 	exit ;;
+    vax:Linux:*:*)
+	echo ${UNAME_MACHINE}-dec-linux-gnu
+	exit ;;
     x86_64:Linux:*:*)
 	echo x86_64-unknown-linux-gnu
 	exit ;;
+    xtensa*:Linux:*:*)
+    	echo ${UNAME_MACHINE}-unknown-linux-gnu
+	exit ;;
     i*86:Linux:*:*)
 	# The BFD linker knows what the default object file format is, so
 	# first see if it will tell us. cd to the root directory to prevent
@@ -964,7 +1009,7 @@ EOF
 	LIBC=gnulibc1
 	# endif
 	#else
-	#ifdef __INTEL_COMPILER
+	#if defined(__INTEL_COMPILER) || defined(__PGI) || defined(__SUNPRO_C) || defined(__SUNPRO_CC)
 	LIBC=gnu
 	#else
 	LIBC=gnuaout
@@ -974,7 +1019,11 @@ EOF
 	LIBC=dietlibc
 	#endif
 EOF
-	eval `$CC_FOR_BUILD -E $dummy.c 2>/dev/null | grep ^LIBC=`
+	eval "`$CC_FOR_BUILD -E $dummy.c 2>/dev/null | sed -n '
+	    /^LIBC/{
+		s: ::g
+		p
+	    }'`"
 	test x"${LIBC}" != x && {
 		echo "${UNAME_MACHINE}-pc-linux-${LIBC}"
 		exit
@@ -1176,6 +1225,15 @@ EOF
     SX-6:SUPER-UX:*:*)
 	echo sx6-nec-superux${UNAME_RELEASE}
 	exit ;;
+    SX-7:SUPER-UX:*:*)
+	echo sx7-nec-superux${UNAME_RELEASE}
+	exit ;;
+    SX-8:SUPER-UX:*:*)
+	echo sx8-nec-superux${UNAME_RELEASE}
+	exit ;;
+    SX-8R:SUPER-UX:*:*)
+	echo sx8r-nec-superux${UNAME_RELEASE}
+	exit ;;
     Power*:Rhapsody:*:*)
 	echo powerpc-apple-rhapsody${UNAME_RELEASE}
 	exit ;;
@@ -1185,7 +1243,6 @@ EOF
     *:Darwin:*:*)
 	UNAME_PROCESSOR=`uname -p` || UNAME_PROCESSOR=unknown
 	case $UNAME_PROCESSOR in
-	    *86) UNAME_PROCESSOR=i686 ;;
 	    unknown) UNAME_PROCESSOR=powerpc ;;
 	esac
 	echo ${UNAME_PROCESSOR}-apple-darwin${UNAME_RELEASE}
@@ -1264,6 +1321,9 @@ EOF
     i*86:skyos:*:*)
 	echo ${UNAME_MACHINE}-pc-skyos`echo ${UNAME_RELEASE}` | sed -e 's/ .*$//'
 	exit ;;
+    i*86:rdos:*:*)
+	echo ${UNAME_MACHINE}-pc-rdos
+	exit ;;
 esac
 
 #echo '(No uname command or uname output not recognized.)' 1>&2
@@ -1424,9 +1484,9 @@ This script, last modified $timestamp, has failed to recognize
 the operating system you are using. It is advised that you
 download the most up to date version of the config scripts from
 
-  http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/config/config/config.guess
+  http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.guess;hb=HEAD
 and
-  http://savannah.gnu.org/cgi-bin/viewcvs/*checkout*/config/config/config.sub
+  http://git.savannah.gnu.org/gitweb/?p=config.git;a=blob_plain;f=config.sub;hb=HEAD
 
 If the version you run ($0) is already up to date, please
 send the following data and any information you think might be
diff --git a/config.sub b/config.sub
index 1c366df..6759825 100644
--- a/config.sub
+++ b/config.sub
@@ -1,9 +1,10 @@
 #! /bin/sh
 # Configuration validation subroutine script.
 #   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-#   2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
+#   2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
+#   Free Software Foundation, Inc.
 
-timestamp='2005-07-08'
+timestamp='2008-01-16'
 
 # This file is (in principle) common to ALL GNU software.
 # The presence of a machine in this file suggests that SOME GNU software
@@ -71,8 +72,8 @@ Report bugs and patches to <config-patches at gnu.org>."
 version="\
 GNU config.sub ($timestamp)
 
-Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005
-Free Software Foundation, Inc.
+Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001,
+2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
 
 This is free software; see the source for copying conditions.  There is NO
 warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
@@ -119,8 +120,9 @@ esac
 # Here we must recognize all the valid KERNEL-OS combinations.
 maybe_os=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\2/'`
 case $maybe_os in
-  nto-qnx* | linux-gnu* | linux-dietlibc | linux-uclibc* | uclinux-uclibc* | uclinux-gnu* | \
-  kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | storm-chaos* | os2-emx* | rtmk-nova*)
+  nto-qnx* | linux-gnu* | linux-dietlibc | linux-newlib* | linux-uclibc* | \
+  uclinux-uclibc* | uclinux-gnu* | kfreebsd*-gnu* | knetbsd*-gnu* | netbsd*-gnu* | \
+  storm-chaos* | os2-emx* | rtmk-nova*)
     os=-$maybe_os
     basic_machine=`echo $1 | sed 's/^\(.*\)-\([^-]*-[^-]*\)$/\1/'`
     ;;
@@ -171,6 +173,10 @@ case $os in
 	-hiux*)
 		os=-hiuxwe2
 		;;
+	-sco6)
+		os=-sco5v6
+		basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
+		;;
 	-sco5)
 		os=-sco3.2v5
 		basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
@@ -187,6 +193,10 @@ case $os in
 		# Don't forget version if it is 3.2v4 or newer.
 		basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
 		;;
+	-sco5v6*)
+		# Don't forget version if it is 3.2v4 or newer.
+		basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
+		;;
 	-sco*)
 		os=-sco3.2v2
 		basic_machine=`echo $1 | sed -e 's/86-.*/86-pc/'`
@@ -231,15 +241,16 @@ case $basic_machine in
 	| alpha | alphaev[4-8] | alphaev56 | alphaev6[78] | alphapca5[67] \
 	| alpha64 | alpha64ev[4-8] | alpha64ev56 | alpha64ev6[78] | alpha64pca5[67] \
 	| am33_2.0 \
-	| arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr \
+	| arc | arm | arm[bl]e | arme[lb] | armv[2345] | armv[345][lb] | avr | avr32 \
 	| bfin \
 	| c4x | clipper \
 	| d10v | d30v | dlx | dsp16xx \
-	| fr30 | frv \
+	| fido | fr30 | frv \
 	| h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
 	| i370 | i860 | i960 | ia64 \
 	| ip2k | iq2000 \
-	| m32r | m32rle | m68000 | m68k | m88k | maxq | mcore \
+	| m32c | m32r | m32rle | m68000 | m68k | m88k \
+	| maxq | mb | microblaze | mcore | mep \
 	| mips | mipsbe | mipseb | mipsel | mipsle \
 	| mips16 \
 	| mips64 | mips64el \
@@ -257,28 +268,27 @@ case $basic_machine in
 	| mipsisa64sr71k | mipsisa64sr71kel \
 	| mipstx39 | mipstx39el \
 	| mn10200 | mn10300 \
-	| ms1 \
+	| mt \
 	| msp430 \
+	| nios | nios2 \
 	| ns16k | ns32k \
 	| or32 \
 	| pdp10 | pdp11 | pj | pjl \
 	| powerpc | powerpc64 | powerpc64le | powerpcle | ppcbe \
 	| pyramid \
-	| sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | shbe | shle | sh[1234]le | sh3ele \
+	| score \
+	| sh | sh[1234] | sh[24]a | sh[23]e | sh[34]eb | sheb | shbe | shle | sh[1234]le | sh3ele \
 	| sh64 | sh64le \
-	| sparc | sparc64 | sparc64b | sparc86x | sparclet | sparclite \
-	| sparcv8 | sparcv9 | sparcv9b \
-	| strongarm \
+	| sparc | sparc64 | sparc64b | sparc64v | sparc86x | sparclet | sparclite \
+	| sparcv8 | sparcv9 | sparcv9b | sparcv9v \
+	| spu | strongarm \
 	| tahoe | thumb | tic4x | tic80 | tron \
 	| v850 | v850e \
 	| we32k \
-	| x86 | xscale | xscalee[bl] | xstormy16 | xtensa \
+	| x86 | xc16x | xscale | xscalee[bl] | xstormy16 | xtensa \
 	| z8k)
 		basic_machine=$basic_machine-unknown
 		;;
-	m32c)
-		basic_machine=$basic_machine-unknown
-		;;
 	m6811 | m68hc11 | m6812 | m68hc12)
 		# Motorola 68HC11/12.
 		basic_machine=$basic_machine-unknown
@@ -286,6 +296,9 @@ case $basic_machine in
 		;;
 	m88110 | m680[12346]0 | m683?2 | m68360 | m5200 | v70 | w65 | z8k)
 		;;
+	ms1)
+		basic_machine=mt-unknown
+		;;
 
 	# We use `pc' rather than `unknown'
 	# because (1) that's what they normally are, and
@@ -305,18 +318,18 @@ case $basic_machine in
 	| alpha64-* | alpha64ev[4-8]-* | alpha64ev56-* | alpha64ev6[78]-* \
 	| alphapca5[67]-* | alpha64pca5[67]-* | arc-* \
 	| arm-*  | armbe-* | armle-* | armeb-* | armv*-* \
-	| avr-* \
+	| avr-* | avr32-* \
 	| bfin-* | bs2000-* \
 	| c[123]* | c30-* | [cjt]90-* | c4x-* | c54x-* | c55x-* | c6x-* \
 	| clipper-* | craynv-* | cydra-* \
 	| d10v-* | d30v-* | dlx-* \
 	| elxsi-* \
-	| f30[01]-* | f700-* | fr30-* | frv-* | fx80-* \
+	| f30[01]-* | f700-* | fido-* | fr30-* | frv-* | fx80-* \
 	| h8300-* | h8500-* \
 	| hppa-* | hppa1.[01]-* | hppa2.0-* | hppa2.0[nw]-* | hppa64-* \
 	| i*86-* | i860-* | i960-* | ia64-* \
 	| ip2k-* | iq2000-* \
-	| m32r-* | m32rle-* \
+	| m32c-* | m32r-* | m32rle-* \
 	| m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
 	| m88110-* | m88k-* | maxq-* | mcore-* \
 	| mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
@@ -336,30 +349,33 @@ case $basic_machine in
 	| mipsisa64sr71k-* | mipsisa64sr71kel-* \
 	| mipstx39-* | mipstx39el-* \
 	| mmix-* \
-	| ms1-* \
+	| mt-* \
 	| msp430-* \
+	| nios-* | nios2-* \
 	| none-* | np1-* | ns16k-* | ns32k-* \
 	| orion-* \
 	| pdp10-* | pdp11-* | pj-* | pjl-* | pn-* | power-* \
 	| powerpc-* | powerpc64-* | powerpc64le-* | powerpcle-* | ppcbe-* \
 	| pyramid-* \
 	| romp-* | rs6000-* \
-	| sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | shbe-* \
+	| sh-* | sh[1234]-* | sh[24]a-* | sh[23]e-* | sh[34]eb-* | sheb-* | shbe-* \
 	| shle-* | sh[1234]le-* | sh3ele-* | sh64-* | sh64le-* \
-	| sparc-* | sparc64-* | sparc64b-* | sparc86x-* | sparclet-* \
+	| sparc-* | sparc64-* | sparc64b-* | sparc64v-* | sparc86x-* | sparclet-* \
 	| sparclite-* \
-	| sparcv8-* | sparcv9-* | sparcv9b-* | strongarm-* | sv1-* | sx?-* \
+	| sparcv8-* | sparcv9-* | sparcv9b-* | sparcv9v-* | strongarm-* | sv1-* | sx?-* \
 	| tahoe-* | thumb-* \
 	| tic30-* | tic4x-* | tic54x-* | tic55x-* | tic6x-* | tic80-* \
 	| tron-* \
 	| v850-* | v850e-* | vax-* \
 	| we32k-* \
-	| x86-* | x86_64-* | xps100-* | xscale-* | xscalee[bl]-* \
-	| xstormy16-* | xtensa-* \
+	| x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \
+	| xstormy16-* | xtensa*-* \
 	| ymp-* \
 	| z8k-*)
 		;;
-	m32c-*)
+	# Recognize the basic CPU types without company name, with glob match.
+	xtensa*)
+		basic_machine=$basic_machine-unknown
 		;;
 	# Recognize the various machine names and aliases which stand
 	# for a CPU type and a company and sometimes even an OS.
@@ -431,6 +447,14 @@ case $basic_machine in
 		basic_machine=ns32k-sequent
 		os=-dynix
 		;;
+	blackfin)
+		basic_machine=bfin-unknown
+		os=-linux
+		;;
+	blackfin-*)
+		basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'`
+		os=-linux
+		;;
 	c90)
 		basic_machine=c90-cray
 		os=-unicos
@@ -463,8 +487,8 @@ case $basic_machine in
 		basic_machine=craynv-cray
 		os=-unicosmp
 		;;
-	cr16c)
-		basic_machine=cr16c-unknown
+	cr16)
+		basic_machine=cr16-unknown
 		os=-elf
 		;;
 	crds | unos)
@@ -656,6 +680,14 @@ case $basic_machine in
 		basic_machine=m68k-isi
 		os=-sysv
 		;;
+	m68knommu)
+		basic_machine=m68k-unknown
+		os=-linux
+		;;
+	m68knommu-*)
+		basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'`
+		os=-linux
+		;;
 	m88k-omron*)
 		basic_machine=m88k-omron
 		;;
@@ -671,6 +703,10 @@ case $basic_machine in
 		basic_machine=i386-pc
 		os=-mingw32
 		;;
+	mingw32ce)
+		basic_machine=arm-unknown
+		os=-mingw32ce
+		;;
 	miniframe)
 		basic_machine=m68000-convergent
 		;;
@@ -696,6 +732,9 @@ case $basic_machine in
 		basic_machine=i386-pc
 		os=-msdos
 		;;
+	ms1-*)
+		basic_machine=`echo $basic_machine | sed -e 's/ms1-/mt-/'`
+		;;
 	mvs)
 		basic_machine=i370-ibm
 		os=-mvs
@@ -794,6 +833,14 @@ case $basic_machine in
 		basic_machine=i860-intel
 		os=-osf
 		;;
+	parisc)
+		basic_machine=hppa-unknown
+		os=-linux
+		;;
+	parisc-*)
+		basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'`
+		os=-linux
+		;;
 	pbd)
 		basic_machine=sparc-tti
 		;;
@@ -803,6 +850,12 @@ case $basic_machine in
 	pc532 | pc532-*)
 		basic_machine=ns32k-pc532
 		;;
+	pc98)
+		basic_machine=i386-pc
+		;;
+	pc98-*)
+		basic_machine=i386-`echo $basic_machine | sed 's/^[^-]*-//'`
+		;;
 	pentium | p5 | k5 | k6 | nexgen | viac3)
 		basic_machine=i586-pc
 		;;
@@ -859,6 +912,10 @@ case $basic_machine in
 		basic_machine=i586-unknown
 		os=-pw32
 		;;
+	rdos)
+		basic_machine=i386-pc
+		os=-rdos
+		;;
 	rom68k)
 		basic_machine=m68k-rom68k
 		os=-coff
@@ -885,6 +942,10 @@ case $basic_machine in
 	sb1el)
 		basic_machine=mipsisa64sb1el-unknown
 		;;
+	sde)
+		basic_machine=mipsisa32-sde
+		os=-elf
+		;;
 	sei)
 		basic_machine=mips-sei
 		os=-seiux
@@ -896,6 +957,9 @@ case $basic_machine in
 		basic_machine=sh-hitachi
 		os=-hms
 		;;
+	sh5el)
+		basic_machine=sh5le-unknown
+		;;
 	sh64)
 		basic_machine=sh64-unknown
 		;;
@@ -985,6 +1049,10 @@ case $basic_machine in
 		basic_machine=tic6x-unknown
 		os=-coff
 		;;
+	tile*)
+		basic_machine=tile-unknown
+		os=-linux-gnu
+		;;
 	tx39)
 		basic_machine=mipstx39-unknown
 		;;
@@ -1101,7 +1169,7 @@ case $basic_machine in
 	sh[1234] | sh[24]a | sh[34]eb | sh[1234]le | sh[23]ele)
 		basic_machine=sh-unknown
 		;;
-	sparc | sparcv8 | sparcv9 | sparcv9b)
+	sparc | sparcv8 | sparcv9 | sparcv9b | sparcv9v)
 		basic_machine=sparc-sun
 		;;
 	cydra)
@@ -1174,21 +1242,23 @@ case $os in
 	      | -aos* \
 	      | -nindy* | -vxsim* | -vxworks* | -ebmon* | -hms* | -mvs* \
 	      | -clix* | -riscos* | -uniplus* | -iris* | -rtu* | -xenix* \
-	      | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* | -openbsd* \
+	      | -hiux* | -386bsd* | -knetbsd* | -mirbsd* | -netbsd* \
+	      | -openbsd* | -solidbsd* \
 	      | -ekkobsd* | -kfreebsd* | -freebsd* | -riscix* | -lynxos* \
 	      | -bosx* | -nextstep* | -cxux* | -aout* | -elf* | -oabi* \
 	      | -ptx* | -coff* | -ecoff* | -winnt* | -domain* | -vsta* \
 	      | -udi* | -eabi* | -lites* | -ieee* | -go32* | -aux* \
 	      | -chorusos* | -chorusrdb* \
 	      | -cygwin* | -pe* | -psos* | -moss* | -proelf* | -rtems* \
-	      | -mingw32* | -linux-gnu* | -linux-uclibc* | -uxpv* | -beos* | -mpeix* | -udk* \
+	      | -mingw32* | -linux-gnu* | -linux-newlib* | -linux-uclibc* \
+	      | -uxpv* | -beos* | -mpeix* | -udk* \
 	      | -interix* | -uwin* | -mks* | -rhapsody* | -darwin* | -opened* \
 	      | -openstep* | -oskit* | -conix* | -pw32* | -nonstopux* \
 	      | -storm-chaos* | -tops10* | -tenex* | -tops20* | -its* \
 	      | -os2* | -vos* | -palmos* | -uclinux* | -nucleus* \
 	      | -morphos* | -superux* | -rtmk* | -rtmk-nova* | -windiss* \
 	      | -powermax* | -dnix* | -nx6 | -nx7 | -sei* | -dragonfly* \
-	      | -skyos* | -haiku*)
+	      | -skyos* | -haiku* | -rdos* | -toppers* | -drops*)
 	# Remember, each alternative MUST END IN *, to match a version number.
 		;;
 	-qnx*)
@@ -1340,6 +1410,12 @@ else
 # system, and we'll never get to this point.
 
 case $basic_machine in
+        score-*)
+		os=-elf
+		;;
+        spu-*)
+		os=-elf
+		;;
 	*-acorn)
 		os=-riscix1.2
 		;;
@@ -1349,9 +1425,9 @@ case $basic_machine in
 	arm*-semi)
 		os=-aout
 		;;
-    c4x-* | tic4x-*)
-        os=-coff
-        ;;
+        c4x-* | tic4x-*)
+        	os=-coff
+		;;
 	# This must come before the *-dec entry.
 	pdp10-*)
 		os=-tops20
@@ -1377,6 +1453,9 @@ case $basic_machine in
 	m68*-cisco)
 		os=-aout
 		;;
+        mep-*)
+		os=-elf
+		;;
 	mips*-cisco)
 		os=-elf
 		;;
diff --git a/configure b/configure
index c1f928c..4b4d59d 100755
--- a/configure
+++ b/configure
@@ -253,15 +253,15 @@
 
 
 # libtool.m4 - Configure libtool for the host system. -*-Autoconf-*-
-## Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005
-## Free Software Foundation, Inc.
+## Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007,
+## 2008  Free Software Foundation, Inc.
 ## Originally by Gordon Matzigkeit <gord at gnu.ai.mit.edu>, 1996
 ##
 ## This file is free software; the Free Software Foundation gives
 ## unlimited permission to copy and/or distribute it, with or without
 ## modifications, as long as this notice is preserved.
 
-# serial 47 AC_PROG_LIBTOOL
+# serial 52 AC_PROG_LIBTOOL
 
 
 # autoconf 2.13 compatibility
@@ -326,6 +326,10 @@ fi
 
 
 
+# _LT_REQUIRED_DARWIN_CHECKS
+# --------------------------
+# Check for some things on darwin
+
 
 # _LT_AC_SYS_LIBPATH_AIX
 # ----------------------
@@ -375,18 +379,18 @@ fi
 
 
 # _LT_AC_CHECK_DLFCN
-# --------------------
+# ------------------
 # _LT_AC_CHECK_DLFCN
 
 
 # _LT_AC_TRY_DLOPEN_SELF (ACTION-IF-TRUE, ACTION-IF-TRUE-W-USCORE,
 #                           ACTION-IF-FALSE, ACTION-IF-CROSS-COMPILING)
-# ------------------------------------------------------------------
+# ---------------------------------------------------------------------
 # _LT_AC_TRY_DLOPEN_SELF
 
 
 # AC_LIBTOOL_DLOPEN_SELF
-# -------------------
+# ----------------------
 # AC_LIBTOOL_DLOPEN_SELF
 
 
@@ -450,7 +454,7 @@ fi
 
 # AC_DISABLE_SHARED
 # -----------------
-#- set the default shared flag to --disable-shared
+# set the default shared flag to --disable-shared
 # AC_DISABLE_SHARED
 
 
@@ -489,20 +493,18 @@ fi
 
 # AC_PROG_EGREP
 # -------------
-# This is predefined starting with Autoconf 2.54, so this conditional
-# definition can be removed once we require Autoconf 2.54 or later.
 
 
 
 # AC_PATH_TOOL_PREFIX
 # -------------------
-# find a file program which can recognise shared library
+# find a file program which can recognize shared library
 # AC_PATH_TOOL_PREFIX
 
 
 # AC_PATH_MAGIC
 # -------------
-# find a file program which can recognise a shared library
+# find a file program which can recognize a shared library
 # AC_PATH_MAGIC
 
 
@@ -583,55 +585,9 @@ fi
 # _LT_AC_LANG_CXX
 
 # _LT_AC_PROG_CXXCPP
-# ---------------
+# ------------------
 # _LT_AC_PROG_CXXCPP
 
-# AC_LIBTOOL_F77
-# --------------
-# enable support for Fortran 77 libraries
-#AC_DEFUN([AC_LIBTOOL_F77],
-#[AC_REQUIRE([_LT_AC_LANG_F77])
-#])# AC_LIBTOOL_F77
-
-
-# _LT_AC_LANG_F77
-# ---------------
-#AC_DEFUN([_LT_AC_LANG_F77],
-#[AC_REQUIRE([AC_PROG_F77])
-#_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}F77])
-#])# _LT_AC_LANG_F77
-
-
-# AC_LIBTOOL_GCJ
-# --------------
-# enable support for GCJ libraries
-#AC_DEFUN([AC_LIBTOOL_GCJ],
-#[AC_REQUIRE([_LT_AC_LANG_GCJ])
-#])# AC_LIBTOOL_GCJ
-
-
-# _LT_AC_LANG_GCJ
-# ---------------
-#AC_DEFUN([_LT_AC_LANG_GCJ],
-#[AC_PROVIDE_IFELSE([AC_PROG_GCJ],[],
-#  [AC_PROVIDE_IFELSE([A][M_PROG_GCJ],[],
-#    [AC_PROVIDE_IFELSE([LT_AC_PROG_GCJ],[],
-#      [ifdef([AC_PROG_GCJ],[AC_REQUIRE([AC_PROG_GCJ])],
-#	 [ifdef([A][M_PROG_GCJ],[AC_REQUIRE([A][M_PROG_GCJ])],
-#	   [AC_REQUIRE([A][C_PROG_GCJ_OR_A][M_PROG_GCJ])])])])])])
-#_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}GCJ])
-#])# _LT_AC_LANG_GCJ
-
-
-# AC_LIBTOOL_RC
-# --------------
-# enable support for Windows resource files
-#AC_DEFUN([AC_LIBTOOL_RC],
-#[AC_REQUIRE([LT_AC_PROG_RC])
-#_LT_AC_SHELL_INIT([tagnames=${tagnames+${tagnames},}RC])
-#])# AC_LIBTOOL_RC
-
-
 # AC_LIBTOOL_LANG_C_CONFIG
 # ------------------------
 # Ensure that the configuration vars for the C compiler are
@@ -650,226 +606,13 @@ fi
 # AC_LIBTOOL_LANG_CXX_CONFIG
 
 # AC_LIBTOOL_POSTDEP_PREDEP([TAGNAME])
-# ------------------------
+# ------------------------------------
 # Figure out "hidden" library dependencies from verbose
 # compiler output when linking a shared library.
 # Parse the compiler output and extract the necessary
 # objects, libraries and library flags.
 # AC_LIBTOOL_POSTDEP_PREDEP
 
-# AC_LIBTOOL_LANG_F77_CONFIG
-# ------------------------
-# Ensure that the configuration vars for the C compiler are
-# suitably defined.  Those variables are subsequently used by
-# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
-#AC_DEFUN([AC_LIBTOOL_LANG_F77_CONFIG], [_LT_AC_LANG_F77_CONFIG(F77)])
-#AC_DEFUN([_LT_AC_LANG_F77_CONFIG],
-#[AC_REQUIRE([AC_PROG_F77])
-#AC_LANG_SAVE
-#AC_LANG_FORTRAN77
-#
-#_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
-#_LT_AC_TAGVAR(allow_undefined_flag, $1)=
-#_LT_AC_TAGVAR(always_export_symbols, $1)=no
-#_LT_AC_TAGVAR(archive_expsym_cmds, $1)=
-#_LT_AC_TAGVAR(export_dynamic_flag_spec, $1)=
-#_LT_AC_TAGVAR(hardcode_direct, $1)=no
-#_LT_AC_TAGVAR(hardcode_libdir_flag_spec, $1)=
-#_LT_AC_TAGVAR(hardcode_libdir_flag_spec_ld, $1)=
-#_LT_AC_TAGVAR(hardcode_libdir_separator, $1)=
-#_LT_AC_TAGVAR(hardcode_minus_L, $1)=no
-#_LT_AC_TAGVAR(hardcode_automatic, $1)=no
-#_LT_AC_TAGVAR(module_cmds, $1)=
-#_LT_AC_TAGVAR(module_expsym_cmds, $1)=
-#_LT_AC_TAGVAR(link_all_deplibs, $1)=unknown
-#_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
-#_LT_AC_TAGVAR(no_undefined_flag, $1)=
-#_LT_AC_TAGVAR(whole_archive_flag_spec, $1)=
-#_LT_AC_TAGVAR(enable_shared_with_static_runtimes, $1)=no
-#
-## Source file extension for f77 test sources.
-#ac_ext=f
-#
-## Object file extension for compiled f77 test sources.
-#objext=o
-#_LT_AC_TAGVAR(objext, $1)=$objext
-#
-## Code to be used in simple compile tests
-#lt_simple_compile_test_code="      subroutine t\n      return\n      end\n"
-#
-## Code to be used in simple link tests
-#lt_simple_link_test_code="      program t\n      end\n"
-#
-## ltmain only uses $CC for tagged configurations so make sure $CC is set.
-#_LT_AC_SYS_COMPILER
-#
-## save warnings/boilerplate of simple test code
-#_LT_COMPILER_BOILERPLATE
-#_LT_LINKER_BOILERPLATE
-#
-## Allow CC to be a program name with arguments.
-#lt_save_CC="$CC"
-#CC=${F77-"f77"}
-#compiler=$CC
-#_LT_AC_TAGVAR(compiler, $1)=$CC
-#_LT_CC_BASENAME([$compiler])
-#
-#AC_MSG_CHECKING([if libtool supports shared libraries])
-#AC_MSG_RESULT([$can_build_shared])
-#
-#AC_MSG_CHECKING([whether to build shared libraries])
-#test "$can_build_shared" = "no" && enable_shared=no
-#
-## On AIX, shared libraries and static libraries use the same namespace, and
-## are all built from PIC.
-#case "$host_os" in
-#aix3*)
-#  test "$enable_shared" = yes && enable_static=no
-#  if test -n "$RANLIB"; then
-#    archive_cmds="$archive_cmds~\$RANLIB \$lib"
-#    postinstall_cmds='$RANLIB $lib'
-#  fi
-#  ;;
-#aix4* | aix5*)
-#  if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
-#    test "$enable_shared" = yes && enable_static=no
-#  fi
-#  ;;
-#esac
-#AC_MSG_RESULT([$enable_shared])
-#
-#AC_MSG_CHECKING([whether to build static libraries])
-## Make sure either enable_shared or enable_static is yes.
-#test "$enable_shared" = yes || enable_static=yes
-#AC_MSG_RESULT([$enable_static])
-#
-#test "$_LT_AC_TAGVAR(ld_shlibs, $1)" = no && can_build_shared=no
-#
-#_LT_AC_TAGVAR(GCC, $1)="$G77"
-#_LT_AC_TAGVAR(LD, $1)="$LD"
-#
-#AC_LIBTOOL_PROG_COMPILER_PIC($1)
-#AC_LIBTOOL_PROG_CC_C_O($1)
-#AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
-#AC_LIBTOOL_PROG_LD_SHLIBS($1)
-#AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
-#AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
-#AC_LIBTOOL_SYS_LIB_STRIP
-#
-#
-#AC_LIBTOOL_CONFIG($1)
-#
-#AC_LANG_RESTORE
-#CC="$lt_save_CC"
-#])# AC_LIBTOOL_LANG_F77_CONFIG
-
-
-# AC_LIBTOOL_LANG_GCJ_CONFIG
-# --------------------------
-# Ensure that the configuration vars for the C compiler are
-# suitably defined.  Those variables are subsequently used by
-# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
-#AC_DEFUN([AC_LIBTOOL_LANG_GCJ_CONFIG], [_LT_AC_LANG_GCJ_CONFIG(GCJ)])
-#AC_DEFUN([_LT_AC_LANG_GCJ_CONFIG],
-#[AC_LANG_SAVE
-#
-## Source file extension for Java test sources.
-#ac_ext=java
-#
-## Object file extension for compiled Java test sources.
-#objext=o
-#_LT_AC_TAGVAR(objext, $1)=$objext
-#
-## Code to be used in simple compile tests
-#lt_simple_compile_test_code="class foo {}\n"
-#
-## Code to be used in simple link tests
-#lt_simple_link_test_code='public class conftest { public static void main(String[[]] argv) {}; }\n'
-#
-## ltmain only uses $CC for tagged configurations so make sure $CC is set.
-#_LT_AC_SYS_COMPILER
-#
-## save warnings/boilerplate of simple test code
-#_LT_COMPILER_BOILERPLATE
-#_LT_LINKER_BOILERPLATE
-#
-## Allow CC to be a program name with arguments.
-#lt_save_CC="$CC"
-#CC=${GCJ-"gcj"}
-#compiler=$CC
-#_LT_AC_TAGVAR(compiler, $1)=$CC
-#_LT_CC_BASENAME([$compiler])
-#
-## GCJ did not exist at the time GCC didn't implicitly link libc in.
-#_LT_AC_TAGVAR(archive_cmds_need_lc, $1)=no
-#
-#_LT_AC_TAGVAR(old_archive_cmds, $1)=$old_archive_cmds
-#
-### CAVEAT EMPTOR:
-### There is no encapsulation within the following macros, do not change
-### the running order or otherwise move them around unless you know exactly
-### what you are doing...
-#AC_LIBTOOL_PROG_COMPILER_NO_RTTI($1)
-#AC_LIBTOOL_PROG_COMPILER_PIC($1)
-#AC_LIBTOOL_PROG_CC_C_O($1)
-#AC_LIBTOOL_SYS_HARD_LINK_LOCKS($1)
-#AC_LIBTOOL_PROG_LD_SHLIBS($1)
-#AC_LIBTOOL_SYS_DYNAMIC_LINKER($1)
-#AC_LIBTOOL_PROG_LD_HARDCODE_LIBPATH($1)
-#AC_LIBTOOL_SYS_LIB_STRIP
-#AC_LIBTOOL_DLOPEN_SELF($1)
-#
-#AC_LIBTOOL_CONFIG($1)
-#
-#AC_LANG_RESTORE
-#CC="$lt_save_CC"
-#])# AC_LIBTOOL_LANG_GCJ_CONFIG
-
-
-# AC_LIBTOOL_LANG_RC_CONFIG
-# --------------------------
-# Ensure that the configuration vars for the Windows resource compiler are
-# suitably defined.  Those variables are subsequently used by
-# AC_LIBTOOL_CONFIG to write the compiler configuration to `libtool'.
-#AC_DEFUN([AC_LIBTOOL_LANG_RC_CONFIG], [_LT_AC_LANG_RC_CONFIG(RC)])
-#AC_DEFUN([_LT_AC_LANG_RC_CONFIG],
-#[AC_LANG_SAVE
-#
-## Source file extension for RC test sources.
-#ac_ext=rc
-#
-## Object file extension for compiled RC test sources.
-#objext=o
-#_LT_AC_TAGVAR(objext, $1)=$objext
-#
-## Code to be used in simple compile tests
-#lt_simple_compile_test_code='sample MENU { MENUITEM "&Soup", 100, CHECKED }\n'
-#
-## Code to be used in simple link tests
-#lt_simple_link_test_code="$lt_simple_compile_test_code"
-#
-## ltmain only uses $CC for tagged configurations so make sure $CC is set.
-#_LT_AC_SYS_COMPILER
-#
-## save warnings/boilerplate of simple test code
-#_LT_COMPILER_BOILERPLATE
-#_LT_LINKER_BOILERPLATE
-#
-## Allow CC to be a program name with arguments.
-#lt_save_CC="$CC"
-#CC=${RC-"windres"}
-#compiler=$CC
-#_LT_AC_TAGVAR(compiler, $1)=$CC
-#_LT_CC_BASENAME([$compiler])
-#_LT_AC_TAGVAR(lt_cv_prog_compiler_c_o, $1)=yes
-#
-#AC_LIBTOOL_CONFIG($1)
-#
-#AC_LANG_RESTORE
-#CC="$lt_save_CC"
-#])# AC_LIBTOOL_LANG_RC_CONFIG
-
-
 # AC_LIBTOOL_CONFIG([TAGNAME])
 # ----------------------------
 # If TAGNAME is not passed, then create an initial libtool script
@@ -923,16 +666,6 @@ fi
 # This is just to silence aclocal about the macro not being used
 
 
-#AC_DEFUN([LT_AC_PROG_GCJ],
-#[AC_CHECK_TOOL(GCJ, gcj, no)
-#  test "x${GCJFLAGS+set}" = xset || GCJFLAGS="-g -O2"
-#  AC_SUBST(GCJFLAGS)
-#])
-
-#AC_DEFUN([LT_AC_PROG_RC],
-#[AC_CHECK_TOOL(RC, windres, no)
-#])
-
 ############################################################
 # NOTE: This macro has been submitted for inclusion into   #
 #  GNU Autoconf as AC_PROG_SED.  When it is available in   #
@@ -2151,12 +1884,12 @@ fi
 
 
 echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:2155: checking for Cygwin environment" >&5
+echo "configure:1888: checking for Cygwin environment" >&5
 if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2160 "configure"
+#line 1893 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -2167,7 +1900,7 @@ int main() {
 return __CYGWIN__;
 ; return 0; }
 EOF
-if { (eval echo configure:2171: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1904: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_cygwin=yes
 else
@@ -2184,19 +1917,19 @@ echo "$ac_t""$ac_cv_cygwin" 1>&6
 CYGWIN=
 test "$ac_cv_cygwin" = yes && CYGWIN=yes
 echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:2188: checking for mingw32 environment" >&5
+echo "configure:1921: checking for mingw32 environment" >&5
 if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2193 "configure"
+#line 1926 "configure"
 #include "confdefs.h"
 
 int main() {
 return __MINGW32__;
 ; return 0; }
 EOF
-if { (eval echo configure:2200: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1933: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_mingw32=yes
 else
@@ -2215,7 +1948,7 @@ test "$ac_cv_mingw32" = yes && MINGW32=yes
 
 
 echo $ac_n "checking for egrep""... $ac_c" 1>&6
-echo "configure:2219: checking for egrep" >&5
+echo "configure:1952: checking for egrep" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_egrep'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2230,7 +1963,7 @@ echo "$ac_t""$ac_cv_prog_egrep" 1>&6
  
 
 echo $ac_n "checking for a sed that does not truncate output""... $ac_c" 1>&6
-echo "configure:2234: checking for a sed that does not truncate output" >&5
+echo "configure:1967: checking for a sed that does not truncate output" >&5
 if eval "test \"`echo '$''{'lt_cv_path_SED'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2380,7 +2113,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
 fi
 
 echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:2384: checking host system type" >&5
+echo "configure:2117: checking host system type" >&5
 
 host_alias=$host
 case "$host_alias" in
@@ -2401,7 +2134,7 @@ host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
 echo "$ac_t""$host" 1>&6
 
 echo $ac_n "checking target system type""... $ac_c" 1>&6
-echo "configure:2405: checking target system type" >&5
+echo "configure:2138: checking target system type" >&5
 
 target_alias=$target
 case "$target_alias" in
@@ -2431,7 +2164,7 @@ echo "$ac_t""$target" 1>&6
 
 PHP_MAJOR_VERSION=5
 PHP_MINOR_VERSION=2
-PHP_RELEASE_VERSION=11
+PHP_RELEASE_VERSION=12
 PHP_EXTRA_VERSION=""
 PHP_VERSION="$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION"
 PHP_VERSION_ID=`expr $PHP_MAJOR_VERSION \* 10000 + $PHP_MINOR_VERSION \* 100 + $PHP_RELEASE_VERSION`
@@ -2509,22 +2242,11 @@ php_abs_top_builddir=$abs_builddir
 $php_shtool mkdir -p libs
 rm -f libs/*
 
-php_did_darwin9_cheat=0
-case $host_alias in
-*darwin9*)
-  hasg=`echo $CFLAGS | grep -E '(^-g)|([:space:]-g)'`
-  if test x"$hasg" = "x"; then
-    php_did_darwin9_cheat=1
-    CFLAGS="$CFLAGS -gstabs"
-  fi
-  ;;
-esac
-
 
 # Extract the first word of "gcc", so it can be a program name with args.
 set dummy gcc; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2528: checking for $ac_word" >&5
+echo "configure:2250: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2554,7 +2276,7 @@ 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 $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2558: checking for $ac_word" >&5
+echo "configure:2280: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2605,7 +2327,7 @@ fi
       # Extract the first word of "cl", so it can be a program name with args.
 set dummy cl; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2609: checking for $ac_word" >&5
+echo "configure:2331: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2637,7 +2359,7 @@ fi
 fi
 
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:2641: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:2363: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
 
 ac_ext=c
 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
@@ -2648,12 +2370,12 @@ cross_compiling=$ac_cv_prog_cc_cross
 
 cat > conftest.$ac_ext << EOF
 
-#line 2652 "configure"
+#line 2374 "configure"
 #include "confdefs.h"
 
 main(){return(0);}
 EOF
-if { (eval echo configure:2657: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2379: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   ac_cv_prog_cc_works=yes
   # If we can't run a trivial program, we are probably using a cross compiler.
   if (./conftest; exit) 2>/dev/null; then
@@ -2679,12 +2401,12 @@ if test $ac_cv_prog_cc_works = no; then
   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
 fi
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:2683: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:2405: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
 cross_compiling=$ac_cv_prog_cc_cross
 
 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:2688: checking whether we are using GNU C" >&5
+echo "configure:2410: checking whether we are using GNU C" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2693,7 +2415,7 @@ else
   yes;
 #endif
 EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2697: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:2419: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
   ac_cv_prog_gcc=yes
 else
   ac_cv_prog_gcc=no
@@ -2712,7 +2434,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
 ac_save_CFLAGS="$CFLAGS"
 CFLAGS=
 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:2716: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:2438: checking whether ${CC-cc} accepts -g" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2744,7 +2466,7 @@ else
 fi
 
 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:2748: checking how to run the C preprocessor" >&5
+echo "configure:2470: checking how to run the C preprocessor" >&5
 # On Suns, sometimes $CPP names a directory.
 if test -n "$CPP" && test -d "$CPP"; then
   CPP=
@@ -2759,13 +2481,13 @@ else
   # On the NeXT, cc -E runs the code through the compiler's parser,
   # not just through cpp.
   cat > conftest.$ac_ext <<EOF
-#line 2763 "configure"
+#line 2485 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2769: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2491: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -2776,13 +2498,13 @@ else
   rm -rf conftest*
   CPP="${CC-cc} -E -traditional-cpp"
   cat > conftest.$ac_ext <<EOF
-#line 2780 "configure"
+#line 2502 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2786: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2508: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -2793,13 +2515,13 @@ else
   rm -rf conftest*
   CPP="${CC-cc} -nologo -E"
   cat > conftest.$ac_ext <<EOF
-#line 2797 "configure"
+#line 2519 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2803: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2525: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -2826,9 +2548,9 @@ echo "$ac_t""$CPP" 1>&6
 
   ICC="no"
   echo $ac_n "checking for icc""... $ac_c" 1>&6
-echo "configure:2830: checking for icc" >&5
+echo "configure:2552: checking for icc" >&5
   cat > conftest.$ac_ext <<EOF
-#line 2832 "configure"
+#line 2554 "configure"
 #include "confdefs.h"
 __INTEL_COMPILER
 EOF
@@ -2850,9 +2572,9 @@ rm -f conftest*
 
   SUNCC="no"
   echo $ac_n "checking for suncc""... $ac_c" 1>&6
-echo "configure:2854: checking for suncc" >&5
+echo "configure:2576: checking for suncc" >&5
   cat > conftest.$ac_ext <<EOF
-#line 2856 "configure"
+#line 2578 "configure"
 #include "confdefs.h"
 __SUNPRO_C
 EOF
@@ -2875,10 +2597,10 @@ rm -f conftest*
 
 if test "x$CC" != xcc; then
   echo $ac_n "checking whether $CC and cc understand -c and -o together""... $ac_c" 1>&6
-echo "configure:2879: checking whether $CC and cc understand -c and -o together" >&5
+echo "configure:2601: checking whether $CC and cc understand -c and -o together" >&5
 else
   echo $ac_n "checking whether cc understands -c and -o together""... $ac_c" 1>&6
-echo "configure:2882: checking whether cc understands -c and -o together" >&5
+echo "configure:2604: checking whether cc understands -c and -o together" >&5
 fi
 set dummy $CC; ac_cc="`echo $2 |
 		       sed -e 's/[^a-zA-Z0-9_]/_/g' -e 's/^[0-9]/_/'`"
@@ -2890,16 +2612,16 @@ else
 # We do the test twice because some compilers refuse to overwrite an
 # existing .o file with -o, though they will create one.
 ac_try='${CC-cc} -c conftest.c -o conftest.o 1>&5'
-if { (eval echo configure:2894: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
-   test -f conftest.o && { (eval echo configure:2895: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
+if { (eval echo configure:2616: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
+   test -f conftest.o && { (eval echo configure:2617: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
 then
   eval ac_cv_prog_cc_${ac_cc}_c_o=yes
   if test "x$CC" != xcc; then
     # Test first that cc exists at all.
-    if { ac_try='cc -c conftest.c 1>&5'; { (eval echo configure:2900: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+    if { ac_try='cc -c conftest.c 1>&5'; { (eval echo configure:2622: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
       ac_try='cc -c conftest.c -o conftest.o 1>&5'
-      if { (eval echo configure:2902: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
-	 test -f conftest.o && { (eval echo configure:2903: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
+      if { (eval echo configure:2624: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
+	 test -f conftest.o && { (eval echo configure:2625: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
       then
         # cc works too.
         :
@@ -2926,7 +2648,7 @@ EOF
 fi
 
 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:2930: checking how to run the C preprocessor" >&5
+echo "configure:2652: checking how to run the C preprocessor" >&5
 # On Suns, sometimes $CPP names a directory.
 if test -n "$CPP" && test -d "$CPP"; then
   CPP=
@@ -2941,13 +2663,13 @@ else
   # On the NeXT, cc -E runs the code through the compiler's parser,
   # not just through cpp.
   cat > conftest.$ac_ext <<EOF
-#line 2945 "configure"
+#line 2667 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2951: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2673: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -2958,13 +2680,13 @@ else
   rm -rf conftest*
   CPP="${CC-cc} -E -traditional-cpp"
   cat > conftest.$ac_ext <<EOF
-#line 2962 "configure"
+#line 2684 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2968: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2690: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -2975,13 +2697,13 @@ else
   rm -rf conftest*
   CPP="${CC-cc} -nologo -E"
   cat > conftest.$ac_ext <<EOF
-#line 2979 "configure"
+#line 2701 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2985: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2707: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -3006,9 +2728,9 @@ fi
 echo "$ac_t""$CPP" 1>&6
 
 echo $ac_n "checking for AIX""... $ac_c" 1>&6
-echo "configure:3010: checking for AIX" >&5
+echo "configure:2732: checking for AIX" >&5
 cat > conftest.$ac_ext <<EOF
-#line 3012 "configure"
+#line 2734 "configure"
 #include "confdefs.h"
 #ifdef _AIX
   yes
@@ -3030,7 +2752,7 @@ rm -f conftest*
 
 
 echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:3034: checking whether ln -s works" >&5
+echo "configure:2756: checking whether ln -s works" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3055,7 +2777,7 @@ fi
 php_with_libdir=lib
 
 echo $ac_n "checking for system library directory""... $ac_c" 1>&6
-echo "configure:3059: checking for system library directory" >&5
+echo "configure:2781: checking for system library directory" >&5
 # Check whether --with-libdir or --without-libdir was given.
 if test "${with_libdir+set}" = set; then
   withval="$with_libdir"
@@ -3081,7 +2803,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_enable_rpath=yes
 
 echo $ac_n "checking whether to enable runpaths""... $ac_c" 1>&6
-echo "configure:3085: checking whether to enable runpaths" >&5
+echo "configure:2807: checking whether to enable runpaths" >&5
 # Check whether --enable-rpath or --disable-rpath was given.
 if test "${enable_rpath+set}" = set; then
   enableval="$enable_rpath"
@@ -3105,7 +2827,7 @@ echo "$ac_t""$ext_output" 1>&6
 
 
 echo $ac_n "checking if compiler supports -R""... $ac_c" 1>&6
-echo "configure:3109: checking if compiler supports -R" >&5
+echo "configure:2831: checking if compiler supports -R" >&5
 if eval "test \"`echo '$''{'php_cv_cc_dashr'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3113,14 +2835,14 @@ else
   SAVE_LIBS=$LIBS
   LIBS="-R /usr/$PHP_LIBDIR $LIBS"
   cat > conftest.$ac_ext <<EOF
-#line 3117 "configure"
+#line 2839 "configure"
 #include "confdefs.h"
 
 int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:3124: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2846: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   php_cv_cc_dashr=yes
 else
@@ -3138,7 +2860,7 @@ if test $php_cv_cc_dashr = "yes"; then
   ld_runpath_switch=-R
 else
   echo $ac_n "checking if compiler supports -Wl,-rpath,""... $ac_c" 1>&6
-echo "configure:3142: checking if compiler supports -Wl,-rpath," >&5
+echo "configure:2864: checking if compiler supports -Wl,-rpath," >&5
   if eval "test \"`echo '$''{'php_cv_cc_rpath'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3146,14 +2868,14 @@ else
     SAVE_LIBS=$LIBS
     LIBS="-Wl,-rpath,/usr/$PHP_LIBDIR $LIBS"
     cat > conftest.$ac_ext <<EOF
-#line 3150 "configure"
+#line 2872 "configure"
 #include "confdefs.h"
 
 int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:3157: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2879: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   php_cv_cc_rpath=yes
 else
@@ -3184,7 +2906,7 @@ 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 $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3188: checking for $ac_word" >&5
+echo "configure:2910: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3225,7 +2947,7 @@ test -n "$AWK" || AWK="bork"
       ;;
     *)
       echo $ac_n "checking if $AWK is broken""... $ac_c" 1>&6
-echo "configure:3229: checking if $AWK is broken" >&5
+echo "configure:2951: checking if $AWK is broken" >&5
       if ! $AWK 'function foo() {}' >/dev/null 2>&1 ; then
         echo "$ac_t""yes" 1>&6
         { echo "configure: error: You should install GNU awk" 1>&2; exit 1; }
@@ -3244,7 +2966,7 @@ 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 $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3248: checking for $ac_word" >&5
+echo "configure:2970: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_YACC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3284,7 +3006,7 @@ test -n "$YACC" || YACC="yacc"
   bison_version=none
   if test "$YACC"; then
     echo $ac_n "checking for bison version""... $ac_c" 1>&6
-echo "configure:3288: checking for bison version" >&5
+echo "configure:3010: checking for bison version" >&5
 if eval "test \"`echo '$''{'php_cv_bison_version'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3324,7 +3046,7 @@ echo "$ac_t""$php_cv_bison_version" 1>&6
   # Extract the first word of "flex", so it can be a program name with args.
 set dummy flex; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3328: checking for $ac_word" >&5
+echo "configure:3050: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3358,7 +3080,7 @@ then
   *) ac_lib=l ;;
   esac
   echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
-echo "configure:3362: checking for yywrap in -l$ac_lib" >&5
+echo "configure:3084: checking for yywrap in -l$ac_lib" >&5
 ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -3366,7 +3088,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$ac_lib  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 3370 "configure"
+#line 3092 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -3377,7 +3099,7 @@ int main() {
 yywrap()
 ; return 0; }
 EOF
-if { (eval echo configure:3381: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3103: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -3401,7 +3123,7 @@ fi
 
   if test "$LEX" = "flex"; then
     echo $ac_n "checking lex output file root""... $ac_c" 1>&6
-echo "configure:3405: checking lex output file root" >&5
+echo "configure:3127: checking lex output file root" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_lex_root'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3422,7 +3144,7 @@ echo "$ac_t""$ac_cv_prog_lex_root" 1>&6
 LEX_OUTPUT_ROOT=$ac_cv_prog_lex_root
 
 echo $ac_n "checking whether yytext is a pointer""... $ac_c" 1>&6
-echo "configure:3426: checking whether yytext is a pointer" >&5
+echo "configure:3148: checking whether yytext is a pointer" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_lex_yytext_pointer'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3434,14 +3156,14 @@ echo 'extern char *yytext;' >>$LEX_OUTPUT_ROOT.c
 ac_save_LIBS="$LIBS"
 LIBS="$LIBS $LEXLIB"
 cat > conftest.$ac_ext <<EOF
-#line 3438 "configure"
+#line 3160 "configure"
 #include "confdefs.h"
 `cat $LEX_OUTPUT_ROOT.c`
 int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:3445: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3167: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_cv_prog_lex_yytext_pointer=yes
 else
@@ -3465,12 +3187,12 @@ fi
     :
   fi
         echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:3469: checking for working const" >&5
+echo "configure:3191: checking for working const" >&5
 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3474 "configure"
+#line 3196 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -3519,7 +3241,7 @@ ccp = (char const *const *) p;
 
 ; return 0; }
 EOF
-if { (eval echo configure:3523: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3245: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_const=yes
 else
@@ -3545,7 +3267,7 @@ fi
 
   if test "$LEX" = "flex"; then
     echo $ac_n "checking for flex version""... $ac_c" 1>&6
-echo "configure:3549: checking for flex version" >&5
+echo "configure:3271: checking for flex version" >&5
 if eval "test \"`echo '$''{'php_cv_flex_version'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3589,7 +3311,7 @@ echo "$ac_t""$php_cv_flex_version" 1>&6
   # Extract the first word of "re2c", so it can be a program name with args.
 set dummy re2c; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3593: checking for $ac_word" >&5
+echo "configure:3315: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_RE2C'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3617,7 +3339,7 @@ fi
 
   if test -n "$RE2C"; then
     echo $ac_n "checking for re2c version""... $ac_c" 1>&6
-echo "configure:3621: checking for re2c version" >&5
+echo "configure:3343: checking for re2c version" >&5
 if eval "test \"`echo '$''{'php_cv_re2c_version'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3665,6 +3387,7 @@ case $host_cpu in
     if test "$SUNCC" = "yes"; then
       CFLAGS="$CFLAGS -xmemalign=8s"
     fi
+    ;;
 esac
 
 case $host_alias in
@@ -3682,7 +3405,7 @@ case $host_alias in
       
   gcc_arg_name=ac_cv_gcc_arg_no_cpp_precomp
   echo $ac_n "checking whether $CC supports -no-cpp-precomp""... $ac_c" 1>&6
-echo "configure:3686: checking whether $CC supports -no-cpp-precomp" >&5
+echo "configure:3409: checking whether $CC supports -no-cpp-precomp" >&5
 if eval "test \"`echo '$''{'ac_cv_gcc_arg_no_cpp_precomp'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3711,10 +3434,17 @@ echo "$ac_t""$ac_cv_gcc_arg_no_cpp_precomp" 1>&6
         CPPFLAGS="$CPPFLAGS -no-cpp-precomp"
       fi
     fi
-    cat >> confdefs.h <<\EOF
+
+    macosx_major=`sw_vers -productVersion | cut -d . -f 1`
+    macosx_minor=`sw_vers -productVersion | cut -d . -f 2`
+
+    if test "$macosx_major" -ge "10" && test "$macosx_minor" -lt "6" ; then
+      cat >> confdefs.h <<\EOF
 #define BIND_8_COMPAT 1
 EOF
 
+    fi
+
     php_multiple_shlib_versions_ok=yes
     ;;
   *beos*)
@@ -3887,7 +3617,7 @@ esac
 # Disable PIC mode by default where it is known to be safe to do so,
 # to avoid the performance hit from the lost register
 echo $ac_n "checking whether to force non-PIC code in shared modules""... $ac_c" 1>&6
-echo "configure:3891: checking whether to force non-PIC code in shared modules" >&5
+echo "configure:3621: checking whether to force non-PIC code in shared modules" >&5
 case $host_alias in
   i?86-*-linux*|i?86-*-freebsd*)
     if test "${with_pic+set}" != "set" || test "$with_pic" = "no"; then
@@ -3917,7 +3647,7 @@ esac
 
 
 echo $ac_n "checking whether /dev/urandom exists""... $ac_c" 1>&6
-echo "configure:3921: checking whether /dev/urandom exists" >&5 
+echo "configure:3651: checking whether /dev/urandom exists" >&5 
 if test -r "/dev/urandom" && test -c "/dev/urandom"; then 
   cat >> confdefs.h <<\EOF
 #define HAVE_DEV_URANDOM 1
@@ -3978,7 +3708,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 3982 "configure"
+#line 3712 "configure"
 #include "confdefs.h"
 
 #include <pthread.h>
@@ -3996,7 +3726,7 @@ int main() {
     return pthread_create(&thd, NULL, thread_routine, &data);
 } 
 EOF
-if { (eval echo configure:4000: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3730: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   pthreads_working=yes
@@ -4016,7 +3746,7 @@ fi
   CFLAGS=$save_CFLAGS
 
   echo $ac_n "checking for pthreads_cflags""... $ac_c" 1>&6
-echo "configure:4020: checking for pthreads_cflags" >&5
+echo "configure:3750: checking for pthreads_cflags" >&5
 if eval "test \"`echo '$''{'ac_cv_pthreads_cflags'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4038,7 +3768,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 4042 "configure"
+#line 3772 "configure"
 #include "confdefs.h"
 
 #include <pthread.h>
@@ -4056,7 +3786,7 @@ int main() {
     return pthread_create(&thd, NULL, thread_routine, &data);
 } 
 EOF
-if { (eval echo configure:4060: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3790: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   pthreads_working=yes
@@ -4086,7 +3816,7 @@ fi
 echo "$ac_t""$ac_cv_pthreads_cflags" 1>&6
 
 echo $ac_n "checking for pthreads_lib""... $ac_c" 1>&6
-echo "configure:4090: checking for pthreads_lib" >&5
+echo "configure:3820: checking for pthreads_lib" >&5
 if eval "test \"`echo '$''{'ac_cv_pthreads_lib'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4108,7 +3838,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 4112 "configure"
+#line 3842 "configure"
 #include "confdefs.h"
 
 #include <pthread.h>
@@ -4126,7 +3856,7 @@ int main() {
     return pthread_create(&thd, NULL, thread_routine, &data);
 } 
 EOF
-if { (eval echo configure:4130: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3860: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   pthreads_working=yes
@@ -4260,7 +3990,7 @@ ext_output=$PHP_AOLSERVER
 
 
 echo $ac_n "checking for AOLserver support""... $ac_c" 1>&6
-echo "configure:4264: checking for AOLserver support" >&5
+echo "configure:3994: checking for AOLserver support" >&5
 
 if test "$PHP_AOLSERVER" != "no"; then
   if test -d "$PHP_AOLSERVER/include"; then
@@ -4517,7 +4247,7 @@ ext_output=$PHP_APXS
 
 
 echo $ac_n "checking for Apache 1.x module support via DSO through APXS""... $ac_c" 1>&6
-echo "configure:4521: checking for Apache 1.x module support via DSO through APXS" >&5
+echo "configure:4251: checking for Apache 1.x module support via DSO through APXS" >&5
 
 if test "$PHP_APXS" != "no"; then
   if test "$PHP_APXS" = "yes"; then
@@ -4840,7 +4570,7 @@ ext_output=$PHP_APACHE
 
 
 echo $ac_n "checking for Apache 1.x module support""... $ac_c" 1>&6
-echo "configure:4844: checking for Apache 1.x module support" >&5
+echo "configure:4574: checking for Apache 1.x module support" >&5
 
 if test "$PHP_SAPI" != "apache" && test "$PHP_APACHE" != "no"; then
   
@@ -5673,7 +5403,7 @@ fi
 php_enable_mod_charset=no
 
 echo $ac_n "checking whether to enable Apache charset compatibility option""... $ac_c" 1>&6
-echo "configure:5677: checking whether to enable Apache charset compatibility option" >&5
+echo "configure:5407: checking whether to enable Apache charset compatibility option" >&5
 # Check whether --enable-mod-charset or --disable-mod-charset was given.
 if test "${enable_mod_charset+set}" = set; then
   enableval="$enable_mod_charset"
@@ -5708,7 +5438,7 @@ if test "$APACHE_MODULE" = "yes"; then
         
   gcc_arg_name=ac_cv_gcc_arg_rdynamic
   echo $ac_n "checking whether $CC supports -rdynamic""... $ac_c" 1>&6
-echo "configure:5712: checking whether $CC supports -rdynamic" >&5
+echo "configure:5442: checking whether $CC supports -rdynamic" >&5
 if eval "test \"`echo '$''{'ac_cv_gcc_arg_rdynamic'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -5751,7 +5481,7 @@ if test -n "$APACHE_INSTALL"; then
 
   
 echo $ac_n "checking for member fd in BUFF *""... $ac_c" 1>&6
-echo "configure:5755: checking for member fd in BUFF *" >&5
+echo "configure:5485: checking for member fd in BUFF *" >&5
 if eval "test \"`echo '$''{'ac_cv_php_fd_in_buff'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -5763,14 +5493,14 @@ else
     CPPFLAGS="$CPPFLAGS $APACHE_INCLUDE"
   fi
   cat > conftest.$ac_ext <<EOF
-#line 5767 "configure"
+#line 5497 "configure"
 #include "confdefs.h"
 #include <httpd.h>
 int main() {
 conn_rec *c; int fd = c->client->fd;
 ; return 0; }
 EOF
-if { (eval echo configure:5774: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5504: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
     ac_cv_php_fd_in_buff=yes
@@ -5846,7 +5576,7 @@ ext_output=$PHP_APXS2FILTER
 
 
 echo $ac_n "checking for Apache 2.0 filter-module support via DSO through APXS""... $ac_c" 1>&6
-echo "configure:5850: checking for Apache 2.0 filter-module support via DSO through APXS" >&5
+echo "configure:5580: checking for Apache 2.0 filter-module support via DSO through APXS" >&5
 
 if test "$PHP_APXS2FILTER" != "no"; then
   if test "$PHP_APXS2FILTER" = "yes"; then
@@ -6694,7 +6424,7 @@ ext_output=$PHP_APXS2
 
 
 echo $ac_n "checking for Apache 2.0 handler-module support via DSO through APXS""... $ac_c" 1>&6
-echo "configure:6698: checking for Apache 2.0 handler-module support via DSO through APXS" >&5
+echo "configure:6428: checking for Apache 2.0 handler-module support via DSO through APXS" >&5
 
 if test "$PHP_APXS2" != "no"; then
   if test "$PHP_APXS2" = "yes"; then
@@ -7543,7 +7273,7 @@ ext_output=$PHP_APACHE_HOOKS
 
 
 echo $ac_n "checking for Apache 1.x (hooks) module support via DSO through APXS""... $ac_c" 1>&6
-echo "configure:7547: checking for Apache 1.x (hooks) module support via DSO through APXS" >&5
+echo "configure:7277: checking for Apache 1.x (hooks) module support via DSO through APXS" >&5
 
 if test "$PHP_APACHE_HOOKS" != "no"; then
   if test "$PHP_APACHE_HOOKS" = "yes"; then
@@ -7866,7 +7596,7 @@ ext_output=$PHP_APACHE_HOOKS_STATIC
 
 
 echo $ac_n "checking for Apache 1.x (hooks) module support""... $ac_c" 1>&6
-echo "configure:7870: checking for Apache 1.x (hooks) module support" >&5
+echo "configure:7600: checking for Apache 1.x (hooks) module support" >&5
 
 if test "$PHP_SAPI" != "apache" && test "$PHP_SAPI" != "apache_hooks" && test "$PHP_APACHE_HOOKS_STATIC" != "no"; then
 
@@ -8699,7 +8429,7 @@ fi
 php_enable_mod_charset=no
 
 echo $ac_n "checking whether to enable Apache charset compatibility option""... $ac_c" 1>&6
-echo "configure:8703: checking whether to enable Apache charset compatibility option" >&5
+echo "configure:8433: checking whether to enable Apache charset compatibility option" >&5
 # Check whether --enable-mod-charset or --disable-mod-charset was given.
 if test "${enable_mod_charset+set}" = set; then
   enableval="$enable_mod_charset"
@@ -8734,7 +8464,7 @@ if test "$APACHE_HOOKS_MODULE" = "yes"; then
         
   gcc_arg_name=ac_cv_gcc_arg_rdynamic
   echo $ac_n "checking whether $CC supports -rdynamic""... $ac_c" 1>&6
-echo "configure:8738: checking whether $CC supports -rdynamic" >&5
+echo "configure:8468: checking whether $CC supports -rdynamic" >&5
 if eval "test \"`echo '$''{'ac_cv_gcc_arg_rdynamic'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -8777,7 +8507,7 @@ if test -n "$APACHE_HOOKS_INSTALL"; then
 
   
 echo $ac_n "checking for member fd in BUFF *""... $ac_c" 1>&6
-echo "configure:8781: checking for member fd in BUFF *" >&5
+echo "configure:8511: checking for member fd in BUFF *" >&5
 if eval "test \"`echo '$''{'ac_cv_php_fd_in_buff'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -8789,14 +8519,14 @@ else
     CPPFLAGS="$CPPFLAGS $APACHE_INCLUDE"
   fi
   cat > conftest.$ac_ext <<EOF
-#line 8793 "configure"
+#line 8523 "configure"
 #include "confdefs.h"
 #include <httpd.h>
 int main() {
 conn_rec *c; int fd = c->client->fd;
 ; return 0; }
 EOF
-if { (eval echo configure:8800: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:8530: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
     ac_cv_php_fd_in_buff=yes
@@ -8873,7 +8603,7 @@ ext_output=$PHP_CAUDIUM
 
 
 echo $ac_n "checking for Caudium support""... $ac_c" 1>&6
-echo "configure:8877: checking for Caudium support" >&5
+echo "configure:8607: checking for Caudium support" >&5
 
 if test "$PHP_CAUDIUM" != "no"; then
   if test "$prefix" = "NONE"; then CPREF=/usr/local/; fi
@@ -8943,7 +8673,7 @@ if test "$PHP_CAUDIUM" != "no"; then
       PIKE_C_INCLUDE=/usr/local/include/`basename $PIKE`
     fi
     echo $ac_n "checking for C includes in $PIKE_C_INCLUDE""... $ac_c" 1>&6
-echo "configure:8947: checking for C includes in $PIKE_C_INCLUDE" >&5
+echo "configure:8677: checking for C includes in $PIKE_C_INCLUDE" >&5
     if test -f $PIKE_C_INCLUDE/version.h; then
       PIKE_TEST_VER=`$PIKE -e 'string v; int rel;sscanf(version(), "Pike v%s release %d", v, rel); write(v+"."+rel);'`
       ###### VERSION MATCH CHECK #######
@@ -9224,7 +8954,7 @@ ext_output=$PHP_CLI
 
 
 echo $ac_n "checking for CLI build""... $ac_c" 1>&6
-echo "configure:9228: checking for CLI build" >&5
+echo "configure:8958: checking for CLI build" >&5
 if test "$PHP_CLI" != "no"; then
   
   src=$abs_srcdir/sapi/cli/Makefile.frag
@@ -9274,7 +9004,7 @@ echo "$ac_t""$PHP_CLI" 1>&6
 php_with_continuity=no
 
 echo $ac_n "checking for Continuity support""... $ac_c" 1>&6
-echo "configure:9278: checking for Continuity support" >&5
+echo "configure:9008: checking for Continuity support" >&5
 # Check whether --with-continuity or --without-continuity was given.
 if test "${with_continuity+set}" = set; then
   withval="$with_continuity"
@@ -9301,7 +9031,7 @@ if test "$PHP_CONTINUITY" != "no"; then
     { echo "configure: error: Please specify the path to the root of your Continuity server using --with-continuity=DIR" 1>&2; exit 1; }
   fi
   echo $ac_n "checking for Continuity include files""... $ac_c" 1>&6
-echo "configure:9305: checking for Continuity include files" >&5
+echo "configure:9035: checking for Continuity include files" >&5
   if test -d $PHP_CONTINUITY/include ; then
     CAPI_INCLUDE=$PHP_CONTINUITY/include
     echo "$ac_t""Continuity Binary Distribution" 1>&6
@@ -9551,7 +9281,7 @@ ext_output=$PHP_EMBED
 
 
 echo $ac_n "checking for embedded SAPI library support""... $ac_c" 1>&6
-echo "configure:9555: checking for embedded SAPI library support" >&5
+echo "configure:9285: checking for embedded SAPI library support" >&5
 
 if test "$PHP_EMBED" != "no"; then
   case "$PHP_EMBED" in
@@ -9768,7 +9498,7 @@ fi
 php_with_isapi=no
 
 echo $ac_n "checking for Zeus ISAPI support""... $ac_c" 1>&6
-echo "configure:9772: checking for Zeus ISAPI support" >&5
+echo "configure:9502: checking for Zeus ISAPI support" >&5
 # Check whether --with-isapi or --without-isapi was given.
 if test "${with_isapi+set}" = set; then
   withval="$with_isapi"
@@ -10017,7 +9747,7 @@ fi
 php_with_milter=no
 
 echo $ac_n "checking for Milter support""... $ac_c" 1>&6
-echo "configure:10021: checking for Milter support" >&5
+echo "configure:9751: checking for Milter support" >&5
 # Check whether --with-milter or --without-milter was given.
 if test "${with_milter+set}" = set; then
   withval="$with_milter"
@@ -10301,7 +10031,7 @@ fi
 php_with_nsapi=no
 
 echo $ac_n "checking for NSAPI support""... $ac_c" 1>&6
-echo "configure:10305: checking for NSAPI support" >&5
+echo "configure:10035: checking for NSAPI support" >&5
 # Check whether --with-nsapi or --without-nsapi was given.
 if test "${with_nsapi+set}" = set; then
   withval="$with_nsapi"
@@ -10328,7 +10058,7 @@ if test "$PHP_NSAPI" != "no"; then
     { echo "configure: error: Please specify the path to the root of your Netscape/iPlanet/Sun Webserver using --with-nsapi=DIR" 1>&2; exit 1; }
   fi
   echo $ac_n "checking for NSAPI include files""... $ac_c" 1>&6
-echo "configure:10332: checking for NSAPI include files" >&5
+echo "configure:10062: checking for NSAPI include files" >&5
   if test -d $PHP_NSAPI/include ; then
     NSAPI_INC_DIR="$PHP_NSAPI/include"
     echo "$ac_t""Netscape 3.x / Sun 7.x style" 1>&6
@@ -10336,17 +10066,17 @@ echo "configure:10332: checking for NSAPI include files" >&5
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:10340: checking for $ac_hdr" >&5
+echo "configure:10070: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 10345 "configure"
+#line 10075 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:10350: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:10080: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -10381,17 +10111,17 @@ done
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:10385: checking for $ac_hdr" >&5
+echo "configure:10115: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 10390 "configure"
+#line 10120 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:10395: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:10125: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -10653,7 +10383,7 @@ fi
 php_with_phttpd=no
 
 echo $ac_n "checking for PHTTPD support""... $ac_c" 1>&6
-echo "configure:10657: checking for PHTTPD support" >&5
+echo "configure:10387: checking for PHTTPD support" >&5
 # Check whether --with-phttpd or --without-phttpd was given.
 if test "${with_phttpd+set}" = set; then
   withval="$with_phttpd"
@@ -10899,7 +10629,7 @@ fi
 php_with_pi3web=no
 
 echo $ac_n "checking for Pi3Web support""... $ac_c" 1>&6
-echo "configure:10903: checking for Pi3Web support" >&5
+echo "configure:10633: checking for Pi3Web support" >&5
 # Check whether --with-pi3web or --without-pi3web was given.
 if test "${with_pi3web+set}" = set; then
   withval="$with_pi3web"
@@ -11266,7 +10996,7 @@ ext_output=$PHP_ROXEN
 php_enable_roxen_zts=no
 
 echo $ac_n "checking whether Roxen module is build using ZTS""... $ac_c" 1>&6
-echo "configure:11270: checking whether Roxen module is build using ZTS" >&5
+echo "configure:11000: checking whether Roxen module is build using ZTS" >&5
 # Check whether --enable-roxen-zts or --disable-roxen-zts was given.
 if test "${enable_roxen_zts+set}" = set; then
   enableval="$enable_roxen_zts"
@@ -11290,7 +11020,7 @@ echo "$ac_t""$ext_output" 1>&6
 
 RESULT=
 echo $ac_n "checking for Roxen/Pike support""... $ac_c" 1>&6
-echo "configure:11294: checking for Roxen/Pike support" >&5
+echo "configure:11024: checking for Roxen/Pike support" >&5
 if test "$PHP_ROXEN" != "no"; then
   if test ! -d $PHP_ROXEN ; then
     { echo "configure: error: You did not specify a directory" 1>&2; exit 1; }
@@ -11568,7 +11298,7 @@ ext_output=$PHP_THTTPD
 
 
 echo $ac_n "checking for thttpd""... $ac_c" 1>&6
-echo "configure:11572: checking for thttpd" >&5
+echo "configure:11302: checking for thttpd" >&5
 
 if test "$PHP_THTTPD" != "no"; then
   if test ! -d $PHP_THTTPD; then
@@ -11601,7 +11331,7 @@ if test "$PHP_THTTPD" != "no"; then
         
   gcc_arg_name=ac_cv_gcc_arg_rdynamic
   echo $ac_n "checking whether $CC supports -rdynamic""... $ac_c" 1>&6
-echo "configure:11605: checking whether $CC supports -rdynamic" >&5
+echo "configure:11335: checking whether $CC supports -rdynamic" >&5
 if eval "test \"`echo '$''{'ac_cv_gcc_arg_rdynamic'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -11829,24 +11559,24 @@ ext_output=$PHP_TUX
 
 
 echo $ac_n "checking for TUX""... $ac_c" 1>&6
-echo "configure:11833: checking for TUX" >&5
+echo "configure:11563: checking for TUX" >&5
 if test "$PHP_TUX" != "no"; then
   INSTALL_IT="\$(INSTALL) -m 0755 $SAPI_SHARED $PHP_TUX/php5.tux.so"
   for ac_hdr in tuxmodule.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:11840: checking for $ac_hdr" >&5
+echo "configure:11570: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 11845 "configure"
+#line 11575 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:11850: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:11580: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -12075,7 +11805,7 @@ ext_output=$PHP_WEBJAMES
 
 
 echo $ac_n "checking for webjames""... $ac_c" 1>&6
-echo "configure:12079: checking for webjames" >&5
+echo "configure:11809: checking for webjames" >&5
 
 if test "$PHP_WEBJAMES" != "no"; then
   
@@ -12427,7 +12157,7 @@ ext_output=$PHP_PATH_INFO_CHECK
 
 if test "$PHP_SAPI" = "default"; then
   echo $ac_n "checking whether to build CGI binary""... $ac_c" 1>&6
-echo "configure:12431: checking whether to build CGI binary" >&5
+echo "configure:12161: checking whether to build CGI binary" >&5
   if test "$PHP_CGI" != "no"; then
     echo "$ac_t""yes" 1>&6
     
@@ -12450,7 +12180,7 @@ echo "configure:12431: checking whether to build CGI binary" >&5
 
 
         echo $ac_n "checking whether to enable fastcgi support""... $ac_c" 1>&6
-echo "configure:12454: checking whether to enable fastcgi support" >&5
+echo "configure:12184: checking whether to enable fastcgi support" >&5
     if test "$PHP_FASTCGI" = "yes"; then
       PHP_ENABLE_FASTCGI=1
       PHP_FCGI_FILES="fastcgi.c"
@@ -12465,7 +12195,7 @@ EOF
     echo "$ac_t""$PHP_FASTCGI" 1>&6
 
         echo $ac_n "checking whether to force Apache CGI redirect""... $ac_c" 1>&6
-echo "configure:12469: checking whether to force Apache CGI redirect" >&5
+echo "configure:12199: checking whether to force Apache CGI redirect" >&5
     if test "$PHP_FORCE_CGI_REDIRECT" = "yes"; then
       CGI_REDIRECT=1
     else
@@ -12478,7 +12208,7 @@ EOF
     echo "$ac_t""$PHP_FORCE_CGI_REDIRECT" 1>&6
 
         echo $ac_n "checking whether to discard path_info + path_translated""... $ac_c" 1>&6
-echo "configure:12482: checking whether to discard path_info + path_translated" >&5
+echo "configure:12212: checking whether to discard path_info + path_translated" >&5
     if test "$PHP_DISCARD_PATH" = "yes"; then
       DISCARD_PATH=1
     else
@@ -12491,7 +12221,7 @@ EOF
     echo "$ac_t""$PHP_DISCARD_PATH" 1>&6
 
         echo $ac_n "checking whether to enable path info checking""... $ac_c" 1>&6
-echo "configure:12495: checking whether to enable path info checking" >&5
+echo "configure:12225: checking whether to enable path info checking" >&5
     if test "$PHP_PATH_INFO_CHECK" = "yes"; then
       ENABLE_PATHINFO_CHECK=1
     else
@@ -12703,7 +12433,7 @@ fi
 
 
 echo $ac_n "checking for chosen SAPI module""... $ac_c" 1>&6
-echo "configure:12707: checking for chosen SAPI module" >&5
+echo "configure:12437: checking for chosen SAPI module" >&5
 echo "$ac_t""$PHP_SAPI" 1>&6
 
 if test "$enable_maintainer_zts" = "yes"; then
@@ -12760,7 +12490,7 @@ fi
   # Extract the first word of "sendmail", so it can be a program name with args.
 set dummy sendmail; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:12764: checking for $ac_word" >&5
+echo "configure:12494: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_PROG_SENDMAIL'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -12799,7 +12529,7 @@ fi
 
 
   echo $ac_n "checking whether system uses EBCDIC""... $ac_c" 1>&6
-echo "configure:12803: checking whether system uses EBCDIC" >&5
+echo "configure:12533: checking whether system uses EBCDIC" >&5
 if eval "test \"`echo '$''{'ac_cv_ebcdic'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -12810,7 +12540,7 @@ else
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 12814 "configure"
+#line 12544 "configure"
 #include "confdefs.h"
 
 int main(void) { 
@@ -12818,7 +12548,7 @@ int main(void) {
 } 
 
 EOF
-if { (eval echo configure:12822: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:12552: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   ac_cv_ebcdic=yes
@@ -12846,7 +12576,7 @@ EOF
 
 
 echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
-echo "configure:12850: checking whether byte ordering is bigendian" >&5
+echo "configure:12580: checking whether byte ordering is bigendian" >&5
 if eval "test \"`echo '$''{'ac_cv_c_bigendian_php'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -12856,7 +12586,7 @@ else
   ac_cv_c_bigendian_php=unknown
 else
   cat > conftest.$ac_ext <<EOF
-#line 12860 "configure"
+#line 12590 "configure"
 #include "confdefs.h"
 
 int main(void)
@@ -12872,7 +12602,7 @@ int main(void)
 }
   
 EOF
-if { (eval echo configure:12876: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:12606: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_c_bigendian_php=yes
 else
@@ -12898,7 +12628,7 @@ EOF
 
 
   echo $ac_n "checking whether writing to stdout works""... $ac_c" 1>&6
-echo "configure:12902: checking whether writing to stdout works" >&5
+echo "configure:12632: checking whether writing to stdout works" >&5
 if eval "test \"`echo '$''{'ac_cv_write_stdout'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -12909,7 +12639,7 @@ else
     
 else
   cat > conftest.$ac_ext <<EOF
-#line 12913 "configure"
+#line 12643 "configure"
 #include "confdefs.h"
 
 #ifdef HAVE_UNISTD_H
@@ -12927,7 +12657,7 @@ main()
 }
     
 EOF
-if { (eval echo configure:12931: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:12661: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
       ac_cv_write_stdout=yes
@@ -13002,12 +12732,12 @@ test -d /usr/ucblib &&
   unset found
   
   echo $ac_n "checking for socket""... $ac_c" 1>&6
-echo "configure:13006: checking for socket" >&5
+echo "configure:12736: checking for socket" >&5
 if eval "test \"`echo '$''{'ac_cv_func_socket'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 13011 "configure"
+#line 12741 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char socket(); below.  */
@@ -13030,7 +12760,7 @@ socket();
 
 ; return 0; }
 EOF
-if { (eval echo configure:13034: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:12764: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_socket=yes"
 else
@@ -13048,12 +12778,12 @@ if eval "test \"`echo '$ac_cv_func_'socket`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
  echo $ac_n "checking for __socket""... $ac_c" 1>&6
-echo "configure:13052: checking for __socket" >&5
+echo "configure:12782: checking for __socket" >&5
 if eval "test \"`echo '$''{'ac_cv_func___socket'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 13057 "configure"
+#line 12787 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char __socket(); below.  */
@@ -13076,7 +12806,7 @@ __socket();
 
 ; return 0; }
 EOF
-if { (eval echo configure:13080: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:12810: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func___socket=yes"
 else
@@ -13114,7 +12844,7 @@ EOF
   unset ac_cv_lib_socket___socket
   unset found
   echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6
-echo "configure:13118: checking for socket in -lsocket" >&5
+echo "configure:12848: checking for socket in -lsocket" >&5
 ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13122,7 +12852,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13126 "configure"
+#line 12856 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13133,7 +12863,7 @@ int main() {
 socket()
 ; return 0; }
 EOF
-if { (eval echo configure:13137: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:12867: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13153,7 +12883,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __socket in -lsocket""... $ac_c" 1>&6
-echo "configure:13157: checking for __socket in -lsocket" >&5
+echo "configure:12887: checking for __socket in -lsocket" >&5
 ac_lib_var=`echo socket'_'__socket | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13161,7 +12891,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13165 "configure"
+#line 12895 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13172,7 +12902,7 @@ int main() {
 __socket()
 ; return 0; }
 EOF
-if { (eval echo configure:13176: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:12906: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13204,11 +12934,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 13208 "configure"
+#line 12938 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:13212: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:12942: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -13259,12 +12989,12 @@ EOF
   unset found
   
   echo $ac_n "checking for socketpair""... $ac_c" 1>&6
-echo "configure:13263: checking for socketpair" >&5
+echo "configure:12993: checking for socketpair" >&5
 if eval "test \"`echo '$''{'ac_cv_func_socketpair'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 13268 "configure"
+#line 12998 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char socketpair(); below.  */
@@ -13287,7 +13017,7 @@ socketpair();
 
 ; return 0; }
 EOF
-if { (eval echo configure:13291: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13021: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_socketpair=yes"
 else
@@ -13305,12 +13035,12 @@ if eval "test \"`echo '$ac_cv_func_'socketpair`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
  echo $ac_n "checking for __socketpair""... $ac_c" 1>&6
-echo "configure:13309: checking for __socketpair" >&5
+echo "configure:13039: checking for __socketpair" >&5
 if eval "test \"`echo '$''{'ac_cv_func___socketpair'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 13314 "configure"
+#line 13044 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char __socketpair(); below.  */
@@ -13333,7 +13063,7 @@ __socketpair();
 
 ; return 0; }
 EOF
-if { (eval echo configure:13337: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13067: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func___socketpair=yes"
 else
@@ -13371,7 +13101,7 @@ EOF
   unset ac_cv_lib_socket___socketpair
   unset found
   echo $ac_n "checking for socketpair in -lsocket""... $ac_c" 1>&6
-echo "configure:13375: checking for socketpair in -lsocket" >&5
+echo "configure:13105: checking for socketpair in -lsocket" >&5
 ac_lib_var=`echo socket'_'socketpair | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13379,7 +13109,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13383 "configure"
+#line 13113 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13390,7 +13120,7 @@ int main() {
 socketpair()
 ; return 0; }
 EOF
-if { (eval echo configure:13394: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13124: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13410,7 +13140,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __socketpair in -lsocket""... $ac_c" 1>&6
-echo "configure:13414: checking for __socketpair in -lsocket" >&5
+echo "configure:13144: checking for __socketpair in -lsocket" >&5
 ac_lib_var=`echo socket'_'__socketpair | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13418,7 +13148,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13422 "configure"
+#line 13152 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13429,7 +13159,7 @@ int main() {
 __socketpair()
 ; return 0; }
 EOF
-if { (eval echo configure:13433: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13163: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13461,11 +13191,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 13465 "configure"
+#line 13195 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:13469: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:13199: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -13516,12 +13246,12 @@ EOF
   unset found
   
   echo $ac_n "checking for htonl""... $ac_c" 1>&6
-echo "configure:13520: checking for htonl" >&5
+echo "configure:13250: checking for htonl" >&5
 if eval "test \"`echo '$''{'ac_cv_func_htonl'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 13525 "configure"
+#line 13255 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char htonl(); below.  */
@@ -13544,7 +13274,7 @@ htonl();
 
 ; return 0; }
 EOF
-if { (eval echo configure:13548: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13278: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_htonl=yes"
 else
@@ -13562,12 +13292,12 @@ if eval "test \"`echo '$ac_cv_func_'htonl`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
  echo $ac_n "checking for __htonl""... $ac_c" 1>&6
-echo "configure:13566: checking for __htonl" >&5
+echo "configure:13296: checking for __htonl" >&5
 if eval "test \"`echo '$''{'ac_cv_func___htonl'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 13571 "configure"
+#line 13301 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char __htonl(); below.  */
@@ -13590,7 +13320,7 @@ __htonl();
 
 ; return 0; }
 EOF
-if { (eval echo configure:13594: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13324: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func___htonl=yes"
 else
@@ -13628,7 +13358,7 @@ EOF
   unset ac_cv_lib_socket___htonl
   unset found
   echo $ac_n "checking for htonl in -lsocket""... $ac_c" 1>&6
-echo "configure:13632: checking for htonl in -lsocket" >&5
+echo "configure:13362: checking for htonl in -lsocket" >&5
 ac_lib_var=`echo socket'_'htonl | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13636,7 +13366,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13640 "configure"
+#line 13370 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13647,7 +13377,7 @@ int main() {
 htonl()
 ; return 0; }
 EOF
-if { (eval echo configure:13651: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13381: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13667,7 +13397,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __htonl in -lsocket""... $ac_c" 1>&6
-echo "configure:13671: checking for __htonl in -lsocket" >&5
+echo "configure:13401: checking for __htonl in -lsocket" >&5
 ac_lib_var=`echo socket'_'__htonl | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13675,7 +13405,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13679 "configure"
+#line 13409 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13686,7 +13416,7 @@ int main() {
 __htonl()
 ; return 0; }
 EOF
-if { (eval echo configure:13690: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13420: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13718,11 +13448,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 13722 "configure"
+#line 13452 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:13726: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:13456: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -13773,12 +13503,12 @@ EOF
   unset found
   
   echo $ac_n "checking for gethostname""... $ac_c" 1>&6
-echo "configure:13777: checking for gethostname" >&5
+echo "configure:13507: checking for gethostname" >&5
 if eval "test \"`echo '$''{'ac_cv_func_gethostname'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 13782 "configure"
+#line 13512 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char gethostname(); below.  */
@@ -13801,7 +13531,7 @@ gethostname();
 
 ; return 0; }
 EOF
-if { (eval echo configure:13805: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13535: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_gethostname=yes"
 else
@@ -13819,12 +13549,12 @@ if eval "test \"`echo '$ac_cv_func_'gethostname`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
  echo $ac_n "checking for __gethostname""... $ac_c" 1>&6
-echo "configure:13823: checking for __gethostname" >&5
+echo "configure:13553: checking for __gethostname" >&5
 if eval "test \"`echo '$''{'ac_cv_func___gethostname'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 13828 "configure"
+#line 13558 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char __gethostname(); below.  */
@@ -13847,7 +13577,7 @@ __gethostname();
 
 ; return 0; }
 EOF
-if { (eval echo configure:13851: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13581: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func___gethostname=yes"
 else
@@ -13885,7 +13615,7 @@ EOF
   unset ac_cv_lib_nsl___gethostname
   unset found
   echo $ac_n "checking for gethostname in -lnsl""... $ac_c" 1>&6
-echo "configure:13889: checking for gethostname in -lnsl" >&5
+echo "configure:13619: checking for gethostname in -lnsl" >&5
 ac_lib_var=`echo nsl'_'gethostname | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13893,7 +13623,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lnsl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13897 "configure"
+#line 13627 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13904,7 +13634,7 @@ int main() {
 gethostname()
 ; return 0; }
 EOF
-if { (eval echo configure:13908: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13638: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13924,7 +13654,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __gethostname in -lnsl""... $ac_c" 1>&6
-echo "configure:13928: checking for __gethostname in -lnsl" >&5
+echo "configure:13658: checking for __gethostname in -lnsl" >&5
 ac_lib_var=`echo nsl'_'__gethostname | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13932,7 +13662,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lnsl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13936 "configure"
+#line 13666 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13943,7 +13673,7 @@ int main() {
 __gethostname()
 ; return 0; }
 EOF
-if { (eval echo configure:13947: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13677: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13975,11 +13705,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 13979 "configure"
+#line 13709 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:13983: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:13713: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -14030,12 +13760,12 @@ EOF
   unset found
   
   echo $ac_n "checking for gethostbyaddr""... $ac_c" 1>&6
-echo "configure:14034: checking for gethostbyaddr" >&5
+echo "configure:13764: checking for gethostbyaddr" >&5
 if eval "test \"`echo '$''{'ac_cv_func_gethostbyaddr'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 14039 "configure"
+#line 13769 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char gethostbyaddr(); below.  */
@@ -14058,7 +13788,7 @@ gethostbyaddr();
 
 ; return 0; }
 EOF
-if { (eval echo configure:14062: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13792: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_gethostbyaddr=yes"
 else
@@ -14076,12 +13806,12 @@ if eval "test \"`echo '$ac_cv_func_'gethostbyaddr`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
  echo $ac_n "checking for __gethostbyaddr""... $ac_c" 1>&6
-echo "configure:14080: checking for __gethostbyaddr" >&5
+echo "configure:13810: checking for __gethostbyaddr" >&5
 if eval "test \"`echo '$''{'ac_cv_func___gethostbyaddr'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 14085 "configure"
+#line 13815 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char __gethostbyaddr(); below.  */
@@ -14104,7 +13834,7 @@ __gethostbyaddr();
 
 ; return 0; }
 EOF
-if { (eval echo configure:14108: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13838: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func___gethostbyaddr=yes"
 else
@@ -14142,7 +13872,7 @@ EOF
   unset ac_cv_lib_nsl___gethostbyaddr
   unset found
   echo $ac_n "checking for gethostbyaddr in -lnsl""... $ac_c" 1>&6
-echo "configure:14146: checking for gethostbyaddr in -lnsl" >&5
+echo "configure:13876: checking for gethostbyaddr in -lnsl" >&5
 ac_lib_var=`echo nsl'_'gethostbyaddr | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -14150,7 +13880,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lnsl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 14154 "configure"
+#line 13884 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -14161,7 +13891,7 @@ int main() {
 gethostbyaddr()
 ; return 0; }
 EOF
-if { (eval echo configure:14165: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13895: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -14181,7 +13911,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __gethostbyaddr in -lnsl""... $ac_c" 1>&6
-echo "configure:14185: checking for __gethostbyaddr in -lnsl" >&5
+echo "configure:13915: checking for __gethostbyaddr in -lnsl" >&5
 ac_lib_var=`echo nsl'_'__gethostbyaddr | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -14189,7 +13919,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lnsl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 14193 "configure"
+#line 13923 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -14200,7 +13930,7 @@ int main() {
 __gethostbyaddr()
 ; return 0; }
 EOF
-if { (eval echo configure:14204: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13934: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -14232,11 +13962,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 14236 "configure"
+#line 13966 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:14240: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:13970: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -14287,12 +14017,12 @@ EOF
   unset found
   
   echo $ac_n "checking for yp_get_default_domain""... $ac_c" 1>&6
-echo "configure:14291: checking for yp_get_default_domain" >&5
+echo "configure:14021: checking for yp_get_default_domain" >&5
 if eval "test \"`echo '$''{'ac_cv_func_yp_get_default_domain'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 14296 "configure"
+#line 14026 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char yp_get_default_domain(); below.  */
@@ -14315,7 +14045,7 @@ yp_get_default_domain();
 
 ; return 0; }
 EOF
-if { (eval echo configure:14319: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14049: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_yp_get_default_domain=yes"
 else
@@ -14333,12 +14063,12 @@ if eval "test \"`echo '$ac_cv_func_'yp_get_default_domain`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
  echo $ac_n "checking for __yp_get_default_domain""... $ac_c" 1>&6
-echo "configure:14337: checking for __yp_get_default_domain" >&5
+echo "configure:14067: checking for __yp_get_default_domain" >&5
 if eval "test \"`echo '$''{'ac_cv_func___yp_get_default_domain'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 14342 "configure"
+#line 14072 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char __yp_get_default_domain(); below.  */
@@ -14361,7 +14091,7 @@ __yp_get_default_domain();
 
 ; return 0; }
 EOF
-if { (eval echo configure:14365: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14095: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func___yp_get_default_domain=yes"
 else
@@ -14399,7 +14129,7 @@ EOF
   unset ac_cv_lib_nsl___yp_get_default_domain
   unset found
   echo $ac_n "checking for yp_get_default_domain in -lnsl""... $ac_c" 1>&6
-echo "configure:14403: checking for yp_get_default_domain in -lnsl" >&5
+echo "configure:14133: checking for yp_get_default_domain in -lnsl" >&5
 ac_lib_var=`echo nsl'_'yp_get_default_domain | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -14407,7 +14137,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lnsl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 14411 "configure"
+#line 14141 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -14418,7 +14148,7 @@ int main() {
 yp_get_default_domain()
 ; return 0; }
 EOF
-if { (eval echo configure:14422: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14152: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -14438,7 +14168,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __yp_get_default_domain in -lnsl""... $ac_c" 1>&6
-echo "configure:14442: checking for __yp_get_default_domain in -lnsl" >&5
+echo "configure:14172: checking for __yp_get_default_domain in -lnsl" >&5
 ac_lib_var=`echo nsl'_'__yp_get_default_domain | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -14446,7 +14176,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lnsl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 14450 "configure"
+#line 14180 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -14457,7 +14187,7 @@ int main() {
 __yp_get_default_domain()
 ; return 0; }
 EOF
-if { (eval echo configure:14461: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14191: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -14489,11 +14219,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 14493 "configure"
+#line 14223 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:14497: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:14227: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -14545,12 +14275,12 @@ EOF
   unset found
   
   echo $ac_n "checking for dlopen""... $ac_c" 1>&6
-echo "configure:14549: checking for dlopen" >&5
+echo "configure:14279: checking for dlopen" >&5
 if eval "test \"`echo '$''{'ac_cv_func_dlopen'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 14554 "configure"
+#line 14284 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char dlopen(); below.  */
@@ -14573,7 +14303,7 @@ dlopen();
 
 ; return 0; }
 EOF
-if { (eval echo configure:14577: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14307: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_dlopen=yes"
 else
@@ -14591,12 +14321,12 @@ if eval "test \"`echo '$ac_cv_func_'dlopen`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
  echo $ac_n "checking for __dlopen""... $ac_c" 1>&6
-echo "configure:14595: checking for __dlopen" >&5
+echo "configure:14325: checking for __dlopen" >&5
 if eval "test \"`echo '$''{'ac_cv_func___dlopen'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 14600 "configure"
+#line 14330 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char __dlopen(); below.  */
@@ -14619,7 +14349,7 @@ __dlopen();
 
 ; return 0; }
 EOF
-if { (eval echo configure:14623: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14353: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func___dlopen=yes"
 else
@@ -14657,7 +14387,7 @@ EOF
   unset ac_cv_lib_dl___dlopen
   unset found
   echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
-echo "configure:14661: checking for dlopen in -ldl" >&5
+echo "configure:14391: checking for dlopen in -ldl" >&5
 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -14665,7 +14395,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 14669 "configure"
+#line 14399 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -14676,7 +14406,7 @@ int main() {
 dlopen()
 ; return 0; }
 EOF
-if { (eval echo configure:14680: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14410: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -14696,7 +14426,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __dlopen in -ldl""... $ac_c" 1>&6
-echo "configure:14700: checking for __dlopen in -ldl" >&5
+echo "configure:14430: checking for __dlopen in -ldl" >&5
 ac_lib_var=`echo dl'_'__dlopen | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -14704,7 +14434,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 14708 "configure"
+#line 14438 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -14715,7 +14445,7 @@ int main() {
 __dlopen()
 ; return 0; }
 EOF
-if { (eval echo configure:14719: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14449: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -14747,11 +14477,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 14751 "configure"
+#line 14481 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:14755: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:14485: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -14803,7 +14533,7 @@ EOF
 
 fi
 echo $ac_n "checking for sin in -lm""... $ac_c" 1>&6
-echo "configure:14807: checking for sin in -lm" >&5
+echo "configure:14537: checking for sin in -lm" >&5
 ac_lib_var=`echo m'_'sin | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -14811,7 +14541,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lm  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 14815 "configure"
+#line 14545 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -14822,7 +14552,7 @@ int main() {
 sin()
 ; return 0; }
 EOF
-if { (eval echo configure:14826: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14556: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -14856,12 +14586,12 @@ fi
   unset found
   
   echo $ac_n "checking for res_search""... $ac_c" 1>&6
-echo "configure:14860: checking for res_search" >&5
+echo "configure:14590: checking for res_search" >&5
 if eval "test \"`echo '$''{'ac_cv_func_res_search'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 14865 "configure"
+#line 14595 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char res_search(); below.  */
@@ -14884,7 +14614,7 @@ res_search();
 
 ; return 0; }
 EOF
-if { (eval echo configure:14888: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_res_search=yes"
 else
@@ -14902,12 +14632,12 @@ if eval "test \"`echo '$ac_cv_func_'res_search`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
  echo $ac_n "checking for __res_search""... $ac_c" 1>&6
-echo "configure:14906: checking for __res_search" >&5
+echo "configure:14636: checking for __res_search" >&5
 if eval "test \"`echo '$''{'ac_cv_func___res_search'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 14911 "configure"
+#line 14641 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char __res_search(); below.  */
@@ -14930,7 +14660,7 @@ __res_search();
 
 ; return 0; }
 EOF
-if { (eval echo configure:14934: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14664: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func___res_search=yes"
 else
@@ -14968,7 +14698,7 @@ EOF
   unset ac_cv_lib_resolv___res_search
   unset found
   echo $ac_n "checking for res_search in -lresolv""... $ac_c" 1>&6
-echo "configure:14972: checking for res_search in -lresolv" >&5
+echo "configure:14702: checking for res_search in -lresolv" >&5
 ac_lib_var=`echo resolv'_'res_search | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -14976,7 +14706,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lresolv  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 14980 "configure"
+#line 14710 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -14987,7 +14717,7 @@ int main() {
 res_search()
 ; return 0; }
 EOF
-if { (eval echo configure:14991: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14721: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -15007,7 +14737,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __res_search in -lresolv""... $ac_c" 1>&6
-echo "configure:15011: checking for __res_search in -lresolv" >&5
+echo "configure:14741: checking for __res_search in -lresolv" >&5
 ac_lib_var=`echo resolv'_'__res_search | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -15015,7 +14745,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lresolv  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 15019 "configure"
+#line 14749 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -15026,7 +14756,7 @@ int main() {
 __res_search()
 ; return 0; }
 EOF
-if { (eval echo configure:15030: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14760: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -15058,11 +14788,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 15062 "configure"
+#line 14792 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:15066: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:14796: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -15104,7 +14834,7 @@ EOF
   unset ac_cv_lib_bind___res_search
   unset found
   echo $ac_n "checking for res_search in -lbind""... $ac_c" 1>&6
-echo "configure:15108: checking for res_search in -lbind" >&5
+echo "configure:14838: checking for res_search in -lbind" >&5
 ac_lib_var=`echo bind'_'res_search | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -15112,7 +14842,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbind  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 15116 "configure"
+#line 14846 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -15123,7 +14853,7 @@ int main() {
 res_search()
 ; return 0; }
 EOF
-if { (eval echo configure:15127: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14857: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -15143,7 +14873,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __res_search in -lbind""... $ac_c" 1>&6
-echo "configure:15147: checking for __res_search in -lbind" >&5
+echo "configure:14877: checking for __res_search in -lbind" >&5
 ac_lib_var=`echo bind'_'__res_search | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -15151,7 +14881,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbind  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 15155 "configure"
+#line 14885 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -15162,7 +14892,7 @@ int main() {
 __res_search()
 ; return 0; }
 EOF
-if { (eval echo configure:15166: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14896: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -15194,11 +14924,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 15198 "configure"
+#line 14928 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:15202: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:14932: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -15240,7 +14970,7 @@ EOF
   unset ac_cv_lib_socket___res_search
   unset found
   echo $ac_n "checking for res_search in -lsocket""... $ac_c" 1>&6
-echo "configure:15244: checking for res_search in -lsocket" >&5
+echo "configure:14974: checking for res_search in -lsocket" >&5
 ac_lib_var=`echo socket'_'res_search | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -15248,7 +14978,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 15252 "configure"
+#line 14982 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -15259,7 +14989,7 @@ int main() {
 res_search()
 ; return 0; }
 EOF
-if { (eval echo configure:15263: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14993: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -15279,7 +15009,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __res_search in -lsocket""... $ac_c" 1>&6
-echo "configure:15283: checking for __res_search in -lsocket" >&5
+echo "configure:15013: checking for __res_search in -lsocket" >&5
 ac_lib_var=`echo socket'_'__res_search | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -15287,7 +15017,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 15291 "configure"
+#line 15021 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -15298,7 +15028,7 @@ int main() {
 __res_search()
 ; return 0; }
 EOF
-if { (eval echo configure:15302: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15032: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -15330,11 +15060,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 15334 "configure"
+#line 15064 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:15338: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:15068: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -15392,12 +15122,12 @@ EOF
   unset found
   
   echo $ac_n "checking for inet_aton""... $ac_c" 1>&6
-echo "configure:15396: checking for inet_aton" >&5
+echo "configure:15126: checking for inet_aton" >&5
 if eval "test \"`echo '$''{'ac_cv_func_inet_aton'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 15401 "configure"
+#line 15131 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char inet_aton(); below.  */
@@ -15420,7 +15150,7 @@ inet_aton();
 
 ; return 0; }
 EOF
-if { (eval echo configure:15424: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15154: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_inet_aton=yes"
 else
@@ -15438,12 +15168,12 @@ if eval "test \"`echo '$ac_cv_func_'inet_aton`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
  echo $ac_n "checking for __inet_aton""... $ac_c" 1>&6
-echo "configure:15442: checking for __inet_aton" >&5
+echo "configure:15172: checking for __inet_aton" >&5
 if eval "test \"`echo '$''{'ac_cv_func___inet_aton'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 15447 "configure"
+#line 15177 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char __inet_aton(); below.  */
@@ -15466,7 +15196,7 @@ __inet_aton();
 
 ; return 0; }
 EOF
-if { (eval echo configure:15470: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15200: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func___inet_aton=yes"
 else
@@ -15504,7 +15234,7 @@ EOF
   unset ac_cv_lib_resolv___inet_aton
   unset found
   echo $ac_n "checking for inet_aton in -lresolv""... $ac_c" 1>&6
-echo "configure:15508: checking for inet_aton in -lresolv" >&5
+echo "configure:15238: checking for inet_aton in -lresolv" >&5
 ac_lib_var=`echo resolv'_'inet_aton | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -15512,7 +15242,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lresolv  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 15516 "configure"
+#line 15246 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -15523,7 +15253,7 @@ int main() {
 inet_aton()
 ; return 0; }
 EOF
-if { (eval echo configure:15527: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15257: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -15543,7 +15273,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __inet_aton in -lresolv""... $ac_c" 1>&6
-echo "configure:15547: checking for __inet_aton in -lresolv" >&5
+echo "configure:15277: checking for __inet_aton in -lresolv" >&5
 ac_lib_var=`echo resolv'_'__inet_aton | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -15551,7 +15281,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lresolv  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 15555 "configure"
+#line 15285 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -15562,7 +15292,7 @@ int main() {
 __inet_aton()
 ; return 0; }
 EOF
-if { (eval echo configure:15566: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15296: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -15594,11 +15324,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 15598 "configure"
+#line 15328 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:15602: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:15332: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -15640,7 +15370,7 @@ EOF
   unset ac_cv_lib_bind___inet_aton
   unset found
   echo $ac_n "checking for inet_aton in -lbind""... $ac_c" 1>&6
-echo "configure:15644: checking for inet_aton in -lbind" >&5
+echo "configure:15374: checking for inet_aton in -lbind" >&5
 ac_lib_var=`echo bind'_'inet_aton | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -15648,7 +15378,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbind  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 15652 "configure"
+#line 15382 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -15659,7 +15389,7 @@ int main() {
 inet_aton()
 ; return 0; }
 EOF
-if { (eval echo configure:15663: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15393: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -15679,7 +15409,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __inet_aton in -lbind""... $ac_c" 1>&6
-echo "configure:15683: checking for __inet_aton in -lbind" >&5
+echo "configure:15413: checking for __inet_aton in -lbind" >&5
 ac_lib_var=`echo bind'_'__inet_aton | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -15687,7 +15417,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbind  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 15691 "configure"
+#line 15421 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -15698,7 +15428,7 @@ int main() {
 __inet_aton()
 ; return 0; }
 EOF
-if { (eval echo configure:15702: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15432: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -15730,11 +15460,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 15734 "configure"
+#line 15464 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:15738: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:15468: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -15788,12 +15518,12 @@ EOF
   unset found
   
   echo $ac_n "checking for dn_skipname""... $ac_c" 1>&6
-echo "configure:15792: checking for dn_skipname" >&5
+echo "configure:15522: checking for dn_skipname" >&5
 if eval "test \"`echo '$''{'ac_cv_func_dn_skipname'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 15797 "configure"
+#line 15527 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char dn_skipname(); below.  */
@@ -15816,7 +15546,7 @@ dn_skipname();
 
 ; return 0; }
 EOF
-if { (eval echo configure:15820: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15550: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_dn_skipname=yes"
 else
@@ -15834,12 +15564,12 @@ if eval "test \"`echo '$ac_cv_func_'dn_skipname`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
  echo $ac_n "checking for __dn_skipname""... $ac_c" 1>&6
-echo "configure:15838: checking for __dn_skipname" >&5
+echo "configure:15568: checking for __dn_skipname" >&5
 if eval "test \"`echo '$''{'ac_cv_func___dn_skipname'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 15843 "configure"
+#line 15573 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char __dn_skipname(); below.  */
@@ -15862,7 +15592,7 @@ __dn_skipname();
 
 ; return 0; }
 EOF
-if { (eval echo configure:15866: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15596: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func___dn_skipname=yes"
 else
@@ -15900,7 +15630,7 @@ EOF
   unset ac_cv_lib_resolv___dn_skipname
   unset found
   echo $ac_n "checking for dn_skipname in -lresolv""... $ac_c" 1>&6
-echo "configure:15904: checking for dn_skipname in -lresolv" >&5
+echo "configure:15634: checking for dn_skipname in -lresolv" >&5
 ac_lib_var=`echo resolv'_'dn_skipname | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -15908,7 +15638,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lresolv  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 15912 "configure"
+#line 15642 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -15919,7 +15649,7 @@ int main() {
 dn_skipname()
 ; return 0; }
 EOF
-if { (eval echo configure:15923: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15653: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -15939,7 +15669,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __dn_skipname in -lresolv""... $ac_c" 1>&6
-echo "configure:15943: checking for __dn_skipname in -lresolv" >&5
+echo "configure:15673: checking for __dn_skipname in -lresolv" >&5
 ac_lib_var=`echo resolv'_'__dn_skipname | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -15947,7 +15677,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lresolv  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 15951 "configure"
+#line 15681 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -15958,7 +15688,7 @@ int main() {
 __dn_skipname()
 ; return 0; }
 EOF
-if { (eval echo configure:15962: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15692: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -15990,11 +15720,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 15994 "configure"
+#line 15724 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:15998: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:15728: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -16036,7 +15766,7 @@ EOF
   unset ac_cv_lib_bind___dn_skipname
   unset found
   echo $ac_n "checking for dn_skipname in -lbind""... $ac_c" 1>&6
-echo "configure:16040: checking for dn_skipname in -lbind" >&5
+echo "configure:15770: checking for dn_skipname in -lbind" >&5
 ac_lib_var=`echo bind'_'dn_skipname | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -16044,7 +15774,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbind  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 16048 "configure"
+#line 15778 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -16055,7 +15785,7 @@ int main() {
 dn_skipname()
 ; return 0; }
 EOF
-if { (eval echo configure:16059: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15789: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -16075,7 +15805,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __dn_skipname in -lbind""... $ac_c" 1>&6
-echo "configure:16079: checking for __dn_skipname in -lbind" >&5
+echo "configure:15809: checking for __dn_skipname in -lbind" >&5
 ac_lib_var=`echo bind'_'__dn_skipname | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -16083,7 +15813,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbind  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 16087 "configure"
+#line 15817 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -16094,7 +15824,7 @@ int main() {
 __dn_skipname()
 ; return 0; }
 EOF
-if { (eval echo configure:16098: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:15828: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -16126,11 +15856,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 16130 "configure"
+#line 15860 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:16134: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:15864: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -16180,14 +15910,13 @@ EOF
 
 
 
-
 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:16186: checking for ANSI C header files" >&5
+echo "configure:15915: checking for ANSI C header files" >&5
 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 16191 "configure"
+#line 15920 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 #include <stdarg.h>
@@ -16195,7 +15924,7 @@ else
 #include <float.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:16199: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:15928: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -16212,7 +15941,7 @@ rm -f conftest*
 if test $ac_cv_header_stdc = yes; then
   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 16216 "configure"
+#line 15945 "configure"
 #include "confdefs.h"
 #include <string.h>
 EOF
@@ -16230,7 +15959,7 @@ fi
 if test $ac_cv_header_stdc = yes; then
   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 16234 "configure"
+#line 15963 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 EOF
@@ -16251,7 +15980,7 @@ if test "$cross_compiling" = yes; then
   :
 else
   cat > conftest.$ac_ext <<EOF
-#line 16255 "configure"
+#line 15984 "configure"
 #include "confdefs.h"
 #include <ctype.h>
 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -16262,7 +15991,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
 exit (0); }
 
 EOF
-if { (eval echo configure:16266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:15995: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   :
 else
@@ -16290,12 +16019,12 @@ for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
-echo "configure:16294: checking for $ac_hdr that defines DIR" >&5
+echo "configure:16023: checking for $ac_hdr that defines DIR" >&5
 if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 16299 "configure"
+#line 16028 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <$ac_hdr>
@@ -16303,7 +16032,7 @@ int main() {
 DIR *dirp = 0;
 ; return 0; }
 EOF
-if { (eval echo configure:16307: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16036: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   eval "ac_cv_header_dirent_$ac_safe=yes"
 else
@@ -16328,7 +16057,7 @@ done
 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
 if test $ac_header_dirent = dirent.h; then
 echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
-echo "configure:16332: checking for opendir in -ldir" >&5
+echo "configure:16061: checking for opendir in -ldir" >&5
 ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -16336,7 +16065,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldir  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 16340 "configure"
+#line 16069 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -16347,7 +16076,7 @@ int main() {
 opendir()
 ; return 0; }
 EOF
-if { (eval echo configure:16351: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:16080: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -16369,7 +16098,7 @@ fi
 
 else
 echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
-echo "configure:16373: checking for opendir in -lx" >&5
+echo "configure:16102: checking for opendir in -lx" >&5
 ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -16377,7 +16106,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lx  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 16381 "configure"
+#line 16110 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -16388,7 +16117,7 @@ int main() {
 opendir()
 ; return 0; }
 EOF
-if { (eval echo configure:16392: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:16121: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -16422,6 +16151,7 @@ sys/time.h \
 netinet/in.h \
 alloca.h \
 arpa/inet.h \
+arpa/nameser_compat.h \
 arpa/nameser.h \
 assert.h \
 crypt.h \
@@ -16469,17 +16199,17 @@ assert.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:16473: checking for $ac_hdr" >&5
+echo "configure:16203: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 16478 "configure"
+#line 16208 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:16483: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:16213: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -16514,17 +16244,17 @@ case $host_alias in
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:16518: checking for $ac_hdr" >&5
+echo "configure:16248: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 16523 "configure"
+#line 16253 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:16528: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:16258: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -16555,12 +16285,12 @@ esac
 
 
   echo $ac_n "checking for fopencookie""... $ac_c" 1>&6
-echo "configure:16559: checking for fopencookie" >&5
+echo "configure:16289: checking for fopencookie" >&5
 if eval "test \"`echo '$''{'ac_cv_func_fopencookie'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 16564 "configure"
+#line 16294 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char fopencookie(); below.  */
@@ -16583,7 +16313,7 @@ fopencookie();
 
 ; return 0; }
 EOF
-if { (eval echo configure:16587: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:16317: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_fopencookie=yes"
 else
@@ -16605,7 +16335,7 @@ fi
 
   if test "$have_glibc_fopencookie" = "yes"; then
 cat > conftest.$ac_ext <<EOF
-#line 16609 "configure"
+#line 16339 "configure"
 #include "confdefs.h"
 
 #define _GNU_SOURCE
@@ -16615,7 +16345,7 @@ int main() {
 cookie_io_functions_t cookie;
 ; return 0; }
 EOF
-if { (eval echo configure:16619: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16349: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   have_cookie_io_functions_t=yes
 else
@@ -16634,7 +16364,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 16638 "configure"
+#line 16368 "configure"
 #include "confdefs.h"
 
 #define _GNU_SOURCE
@@ -16666,7 +16396,7 @@ main() {
 
 
 EOF
-if { (eval echo configure:16670: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:16400: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   cookie_io_functions_use_off64_t=yes
@@ -16686,7 +16416,7 @@ fi
     else
 
 cat > conftest.$ac_ext <<EOF
-#line 16690 "configure"
+#line 16420 "configure"
 #include "confdefs.h"
 
 #define _GNU_SOURCE
@@ -16696,7 +16426,7 @@ int main() {
  _IO_cookie_io_functions_t cookie; 
 ; return 0; }
 EOF
-if { (eval echo configure:16700: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16430: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   have_IO_cookie_io_functions_t=yes
 else
@@ -16730,7 +16460,7 @@ EOF
 
 
   echo $ac_n "checking for broken getcwd""... $ac_c" 1>&6
-echo "configure:16734: checking for broken getcwd" >&5
+echo "configure:16464: checking for broken getcwd" >&5
   os=`uname -sr 2>/dev/null`
   case $os in
     SunOS*)
@@ -16745,14 +16475,14 @@ EOF
 
 
   echo $ac_n "checking for broken libc stdio""... $ac_c" 1>&6
-echo "configure:16749: checking for broken libc stdio" >&5
-  if eval "test \"`echo '$''{'have_broken_glibc_fopen_append'+set}'`\" = set"; then
+echo "configure:16479: checking for broken libc stdio" >&5
+  if eval "test \"`echo '$''{'_cv_have_broken_glibc_fopen_append'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
   if test "$cross_compiling" = yes; then
   cat > conftest.$ac_ext <<EOF
-#line 16756 "configure"
+#line 16486 "configure"
 #include "confdefs.h"
 
 #include <features.h>
@@ -16765,20 +16495,20 @@ choke me
 
 ; return 0; }
 EOF
-if { (eval echo configure:16769: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16499: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
-  have_broken_glibc_fopen_append=yes
+  _cv_have_broken_glibc_fopen_append=yes
 else
   echo "configure: failed program was:" >&5
   cat conftest.$ac_ext >&5
   rm -rf conftest*
-  have_broken_glibc_fopen_append=no 
+  _cv_have_broken_glibc_fopen_append=no 
 fi
 rm -f conftest*
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 16782 "configure"
+#line 16512 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -16806,14 +16536,14 @@ int main(int argc, char *argv[])
 }
 
 EOF
-if { (eval echo configure:16810: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:16540: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
-  have_broken_glibc_fopen_append=no
+  _cv_have_broken_glibc_fopen_append=no
 else
   echo "configure: failed program was:" >&5
   cat conftest.$ac_ext >&5
   rm -fr conftest*
-  have_broken_glibc_fopen_append=yes 
+  _cv_have_broken_glibc_fopen_append=yes 
 fi
 rm -fr conftest*
 fi
@@ -16821,7 +16551,7 @@ fi
 fi
 
 
-  if test "$have_broken_glibc_fopen_append" = "yes"; then
+  if test "$_cv_have_broken_glibc_fopen_append" = "yes"; then
     echo "$ac_t""yes" 1>&6
     cat >> confdefs.h <<\EOF
 #define HAVE_BROKEN_GLIBC_FOPEN_APPEND 1
@@ -16834,12 +16564,12 @@ EOF
 
 
 echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
-echo "configure:16838: checking whether struct tm is in sys/time.h or time.h" >&5
+echo "configure:16568: checking whether struct tm is in sys/time.h or time.h" >&5
 if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 16843 "configure"
+#line 16573 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <time.h>
@@ -16847,7 +16577,7 @@ int main() {
 struct tm *tp; tp->tm_sec;
 ; return 0; }
 EOF
-if { (eval echo configure:16851: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16581: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_struct_tm=time.h
 else
@@ -16868,12 +16598,12 @@ EOF
 fi
 
 echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6
-echo "configure:16872: checking for tm_zone in struct tm" >&5
+echo "configure:16602: checking for tm_zone in struct tm" >&5
 if eval "test \"`echo '$''{'ac_cv_struct_tm_zone'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 16877 "configure"
+#line 16607 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <$ac_cv_struct_tm>
@@ -16881,7 +16611,7 @@ int main() {
 struct tm tm; tm.tm_zone;
 ; return 0; }
 EOF
-if { (eval echo configure:16885: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16615: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_struct_tm_zone=yes
 else
@@ -16901,12 +16631,12 @@ EOF
 
 else
   echo $ac_n "checking for tzname""... $ac_c" 1>&6
-echo "configure:16905: checking for tzname" >&5
+echo "configure:16635: checking for tzname" >&5
 if eval "test \"`echo '$''{'ac_cv_var_tzname'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 16910 "configure"
+#line 16640 "configure"
 #include "confdefs.h"
 #include <time.h>
 #ifndef tzname /* For SGI.  */
@@ -16916,7 +16646,7 @@ int main() {
 atoi(*tzname);
 ; return 0; }
 EOF
-if { (eval echo configure:16920: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:16650: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_cv_var_tzname=yes
 else
@@ -16940,16 +16670,16 @@ fi
 
 
   echo $ac_n "checking for missing declarations of reentrant functions""... $ac_c" 1>&6
-echo "configure:16944: checking for missing declarations of reentrant functions" >&5
+echo "configure:16674: checking for missing declarations of reentrant functions" >&5
   cat > conftest.$ac_ext <<EOF
-#line 16946 "configure"
+#line 16676 "configure"
 #include "confdefs.h"
 #include <time.h>
 int main() {
 struct tm *(*func)() = localtime_r
 ; return 0; }
 EOF
-if { (eval echo configure:16953: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16683: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
     :
@@ -16967,14 +16697,14 @@ EOF
 fi
 rm -f conftest*
   cat > conftest.$ac_ext <<EOF
-#line 16971 "configure"
+#line 16701 "configure"
 #include "confdefs.h"
 #include <time.h>
 int main() {
 struct tm *(*func)() = gmtime_r
 ; return 0; }
 EOF
-if { (eval echo configure:16978: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16708: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
     :
@@ -16992,14 +16722,14 @@ EOF
 fi
 rm -f conftest*
   cat > conftest.$ac_ext <<EOF
-#line 16996 "configure"
+#line 16726 "configure"
 #include "confdefs.h"
 #include <time.h>
 int main() {
 char *(*func)() = asctime_r
 ; return 0; }
 EOF
-if { (eval echo configure:17003: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16733: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
     :
@@ -17017,14 +16747,14 @@ EOF
 fi
 rm -f conftest*
   cat > conftest.$ac_ext <<EOF
-#line 17021 "configure"
+#line 16751 "configure"
 #include "confdefs.h"
 #include <time.h>
 int main() {
 char *(*func)() = ctime_r
 ; return 0; }
 EOF
-if { (eval echo configure:17028: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16758: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
     :
@@ -17042,14 +16772,14 @@ EOF
 fi
 rm -f conftest*
   cat > conftest.$ac_ext <<EOF
-#line 17046 "configure"
+#line 16776 "configure"
 #include "confdefs.h"
 #include <string.h>
 int main() {
 char *(*func)() = strtok_r
 ; return 0; }
 EOF
-if { (eval echo configure:17053: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16783: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
     :
@@ -17070,16 +16800,16 @@ rm -f conftest*
 
 
   echo $ac_n "checking for fclose declaration""... $ac_c" 1>&6
-echo "configure:17074: checking for fclose declaration" >&5
+echo "configure:16804: checking for fclose declaration" >&5
   cat > conftest.$ac_ext <<EOF
-#line 17076 "configure"
+#line 16806 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main() {
 int (*func)() = fclose
 ; return 0; }
 EOF
-if { (eval echo configure:17083: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16813: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
     cat >> confdefs.h <<\EOF
@@ -17105,12 +16835,12 @@ rm -f conftest*
 
 
 echo $ac_n "checking for tm_gmtoff in struct tm""... $ac_c" 1>&6
-echo "configure:17109: checking for tm_gmtoff in struct tm" >&5
+echo "configure:16839: checking for tm_gmtoff in struct tm" >&5
 if eval "test \"`echo '$''{'ac_cv_struct_tm_gmtoff'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 17114 "configure"
+#line 16844 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <$ac_cv_struct_tm>
@@ -17118,7 +16848,7 @@ int main() {
 struct tm tm; tm.tm_gmtoff;
 ; return 0; }
 EOF
-if { (eval echo configure:17122: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16852: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_struct_tm_gmtoff=yes
 else
@@ -17141,12 +16871,12 @@ fi
 
 
 echo $ac_n "checking for struct flock""... $ac_c" 1>&6
-echo "configure:17145: checking for struct flock" >&5
+echo "configure:16875: checking for struct flock" >&5
 if eval "test \"`echo '$''{'ac_cv_struct_flock'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 17150 "configure"
+#line 16880 "configure"
 #include "confdefs.h"
 
 #include <unistd.h>
@@ -17156,7 +16886,7 @@ int main() {
 struct flock x;
 ; return 0; }
 EOF
-if { (eval echo configure:17160: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16890: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
           ac_cv_struct_flock=yes
@@ -17183,12 +16913,12 @@ fi
 
 
 echo $ac_n "checking for socklen_t""... $ac_c" 1>&6
-echo "configure:17187: checking for socklen_t" >&5
+echo "configure:16917: checking for socklen_t" >&5
 if eval "test \"`echo '$''{'ac_cv_socklen_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 17192 "configure"
+#line 16922 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -17200,7 +16930,7 @@ socklen_t x;
 
 ; return 0; }
 EOF
-if { (eval echo configure:17204: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:16934: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
   ac_cv_socklen_t=yes
@@ -17226,7 +16956,7 @@ fi
 
 
 echo $ac_n "checking size of size_t""... $ac_c" 1>&6
-echo "configure:17230: checking size of size_t" >&5
+echo "configure:16960: checking size of size_t" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_size_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -17234,7 +16964,7 @@ else
   ac_cv_sizeof_size_t=8
 else
   cat > conftest.$ac_ext <<EOF
-#line 17238 "configure"
+#line 16968 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -17245,7 +16975,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:17249: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:16979: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_size_t=`cat conftestval`
 else
@@ -17265,7 +16995,7 @@ EOF
 
 
 echo $ac_n "checking size of long long""... $ac_c" 1>&6
-echo "configure:17269: checking size of long long" >&5
+echo "configure:16999: checking size of long long" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -17273,7 +17003,7 @@ else
   ac_cv_sizeof_long_long=8
 else
   cat > conftest.$ac_ext <<EOF
-#line 17277 "configure"
+#line 17007 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -17284,7 +17014,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:17288: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:17018: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long_long=`cat conftestval`
 else
@@ -17304,7 +17034,7 @@ EOF
 
 
 echo $ac_n "checking size of long long int""... $ac_c" 1>&6
-echo "configure:17308: checking size of long long int" >&5
+echo "configure:17038: checking size of long long int" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long_long_int'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -17312,7 +17042,7 @@ else
   ac_cv_sizeof_long_long_int=8
 else
   cat > conftest.$ac_ext <<EOF
-#line 17316 "configure"
+#line 17046 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -17323,7 +17053,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:17327: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:17057: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long_long_int=`cat conftestval`
 else
@@ -17343,7 +17073,7 @@ EOF
 
 
 echo $ac_n "checking size of long""... $ac_c" 1>&6
-echo "configure:17347: checking size of long" >&5
+echo "configure:17077: checking size of long" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -17351,7 +17081,7 @@ else
   ac_cv_sizeof_long=8
 else
   cat > conftest.$ac_ext <<EOF
-#line 17355 "configure"
+#line 17085 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -17362,7 +17092,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:17366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:17096: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long=`cat conftestval`
 else
@@ -17382,7 +17112,7 @@ EOF
 
 
 echo $ac_n "checking size of int""... $ac_c" 1>&6
-echo "configure:17386: checking size of int" >&5
+echo "configure:17116: checking size of int" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -17390,7 +17120,7 @@ else
   ac_cv_sizeof_int=4
 else
   cat > conftest.$ac_ext <<EOF
-#line 17394 "configure"
+#line 17124 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -17401,7 +17131,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:17405: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:17135: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_int=`cat conftestval`
 else
@@ -17423,7 +17153,7 @@ EOF
 
 
   echo $ac_n "checking size of intmax_t""... $ac_c" 1>&6
-echo "configure:17427: checking size of intmax_t" >&5
+echo "configure:17157: checking size of intmax_t" >&5
   
   php_cache_value=php_cv_sizeof_intmax_t
   if eval "test \"`echo '$''{'php_cv_sizeof_intmax_t'+set}'`\" = set"; then
@@ -17440,7 +17170,7 @@ else
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 17444 "configure"
+#line 17174 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 #if STDC_HEADERS
@@ -17464,7 +17194,7 @@ int main()
 }
   
 EOF
-if { (eval echo configure:17468: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:17198: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     eval $php_cache_value=`cat conftestval`
@@ -17503,7 +17233,7 @@ EOF
 
 
   echo $ac_n "checking size of ssize_t""... $ac_c" 1>&6
-echo "configure:17507: checking size of ssize_t" >&5
+echo "configure:17237: checking size of ssize_t" >&5
   
   php_cache_value=php_cv_sizeof_ssize_t
   if eval "test \"`echo '$''{'php_cv_sizeof_ssize_t'+set}'`\" = set"; then
@@ -17520,7 +17250,7 @@ else
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 17524 "configure"
+#line 17254 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 #if STDC_HEADERS
@@ -17544,7 +17274,7 @@ int main()
 }
   
 EOF
-if { (eval echo configure:17548: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:17278: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     eval $php_cache_value=`cat conftestval`
@@ -17583,7 +17313,7 @@ EOF
 
 
   echo $ac_n "checking size of ptrdiff_t""... $ac_c" 1>&6
-echo "configure:17587: checking size of ptrdiff_t" >&5
+echo "configure:17317: checking size of ptrdiff_t" >&5
   
   php_cache_value=php_cv_sizeof_ptrdiff_t
   if eval "test \"`echo '$''{'php_cv_sizeof_ptrdiff_t'+set}'`\" = set"; then
@@ -17600,7 +17330,7 @@ else
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 17604 "configure"
+#line 17334 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 #if STDC_HEADERS
@@ -17624,7 +17354,7 @@ int main()
 }
   
 EOF
-if { (eval echo configure:17628: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:17358: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     eval $php_cache_value=`cat conftestval`
@@ -17663,12 +17393,12 @@ EOF
 
 
 echo $ac_n "checking for st_blksize in struct stat""... $ac_c" 1>&6
-echo "configure:17667: checking for st_blksize in struct stat" >&5
+echo "configure:17397: checking for st_blksize in struct stat" >&5
 if eval "test \"`echo '$''{'ac_cv_struct_st_blksize'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 17672 "configure"
+#line 17402 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/stat.h>
@@ -17676,7 +17406,7 @@ int main() {
 struct stat s; s.st_blksize;
 ; return 0; }
 EOF
-if { (eval echo configure:17680: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:17410: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_struct_st_blksize=yes
 else
@@ -17698,12 +17428,12 @@ fi
 
 if test "`uname -s 2>/dev/null`" != "QNX"; then
   echo $ac_n "checking for st_blocks in struct stat""... $ac_c" 1>&6
-echo "configure:17702: checking for st_blocks in struct stat" >&5
+echo "configure:17432: checking for st_blocks in struct stat" >&5
 if eval "test \"`echo '$''{'ac_cv_struct_st_blocks'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 17707 "configure"
+#line 17437 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/stat.h>
@@ -17711,7 +17441,7 @@ int main() {
 struct stat s; s.st_blocks;
 ; return 0; }
 EOF
-if { (eval echo configure:17715: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:17445: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_struct_st_blocks=yes
 else
@@ -17738,12 +17468,12 @@ else
   WARNING_LEVEL=0
 fi
 echo $ac_n "checking for st_rdev in struct stat""... $ac_c" 1>&6
-echo "configure:17742: checking for st_rdev in struct stat" >&5
+echo "configure:17472: checking for st_rdev in struct stat" >&5
 if eval "test \"`echo '$''{'ac_cv_struct_st_rdev'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 17747 "configure"
+#line 17477 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/stat.h>
@@ -17751,7 +17481,7 @@ int main() {
 struct stat s; s.st_rdev;
 ; return 0; }
 EOF
-if { (eval echo configure:17755: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:17485: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_struct_st_rdev=yes
 else
@@ -17773,12 +17503,12 @@ fi
 
 
 echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:17777: checking for size_t" >&5
+echo "configure:17507: checking for size_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 17782 "configure"
+#line 17512 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -17806,12 +17536,12 @@ EOF
 fi
 
 echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
-echo "configure:17810: checking for uid_t in sys/types.h" >&5
+echo "configure:17540: checking for uid_t in sys/types.h" >&5
 if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 17815 "configure"
+#line 17545 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 EOF
@@ -17842,12 +17572,12 @@ fi
 
 
     echo $ac_n "checking for struct sockaddr_storage""... $ac_c" 1>&6
-echo "configure:17846: checking for struct sockaddr_storage" >&5
+echo "configure:17576: checking for struct sockaddr_storage" >&5
 if eval "test \"`echo '$''{'ac_cv_sockaddr_storage'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 17851 "configure"
+#line 17581 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/socket.h>
@@ -17855,7 +17585,7 @@ int main() {
 struct sockaddr_storage s; s
 ; return 0; }
 EOF
-if { (eval echo configure:17859: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:17589: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_sockaddr_storage=yes
 else
@@ -17876,13 +17606,13 @@ EOF
 
   fi
     echo $ac_n "checking for field sa_len in struct sockaddr""... $ac_c" 1>&6
-echo "configure:17880: checking for field sa_len in struct sockaddr" >&5
+echo "configure:17610: checking for field sa_len in struct sockaddr" >&5
 if eval "test \"`echo '$''{'ac_cv_sockaddr_sa_len'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     cat > conftest.$ac_ext <<EOF
-#line 17886 "configure"
+#line 17616 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/socket.h>
@@ -17890,7 +17620,7 @@ int main() {
 static struct sockaddr sa; int n = (int) sa.sa_len; return n;
 ; return 0; }
 EOF
-if { (eval echo configure:17894: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:17624: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_sockaddr_sa_len=yes
 else
@@ -17913,12 +17643,12 @@ EOF
 
 
 echo $ac_n "checking for IPv6 support""... $ac_c" 1>&6
-echo "configure:17917: checking for IPv6 support" >&5
+echo "configure:17647: checking for IPv6 support" >&5
 if eval "test \"`echo '$''{'ac_cv_ipv6_support'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 17922 "configure"
+#line 17652 "configure"
 #include "confdefs.h"
  #include <sys/types.h>
 #include <sys/socket.h>
@@ -17927,7 +17657,7 @@ int main() {
 struct sockaddr_in6 s; struct in6_addr t=in6addr_any; int i=AF_INET6; s; t.s6_addr[0] = 0;
 ; return 0; }
 EOF
-if { (eval echo configure:17931: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:17661: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_cv_ipv6_support=yes
 else
@@ -17943,12 +17673,12 @@ echo "$ac_t""$ac_cv_ipv6_support" 1>&6
 
 
 echo $ac_n "checking for vprintf""... $ac_c" 1>&6
-echo "configure:17947: checking for vprintf" >&5
+echo "configure:17677: checking for vprintf" >&5
 if eval "test \"`echo '$''{'ac_cv_func_vprintf'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 17952 "configure"
+#line 17682 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char vprintf(); below.  */
@@ -17971,7 +17701,7 @@ vprintf();
 
 ; return 0; }
 EOF
-if { (eval echo configure:17975: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:17705: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_vprintf=yes"
 else
@@ -17995,12 +17725,12 @@ fi
 
 if test "$ac_cv_func_vprintf" != yes; then
 echo $ac_n "checking for _doprnt""... $ac_c" 1>&6
-echo "configure:17999: checking for _doprnt" >&5
+echo "configure:17729: checking for _doprnt" >&5
 if eval "test \"`echo '$''{'ac_cv_func__doprnt'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 18004 "configure"
+#line 17734 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char _doprnt(); below.  */
@@ -18023,7 +17753,7 @@ _doprnt();
 
 ; return 0; }
 EOF
-if { (eval echo configure:18027: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:17757: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func__doprnt=yes"
 else
@@ -18125,18 +17855,17 @@ tzset \
 unlockpt \
 unsetenv \
 usleep \
-nanosleep \
 utime \
 vsnprintf \
 
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:18135: checking for $ac_func" >&5
+echo "configure:17864: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 18140 "configure"
+#line 17869 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -18159,7 +17888,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:18163: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:17892: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -18184,26 +17913,177 @@ fi
 done
 
 
+echo $ac_n "checking for nanosleep""... $ac_c" 1>&6
+echo "configure:17918: checking for nanosleep" >&5
+if eval "test \"`echo '$''{'ac_cv_func_nanosleep'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  
+  
+  unset ac_cv_lib_rt_nanosleep
+  unset ac_cv_lib_rt___nanosleep
+  unset found
+  echo $ac_n "checking for nanosleep in -lrt""... $ac_c" 1>&6
+echo "configure:17928: checking for nanosleep in -lrt" >&5
+ac_lib_var=`echo rt'_'nanosleep | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-lrt  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 17936 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char nanosleep();
+
+int main() {
+nanosleep()
+; return 0; }
+EOF
+if { (eval echo configure:17947: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  found=yes
+else
+  echo "$ac_t""no" 1>&6
+
+    echo $ac_n "checking for __nanosleep in -lrt""... $ac_c" 1>&6
+echo "configure:17967: checking for __nanosleep in -lrt" >&5
+ac_lib_var=`echo rt'_'__nanosleep | sed 'y%./+-%__p_%'`
+if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  ac_save_LIBS="$LIBS"
+LIBS="-lrt  $LIBS"
+cat > conftest.$ac_ext <<EOF
+#line 17975 "configure"
+#include "confdefs.h"
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* We use char because int might match the return type of a gcc2
+    builtin and then its argument prototype would still apply.  */
+char __nanosleep();
+
+int main() {
+__nanosleep()
+; return 0; }
+EOF
+if { (eval echo configure:17986: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_lib_$ac_lib_var=no"
+fi
+rm -f conftest*
+LIBS="$ac_save_LIBS"
+
+fi
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+  found=yes
+else
+  echo "$ac_t""no" 1>&6
+found=no
+fi
+
+  
+fi
+
+
+  if test "$found" = "yes"; then
+    ac_libs=$LIBS
+    LIBS="$LIBS -lrt"
+    if test "$cross_compiling" = yes; then
+  found=no
+else
+  cat > conftest.$ac_ext <<EOF
+#line 18018 "configure"
+#include "confdefs.h"
+main() { return (0); }
+EOF
+if { (eval echo configure:18022: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+then
+  found=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -fr conftest*
+  found=no
+fi
+rm -fr conftest*
+fi
+
+    LIBS=$ac_libs
+  fi
+
+  if test "$found" = "yes"; then
+    
+  
+  case rt in
+  c|c_r|pthread*) ;;
+  *) 
+      LIBS="-lrt $LIBS" 
+   ;;
+  esac
+
+
+    cat >> confdefs.h <<\EOF
+#define HAVE_NANOSLEEP 1
+EOF
+
+    cat >> confdefs.h <<\EOF
+#define HAVE_LIBRT 1
+EOF
+
+    ac_cv_func_nanosleep=yes
+  else
+    
+  :
+
+  fi
+  
+
+fi
+
+echo "$ac_t""$ac_cv_func_nanosleep" 1>&6
+
 echo $ac_n "checking for getaddrinfo""... $ac_c" 1>&6
-echo "configure:18189: checking for getaddrinfo" >&5
+echo "configure:18069: checking for getaddrinfo" >&5
 if eval "test \"`echo '$''{'ac_cv_func_getaddrinfo'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 18194 "configure"
+#line 18074 "configure"
 #include "confdefs.h"
 #include <netdb.h>
 int main() {
 struct addrinfo *g,h;g=&h;getaddrinfo("","",g,&g);
 ; return 0; }
 EOF
-if { (eval echo configure:18201: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:18081: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   if test "$cross_compiling" = yes; then
   ac_cv_func_getaddrinfo=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 18207 "configure"
+#line 18087 "configure"
 #include "confdefs.h"
 
 #include <netdb.h>
@@ -18243,7 +18123,7 @@ int main(void) {
 }
   
 EOF
-if { (eval echo configure:18247: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:18127: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_getaddrinfo=yes
 else
@@ -18275,12 +18155,12 @@ fi
 for ac_func in strlcat strlcpy getopt
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:18279: checking for $ac_func" >&5
+echo "configure:18159: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 18284 "configure"
+#line 18164 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -18303,7 +18183,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:18307: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:18187: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -18330,7 +18210,7 @@ done
 
 
 echo $ac_n "checking whether utime accepts a null argument""... $ac_c" 1>&6
-echo "configure:18334: checking whether utime accepts a null argument" >&5
+echo "configure:18214: checking whether utime accepts a null argument" >&5
 if eval "test \"`echo '$''{'ac_cv_func_utime_null'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -18340,7 +18220,7 @@ if test "$cross_compiling" = yes; then
   ac_cv_func_utime_null=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 18344 "configure"
+#line 18224 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/stat.h>
@@ -18351,7 +18231,7 @@ exit(!(stat ("conftestdata", &s) == 0 && utime("conftestdata", (long *)0) == 0
 && t.st_mtime - s.st_mtime < 120));
 }
 EOF
-if { (eval echo configure:18355: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:18235: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_utime_null=yes
 else
@@ -18377,19 +18257,19 @@ fi
 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
 # for constant arguments.  Useless!
 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:18381: checking for working alloca.h" >&5
+echo "configure:18261: checking for working alloca.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 18386 "configure"
+#line 18266 "configure"
 #include "confdefs.h"
 #include <alloca.h>
 int main() {
 char *p = alloca(2 * sizeof(int));
 ; return 0; }
 EOF
-if { (eval echo configure:18393: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:18273: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_cv_header_alloca_h=yes
 else
@@ -18410,12 +18290,12 @@ EOF
 fi
 
 echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:18414: checking for alloca" >&5
+echo "configure:18294: checking for alloca" >&5
 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 18419 "configure"
+#line 18299 "configure"
 #include "confdefs.h"
 
 #ifdef __GNUC__
@@ -18443,7 +18323,7 @@ int main() {
 char *p = (char *) alloca(1);
 ; return 0; }
 EOF
-if { (eval echo configure:18447: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:18327: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_cv_func_alloca_works=yes
 else
@@ -18475,12 +18355,12 @@ EOF
 
 
 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:18479: checking whether alloca needs Cray hooks" >&5
+echo "configure:18359: checking whether alloca needs Cray hooks" >&5
 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 18484 "configure"
+#line 18364 "configure"
 #include "confdefs.h"
 #if defined(CRAY) && ! defined(CRAY2)
 webecray
@@ -18505,12 +18385,12 @@ echo "$ac_t""$ac_cv_os_cray" 1>&6
 if test $ac_cv_os_cray = yes; then
 for ac_func in _getb67 GETB67 getb67; do
   echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:18509: checking for $ac_func" >&5
+echo "configure:18389: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 18514 "configure"
+#line 18394 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -18533,7 +18413,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:18537: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:18417: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -18560,7 +18440,7 @@ done
 fi
 
 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:18564: checking stack direction for C alloca" >&5
+echo "configure:18444: checking stack direction for C alloca" >&5
 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -18568,7 +18448,7 @@ else
   ac_cv_c_stack_direction=0
 else
   cat > conftest.$ac_ext <<EOF
-#line 18572 "configure"
+#line 18452 "configure"
 #include "confdefs.h"
 find_stack_direction ()
 {
@@ -18587,7 +18467,7 @@ main ()
   exit (find_stack_direction() < 0);
 }
 EOF
-if { (eval echo configure:18591: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:18471: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_c_stack_direction=1
 else
@@ -18610,13 +18490,13 @@ fi
 
 
   echo $ac_n "checking for declared timezone""... $ac_c" 1>&6
-echo "configure:18614: checking for declared timezone" >&5
+echo "configure:18494: checking for declared timezone" >&5
 if eval "test \"`echo '$''{'ac_cv_declared_timezone'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     cat > conftest.$ac_ext <<EOF
-#line 18620 "configure"
+#line 18500 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -18631,7 +18511,7 @@ int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:18635: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:18515: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
   ac_cv_declared_timezone=yes
@@ -18657,7 +18537,7 @@ EOF
 
 
 echo $ac_n "checking for type of reentrant time-related functions""... $ac_c" 1>&6
-echo "configure:18661: checking for type of reentrant time-related functions" >&5
+echo "configure:18541: checking for type of reentrant time-related functions" >&5
 if eval "test \"`echo '$''{'ac_cv_time_r_type'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -18668,7 +18548,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 18672 "configure"
+#line 18552 "configure"
 #include "confdefs.h"
 
 #include <time.h>
@@ -18686,7 +18566,7 @@ return (1);
 }
 
 EOF
-if { (eval echo configure:18690: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:18570: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   ac_cv_time_r_type=hpux
@@ -18702,7 +18582,7 @@ else
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 18706 "configure"
+#line 18586 "configure"
 #include "confdefs.h"
 
 #include <time.h>
@@ -18718,7 +18598,7 @@ main() {
 }
   
 EOF
-if { (eval echo configure:18722: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:18602: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     ac_cv_time_r_type=irix
@@ -18756,12 +18636,12 @@ EOF
 
 
     echo $ac_n "checking for readdir_r""... $ac_c" 1>&6
-echo "configure:18760: checking for readdir_r" >&5
+echo "configure:18640: checking for readdir_r" >&5
 if eval "test \"`echo '$''{'ac_cv_func_readdir_r'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 18765 "configure"
+#line 18645 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char readdir_r(); below.  */
@@ -18784,7 +18664,7 @@ readdir_r();
 
 ; return 0; }
 EOF
-if { (eval echo configure:18788: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:18668: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_readdir_r=yes"
 else
@@ -18806,7 +18686,7 @@ fi
 
   if test "$ac_cv_func_readdir_r" = "yes"; then
   echo $ac_n "checking for type of readdir_r""... $ac_c" 1>&6
-echo "configure:18810: checking for type of readdir_r" >&5
+echo "configure:18690: checking for type of readdir_r" >&5
 if eval "test \"`echo '$''{'ac_cv_what_readdir_r'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -18817,7 +18697,7 @@ else
    
 else
   cat > conftest.$ac_ext <<EOF
-#line 18821 "configure"
+#line 18701 "configure"
 #include "confdefs.h"
 
 #define _REENTRANT
@@ -18842,7 +18722,7 @@ main() {
 }
     
 EOF
-if { (eval echo configure:18846: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:18726: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
       ac_cv_what_readdir_r=POSIX
@@ -18853,7 +18733,7 @@ else
   rm -fr conftest*
   
       cat > conftest.$ac_ext <<EOF
-#line 18857 "configure"
+#line 18737 "configure"
 #include "confdefs.h"
 
 #define _REENTRANT
@@ -18863,7 +18743,7 @@ int readdir_r(DIR *, struct dirent *);
         
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:18867: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:18747: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -18905,12 +18785,12 @@ EOF
 
 
 echo $ac_n "checking for in_addr_t""... $ac_c" 1>&6
-echo "configure:18909: checking for in_addr_t" >&5
+echo "configure:18789: checking for in_addr_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_in_addr_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 18914 "configure"
+#line 18794 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -18944,12 +18824,12 @@ fi
 for ac_func in crypt_r
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:18948: checking for $ac_func" >&5
+echo "configure:18828: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 18953 "configure"
+#line 18833 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -18972,7 +18852,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:18976: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:18856: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -19000,14 +18880,14 @@ done
 if test "x$php_crypt_r" = "x1"; then
   
   echo $ac_n "checking which data struct is used by crypt_r""... $ac_c" 1>&6
-echo "configure:19004: checking which data struct is used by crypt_r" >&5
+echo "configure:18884: checking which data struct is used by crypt_r" >&5
 if eval "test \"`echo '$''{'php_cv_crypt_r_style'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     php_cv_crypt_r_style=none
     cat > conftest.$ac_ext <<EOF
-#line 19011 "configure"
+#line 18891 "configure"
 #include "confdefs.h"
 
 #define _REENTRANT 1
@@ -19020,7 +18900,7 @@ crypt_r("passwd", "hash", &buffer);
 
 ; return 0; }
 EOF
-if { (eval echo configure:19024: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:18904: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   php_cv_crypt_r_style=cryptd
 else
@@ -19031,7 +18911,7 @@ rm -f conftest*
 
     if test "$php_cv_crypt_r_style" = "none"; then
       cat > conftest.$ac_ext <<EOF
-#line 19035 "configure"
+#line 18915 "configure"
 #include "confdefs.h"
 
 #define _REENTRANT 1
@@ -19044,7 +18924,7 @@ crypt_r("passwd", "hash", &buffer);
 
 ; return 0; }
 EOF
-if { (eval echo configure:19048: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:18928: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   php_cv_crypt_r_style=struct_crypt_data
 else
@@ -19056,7 +18936,7 @@ rm -f conftest*
 
     if test "$php_cv_crypt_r_style" = "none"; then
       cat > conftest.$ac_ext <<EOF
-#line 19060 "configure"
+#line 18940 "configure"
 #include "confdefs.h"
 
 #define _REENTRANT 1
@@ -19070,7 +18950,7 @@ crypt_r("passwd", "hash", &buffer);
 
 ; return 0; }
 EOF
-if { (eval echo configure:19074: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:18954: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   php_cv_crypt_r_style=struct_crypt_data_gnu_source
 else
@@ -19129,7 +19009,7 @@ fi
 php_enable_gcov=no
 
 echo $ac_n "checking whether to include gcov symbols""... $ac_c" 1>&6
-echo "configure:19133: checking whether to include gcov symbols" >&5
+echo "configure:19013: checking whether to include gcov symbols" >&5
 # Check whether --enable-gcov or --disable-gcov was given.
 if test "${enable_gcov+set}" = set; then
   enableval="$enable_gcov"
@@ -19171,7 +19051,7 @@ if test "$PHP_GCOV" = "yes"; then
   # Extract the first word of "lcov", so it can be a program name with args.
 set dummy lcov; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:19175: checking for $ac_word" >&5
+echo "configure:19055: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_LTP'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -19200,7 +19080,7 @@ fi
   # Extract the first word of "genhtml", so it can be a program name with args.
 set dummy genhtml; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:19204: checking for $ac_word" >&5
+echo "configure:19084: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_LTP_GENHTML'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -19235,7 +19115,7 @@ fi
 
   if test "$LTP"; then
     echo $ac_n "checking for ltp version""... $ac_c" 1>&6
-echo "configure:19239: checking for ltp version" >&5
+echo "configure:19119: checking for ltp version" >&5
 if eval "test \"`echo '$''{'php_cv_ltp_version'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -19286,22 +19166,13 @@ EOF
 
     CFLAGS="$CFLAGS -O0 -fprofile-arcs -ftest-coverage"
   CXXFLAGS="$CXXFLAGS -O0 -fprofile-arcs -ftest-coverage"
-  if test "$SUNCC" = "yes"; then
-    if test -n "$auto_cflags"; then
-      CFLAGS="-g"
-      CXXFLAGS="-g"
-    else
-      CFLAGS="$CFLAGS -g"
-      CXXFLAGS="$CFLAGS -g"
-    fi
-  fi
 fi
 
 
 php_enable_debug=no
 
 echo $ac_n "checking whether to include debugging symbols""... $ac_c" 1>&6
-echo "configure:19305: checking whether to include debugging symbols" >&5
+echo "configure:19176: checking whether to include debugging symbols" >&5
 # Check whether --enable-debug or --disable-debug was given.
 if test "${enable_debug+set}" = set; then
   enableval="$enable_debug"
@@ -19331,8 +19202,17 @@ if test "$PHP_DEBUG" = "yes"; then
   CXXFLAGS=`echo "$CXXFLAGS" | $SED -e 's/-O[0-9s]*//g'`
   
     if test "$GCC" = "yes" || test "$ICC" = "yes"; then
-    CFLAGS="$CFLAGS -O0"
-    CXXFLAGS="$CXXFLAGS -O0"
+    CFLAGS="$CFLAGS -g -O0"
+    CXXFLAGS="$CXXFLAGS -g -O0"
+  fi
+  if test "$SUNCC" = "yes"; then
+    if test -n "$auto_cflags"; then
+      CFLAGS="-g"
+      CXXFLAGS="-g"
+    else
+      CFLAGS="$CFLAGS -g"
+      CXXFLAGS="$CFLAGS -g"
+    fi
   fi
 else
   PHP_DEBUG=0
@@ -19343,7 +19223,7 @@ fi
 php_with_layout=PHP
 
 echo $ac_n "checking layout of installed files""... $ac_c" 1>&6
-echo "configure:19347: checking layout of installed files" >&5
+echo "configure:19227: checking layout of installed files" >&5
 # Check whether --with-layout or --without-layout was given.
 if test "${with_layout+set}" = set; then
   withval="$with_layout"
@@ -19378,7 +19258,7 @@ esac
 php_with_config_file_path=DEFAULT
 
 echo $ac_n "checking path to configuration file""... $ac_c" 1>&6
-echo "configure:19382: checking path to configuration file" >&5
+echo "configure:19262: checking path to configuration file" >&5
 # Check whether --with-config-file-path or --without-config-file-path was given.
 if test "${with_config_file_path+set}" = set; then
   withval="$with_config_file_path"
@@ -19412,7 +19292,7 @@ if test "$PHP_CONFIG_FILE_PATH" = "DEFAULT"; then
 fi
 
 echo $ac_n "checking where to scan for configuration files""... $ac_c" 1>&6
-echo "configure:19416: checking where to scan for configuration files" >&5
+echo "configure:19296: checking where to scan for configuration files" >&5
 
 php_with_config_file_scan_dir=DEFAULT
 
@@ -19448,7 +19328,7 @@ test -n "$DEBUG_CFLAGS" && CFLAGS="$CFLAGS $DEBUG_CFLAGS"
 php_enable_safe_mode=no
 
 echo $ac_n "checking whether to enable safe mode by default""... $ac_c" 1>&6
-echo "configure:19452: checking whether to enable safe mode by default" >&5
+echo "configure:19332: checking whether to enable safe mode by default" >&5
 # Check whether --enable-safe-mode or --disable-safe-mode was given.
 if test "${enable_safe_mode+set}" = set; then
   enableval="$enable_safe_mode"
@@ -19483,7 +19363,7 @@ EOF
 fi
 
 echo $ac_n "checking for safe mode exec dir""... $ac_c" 1>&6
-echo "configure:19487: checking for safe mode exec dir" >&5
+echo "configure:19367: checking for safe mode exec dir" >&5
 
 php_with_exec_dir=no
 
@@ -19527,7 +19407,7 @@ fi
 php_enable_sigchild=no
 
 echo $ac_n "checking whether to enable PHP's own SIGCHLD handler""... $ac_c" 1>&6
-echo "configure:19531: checking whether to enable PHP's own SIGCHLD handler" >&5
+echo "configure:19411: checking whether to enable PHP's own SIGCHLD handler" >&5
 # Check whether --enable-sigchild or --disable-sigchild was given.
 if test "${enable_sigchild+set}" = set; then
   enableval="$enable_sigchild"
@@ -19565,7 +19445,7 @@ fi
 php_enable_magic_quotes=no
 
 echo $ac_n "checking whether to enable magic quotes by default""... $ac_c" 1>&6
-echo "configure:19569: checking whether to enable magic quotes by default" >&5
+echo "configure:19449: checking whether to enable magic quotes by default" >&5
 # Check whether --enable-magic-quotes or --disable-magic-quotes was given.
 if test "${enable_magic_quotes+set}" = set; then
   enableval="$enable_magic_quotes"
@@ -19603,7 +19483,7 @@ fi
 php_enable_libgcc=no
 
 echo $ac_n "checking whether to explicitly link against libgcc""... $ac_c" 1>&6
-echo "configure:19607: checking whether to explicitly link against libgcc" >&5
+echo "configure:19487: checking whether to explicitly link against libgcc" >&5
 # Check whether --enable-libgcc or --disable-libgcc was given.
 if test "${enable_libgcc+set}" = set; then
   enableval="$enable_libgcc"
@@ -19683,7 +19563,7 @@ fi
 php_enable_short_tags=yes
 
 echo $ac_n "checking whether to enable short tags by default""... $ac_c" 1>&6
-echo "configure:19687: checking whether to enable short tags by default" >&5
+echo "configure:19567: checking whether to enable short tags by default" >&5
 # Check whether --enable-short-tags or --disable-short-tags was given.
 if test "${enable_short_tags+set}" = set; then
   enableval="$enable_short_tags"
@@ -19721,7 +19601,7 @@ fi
 php_enable_dmalloc=no
 
 echo $ac_n "checking whether to enable dmalloc""... $ac_c" 1>&6
-echo "configure:19725: checking whether to enable dmalloc" >&5
+echo "configure:19605: checking whether to enable dmalloc" >&5
 # Check whether --enable-dmalloc or --disable-dmalloc was given.
 if test "${enable_dmalloc+set}" = set; then
   enableval="$enable_dmalloc"
@@ -19745,7 +19625,7 @@ echo "$ac_t""$ext_output" 1>&6
 
 if test "$PHP_DMALLOC" = "yes"; then
   echo $ac_n "checking for dmalloc_error in -ldmalloc""... $ac_c" 1>&6
-echo "configure:19749: checking for dmalloc_error in -ldmalloc" >&5
+echo "configure:19629: checking for dmalloc_error in -ldmalloc" >&5
 ac_lib_var=`echo dmalloc'_'dmalloc_error | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -19753,7 +19633,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldmalloc  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 19757 "configure"
+#line 19637 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -19764,7 +19644,7 @@ int main() {
 dmalloc_error()
 ; return 0; }
 EOF
-if { (eval echo configure:19768: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:19648: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -19809,7 +19689,7 @@ fi
 php_enable_ipv6=yes
 
 echo $ac_n "checking whether to enable IPv6 support""... $ac_c" 1>&6
-echo "configure:19813: checking whether to enable IPv6 support" >&5
+echo "configure:19693: checking whether to enable IPv6 support" >&5
 # Check whether --enable-ipv6 or --disable-ipv6 was given.
 if test "${enable_ipv6+set}" = set; then
   enableval="$enable_ipv6"
@@ -19839,7 +19719,7 @@ EOF
 fi
 
 echo $ac_n "checking how big to make fd sets""... $ac_c" 1>&6
-echo "configure:19843: checking how big to make fd sets" >&5
+echo "configure:19723: checking how big to make fd sets" >&5
 
 php_enable_fd_setsize=no
 
@@ -19910,7 +19790,7 @@ fi
 
 
 echo $ac_n "checking size of long""... $ac_c" 1>&6
-echo "configure:19914: checking size of long" >&5
+echo "configure:19794: checking size of long" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -19918,7 +19798,7 @@ else
   ac_cv_sizeof_long=8
 else
   cat > conftest.$ac_ext <<EOF
-#line 19922 "configure"
+#line 19802 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -19929,7 +19809,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:19933: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:19813: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long=`cat conftestval`
 else
@@ -19949,7 +19829,7 @@ EOF
 
 
 echo $ac_n "checking size of int""... $ac_c" 1>&6
-echo "configure:19953: checking size of int" >&5
+echo "configure:19833: checking size of int" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -19957,7 +19837,7 @@ else
   ac_cv_sizeof_int=4
 else
   cat > conftest.$ac_ext <<EOF
-#line 19961 "configure"
+#line 19841 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -19968,7 +19848,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:19972: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:19852: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_int=`cat conftestval`
 else
@@ -19989,13 +19869,13 @@ EOF
 
 
 echo $ac_n "checking for int32_t""... $ac_c" 1>&6
-echo "configure:19993: checking for int32_t" >&5
+echo "configure:19873: checking for int32_t" >&5
 if eval "test \"`echo '$''{'ac_cv_int_type_int32_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 19999 "configure"
+#line 19879 "configure"
 #include "confdefs.h"
 
 #if HAVE_SYS_TYPES_H
@@ -20014,7 +19894,7 @@ if (sizeof (int32_t))
 
 ; return 0; }
 EOF
-if { (eval echo configure:20018: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:19898: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_int_type_int32_t=yes
 else
@@ -20037,13 +19917,13 @@ fi
 
 
 echo $ac_n "checking for uint32_t""... $ac_c" 1>&6
-echo "configure:20041: checking for uint32_t" >&5
+echo "configure:19921: checking for uint32_t" >&5
 if eval "test \"`echo '$''{'ac_cv_int_type_uint32_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 20047 "configure"
+#line 19927 "configure"
 #include "confdefs.h"
 
 #if HAVE_SYS_TYPES_H
@@ -20062,7 +19942,7 @@ if (sizeof (uint32_t))
 
 ; return 0; }
 EOF
-if { (eval echo configure:20066: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:19946: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_int_type_uint32_t=yes
 else
@@ -20094,17 +19974,17 @@ stdlib.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:20098: checking for $ac_hdr" >&5
+echo "configure:19978: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 20103 "configure"
+#line 19983 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:20108: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:19988: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -20134,12 +20014,12 @@ done
 for ac_func in strtoll atoll strftime
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:20138: checking for $ac_func" >&5
+echo "configure:20018: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 20143 "configure"
+#line 20023 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -20162,7 +20042,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:20166: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:20046: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -20575,6 +20455,62 @@ EOF
   
 
 
+for ac_func in llabs
+do
+echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
+echo "configure:20462: checking for $ac_func" >&5
+if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 20467 "configure"
+#include "confdefs.h"
+/* System header to define __stub macros and hopefully few prototypes,
+    which can conflict with char $ac_func(); below.  */
+#include <assert.h>
+/* Override any gcc2 internal prototype to avoid an error.  */
+/* 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();
+
+int main() {
+
+/* The GNU C library defines this for functions which it implements
+    to always fail with ENOSYS.  Some functions are actually named
+    something starting with __ and the normal name is an alias.  */
+#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
+choke me
+#else
+$ac_func();
+#endif
+
+; return 0; }
+EOF
+if { (eval echo configure:20490: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+  rm -rf conftest*
+  eval "ac_cv_func_$ac_func=yes"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_func_$ac_func=no"
+fi
+rm -f conftest*
+fi
+
+if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
+  cat >> confdefs.h <<EOF
+#define $ac_tr_func 1
+EOF
+ 
+else
+  echo "$ac_t""no" 1>&6
+fi
+done
+
+
 cat > $ext_builddir/lib/timelib_config.h <<EOF
 #ifdef PHP_WIN32
 # include "config.w32.h"
@@ -20588,7 +20524,7 @@ EOF
 php_enable_libxml=yes
 
 echo $ac_n "checking whether to enable LIBXML support""... $ac_c" 1>&6
-echo "configure:20592: checking whether to enable LIBXML support" >&5
+echo "configure:20528: checking whether to enable LIBXML support" >&5
 # Check whether --enable-libxml or --disable-libxml was given.
 if test "${enable_libxml+set}" = set; then
   enableval="$enable_libxml"
@@ -20636,7 +20572,7 @@ if test -z "$PHP_LIBXML_DIR"; then
 php_with_libxml_dir=no
 
 echo $ac_n "checking libxml2 install dir""... $ac_c" 1>&6
-echo "configure:20640: checking libxml2 install dir" >&5
+echo "configure:20576: checking libxml2 install dir" >&5
 # Check whether --with-libxml-dir or --without-libxml-dir was given.
 if test "${with_libxml_dir+set}" = set; then
   withval="$with_libxml_dir"
@@ -20665,7 +20601,7 @@ if test "$PHP_LIBXML" != "no"; then
 
   
 echo $ac_n "checking for xml2-config path""... $ac_c" 1>&6
-echo "configure:20669: checking for xml2-config path" >&5
+echo "configure:20605: checking for xml2-config path" >&5
 if eval "test \"`echo '$''{'ac_cv_php_xml2_config_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -20823,7 +20759,7 @@ echo "$ac_t""$ac_cv_php_xml2_config_path" 1>&6
 
 
             echo $ac_n "checking whether libxml build works""... $ac_c" 1>&6
-echo "configure:20827: checking whether libxml build works" >&5
+echo "configure:20763: checking whether libxml build works" >&5
 if eval "test \"`echo '$''{'php_cv_libxml_build_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -20839,7 +20775,7 @@ else
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 20843 "configure"
+#line 20779 "configure"
 #include "confdefs.h"
 
     
@@ -20850,7 +20786,7 @@ else
     }
   
 EOF
-if { (eval echo configure:20854: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:20790: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     LIBS=$old_LIBS
@@ -21215,7 +21151,7 @@ fi
 php_with_openssl=no
 
 echo $ac_n "checking for OpenSSL support""... $ac_c" 1>&6
-echo "configure:21219: checking for OpenSSL support" >&5
+echo "configure:21155: checking for OpenSSL support" >&5
 # Check whether --with-openssl or --without-openssl was given.
 if test "${with_openssl+set}" = set; then
   withval="$with_openssl"
@@ -21262,7 +21198,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_kerberos=no
 
 echo $ac_n "checking for Kerberos support""... $ac_c" 1>&6
-echo "configure:21266: checking for Kerberos support" >&5
+echo "configure:21202: checking for Kerberos support" >&5
 # Check whether --with-kerberos or --without-kerberos was given.
 if test "${with_kerberos+set}" = set; then
   withval="$with_kerberos"
@@ -21591,7 +21527,7 @@ EOF
     # Extract the first word of "krb5-config", so it can be a program name with args.
 set dummy krb5-config; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:21595: checking for $ac_word" >&5
+echo "configure:21531: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_KRB5_CONFIG'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -21951,7 +21887,7 @@ fi
   fi
 
   echo $ac_n "checking for DSA_get_default_method in -lssl""... $ac_c" 1>&6
-echo "configure:21955: checking for DSA_get_default_method in -lssl" >&5
+echo "configure:21891: checking for DSA_get_default_method in -lssl" >&5
 ac_lib_var=`echo ssl'_'DSA_get_default_method | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -21959,7 +21895,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lssl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 21963 "configure"
+#line 21899 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -21970,7 +21906,7 @@ int main() {
 DSA_get_default_method()
 ; return 0; }
 EOF
-if { (eval echo configure:21974: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:21910: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -22012,7 +21948,7 @@ fi
     # Extract the first word of "pkg-config", so it can be a program name with args.
 set dummy pkg-config; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:22016: checking for $ac_word" >&5
+echo "configure:21952: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_PKG_CONFIG'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -22217,9 +22153,9 @@ fi
     old_CPPFLAGS=$CPPFLAGS
     CPPFLAGS=-I$OPENSSL_INCDIR
     echo $ac_n "checking for OpenSSL version""... $ac_c" 1>&6
-echo "configure:22221: checking for OpenSSL version" >&5
+echo "configure:22157: checking for OpenSSL version" >&5
     cat > conftest.$ac_ext <<EOF
-#line 22223 "configure"
+#line 22159 "configure"
 #include "confdefs.h"
 
 #include <openssl/opensslv.h>
@@ -22374,7 +22310,7 @@ rm -f conftest*
   done
 
   echo $ac_n "checking for CRYPTO_free in -lcrypto""... $ac_c" 1>&6
-echo "configure:22378: checking for CRYPTO_free in -lcrypto" >&5
+echo "configure:22314: checking for CRYPTO_free in -lcrypto" >&5
 ac_lib_var=`echo crypto'_'CRYPTO_free | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -22382,7 +22318,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lcrypto  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 22386 "configure"
+#line 22322 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -22393,7 +22329,7 @@ int main() {
 CRYPTO_free()
 ; return 0; }
 EOF
-if { (eval echo configure:22397: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:22333: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -22550,7 +22486,7 @@ fi
   done
 
   echo $ac_n "checking for SSL_CTX_set_ssl_version in -lssl""... $ac_c" 1>&6
-echo "configure:22554: checking for SSL_CTX_set_ssl_version in -lssl" >&5
+echo "configure:22490: checking for SSL_CTX_set_ssl_version in -lssl" >&5
 ac_lib_var=`echo ssl'_'SSL_CTX_set_ssl_version | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -22558,7 +22494,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lssl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 22562 "configure"
+#line 22498 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -22569,7 +22505,7 @@ int main() {
 SSL_CTX_set_ssl_version()
 ; return 0; }
 EOF
-if { (eval echo configure:22573: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:22509: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -22691,7 +22627,7 @@ fi
 php_with_pcre_regex=yes
 
 echo $ac_n "checking for PCRE support""... $ac_c" 1>&6
-echo "configure:22695: checking for PCRE support" >&5
+echo "configure:22631: checking for PCRE support" >&5
 # Check whether --with-pcre-regex or --without-pcre-regex was given.
 if test "${with_pcre_regex+set}" = set; then
   withval="$with_pcre_regex"
@@ -23545,7 +23481,7 @@ fi
 php_with_zlib=no
 
 echo $ac_n "checking for ZLIB support""... $ac_c" 1>&6
-echo "configure:23549: checking for ZLIB support" >&5
+echo "configure:23485: checking for ZLIB support" >&5
 # Check whether --with-zlib or --without-zlib was given.
 if test "${with_zlib+set}" = set; then
   withval="$with_zlib"
@@ -23592,7 +23528,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_zlib_dir=no
 
 echo $ac_n "checking if the location of ZLIB install directory is defined""... $ac_c" 1>&6
-echo "configure:23596: checking if the location of ZLIB install directory is defined" >&5
+echo "configure:23532: checking if the location of ZLIB install directory is defined" >&5
 # Check whether --with-zlib-dir or --without-zlib-dir was given.
 if test "${with_zlib_dir+set}" = set; then
   withval="$with_zlib_dir"
@@ -24038,7 +23974,7 @@ EOF
   done
 
   echo $ac_n "checking for gzgets in -lz""... $ac_c" 1>&6
-echo "configure:24042: checking for gzgets in -lz" >&5
+echo "configure:23978: checking for gzgets in -lz" >&5
 ac_lib_var=`echo z'_'gzgets | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -24046,7 +23982,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lz  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 24050 "configure"
+#line 23986 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -24057,7 +23993,7 @@ int main() {
 gzgets()
 ; return 0; }
 EOF
-if { (eval echo configure:24061: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:23997: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -24197,7 +24133,7 @@ fi
 php_enable_bcmath=no
 
 echo $ac_n "checking whether to enable bc style precision math functions""... $ac_c" 1>&6
-echo "configure:24201: checking whether to enable bc style precision math functions" >&5
+echo "configure:24137: checking whether to enable bc style precision math functions" >&5
 # Check whether --enable-bcmath or --disable-bcmath was given.
 if test "${enable_bcmath+set}" = set; then
   enableval="$enable_bcmath"
@@ -24565,7 +24501,7 @@ fi
 php_with_bz2=no
 
 echo $ac_n "checking for BZip2 support""... $ac_c" 1>&6
-echo "configure:24569: checking for BZip2 support" >&5
+echo "configure:24505: checking for BZip2 support" >&5
 # Check whether --with-bz2 or --without-bz2 was given.
 if test "${with_bz2+set}" = set; then
   withval="$with_bz2"
@@ -24613,7 +24549,7 @@ if test "$PHP_BZ2" != "no"; then
     BZIP_DIR=$PHP_BZ2
   else
     echo $ac_n "checking for BZip2 in default path""... $ac_c" 1>&6
-echo "configure:24617: checking for BZip2 in default path" >&5
+echo "configure:24553: checking for BZip2 in default path" >&5
     for i in /usr/local /usr; do
       if test -r $i/include/bzlib.h; then
         BZIP_DIR=$i
@@ -24726,7 +24662,7 @@ echo "configure:24617: checking for BZip2 in default path" >&5
   done
 
   echo $ac_n "checking for BZ2_bzerror in -lbz2""... $ac_c" 1>&6
-echo "configure:24730: checking for BZ2_bzerror in -lbz2" >&5
+echo "configure:24666: checking for BZ2_bzerror in -lbz2" >&5
 ac_lib_var=`echo bz2'_'BZ2_bzerror | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -24734,7 +24670,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbz2  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 24738 "configure"
+#line 24674 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -24745,7 +24681,7 @@ int main() {
 BZ2_bzerror()
 ; return 0; }
 EOF
-if { (eval echo configure:24749: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:24685: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -25213,7 +25149,7 @@ fi
 php_enable_calendar=no
 
 echo $ac_n "checking whether to enable calendar conversion support""... $ac_c" 1>&6
-echo "configure:25217: checking whether to enable calendar conversion support" >&5
+echo "configure:25153: checking whether to enable calendar conversion support" >&5
 # Check whether --enable-calendar or --disable-calendar was given.
 if test "${enable_calendar+set}" = set; then
   enableval="$enable_calendar"
@@ -25560,7 +25496,7 @@ fi
 php_enable_ctype=yes
 
 echo $ac_n "checking whether to enable ctype functions""... $ac_c" 1>&6
-echo "configure:25564: checking whether to enable ctype functions" >&5
+echo "configure:25500: checking whether to enable ctype functions" >&5
 # Check whether --enable-ctype or --disable-ctype was given.
 if test "${enable_ctype+set}" = set; then
   enableval="$enable_ctype"
@@ -25907,7 +25843,7 @@ fi
 php_with_curl=no
 
 echo $ac_n "checking for cURL support""... $ac_c" 1>&6
-echo "configure:25911: checking for cURL support" >&5
+echo "configure:25847: checking for cURL support" >&5
 # Check whether --with-curl or --without-curl was given.
 if test "${with_curl+set}" = set; then
   withval="$with_curl"
@@ -25954,7 +25890,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_curlwrappers=no
 
 echo $ac_n "checking if we should use cURL for url streams""... $ac_c" 1>&6
-echo "configure:25958: checking if we should use cURL for url streams" >&5
+echo "configure:25894: checking if we should use cURL for url streams" >&5
 # Check whether --with-curlwrappers or --without-curlwrappers was given.
 if test "${with_curlwrappers+set}" = set; then
   withval="$with_curlwrappers"
@@ -25981,7 +25917,7 @@ if test "$PHP_CURL" != "no"; then
     CURL_DIR=$PHP_CURL
   else
     echo $ac_n "checking for cURL in default path""... $ac_c" 1>&6
-echo "configure:25985: checking for cURL in default path" >&5
+echo "configure:25921: checking for cURL in default path" >&5
     for i in /usr/local /usr; do
       if test -r $i/include/curl/easy.h; then
         CURL_DIR=$i
@@ -25999,7 +25935,7 @@ echo "configure:25985: checking for cURL in default path" >&5
 
   CURL_CONFIG="curl-config"
   echo $ac_n "checking for cURL 7.10.5 or greater""... $ac_c" 1>&6
-echo "configure:26003: checking for cURL 7.10.5 or greater" >&5
+echo "configure:25939: checking for cURL 7.10.5 or greater" >&5
 
   if ${CURL_DIR}/bin/curl-config --libs > /dev/null 2>&1; then
     CURL_CONFIG=${CURL_DIR}/bin/curl-config
@@ -26237,7 +26173,7 @@ echo "configure:26003: checking for cURL 7.10.5 or greater" >&5
 
   
   echo $ac_n "checking for SSL support in libcurl""... $ac_c" 1>&6
-echo "configure:26241: checking for SSL support in libcurl" >&5
+echo "configure:26177: checking for SSL support in libcurl" >&5
   CURL_SSL=`$CURL_CONFIG --feature | $EGREP SSL`
   if test "$CURL_SSL" = "SSL"; then
     echo "$ac_t""yes" 1>&6
@@ -26250,7 +26186,7 @@ EOF
     CFLAGS="`$CURL_CONFIG --cflags`"
    
     echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:26254: checking how to run the C preprocessor" >&5
+echo "configure:26190: checking how to run the C preprocessor" >&5
 # On Suns, sometimes $CPP names a directory.
 if test -n "$CPP" && test -d "$CPP"; then
   CPP=
@@ -26265,13 +26201,13 @@ else
   # On the NeXT, cc -E runs the code through the compiler's parser,
   # not just through cpp.
   cat > conftest.$ac_ext <<EOF
-#line 26269 "configure"
+#line 26205 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:26275: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:26211: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -26282,13 +26218,13 @@ else
   rm -rf conftest*
   CPP="${CC-cc} -E -traditional-cpp"
   cat > conftest.$ac_ext <<EOF
-#line 26286 "configure"
+#line 26222 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:26292: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:26228: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -26299,13 +26235,13 @@ else
   rm -rf conftest*
   CPP="${CC-cc} -nologo -E"
   cat > conftest.$ac_ext <<EOF
-#line 26303 "configure"
+#line 26239 "configure"
 #include "confdefs.h"
 #include <assert.h>
 Syntax Error
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:26309: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:26245: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   :
@@ -26330,14 +26266,14 @@ fi
 echo "$ac_t""$CPP" 1>&6
 
     echo $ac_n "checking for openssl support in libcurl""... $ac_c" 1>&6
-echo "configure:26334: checking for openssl support in libcurl" >&5
+echo "configure:26270: checking for openssl support in libcurl" >&5
     if test "$cross_compiling" = yes; then
   
       echo "$ac_t""no" 1>&6
     
 else
   cat > conftest.$ac_ext <<EOF
-#line 26341 "configure"
+#line 26277 "configure"
 #include "confdefs.h"
 
 #include <curl/curl.h>
@@ -26356,7 +26292,7 @@ int main(int argc, char *argv[])
 }
     
 EOF
-if { (eval echo configure:26360: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:26296: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
       echo "$ac_t""yes" 1>&6
@@ -26364,17 +26300,17 @@ then
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:26368: checking for $ac_hdr" >&5
+echo "configure:26304: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 26373 "configure"
+#line 26309 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:26378: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:26314: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -26419,14 +26355,14 @@ fi
 
    
     echo $ac_n "checking for gnutls support in libcurl""... $ac_c" 1>&6
-echo "configure:26423: checking for gnutls support in libcurl" >&5
+echo "configure:26359: checking for gnutls support in libcurl" >&5
     if test "$cross_compiling" = yes; then
   
       echo "$ac_t""no" 1>&6
     
 else
   cat > conftest.$ac_ext <<EOF
-#line 26430 "configure"
+#line 26366 "configure"
 #include "confdefs.h"
 
 #include <curl/curl.h>
@@ -26445,23 +26381,23 @@ int main(int argc, char *argv[])
 }
 
 EOF
-if { (eval echo configure:26449: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:26385: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
       echo "$ac_t""yes" 1>&6
       ac_safe=`echo "gcrypt.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for gcrypt.h""... $ac_c" 1>&6
-echo "configure:26455: checking for gcrypt.h" >&5
+echo "configure:26391: checking for gcrypt.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 26460 "configure"
+#line 26396 "configure"
 #include "confdefs.h"
 #include <gcrypt.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:26465: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:26401: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -26603,7 +26539,7 @@ fi
   done
 
   echo $ac_n "checking for curl_easy_perform in -lcurl""... $ac_c" 1>&6
-echo "configure:26607: checking for curl_easy_perform in -lcurl" >&5
+echo "configure:26543: checking for curl_easy_perform in -lcurl" >&5
 ac_lib_var=`echo curl'_'curl_easy_perform | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -26611,7 +26547,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lcurl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 26615 "configure"
+#line 26551 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -26622,7 +26558,7 @@ int main() {
 curl_easy_perform()
 ; return 0; }
 EOF
-if { (eval echo configure:26626: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:26562: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -26758,7 +26694,7 @@ fi
   done
 
   echo $ac_n "checking for curl_version_info in -lcurl""... $ac_c" 1>&6
-echo "configure:26762: checking for curl_version_info in -lcurl" >&5
+echo "configure:26698: checking for curl_version_info in -lcurl" >&5
 ac_lib_var=`echo curl'_'curl_version_info | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -26766,7 +26702,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lcurl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 26770 "configure"
+#line 26706 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -26777,7 +26713,7 @@ int main() {
 curl_version_info()
 ; return 0; }
 EOF
-if { (eval echo configure:26781: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:26717: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -26911,7 +26847,7 @@ fi
   done
 
   echo $ac_n "checking for curl_easy_strerror in -lcurl""... $ac_c" 1>&6
-echo "configure:26915: checking for curl_easy_strerror in -lcurl" >&5
+echo "configure:26851: checking for curl_easy_strerror in -lcurl" >&5
 ac_lib_var=`echo curl'_'curl_easy_strerror | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -26919,7 +26855,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lcurl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 26923 "configure"
+#line 26859 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -26930,7 +26866,7 @@ int main() {
 curl_easy_strerror()
 ; return 0; }
 EOF
-if { (eval echo configure:26934: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:26870: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -27064,7 +27000,7 @@ fi
   done
 
   echo $ac_n "checking for curl_multi_strerror in -lcurl""... $ac_c" 1>&6
-echo "configure:27068: checking for curl_multi_strerror in -lcurl" >&5
+echo "configure:27004: checking for curl_multi_strerror in -lcurl" >&5
 ac_lib_var=`echo curl'_'curl_multi_strerror | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -27072,7 +27008,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lcurl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 27076 "configure"
+#line 27012 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -27083,7 +27019,7 @@ int main() {
 curl_multi_strerror()
 ; return 0; }
 EOF
-if { (eval echo configure:27087: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:27023: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -27796,7 +27732,7 @@ if test "$PHP_QDBM" != "no"; then
   done
 
   echo $ac_n "checking for dpopen in -l$LIB""... $ac_c" 1>&6
-echo "configure:27800: checking for dpopen in -l$LIB" >&5
+echo "configure:27736: checking for dpopen in -l$LIB" >&5
 ac_lib_var=`echo $LIB'_'dpopen | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -27804,7 +27740,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$LIB  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 27808 "configure"
+#line 27744 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -27815,7 +27751,7 @@ int main() {
 dpopen()
 ; return 0; }
 EOF
-if { (eval echo configure:27819: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:27755: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -27984,7 +27920,7 @@ fi
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:27988: checking for $THIS_FULL_NAME support" >&5
+echo "configure:27924: checking for $THIS_FULL_NAME support" >&5
   if test -n ""; then
     { echo "configure: error: " 1>&2; exit 1; }
   fi
@@ -28012,7 +27948,7 @@ if test "$PHP_GDBM" != "no"; then
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:28016: checking for $THIS_FULL_NAME support" >&5
+echo "configure:27952: checking for $THIS_FULL_NAME support" >&5
   if test -n "You cannot combine --with-gdbm with --with-qdbm"; then
     { echo "configure: error: You cannot combine --with-gdbm with --with-qdbm" 1>&2; exit 1; }
   fi
@@ -28131,7 +28067,7 @@ echo "configure:28016: checking for $THIS_FULL_NAME support" >&5
   done
 
   echo $ac_n "checking for gdbm_open in -lgdbm""... $ac_c" 1>&6
-echo "configure:28135: checking for gdbm_open in -lgdbm" >&5
+echo "configure:28071: checking for gdbm_open in -lgdbm" >&5
 ac_lib_var=`echo gdbm'_'gdbm_open | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -28139,7 +28075,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgdbm  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 28143 "configure"
+#line 28079 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -28150,7 +28086,7 @@ int main() {
 gdbm_open()
 ; return 0; }
 EOF
-if { (eval echo configure:28154: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:28090: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -28315,7 +28251,7 @@ fi
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:28319: checking for $THIS_FULL_NAME support" >&5
+echo "configure:28255: checking for $THIS_FULL_NAME support" >&5
   if test -n ""; then
     { echo "configure: error: " 1>&2; exit 1; }
   fi
@@ -28444,7 +28380,7 @@ if test "$PHP_NDBM" != "no"; then
   done
 
   echo $ac_n "checking for dbm_open in -l$LIB""... $ac_c" 1>&6
-echo "configure:28448: checking for dbm_open in -l$LIB" >&5
+echo "configure:28384: checking for dbm_open in -l$LIB" >&5
 ac_lib_var=`echo $LIB'_'dbm_open | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -28452,7 +28388,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$LIB  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 28456 "configure"
+#line 28392 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -28463,7 +28399,7 @@ int main() {
 dbm_open()
 ; return 0; }
 EOF
-if { (eval echo configure:28467: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:28403: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -28632,7 +28568,7 @@ fi
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:28636: checking for $THIS_FULL_NAME support" >&5
+echo "configure:28572: checking for $THIS_FULL_NAME support" >&5
   if test -n ""; then
     { echo "configure: error: " 1>&2; exit 1; }
   fi
@@ -28699,7 +28635,7 @@ if test "$PHP_DB4" != "no"; then
   LIBS="-l$LIB $LIBS"
   
         cat > conftest.$ac_ext <<EOF
-#line 28703 "configure"
+#line 28639 "configure"
 #include "confdefs.h"
 
 #include "$THIS_INCLUDE"
@@ -28710,11 +28646,11 @@ int main() {
         
 ; return 0; }
 EOF
-if { (eval echo configure:28714: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:28650: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   
           cat > conftest.$ac_ext <<EOF
-#line 28718 "configure"
+#line 28654 "configure"
 #include "confdefs.h"
 
 #include "$THIS_INCLUDE"
@@ -28751,14 +28687,14 @@ rm -f conftest*
   done
   if test -z "$THIS_LIBS"; then
     echo $ac_n "checking for db4 major version""... $ac_c" 1>&6
-echo "configure:28755: checking for db4 major version" >&5
+echo "configure:28691: checking for db4 major version" >&5
     { echo "configure: error: Header contains different version" 1>&2; exit 1; }
   fi
   if test "4" = "4"; then
     echo $ac_n "checking for db4 minor version and patch level""... $ac_c" 1>&6
-echo "configure:28760: checking for db4 minor version and patch level" >&5
+echo "configure:28696: checking for db4 minor version and patch level" >&5
     cat > conftest.$ac_ext <<EOF
-#line 28762 "configure"
+#line 28698 "configure"
 #include "confdefs.h"
 
 #include "$THIS_INCLUDE"
@@ -28784,9 +28720,9 @@ rm -f conftest*
   fi
   if test "$ext_shared" = "yes"; then
     echo $ac_n "checking if dba can be used as shared extension""... $ac_c" 1>&6
-echo "configure:28788: checking if dba can be used as shared extension" >&5
+echo "configure:28724: checking if dba can be used as shared extension" >&5
     cat > conftest.$ac_ext <<EOF
-#line 28790 "configure"
+#line 28726 "configure"
 #include "confdefs.h"
 
 #include "$THIS_INCLUDE"
@@ -28943,7 +28879,7 @@ fi
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:28947: checking for $THIS_FULL_NAME support" >&5
+echo "configure:28883: checking for $THIS_FULL_NAME support" >&5
   if test -n ""; then
     { echo "configure: error: " 1>&2; exit 1; }
   fi
@@ -28971,7 +28907,7 @@ if test "$PHP_DB3" != "no"; then
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:28975: checking for $THIS_FULL_NAME support" >&5
+echo "configure:28911: checking for $THIS_FULL_NAME support" >&5
   if test -n "You cannot combine --with-db3 with --with-db4"; then
     { echo "configure: error: You cannot combine --with-db3 with --with-db4" 1>&2; exit 1; }
   fi
@@ -29022,7 +28958,7 @@ echo "configure:28975: checking for $THIS_FULL_NAME support" >&5
   LIBS="-l$LIB $LIBS"
   
         cat > conftest.$ac_ext <<EOF
-#line 29026 "configure"
+#line 28962 "configure"
 #include "confdefs.h"
 
 #include "$THIS_INCLUDE"
@@ -29033,11 +28969,11 @@ int main() {
         
 ; return 0; }
 EOF
-if { (eval echo configure:29037: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:28973: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   
           cat > conftest.$ac_ext <<EOF
-#line 29041 "configure"
+#line 28977 "configure"
 #include "confdefs.h"
 
 #include "$THIS_INCLUDE"
@@ -29074,14 +29010,14 @@ rm -f conftest*
   done
   if test -z "$THIS_LIBS"; then
     echo $ac_n "checking for db3 major version""... $ac_c" 1>&6
-echo "configure:29078: checking for db3 major version" >&5
+echo "configure:29014: checking for db3 major version" >&5
     { echo "configure: error: Header contains different version" 1>&2; exit 1; }
   fi
   if test "3" = "4"; then
     echo $ac_n "checking for db4 minor version and patch level""... $ac_c" 1>&6
-echo "configure:29083: checking for db4 minor version and patch level" >&5
+echo "configure:29019: checking for db4 minor version and patch level" >&5
     cat > conftest.$ac_ext <<EOF
-#line 29085 "configure"
+#line 29021 "configure"
 #include "confdefs.h"
 
 #include "$THIS_INCLUDE"
@@ -29107,9 +29043,9 @@ rm -f conftest*
   fi
   if test "$ext_shared" = "yes"; then
     echo $ac_n "checking if dba can be used as shared extension""... $ac_c" 1>&6
-echo "configure:29111: checking if dba can be used as shared extension" >&5
+echo "configure:29047: checking if dba can be used as shared extension" >&5
     cat > conftest.$ac_ext <<EOF
-#line 29113 "configure"
+#line 29049 "configure"
 #include "confdefs.h"
 
 #include "$THIS_INCLUDE"
@@ -29266,7 +29202,7 @@ fi
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:29270: checking for $THIS_FULL_NAME support" >&5
+echo "configure:29206: checking for $THIS_FULL_NAME support" >&5
   if test -n ""; then
     { echo "configure: error: " 1>&2; exit 1; }
   fi
@@ -29294,7 +29230,7 @@ if test "$PHP_DB2" != "no"; then
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:29298: checking for $THIS_FULL_NAME support" >&5
+echo "configure:29234: checking for $THIS_FULL_NAME support" >&5
   if test -n "You cannot combine --with-db2 with --with-db3 or --with-db4"; then
     { echo "configure: error: You cannot combine --with-db2 with --with-db3 or --with-db4" 1>&2; exit 1; }
   fi
@@ -29345,7 +29281,7 @@ echo "configure:29298: checking for $THIS_FULL_NAME support" >&5
   LIBS="-l$LIB $LIBS"
   
         cat > conftest.$ac_ext <<EOF
-#line 29349 "configure"
+#line 29285 "configure"
 #include "confdefs.h"
 
 #include "$THIS_INCLUDE"
@@ -29356,11 +29292,11 @@ int main() {
         
 ; return 0; }
 EOF
-if { (eval echo configure:29360: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:29296: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   
           cat > conftest.$ac_ext <<EOF
-#line 29364 "configure"
+#line 29300 "configure"
 #include "confdefs.h"
 
 #include "$THIS_INCLUDE"
@@ -29397,14 +29333,14 @@ rm -f conftest*
   done
   if test -z "$THIS_LIBS"; then
     echo $ac_n "checking for db2 major version""... $ac_c" 1>&6
-echo "configure:29401: checking for db2 major version" >&5
+echo "configure:29337: checking for db2 major version" >&5
     { echo "configure: error: Header contains different version" 1>&2; exit 1; }
   fi
   if test "2" = "4"; then
     echo $ac_n "checking for db4 minor version and patch level""... $ac_c" 1>&6
-echo "configure:29406: checking for db4 minor version and patch level" >&5
+echo "configure:29342: checking for db4 minor version and patch level" >&5
     cat > conftest.$ac_ext <<EOF
-#line 29408 "configure"
+#line 29344 "configure"
 #include "confdefs.h"
 
 #include "$THIS_INCLUDE"
@@ -29430,9 +29366,9 @@ rm -f conftest*
   fi
   if test "$ext_shared" = "yes"; then
     echo $ac_n "checking if dba can be used as shared extension""... $ac_c" 1>&6
-echo "configure:29434: checking if dba can be used as shared extension" >&5
+echo "configure:29370: checking if dba can be used as shared extension" >&5
     cat > conftest.$ac_ext <<EOF
-#line 29436 "configure"
+#line 29372 "configure"
 #include "confdefs.h"
 
 #include "$THIS_INCLUDE"
@@ -29589,7 +29525,7 @@ fi
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:29593: checking for $THIS_FULL_NAME support" >&5
+echo "configure:29529: checking for $THIS_FULL_NAME support" >&5
   if test -n ""; then
     { echo "configure: error: " 1>&2; exit 1; }
   fi
@@ -29609,7 +29545,7 @@ if test "$PHP_DB1" != "no"; then
   unset THIS_INCLUDE THIS_LIBS THIS_LFLAGS THIS_PREFIX THIS_RESULT
 
   echo $ac_n "checking for DB1 in library""... $ac_c" 1>&6
-echo "configure:29613: checking for DB1 in library" >&5
+echo "configure:29549: checking for DB1 in library" >&5
   if test "$HAVE_DB4" = "1"; then
     THIS_VERSION=4
     THIS_LIBS=$DB4_LIBS
@@ -29657,7 +29593,7 @@ EOF
   fi
   echo "$ac_t""$THIS_LIBS" 1>&6
   echo $ac_n "checking for DB1 in header""... $ac_c" 1>&6
-echo "configure:29661: checking for DB1 in header" >&5
+echo "configure:29597: checking for DB1 in header" >&5
   echo "$ac_t""$THIS_INCLUDE" 1>&6
   if test -n "$THIS_INCLUDE"; then
     
@@ -29667,7 +29603,7 @@ echo "configure:29661: checking for DB1 in header" >&5
   LIBS="-l$THIS_LIBS $LIBS"
   
       cat > conftest.$ac_ext <<EOF
-#line 29671 "configure"
+#line 29607 "configure"
 #include "confdefs.h"
 
 #include "$THIS_INCLUDE"
@@ -29678,7 +29614,7 @@ int main() {
       
 ; return 0; }
 EOF
-if { (eval echo configure:29682: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:29618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   
         cat >> confdefs.h <<EOF
@@ -29828,7 +29764,7 @@ fi
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:29832: checking for $THIS_FULL_NAME support" >&5
+echo "configure:29768: checking for $THIS_FULL_NAME support" >&5
   if test -n ""; then
     { echo "configure: error: " 1>&2; exit 1; }
   fi
@@ -29856,7 +29792,7 @@ if test "$PHP_DBM" != "no"; then
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:29860: checking for $THIS_FULL_NAME support" >&5
+echo "configure:29796: checking for $THIS_FULL_NAME support" >&5
   if test -n "You cannot combine --with-dbm with --with-qdbm"; then
     { echo "configure: error: You cannot combine --with-dbm with --with-qdbm" 1>&2; exit 1; }
   fi
@@ -29980,7 +29916,7 @@ echo "configure:29860: checking for $THIS_FULL_NAME support" >&5
   done
 
   echo $ac_n "checking for dbminit in -l$LIB""... $ac_c" 1>&6
-echo "configure:29984: checking for dbminit in -l$LIB" >&5
+echo "configure:29920: checking for dbminit in -l$LIB" >&5
 ac_lib_var=`echo $LIB'_'dbminit | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -29988,7 +29924,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$LIB  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 29992 "configure"
+#line 29928 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -29999,7 +29935,7 @@ int main() {
 dbminit()
 ; return 0; }
 EOF
-if { (eval echo configure:30003: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:29939: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -30019,7 +29955,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
     ext_shared=$save_ext_shared
     
         echo $ac_n "checking for DBM using GDBM""... $ac_c" 1>&6
-echo "configure:30023: checking for DBM using GDBM" >&5
+echo "configure:29959: checking for DBM using GDBM" >&5
         cat >> confdefs.h <<EOF
 #define DBM_INCLUDE_FILE "$THIS_INCLUDE"
 EOF
@@ -30183,7 +30119,7 @@ fi
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:30187: checking for $THIS_FULL_NAME support" >&5
+echo "configure:30123: checking for $THIS_FULL_NAME support" >&5
   if test -n ""; then
     { echo "configure: error: " 1>&2; exit 1; }
   fi
@@ -30404,7 +30340,7 @@ elif test "$PHP_CDB" != "no"; then
   done
 
   echo $ac_n "checking for cdb_read in -l$LIB""... $ac_c" 1>&6
-echo "configure:30408: checking for cdb_read in -l$LIB" >&5
+echo "configure:30344: checking for cdb_read in -l$LIB" >&5
 ac_lib_var=`echo $LIB'_'cdb_read | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -30412,7 +30348,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$LIB  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 30416 "configure"
+#line 30352 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -30423,7 +30359,7 @@ int main() {
 cdb_read()
 ; return 0; }
 EOF
-if { (eval echo configure:30427: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:30363: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -30592,7 +30528,7 @@ fi
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:30596: checking for $THIS_FULL_NAME support" >&5
+echo "configure:30532: checking for $THIS_FULL_NAME support" >&5
   if test -n ""; then
     { echo "configure: error: " 1>&2; exit 1; }
   fi
@@ -30623,7 +30559,7 @@ fi
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:30627: checking for $THIS_FULL_NAME support" >&5
+echo "configure:30563: checking for $THIS_FULL_NAME support" >&5
   if test -n ""; then
     { echo "configure: error: " 1>&2; exit 1; }
   fi
@@ -30654,7 +30590,7 @@ fi
     THIS_FULL_NAME="$THIS_NAME"
   fi
   echo $ac_n "checking for $THIS_FULL_NAME support""... $ac_c" 1>&6
-echo "configure:30658: checking for $THIS_FULL_NAME support" >&5
+echo "configure:30594: checking for $THIS_FULL_NAME support" >&5
   if test -n ""; then
     { echo "configure: error: " 1>&2; exit 1; }
   fi
@@ -30669,7 +30605,7 @@ echo "configure:30658: checking for $THIS_FULL_NAME support" >&5
 
 
 echo $ac_n "checking whether to enable DBA interface""... $ac_c" 1>&6
-echo "configure:30673: checking whether to enable DBA interface" >&5
+echo "configure:30609: checking whether to enable DBA interface" >&5
 if test "$HAVE_DBA" = "1"; then
   if test "$ext_shared" = "yes"; then
     echo "$ac_t""yes, shared" 1>&6
@@ -30999,7 +30935,7 @@ fi
 php_enable_dbase=no
 
 echo $ac_n "checking whether to enable dbase support""... $ac_c" 1>&6
-echo "configure:31003: checking whether to enable dbase support" >&5
+echo "configure:30939: checking whether to enable dbase support" >&5
 # Check whether --enable-dbase or --disable-dbase was given.
 if test "${enable_dbase+set}" = set; then
   enableval="$enable_dbase"
@@ -31346,7 +31282,7 @@ fi
 php_enable_dom=yes
 
 echo $ac_n "checking whether to enable DOM support""... $ac_c" 1>&6
-echo "configure:31350: checking whether to enable DOM support" >&5
+echo "configure:31286: checking whether to enable DOM support" >&5
 # Check whether --enable-dom or --disable-dom was given.
 if test "${enable_dom+set}" = set; then
   enableval="$enable_dom"
@@ -31394,7 +31330,7 @@ if test -z "$PHP_LIBXML_DIR"; then
 php_with_libxml_dir=no
 
 echo $ac_n "checking libxml2 install dir""... $ac_c" 1>&6
-echo "configure:31398: checking libxml2 install dir" >&5
+echo "configure:31334: checking libxml2 install dir" >&5
 # Check whether --with-libxml-dir or --without-libxml-dir was given.
 if test "${with_libxml_dir+set}" = set; then
   withval="$with_libxml_dir"
@@ -31425,7 +31361,7 @@ if test "$PHP_DOM" != "no"; then
 
   
 echo $ac_n "checking for xml2-config path""... $ac_c" 1>&6
-echo "configure:31429: checking for xml2-config path" >&5
+echo "configure:31365: checking for xml2-config path" >&5
 if eval "test \"`echo '$''{'ac_cv_php_xml2_config_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -31583,7 +31519,7 @@ echo "$ac_t""$ac_cv_php_xml2_config_path" 1>&6
 
 
             echo $ac_n "checking whether libxml build works""... $ac_c" 1>&6
-echo "configure:31587: checking whether libxml build works" >&5
+echo "configure:31523: checking whether libxml build works" >&5
 if eval "test \"`echo '$''{'php_cv_libxml_build_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -31599,7 +31535,7 @@ else
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 31603 "configure"
+#line 31539 "configure"
 #include "confdefs.h"
 
     
@@ -31610,7 +31546,7 @@ else
     }
   
 EOF
-if { (eval echo configure:31614: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:31550: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     LIBS=$old_LIBS
@@ -32033,7 +31969,7 @@ fi
 php_enable_exif=no
 
 echo $ac_n "checking whether to enable EXIF (metadata from images) support""... $ac_c" 1>&6
-echo "configure:32037: checking whether to enable EXIF (metadata from images) support" >&5
+echo "configure:31973: checking whether to enable EXIF (metadata from images) support" >&5
 # Check whether --enable-exif or --disable-exif was given.
 if test "${enable_exif+set}" = set; then
   enableval="$enable_exif"
@@ -32380,7 +32316,7 @@ fi
 php_with_fbsql=no
 
 echo $ac_n "checking for FrontBase SQL92 (fbsql) support""... $ac_c" 1>&6
-echo "configure:32384: checking for FrontBase SQL92 (fbsql) support" >&5
+echo "configure:32320: checking for FrontBase SQL92 (fbsql) support" >&5
 # Check whether --with-fbsql or --without-fbsql was given.
 if test "${with_fbsql+set}" = set; then
   withval="$with_fbsql"
@@ -32887,7 +32823,7 @@ fi
 php_with_fdftk=no
 
 echo $ac_n "checking for FDF support""... $ac_c" 1>&6
-echo "configure:32891: checking for FDF support" >&5
+echo "configure:32827: checking for FDF support" >&5
 # Check whether --with-fdftk or --without-fdftk was given.
 if test "${with_fdftk+set}" = set; then
   withval="$with_fdftk"
@@ -33105,7 +33041,7 @@ EOF
   done
 
   echo $ac_n "checking for FDFOpen in -l$file""... $ac_c" 1>&6
-echo "configure:33109: checking for FDFOpen in -l$file" >&5
+echo "configure:33045: checking for FDFOpen in -l$file" >&5
 ac_lib_var=`echo $file'_'FDFOpen | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -33113,7 +33049,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$file  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 33117 "configure"
+#line 33053 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -33124,7 +33060,7 @@ int main() {
 FDFOpen()
 ; return 0; }
 EOF
-if { (eval echo configure:33128: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:33064: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -33251,7 +33187,7 @@ fi
   done
 
   echo $ac_n "checking for FDFGetFDFVersion in -l$file""... $ac_c" 1>&6
-echo "configure:33255: checking for FDFGetFDFVersion in -l$file" >&5
+echo "configure:33191: checking for FDFGetFDFVersion in -l$file" >&5
 ac_lib_var=`echo $file'_'FDFGetFDFVersion | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -33259,7 +33195,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$file  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 33263 "configure"
+#line 33199 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -33270,7 +33206,7 @@ int main() {
 FDFGetFDFVersion()
 ; return 0; }
 EOF
-if { (eval echo configure:33274: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:33210: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -33718,7 +33654,7 @@ fi
 php_enable_filter=yes
 
 echo $ac_n "checking whether to enable input filter support""... $ac_c" 1>&6
-echo "configure:33722: checking whether to enable input filter support" >&5
+echo "configure:33658: checking whether to enable input filter support" >&5
 # Check whether --enable-filter or --disable-filter was given.
 if test "${enable_filter+set}" = set; then
   enableval="$enable_filter"
@@ -33765,7 +33701,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_pcre_dir=no
 
 echo $ac_n "checking pcre install prefix""... $ac_c" 1>&6
-echo "configure:33769: checking pcre install prefix" >&5
+echo "configure:33705: checking pcre install prefix" >&5
 # Check whether --with-pcre-dir or --without-pcre-dir was given.
 if test "${with_pcre_dir+set}" = set; then
   withval="$with_pcre_dir"
@@ -33795,7 +33731,7 @@ if test "$PHP_FILTER" != "no"; then
         old_CPPFLAGS=$CPPFLAGS
     CPPFLAGS=$INCLUDES
     cat > conftest.$ac_ext <<EOF
-#line 33799 "configure"
+#line 33735 "configure"
 #include "confdefs.h"
 
 #include <main/php_config.h>
@@ -33814,7 +33750,7 @@ else
   rm -rf conftest*
   
       cat > conftest.$ac_ext <<EOF
-#line 33818 "configure"
+#line 33754 "configure"
 #include "confdefs.h"
 
 #include <main/php_config.h>
@@ -34184,7 +34120,7 @@ fi
 php_enable_ftp=no
 
 echo $ac_n "checking whether to enable FTP support""... $ac_c" 1>&6
-echo "configure:34188: checking whether to enable FTP support" >&5
+echo "configure:34124: checking whether to enable FTP support" >&5
 # Check whether --enable-ftp or --disable-ftp was given.
 if test "${enable_ftp+set}" = set; then
   enableval="$enable_ftp"
@@ -34231,7 +34167,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_openssl_dir=no
 
 echo $ac_n "checking OpenSSL dir for FTP""... $ac_c" 1>&6
-echo "configure:34235: checking OpenSSL dir for FTP" >&5
+echo "configure:34171: checking OpenSSL dir for FTP" >&5
 # Check whether --with-openssl-dir or --without-openssl-dir was given.
 if test "${with_openssl_dir+set}" = set; then
   withval="$with_openssl_dir"
@@ -34572,7 +34508,7 @@ EOF
     # Extract the first word of "pkg-config", so it can be a program name with args.
 set dummy pkg-config; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:34576: checking for $ac_word" >&5
+echo "configure:34512: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_PKG_CONFIG'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -34777,9 +34713,9 @@ fi
     old_CPPFLAGS=$CPPFLAGS
     CPPFLAGS=-I$OPENSSL_INCDIR
     echo $ac_n "checking for OpenSSL version""... $ac_c" 1>&6
-echo "configure:34781: checking for OpenSSL version" >&5
+echo "configure:34717: checking for OpenSSL version" >&5
     cat > conftest.$ac_ext <<EOF
-#line 34783 "configure"
+#line 34719 "configure"
 #include "confdefs.h"
 
 #include <openssl/opensslv.h>
@@ -34934,7 +34870,7 @@ rm -f conftest*
   done
 
   echo $ac_n "checking for CRYPTO_free in -lcrypto""... $ac_c" 1>&6
-echo "configure:34938: checking for CRYPTO_free in -lcrypto" >&5
+echo "configure:34874: checking for CRYPTO_free in -lcrypto" >&5
 ac_lib_var=`echo crypto'_'CRYPTO_free | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -34942,7 +34878,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lcrypto  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 34946 "configure"
+#line 34882 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -34953,7 +34889,7 @@ int main() {
 CRYPTO_free()
 ; return 0; }
 EOF
-if { (eval echo configure:34957: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:34893: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -35110,7 +35046,7 @@ fi
   done
 
   echo $ac_n "checking for SSL_CTX_set_ssl_version in -lssl""... $ac_c" 1>&6
-echo "configure:35114: checking for SSL_CTX_set_ssl_version in -lssl" >&5
+echo "configure:35050: checking for SSL_CTX_set_ssl_version in -lssl" >&5
 ac_lib_var=`echo ssl'_'SSL_CTX_set_ssl_version | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -35118,7 +35054,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lssl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 35122 "configure"
+#line 35058 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -35129,7 +35065,7 @@ int main() {
 SSL_CTX_set_ssl_version()
 ; return 0; }
 EOF
-if { (eval echo configure:35133: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:35069: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -35248,7 +35184,7 @@ fi
 php_with_gd=no
 
 echo $ac_n "checking for GD support""... $ac_c" 1>&6
-echo "configure:35252: checking for GD support" >&5
+echo "configure:35188: checking for GD support" >&5
 # Check whether --with-gd or --without-gd was given.
 if test "${with_gd+set}" = set; then
   withval="$with_gd"
@@ -35296,7 +35232,7 @@ if test -z "$PHP_JPEG_DIR"; then
 php_with_jpeg_dir=no
 
 echo $ac_n "checking for the location of libjpeg""... $ac_c" 1>&6
-echo "configure:35300: checking for the location of libjpeg" >&5
+echo "configure:35236: checking for the location of libjpeg" >&5
 # Check whether --with-jpeg-dir or --without-jpeg-dir was given.
 if test "${with_jpeg_dir+set}" = set; then
   withval="$with_jpeg_dir"
@@ -35324,7 +35260,7 @@ if test -z "$PHP_PNG_DIR"; then
 php_with_png_dir=no
 
 echo $ac_n "checking for the location of libpng""... $ac_c" 1>&6
-echo "configure:35328: checking for the location of libpng" >&5
+echo "configure:35264: checking for the location of libpng" >&5
 # Check whether --with-png-dir or --without-png-dir was given.
 if test "${with_png_dir+set}" = set; then
   withval="$with_png_dir"
@@ -35352,7 +35288,7 @@ if test -z "$PHP_ZLIB_DIR"; then
 php_with_zlib_dir=no
 
 echo $ac_n "checking for the location of libz""... $ac_c" 1>&6
-echo "configure:35356: checking for the location of libz" >&5
+echo "configure:35292: checking for the location of libz" >&5
 # Check whether --with-zlib-dir or --without-zlib-dir was given.
 if test "${with_zlib_dir+set}" = set; then
   withval="$with_zlib_dir"
@@ -35379,7 +35315,7 @@ fi
 php_with_xpm_dir=no
 
 echo $ac_n "checking for the location of libXpm""... $ac_c" 1>&6
-echo "configure:35383: checking for the location of libXpm" >&5
+echo "configure:35319: checking for the location of libXpm" >&5
 # Check whether --with-xpm-dir or --without-xpm-dir was given.
 if test "${with_xpm_dir+set}" = set; then
   withval="$with_xpm_dir"
@@ -35405,7 +35341,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_ttf=no
 
 echo $ac_n "checking for FreeType 1.x support""... $ac_c" 1>&6
-echo "configure:35409: checking for FreeType 1.x support" >&5
+echo "configure:35345: checking for FreeType 1.x support" >&5
 # Check whether --with-ttf or --without-ttf was given.
 if test "${with_ttf+set}" = set; then
   withval="$with_ttf"
@@ -35431,7 +35367,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_freetype_dir=no
 
 echo $ac_n "checking for FreeType 2""... $ac_c" 1>&6
-echo "configure:35435: checking for FreeType 2" >&5
+echo "configure:35371: checking for FreeType 2" >&5
 # Check whether --with-freetype-dir or --without-freetype-dir was given.
 if test "${with_freetype_dir+set}" = set; then
   withval="$with_freetype_dir"
@@ -35457,7 +35393,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_t1lib=no
 
 echo $ac_n "checking for T1lib support""... $ac_c" 1>&6
-echo "configure:35461: checking for T1lib support" >&5
+echo "configure:35397: checking for T1lib support" >&5
 # Check whether --with-t1lib or --without-t1lib was given.
 if test "${with_t1lib+set}" = set; then
   withval="$with_t1lib"
@@ -35483,7 +35419,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_enable_gd_native_ttf=no
 
 echo $ac_n "checking whether to enable truetype string function in GD""... $ac_c" 1>&6
-echo "configure:35487: checking whether to enable truetype string function in GD" >&5
+echo "configure:35423: checking whether to enable truetype string function in GD" >&5
 # Check whether --enable-gd-native-ttf or --disable-gd-native-ttf was given.
 if test "${enable_gd_native_ttf+set}" = set; then
   enableval="$enable_gd_native_ttf"
@@ -35509,7 +35445,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_enable_gd_jis_conv=no
 
 echo $ac_n "checking whether to enable JIS-mapped Japanese font support in GD""... $ac_c" 1>&6
-echo "configure:35513: checking whether to enable JIS-mapped Japanese font support in GD" >&5
+echo "configure:35449: checking whether to enable JIS-mapped Japanese font support in GD" >&5
 # Check whether --enable-gd-jis-conv or --disable-gd-jis-conv was given.
 if test "${enable_gd_jis_conv+set}" = set; then
   enableval="$enable_gd_jis_conv"
@@ -35565,12 +35501,12 @@ if test "$PHP_GD" = "yes"; then
   for ac_func in fabsf floorf
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:35569: checking for $ac_func" >&5
+echo "configure:35505: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 35574 "configure"
+#line 35510 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -35593,7 +35529,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:35597: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:35533: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -35765,7 +35701,7 @@ EOF
   done
 
   echo $ac_n "checking for jpeg_read_header in -ljpeg""... $ac_c" 1>&6
-echo "configure:35769: checking for jpeg_read_header in -ljpeg" >&5
+echo "configure:35705: checking for jpeg_read_header in -ljpeg" >&5
 ac_lib_var=`echo jpeg'_'jpeg_read_header | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -35773,7 +35709,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ljpeg  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 35777 "configure"
+#line 35713 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -35784,7 +35720,7 @@ int main() {
 jpeg_read_header()
 ; return 0; }
 EOF
-if { (eval echo configure:35788: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:35724: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -36066,7 +36002,7 @@ fi
   done
 
   echo $ac_n "checking for png_write_image in -lpng""... $ac_c" 1>&6
-echo "configure:36070: checking for png_write_image in -lpng" >&5
+echo "configure:36006: checking for png_write_image in -lpng" >&5
 ac_lib_var=`echo png'_'png_write_image | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -36074,7 +36010,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpng  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 36078 "configure"
+#line 36014 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -36085,7 +36021,7 @@ int main() {
 png_write_image()
 ; return 0; }
 EOF
-if { (eval echo configure:36089: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:36025: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -36465,7 +36401,7 @@ fi
   done
 
   echo $ac_n "checking for XpmFreeXpmImage in -lXpm""... $ac_c" 1>&6
-echo "configure:36469: checking for XpmFreeXpmImage in -lXpm" >&5
+echo "configure:36405: checking for XpmFreeXpmImage in -lXpm" >&5
 ac_lib_var=`echo Xpm'_'XpmFreeXpmImage | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -36473,7 +36409,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lXpm  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 36477 "configure"
+#line 36413 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -36484,7 +36420,7 @@ int main() {
 XpmFreeXpmImage()
 ; return 0; }
 EOF
-if { (eval echo configure:36488: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:36424: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -36859,7 +36795,7 @@ fi
   done
 
   echo $ac_n "checking for FT_New_Face in -lfreetype""... $ac_c" 1>&6
-echo "configure:36863: checking for FT_New_Face in -lfreetype" >&5
+echo "configure:36799: checking for FT_New_Face in -lfreetype" >&5
 ac_lib_var=`echo freetype'_'FT_New_Face | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -36867,7 +36803,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lfreetype  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 36871 "configure"
+#line 36807 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -36878,7 +36814,7 @@ int main() {
 FT_New_Face()
 ; return 0; }
 EOF
-if { (eval echo configure:36882: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:36818: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -37241,7 +37177,7 @@ EOF
 
     else
       echo $ac_n "checking for FreeType 1 support""... $ac_c" 1>&6
-echo "configure:37245: checking for FreeType 1 support" >&5
+echo "configure:37181: checking for FreeType 1 support" >&5
       echo "$ac_t""no - FreeType 2.x is to be used instead" 1>&6
     fi
   fi
@@ -37355,7 +37291,7 @@ echo "configure:37245: checking for FreeType 1 support" >&5
   done
 
   echo $ac_n "checking for T1_StrError in -lt1""... $ac_c" 1>&6
-echo "configure:37359: checking for T1_StrError in -lt1" >&5
+echo "configure:37295: checking for T1_StrError in -lt1" >&5
 ac_lib_var=`echo t1'_'T1_StrError | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -37363,7 +37299,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lt1  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 37367 "configure"
+#line 37303 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -37374,7 +37310,7 @@ int main() {
 T1_StrError()
 ; return 0; }
 EOF
-if { (eval echo configure:37378: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:37314: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -37816,7 +37752,7 @@ EOF
   done
 
   echo $ac_n "checking for jpeg_read_header in -ljpeg""... $ac_c" 1>&6
-echo "configure:37820: checking for jpeg_read_header in -ljpeg" >&5
+echo "configure:37756: checking for jpeg_read_header in -ljpeg" >&5
 ac_lib_var=`echo jpeg'_'jpeg_read_header | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -37824,7 +37760,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ljpeg  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 37828 "configure"
+#line 37764 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -37835,7 +37771,7 @@ int main() {
 jpeg_read_header()
 ; return 0; }
 EOF
-if { (eval echo configure:37839: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:37775: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -38117,7 +38053,7 @@ fi
   done
 
   echo $ac_n "checking for png_write_image in -lpng""... $ac_c" 1>&6
-echo "configure:38121: checking for png_write_image in -lpng" >&5
+echo "configure:38057: checking for png_write_image in -lpng" >&5
 ac_lib_var=`echo png'_'png_write_image | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -38125,7 +38061,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpng  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 38129 "configure"
+#line 38065 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -38136,7 +38072,7 @@ int main() {
 png_write_image()
 ; return 0; }
 EOF
-if { (eval echo configure:38140: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:38076: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -38516,7 +38452,7 @@ fi
   done
 
   echo $ac_n "checking for XpmFreeXpmImage in -lXpm""... $ac_c" 1>&6
-echo "configure:38520: checking for XpmFreeXpmImage in -lXpm" >&5
+echo "configure:38456: checking for XpmFreeXpmImage in -lXpm" >&5
 ac_lib_var=`echo Xpm'_'XpmFreeXpmImage | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -38524,7 +38460,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lXpm  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 38528 "configure"
+#line 38464 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -38535,7 +38471,7 @@ int main() {
 XpmFreeXpmImage()
 ; return 0; }
 EOF
-if { (eval echo configure:38539: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:38475: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -38910,7 +38846,7 @@ fi
   done
 
   echo $ac_n "checking for FT_New_Face in -lfreetype""... $ac_c" 1>&6
-echo "configure:38914: checking for FT_New_Face in -lfreetype" >&5
+echo "configure:38850: checking for FT_New_Face in -lfreetype" >&5
 ac_lib_var=`echo freetype'_'FT_New_Face | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -38918,7 +38854,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lfreetype  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 38922 "configure"
+#line 38858 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -38929,7 +38865,7 @@ int main() {
 FT_New_Face()
 ; return 0; }
 EOF
-if { (eval echo configure:38933: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:38869: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -39292,7 +39228,7 @@ EOF
 
     else
       echo $ac_n "checking for FreeType 1 support""... $ac_c" 1>&6
-echo "configure:39296: checking for FreeType 1 support" >&5
+echo "configure:39232: checking for FreeType 1 support" >&5
       echo "$ac_t""no - FreeType 2.x is to be used instead" 1>&6
     fi
   fi
@@ -39406,7 +39342,7 @@ echo "configure:39296: checking for FreeType 1 support" >&5
   done
 
   echo $ac_n "checking for T1_StrError in -lt1""... $ac_c" 1>&6
-echo "configure:39410: checking for T1_StrError in -lt1" >&5
+echo "configure:39346: checking for T1_StrError in -lt1" >&5
 ac_lib_var=`echo t1'_'T1_StrError | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -39414,7 +39350,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lt1  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 39418 "configure"
+#line 39354 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -39425,7 +39361,7 @@ int main() {
 T1_StrError()
 ; return 0; }
 EOF
-if { (eval echo configure:39429: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:39365: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -39800,7 +39736,7 @@ EOF
   done
 
   echo $ac_n "checking for gdImageString16 in -lgd""... $ac_c" 1>&6
-echo "configure:39804: checking for gdImageString16 in -lgd" >&5
+echo "configure:39740: checking for gdImageString16 in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageString16 | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -39808,7 +39744,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 39812 "configure"
+#line 39748 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -39819,7 +39755,7 @@ int main() {
 gdImageString16()
 ; return 0; }
 EOF
-if { (eval echo configure:39823: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:39759: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -39948,7 +39884,7 @@ fi
   done
 
   echo $ac_n "checking for gdImagePaletteCopy in -lgd""... $ac_c" 1>&6
-echo "configure:39952: checking for gdImagePaletteCopy in -lgd" >&5
+echo "configure:39888: checking for gdImagePaletteCopy in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImagePaletteCopy | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -39956,7 +39892,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 39960 "configure"
+#line 39896 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -39967,7 +39903,7 @@ int main() {
 gdImagePaletteCopy()
 ; return 0; }
 EOF
-if { (eval echo configure:39971: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:39907: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -40096,7 +40032,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageCreateFromPng in -lgd""... $ac_c" 1>&6
-echo "configure:40100: checking for gdImageCreateFromPng in -lgd" >&5
+echo "configure:40036: checking for gdImageCreateFromPng in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageCreateFromPng | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -40104,7 +40040,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 40108 "configure"
+#line 40044 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -40115,7 +40051,7 @@ int main() {
 gdImageCreateFromPng()
 ; return 0; }
 EOF
-if { (eval echo configure:40119: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:40055: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -40244,7 +40180,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageCreateFromGif in -lgd""... $ac_c" 1>&6
-echo "configure:40248: checking for gdImageCreateFromGif in -lgd" >&5
+echo "configure:40184: checking for gdImageCreateFromGif in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageCreateFromGif | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -40252,7 +40188,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 40256 "configure"
+#line 40192 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -40263,7 +40199,7 @@ int main() {
 gdImageCreateFromGif()
 ; return 0; }
 EOF
-if { (eval echo configure:40267: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:40203: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -40392,7 +40328,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageGif in -lgd""... $ac_c" 1>&6
-echo "configure:40396: checking for gdImageGif in -lgd" >&5
+echo "configure:40332: checking for gdImageGif in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageGif | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -40400,7 +40336,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 40404 "configure"
+#line 40340 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -40411,7 +40347,7 @@ int main() {
 gdImageGif()
 ; return 0; }
 EOF
-if { (eval echo configure:40415: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:40351: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -40540,7 +40476,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageWBMP in -lgd""... $ac_c" 1>&6
-echo "configure:40544: checking for gdImageWBMP in -lgd" >&5
+echo "configure:40480: checking for gdImageWBMP in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageWBMP | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -40548,7 +40484,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 40552 "configure"
+#line 40488 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -40559,7 +40495,7 @@ int main() {
 gdImageWBMP()
 ; return 0; }
 EOF
-if { (eval echo configure:40563: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:40499: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -40688,7 +40624,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageCreateFromJpeg in -lgd""... $ac_c" 1>&6
-echo "configure:40692: checking for gdImageCreateFromJpeg in -lgd" >&5
+echo "configure:40628: checking for gdImageCreateFromJpeg in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageCreateFromJpeg | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -40696,7 +40632,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 40700 "configure"
+#line 40636 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -40707,7 +40643,7 @@ int main() {
 gdImageCreateFromJpeg()
 ; return 0; }
 EOF
-if { (eval echo configure:40711: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:40647: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -40836,7 +40772,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageCreateFromXpm in -lgd""... $ac_c" 1>&6
-echo "configure:40840: checking for gdImageCreateFromXpm in -lgd" >&5
+echo "configure:40776: checking for gdImageCreateFromXpm in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageCreateFromXpm | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -40844,7 +40780,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 40848 "configure"
+#line 40784 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -40855,7 +40791,7 @@ int main() {
 gdImageCreateFromXpm()
 ; return 0; }
 EOF
-if { (eval echo configure:40859: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:40795: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -40984,7 +40920,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageCreateFromGd2 in -lgd""... $ac_c" 1>&6
-echo "configure:40988: checking for gdImageCreateFromGd2 in -lgd" >&5
+echo "configure:40924: checking for gdImageCreateFromGd2 in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageCreateFromGd2 | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -40992,7 +40928,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 40996 "configure"
+#line 40932 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -41003,7 +40939,7 @@ int main() {
 gdImageCreateFromGd2()
 ; return 0; }
 EOF
-if { (eval echo configure:41007: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:40943: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -41132,7 +41068,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageCreateTrueColor in -lgd""... $ac_c" 1>&6
-echo "configure:41136: checking for gdImageCreateTrueColor in -lgd" >&5
+echo "configure:41072: checking for gdImageCreateTrueColor in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageCreateTrueColor | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -41140,7 +41076,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 41144 "configure"
+#line 41080 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -41151,7 +41087,7 @@ int main() {
 gdImageCreateTrueColor()
 ; return 0; }
 EOF
-if { (eval echo configure:41155: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:41091: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -41280,7 +41216,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageSetTile in -lgd""... $ac_c" 1>&6
-echo "configure:41284: checking for gdImageSetTile in -lgd" >&5
+echo "configure:41220: checking for gdImageSetTile in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageSetTile | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -41288,7 +41224,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 41292 "configure"
+#line 41228 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -41299,7 +41235,7 @@ int main() {
 gdImageSetTile()
 ; return 0; }
 EOF
-if { (eval echo configure:41303: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:41239: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -41428,7 +41364,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageEllipse in -lgd""... $ac_c" 1>&6
-echo "configure:41432: checking for gdImageEllipse in -lgd" >&5
+echo "configure:41368: checking for gdImageEllipse in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageEllipse | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -41436,7 +41372,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 41440 "configure"
+#line 41376 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -41447,7 +41383,7 @@ int main() {
 gdImageEllipse()
 ; return 0; }
 EOF
-if { (eval echo configure:41451: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:41387: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -41576,7 +41512,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageSetBrush in -lgd""... $ac_c" 1>&6
-echo "configure:41580: checking for gdImageSetBrush in -lgd" >&5
+echo "configure:41516: checking for gdImageSetBrush in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageSetBrush | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -41584,7 +41520,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 41588 "configure"
+#line 41524 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -41595,7 +41531,7 @@ int main() {
 gdImageSetBrush()
 ; return 0; }
 EOF
-if { (eval echo configure:41599: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:41535: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -41724,7 +41660,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageStringTTF in -lgd""... $ac_c" 1>&6
-echo "configure:41728: checking for gdImageStringTTF in -lgd" >&5
+echo "configure:41664: checking for gdImageStringTTF in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageStringTTF | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -41732,7 +41668,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 41736 "configure"
+#line 41672 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -41743,7 +41679,7 @@ int main() {
 gdImageStringTTF()
 ; return 0; }
 EOF
-if { (eval echo configure:41747: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:41683: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -41872,7 +41808,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageStringFT in -lgd""... $ac_c" 1>&6
-echo "configure:41876: checking for gdImageStringFT in -lgd" >&5
+echo "configure:41812: checking for gdImageStringFT in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageStringFT | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -41880,7 +41816,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 41884 "configure"
+#line 41820 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -41891,7 +41827,7 @@ int main() {
 gdImageStringFT()
 ; return 0; }
 EOF
-if { (eval echo configure:41895: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:41831: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -42020,7 +41956,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageStringFTEx in -lgd""... $ac_c" 1>&6
-echo "configure:42024: checking for gdImageStringFTEx in -lgd" >&5
+echo "configure:41960: checking for gdImageStringFTEx in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageStringFTEx | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -42028,7 +41964,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 42032 "configure"
+#line 41968 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -42039,7 +41975,7 @@ int main() {
 gdImageStringFTEx()
 ; return 0; }
 EOF
-if { (eval echo configure:42043: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:41979: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -42168,7 +42104,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageColorClosestHWB in -lgd""... $ac_c" 1>&6
-echo "configure:42172: checking for gdImageColorClosestHWB in -lgd" >&5
+echo "configure:42108: checking for gdImageColorClosestHWB in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageColorClosestHWB | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -42176,7 +42112,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 42180 "configure"
+#line 42116 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -42187,7 +42123,7 @@ int main() {
 gdImageColorClosestHWB()
 ; return 0; }
 EOF
-if { (eval echo configure:42191: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:42127: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -42316,7 +42252,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageColorResolve in -lgd""... $ac_c" 1>&6
-echo "configure:42320: checking for gdImageColorResolve in -lgd" >&5
+echo "configure:42256: checking for gdImageColorResolve in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageColorResolve | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -42324,7 +42260,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 42328 "configure"
+#line 42264 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -42335,7 +42271,7 @@ int main() {
 gdImageColorResolve()
 ; return 0; }
 EOF
-if { (eval echo configure:42339: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:42275: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -42464,7 +42400,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageGifCtx in -lgd""... $ac_c" 1>&6
-echo "configure:42468: checking for gdImageGifCtx in -lgd" >&5
+echo "configure:42404: checking for gdImageGifCtx in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageGifCtx | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -42472,7 +42408,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 42476 "configure"
+#line 42412 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -42483,7 +42419,7 @@ int main() {
 gdImageGifCtx()
 ; return 0; }
 EOF
-if { (eval echo configure:42487: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:42423: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -42612,7 +42548,7 @@ fi
   done
 
   echo $ac_n "checking for gdCacheCreate in -lgd""... $ac_c" 1>&6
-echo "configure:42616: checking for gdCacheCreate in -lgd" >&5
+echo "configure:42552: checking for gdCacheCreate in -lgd" >&5
 ac_lib_var=`echo gd'_'gdCacheCreate | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -42620,7 +42556,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 42624 "configure"
+#line 42560 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -42631,7 +42567,7 @@ int main() {
 gdCacheCreate()
 ; return 0; }
 EOF
-if { (eval echo configure:42635: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:42571: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -42760,7 +42696,7 @@ fi
   done
 
   echo $ac_n "checking for gdFontCacheShutdown in -lgd""... $ac_c" 1>&6
-echo "configure:42764: checking for gdFontCacheShutdown in -lgd" >&5
+echo "configure:42700: checking for gdFontCacheShutdown in -lgd" >&5
 ac_lib_var=`echo gd'_'gdFontCacheShutdown | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -42768,7 +42704,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 42772 "configure"
+#line 42708 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -42779,7 +42715,7 @@ int main() {
 gdFontCacheShutdown()
 ; return 0; }
 EOF
-if { (eval echo configure:42783: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:42719: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -42908,7 +42844,7 @@ fi
   done
 
   echo $ac_n "checking for gdFreeFontCache in -lgd""... $ac_c" 1>&6
-echo "configure:42912: checking for gdFreeFontCache in -lgd" >&5
+echo "configure:42848: checking for gdFreeFontCache in -lgd" >&5
 ac_lib_var=`echo gd'_'gdFreeFontCache | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -42916,7 +42852,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 42920 "configure"
+#line 42856 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -42927,7 +42863,7 @@ int main() {
 gdFreeFontCache()
 ; return 0; }
 EOF
-if { (eval echo configure:42931: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:42867: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -43056,7 +42992,7 @@ fi
   done
 
   echo $ac_n "checking for gdFontCacheMutexSetup in -lgd""... $ac_c" 1>&6
-echo "configure:43060: checking for gdFontCacheMutexSetup in -lgd" >&5
+echo "configure:42996: checking for gdFontCacheMutexSetup in -lgd" >&5
 ac_lib_var=`echo gd'_'gdFontCacheMutexSetup | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -43064,7 +43000,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 43068 "configure"
+#line 43004 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -43075,7 +43011,7 @@ int main() {
 gdFontCacheMutexSetup()
 ; return 0; }
 EOF
-if { (eval echo configure:43079: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:43015: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -43204,7 +43140,7 @@ fi
   done
 
   echo $ac_n "checking for gdNewDynamicCtxEx in -lgd""... $ac_c" 1>&6
-echo "configure:43208: checking for gdNewDynamicCtxEx in -lgd" >&5
+echo "configure:43144: checking for gdNewDynamicCtxEx in -lgd" >&5
 ac_lib_var=`echo gd'_'gdNewDynamicCtxEx | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -43212,7 +43148,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 43216 "configure"
+#line 43152 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -43223,7 +43159,7 @@ int main() {
 gdNewDynamicCtxEx()
 ; return 0; }
 EOF
-if { (eval echo configure:43227: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:43163: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -43278,7 +43214,7 @@ fi
         old_CPPFLAGS=$CPPFLAGS
   CPPFLAGS=-I$GD_INCLUDE
   cat > conftest.$ac_ext <<EOF
-#line 43282 "configure"
+#line 43218 "configure"
 #include "confdefs.h"
 
 #include <gd.h>
@@ -43292,7 +43228,7 @@ ctx->gd_free = 1;
   
 ; return 0; }
 EOF
-if { (eval echo configure:43296: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:43232: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
     cat >> confdefs.h <<\EOF
@@ -43622,7 +43558,7 @@ EOF
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 43626 "configure"
+#line 43562 "configure"
 #include "confdefs.h"
 
     char foobar () {}
@@ -43633,7 +43569,7 @@ else
     }
   
 EOF
-if { (eval echo configure:43637: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:43573: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     LIBS=$old_LIBS
@@ -43785,7 +43721,7 @@ fi
   done
 
   echo $ac_n "checking for gdImageCreate in -lgd""... $ac_c" 1>&6
-echo "configure:43789: checking for gdImageCreate in -lgd" >&5
+echo "configure:43725: checking for gdImageCreate in -lgd" >&5
 ac_lib_var=`echo gd'_'gdImageCreate | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -43793,7 +43729,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 43797 "configure"
+#line 43733 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -43804,7 +43740,7 @@ int main() {
 gdImageCreate()
 ; return 0; }
 EOF
-if { (eval echo configure:43808: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:43744: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -43869,7 +43805,7 @@ fi
 php_with_gettext=no
 
 echo $ac_n "checking for GNU gettext support""... $ac_c" 1>&6
-echo "configure:43873: checking for GNU gettext support" >&5
+echo "configure:43809: checking for GNU gettext support" >&5
 # Check whether --with-gettext or --without-gettext was given.
 if test "${with_gettext+set}" = set; then
   withval="$with_gettext"
@@ -43927,7 +43863,7 @@ if test "$PHP_GETTEXT" != "no"; then
   O_LDFLAGS=$LDFLAGS
   LDFLAGS="$LDFLAGS -L$GETTEXT_LIBDIR"
   echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:43931: checking for bindtextdomain in -lintl" >&5
+echo "configure:43867: checking for bindtextdomain in -lintl" >&5
 ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -43935,7 +43871,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lintl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 43939 "configure"
+#line 43875 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -43946,7 +43882,7 @@ int main() {
 bindtextdomain()
 ; return 0; }
 EOF
-if { (eval echo configure:43950: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:43886: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -43968,7 +43904,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
 echo $ac_n "checking for bindtextdomain in -lc""... $ac_c" 1>&6
-echo "configure:43972: checking for bindtextdomain in -lc" >&5
+echo "configure:43908: checking for bindtextdomain in -lc" >&5
 ac_lib_var=`echo c'_'bindtextdomain | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -43976,7 +43912,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lc  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 43980 "configure"
+#line 43916 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -43987,7 +43923,7 @@ int main() {
 bindtextdomain()
 ; return 0; }
 EOF
-if { (eval echo configure:43991: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:43927: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -44451,7 +44387,7 @@ EOF
 
 
   echo $ac_n "checking for ngettext in -l$GETTEXT_CHECK_IN_LIB""... $ac_c" 1>&6
-echo "configure:44455: checking for ngettext in -l$GETTEXT_CHECK_IN_LIB" >&5
+echo "configure:44391: checking for ngettext in -l$GETTEXT_CHECK_IN_LIB" >&5
 ac_lib_var=`echo $GETTEXT_CHECK_IN_LIB'_'ngettext | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -44459,7 +44395,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$GETTEXT_CHECK_IN_LIB  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 44463 "configure"
+#line 44399 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -44470,7 +44406,7 @@ int main() {
 ngettext()
 ; return 0; }
 EOF
-if { (eval echo configure:44474: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:44410: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -44494,7 +44430,7 @@ else
 fi
 
   echo $ac_n "checking for dngettext in -l$GETTEXT_CHECK_IN_LIB""... $ac_c" 1>&6
-echo "configure:44498: checking for dngettext in -l$GETTEXT_CHECK_IN_LIB" >&5
+echo "configure:44434: checking for dngettext in -l$GETTEXT_CHECK_IN_LIB" >&5
 ac_lib_var=`echo $GETTEXT_CHECK_IN_LIB'_'dngettext | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -44502,7 +44438,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$GETTEXT_CHECK_IN_LIB  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 44506 "configure"
+#line 44442 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -44513,7 +44449,7 @@ int main() {
 dngettext()
 ; return 0; }
 EOF
-if { (eval echo configure:44517: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:44453: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -44537,7 +44473,7 @@ else
 fi
 
   echo $ac_n "checking for dcngettext in -l$GETTEXT_CHECK_IN_LIB""... $ac_c" 1>&6
-echo "configure:44541: checking for dcngettext in -l$GETTEXT_CHECK_IN_LIB" >&5
+echo "configure:44477: checking for dcngettext in -l$GETTEXT_CHECK_IN_LIB" >&5
 ac_lib_var=`echo $GETTEXT_CHECK_IN_LIB'_'dcngettext | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -44545,7 +44481,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$GETTEXT_CHECK_IN_LIB  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 44549 "configure"
+#line 44485 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -44556,7 +44492,7 @@ int main() {
 dcngettext()
 ; return 0; }
 EOF
-if { (eval echo configure:44560: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:44496: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -44580,7 +44516,7 @@ else
 fi
 
   echo $ac_n "checking for bind_textdomain_codeset in -l$GETTEXT_CHECK_IN_LIB""... $ac_c" 1>&6
-echo "configure:44584: checking for bind_textdomain_codeset in -l$GETTEXT_CHECK_IN_LIB" >&5
+echo "configure:44520: checking for bind_textdomain_codeset in -l$GETTEXT_CHECK_IN_LIB" >&5
 ac_lib_var=`echo $GETTEXT_CHECK_IN_LIB'_'bind_textdomain_codeset | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -44588,7 +44524,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$GETTEXT_CHECK_IN_LIB  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 44592 "configure"
+#line 44528 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -44599,7 +44535,7 @@ int main() {
 bind_textdomain_codeset()
 ; return 0; }
 EOF
-if { (eval echo configure:44603: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:44539: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -44630,7 +44566,7 @@ fi
 php_with_gmp=no
 
 echo $ac_n "checking for GNU MP support""... $ac_c" 1>&6
-echo "configure:44634: checking for GNU MP support" >&5
+echo "configure:44570: checking for GNU MP support" >&5
 # Check whether --with-gmp or --without-gmp was given.
 if test "${with_gmp+set}" = set; then
   withval="$with_gmp"
@@ -44781,7 +44717,7 @@ if test "$PHP_GMP" != "no"; then
   done
 
   echo $ac_n "checking for __gmp_randinit_lc_2exp_size in -lgmp""... $ac_c" 1>&6
-echo "configure:44785: checking for __gmp_randinit_lc_2exp_size in -lgmp" >&5
+echo "configure:44721: checking for __gmp_randinit_lc_2exp_size in -lgmp" >&5
 ac_lib_var=`echo gmp'_'__gmp_randinit_lc_2exp_size | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -44789,7 +44725,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgmp  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 44793 "configure"
+#line 44729 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -44800,7 +44736,7 @@ int main() {
 __gmp_randinit_lc_2exp_size()
 ; return 0; }
 EOF
-if { (eval echo configure:44804: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:44740: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -44925,7 +44861,7 @@ else
   done
 
   echo $ac_n "checking for gmp_randinit_lc_2exp_size in -lgmp""... $ac_c" 1>&6
-echo "configure:44929: checking for gmp_randinit_lc_2exp_size in -lgmp" >&5
+echo "configure:44865: checking for gmp_randinit_lc_2exp_size in -lgmp" >&5
 ac_lib_var=`echo gmp'_'gmp_randinit_lc_2exp_size | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -44933,7 +44869,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgmp  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 44937 "configure"
+#line 44873 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -44944,7 +44880,7 @@ int main() {
 gmp_randinit_lc_2exp_size()
 ; return 0; }
 EOF
-if { (eval echo configure:44948: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:44884: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -45416,7 +45352,7 @@ fi
 php_enable_hash=yes
 
 echo $ac_n "checking whether to enable hash support""... $ac_c" 1>&6
-echo "configure:45420: checking whether to enable hash support" >&5
+echo "configure:45356: checking whether to enable hash support" >&5
 # Check whether --enable-hash or --disable-hash was given.
 if test "${enable_hash+set}" = set; then
   enableval="$enable_hash"
@@ -45466,7 +45402,7 @@ EOF
 
 
   echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
-echo "configure:45470: checking whether byte ordering is bigendian" >&5
+echo "configure:45406: checking whether byte ordering is bigendian" >&5
 if eval "test \"`echo '$''{'ac_cv_c_bigendian_php'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -45476,7 +45412,7 @@ else
   ac_cv_c_bigendian_php=unknown
 else
   cat > conftest.$ac_ext <<EOF
-#line 45480 "configure"
+#line 45416 "configure"
 #include "confdefs.h"
 
 int main(void)
@@ -45492,7 +45428,7 @@ int main(void)
 }
   
 EOF
-if { (eval echo configure:45496: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:45432: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_c_bigendian_php=yes
 else
@@ -45517,7 +45453,7 @@ EOF
 
 
   echo $ac_n "checking size of short""... $ac_c" 1>&6
-echo "configure:45521: checking size of short" >&5
+echo "configure:45457: checking size of short" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -45525,7 +45461,7 @@ else
   ac_cv_sizeof_short=2
 else
   cat > conftest.$ac_ext <<EOF
-#line 45529 "configure"
+#line 45465 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -45536,7 +45472,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:45540: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:45476: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_short=`cat conftestval`
 else
@@ -45556,7 +45492,7 @@ EOF
 
 
   echo $ac_n "checking size of int""... $ac_c" 1>&6
-echo "configure:45560: checking size of int" >&5
+echo "configure:45496: checking size of int" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -45564,7 +45500,7 @@ else
   ac_cv_sizeof_int=4
 else
   cat > conftest.$ac_ext <<EOF
-#line 45568 "configure"
+#line 45504 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -45575,7 +45511,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:45579: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:45515: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_int=`cat conftestval`
 else
@@ -45595,7 +45531,7 @@ EOF
 
 
   echo $ac_n "checking size of long""... $ac_c" 1>&6
-echo "configure:45599: checking size of long" >&5
+echo "configure:45535: checking size of long" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -45603,7 +45539,7 @@ else
   ac_cv_sizeof_long=4
 else
   cat > conftest.$ac_ext <<EOF
-#line 45607 "configure"
+#line 45543 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -45614,7 +45550,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:45618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:45554: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long=`cat conftestval`
 else
@@ -45634,7 +45570,7 @@ EOF
 
 
   echo $ac_n "checking size of long long""... $ac_c" 1>&6
-echo "configure:45638: checking size of long long" >&5
+echo "configure:45574: checking size of long long" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -45642,7 +45578,7 @@ else
   ac_cv_sizeof_long_long=8
 else
   cat > conftest.$ac_ext <<EOF
-#line 45646 "configure"
+#line 45582 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -45653,7 +45589,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:45657: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:45593: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long_long=`cat conftestval`
 else
@@ -46001,7 +45937,7 @@ fi
 php_with_iconv=yes
 
 echo $ac_n "checking for iconv support""... $ac_c" 1>&6
-echo "configure:46005: checking for iconv support" >&5
+echo "configure:45941: checking for iconv support" >&5
 # Check whether --with-iconv or --without-iconv was given.
 if test "${with_iconv+set}" = set; then
   withval="$with_iconv"
@@ -46064,12 +46000,12 @@ if test "$PHP_ICONV" != "no"; then
 
         if test "$PHP_ICONV" = "yes"; then
     echo $ac_n "checking for iconv""... $ac_c" 1>&6
-echo "configure:46068: checking for iconv" >&5
+echo "configure:46004: checking for iconv" >&5
 if eval "test \"`echo '$''{'ac_cv_func_iconv'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 46073 "configure"
+#line 46009 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char iconv(); below.  */
@@ -46092,7 +46028,7 @@ iconv();
 
 ; return 0; }
 EOF
-if { (eval echo configure:46096: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:46032: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_iconv=yes"
 else
@@ -46113,12 +46049,12 @@ else
   echo "$ac_t""no" 1>&6
 
       echo $ac_n "checking for libiconv""... $ac_c" 1>&6
-echo "configure:46117: checking for libiconv" >&5
+echo "configure:46053: checking for libiconv" >&5
 if eval "test \"`echo '$''{'ac_cv_func_libiconv'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 46122 "configure"
+#line 46058 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char libiconv(); below.  */
@@ -46141,7 +46077,7 @@ libiconv();
 
 ; return 0; }
 EOF
-if { (eval echo configure:46145: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:46081: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_libiconv=yes"
 else
@@ -46297,7 +46233,7 @@ EOF
   done
 
   echo $ac_n "checking for libiconv in -l$iconv_lib_name""... $ac_c" 1>&6
-echo "configure:46301: checking for libiconv in -l$iconv_lib_name" >&5
+echo "configure:46237: checking for libiconv in -l$iconv_lib_name" >&5
 ac_lib_var=`echo $iconv_lib_name'_'libiconv | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -46305,7 +46241,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$iconv_lib_name  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 46309 "configure"
+#line 46245 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -46316,7 +46252,7 @@ int main() {
 libiconv()
 ; return 0; }
 EOF
-if { (eval echo configure:46320: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:46256: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -46450,7 +46386,7 @@ else
   done
 
   echo $ac_n "checking for iconv in -l$iconv_lib_name""... $ac_c" 1>&6
-echo "configure:46454: checking for iconv in -l$iconv_lib_name" >&5
+echo "configure:46390: checking for iconv in -l$iconv_lib_name" >&5
 ac_lib_var=`echo $iconv_lib_name'_'iconv | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -46458,7 +46394,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$iconv_lib_name  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 46462 "configure"
+#line 46398 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -46469,7 +46405,7 @@ int main() {
 iconv()
 ; return 0; }
 EOF
-if { (eval echo configure:46473: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:46409: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -46680,16 +46616,16 @@ else
     fi 
 
     echo $ac_n "checking if iconv is glibc's""... $ac_c" 1>&6
-echo "configure:46684: checking if iconv is glibc's" >&5
+echo "configure:46620: checking if iconv is glibc's" >&5
     cat > conftest.$ac_ext <<EOF
-#line 46686 "configure"
+#line 46622 "configure"
 #include "confdefs.h"
 #include <gnu/libc-version.h>
 int main() {
 gnu_get_libc_version();
 ; return 0; }
 EOF
-if { (eval echo configure:46693: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:46629: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   
       echo "$ac_t""yes" 1>&6
@@ -46707,7 +46643,7 @@ rm -f conftest*
 
     if test -z "$iconv_impl_name"; then
       echo $ac_n "checking if using GNU libiconv""... $ac_c" 1>&6
-echo "configure:46711: checking if using GNU libiconv" >&5
+echo "configure:46647: checking if using GNU libiconv" >&5
       php_iconv_old_ld="$LDFLAGS"
       LDFLAGS="-liconv $LDFLAGS"
       if test "$cross_compiling" = yes; then
@@ -46717,7 +46653,7 @@ echo "configure:46711: checking if using GNU libiconv" >&5
       
 else
   cat > conftest.$ac_ext <<EOF
-#line 46721 "configure"
+#line 46657 "configure"
 #include "confdefs.h"
 
 #include <$PHP_ICONV_H_PATH>
@@ -46727,7 +46663,7 @@ int main() {
 }
       
 EOF
-if { (eval echo configure:46731: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:46667: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
         echo "$ac_t""yes" 1>&6
@@ -46749,16 +46685,16 @@ fi
 
     if test -z "$iconv_impl_name"; then
       echo $ac_n "checking if iconv is Konstantin Chuguev's""... $ac_c" 1>&6
-echo "configure:46753: checking if iconv is Konstantin Chuguev's" >&5
+echo "configure:46689: checking if iconv is Konstantin Chuguev's" >&5
       cat > conftest.$ac_ext <<EOF
-#line 46755 "configure"
+#line 46691 "configure"
 #include "confdefs.h"
 #include <iconv.h>
 int main() {
 iconv_ccs_init(NULL, NULL);
 ; return 0; }
 EOF
-if { (eval echo configure:46762: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:46698: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   
         echo "$ac_t""yes" 1>&6
@@ -46926,7 +46862,7 @@ EOF
     esac
 
     echo $ac_n "checking if iconv supports errno""... $ac_c" 1>&6
-echo "configure:46930: checking if iconv supports errno" >&5
+echo "configure:46866: checking if iconv supports errno" >&5
     if test "$cross_compiling" = yes; then
   
       echo "$ac_t""no" 1>&6
@@ -46940,7 +46876,7 @@ EOF
     
 else
   cat > conftest.$ac_ext <<EOF
-#line 46944 "configure"
+#line 46880 "configure"
 #include "confdefs.h"
 
 #include <$PHP_ICONV_H_PATH>
@@ -46961,7 +46897,7 @@ int main() {
 }
     
 EOF
-if { (eval echo configure:46965: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:46901: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
       echo "$ac_t""yes" 1>&6
@@ -46993,9 +46929,9 @@ fi
 
 
     echo $ac_n "checking if your cpp allows macro usage in include lines""... $ac_c" 1>&6
-echo "configure:46997: checking if your cpp allows macro usage in include lines" >&5
+echo "configure:46933: checking if your cpp allows macro usage in include lines" >&5
     cat > conftest.$ac_ext <<EOF
-#line 46999 "configure"
+#line 46935 "configure"
 #include "confdefs.h"
 
 #define FOO <$PHP_ICONV_H_PATH>
@@ -47005,7 +46941,7 @@ int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:47009: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:46945: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
       echo "$ac_t""yes" 1>&6
@@ -47361,7 +47297,7 @@ fi
 php_with_imap=no
 
 echo $ac_n "checking for IMAP support""... $ac_c" 1>&6
-echo "configure:47365: checking for IMAP support" >&5
+echo "configure:47301: checking for IMAP support" >&5
 # Check whether --with-imap or --without-imap was given.
 if test "${with_imap+set}" = set; then
   withval="$with_imap"
@@ -47408,7 +47344,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_kerberos=no
 
 echo $ac_n "checking for IMAP Kerberos support""... $ac_c" 1>&6
-echo "configure:47412: checking for IMAP Kerberos support" >&5
+echo "configure:47348: checking for IMAP Kerberos support" >&5
 # Check whether --with-kerberos or --without-kerberos was given.
 if test "${with_kerberos+set}" = set; then
   withval="$with_kerberos"
@@ -47434,7 +47370,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_imap_ssl=no
 
 echo $ac_n "checking for IMAP SSL support""... $ac_c" 1>&6
-echo "configure:47438: checking for IMAP SSL support" >&5
+echo "configure:47374: checking for IMAP SSL support" >&5
 # Check whether --with-imap-ssl or --without-imap-ssl was given.
 if test "${with_imap_ssl+set}" = set; then
   withval="$with_imap_ssl"
@@ -47841,7 +47777,7 @@ EOF
     done
 
         cat > conftest.$ac_ext <<EOF
-#line 47845 "configure"
+#line 47781 "configure"
 #include "confdefs.h"
 #include <$IMAP_INC_DIR/mail.h>
 EOF
@@ -47861,12 +47797,12 @@ rm -f conftest*
         old_CFLAGS=$CFLAGS
     CFLAGS="-I$IMAP_INC_DIR"
     echo $ac_n "checking for utf8_mime2text signature""... $ac_c" 1>&6
-echo "configure:47865: checking for utf8_mime2text signature" >&5
+echo "configure:47801: checking for utf8_mime2text signature" >&5
 if eval "test \"`echo '$''{'ac_cv_utf8_mime2text'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 47870 "configure"
+#line 47806 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -47879,7 +47815,7 @@ int main() {
       
 ; return 0; }
 EOF
-if { (eval echo configure:47883: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:47819: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
         ac_cv_utf8_mime2text=old
@@ -47908,12 +47844,12 @@ EOF
     old_CFLAGS=$CFLAGS
     CFLAGS="-I$IMAP_INC_DIR"
     echo $ac_n "checking for U8T_CANONICAL""... $ac_c" 1>&6
-echo "configure:47912: checking for U8T_CANONICAL" >&5
+echo "configure:47848: checking for U8T_CANONICAL" >&5
 if eval "test \"`echo '$''{'ac_cv_u8t_canonical'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 47917 "configure"
+#line 47853 "configure"
 #include "confdefs.h"
 
 #include <c-client.h>
@@ -47924,7 +47860,7 @@ int main() {
       
 ; return 0; }
 EOF
-if { (eval echo configure:47928: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:47864: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
          ac_cv_u8t_canonical=yes
@@ -47954,7 +47890,7 @@ echo "$ac_t""$ac_cv_u8t_canonical" 1>&6
         old_CPPFLAGS=$CPPFLAGS
     CPPFLAGS=-I$IMAP_INC_DIR
     cat > conftest.$ac_ext <<EOF
-#line 47958 "configure"
+#line 47894 "configure"
 #include "confdefs.h"
 
 #include "imap4r1.h"
@@ -48073,7 +48009,7 @@ rm -f conftest*
   done
 
   echo $ac_n "checking for pam_start in -lpam""... $ac_c" 1>&6
-echo "configure:48077: checking for pam_start in -lpam" >&5
+echo "configure:48013: checking for pam_start in -lpam" >&5
 ac_lib_var=`echo pam'_'pam_start | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -48081,7 +48017,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpam  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 48085 "configure"
+#line 48021 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -48092,7 +48028,7 @@ int main() {
 pam_start()
 ; return 0; }
 EOF
-if { (eval echo configure:48096: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:48032: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -48247,7 +48183,7 @@ fi
   done
 
   echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6
-echo "configure:48251: checking for crypt in -lcrypt" >&5
+echo "configure:48187: checking for crypt in -lcrypt" >&5
 ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -48255,7 +48191,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lcrypt  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 48259 "configure"
+#line 48195 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -48266,7 +48202,7 @@ int main() {
 crypt()
 ; return 0; }
 EOF
-if { (eval echo configure:48270: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:48206: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -48470,7 +48406,7 @@ fi
     # Extract the first word of "krb5-config", so it can be a program name with args.
 set dummy krb5-config; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:48474: checking for $ac_word" >&5
+echo "configure:48410: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_KRB5_CONFIG'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -48839,7 +48775,7 @@ else
 
   else
     cat > conftest.$ac_ext <<EOF
-#line 48843 "configure"
+#line 48779 "configure"
 #include "confdefs.h"
 #include <$IMAP_INC_DIR/linkage.h>
 EOF
@@ -48880,7 +48816,7 @@ rm -f conftest*
     # Extract the first word of "pkg-config", so it can be a program name with args.
 set dummy pkg-config; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:48884: checking for $ac_word" >&5
+echo "configure:48820: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_PKG_CONFIG'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -49085,9 +49021,9 @@ fi
     old_CPPFLAGS=$CPPFLAGS
     CPPFLAGS=-I$OPENSSL_INCDIR
     echo $ac_n "checking for OpenSSL version""... $ac_c" 1>&6
-echo "configure:49089: checking for OpenSSL version" >&5
+echo "configure:49025: checking for OpenSSL version" >&5
     cat > conftest.$ac_ext <<EOF
-#line 49091 "configure"
+#line 49027 "configure"
 #include "confdefs.h"
 
 #include <openssl/opensslv.h>
@@ -49242,7 +49178,7 @@ rm -f conftest*
   done
 
   echo $ac_n "checking for CRYPTO_free in -lcrypto""... $ac_c" 1>&6
-echo "configure:49246: checking for CRYPTO_free in -lcrypto" >&5
+echo "configure:49182: checking for CRYPTO_free in -lcrypto" >&5
 ac_lib_var=`echo crypto'_'CRYPTO_free | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -49250,7 +49186,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lcrypto  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 49254 "configure"
+#line 49190 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -49261,7 +49197,7 @@ int main() {
 CRYPTO_free()
 ; return 0; }
 EOF
-if { (eval echo configure:49265: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:49201: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -49418,7 +49354,7 @@ fi
   done
 
   echo $ac_n "checking for SSL_CTX_set_ssl_version in -lssl""... $ac_c" 1>&6
-echo "configure:49422: checking for SSL_CTX_set_ssl_version in -lssl" >&5
+echo "configure:49358: checking for SSL_CTX_set_ssl_version in -lssl" >&5
 ac_lib_var=`echo ssl'_'SSL_CTX_set_ssl_version | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -49426,7 +49362,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lssl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 49430 "configure"
+#line 49366 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -49437,7 +49373,7 @@ int main() {
 SSL_CTX_set_ssl_version()
 ; return 0; }
 EOF
-if { (eval echo configure:49441: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:49377: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -49556,7 +49492,7 @@ else
 
   elif test -f "$IMAP_INC_DIR/linkage.c"; then
     cat > conftest.$ac_ext <<EOF
-#line 49560 "configure"
+#line 49496 "configure"
 #include "confdefs.h"
 #include <$IMAP_INC_DIR/linkage.c>
 EOF
@@ -49587,7 +49523,7 @@ rm -f conftest*
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 49591 "configure"
+#line 49527 "configure"
 #include "confdefs.h"
 
     
@@ -49614,7 +49550,7 @@ else
     }
   
 EOF
-if { (eval echo configure:49618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:49554: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     LIBS=$old_LIBS
@@ -49641,7 +49577,7 @@ fi
 
 
     echo $ac_n "checking whether build with IMAP works""... $ac_c" 1>&6
-echo "configure:49645: checking whether build with IMAP works" >&5
+echo "configure:49581: checking whether build with IMAP works" >&5
     
   
   old_LIBS=$LIBS
@@ -49652,7 +49588,7 @@ echo "configure:49645: checking whether build with IMAP works" >&5
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 49656 "configure"
+#line 49592 "configure"
 #include "confdefs.h"
 
     
@@ -49679,7 +49615,7 @@ else
     }
   
 EOF
-if { (eval echo configure:49683: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:49619: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     LIBS=$old_LIBS
@@ -49706,7 +49642,7 @@ fi
 
 
     echo $ac_n "checking whether rfc822_output_address_list function present""... $ac_c" 1>&6
-echo "configure:49710: checking whether rfc822_output_address_list function present" >&5
+echo "configure:49646: checking whether rfc822_output_address_list function present" >&5
     
   old_LIBS=$LIBS
   LIBS="
@@ -49718,7 +49654,7 @@ echo "configure:49710: checking whether rfc822_output_address_list function pres
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 49722 "configure"
+#line 49658 "configure"
 #include "confdefs.h"
 
     
@@ -49748,7 +49684,7 @@ else
     }
   
 EOF
-if { (eval echo configure:49752: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:49688: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     LIBS=$old_LIBS
@@ -49783,7 +49719,7 @@ fi
 php_with_interbase=no
 
 echo $ac_n "checking for InterBase support""... $ac_c" 1>&6
-echo "configure:49787: checking for InterBase support" >&5
+echo "configure:49723: checking for InterBase support" >&5
 # Check whether --with-interbase or --without-interbase was given.
 if test "${with_interbase+set}" = set; then
   withval="$with_interbase"
@@ -49933,7 +49869,7 @@ if test "$PHP_INTERBASE" != "no"; then
   done
 
   echo $ac_n "checking for isc_detach_database in -lfbclient""... $ac_c" 1>&6
-echo "configure:49937: checking for isc_detach_database in -lfbclient" >&5
+echo "configure:49873: checking for isc_detach_database in -lfbclient" >&5
 ac_lib_var=`echo fbclient'_'isc_detach_database | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -49941,7 +49877,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lfbclient  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 49945 "configure"
+#line 49881 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -49952,7 +49888,7 @@ int main() {
 isc_detach_database()
 ; return 0; }
 EOF
-if { (eval echo configure:49956: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:49892: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -50079,7 +50015,7 @@ else
   done
 
   echo $ac_n "checking for isc_detach_database in -lgds""... $ac_c" 1>&6
-echo "configure:50083: checking for isc_detach_database in -lgds" >&5
+echo "configure:50019: checking for isc_detach_database in -lgds" >&5
 ac_lib_var=`echo gds'_'isc_detach_database | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -50087,7 +50023,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgds  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 50091 "configure"
+#line 50027 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -50098,7 +50034,7 @@ int main() {
 isc_detach_database()
 ; return 0; }
 EOF
-if { (eval echo configure:50102: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:50038: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -50225,7 +50161,7 @@ else
   done
 
   echo $ac_n "checking for isc_detach_database in -lib_util""... $ac_c" 1>&6
-echo "configure:50229: checking for isc_detach_database in -lib_util" >&5
+echo "configure:50165: checking for isc_detach_database in -lib_util" >&5
 ac_lib_var=`echo ib_util'_'isc_detach_database | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -50233,7 +50169,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lib_util  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 50237 "configure"
+#line 50173 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -50244,7 +50180,7 @@ int main() {
 isc_detach_database()
 ; return 0; }
 EOF
-if { (eval echo configure:50248: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:50184: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -50721,7 +50657,7 @@ fi
 php_enable_json=yes
 
 echo $ac_n "checking whether to enable JavaScript Object Serialization support""... $ac_c" 1>&6
-echo "configure:50725: checking whether to enable JavaScript Object Serialization support" >&5
+echo "configure:50661: checking whether to enable JavaScript Object Serialization support" >&5
 # Check whether --enable-json or --disable-json was given.
 if test "${enable_json+set}" = set; then
   enableval="$enable_json"
@@ -50770,12 +50706,12 @@ if test "$PHP_JSON" != "no"; then
 EOF
 
   echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:50774: checking for ANSI C header files" >&5
+echo "configure:50710: checking for ANSI C header files" >&5
 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 50779 "configure"
+#line 50715 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 #include <stdarg.h>
@@ -50783,7 +50719,7 @@ else
 #include <float.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:50787: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:50723: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -50800,7 +50736,7 @@ rm -f conftest*
 if test $ac_cv_header_stdc = yes; then
   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 50804 "configure"
+#line 50740 "configure"
 #include "confdefs.h"
 #include <string.h>
 EOF
@@ -50818,7 +50754,7 @@ fi
 if test $ac_cv_header_stdc = yes; then
   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 50822 "configure"
+#line 50758 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 EOF
@@ -50839,7 +50775,7 @@ if test "$cross_compiling" = yes; then
   :
 else
   cat > conftest.$ac_ext <<EOF
-#line 50843 "configure"
+#line 50779 "configure"
 #include "confdefs.h"
 #include <ctype.h>
 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -50850,7 +50786,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
 exit (0); }
 
 EOF
-if { (eval echo configure:50854: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:50790: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   :
 else
@@ -51180,7 +51116,7 @@ fi
 php_with_ldap=no
 
 echo $ac_n "checking for LDAP support""... $ac_c" 1>&6
-echo "configure:51184: checking for LDAP support" >&5
+echo "configure:51120: checking for LDAP support" >&5
 # Check whether --with-ldap or --without-ldap was given.
 if test "${with_ldap+set}" = set; then
   withval="$with_ldap"
@@ -51227,7 +51163,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_ldap_sasl=no
 
 echo $ac_n "checking for LDAP Cyrus SASL support""... $ac_c" 1>&6
-echo "configure:51231: checking for LDAP Cyrus SASL support" >&5
+echo "configure:51167: checking for LDAP Cyrus SASL support" >&5
 # Check whether --with-ldap-sasl or --without-ldap-sasl was given.
 if test "${with_ldap_sasl+set}" = set; then
   withval="$with_ldap_sasl"
@@ -53572,19 +53508,19 @@ EOF
   LIBS="$LIBS $LDAP_SHARED_LIBADD"
 
     echo $ac_n "checking for 3 arg ldap_set_rebind_proc""... $ac_c" 1>&6
-echo "configure:53576: checking for 3 arg ldap_set_rebind_proc" >&5
+echo "configure:53512: checking for 3 arg ldap_set_rebind_proc" >&5
 if eval "test \"`echo '$''{'ac_cv_3arg_setrebindproc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 53581 "configure"
+#line 53517 "configure"
 #include "confdefs.h"
 #include <ldap.h>
 int main() {
 ldap_set_rebind_proc(0,0,0)
 ; return 0; }
 EOF
-if { (eval echo configure:53588: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:53524: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_3arg_setrebindproc=yes
 else
@@ -53607,12 +53543,12 @@ EOF
       for ac_func in ldap_parse_result ldap_parse_reference ldap_start_tls_s
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:53611: checking for $ac_func" >&5
+echo "configure:53547: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 53616 "configure"
+#line 53552 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -53635,7 +53571,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:53639: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:53575: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -53797,7 +53733,7 @@ EOF
   done
 
   echo $ac_n "checking for sasl_version in -lldap""... $ac_c" 1>&6
-echo "configure:53801: checking for sasl_version in -lldap" >&5
+echo "configure:53737: checking for sasl_version in -lldap" >&5
 ac_lib_var=`echo ldap'_'sasl_version | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -53805,7 +53741,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lldap  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 53809 "configure"
+#line 53745 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -53816,7 +53752,7 @@ int main() {
 sasl_version()
 ; return 0; }
 EOF
-if { (eval echo configure:53820: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:53756: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -53985,12 +53921,12 @@ fi
   fi
 
         echo $ac_n "checking for ldap_bind_s""... $ac_c" 1>&6
-echo "configure:53989: checking for ldap_bind_s" >&5
+echo "configure:53925: checking for ldap_bind_s" >&5
 if eval "test \"`echo '$''{'ac_cv_func_ldap_bind_s'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 53994 "configure"
+#line 53930 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char ldap_bind_s(); below.  */
@@ -54013,7 +53949,7 @@ ldap_bind_s();
 
 ; return 0; }
 EOF
-if { (eval echo configure:54017: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:53953: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_ldap_bind_s=yes"
 else
@@ -54064,7 +54000,7 @@ fi
 php_enable_mbstring=no
 
 echo $ac_n "checking whether to enable multibyte string support""... $ac_c" 1>&6
-echo "configure:54068: checking whether to enable multibyte string support" >&5
+echo "configure:54004: checking whether to enable multibyte string support" >&5
 # Check whether --enable-mbstring or --disable-mbstring was given.
 if test "${enable_mbstring+set}" = set; then
   enableval="$enable_mbstring"
@@ -54111,7 +54047,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_enable_mbregex=yes
 
 echo $ac_n "checking whether to enable multibyte regex support""... $ac_c" 1>&6
-echo "configure:54115: checking whether to enable multibyte regex support" >&5
+echo "configure:54051: checking whether to enable multibyte regex support" >&5
 # Check whether --enable-mbregex or --disable-mbregex was given.
 if test "${enable_mbregex+set}" = set; then
   enableval="$enable_mbregex"
@@ -54137,7 +54073,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_enable_mbregex_backtrack=yes
 
 echo $ac_n "checking whether to check multibyte regex backtrack""... $ac_c" 1>&6
-echo "configure:54141: checking whether to check multibyte regex backtrack" >&5
+echo "configure:54077: checking whether to check multibyte regex backtrack" >&5
 # Check whether --enable-mbregex_backtrack or --disable-mbregex_backtrack was given.
 if test "${enable_mbregex_backtrack+set}" = set; then
   enableval="$enable_mbregex_backtrack"
@@ -54163,7 +54099,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_libmbfl=no
 
 echo $ac_n "checking for external libmbfl""... $ac_c" 1>&6
-echo "configure:54167: checking for external libmbfl" >&5
+echo "configure:54103: checking for external libmbfl" >&5
 # Check whether --with-libmbfl or --without-libmbfl was given.
 if test "${with_libmbfl+set}" = set; then
   withval="$with_libmbfl"
@@ -54199,8 +54135,8 @@ EOF
     
   if test "$PHP_MBREGEX" = "yes"; then
     echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6
-echo "configure:54203: checking for variable length prototypes and stdarg.h" >&5
-if eval "test \"`echo '$''{'cv_php_mbstring_stdarg'+set}'`\" = set"; then
+echo "configure:54139: checking for variable length prototypes and stdarg.h" >&5
+if eval "test \"`echo '$''{'php_cv_mbstring_stdarg'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
@@ -54208,16 +54144,16 @@ else
   
                 case $host_alias in
         *netware*)
-          cv_php_mbstring_stdarg=yes
+          php_cv_mbstring_stdarg=yes
           ;;
         *)
-          cv_php_mbstring_stdarg=no
+          php_cv_mbstring_stdarg=no
           ;;
         esac
       
 else
   cat > conftest.$ac_ext <<EOF
-#line 54221 "configure"
+#line 54157 "configure"
 #include "confdefs.h"
 
 #include <stdarg.h>
@@ -54232,14 +54168,14 @@ int foo(int x, ...) {
 int main() { return foo(10, "", 3.14); }
       
 EOF
-if { (eval echo configure:54236: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:54172: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
-  cv_php_mbstring_stdarg=yes
+  php_cv_mbstring_stdarg=yes
 else
   echo "configure: failed program was:" >&5
   cat conftest.$ac_ext >&5
   rm -fr conftest*
-  cv_php_mbstring_stdarg=no
+  php_cv_mbstring_stdarg=no
 fi
 rm -fr conftest*
 fi
@@ -54247,23 +54183,23 @@ fi
     
 fi
 
-echo "$ac_t""$cv_php_mbstring_stdarg" 1>&6
+echo "$ac_t""$php_cv_mbstring_stdarg" 1>&6
 
     for ac_hdr in stdlib.h string.h strings.h unistd.h sys/time.h sys/times.h stdarg.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:54257: checking for $ac_hdr" >&5
+echo "configure:54193: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 54262 "configure"
+#line 54198 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:54267: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:54203: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -54290,7 +54226,7 @@ fi
 done
 
     echo $ac_n "checking size of int""... $ac_c" 1>&6
-echo "configure:54294: checking size of int" >&5
+echo "configure:54230: checking size of int" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -54298,7 +54234,7 @@ else
   ac_cv_sizeof_int=4
 else
   cat > conftest.$ac_ext <<EOF
-#line 54302 "configure"
+#line 54238 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -54309,7 +54245,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:54313: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:54249: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_int=`cat conftestval`
 else
@@ -54329,7 +54265,7 @@ EOF
 
 
     echo $ac_n "checking size of short""... $ac_c" 1>&6
-echo "configure:54333: checking size of short" >&5
+echo "configure:54269: checking size of short" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -54337,7 +54273,7 @@ else
   ac_cv_sizeof_short=2
 else
   cat > conftest.$ac_ext <<EOF
-#line 54341 "configure"
+#line 54277 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -54348,7 +54284,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:54352: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:54288: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_short=`cat conftestval`
 else
@@ -54368,7 +54304,7 @@ EOF
 
 
     echo $ac_n "checking size of long""... $ac_c" 1>&6
-echo "configure:54372: checking size of long" >&5
+echo "configure:54308: checking size of long" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -54376,7 +54312,7 @@ else
   ac_cv_sizeof_long=4
 else
   cat > conftest.$ac_ext <<EOF
-#line 54380 "configure"
+#line 54316 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -54387,7 +54323,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:54391: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:54327: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long=`cat conftestval`
 else
@@ -54407,12 +54343,12 @@ EOF
 
 
     echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:54411: checking for working const" >&5
+echo "configure:54347: checking for working const" >&5
 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 54416 "configure"
+#line 54352 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -54461,7 +54397,7 @@ ccp = (char const *const *) p;
 
 ; return 0; }
 EOF
-if { (eval echo configure:54465: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:54401: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_const=yes
 else
@@ -54482,12 +54418,12 @@ EOF
 fi
 
     echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
-echo "configure:54486: checking whether time.h and sys/time.h may both be included" >&5
+echo "configure:54422: checking whether time.h and sys/time.h may both be included" >&5
 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 54491 "configure"
+#line 54427 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/time.h>
@@ -54496,7 +54432,7 @@ int main() {
 struct tm *tp;
 ; return 0; }
 EOF
-if { (eval echo configure:54500: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:54436: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_header_time=yes
 else
@@ -54519,19 +54455,19 @@ fi
     # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
 # for constant arguments.  Useless!
 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:54523: checking for working alloca.h" >&5
+echo "configure:54459: checking for working alloca.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 54528 "configure"
+#line 54464 "configure"
 #include "confdefs.h"
 #include <alloca.h>
 int main() {
 char *p = alloca(2 * sizeof(int));
 ; return 0; }
 EOF
-if { (eval echo configure:54535: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:54471: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_cv_header_alloca_h=yes
 else
@@ -54552,12 +54488,12 @@ EOF
 fi
 
 echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:54556: checking for alloca" >&5
+echo "configure:54492: checking for alloca" >&5
 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 54561 "configure"
+#line 54497 "configure"
 #include "confdefs.h"
 
 #ifdef __GNUC__
@@ -54585,7 +54521,7 @@ int main() {
 char *p = (char *) alloca(1);
 ; return 0; }
 EOF
-if { (eval echo configure:54589: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:54525: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_cv_func_alloca_works=yes
 else
@@ -54617,12 +54553,12 @@ EOF
 
 
 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:54621: checking whether alloca needs Cray hooks" >&5
+echo "configure:54557: checking whether alloca needs Cray hooks" >&5
 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 54626 "configure"
+#line 54562 "configure"
 #include "confdefs.h"
 #if defined(CRAY) && ! defined(CRAY2)
 webecray
@@ -54647,12 +54583,12 @@ echo "$ac_t""$ac_cv_os_cray" 1>&6
 if test $ac_cv_os_cray = yes; then
 for ac_func in _getb67 GETB67 getb67; do
   echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:54651: checking for $ac_func" >&5
+echo "configure:54587: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 54656 "configure"
+#line 54592 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -54675,7 +54611,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:54679: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:54615: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -54702,7 +54638,7 @@ done
 fi
 
 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:54706: checking stack direction for C alloca" >&5
+echo "configure:54642: checking stack direction for C alloca" >&5
 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -54710,7 +54646,7 @@ else
   ac_cv_c_stack_direction=0
 else
   cat > conftest.$ac_ext <<EOF
-#line 54714 "configure"
+#line 54650 "configure"
 #include "confdefs.h"
 find_stack_direction ()
 {
@@ -54729,7 +54665,7 @@ main ()
   exit (find_stack_direction() < 0);
 }
 EOF
-if { (eval echo configure:54733: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:54669: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_c_stack_direction=1
 else
@@ -54751,7 +54687,7 @@ EOF
 fi
 
     echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6
-echo "configure:54755: checking for 8-bit clean memcmp" >&5
+echo "configure:54691: checking for 8-bit clean memcmp" >&5
 if eval "test \"`echo '$''{'ac_cv_func_memcmp_clean'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -54759,7 +54695,7 @@ else
   ac_cv_func_memcmp_clean=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 54763 "configure"
+#line 54699 "configure"
 #include "confdefs.h"
 
 main()
@@ -54769,7 +54705,7 @@ main()
 }
 
 EOF
-if { (eval echo configure:54773: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:54709: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_memcmp_clean=yes
 else
@@ -55112,7 +55048,7 @@ EOF
   done
 
   echo $ac_n "checking for mbfl_buffer_converter_new in -lmbfl""... $ac_c" 1>&6
-echo "configure:55116: checking for mbfl_buffer_converter_new in -lmbfl" >&5
+echo "configure:55052: checking for mbfl_buffer_converter_new in -lmbfl" >&5
 ac_lib_var=`echo mbfl'_'mbfl_buffer_converter_new | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -55120,7 +55056,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lmbfl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 55124 "configure"
+#line 55060 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -55131,7 +55067,7 @@ int main() {
 mbfl_buffer_converter_new()
 ; return 0; }
 EOF
-if { (eval echo configure:55135: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:55071: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -55765,7 +55701,7 @@ fi
 php_with_mcrypt=no
 
 echo $ac_n "checking for mcrypt support""... $ac_c" 1>&6
-echo "configure:55769: checking for mcrypt support" >&5
+echo "configure:55705: checking for mcrypt support" >&5
 # Check whether --with-mcrypt or --without-mcrypt was given.
 if test "${with_mcrypt+set}" = set; then
   withval="$with_mcrypt"
@@ -55821,9 +55757,9 @@ if test "$PHP_MCRYPT" != "no"; then
   old_CPPFLAGS=$CPPFLAGS
   CPPFLAGS=-I$MCRYPT_DIR/include
   echo $ac_n "checking for libmcrypt version""... $ac_c" 1>&6
-echo "configure:55825: checking for libmcrypt version" >&5
+echo "configure:55761: checking for libmcrypt version" >&5
   cat > conftest.$ac_ext <<EOF
-#line 55827 "configure"
+#line 55763 "configure"
 #include "confdefs.h"
 
 #include <mcrypt.h>
@@ -55947,7 +55883,7 @@ rm -f conftest*
   done
 
   echo $ac_n "checking for mcrypt_module_open in -lmcrypt""... $ac_c" 1>&6
-echo "configure:55951: checking for mcrypt_module_open in -lmcrypt" >&5
+echo "configure:55887: checking for mcrypt_module_open in -lmcrypt" >&5
 ac_lib_var=`echo mcrypt'_'mcrypt_module_open | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -55955,7 +55891,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lmcrypt  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 55959 "configure"
+#line 55895 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -55966,7 +55902,7 @@ int main() {
 mcrypt_module_open()
 ; return 0; }
 EOF
-if { (eval echo configure:55970: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:55906: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -56119,7 +56055,7 @@ else
   done
 
   echo $ac_n "checking for mcrypt_module_open in -lmcrypt""... $ac_c" 1>&6
-echo "configure:56123: checking for mcrypt_module_open in -lmcrypt" >&5
+echo "configure:56059: checking for mcrypt_module_open in -lmcrypt" >&5
 ac_lib_var=`echo mcrypt'_'mcrypt_module_open | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -56127,7 +56063,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lmcrypt  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 56131 "configure"
+#line 56067 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -56138,7 +56074,7 @@ int main() {
 mcrypt_module_open()
 ; return 0; }
 EOF
-if { (eval echo configure:56142: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:56078: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -56611,7 +56547,7 @@ fi
 php_with_mhash=no
 
 echo $ac_n "checking for mhash support""... $ac_c" 1>&6
-echo "configure:56615: checking for mhash support" >&5
+echo "configure:56551: checking for mhash support" >&5
 # Check whether --with-mhash or --without-mhash was given.
 if test "${with_mhash+set}" = set; then
   withval="$with_mhash"
@@ -57098,7 +57034,7 @@ fi
 php_with_mime_magic=no
 
 echo $ac_n "checking whether to include mime_magic support""... $ac_c" 1>&6
-echo "configure:57102: checking whether to include mime_magic support" >&5
+echo "configure:57038: checking whether to include mime_magic support" >&5
 # Check whether --with-mime-magic or --without-mime-magic was given.
 if test "${with_mime_magic+set}" = set; then
   withval="$with_mime_magic"
@@ -57467,7 +57403,7 @@ fi
 php_with_ming=no
 
 echo $ac_n "checking for MING support""... $ac_c" 1>&6
-echo "configure:57471: checking for MING support" >&5
+echo "configure:57407: checking for MING support" >&5
 # Check whether --with-ming or --without-ming was given.
 if test "${with_ming+set}" = set; then
   withval="$with_ming"
@@ -57512,7 +57448,7 @@ echo "$ac_t""$ext_output" 1>&6
 
 if test "$PHP_MING" != "no"; then
   echo $ac_n "checking for sin in -lm""... $ac_c" 1>&6
-echo "configure:57516: checking for sin in -lm" >&5
+echo "configure:57452: checking for sin in -lm" >&5
 ac_lib_var=`echo m'_'sin | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -57520,7 +57456,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lm  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 57524 "configure"
+#line 57460 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -57531,7 +57467,7 @@ int main() {
 sin()
 ; return 0; }
 EOF
-if { (eval echo configure:57535: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:57471: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -57678,7 +57614,7 @@ fi
   done
 
   echo $ac_n "checking for Ming_useSWFVersion in -lming""... $ac_c" 1>&6
-echo "configure:57682: checking for Ming_useSWFVersion in -lming" >&5
+echo "configure:57618: checking for Ming_useSWFVersion in -lming" >&5
 ac_lib_var=`echo ming'_'Ming_useSWFVersion | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -57686,7 +57622,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lming  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 57690 "configure"
+#line 57626 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -57697,7 +57633,7 @@ int main() {
 Ming_useSWFVersion()
 ; return 0; }
 EOF
-if { (eval echo configure:57701: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:57637: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -57960,7 +57896,7 @@ fi
   done
 
   echo $ac_n "checking for SWFPrebuiltClip in -lming""... $ac_c" 1>&6
-echo "configure:57964: checking for SWFPrebuiltClip in -lming" >&5
+echo "configure:57900: checking for SWFPrebuiltClip in -lming" >&5
 ac_lib_var=`echo ming'_'SWFPrebuiltClip | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -57968,7 +57904,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lming  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 57972 "configure"
+#line 57908 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -57979,7 +57915,7 @@ int main() {
 SWFPrebuiltClip()
 ; return 0; }
 EOF
-if { (eval echo configure:57983: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:57919: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -58108,7 +58044,7 @@ fi
   done
 
   echo $ac_n "checking for SWFMovie_namedAnchor in -lming""... $ac_c" 1>&6
-echo "configure:58112: checking for SWFMovie_namedAnchor in -lming" >&5
+echo "configure:58048: checking for SWFMovie_namedAnchor in -lming" >&5
 ac_lib_var=`echo ming'_'SWFMovie_namedAnchor | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -58116,7 +58052,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lming  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 58120 "configure"
+#line 58056 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -58127,7 +58063,7 @@ int main() {
 SWFMovie_namedAnchor()
 ; return 0; }
 EOF
-if { (eval echo configure:58131: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:58067: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -58256,7 +58192,7 @@ fi
   done
 
   echo $ac_n "checking for Ming_setSWFCompression in -lming""... $ac_c" 1>&6
-echo "configure:58260: checking for Ming_setSWFCompression in -lming" >&5
+echo "configure:58196: checking for Ming_setSWFCompression in -lming" >&5
 ac_lib_var=`echo ming'_'Ming_setSWFCompression | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -58264,7 +58200,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lming  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 58268 "configure"
+#line 58204 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -58275,7 +58211,7 @@ int main() {
 Ming_setSWFCompression()
 ; return 0; }
 EOF
-if { (eval echo configure:58279: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:58215: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -58312,14 +58248,14 @@ fi
   old_CPPFLAGS=$CPPFLAGS
   CPPFLAGS=-I$MING_INC_DIR
   echo $ac_n "checking for destroySWFBlock""... $ac_c" 1>&6
-echo "configure:58316: checking for destroySWFBlock" >&5
+echo "configure:58252: checking for destroySWFBlock" >&5
   if test "$cross_compiling" = yes; then
   
     echo "$ac_t""unknown" 1>&6
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 58323 "configure"
+#line 58259 "configure"
 #include "confdefs.h"
 
 #include "ming.h"
@@ -58331,7 +58267,7 @@ int main() {
 }
   
 EOF
-if { (eval echo configure:58335: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:58271: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     echo "$ac_t""missing" 1>&6
@@ -58353,7 +58289,7 @@ fi
  
 
   cat > conftest.$ac_ext <<EOF
-#line 58357 "configure"
+#line 58293 "configure"
 #include "confdefs.h"
 
 #include <ming.h>
@@ -58380,7 +58316,7 @@ rm -f conftest*
 
 
     cat > conftest.$ac_ext <<EOF
-#line 58384 "configure"
+#line 58320 "configure"
 #include "confdefs.h"
 
 #include <ming.h>
@@ -58391,7 +58327,7 @@ SWFMovie_output(NULL, NULL, NULL, 0);
   
 ; return 0; }
 EOF
-if { (eval echo configure:58395: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:58331: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
     cat >> confdefs.h <<\EOF
@@ -58710,7 +58646,7 @@ fi
 php_with_msql=no
 
 echo $ac_n "checking for mSQL support""... $ac_c" 1>&6
-echo "configure:58714: checking for mSQL support" >&5
+echo "configure:58650: checking for mSQL support" >&5
 # Check whether --with-msql or --without-msql was given.
 if test "${with_msql+set}" = set; then
   withval="$with_msql"
@@ -59190,11 +59126,11 @@ EOF
 
     
   echo $ac_n "checking mSQL version""... $ac_c" 1>&6
-echo "configure:59194: checking mSQL version" >&5
+echo "configure:59130: checking mSQL version" >&5
   ac_php_oldcppflags=$CPPFLAGS
   CPPFLAGS="$INCLUDES $CPPFLAGS"
   cat > conftest.$ac_ext <<EOF
-#line 59198 "configure"
+#line 59134 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include "msql.h"
@@ -59202,7 +59138,7 @@ int main() {
 int i = IDX_TYPE
 ; return 0; }
 EOF
-if { (eval echo configure:59206: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:59142: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
     cat >> confdefs.h <<\EOF
@@ -59234,7 +59170,7 @@ rm -f conftest*
 php_with_mssql=no
 
 echo $ac_n "checking for MSSQL support via FreeTDS""... $ac_c" 1>&6
-echo "configure:59238: checking for MSSQL support via FreeTDS" >&5
+echo "configure:59174: checking for MSSQL support via FreeTDS" >&5
 # Check whether --with-mssql or --without-mssql was given.
 if test "${with_mssql+set}" = set; then
   withval="$with_mssql"
@@ -59735,7 +59671,7 @@ EOF
   fi
 
   echo $ac_n "checking for dnet_addr in -ldnet_stub""... $ac_c" 1>&6
-echo "configure:59739: checking for dnet_addr in -ldnet_stub" >&5
+echo "configure:59675: checking for dnet_addr in -ldnet_stub" >&5
 ac_lib_var=`echo dnet_stub'_'dnet_addr | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -59743,7 +59679,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldnet_stub  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 59747 "configure"
+#line 59683 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -59754,7 +59690,7 @@ int main() {
 dnet_addr()
 ; return 0; }
 EOF
-if { (eval echo configure:59758: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:59694: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -59898,7 +59834,7 @@ fi
 php_with_mysql=no
 
 echo $ac_n "checking for MySQL support""... $ac_c" 1>&6
-echo "configure:59902: checking for MySQL support" >&5
+echo "configure:59838: checking for MySQL support" >&5
 # Check whether --with-mysql or --without-mysql was given.
 if test "${with_mysql+set}" = set; then
   withval="$with_mysql"
@@ -59945,7 +59881,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_mysql_sock=no
 
 echo $ac_n "checking for specified location of the MySQL UNIX socket""... $ac_c" 1>&6
-echo "configure:59949: checking for specified location of the MySQL UNIX socket" >&5
+echo "configure:59885: checking for specified location of the MySQL UNIX socket" >&5
 # Check whether --with-mysql-sock or --without-mysql-sock was given.
 if test "${with_mysql_sock+set}" = set; then
   withval="$with_mysql_sock"
@@ -59972,7 +59908,7 @@ if test -z "$PHP_ZLIB_DIR"; then
 php_with_zlib_dir=no
 
 echo $ac_n "checking for the location of libz""... $ac_c" 1>&6
-echo "configure:59976: checking for the location of libz" >&5
+echo "configure:59912: checking for the location of libz" >&5
 # Check whether --with-zlib-dir or --without-zlib-dir was given.
 if test "${with_zlib_dir+set}" = set; then
   withval="$with_zlib_dir"
@@ -60003,7 +59939,7 @@ EOF
 
 
   echo $ac_n "checking for MySQL UNIX socket location""... $ac_c" 1>&6
-echo "configure:60007: checking for MySQL UNIX socket location" >&5
+echo "configure:59943: checking for MySQL UNIX socket location" >&5
   if test "$PHP_MYSQL_SOCK" != "no" && test "$PHP_MYSQL_SOCK" != "yes"; then
     MYSQL_SOCK=$PHP_MYSQL_SOCK
     cat >> confdefs.h <<EOF
@@ -60194,7 +60130,7 @@ Note that the MySQL client library is not bundled anymore!" 1>&2; exit 1; }
   done
 
   echo $ac_n "checking for mysql_close in -l$MYSQL_LIBNAME""... $ac_c" 1>&6
-echo "configure:60198: checking for mysql_close in -l$MYSQL_LIBNAME" >&5
+echo "configure:60134: checking for mysql_close in -l$MYSQL_LIBNAME" >&5
 ac_lib_var=`echo $MYSQL_LIBNAME'_'mysql_close | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -60202,7 +60138,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$MYSQL_LIBNAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 60206 "configure"
+#line 60142 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -60213,7 +60149,7 @@ int main() {
 mysql_close()
 ; return 0; }
 EOF
-if { (eval echo configure:60217: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:60153: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -60436,7 +60372,7 @@ else
   done
 
   echo $ac_n "checking for mysql_error in -l$MYSQL_LIBNAME""... $ac_c" 1>&6
-echo "configure:60440: checking for mysql_error in -l$MYSQL_LIBNAME" >&5
+echo "configure:60376: checking for mysql_error in -l$MYSQL_LIBNAME" >&5
 ac_lib_var=`echo $MYSQL_LIBNAME'_'mysql_error | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -60444,7 +60380,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$MYSQL_LIBNAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 60448 "configure"
+#line 60384 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -60455,7 +60391,7 @@ int main() {
 mysql_error()
 ; return 0; }
 EOF
-if { (eval echo configure:60459: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:60395: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -60610,7 +60546,7 @@ fi
   done
 
   echo $ac_n "checking for mysql_errno in -l$MYSQL_LIBNAME""... $ac_c" 1>&6
-echo "configure:60614: checking for mysql_errno in -l$MYSQL_LIBNAME" >&5
+echo "configure:60550: checking for mysql_errno in -l$MYSQL_LIBNAME" >&5
 ac_lib_var=`echo $MYSQL_LIBNAME'_'mysql_errno | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -60618,7 +60554,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$MYSQL_LIBNAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 60622 "configure"
+#line 60558 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -60629,7 +60565,7 @@ int main() {
 mysql_errno()
 ; return 0; }
 EOF
-if { (eval echo configure:60633: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:60569: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -61122,7 +61058,7 @@ fi
 php_with_mysqli=no
 
 echo $ac_n "checking for MySQLi support""... $ac_c" 1>&6
-echo "configure:61126: checking for MySQLi support" >&5
+echo "configure:61062: checking for MySQLi support" >&5
 # Check whether --with-mysqli or --without-mysqli was given.
 if test "${with_mysqli+set}" = set; then
   withval="$with_mysqli"
@@ -61169,7 +61105,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_enable_embedded_mysqli=no
 
 echo $ac_n "checking whether to enable embedded MySQLi support""... $ac_c" 1>&6
-echo "configure:61173: checking whether to enable embedded MySQLi support" >&5
+echo "configure:61109: checking whether to enable embedded MySQLi support" >&5
 # Check whether --enable-embedded_mysqli or --disable-embedded_mysqli was given.
 if test "${enable_embedded_mysqli+set}" = set; then
   enableval="$enable_embedded_mysqli"
@@ -61320,7 +61256,7 @@ EOF
   done
 
   echo $ac_n "checking for mysql_set_server_option in -l$MYSQL_LIB_NAME""... $ac_c" 1>&6
-echo "configure:61324: checking for mysql_set_server_option in -l$MYSQL_LIB_NAME" >&5
+echo "configure:61260: checking for mysql_set_server_option in -l$MYSQL_LIB_NAME" >&5
 ac_lib_var=`echo $MYSQL_LIB_NAME'_'mysql_set_server_option | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -61328,7 +61264,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$MYSQL_LIB_NAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 61332 "configure"
+#line 61268 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -61339,7 +61275,7 @@ int main() {
 mysql_set_server_option()
 ; return 0; }
 EOF
-if { (eval echo configure:61343: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:61279: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -61587,7 +61523,7 @@ EOF
   done
 
   echo $ac_n "checking for mysql_stmt_field_count in -l$MYSQL_LIB_NAME""... $ac_c" 1>&6
-echo "configure:61591: checking for mysql_stmt_field_count in -l$MYSQL_LIB_NAME" >&5
+echo "configure:61527: checking for mysql_stmt_field_count in -l$MYSQL_LIB_NAME" >&5
 ac_lib_var=`echo $MYSQL_LIB_NAME'_'mysql_stmt_field_count | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -61595,7 +61531,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$MYSQL_LIB_NAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 61599 "configure"
+#line 61535 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -61606,7 +61542,7 @@ int main() {
 mysql_stmt_field_count()
 ; return 0; }
 EOF
-if { (eval echo configure:61610: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:61546: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -61955,7 +61891,7 @@ fi
 php_with_ncurses=no
 
 echo $ac_n "checking for ncurses support""... $ac_c" 1>&6
-echo "configure:61959: checking for ncurses support" >&5
+echo "configure:61895: checking for ncurses support" >&5
 # Check whether --with-ncurses or --without-ncurses was given.
 if test "${with_ncurses+set}" = set; then
   withval="$with_ncurses"
@@ -62162,7 +62098,7 @@ EOF
   done
 
   echo $ac_n "checking for $LIBSYMBOL in -l$LIBNAME""... $ac_c" 1>&6
-echo "configure:62166: checking for $LIBSYMBOL in -l$LIBNAME" >&5
+echo "configure:62102: checking for $LIBSYMBOL in -l$LIBNAME" >&5
 ac_lib_var=`echo $LIBNAME'_'$LIBSYMBOL | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -62170,7 +62106,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$LIBNAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 62174 "configure"
+#line 62110 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -62181,7 +62117,7 @@ int main() {
 $LIBSYMBOL()
 ; return 0; }
 EOF
-if { (eval echo configure:62185: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:62121: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -62400,7 +62336,7 @@ EOF
   done
 
   echo $ac_n "checking for new_panel in -lpanel""... $ac_c" 1>&6
-echo "configure:62404: checking for new_panel in -lpanel" >&5
+echo "configure:62340: checking for new_panel in -lpanel" >&5
 ac_lib_var=`echo panel'_'new_panel | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -62408,7 +62344,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpanel  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 62412 "configure"
+#line 62348 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -62419,7 +62355,7 @@ int main() {
 new_panel()
 ; return 0; }
 EOF
-if { (eval echo configure:62423: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:62359: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -62567,7 +62503,7 @@ fi
 
  
    echo $ac_n "checking for color_set in -l$LIBNAME""... $ac_c" 1>&6
-echo "configure:62571: checking for color_set in -l$LIBNAME" >&5
+echo "configure:62507: checking for color_set in -l$LIBNAME" >&5
 ac_lib_var=`echo $LIBNAME'_'color_set | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -62575,7 +62511,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$LIBNAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 62579 "configure"
+#line 62515 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -62586,7 +62522,7 @@ int main() {
 color_set()
 ; return 0; }
 EOF
-if { (eval echo configure:62590: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:62526: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -62610,7 +62546,7 @@ else
 fi
 
    echo $ac_n "checking for slk_color in -l$LIBNAME""... $ac_c" 1>&6
-echo "configure:62614: checking for slk_color in -l$LIBNAME" >&5
+echo "configure:62550: checking for slk_color in -l$LIBNAME" >&5
 ac_lib_var=`echo $LIBNAME'_'slk_color | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -62618,7 +62554,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$LIBNAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 62622 "configure"
+#line 62558 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -62629,7 +62565,7 @@ int main() {
 slk_color()
 ; return 0; }
 EOF
-if { (eval echo configure:62633: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:62569: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -62653,7 +62589,7 @@ else
 fi
 
    echo $ac_n "checking for assume_default_colors in -l$LIBNAME""... $ac_c" 1>&6
-echo "configure:62657: checking for assume_default_colors in -l$LIBNAME" >&5
+echo "configure:62593: checking for assume_default_colors in -l$LIBNAME" >&5
 ac_lib_var=`echo $LIBNAME'_'assume_default_colors | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -62661,7 +62597,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$LIBNAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 62665 "configure"
+#line 62601 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -62672,7 +62608,7 @@ int main() {
 assume_default_colors()
 ; return 0; }
 EOF
-if { (eval echo configure:62676: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:62612: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -62696,7 +62632,7 @@ else
 fi
 
    echo $ac_n "checking for use_extended_names in -l$LIBNAME""... $ac_c" 1>&6
-echo "configure:62700: checking for use_extended_names in -l$LIBNAME" >&5
+echo "configure:62636: checking for use_extended_names in -l$LIBNAME" >&5
 ac_lib_var=`echo $LIBNAME'_'use_extended_names | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -62704,7 +62640,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$LIBNAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 62708 "configure"
+#line 62644 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -62715,7 +62651,7 @@ int main() {
 use_extended_names()
 ; return 0; }
 EOF
-if { (eval echo configure:62719: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:62655: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -63058,7 +62994,7 @@ fi
 php_with_oci8=no
 
 echo $ac_n "checking for Oracle (OCI8) support""... $ac_c" 1>&6
-echo "configure:63062: checking for Oracle (OCI8) support" >&5
+echo "configure:62998: checking for Oracle (OCI8) support" >&5
 # Check whether --with-oci8 or --without-oci8 was given.
 if test "${with_oci8+set}" = set; then
   withval="$with_oci8"
@@ -63103,7 +63039,7 @@ echo "$ac_t""$ext_output" 1>&6
 
 if test "$PHP_OCI8" != "no"; then 
   echo $ac_n "checking PHP version""... $ac_c" 1>&6
-echo "configure:63107: checking PHP version" >&5
+echo "configure:63043: checking PHP version" >&5
 
   tmp_version=$PHP_VERSION
   if test -z "$tmp_version"; then
@@ -63159,7 +63095,7 @@ fi
 if test "$PHP_OCI8" != "no" && test "$PHP_OCI8_INSTANT_CLIENT" = "no"; then
 
   echo $ac_n "checking Oracle Install Directory""... $ac_c" 1>&6
-echo "configure:63163: checking Oracle Install Directory" >&5
+echo "configure:63099: checking Oracle Install Directory" >&5
   if test "$PHP_OCI8" = "yes"; then
     OCI8_DIR=$ORACLE_HOME
   else
@@ -63169,7 +63105,7 @@ echo "configure:63163: checking Oracle Install Directory" >&5
 
   
   echo $ac_n "checking size of long int""... $ac_c" 1>&6
-echo "configure:63173: checking size of long int" >&5
+echo "configure:63109: checking size of long int" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long_int'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -63177,7 +63113,7 @@ else
   ac_cv_sizeof_long_int=4
 else
   cat > conftest.$ac_ext <<EOF
-#line 63181 "configure"
+#line 63117 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -63188,7 +63124,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:63192: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:63128: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long_int=`cat conftestval`
 else
@@ -63208,7 +63144,7 @@ EOF
 
 
   echo $ac_n "checking if we're on a 64-bit platform""... $ac_c" 1>&6
-echo "configure:63212: checking if we're on a 64-bit platform" >&5
+echo "configure:63148: checking if we're on a 64-bit platform" >&5
   if test "$ac_cv_sizeof_long_int" = "4" ; then
     echo "$ac_t""no" 1>&6
     TMP_OCI8_LIB_DIR=lib32 
@@ -63218,7 +63154,7 @@ echo "configure:63212: checking if we're on a 64-bit platform" >&5
   fi
 
   echo $ac_n "checking OCI8 libraries dir""... $ac_c" 1>&6
-echo "configure:63222: checking OCI8 libraries dir" >&5
+echo "configure:63158: checking OCI8 libraries dir" >&5
   if test -d "$OCI8_DIR/lib" && test ! -d "$OCI8_DIR/lib32"; then
     OCI8_LIB_DIR=lib
   elif test ! -d "$OCI8_DIR/lib" && test -d "$OCI8_DIR/lib32"; then
@@ -63552,7 +63488,7 @@ echo "configure:63222: checking OCI8 libraries dir" >&5
 
   
   echo $ac_n "checking Oracle version""... $ac_c" 1>&6
-echo "configure:63556: checking Oracle version" >&5
+echo "configure:63492: checking Oracle version" >&5
   if test -s "$OCI8_DIR/orainst/unix.rgs"; then
     OCI8_VERSION=`grep '"ocommon"' $OCI8_DIR/orainst/unix.rgs | $PHP_OCI8_SED 's/  */:/g' | cut -d: -f 6 | cut -c 2-4`
     test -z "$OCI8_VERSION" && OCI8_VERSION=7.3
@@ -64067,7 +64003,7 @@ echo "configure:63556: checking Oracle version" >&5
   done
 
   echo $ac_n "checking for OCIEnvCreate in -lclntsh""... $ac_c" 1>&6
-echo "configure:64071: checking for OCIEnvCreate in -lclntsh" >&5
+echo "configure:64007: checking for OCIEnvCreate in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCIEnvCreate | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -64075,7 +64011,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 64079 "configure"
+#line 64015 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -64086,7 +64022,7 @@ int main() {
 OCIEnvCreate()
 ; return 0; }
 EOF
-if { (eval echo configure:64090: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:64026: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -64220,7 +64156,7 @@ fi
   done
 
   echo $ac_n "checking for OCIStmtPrepare2 in -lclntsh""... $ac_c" 1>&6
-echo "configure:64224: checking for OCIStmtPrepare2 in -lclntsh" >&5
+echo "configure:64160: checking for OCIStmtPrepare2 in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCIStmtPrepare2 | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -64228,7 +64164,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 64232 "configure"
+#line 64168 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -64239,7 +64175,7 @@ int main() {
 OCIStmtPrepare2()
 ; return 0; }
 EOF
-if { (eval echo configure:64243: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:64179: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -64437,7 +64373,7 @@ fi
   done
 
   echo $ac_n "checking for OCIEnvCreate in -lclntsh""... $ac_c" 1>&6
-echo "configure:64441: checking for OCIEnvCreate in -lclntsh" >&5
+echo "configure:64377: checking for OCIEnvCreate in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCIEnvCreate | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -64445,7 +64381,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 64449 "configure"
+#line 64385 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -64456,7 +64392,7 @@ int main() {
 OCIEnvCreate()
 ; return 0; }
 EOF
-if { (eval echo configure:64460: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:64396: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -64590,7 +64526,7 @@ fi
   done
 
   echo $ac_n "checking for OCIStmtPrepare2 in -lclntsh""... $ac_c" 1>&6
-echo "configure:64594: checking for OCIStmtPrepare2 in -lclntsh" >&5
+echo "configure:64530: checking for OCIStmtPrepare2 in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCIStmtPrepare2 | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -64598,7 +64534,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 64602 "configure"
+#line 64538 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -64609,7 +64545,7 @@ int main() {
 OCIStmtPrepare2()
 ; return 0; }
 EOF
-if { (eval echo configure:64613: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:64549: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -64649,7 +64585,7 @@ fi
   old_CPPFLAGS=$CPPFLAGS
   CPPFLAGS=$OCI8_INCLUDES
   cat > conftest.$ac_ext <<EOF
-#line 64653 "configure"
+#line 64589 "configure"
 #include "confdefs.h"
 
 #include <oci.h>
@@ -64844,7 +64780,7 @@ EOF
   done
 
   echo $ac_n "checking for OCIEnvNlsCreate in -lclntsh""... $ac_c" 1>&6
-echo "configure:64848: checking for OCIEnvNlsCreate in -lclntsh" >&5
+echo "configure:64784: checking for OCIEnvNlsCreate in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCIEnvNlsCreate | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -64852,7 +64788,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 64856 "configure"
+#line 64792 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -64863,7 +64799,7 @@ int main() {
 OCIEnvNlsCreate()
 ; return 0; }
 EOF
-if { (eval echo configure:64867: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:64803: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -64980,7 +64916,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
   done
 
   echo $ac_n "checking for OCINlsCharSetNameToId in -lclntsh""... $ac_c" 1>&6
-echo "configure:64984: checking for OCINlsCharSetNameToId in -lclntsh" >&5
+echo "configure:64920: checking for OCINlsCharSetNameToId in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCINlsCharSetNameToId | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -64988,7 +64924,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 64992 "configure"
+#line 64928 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -64999,7 +64935,7 @@ int main() {
 OCINlsCharSetNameToId()
 ; return 0; }
 EOF
-if { (eval echo configure:65003: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:64939: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -65146,7 +65082,7 @@ fi
   done
 
   echo $ac_n "checking for OCIEnvCreate in -lclntsh""... $ac_c" 1>&6
-echo "configure:65150: checking for OCIEnvCreate in -lclntsh" >&5
+echo "configure:65086: checking for OCIEnvCreate in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCIEnvCreate | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -65154,7 +65090,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 65158 "configure"
+#line 65094 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -65165,7 +65101,7 @@ int main() {
 OCIEnvCreate()
 ; return 0; }
 EOF
-if { (eval echo configure:65169: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:65105: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -65299,7 +65235,7 @@ fi
   done
 
   echo $ac_n "checking for OCIStmtPrepare2 in -lclntsh""... $ac_c" 1>&6
-echo "configure:65303: checking for OCIStmtPrepare2 in -lclntsh" >&5
+echo "configure:65239: checking for OCIStmtPrepare2 in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCIStmtPrepare2 | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -65307,7 +65243,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 65311 "configure"
+#line 65247 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -65318,7 +65254,7 @@ int main() {
 OCIStmtPrepare2()
 ; return 0; }
 EOF
-if { (eval echo configure:65322: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:65258: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -65452,7 +65388,7 @@ fi
   done
 
   echo $ac_n "checking for OCILobRead2 in -lclntsh""... $ac_c" 1>&6
-echo "configure:65456: checking for OCILobRead2 in -lclntsh" >&5
+echo "configure:65392: checking for OCILobRead2 in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCILobRead2 | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -65460,7 +65396,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 65464 "configure"
+#line 65400 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -65471,7 +65407,7 @@ int main() {
 OCILobRead2()
 ; return 0; }
 EOF
-if { (eval echo configure:65475: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:65411: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -65703,7 +65639,7 @@ EOF
   done
 
   echo $ac_n "checking for OCILobIsTemporary in -lclntsh""... $ac_c" 1>&6
-echo "configure:65707: checking for OCILobIsTemporary in -lclntsh" >&5
+echo "configure:65643: checking for OCILobIsTemporary in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCILobIsTemporary | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -65711,7 +65647,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 65715 "configure"
+#line 65651 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -65722,7 +65658,7 @@ int main() {
 OCILobIsTemporary()
 ; return 0; }
 EOF
-if { (eval echo configure:65726: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:65662: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -65852,7 +65788,7 @@ else
   done
 
   echo $ac_n "checking for OCILobIsTemporary in -locijdbc8""... $ac_c" 1>&6
-echo "configure:65856: checking for OCILobIsTemporary in -locijdbc8" >&5
+echo "configure:65792: checking for OCILobIsTemporary in -locijdbc8" >&5
 ac_lib_var=`echo ocijdbc8'_'OCILobIsTemporary | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -65860,7 +65796,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-locijdbc8  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 65864 "configure"
+#line 65800 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -65871,7 +65807,7 @@ int main() {
 OCILobIsTemporary()
 ; return 0; }
 EOF
-if { (eval echo configure:65875: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:65811: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -66032,7 +65968,7 @@ fi
   done
 
   echo $ac_n "checking for OCICollAssign in -lclntsh""... $ac_c" 1>&6
-echo "configure:66036: checking for OCICollAssign in -lclntsh" >&5
+echo "configure:65972: checking for OCICollAssign in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCICollAssign | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -66040,7 +65976,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 66044 "configure"
+#line 65980 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -66051,7 +65987,7 @@ int main() {
 OCICollAssign()
 ; return 0; }
 EOF
-if { (eval echo configure:66055: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:65991: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -66699,7 +66635,7 @@ EOF
 elif test "$PHP_OCI8" != "no" && test "$PHP_OCI8_INSTANT_CLIENT" != "no"; then
 
   echo $ac_n "checking size of long int""... $ac_c" 1>&6
-echo "configure:66703: checking size of long int" >&5
+echo "configure:66639: checking size of long int" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long_int'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -66707,7 +66643,7 @@ else
   ac_cv_sizeof_long_int=4
 else
   cat > conftest.$ac_ext <<EOF
-#line 66711 "configure"
+#line 66647 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -66718,7 +66654,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:66722: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:66658: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long_int=`cat conftestval`
 else
@@ -66743,7 +66679,7 @@ EOF
   fi
 
   echo $ac_n "checking Oracle Instant Client directory""... $ac_c" 1>&6
-echo "configure:66747: checking Oracle Instant Client directory" >&5
+echo "configure:66683: checking Oracle Instant Client directory" >&5
   if test "$PHP_OCI8_INSTANT_CLIENT" = "yes"; then
     PHP_OCI8_INSTANT_CLIENT=`ls -d /usr/lib/oracle/*/client${LIBDIR_SUFFIX}/lib 2> /dev/null | tail -1`
     if test -z "$PHP_OCI8_INSTANT_CLIENT"; then
@@ -66755,7 +66691,7 @@ echo "configure:66747: checking Oracle Instant Client directory" >&5
   OCI8_DIR=$PHP_OCI8_INSTANT_CLIENT
 
   echo $ac_n "checking Oracle Instant Client SDK header directory""... $ac_c" 1>&6
-echo "configure:66759: checking Oracle Instant Client SDK header directory" >&5
+echo "configure:66695: checking Oracle Instant Client SDK header directory" >&5
 
   OCISDKRPMINC=`echo "$PHP_OCI8_INSTANT_CLIENT" | $PHP_OCI8_SED -e 's!^/usr/lib/oracle/\(.*\)/client\('${LIBDIR_SUFFIX}'\)*/lib/*$!/usr/include/oracle/\1/client\2!'`
 
@@ -66964,7 +66900,7 @@ echo "configure:66759: checking Oracle Instant Client SDK header directory" >&5
 
   
   echo $ac_n "checking Oracle Instant Client version""... $ac_c" 1>&6
-echo "configure:66968: checking Oracle Instant Client version" >&5
+echo "configure:66904: checking Oracle Instant Client version" >&5
   if test -f $PHP_OCI8_INSTANT_CLIENT/libnnz11.$SHLIB_SUFFIX_NAME; then
     if test -f $PHP_OCI8_INSTANT_CLIENT/libclntsh.$SHLIB_SUFFIX_NAME.11.1; then
       if test ! -f $PHP_OCI8_INSTANT_CLIENT/libclntsh.$SHLIB_SUFFIX_NAME; then
@@ -67469,7 +67405,7 @@ esac
 
   if test "$PHP_ADABAS" != "no"; then
     echo $ac_n "checking for Adabas support""... $ac_c" 1>&6
-echo "configure:67473: checking for Adabas support" >&5
+echo "configure:67409: checking for Adabas support" >&5
     if test "$PHP_ADABAS" = "yes"; then
       PHP_ADABAS=/usr/local
     fi
@@ -67675,7 +67611,7 @@ esac
 
   if test "$PHP_SAPDB" != "no"; then
     echo $ac_n "checking for SAP DB support""... $ac_c" 1>&6
-echo "configure:67679: checking for SAP DB support" >&5
+echo "configure:67615: checking for SAP DB support" >&5
     if test "$PHP_SAPDB" = "yes"; then
       PHP_SAPDB=/usr/local
     fi
@@ -67811,7 +67747,7 @@ esac
 
   if test "$PHP_SOLID" != "no"; then
     echo $ac_n "checking for Solid support""... $ac_c" 1>&6
-echo "configure:67815: checking for Solid support" >&5
+echo "configure:67751: checking for Solid support" >&5
     if test "$PHP_SOLID" = "yes"; then
       PHP_SOLID=/usr/local/solid
     fi
@@ -67838,7 +67774,7 @@ EOF
     echo "$ac_t""$ext_output" 1>&6
     
   echo $ac_n "checking Solid library file""... $ac_c" 1>&6
-echo "configure:67842: checking Solid library file" >&5  
+echo "configure:67778: checking Solid library file" >&5  
   ac_solid_uname_r=`uname -r 2>/dev/null`
   ac_solid_uname_s=`uname -s 2>/dev/null`
   case $ac_solid_uname_s in
@@ -67962,7 +67898,7 @@ esac
 
   if test "$PHP_IBM_DB2" != "no"; then
     echo $ac_n "checking for IBM DB2 support""... $ac_c" 1>&6
-echo "configure:67966: checking for IBM DB2 support" >&5
+echo "configure:67902: checking for IBM DB2 support" >&5
     if test "$PHP_IBM_DB2" = "yes"; then
       ODBC_INCDIR=/home/db2inst1/sqllib/include
       ODBC_LIBDIR=/home/db2inst1/sqllib/lib
@@ -67993,7 +67929,7 @@ fi
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 67997 "configure"
+#line 67933 "configure"
 #include "confdefs.h"
 
     
@@ -68004,7 +67940,7 @@ else
     }
   
 EOF
-if { (eval echo configure:68008: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:67944: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     LIBS=$old_LIBS
@@ -68088,7 +68024,7 @@ esac
 
   if test "$PHP_ODBCROUTER" != "no"; then
     echo $ac_n "checking for ODBCRouter.com support""... $ac_c" 1>&6
-echo "configure:68092: checking for ODBCRouter.com support" >&5
+echo "configure:68028: checking for ODBCRouter.com support" >&5
     if test "$PHP_ODBCROUTER" = "yes"; then
       PHP_ODBCROUTER=/usr
     fi
@@ -68155,7 +68091,7 @@ esac
 
   if test "$PHP_EMPRESS" != "no"; then
     echo $ac_n "checking for Empress support""... $ac_c" 1>&6
-echo "configure:68159: checking for Empress support" >&5
+echo "configure:68095: checking for Empress support" >&5
     if test "$PHP_EMPRESS" = "yes"; then
       ODBC_INCDIR=$EMPRESSPATH/include/odbc
       ODBC_LIBDIR=$EMPRESSPATH/shlib
@@ -68173,7 +68109,7 @@ EOF
     echo "$ac_t""$ext_output" 1>&6
     
   echo $ac_n "checking Empress library file""... $ac_c" 1>&6
-echo "configure:68177: checking Empress library file" >&5
+echo "configure:68113: checking Empress library file" >&5
   ODBC_LIBS=`echo $ODBC_LIBDIR/libempodbccl.so | cut -d' ' -f1`
   if test ! -f $ODBC_LIBS; then
     ODBC_LIBS=`echo $ODBC_LIBDIR/libempodbccl.so | cut -d' ' -f1`
@@ -68232,7 +68168,7 @@ esac
 
   if test "$PHP_EMPRESS_BCS" != "no"; then
     echo $ac_n "checking for Empress local access support""... $ac_c" 1>&6
-echo "configure:68236: checking for Empress local access support" >&5
+echo "configure:68172: checking for Empress local access support" >&5
     if test "$PHP_EMPRESS_BCS" = "yes"; then
       ODBC_INCDIR=$EMPRESSPATH/include/odbc
       ODBC_LIBDIR=$EMPRESSPATH/shlib
@@ -68266,7 +68202,7 @@ EOF
     echo "$ac_t""$ext_output" 1>&6
     
   echo $ac_n "checking Empress local access library file""... $ac_c" 1>&6
-echo "configure:68270: checking Empress local access library file" >&5
+echo "configure:68206: checking Empress local access library file" >&5
   ODBCBCS_LIBS=`echo $ODBC_LIBDIR/libempodbcbcs.a | cut -d' ' -f1`
   if test ! -f $ODBCBCS_LIBS; then
     ODBCBCS_LIBS=`echo $ODBC_LIBDIR/libempodbcbcs.a | cut -d' ' -f1`
@@ -68325,7 +68261,7 @@ esac
   
   if test "$PHP_BIRDSTEP" != "no"; then
     echo $ac_n "checking for Birdstep support""... $ac_c" 1>&6
-echo "configure:68329: checking for Birdstep support" >&5
+echo "configure:68265: checking for Birdstep support" >&5
     if test "$PHP_BIRDSTEP" = "yes"; then
         ODBC_INCDIR=/usr/local/birdstep/include
         ODBC_LIBDIR=/usr/local/birdstep/lib
@@ -68440,7 +68376,7 @@ esac
 
   if test "$PHP_CUSTOM_ODBC" != "no"; then
     echo $ac_n "checking for a custom ODBC support""... $ac_c" 1>&6
-echo "configure:68444: checking for a custom ODBC support" >&5
+echo "configure:68380: checking for a custom ODBC support" >&5
     if test "$PHP_CUSTOM_ODBC" = "yes"; then
       PHP_CUSTOM_ODBC=/usr/local
     fi
@@ -68507,7 +68443,7 @@ esac
 
   if test "$PHP_IODBC" != "no"; then
     echo $ac_n "checking for iODBC support""... $ac_c" 1>&6
-echo "configure:68511: checking for iODBC support" >&5
+echo "configure:68447: checking for iODBC support" >&5
     if test "$PHP_IODBC" = "yes"; then
       PHP_IODBC=/usr/local
     fi
@@ -68656,7 +68592,7 @@ esac
 
   if test "$PHP_ESOOB" != "no"; then
     echo $ac_n "checking for Easysoft ODBC-ODBC Bridge support""... $ac_c" 1>&6
-echo "configure:68660: checking for Easysoft ODBC-ODBC Bridge support" >&5
+echo "configure:68596: checking for Easysoft ODBC-ODBC Bridge support" >&5
     if test "$PHP_ESOOB" = "yes"; then
       PHP_ESOOB=/usr/local/easysoft/oob/client
     fi
@@ -68723,7 +68659,7 @@ esac
 
   if test "$PHP_UNIXODBC" != "no"; then
     echo $ac_n "checking for unixODBC support""... $ac_c" 1>&6
-echo "configure:68727: checking for unixODBC support" >&5
+echo "configure:68663: checking for unixODBC support" >&5
     if test "$PHP_UNIXODBC" = "yes"; then
       PHP_UNIXODBC=/usr/local
     fi
@@ -68795,7 +68731,7 @@ esac
 
   if test "$PHP_DBMAKER" != "no"; then
     echo $ac_n "checking for DBMaker support""... $ac_c" 1>&6
-echo "configure:68799: checking for DBMaker support" >&5
+echo "configure:68735: checking for DBMaker support" >&5
     if test "$PHP_DBMAKER" = "yes"; then
       # find dbmaker's home directory
       DBMAKER_HOME=`grep "^dbmaker:" /etc/passwd | $AWK -F: '{print $6}'`
@@ -69357,7 +69293,7 @@ fi
 php_enable_pcntl=no
 
 echo $ac_n "checking whether to enable pcntl support""... $ac_c" 1>&6
-echo "configure:69361: checking whether to enable pcntl support" >&5
+echo "configure:69297: checking whether to enable pcntl support" >&5
 # Check whether --enable-pcntl or --disable-pcntl was given.
 if test "${enable_pcntl+set}" = set; then
   enableval="$enable_pcntl"
@@ -69405,12 +69341,12 @@ if test "$PHP_PCNTL" != "no"; then
   for ac_func in fork
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:69409: checking for $ac_func" >&5
+echo "configure:69345: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 69414 "configure"
+#line 69350 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -69433,7 +69369,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:69437: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:69373: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -69464,12 +69400,12 @@ done
   for ac_func in waitpid
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:69468: checking for $ac_func" >&5
+echo "configure:69404: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 69473 "configure"
+#line 69409 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -69492,7 +69428,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:69496: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:69432: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -69523,12 +69459,12 @@ done
   for ac_func in sigaction
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:69527: checking for $ac_func" >&5
+echo "configure:69463: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 69532 "configure"
+#line 69468 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -69551,7 +69487,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:69555: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:69491: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -69582,12 +69518,12 @@ done
   for ac_func in getpriority setpriority wait3
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:69586: checking for $ac_func" >&5
+echo "configure:69522: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 69591 "configure"
+#line 69527 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -69610,7 +69546,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:69614: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:69550: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -69936,7 +69872,7 @@ fi
 php_enable_pdo=yes
 
 echo $ac_n "checking whether to enable PDO support""... $ac_c" 1>&6
-echo "configure:69940: checking whether to enable PDO support" >&5
+echo "configure:69876: checking whether to enable PDO support" >&5
 # Check whether --enable-pdo or --disable-pdo was given.
 if test "${enable_pdo+set}" = set; then
   enableval="$enable_pdo"
@@ -70372,7 +70308,7 @@ if test "$PHP_PDO" != "no"; then
 php_with_pdo_dblib=no
 
 echo $ac_n "checking for PDO_DBLIB support via FreeTDS""... $ac_c" 1>&6
-echo "configure:70376: checking for PDO_DBLIB support via FreeTDS" >&5
+echo "configure:70312: checking for PDO_DBLIB support via FreeTDS" >&5
 # Check whether --with-pdo-dblib or --without-pdo-dblib was given.
 if test "${with_pdo_dblib+set}" = set; then
   withval="$with_pdo_dblib"
@@ -70589,13 +70525,13 @@ if test "$PHP_PDO_DBLIB" != "no"; then
   
     
   echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:70593: checking for PDO includes" >&5
+echo "configure:70529: checking for PDO includes" >&5
 if eval "test \"`echo '$''{'pdo_inc_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:70599: checking for PDO includes" >&5
+echo "configure:70535: checking for PDO includes" >&5
     if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
       pdo_inc_path=$abs_srcdir/ext
     elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
@@ -70909,7 +70845,7 @@ EOF
   fi
 
   echo $ac_n "checking for dnet_addr in -ldnet_stub""... $ac_c" 1>&6
-echo "configure:70913: checking for dnet_addr in -ldnet_stub" >&5
+echo "configure:70849: checking for dnet_addr in -ldnet_stub" >&5
 ac_lib_var=`echo dnet_stub'_'dnet_addr | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -70917,7 +70853,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldnet_stub  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 70921 "configure"
+#line 70857 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -70928,7 +70864,7 @@ int main() {
 dnet_addr()
 ; return 0; }
 EOF
-if { (eval echo configure:70932: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:70868: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -71093,7 +71029,7 @@ if test "$PHP_PDO" != "no"; then
 php_with_pdo_firebird=no
 
 echo $ac_n "checking for Firebird support for PDO""... $ac_c" 1>&6
-echo "configure:71097: checking for Firebird support for PDO" >&5
+echo "configure:71033: checking for Firebird support for PDO" >&5
 # Check whether --with-pdo-firebird or --without-pdo-firebird was given.
 if test "${with_pdo_firebird+set}" = set; then
   withval="$with_pdo_firebird"
@@ -71243,7 +71179,7 @@ if test "$PHP_PDO_FIREBIRD" != "no"; then
   done
 
   echo $ac_n "checking for isc_detach_database in -lfbclient""... $ac_c" 1>&6
-echo "configure:71247: checking for isc_detach_database in -lfbclient" >&5
+echo "configure:71183: checking for isc_detach_database in -lfbclient" >&5
 ac_lib_var=`echo fbclient'_'isc_detach_database | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -71251,7 +71187,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lfbclient  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 71255 "configure"
+#line 71191 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -71262,7 +71198,7 @@ int main() {
 isc_detach_database()
 ; return 0; }
 EOF
-if { (eval echo configure:71266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:71202: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -71389,7 +71325,7 @@ else
   done
 
   echo $ac_n "checking for isc_detach_database in -lgds""... $ac_c" 1>&6
-echo "configure:71393: checking for isc_detach_database in -lgds" >&5
+echo "configure:71329: checking for isc_detach_database in -lgds" >&5
 ac_lib_var=`echo gds'_'isc_detach_database | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -71397,7 +71333,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgds  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 71401 "configure"
+#line 71337 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -71408,7 +71344,7 @@ int main() {
 isc_detach_database()
 ; return 0; }
 EOF
-if { (eval echo configure:71412: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:71348: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -71535,7 +71471,7 @@ else
   done
 
   echo $ac_n "checking for isc_detach_database in -lib_util""... $ac_c" 1>&6
-echo "configure:71539: checking for isc_detach_database in -lib_util" >&5
+echo "configure:71475: checking for isc_detach_database in -lib_util" >&5
 ac_lib_var=`echo ib_util'_'isc_detach_database | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -71543,7 +71479,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lib_util  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 71547 "configure"
+#line 71483 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -71554,7 +71490,7 @@ int main() {
 isc_detach_database()
 ; return 0; }
 EOF
-if { (eval echo configure:71558: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:71494: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -71599,13 +71535,13 @@ fi
  
   
   echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:71603: checking for PDO includes" >&5
+echo "configure:71539: checking for PDO includes" >&5
 if eval "test \"`echo '$''{'pdo_inc_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:71609: checking for PDO includes" >&5
+echo "configure:71545: checking for PDO includes" >&5
     if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
       pdo_inc_path=$abs_srcdir/ext
     elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
@@ -72083,7 +72019,7 @@ if test "$PHP_PDO" != "no"; then
 php_with_pdo_mysql=no
 
 echo $ac_n "checking for MySQL support for PDO""... $ac_c" 1>&6
-echo "configure:72087: checking for MySQL support for PDO" >&5
+echo "configure:72023: checking for MySQL support for PDO" >&5
 # Check whether --with-pdo-mysql or --without-pdo-mysql was given.
 if test "${with_pdo_mysql+set}" = set; then
   withval="$with_pdo_mysql"
@@ -72131,7 +72067,7 @@ if test -z "$PHP_ZLIB_DIR"; then
 php_with_zlib_dir=no
 
 echo $ac_n "checking for the location of libz""... $ac_c" 1>&6
-echo "configure:72135: checking for the location of libz" >&5
+echo "configure:72071: checking for the location of libz" >&5
 # Check whether --with-zlib-dir or --without-zlib-dir was given.
 if test "${with_zlib_dir+set}" = set; then
   withval="$with_zlib_dir"
@@ -72161,7 +72097,7 @@ EOF
 
 
   echo $ac_n "checking for mysql_config""... $ac_c" 1>&6
-echo "configure:72165: checking for mysql_config" >&5
+echo "configure:72101: checking for mysql_config" >&5
 
   if test -f $PHP_PDO_MYSQL && test -x $PHP_PDO_MYSQL ; then
     PDO_MYSQL_CONFIG=$PHP_PDO_MYSQL
@@ -72195,7 +72131,7 @@ echo "configure:72165: checking for mysql_config" >&5
       # Extract the first word of "sed", so it can be a program name with args.
 set dummy sed; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:72199: checking for $ac_word" >&5
+echo "configure:72135: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_SED'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -72243,7 +72179,7 @@ fi
   else
     echo "$ac_t""not found" 1>&6
     echo $ac_n "checking for mysql install under $PDO_MYSQL_DIR""... $ac_c" 1>&6
-echo "configure:72247: checking for mysql install under $PDO_MYSQL_DIR" >&5
+echo "configure:72183: checking for mysql install under $PDO_MYSQL_DIR" >&5
     if test -r $PDO_MYSQL_DIR/include/mysql; then
       PDO_MYSQL_INC_DIR=$PDO_MYSQL_DIR/include/mysql
     else
@@ -72497,7 +72433,7 @@ EOF
   done
 
   echo $ac_n "checking for mysql_query in -l$PDO_MYSQL_LIBNAME""... $ac_c" 1>&6
-echo "configure:72501: checking for mysql_query in -l$PDO_MYSQL_LIBNAME" >&5
+echo "configure:72437: checking for mysql_query in -l$PDO_MYSQL_LIBNAME" >&5
 ac_lib_var=`echo $PDO_MYSQL_LIBNAME'_'mysql_query | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -72505,7 +72441,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$PDO_MYSQL_LIBNAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 72509 "configure"
+#line 72445 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -72516,7 +72452,7 @@ int main() {
 mysql_query()
 ; return 0; }
 EOF
-if { (eval echo configure:72520: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:72456: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -72869,7 +72805,7 @@ else
   done
 
   echo $ac_n "checking for mysql_query in -l$PDO_MYSQL_LIBNAME""... $ac_c" 1>&6
-echo "configure:72873: checking for mysql_query in -l$PDO_MYSQL_LIBNAME" >&5
+echo "configure:72809: checking for mysql_query in -l$PDO_MYSQL_LIBNAME" >&5
 ac_lib_var=`echo $PDO_MYSQL_LIBNAME'_'mysql_query | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -72877,7 +72813,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$PDO_MYSQL_LIBNAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 72881 "configure"
+#line 72817 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -72888,7 +72824,7 @@ int main() {
 mysql_query()
 ; return 0; }
 EOF
-if { (eval echo configure:72892: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:72828: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -73043,7 +72979,7 @@ fi
   done
 
   echo $ac_n "checking for mysql_query in -l$PDO_MYSQL_LIBNAME""... $ac_c" 1>&6
-echo "configure:73047: checking for mysql_query in -l$PDO_MYSQL_LIBNAME" >&5
+echo "configure:72983: checking for mysql_query in -l$PDO_MYSQL_LIBNAME" >&5
 ac_lib_var=`echo $PDO_MYSQL_LIBNAME'_'mysql_query | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -73051,7 +72987,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$PDO_MYSQL_LIBNAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 73055 "configure"
+#line 72991 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -73062,7 +72998,7 @@ int main() {
 mysql_query()
 ; return 0; }
 EOF
-if { (eval echo configure:73066: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:73002: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -73235,12 +73171,12 @@ fi
   for ac_func in mysql_commit mysql_stmt_prepare mysql_next_result mysql_sqlstate
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:73239: checking for $ac_func" >&5
+echo "configure:73175: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 73244 "configure"
+#line 73180 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -73263,7 +73199,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:73267: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:73203: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -73292,13 +73228,13 @@ done
   
     
   echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:73296: checking for PDO includes" >&5
+echo "configure:73232: checking for PDO includes" >&5
 if eval "test \"`echo '$''{'pdo_inc_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:73302: checking for PDO includes" >&5
+echo "configure:73238: checking for PDO includes" >&5
     if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
       pdo_inc_path=$abs_srcdir/ext
     elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
@@ -73657,7 +73593,7 @@ if test "$PHP_PDO" != "no"; then
 php_with_pdo_oci=no
 
 echo $ac_n "checking Oracle OCI support for PDO""... $ac_c" 1>&6
-echo "configure:73661: checking Oracle OCI support for PDO" >&5
+echo "configure:73597: checking Oracle OCI support for PDO" >&5
 # Check whether --with-pdo-oci or --without-pdo-oci was given.
 if test "${with_pdo_oci+set}" = set; then
   withval="$with_pdo_oci"
@@ -73702,7 +73638,7 @@ echo "$ac_t""$ext_output" 1>&6
 
 if test "$PHP_PDO_OCI" != "no"; then
   echo $ac_n "checking Oracle Install-Dir""... $ac_c" 1>&6
-echo "configure:73706: checking Oracle Install-Dir" >&5
+echo "configure:73642: checking Oracle Install-Dir" >&5
   if test "$PHP_PDO_OCI" = "yes" || test -z "$PHP_PDO_OCI"; then
     PDO_OCI_DIR=$ORACLE_HOME
   else
@@ -73711,7 +73647,7 @@ echo "configure:73706: checking Oracle Install-Dir" >&5
   echo "$ac_t""$PHP_PDO_OCI" 1>&6
 
   echo $ac_n "checking if that is sane""... $ac_c" 1>&6
-echo "configure:73715: checking if that is sane" >&5
+echo "configure:73651: checking if that is sane" >&5
   if test -z "$PDO_OCI_DIR"; then
     { echo "configure: error: 
 You need to tell me where to find your Oracle Instant Client SDK, or set ORACLE_HOME.
@@ -73724,7 +73660,7 @@ You need to tell me where to find your Oracle Instant Client SDK, or set ORACLE_
     PDO_OCI_IC_PREFIX="`echo $PDO_OCI_DIR | cut -d, -f2`"
     PDO_OCI_IC_VERS="`echo $PDO_OCI_DIR | cut -d, -f3`"
     echo $ac_n "checking for oci.h""... $ac_c" 1>&6
-echo "configure:73728: checking for oci.h" >&5
+echo "configure:73664: checking for oci.h" >&5
     if test -f $PDO_OCI_IC_PREFIX/include/oracle/$PDO_OCI_IC_VERS/client/oci.h ; then
       
   if test "$PDO_OCI_IC_PREFIX/include/oracle/$PDO_OCI_IC_VERS/client" != "/usr/include"; then
@@ -73873,7 +73809,7 @@ echo "configure:73728: checking for oci.h" >&5
   else
     
   echo $ac_n "checking size of long int""... $ac_c" 1>&6
-echo "configure:73877: checking size of long int" >&5
+echo "configure:73813: checking size of long int" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long_int'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -73881,7 +73817,7 @@ else
   ac_cv_sizeof_long_int=4
 else
   cat > conftest.$ac_ext <<EOF
-#line 73885 "configure"
+#line 73821 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -73892,7 +73828,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:73896: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:73832: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long_int=`cat conftestval`
 else
@@ -73912,7 +73848,7 @@ EOF
 
 
   echo $ac_n "checking if we're on a 64-bit platform""... $ac_c" 1>&6
-echo "configure:73916: checking if we're on a 64-bit platform" >&5
+echo "configure:73852: checking if we're on a 64-bit platform" >&5
   if test "$ac_cv_sizeof_long_int" = "4" ; then
     echo "$ac_t""no" 1>&6
     TMP_PDO_OCI_LIB_DIR="$PDO_OCI_DIR/lib32"
@@ -73922,7 +73858,7 @@ echo "configure:73916: checking if we're on a 64-bit platform" >&5
   fi
 
   echo $ac_n "checking OCI8 libraries dir""... $ac_c" 1>&6
-echo "configure:73926: checking OCI8 libraries dir" >&5
+echo "configure:73862: checking OCI8 libraries dir" >&5
   if test -d "$PDO_OCI_DIR/lib" && test ! -d "$PDO_OCI_DIR/lib32"; then
     PDO_OCI_LIB_DIR="$PDO_OCI_DIR/lib"
   elif test ! -d "$PDO_OCI_DIR/lib" && test -d "$PDO_OCI_DIR/lib32"; then
@@ -74289,7 +74225,7 @@ echo "configure:73926: checking OCI8 libraries dir" >&5
     fi
     
   echo $ac_n "checking Oracle version""... $ac_c" 1>&6
-echo "configure:74293: checking Oracle version" >&5
+echo "configure:74229: checking Oracle version" >&5
   if test -s "$PDO_OCI_DIR/orainst/unix.rgs"; then
     PDO_OCI_VERSION=`grep '"ocommon"' $PDO_OCI_DIR/orainst/unix.rgs | sed 's/  */:/g' | cut -d: -f 6 | cut -c 2-4`
     test -z "$PDO_OCI_VERSION" && PDO_OCI_VERSION=7.3
@@ -74980,7 +74916,7 @@ echo "configure:74293: checking Oracle version" >&5
   done
 
   echo $ac_n "checking for OCIEnvCreate in -lclntsh""... $ac_c" 1>&6
-echo "configure:74984: checking for OCIEnvCreate in -lclntsh" >&5
+echo "configure:74920: checking for OCIEnvCreate in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCIEnvCreate | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -74988,7 +74924,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 74992 "configure"
+#line 74928 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -74999,7 +74935,7 @@ int main() {
 OCIEnvCreate()
 ; return 0; }
 EOF
-if { (eval echo configure:75003: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:74939: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -75133,7 +75069,7 @@ fi
   done
 
   echo $ac_n "checking for OCIEnvNlsCreate in -lclntsh""... $ac_c" 1>&6
-echo "configure:75137: checking for OCIEnvNlsCreate in -lclntsh" >&5
+echo "configure:75073: checking for OCIEnvNlsCreate in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCIEnvNlsCreate | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -75141,7 +75077,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 75145 "configure"
+#line 75081 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -75152,7 +75088,7 @@ int main() {
 OCIEnvNlsCreate()
 ; return 0; }
 EOF
-if { (eval echo configure:75156: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:75092: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -75286,7 +75222,7 @@ fi
   done
 
   echo $ac_n "checking for OCILobIsTemporary in -lclntsh""... $ac_c" 1>&6
-echo "configure:75290: checking for OCILobIsTemporary in -lclntsh" >&5
+echo "configure:75226: checking for OCILobIsTemporary in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCILobIsTemporary | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -75294,7 +75230,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 75298 "configure"
+#line 75234 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -75305,7 +75241,7 @@ int main() {
 OCILobIsTemporary()
 ; return 0; }
 EOF
-if { (eval echo configure:75309: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:75245: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -75435,7 +75371,7 @@ else
   done
 
   echo $ac_n "checking for OCILobIsTemporary in -locijdbc8""... $ac_c" 1>&6
-echo "configure:75439: checking for OCILobIsTemporary in -locijdbc8" >&5
+echo "configure:75375: checking for OCILobIsTemporary in -locijdbc8" >&5
 ac_lib_var=`echo ocijdbc8'_'OCILobIsTemporary | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -75443,7 +75379,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-locijdbc8  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 75447 "configure"
+#line 75383 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -75454,7 +75390,7 @@ int main() {
 OCILobIsTemporary()
 ; return 0; }
 EOF
-if { (eval echo configure:75458: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:75394: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -75615,7 +75551,7 @@ fi
   done
 
   echo $ac_n "checking for OCICollAssign in -lclntsh""... $ac_c" 1>&6
-echo "configure:75619: checking for OCICollAssign in -lclntsh" >&5
+echo "configure:75555: checking for OCICollAssign in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCICollAssign | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -75623,7 +75559,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 75627 "configure"
+#line 75563 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -75634,7 +75570,7 @@ int main() {
 OCICollAssign()
 ; return 0; }
 EOF
-if { (eval echo configure:75638: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:75574: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -75768,7 +75704,7 @@ fi
   done
 
   echo $ac_n "checking for OCIStmtFetch2 in -lclntsh""... $ac_c" 1>&6
-echo "configure:75772: checking for OCIStmtFetch2 in -lclntsh" >&5
+echo "configure:75708: checking for OCIStmtFetch2 in -lclntsh" >&5
 ac_lib_var=`echo clntsh'_'OCIStmtFetch2 | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -75776,7 +75712,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lclntsh  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 75780 "configure"
+#line 75716 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -75787,7 +75723,7 @@ int main() {
 OCIStmtFetch2()
 ; return 0; }
 EOF
-if { (eval echo configure:75791: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:75727: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -75826,13 +75762,13 @@ fi
   
     
   echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:75830: checking for PDO includes" >&5
+echo "configure:75766: checking for PDO includes" >&5
 if eval "test \"`echo '$''{'pdo_inc_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:75836: checking for PDO includes" >&5
+echo "configure:75772: checking for PDO includes" >&5
     if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
       pdo_inc_path=$abs_srcdir/ext
     elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
@@ -76203,7 +76139,7 @@ if test "$PHP_PDO" != "no"; then
 php_with_pdo_odbc=no
 
 echo $ac_n "checking for ODBC v3 support for PDO""... $ac_c" 1>&6
-echo "configure:76207: checking for ODBC v3 support for PDO" >&5
+echo "configure:76143: checking for ODBC v3 support for PDO" >&5
 # Check whether --with-pdo-odbc or --without-pdo-odbc was given.
 if test "${with_pdo_odbc+set}" = set; then
   withval="$with_pdo_odbc"
@@ -76254,13 +76190,13 @@ if test "$PHP_PDO_ODBC" != "no"; then
   
     
   echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:76258: checking for PDO includes" >&5
+echo "configure:76194: checking for PDO includes" >&5
 if eval "test \"`echo '$''{'pdo_inc_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:76264: checking for PDO includes" >&5
+echo "configure:76200: checking for PDO includes" >&5
     if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
       pdo_inc_path=$abs_srcdir/ext
     elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
@@ -76281,7 +76217,7 @@ echo "$ac_t""$pdo_inc_path" 1>&6
   
 
   echo $ac_n "checking for selected PDO ODBC flavour""... $ac_c" 1>&6
-echo "configure:76285: checking for selected PDO ODBC flavour" >&5
+echo "configure:76221: checking for selected PDO ODBC flavour" >&5
 
   pdo_odbc_flavour="`echo $PHP_PDO_ODBC | cut -d, -f1`"
   pdo_odbc_dir="`echo $PHP_PDO_ODBC | cut -d, -f2`"
@@ -76354,7 +76290,7 @@ echo "configure:76285: checking for selected PDO ODBC flavour" >&5
 
   
   echo $ac_n "checking for odbc.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76358: checking for odbc.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76294: checking for odbc.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/odbc.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76368,7 +76304,7 @@ EOF
 
   
   echo $ac_n "checking for odbcsdk.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76372: checking for odbcsdk.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76308: checking for odbcsdk.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/odbcsdk.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76382,7 +76318,7 @@ EOF
 
   
   echo $ac_n "checking for iodbc.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76386: checking for iodbc.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76322: checking for iodbc.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/iodbc.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76396,7 +76332,7 @@ EOF
 
   
   echo $ac_n "checking for sqlunix.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76400: checking for sqlunix.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76336: checking for sqlunix.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/sqlunix.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76410,7 +76346,7 @@ EOF
 
   
   echo $ac_n "checking for sqltypes.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76414: checking for sqltypes.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76350: checking for sqltypes.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/sqltypes.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76424,7 +76360,7 @@ EOF
 
   
   echo $ac_n "checking for sqlucode.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76428: checking for sqlucode.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76364: checking for sqlucode.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/sqlucode.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76438,7 +76374,7 @@ EOF
 
   
   echo $ac_n "checking for sql.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76442: checking for sql.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76378: checking for sql.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/sql.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76452,7 +76388,7 @@ EOF
 
   
   echo $ac_n "checking for isql.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76456: checking for isql.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76392: checking for isql.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/isql.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76466,7 +76402,7 @@ EOF
 
   
   echo $ac_n "checking for sqlext.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76470: checking for sqlext.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76406: checking for sqlext.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/sqlext.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76480,7 +76416,7 @@ EOF
 
   
   echo $ac_n "checking for isqlext.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76484: checking for isqlext.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76420: checking for isqlext.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/isqlext.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76494,7 +76430,7 @@ EOF
 
   
   echo $ac_n "checking for udbcext.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76498: checking for udbcext.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76434: checking for udbcext.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/udbcext.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76508,7 +76444,7 @@ EOF
 
   
   echo $ac_n "checking for sqlcli1.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76512: checking for sqlcli1.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76448: checking for sqlcli1.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/sqlcli1.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76522,7 +76458,7 @@ EOF
 
   
   echo $ac_n "checking for LibraryManager.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76526: checking for LibraryManager.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76462: checking for LibraryManager.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/LibraryManager.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76536,7 +76472,7 @@ EOF
 
   
   echo $ac_n "checking for cli0core.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76540: checking for cli0core.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76476: checking for cli0core.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/cli0core.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76550,7 +76486,7 @@ EOF
 
   
   echo $ac_n "checking for cli0ext.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76554: checking for cli0ext.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76490: checking for cli0ext.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/cli0ext.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76564,7 +76500,7 @@ EOF
 
   
   echo $ac_n "checking for cli0cli.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76568: checking for cli0cli.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76504: checking for cli0cli.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/cli0cli.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76578,7 +76514,7 @@ EOF
 
   
   echo $ac_n "checking for cli0defs.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76582: checking for cli0defs.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76518: checking for cli0defs.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/cli0defs.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76592,7 +76528,7 @@ EOF
 
   
   echo $ac_n "checking for cli0env.h in $PDO_ODBC_INCDIR""... $ac_c" 1>&6
-echo "configure:76596: checking for cli0env.h in $PDO_ODBC_INCDIR" >&5
+echo "configure:76532: checking for cli0env.h in $PDO_ODBC_INCDIR" >&5
   if test -f "$PDO_ODBC_INCDIR/cli0env.h"; then
     php_pdo_have_header=yes
     cat >> confdefs.h <<\EOF
@@ -76798,7 +76734,7 @@ EOF
   done
 
   echo $ac_n "checking for SQLBindCol in -l$pdo_odbc_def_lib""... $ac_c" 1>&6
-echo "configure:76802: checking for SQLBindCol in -l$pdo_odbc_def_lib" >&5
+echo "configure:76738: checking for SQLBindCol in -l$pdo_odbc_def_lib" >&5
 ac_lib_var=`echo $pdo_odbc_def_lib'_'SQLBindCol | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -76806,7 +76742,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$pdo_odbc_def_lib  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 76810 "configure"
+#line 76746 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -76817,7 +76753,7 @@ int main() {
 SQLBindCol()
 ; return 0; }
 EOF
-if { (eval echo configure:76821: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:76757: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -76932,7 +76868,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
   done
 
   echo $ac_n "checking for SQLAllocHandle in -l$pdo_odbc_def_lib""... $ac_c" 1>&6
-echo "configure:76936: checking for SQLAllocHandle in -l$pdo_odbc_def_lib" >&5
+echo "configure:76872: checking for SQLAllocHandle in -l$pdo_odbc_def_lib" >&5
 ac_lib_var=`echo $pdo_odbc_def_lib'_'SQLAllocHandle | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -76940,7 +76876,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$pdo_odbc_def_lib  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 76944 "configure"
+#line 76880 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -76951,7 +76887,7 @@ int main() {
 SQLAllocHandle()
 ; return 0; }
 EOF
-if { (eval echo configure:76955: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:76891: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -77329,7 +77265,7 @@ if test "$PHP_PDO" != "no"; then
 php_with_pdo_pgsql=no
 
 echo $ac_n "checking for PostgreSQL support for PDO""... $ac_c" 1>&6
-echo "configure:77333: checking for PostgreSQL support for PDO" >&5
+echo "configure:77269: checking for PostgreSQL support for PDO" >&5
 # Check whether --with-pdo-pgsql or --without-pdo-pgsql was given.
 if test "${with_pdo_pgsql+set}" = set; then
   withval="$with_pdo_pgsql"
@@ -77386,7 +77322,7 @@ if test "$PHP_PDO_PGSQL" != "no"; then
 
 
   echo $ac_n "checking for pg_config""... $ac_c" 1>&6
-echo "configure:77390: checking for pg_config" >&5
+echo "configure:77326: checking for pg_config" >&5
   for i in $PHP_PDO_PGSQL $PHP_PDO_PGSQL/bin /usr/local/pgsql/bin /usr/local/bin /usr/bin ""; do
     if test -x $i/pg_config; then
       PG_CONFIG="$i/pg_config"
@@ -77450,13 +77386,13 @@ EOF
 
 
   echo $ac_n "checking for openssl dependencies""... $ac_c" 1>&6
-echo "configure:77454: checking for openssl dependencies" >&5
+echo "configure:77390: checking for openssl dependencies" >&5
   if grep -q openssl $PGSQL_INCLUDE/libpq-fe.h ; then
     echo "$ac_t""yes" 1>&6
         # Extract the first word of "pkg-config", so it can be a program name with args.
 set dummy pkg-config; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:77460: checking for $ac_word" >&5
+echo "configure:77396: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_PKG_CONFIG'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -77500,7 +77436,7 @@ fi
   old_LDFLAGS=$LDFLAGS
   LDFLAGS="$LDFLAGS -L$PGSQL_LIBDIR"
   echo $ac_n "checking for PQescapeString in -lpq""... $ac_c" 1>&6
-echo "configure:77504: checking for PQescapeString in -lpq" >&5
+echo "configure:77440: checking for PQescapeString in -lpq" >&5
 ac_lib_var=`echo pq'_'PQescapeString | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -77508,7 +77444,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 77512 "configure"
+#line 77448 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -77519,7 +77455,7 @@ int main() {
 PQescapeString()
 ; return 0; }
 EOF
-if { (eval echo configure:77523: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:77459: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -77543,7 +77479,7 @@ else
 fi
 
   echo $ac_n "checking for PQescapeStringConn in -lpq""... $ac_c" 1>&6
-echo "configure:77547: checking for PQescapeStringConn in -lpq" >&5
+echo "configure:77483: checking for PQescapeStringConn in -lpq" >&5
 ac_lib_var=`echo pq'_'PQescapeStringConn | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -77551,7 +77487,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 77555 "configure"
+#line 77491 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -77562,7 +77498,7 @@ int main() {
 PQescapeStringConn()
 ; return 0; }
 EOF
-if { (eval echo configure:77566: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:77502: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -77586,7 +77522,7 @@ else
 fi
 
   echo $ac_n "checking for PQescapeByteaConn in -lpq""... $ac_c" 1>&6
-echo "configure:77590: checking for PQescapeByteaConn in -lpq" >&5
+echo "configure:77526: checking for PQescapeByteaConn in -lpq" >&5
 ac_lib_var=`echo pq'_'PQescapeByteaConn | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -77594,7 +77530,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 77598 "configure"
+#line 77534 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -77605,7 +77541,7 @@ int main() {
 PQescapeByteaConn()
 ; return 0; }
 EOF
-if { (eval echo configure:77609: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:77545: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -77629,7 +77565,7 @@ else
 fi
 
   echo $ac_n "checking for PQsetnonblocking in -lpq""... $ac_c" 1>&6
-echo "configure:77633: checking for PQsetnonblocking in -lpq" >&5
+echo "configure:77569: checking for PQsetnonblocking in -lpq" >&5
 ac_lib_var=`echo pq'_'PQsetnonblocking | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -77637,7 +77573,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 77641 "configure"
+#line 77577 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -77648,7 +77584,7 @@ int main() {
 PQsetnonblocking()
 ; return 0; }
 EOF
-if { (eval echo configure:77652: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:77588: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -77672,7 +77608,7 @@ else
 fi
 
   echo $ac_n "checking for PQcmdTuples in -lpq""... $ac_c" 1>&6
-echo "configure:77676: checking for PQcmdTuples in -lpq" >&5
+echo "configure:77612: checking for PQcmdTuples in -lpq" >&5
 ac_lib_var=`echo pq'_'PQcmdTuples | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -77680,7 +77616,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 77684 "configure"
+#line 77620 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -77691,7 +77627,7 @@ int main() {
 PQcmdTuples()
 ; return 0; }
 EOF
-if { (eval echo configure:77695: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:77631: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -77715,7 +77651,7 @@ else
 fi
 
   echo $ac_n "checking for PQoidValue in -lpq""... $ac_c" 1>&6
-echo "configure:77719: checking for PQoidValue in -lpq" >&5
+echo "configure:77655: checking for PQoidValue in -lpq" >&5
 ac_lib_var=`echo pq'_'PQoidValue | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -77723,7 +77659,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 77727 "configure"
+#line 77663 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -77734,7 +77670,7 @@ int main() {
 PQoidValue()
 ; return 0; }
 EOF
-if { (eval echo configure:77738: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:77674: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -77758,7 +77694,7 @@ else
 fi
 
   echo $ac_n "checking for PQclientEncoding in -lpq""... $ac_c" 1>&6
-echo "configure:77762: checking for PQclientEncoding in -lpq" >&5
+echo "configure:77698: checking for PQclientEncoding in -lpq" >&5
 ac_lib_var=`echo pq'_'PQclientEncoding | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -77766,7 +77702,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 77770 "configure"
+#line 77706 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -77777,7 +77713,7 @@ int main() {
 PQclientEncoding()
 ; return 0; }
 EOF
-if { (eval echo configure:77781: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:77717: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -77801,7 +77737,7 @@ else
 fi
 
   echo $ac_n "checking for PQparameterStatus in -lpq""... $ac_c" 1>&6
-echo "configure:77805: checking for PQparameterStatus in -lpq" >&5
+echo "configure:77741: checking for PQparameterStatus in -lpq" >&5
 ac_lib_var=`echo pq'_'PQparameterStatus | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -77809,7 +77745,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 77813 "configure"
+#line 77749 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -77820,7 +77756,7 @@ int main() {
 PQparameterStatus()
 ; return 0; }
 EOF
-if { (eval echo configure:77824: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:77760: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -77844,7 +77780,7 @@ else
 fi
 
   echo $ac_n "checking for PQprotocolVersion in -lpq""... $ac_c" 1>&6
-echo "configure:77848: checking for PQprotocolVersion in -lpq" >&5
+echo "configure:77784: checking for PQprotocolVersion in -lpq" >&5
 ac_lib_var=`echo pq'_'PQprotocolVersion | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -77852,7 +77788,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 77856 "configure"
+#line 77792 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -77863,7 +77799,7 @@ int main() {
 PQprotocolVersion()
 ; return 0; }
 EOF
-if { (eval echo configure:77867: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:77803: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -77887,7 +77823,7 @@ else
 fi
 
   echo $ac_n "checking for PQtransactionStatus in -lpq""... $ac_c" 1>&6
-echo "configure:77891: checking for PQtransactionStatus in -lpq" >&5
+echo "configure:77827: checking for PQtransactionStatus in -lpq" >&5
 ac_lib_var=`echo pq'_'PQtransactionStatus | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -77895,7 +77831,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 77899 "configure"
+#line 77835 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -77906,7 +77842,7 @@ int main() {
 PQtransactionStatus()
 ; return 0; }
 EOF
-if { (eval echo configure:77910: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:77846: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -77930,7 +77866,7 @@ else
 fi
 
   echo $ac_n "checking for PQunescapeBytea in -lpq""... $ac_c" 1>&6
-echo "configure:77934: checking for PQunescapeBytea in -lpq" >&5
+echo "configure:77870: checking for PQunescapeBytea in -lpq" >&5
 ac_lib_var=`echo pq'_'PQunescapeBytea | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -77938,7 +77874,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 77942 "configure"
+#line 77878 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -77949,7 +77885,7 @@ int main() {
 PQunescapeBytea()
 ; return 0; }
 EOF
-if { (eval echo configure:77953: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:77889: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -77973,7 +77909,7 @@ else
 fi
 
   echo $ac_n "checking for PQExecParams in -lpq""... $ac_c" 1>&6
-echo "configure:77977: checking for PQExecParams in -lpq" >&5
+echo "configure:77913: checking for PQExecParams in -lpq" >&5
 ac_lib_var=`echo pq'_'PQExecParams | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -77981,7 +77917,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 77985 "configure"
+#line 77921 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -77992,7 +77928,7 @@ int main() {
 PQExecParams()
 ; return 0; }
 EOF
-if { (eval echo configure:77996: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:77932: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -78016,7 +77952,7 @@ else
 fi
 
   echo $ac_n "checking for PQresultErrorField in -lpq""... $ac_c" 1>&6
-echo "configure:78020: checking for PQresultErrorField in -lpq" >&5
+echo "configure:77956: checking for PQresultErrorField in -lpq" >&5
 ac_lib_var=`echo pq'_'PQresultErrorField | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -78024,7 +77960,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 78028 "configure"
+#line 77964 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -78035,7 +77971,7 @@ int main() {
 PQresultErrorField()
 ; return 0; }
 EOF
-if { (eval echo configure:78039: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:77975: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -78059,7 +77995,7 @@ else
 fi
 
   echo $ac_n "checking for pg_encoding_to_char in -lpq""... $ac_c" 1>&6
-echo "configure:78063: checking for pg_encoding_to_char in -lpq" >&5
+echo "configure:77999: checking for pg_encoding_to_char in -lpq" >&5
 ac_lib_var=`echo pq'_'pg_encoding_to_char | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -78067,7 +78003,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 78071 "configure"
+#line 78007 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -78078,7 +78014,7 @@ int main() {
 pg_encoding_to_char()
 ; return 0; }
 EOF
-if { (eval echo configure:78082: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:78018: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -78103,7 +78039,7 @@ fi
 
   
   echo $ac_n "checking for PQprepare in -lpq""... $ac_c" 1>&6
-echo "configure:78107: checking for PQprepare in -lpq" >&5
+echo "configure:78043: checking for PQprepare in -lpq" >&5
 ac_lib_var=`echo pq'_'PQprepare | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -78111,7 +78047,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 78115 "configure"
+#line 78051 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -78122,7 +78058,7 @@ int main() {
 PQprepare()
 ; return 0; }
 EOF
-if { (eval echo configure:78126: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:78062: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -78285,13 +78221,13 @@ fi
   
     
   echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:78289: checking for PDO includes" >&5
+echo "configure:78225: checking for PDO includes" >&5
 if eval "test \"`echo '$''{'pdo_inc_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:78295: checking for PDO includes" >&5
+echo "configure:78231: checking for PDO includes" >&5
     if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
       pdo_inc_path=$abs_srcdir/ext
     elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
@@ -78635,7 +78571,7 @@ if test "$PHP_PDO" != "no"; then
 php_with_pdo_sqlite=yes
 
 echo $ac_n "checking for sqlite 3 support for PDO""... $ac_c" 1>&6
-echo "configure:78639: checking for sqlite 3 support for PDO" >&5
+echo "configure:78575: checking for sqlite 3 support for PDO" >&5
 # Check whether --with-pdo-sqlite or --without-pdo-sqlite was given.
 if test "${with_pdo_sqlite+set}" = set; then
   withval="$with_pdo_sqlite"
@@ -78683,13 +78619,13 @@ if test "$PHP_PDO_SQLITE" != "no"; then
   
     
   echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:78687: checking for PDO includes" >&5
+echo "configure:78623: checking for PDO includes" >&5
 if eval "test \"`echo '$''{'pdo_inc_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:78693: checking for PDO includes" >&5
+echo "configure:78629: checking for PDO includes" >&5
     if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
       pdo_inc_path=$abs_srcdir/ext
     elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
@@ -78718,7 +78654,7 @@ echo "$ac_t""$pdo_inc_path" 1>&6
       PDO_SQLITE_DIR=$PHP_PDO_SQLITE
     else # search default path list
       echo $ac_n "checking for sqlite3 files in default path""... $ac_c" 1>&6
-echo "configure:78722: checking for sqlite3 files in default path" >&5
+echo "configure:78658: checking for sqlite3 files in default path" >&5
       for i in $SEARCH_PATH ; do
         if test -r $i/$SEARCH_FOR; then
           PDO_SQLITE_DIR=$i
@@ -78864,7 +78800,7 @@ echo "configure:78722: checking for sqlite3 files in default path" >&5
   done
 
   echo $ac_n "checking for $LIBSYMBOL in -l$LIBNAME""... $ac_c" 1>&6
-echo "configure:78868: checking for $LIBSYMBOL in -l$LIBNAME" >&5
+echo "configure:78804: checking for $LIBSYMBOL in -l$LIBNAME" >&5
 ac_lib_var=`echo $LIBNAME'_'$LIBSYMBOL | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -78872,7 +78808,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$LIBNAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 78876 "configure"
+#line 78812 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -78883,7 +78819,7 @@ int main() {
 $LIBSYMBOL()
 ; return 0; }
 EOF
-if { (eval echo configure:78887: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:78823: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -79113,7 +79049,7 @@ fi
   done
 
   echo $ac_n "checking for sqlite3_key in -lsqlite3""... $ac_c" 1>&6
-echo "configure:79117: checking for sqlite3_key in -lsqlite3" >&5
+echo "configure:79053: checking for sqlite3_key in -lsqlite3" >&5
 ac_lib_var=`echo sqlite3'_'sqlite3_key | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -79121,7 +79057,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsqlite3  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 79125 "configure"
+#line 79061 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -79132,7 +79068,7 @@ int main() {
 sqlite3_key()
 ; return 0; }
 EOF
-if { (eval echo configure:79136: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:79072: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -79785,7 +79721,7 @@ EOF
   
 
       echo $ac_n "checking size of char *""... $ac_c" 1>&6
-echo "configure:79789: checking size of char *" >&5
+echo "configure:79725: checking size of char *" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_char_p'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -79793,7 +79729,7 @@ else
   ac_cv_sizeof_char_p=4
 else
   cat > conftest.$ac_ext <<EOF
-#line 79797 "configure"
+#line 79733 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -79804,7 +79740,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:79808: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:79744: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_char_p=`cat conftestval`
 else
@@ -79851,12 +79787,12 @@ EOF
       for ac_func in usleep nanosleep
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:79855: checking for $ac_func" >&5
+echo "configure:79791: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 79860 "configure"
+#line 79796 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -79879,7 +79815,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:79883: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:79819: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -79907,17 +79843,17 @@ done
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:79911: checking for $ac_hdr" >&5
+echo "configure:79847: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 79916 "configure"
+#line 79852 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:79921: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:79857: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -80041,7 +79977,7 @@ done
   done
 
   echo $ac_n "checking for fdatasync in -lrt""... $ac_c" 1>&6
-echo "configure:80045: checking for fdatasync in -lrt" >&5
+echo "configure:79981: checking for fdatasync in -lrt" >&5
 ac_lib_var=`echo rt'_'fdatasync | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80049,7 +79985,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lrt  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80053 "configure"
+#line 79989 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80060,7 +79996,7 @@ int main() {
 fdatasync()
 ; return 0; }
 EOF
-if { (eval echo configure:80064: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80000: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80143,7 +80079,7 @@ fi
 php_with_pgsql=no
 
 echo $ac_n "checking for PostgreSQL support""... $ac_c" 1>&6
-echo "configure:80147: checking for PostgreSQL support" >&5
+echo "configure:80083: checking for PostgreSQL support" >&5
 # Check whether --with-pgsql or --without-pgsql was given.
 if test "${with_pgsql+set}" = set; then
   withval="$with_pgsql"
@@ -80200,7 +80136,7 @@ if test "$PHP_PGSQL" != "no"; then
 
 
   echo $ac_n "checking for pg_config""... $ac_c" 1>&6
-echo "configure:80204: checking for pg_config" >&5
+echo "configure:80140: checking for pg_config" >&5
   for i in $PHP_PGSQL $PHP_PGSQL/bin /usr/local/pgsql/bin /usr/local/bin /usr/bin ""; do
 	if test -x $i/pg_config; then
       PG_CONFIG="$i/pg_config"
@@ -80268,7 +80204,7 @@ EOF
   old_LDFLAGS=$LDFLAGS
   LDFLAGS="$LDFLAGS -L$PGSQL_LIBDIR"
   echo $ac_n "checking for PQescapeString in -lpq""... $ac_c" 1>&6
-echo "configure:80272: checking for PQescapeString in -lpq" >&5
+echo "configure:80208: checking for PQescapeString in -lpq" >&5
 ac_lib_var=`echo pq'_'PQescapeString | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80276,7 +80212,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80280 "configure"
+#line 80216 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80287,7 +80223,7 @@ int main() {
 PQescapeString()
 ; return 0; }
 EOF
-if { (eval echo configure:80291: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80227: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80311,7 +80247,7 @@ else
 fi
 
   echo $ac_n "checking for PQunescapeBytea in -lpq""... $ac_c" 1>&6
-echo "configure:80315: checking for PQunescapeBytea in -lpq" >&5
+echo "configure:80251: checking for PQunescapeBytea in -lpq" >&5
 ac_lib_var=`echo pq'_'PQunescapeBytea | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80319,7 +80255,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80323 "configure"
+#line 80259 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80330,7 +80266,7 @@ int main() {
 PQunescapeBytea()
 ; return 0; }
 EOF
-if { (eval echo configure:80334: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80270: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80354,7 +80290,7 @@ else
 fi
 
   echo $ac_n "checking for PQsetnonblocking in -lpq""... $ac_c" 1>&6
-echo "configure:80358: checking for PQsetnonblocking in -lpq" >&5
+echo "configure:80294: checking for PQsetnonblocking in -lpq" >&5
 ac_lib_var=`echo pq'_'PQsetnonblocking | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80362,7 +80298,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80366 "configure"
+#line 80302 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80373,7 +80309,7 @@ int main() {
 PQsetnonblocking()
 ; return 0; }
 EOF
-if { (eval echo configure:80377: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80313: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80397,7 +80333,7 @@ else
 fi
 
   echo $ac_n "checking for PQcmdTuples in -lpq""... $ac_c" 1>&6
-echo "configure:80401: checking for PQcmdTuples in -lpq" >&5
+echo "configure:80337: checking for PQcmdTuples in -lpq" >&5
 ac_lib_var=`echo pq'_'PQcmdTuples | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80405,7 +80341,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80409 "configure"
+#line 80345 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80416,7 +80352,7 @@ int main() {
 PQcmdTuples()
 ; return 0; }
 EOF
-if { (eval echo configure:80420: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80356: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80440,7 +80376,7 @@ else
 fi
 
   echo $ac_n "checking for PQoidValue in -lpq""... $ac_c" 1>&6
-echo "configure:80444: checking for PQoidValue in -lpq" >&5
+echo "configure:80380: checking for PQoidValue in -lpq" >&5
 ac_lib_var=`echo pq'_'PQoidValue | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80448,7 +80384,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80452 "configure"
+#line 80388 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80459,7 +80395,7 @@ int main() {
 PQoidValue()
 ; return 0; }
 EOF
-if { (eval echo configure:80463: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80399: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80483,7 +80419,7 @@ else
 fi
 
   echo $ac_n "checking for PQclientEncoding in -lpq""... $ac_c" 1>&6
-echo "configure:80487: checking for PQclientEncoding in -lpq" >&5
+echo "configure:80423: checking for PQclientEncoding in -lpq" >&5
 ac_lib_var=`echo pq'_'PQclientEncoding | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80491,7 +80427,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80495 "configure"
+#line 80431 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80502,7 +80438,7 @@ int main() {
 PQclientEncoding()
 ; return 0; }
 EOF
-if { (eval echo configure:80506: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80442: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80526,7 +80462,7 @@ else
 fi
 
   echo $ac_n "checking for PQparameterStatus in -lpq""... $ac_c" 1>&6
-echo "configure:80530: checking for PQparameterStatus in -lpq" >&5
+echo "configure:80466: checking for PQparameterStatus in -lpq" >&5
 ac_lib_var=`echo pq'_'PQparameterStatus | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80534,7 +80470,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80538 "configure"
+#line 80474 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80545,7 +80481,7 @@ int main() {
 PQparameterStatus()
 ; return 0; }
 EOF
-if { (eval echo configure:80549: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80485: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80569,7 +80505,7 @@ else
 fi
 
   echo $ac_n "checking for PQprotocolVersion in -lpq""... $ac_c" 1>&6
-echo "configure:80573: checking for PQprotocolVersion in -lpq" >&5
+echo "configure:80509: checking for PQprotocolVersion in -lpq" >&5
 ac_lib_var=`echo pq'_'PQprotocolVersion | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80577,7 +80513,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80581 "configure"
+#line 80517 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80588,7 +80524,7 @@ int main() {
 PQprotocolVersion()
 ; return 0; }
 EOF
-if { (eval echo configure:80592: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80528: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80612,7 +80548,7 @@ else
 fi
 
   echo $ac_n "checking for PQtransactionStatus in -lpq""... $ac_c" 1>&6
-echo "configure:80616: checking for PQtransactionStatus in -lpq" >&5
+echo "configure:80552: checking for PQtransactionStatus in -lpq" >&5
 ac_lib_var=`echo pq'_'PQtransactionStatus | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80620,7 +80556,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80624 "configure"
+#line 80560 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80631,7 +80567,7 @@ int main() {
 PQtransactionStatus()
 ; return 0; }
 EOF
-if { (eval echo configure:80635: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80571: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80655,7 +80591,7 @@ else
 fi
 
   echo $ac_n "checking for PQexecParams in -lpq""... $ac_c" 1>&6
-echo "configure:80659: checking for PQexecParams in -lpq" >&5
+echo "configure:80595: checking for PQexecParams in -lpq" >&5
 ac_lib_var=`echo pq'_'PQexecParams | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80663,7 +80599,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80667 "configure"
+#line 80603 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80674,7 +80610,7 @@ int main() {
 PQexecParams()
 ; return 0; }
 EOF
-if { (eval echo configure:80678: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80614: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80698,7 +80634,7 @@ else
 fi
 
   echo $ac_n "checking for PQprepare in -lpq""... $ac_c" 1>&6
-echo "configure:80702: checking for PQprepare in -lpq" >&5
+echo "configure:80638: checking for PQprepare in -lpq" >&5
 ac_lib_var=`echo pq'_'PQprepare | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80706,7 +80642,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80710 "configure"
+#line 80646 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80717,7 +80653,7 @@ int main() {
 PQprepare()
 ; return 0; }
 EOF
-if { (eval echo configure:80721: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80657: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80741,7 +80677,7 @@ else
 fi
 
   echo $ac_n "checking for PQexecPrepared in -lpq""... $ac_c" 1>&6
-echo "configure:80745: checking for PQexecPrepared in -lpq" >&5
+echo "configure:80681: checking for PQexecPrepared in -lpq" >&5
 ac_lib_var=`echo pq'_'PQexecPrepared | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80749,7 +80685,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80753 "configure"
+#line 80689 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80760,7 +80696,7 @@ int main() {
 PQexecPrepared()
 ; return 0; }
 EOF
-if { (eval echo configure:80764: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80700: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80784,7 +80720,7 @@ else
 fi
 
   echo $ac_n "checking for PQresultErrorField in -lpq""... $ac_c" 1>&6
-echo "configure:80788: checking for PQresultErrorField in -lpq" >&5
+echo "configure:80724: checking for PQresultErrorField in -lpq" >&5
 ac_lib_var=`echo pq'_'PQresultErrorField | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80792,7 +80728,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80796 "configure"
+#line 80732 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80803,7 +80739,7 @@ int main() {
 PQresultErrorField()
 ; return 0; }
 EOF
-if { (eval echo configure:80807: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80743: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80827,7 +80763,7 @@ else
 fi
 
   echo $ac_n "checking for PQsendQueryParams in -lpq""... $ac_c" 1>&6
-echo "configure:80831: checking for PQsendQueryParams in -lpq" >&5
+echo "configure:80767: checking for PQsendQueryParams in -lpq" >&5
 ac_lib_var=`echo pq'_'PQsendQueryParams | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80835,7 +80771,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80839 "configure"
+#line 80775 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80846,7 +80782,7 @@ int main() {
 PQsendQueryParams()
 ; return 0; }
 EOF
-if { (eval echo configure:80850: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80786: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80870,7 +80806,7 @@ else
 fi
 
   echo $ac_n "checking for PQsendPrepare in -lpq""... $ac_c" 1>&6
-echo "configure:80874: checking for PQsendPrepare in -lpq" >&5
+echo "configure:80810: checking for PQsendPrepare in -lpq" >&5
 ac_lib_var=`echo pq'_'PQsendPrepare | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80878,7 +80814,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80882 "configure"
+#line 80818 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80889,7 +80825,7 @@ int main() {
 PQsendPrepare()
 ; return 0; }
 EOF
-if { (eval echo configure:80893: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80829: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80913,7 +80849,7 @@ else
 fi
 
   echo $ac_n "checking for PQsendQueryPrepared in -lpq""... $ac_c" 1>&6
-echo "configure:80917: checking for PQsendQueryPrepared in -lpq" >&5
+echo "configure:80853: checking for PQsendQueryPrepared in -lpq" >&5
 ac_lib_var=`echo pq'_'PQsendQueryPrepared | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80921,7 +80857,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80925 "configure"
+#line 80861 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80932,7 +80868,7 @@ int main() {
 PQsendQueryPrepared()
 ; return 0; }
 EOF
-if { (eval echo configure:80936: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80872: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80956,7 +80892,7 @@ else
 fi
 
   echo $ac_n "checking for PQputCopyData in -lpq""... $ac_c" 1>&6
-echo "configure:80960: checking for PQputCopyData in -lpq" >&5
+echo "configure:80896: checking for PQputCopyData in -lpq" >&5
 ac_lib_var=`echo pq'_'PQputCopyData | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -80964,7 +80900,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 80968 "configure"
+#line 80904 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -80975,7 +80911,7 @@ int main() {
 PQputCopyData()
 ; return 0; }
 EOF
-if { (eval echo configure:80979: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80915: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -80999,7 +80935,7 @@ else
 fi
 
   echo $ac_n "checking for PQputCopyEnd in -lpq""... $ac_c" 1>&6
-echo "configure:81003: checking for PQputCopyEnd in -lpq" >&5
+echo "configure:80939: checking for PQputCopyEnd in -lpq" >&5
 ac_lib_var=`echo pq'_'PQputCopyEnd | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -81007,7 +80943,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 81011 "configure"
+#line 80947 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -81018,7 +80954,7 @@ int main() {
 PQputCopyEnd()
 ; return 0; }
 EOF
-if { (eval echo configure:81022: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:80958: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -81042,7 +80978,7 @@ else
 fi
 
   echo $ac_n "checking for PQgetCopyData in -lpq""... $ac_c" 1>&6
-echo "configure:81046: checking for PQgetCopyData in -lpq" >&5
+echo "configure:80982: checking for PQgetCopyData in -lpq" >&5
 ac_lib_var=`echo pq'_'PQgetCopyData | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -81050,7 +80986,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 81054 "configure"
+#line 80990 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -81061,7 +80997,7 @@ int main() {
 PQgetCopyData()
 ; return 0; }
 EOF
-if { (eval echo configure:81065: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:81001: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -81085,7 +81021,7 @@ else
 fi
 
   echo $ac_n "checking for PQfreemem in -lpq""... $ac_c" 1>&6
-echo "configure:81089: checking for PQfreemem in -lpq" >&5
+echo "configure:81025: checking for PQfreemem in -lpq" >&5
 ac_lib_var=`echo pq'_'PQfreemem | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -81093,7 +81029,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 81097 "configure"
+#line 81033 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -81104,7 +81040,7 @@ int main() {
 PQfreemem()
 ; return 0; }
 EOF
-if { (eval echo configure:81108: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:81044: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -81128,7 +81064,7 @@ else
 fi
 
   echo $ac_n "checking for PQsetErrorVerbosity in -lpq""... $ac_c" 1>&6
-echo "configure:81132: checking for PQsetErrorVerbosity in -lpq" >&5
+echo "configure:81068: checking for PQsetErrorVerbosity in -lpq" >&5
 ac_lib_var=`echo pq'_'PQsetErrorVerbosity | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -81136,7 +81072,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 81140 "configure"
+#line 81076 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -81147,7 +81083,7 @@ int main() {
 PQsetErrorVerbosity()
 ; return 0; }
 EOF
-if { (eval echo configure:81151: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:81087: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -81171,7 +81107,7 @@ else
 fi
 
   echo $ac_n "checking for PQftable in -lpq""... $ac_c" 1>&6
-echo "configure:81175: checking for PQftable in -lpq" >&5
+echo "configure:81111: checking for PQftable in -lpq" >&5
 ac_lib_var=`echo pq'_'PQftable | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -81179,7 +81115,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 81183 "configure"
+#line 81119 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -81190,7 +81126,7 @@ int main() {
 PQftable()
 ; return 0; }
 EOF
-if { (eval echo configure:81194: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:81130: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -81214,7 +81150,7 @@ else
 fi
 
   echo $ac_n "checking for PQescapeStringConn in -lpq""... $ac_c" 1>&6
-echo "configure:81218: checking for PQescapeStringConn in -lpq" >&5
+echo "configure:81154: checking for PQescapeStringConn in -lpq" >&5
 ac_lib_var=`echo pq'_'PQescapeStringConn | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -81222,7 +81158,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 81226 "configure"
+#line 81162 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -81233,7 +81169,7 @@ int main() {
 PQescapeStringConn()
 ; return 0; }
 EOF
-if { (eval echo configure:81237: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:81173: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -81257,7 +81193,7 @@ else
 fi
 
   echo $ac_n "checking for PQescapeByteaConn in -lpq""... $ac_c" 1>&6
-echo "configure:81261: checking for PQescapeByteaConn in -lpq" >&5
+echo "configure:81197: checking for PQescapeByteaConn in -lpq" >&5
 ac_lib_var=`echo pq'_'PQescapeByteaConn | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -81265,7 +81201,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 81269 "configure"
+#line 81205 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -81276,7 +81212,7 @@ int main() {
 PQescapeByteaConn()
 ; return 0; }
 EOF
-if { (eval echo configure:81280: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:81216: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -81300,7 +81236,7 @@ else
 fi
 
   echo $ac_n "checking for pg_encoding_to_char in -lpq""... $ac_c" 1>&6
-echo "configure:81304: checking for pg_encoding_to_char in -lpq" >&5
+echo "configure:81240: checking for pg_encoding_to_char in -lpq" >&5
 ac_lib_var=`echo pq'_'pg_encoding_to_char | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -81308,7 +81244,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lpq  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 81312 "configure"
+#line 81248 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -81319,7 +81255,7 @@ int main() {
 pg_encoding_to_char()
 ; return 0; }
 EOF
-if { (eval echo configure:81323: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:81259: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -81779,7 +81715,7 @@ fi
 php_enable_posix=yes
 
 echo $ac_n "checking whether to enable POSIX-like functions""... $ac_c" 1>&6
-echo "configure:81783: checking whether to enable POSIX-like functions" >&5
+echo "configure:81719: checking whether to enable POSIX-like functions" >&5
 # Check whether --enable-posix or --disable-posix was given.
 if test "${enable_posix+set}" = set; then
   enableval="$enable_posix"
@@ -82124,17 +82060,17 @@ EOF
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:82128: checking for $ac_hdr" >&5
+echo "configure:82064: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 82133 "configure"
+#line 82069 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:82138: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:82074: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -82164,12 +82100,12 @@ done
   for ac_func in seteuid setegid setsid getsid setpgid getpgid ctermid mkfifo mknod getrlimit getlogin getgroups makedev initgroups getpwuid_r getgrgid_r
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:82168: checking for $ac_func" >&5
+echo "configure:82104: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 82173 "configure"
+#line 82109 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -82192,7 +82128,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:82196: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:82132: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -82218,14 +82154,14 @@ done
 
 
   echo $ac_n "checking for working ttyname_r() implementation""... $ac_c" 1>&6
-echo "configure:82222: checking for working ttyname_r() implementation" >&5
+echo "configure:82158: checking for working ttyname_r() implementation" >&5
   if test "$cross_compiling" = yes; then
   
     echo "$ac_t""no, cannot detect working ttyname_r() when cross compiling. posix_ttyname() will be thread-unsafe" 1>&6
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 82229 "configure"
+#line 82165 "configure"
 #include "confdefs.h"
 
 #include <unistd.h>
@@ -82238,7 +82174,7 @@ int main(int argc, char *argv[])
 }
   
 EOF
-if { (eval echo configure:82242: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:82178: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     echo "$ac_t""yes" 1>&6
@@ -82260,13 +82196,13 @@ fi
 
 
   echo $ac_n "checking for utsname.domainname""... $ac_c" 1>&6
-echo "configure:82264: checking for utsname.domainname" >&5
+echo "configure:82200: checking for utsname.domainname" >&5
 if eval "test \"`echo '$''{'ac_cv_have_utsname_domainname'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     cat > conftest.$ac_ext <<EOF
-#line 82270 "configure"
+#line 82206 "configure"
 #include "confdefs.h"
 
       #define _GNU_SOURCE
@@ -82278,7 +82214,7 @@ int main() {
     
 ; return 0; }
 EOF
-if { (eval echo configure:82282: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:82218: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
       ac_cv_have_utsname_domainname=yes
@@ -82309,7 +82245,7 @@ fi
 php_with_pspell=no
 
 echo $ac_n "checking for PSPELL support""... $ac_c" 1>&6
-echo "configure:82313: checking for PSPELL support" >&5
+echo "configure:82249: checking for PSPELL support" >&5
 # Check whether --with-pspell or --without-pspell was given.
 if test "${with_pspell+set}" = set; then
   withval="$with_pspell"
@@ -82862,7 +82798,7 @@ EOF
   done
 
   echo $ac_n "checking for new_aspell_config in -laspell""... $ac_c" 1>&6
-echo "configure:82866: checking for new_aspell_config in -laspell" >&5
+echo "configure:82802: checking for new_aspell_config in -laspell" >&5
 ac_lib_var=`echo aspell'_'new_aspell_config | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -82870,7 +82806,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-laspell  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 82874 "configure"
+#line 82810 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -82881,7 +82817,7 @@ int main() {
 new_aspell_config()
 ; return 0; }
 EOF
-if { (eval echo configure:82885: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:82821: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -83055,7 +82991,7 @@ fi
 php_with_libedit=no
 
 echo $ac_n "checking for libedit readline replacement""... $ac_c" 1>&6
-echo "configure:83059: checking for libedit readline replacement" >&5
+echo "configure:82995: checking for libedit readline replacement" >&5
 # Check whether --with-libedit or --without-libedit was given.
 if test "${with_libedit+set}" = set; then
   withval="$with_libedit"
@@ -83103,7 +83039,7 @@ if test "$PHP_LIBEDIT" = "no"; then
 php_with_readline=no
 
 echo $ac_n "checking for readline support""... $ac_c" 1>&6
-echo "configure:83107: checking for readline support" >&5
+echo "configure:83043: checking for readline support" >&5
 # Check whether --with-readline or --without-readline was given.
 if test "${with_readline+set}" = set; then
   withval="$with_readline"
@@ -83192,7 +83128,7 @@ if test "$PHP_READLINE" && test "$PHP_READLINE" != "no"; then
 
   PHP_READLINE_LIBS=""
   echo $ac_n "checking for tgetent in -lncurses""... $ac_c" 1>&6
-echo "configure:83196: checking for tgetent in -lncurses" >&5
+echo "configure:83132: checking for tgetent in -lncurses" >&5
 ac_lib_var=`echo ncurses'_'tgetent | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -83200,7 +83136,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lncurses  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 83204 "configure"
+#line 83140 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -83211,7 +83147,7 @@ int main() {
 tgetent()
 ; return 0; }
 EOF
-if { (eval echo configure:83215: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:83151: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -83256,7 +83192,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for tgetent in -ltermcap""... $ac_c" 1>&6
-echo "configure:83260: checking for tgetent in -ltermcap" >&5
+echo "configure:83196: checking for tgetent in -ltermcap" >&5
 ac_lib_var=`echo termcap'_'tgetent | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -83264,7 +83200,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ltermcap  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 83268 "configure"
+#line 83204 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -83275,7 +83211,7 @@ int main() {
 tgetent()
 ; return 0; }
 EOF
-if { (eval echo configure:83279: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:83215: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -83422,7 +83358,7 @@ fi
   done
 
   echo $ac_n "checking for readline in -lreadline""... $ac_c" 1>&6
-echo "configure:83426: checking for readline in -lreadline" >&5
+echo "configure:83362: checking for readline in -lreadline" >&5
 ac_lib_var=`echo readline'_'readline | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -83430,7 +83366,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lreadline  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 83434 "configure"
+#line 83370 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -83441,7 +83377,7 @@ int main() {
 readline()
 ; return 0; }
 EOF
-if { (eval echo configure:83445: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:83381: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -83670,7 +83606,7 @@ fi
   done
 
   echo $ac_n "checking for rl_pending_input in -lreadline""... $ac_c" 1>&6
-echo "configure:83674: checking for rl_pending_input in -lreadline" >&5
+echo "configure:83610: checking for rl_pending_input in -lreadline" >&5
 ac_lib_var=`echo readline'_'rl_pending_input | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -83678,7 +83614,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lreadline  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 83682 "configure"
+#line 83618 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -83689,7 +83625,7 @@ int main() {
 rl_pending_input()
 ; return 0; }
 EOF
-if { (eval echo configure:83693: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:83629: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -83820,7 +83756,7 @@ fi
   done
 
   echo $ac_n "checking for rl_callback_read_char in -lreadline""... $ac_c" 1>&6
-echo "configure:83824: checking for rl_callback_read_char in -lreadline" >&5
+echo "configure:83760: checking for rl_callback_read_char in -lreadline" >&5
 ac_lib_var=`echo readline'_'rl_callback_read_char | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -83828,7 +83764,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lreadline  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 83832 "configure"
+#line 83768 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -83839,7 +83775,7 @@ int main() {
 rl_callback_read_char()
 ; return 0; }
 EOF
-if { (eval echo configure:83843: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:83779: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -83883,7 +83819,7 @@ EOF
 elif test "$PHP_LIBEDIT" != "no"; then
 
   for i in $PHP_LIBEDIT /usr/local /usr; do
-    test -f $i/include/readline/readline.h && LIBEDIT_DIR=$i && break
+    test -f $i/include/editline/readline.h && LIBEDIT_DIR=$i && break
   done
 
   if test -z "$LIBEDIT_DIR"; then
@@ -83923,7 +83859,7 @@ elif test "$PHP_LIBEDIT" != "no"; then
 
 
   echo $ac_n "checking for tgetent in -lncurses""... $ac_c" 1>&6
-echo "configure:83927: checking for tgetent in -lncurses" >&5
+echo "configure:83863: checking for tgetent in -lncurses" >&5
 ac_lib_var=`echo ncurses'_'tgetent | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -83931,7 +83867,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lncurses  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 83935 "configure"
+#line 83871 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -83942,7 +83878,7 @@ int main() {
 tgetent()
 ; return 0; }
 EOF
-if { (eval echo configure:83946: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:83882: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -83986,7 +83922,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for tgetent in -ltermcap""... $ac_c" 1>&6
-echo "configure:83990: checking for tgetent in -ltermcap" >&5
+echo "configure:83926: checking for tgetent in -ltermcap" >&5
 ac_lib_var=`echo termcap'_'tgetent | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -83994,7 +83930,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ltermcap  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 83998 "configure"
+#line 83934 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -84005,7 +83941,7 @@ int main() {
 tgetent()
 ; return 0; }
 EOF
-if { (eval echo configure:84009: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:83945: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -84151,7 +84087,7 @@ fi
   done
 
   echo $ac_n "checking for readline in -ledit""... $ac_c" 1>&6
-echo "configure:84155: checking for readline in -ledit" >&5
+echo "configure:84091: checking for readline in -ledit" >&5
 ac_lib_var=`echo edit'_'readline | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -84159,7 +84095,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ledit  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 84163 "configure"
+#line 84099 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -84170,7 +84106,7 @@ int main() {
 readline()
 ; return 0; }
 EOF
-if { (eval echo configure:84174: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:84110: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -84311,12 +84247,12 @@ if test "$PHP_READLINE" != "no" || test "$PHP_LIBEDIT" != "no"; then
   for ac_func in rl_completion_matches
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:84315: checking for $ac_func" >&5
+echo "configure:84251: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 84320 "configure"
+#line 84256 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -84339,7 +84275,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:84343: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:84279: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -84665,7 +84601,7 @@ fi
 php_with_recode=no
 
 echo $ac_n "checking for recode support""... $ac_c" 1>&6
-echo "configure:84669: checking for recode support" >&5
+echo "configure:84605: checking for recode support" >&5
 # Check whether --with-recode or --without-recode was given.
 if test "${with_recode+set}" = set; then
   withval="$with_recode"
@@ -84832,7 +84768,7 @@ if test "$PHP_RECODE" != "no"; then
   done
 
   echo $ac_n "checking for recode_format_table in -lrecode""... $ac_c" 1>&6
-echo "configure:84836: checking for recode_format_table in -lrecode" >&5
+echo "configure:84772: checking for recode_format_table in -lrecode" >&5
 ac_lib_var=`echo recode'_'recode_format_table | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -84840,7 +84776,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lrecode  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 84844 "configure"
+#line 84780 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -84851,7 +84787,7 @@ int main() {
 recode_format_table()
 ; return 0; }
 EOF
-if { (eval echo configure:84855: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:84791: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -84981,7 +84917,7 @@ else
     LDFLAGS="$LDFLAGS -L$RECODE_DIR/$RECODE_LIB"
     LIBS="$LIBS -lrecode"
     cat > conftest.$ac_ext <<EOF
-#line 84985 "configure"
+#line 84921 "configure"
 #include "confdefs.h"
 
 char *program_name;
@@ -84992,7 +84928,7 @@ recode_format_table();
     
 ; return 0; }
 EOF
-if { (eval echo configure:84996: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:84932: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   
       
@@ -85155,17 +85091,17 @@ EOF
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:85159: checking for $ac_hdr" >&5
+echo "configure:85095: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 85164 "configure"
+#line 85100 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:85169: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:85105: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -85490,7 +85426,7 @@ fi
 php_enable_reflection=yes
 
 echo $ac_n "checking whether to enable reflection support""... $ac_c" 1>&6
-echo "configure:85494: checking whether to enable reflection support" >&5
+echo "configure:85430: checking whether to enable reflection support" >&5
 # Check whether --enable-reflection or --disable-reflection was given.
 if test "${enable_reflection+set}" = set; then
   enableval="$enable_reflection"
@@ -85816,7 +85752,7 @@ fi
 php_enable_session=yes
 
 echo $ac_n "checking whether to enable PHP sessions""... $ac_c" 1>&6
-echo "configure:85820: checking whether to enable PHP sessions" >&5
+echo "configure:85756: checking whether to enable PHP sessions" >&5
 # Check whether --enable-session or --disable-session was given.
 if test "${enable_session+set}" = set; then
   enableval="$enable_session"
@@ -85863,7 +85799,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_mm=no
 
 echo $ac_n "checking for mm support""... $ac_c" 1>&6
-echo "configure:85867: checking for mm support" >&5
+echo "configure:85803: checking for mm support" >&5
 # Check whether --with-mm or --without-mm was given.
 if test "${with_mm+set}" = set; then
   withval="$with_mm"
@@ -85888,7 +85824,7 @@ echo "$ac_t""$ext_output" 1>&6
 if test "$PHP_SESSION" != "no"; then
   
   echo $ac_n "checking whether pwrite works""... $ac_c" 1>&6
-echo "configure:85892: checking whether pwrite works" >&5
+echo "configure:85828: checking whether pwrite works" >&5
 if eval "test \"`echo '$''{'ac_cv_pwrite'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -85900,7 +85836,7 @@ else
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 85904 "configure"
+#line 85840 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -85921,7 +85857,7 @@ else
 
   
 EOF
-if { (eval echo configure:85925: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:85861: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     ac_cv_pwrite=yes
@@ -85946,7 +85882,7 @@ fi
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 85950 "configure"
+#line 85886 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -85967,7 +85903,7 @@ ssize_t pwrite(int, void *, size_t, off64_t);
 
   
 EOF
-if { (eval echo configure:85971: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:85907: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     ac_cv_pwrite=yes
@@ -86008,7 +85944,7 @@ EOF
 
   
   echo $ac_n "checking whether pread works""... $ac_c" 1>&6
-echo "configure:86012: checking whether pread works" >&5
+echo "configure:85948: checking whether pread works" >&5
 if eval "test \"`echo '$''{'ac_cv_pread'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -86021,7 +85957,7 @@ else
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 86025 "configure"
+#line 85961 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -86041,7 +85977,7 @@ else
     }
   
 EOF
-if { (eval echo configure:86045: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:85981: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     ac_cv_pread=yes
@@ -86068,7 +86004,7 @@ fi
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 86072 "configure"
+#line 86008 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -86088,7 +86024,7 @@ ssize_t pread(int, void *, size_t, off64_t);
     }
   
 EOF
-if { (eval echo configure:86092: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:86028: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     ac_cv_pread=yes
@@ -86633,7 +86569,7 @@ fi
 php_enable_shmop=no
 
 echo $ac_n "checking whether to enable shmop support""... $ac_c" 1>&6
-echo "configure:86637: checking whether to enable shmop support" >&5
+echo "configure:86573: checking whether to enable shmop support" >&5
 # Check whether --enable-shmop or --disable-shmop was given.
 if test "${enable_shmop+set}" = set; then
   enableval="$enable_shmop"
@@ -86980,7 +86916,7 @@ fi
 php_enable_simplexml=yes
 
 echo $ac_n "checking whether to enable SimpleXML support""... $ac_c" 1>&6
-echo "configure:86984: checking whether to enable SimpleXML support" >&5
+echo "configure:86920: checking whether to enable SimpleXML support" >&5
 # Check whether --enable-simplexml or --disable-simplexml was given.
 if test "${enable_simplexml+set}" = set; then
   enableval="$enable_simplexml"
@@ -87028,7 +86964,7 @@ if test -z "$PHP_LIBXML_DIR"; then
 php_with_libxml_dir=no
 
 echo $ac_n "checking libxml2 install dir""... $ac_c" 1>&6
-echo "configure:87032: checking libxml2 install dir" >&5
+echo "configure:86968: checking libxml2 install dir" >&5
 # Check whether --with-libxml-dir or --without-libxml-dir was given.
 if test "${with_libxml_dir+set}" = set; then
   withval="$with_libxml_dir"
@@ -87059,7 +86995,7 @@ if test "$PHP_SIMPLEXML" != "no"; then
 
   
 echo $ac_n "checking for xml2-config path""... $ac_c" 1>&6
-echo "configure:87063: checking for xml2-config path" >&5
+echo "configure:86999: checking for xml2-config path" >&5
 if eval "test \"`echo '$''{'ac_cv_php_xml2_config_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -87217,7 +87153,7 @@ echo "$ac_t""$ac_cv_php_xml2_config_path" 1>&6
 
 
             echo $ac_n "checking whether libxml build works""... $ac_c" 1>&6
-echo "configure:87221: checking whether libxml build works" >&5
+echo "configure:87157: checking whether libxml build works" >&5
 if eval "test \"`echo '$''{'php_cv_libxml_build_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -87233,7 +87169,7 @@ else
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 87237 "configure"
+#line 87173 "configure"
 #include "confdefs.h"
 
     
@@ -87244,7 +87180,7 @@ else
     }
   
 EOF
-if { (eval echo configure:87248: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:87184: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     LIBS=$old_LIBS
@@ -87632,7 +87568,7 @@ fi
 php_with_snmp=no
 
 echo $ac_n "checking for SNMP support""... $ac_c" 1>&6
-echo "configure:87636: checking for SNMP support" >&5
+echo "configure:87572: checking for SNMP support" >&5
 # Check whether --with-snmp or --without-snmp was given.
 if test "${with_snmp+set}" = set; then
   withval="$with_snmp"
@@ -87679,7 +87615,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_openssl_dir=no
 
 echo $ac_n "checking OpenSSL dir for SNMP""... $ac_c" 1>&6
-echo "configure:87683: checking OpenSSL dir for SNMP" >&5
+echo "configure:87619: checking OpenSSL dir for SNMP" >&5
 # Check whether --with-openssl-dir or --without-openssl-dir was given.
 if test "${with_openssl_dir+set}" = set; then
   withval="$with_openssl_dir"
@@ -87705,7 +87641,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_enable_ucd_snmp_hack=no
 
 echo $ac_n "checking whether to enable UCD SNMP hack""... $ac_c" 1>&6
-echo "configure:87709: checking whether to enable UCD SNMP hack" >&5
+echo "configure:87645: checking whether to enable UCD SNMP hack" >&5
 # Check whether --enable-ucd-snmp-hack or --disable-ucd-snmp-hack was given.
 if test "${enable_ucd_snmp_hack+set}" = set; then
   enableval="$enable_ucd_snmp_hack"
@@ -87733,7 +87669,7 @@ if test "$PHP_SNMP" != "no"; then
     # Extract the first word of "net-snmp-config", so it can be a program name with args.
 set dummy net-snmp-config; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:87737: checking for $ac_word" >&5
+echo "configure:87673: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_SNMP_CONFIG'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -87934,17 +87870,17 @@ EOF
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:87938: checking for $ac_hdr" >&5
+echo "configure:87874: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 87943 "configure"
+#line 87879 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:87948: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:87884: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -87972,9 +87908,9 @@ done
 
     if test "$ac_cv_header_default_store_h" = "yes"; then
       echo $ac_n "checking for OpenSSL support in SNMP libraries""... $ac_c" 1>&6
-echo "configure:87976: checking for OpenSSL support in SNMP libraries" >&5
+echo "configure:87912: checking for OpenSSL support in SNMP libraries" >&5
       cat > conftest.$ac_ext <<EOF
-#line 87978 "configure"
+#line 87914 "configure"
 #include "confdefs.h"
 
 #include <ucd-snmp-config.h>
@@ -88029,7 +87965,7 @@ rm -f conftest*
     # Extract the first word of "pkg-config", so it can be a program name with args.
 set dummy pkg-config; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:88033: checking for $ac_word" >&5
+echo "configure:87969: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_PKG_CONFIG'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -88234,9 +88170,9 @@ fi
     old_CPPFLAGS=$CPPFLAGS
     CPPFLAGS=-I$OPENSSL_INCDIR
     echo $ac_n "checking for OpenSSL version""... $ac_c" 1>&6
-echo "configure:88238: checking for OpenSSL version" >&5
+echo "configure:88174: checking for OpenSSL version" >&5
     cat > conftest.$ac_ext <<EOF
-#line 88240 "configure"
+#line 88176 "configure"
 #include "confdefs.h"
 
 #include <openssl/opensslv.h>
@@ -88391,7 +88327,7 @@ rm -f conftest*
   done
 
   echo $ac_n "checking for CRYPTO_free in -lcrypto""... $ac_c" 1>&6
-echo "configure:88395: checking for CRYPTO_free in -lcrypto" >&5
+echo "configure:88331: checking for CRYPTO_free in -lcrypto" >&5
 ac_lib_var=`echo crypto'_'CRYPTO_free | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -88399,7 +88335,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lcrypto  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 88403 "configure"
+#line 88339 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -88410,7 +88346,7 @@ int main() {
 CRYPTO_free()
 ; return 0; }
 EOF
-if { (eval echo configure:88414: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:88350: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -88567,7 +88503,7 @@ fi
   done
 
   echo $ac_n "checking for SSL_CTX_set_ssl_version in -lssl""... $ac_c" 1>&6
-echo "configure:88571: checking for SSL_CTX_set_ssl_version in -lssl" >&5
+echo "configure:88507: checking for SSL_CTX_set_ssl_version in -lssl" >&5
 ac_lib_var=`echo ssl'_'SSL_CTX_set_ssl_version | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -88575,7 +88511,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lssl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 88579 "configure"
+#line 88515 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -88586,7 +88522,7 @@ int main() {
 SSL_CTX_set_ssl_version()
 ; return 0; }
 EOF
-if { (eval echo configure:88590: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:88526: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -88699,7 +88635,7 @@ else
     fi
 
     echo $ac_n "checking for kstat_read in -lkstat""... $ac_c" 1>&6
-echo "configure:88703: checking for kstat_read in -lkstat" >&5
+echo "configure:88639: checking for kstat_read in -lkstat" >&5
 ac_lib_var=`echo kstat'_'kstat_read | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -88707,7 +88643,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lkstat  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 88711 "configure"
+#line 88647 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -88718,7 +88654,7 @@ int main() {
 kstat_read()
 ; return 0; }
 EOF
-if { (eval echo configure:88722: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:88658: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -88989,7 +88925,7 @@ fi
   done
 
   echo $ac_n "checking for snmp_parse_oid in -l$SNMP_LIBNAME""... $ac_c" 1>&6
-echo "configure:88993: checking for snmp_parse_oid in -l$SNMP_LIBNAME" >&5
+echo "configure:88929: checking for snmp_parse_oid in -l$SNMP_LIBNAME" >&5
 ac_lib_var=`echo $SNMP_LIBNAME'_'snmp_parse_oid | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -88997,7 +88933,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$SNMP_LIBNAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 89001 "configure"
+#line 88937 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -89008,7 +88944,7 @@ int main() {
 snmp_parse_oid()
 ; return 0; }
 EOF
-if { (eval echo configure:89012: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:88948: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -89142,7 +89078,7 @@ fi
   done
 
   echo $ac_n "checking for init_snmp in -l$SNMP_LIBNAME""... $ac_c" 1>&6
-echo "configure:89146: checking for init_snmp in -l$SNMP_LIBNAME" >&5
+echo "configure:89082: checking for init_snmp in -l$SNMP_LIBNAME" >&5
 ac_lib_var=`echo $SNMP_LIBNAME'_'init_snmp | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -89150,7 +89086,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$SNMP_LIBNAME  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 89154 "configure"
+#line 89090 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -89161,7 +89097,7 @@ int main() {
 init_snmp()
 ; return 0; }
 EOF
-if { (eval echo configure:89165: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:89101: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -89508,7 +89444,7 @@ fi
 php_enable_soap=no
 
 echo $ac_n "checking whether to enable SOAP support""... $ac_c" 1>&6
-echo "configure:89512: checking whether to enable SOAP support" >&5
+echo "configure:89448: checking whether to enable SOAP support" >&5
 # Check whether --enable-soap or --disable-soap was given.
 if test "${enable_soap+set}" = set; then
   enableval="$enable_soap"
@@ -89556,7 +89492,7 @@ if test -z "$PHP_LIBXML_DIR"; then
 php_with_libxml_dir=no
 
 echo $ac_n "checking libxml2 install dir""... $ac_c" 1>&6
-echo "configure:89560: checking libxml2 install dir" >&5
+echo "configure:89496: checking libxml2 install dir" >&5
 # Check whether --with-libxml-dir or --without-libxml-dir was given.
 if test "${with_libxml_dir+set}" = set; then
   withval="$with_libxml_dir"
@@ -89587,7 +89523,7 @@ if test "$PHP_SOAP" != "no"; then
 
   
 echo $ac_n "checking for xml2-config path""... $ac_c" 1>&6
-echo "configure:89591: checking for xml2-config path" >&5
+echo "configure:89527: checking for xml2-config path" >&5
 if eval "test \"`echo '$''{'ac_cv_php_xml2_config_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -89745,7 +89681,7 @@ echo "$ac_t""$ac_cv_php_xml2_config_path" 1>&6
 
 
             echo $ac_n "checking whether libxml build works""... $ac_c" 1>&6
-echo "configure:89749: checking whether libxml build works" >&5
+echo "configure:89685: checking whether libxml build works" >&5
 if eval "test \"`echo '$''{'php_cv_libxml_build_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -89761,7 +89697,7 @@ else
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 89765 "configure"
+#line 89701 "configure"
 #include "confdefs.h"
 
     
@@ -89772,7 +89708,7 @@ else
     }
   
 EOF
-if { (eval echo configure:89776: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:89712: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     LIBS=$old_LIBS
@@ -90122,7 +90058,7 @@ fi
 php_enable_sockets=no
 
 echo $ac_n "checking whether to enable sockets support""... $ac_c" 1>&6
-echo "configure:90126: checking whether to enable sockets support" >&5
+echo "configure:90062: checking whether to enable sockets support" >&5
 # Check whether --enable-sockets or --disable-sockets was given.
 if test "${enable_sockets+set}" = set; then
   enableval="$enable_sockets"
@@ -90167,13 +90103,13 @@ echo "$ac_t""$ext_output" 1>&6
 
 if test "$PHP_SOCKETS" != "no"; then
     echo $ac_n "checking for struct cmsghdr""... $ac_c" 1>&6
-echo "configure:90171: checking for struct cmsghdr" >&5
+echo "configure:90107: checking for struct cmsghdr" >&5
 if eval "test \"`echo '$''{'ac_cv_cmsghdr'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     cat > conftest.$ac_ext <<EOF
-#line 90177 "configure"
+#line 90113 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -90182,7 +90118,7 @@ int main() {
 struct cmsghdr s; s
 ; return 0; }
 EOF
-if { (eval echo configure:90186: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:90122: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_cmsghdr=yes
 else
@@ -90207,12 +90143,12 @@ EOF
   for ac_func in hstrerror socketpair
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:90211: checking for $ac_func" >&5
+echo "configure:90147: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 90216 "configure"
+#line 90152 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -90235,7 +90171,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:90239: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:90175: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -90263,17 +90199,17 @@ done
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:90267: checking for $ac_hdr" >&5
+echo "configure:90203: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 90272 "configure"
+#line 90208 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:90277: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:90213: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -90300,7 +90236,7 @@ fi
 done
 
   cat > conftest.$ac_ext <<EOF
-#line 90304 "configure"
+#line 90240 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -90310,7 +90246,7 @@ int main() {
 static struct msghdr tp; int n = (int) tp.msg_flags; return n
 ; return 0; }
 EOF
-if { (eval echo configure:90314: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:90250: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   :
 else
   echo "configure: failed program was:" >&5
@@ -90627,7 +90563,7 @@ fi
 php_enable_spl=yes
 
 echo $ac_n "checking enable SPL suppport""... $ac_c" 1>&6
-echo "configure:90631: checking enable SPL suppport" >&5
+echo "configure:90567: checking enable SPL suppport" >&5
 # Check whether --enable-spl or --disable-spl was given.
 if test "${enable_spl+set}" = set; then
   enableval="$enable_spl"
@@ -90672,7 +90608,7 @@ echo "$ac_t""$ext_output" 1>&6
 
 if test "$PHP_SPL" != "no"; then
   echo $ac_n "checking whether zend_object_value is packed""... $ac_c" 1>&6
-echo "configure:90676: checking whether zend_object_value is packed" >&5
+echo "configure:90612: checking whether zend_object_value is packed" >&5
   old_CPPFLAGS=$CPPFLAGS
   CPPFLAGS="$INCLUDES -I$abs_srcdir $CPPFLAGS"
   if test "$cross_compiling" = yes; then
@@ -90682,7 +90618,7 @@ echo "configure:90676: checking whether zend_object_value is packed" >&5
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 90686 "configure"
+#line 90622 "configure"
 #include "confdefs.h"
 
 #include "Zend/zend_types.h"
@@ -90691,7 +90627,7 @@ int main(int argc, char **argv) {
 }
   
 EOF
-if { (eval echo configure:90695: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:90631: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     ac_result=1
@@ -91056,7 +90992,7 @@ fi
 php_with_sqlite=yes
 
 echo $ac_n "checking for sqlite support""... $ac_c" 1>&6
-echo "configure:91060: checking for sqlite support" >&5
+echo "configure:90996: checking for sqlite support" >&5
 # Check whether --with-sqlite or --without-sqlite was given.
 if test "${with_sqlite+set}" = set; then
   withval="$with_sqlite"
@@ -91103,7 +91039,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_enable_sqlite_utf8=no
 
 echo $ac_n "checking whether to enable UTF-8 support in sqlite (default: ISO-8859-1)""... $ac_c" 1>&6
-echo "configure:91107: checking whether to enable UTF-8 support in sqlite (default: ISO-8859-1)" >&5
+echo "configure:91043: checking whether to enable UTF-8 support in sqlite (default: ISO-8859-1)" >&5
 # Check whether --enable-sqlite-utf8 or --disable-sqlite-utf8 was given.
 if test "${enable_sqlite_utf8+set}" = set; then
   enableval="$enable_sqlite_utf8"
@@ -91134,13 +91070,13 @@ if test "$PHP_SQLITE" != "no"; then
   if test "$PHP_PDO" != "no"; then
     
   echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:91138: checking for PDO includes" >&5
+echo "configure:91074: checking for PDO includes" >&5
 if eval "test \"`echo '$''{'pdo_inc_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     echo $ac_n "checking for PDO includes""... $ac_c" 1>&6
-echo "configure:91144: checking for PDO includes" >&5
+echo "configure:91080: checking for PDO includes" >&5
     if test -f $abs_srcdir/include/php/ext/pdo/php_pdo_driver.h; then
       pdo_inc_path=$abs_srcdir/ext
     elif test -f $abs_srcdir/ext/pdo/php_pdo_driver.h; then
@@ -91174,7 +91110,7 @@ EOF
       SQLITE_DIR=$PHP_SQLITE
     else # search default path list
       echo $ac_n "checking for sqlite files in default path""... $ac_c" 1>&6
-echo "configure:91178: checking for sqlite files in default path" >&5
+echo "configure:91114: checking for sqlite files in default path" >&5
       for i in $SEARCH_PATH ; do
         if test -r $i/$SEARCH_FOR; then
           SQLITE_DIR=$i
@@ -91286,7 +91222,7 @@ echo "configure:91178: checking for sqlite files in default path" >&5
   done
 
   echo $ac_n "checking for sqlite_open in -lsqlite""... $ac_c" 1>&6
-echo "configure:91290: checking for sqlite_open in -lsqlite" >&5
+echo "configure:91226: checking for sqlite_open in -lsqlite" >&5
 ac_lib_var=`echo sqlite'_'sqlite_open | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -91294,7 +91230,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsqlite  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 91298 "configure"
+#line 91234 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -91305,7 +91241,7 @@ int main() {
 sqlite_open()
 ; return 0; }
 EOF
-if { (eval echo configure:91309: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:91245: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -91478,7 +91414,7 @@ fi
   # Extract the first word of "lemon", so it can be a program name with args.
 set dummy lemon; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:91482: checking for $ac_word" >&5
+echo "configure:91418: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_LEMON'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -91506,7 +91442,7 @@ fi
 
   if test "$LEMON"; then
     echo $ac_n "checking for lemon version""... $ac_c" 1>&6
-echo "configure:91510: checking for lemon version" >&5
+echo "configure:91446: checking for lemon version" >&5
 if eval "test \"`echo '$''{'php_cv_lemon_version'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -91919,7 +91855,7 @@ but you've either not enabled pdo, or have disabled it.
   
 
     echo $ac_n "checking size of char *""... $ac_c" 1>&6
-echo "configure:91923: checking size of char *" >&5
+echo "configure:91859: checking size of char *" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_char_p'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -91927,7 +91863,7 @@ else
   ac_cv_sizeof_char_p=4
 else
   cat > conftest.$ac_ext <<EOF
-#line 91931 "configure"
+#line 91867 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -91938,7 +91874,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:91942: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:91878: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_char_p=`cat conftestval`
 else
@@ -92000,12 +91936,12 @@ EOF
   for ac_func in usleep nanosleep
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:92004: checking for $ac_func" >&5
+echo "configure:91940: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 92009 "configure"
+#line 91945 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -92028,7 +91964,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:92032: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:91968: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -92056,17 +91992,17 @@ done
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:92060: checking for $ac_hdr" >&5
+echo "configure:91996: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 92065 "configure"
+#line 92001 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:92070: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:92006: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -92097,7 +92033,7 @@ fi
 
 
 echo $ac_n "checking whether flush should be called explicitly after a buffered io""... $ac_c" 1>&6
-echo "configure:92101: checking whether flush should be called explicitly after a buffered io" >&5
+echo "configure:92037: checking whether flush should be called explicitly after a buffered io" >&5
 if eval "test \"`echo '$''{'ac_cv_flush_io'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -92108,7 +92044,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 92112 "configure"
+#line 92048 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -92146,7 +92082,7 @@ int main(int argc, char **argv)
 }
 
 EOF
-if { (eval echo configure:92150: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:92086: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   ac_cv_flush_io=no
@@ -92174,7 +92110,7 @@ fi
 
 if test "$ac_cv_func_crypt" = "no"; then
   echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6
-echo "configure:92178: checking for crypt in -lcrypt" >&5
+echo "configure:92114: checking for crypt in -lcrypt" >&5
 ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -92182,7 +92118,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lcrypt  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 92186 "configure"
+#line 92122 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -92193,7 +92129,7 @@ int main() {
 crypt()
 ; return 0; }
 EOF
-if { (eval echo configure:92197: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:92133: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -92222,7 +92158,7 @@ fi
 fi
   
 echo $ac_n "checking for standard DES crypt""... $ac_c" 1>&6
-echo "configure:92226: checking for standard DES crypt" >&5
+echo "configure:92162: checking for standard DES crypt" >&5
 if eval "test \"`echo '$''{'ac_cv_crypt_des'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -92233,7 +92169,7 @@ else
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 92237 "configure"
+#line 92173 "configure"
 #include "confdefs.h"
 
 #if HAVE_UNISTD_H
@@ -92252,7 +92188,7 @@ main() {
 #endif
 }
 EOF
-if { (eval echo configure:92256: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:92192: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   ac_cv_crypt_des=yes
@@ -92282,7 +92218,7 @@ EOF
 
 
 echo $ac_n "checking for extended DES crypt""... $ac_c" 1>&6
-echo "configure:92286: checking for extended DES crypt" >&5
+echo "configure:92222: checking for extended DES crypt" >&5
 if eval "test \"`echo '$''{'ac_cv_crypt_ext_des'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -92293,7 +92229,7 @@ else
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 92297 "configure"
+#line 92233 "configure"
 #include "confdefs.h"
 
 #if HAVE_UNISTD_H
@@ -92312,7 +92248,7 @@ main() {
 #endif
 }
 EOF
-if { (eval echo configure:92316: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:92252: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   ac_cv_crypt_ext_des=yes
@@ -92342,7 +92278,7 @@ EOF
 
 
 echo $ac_n "checking for MD5 crypt""... $ac_c" 1>&6
-echo "configure:92346: checking for MD5 crypt" >&5
+echo "configure:92282: checking for MD5 crypt" >&5
 if eval "test \"`echo '$''{'ac_cv_crypt_md5'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -92353,7 +92289,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 92357 "configure"
+#line 92293 "configure"
 #include "confdefs.h"
 
 #if HAVE_UNISTD_H
@@ -92381,7 +92317,7 @@ main() {
 #endif
 }
 EOF
-if { (eval echo configure:92385: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:92321: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   ac_cv_crypt_md5=yes
@@ -92440,7 +92376,7 @@ EOF
 
 
 echo $ac_n "checking for Blowfish crypt""... $ac_c" 1>&6
-echo "configure:92444: checking for Blowfish crypt" >&5
+echo "configure:92380: checking for Blowfish crypt" >&5
 if eval "test \"`echo '$''{'ac_cv_crypt_blowfish'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -92451,7 +92387,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 92455 "configure"
+#line 92391 "configure"
 #include "confdefs.h"
 
 #if HAVE_UNISTD_H
@@ -92476,7 +92412,7 @@ main() {
 #endif
 }
 EOF
-if { (eval echo configure:92480: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:92416: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   ac_cv_crypt_blowfish=yes
@@ -92508,12 +92444,12 @@ EOF
 for ac_func in getcwd getwd asinh acosh atanh log1p hypot glob strfmon nice fpclass isinf isnan
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:92512: checking for $ac_func" >&5
+echo "configure:92448: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 92517 "configure"
+#line 92453 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -92536,7 +92472,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:92540: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:92476: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -92561,7 +92497,7 @@ fi
 done
 
 echo $ac_n "checking for working fnmatch""... $ac_c" 1>&6
-echo "configure:92565: checking for working fnmatch" >&5
+echo "configure:92501: checking for working fnmatch" >&5
 if eval "test \"`echo '$''{'ac_cv_func_fnmatch_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -92572,11 +92508,11 @@ if test "$cross_compiling" = yes; then
   ac_cv_func_fnmatch_works=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 92576 "configure"
+#line 92512 "configure"
 #include "confdefs.h"
 main() { exit (fnmatch ("a*", "abc", 0) != 0); }
 EOF
-if { (eval echo configure:92580: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:92516: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_fnmatch_works=yes
 else
@@ -92707,13 +92643,13 @@ elif test "$REGEX_TYPE" = "system"; then
 EOF
 
     echo $ac_n "checking whether field re_magic exists in struct regex_t""... $ac_c" 1>&6
-echo "configure:92711: checking whether field re_magic exists in struct regex_t" >&5
+echo "configure:92647: checking whether field re_magic exists in struct regex_t" >&5
 if eval "test \"`echo '$''{'ac_cv_regex_t_re_magic'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
   cat > conftest.$ac_ext <<EOF
-#line 92717 "configure"
+#line 92653 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <regex.h>
@@ -92721,7 +92657,7 @@ int main() {
 regex_t rt; rt.re_magic;
 ; return 0; }
 EOF
-if { (eval echo configure:92725: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:92661: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_regex_t_re_magic=yes
 else
@@ -92742,11 +92678,11 @@ EOF
   fi 
 fi   
 echo $ac_n "checking which regex library to use""... $ac_c" 1>&6
-echo "configure:92746: checking which regex library to use" >&5
+echo "configure:92682: checking which regex library to use" >&5
 echo "$ac_t""$REGEX_TYPE" 1>&6
 
 echo $ac_n "checking whether rounding works as expected""... $ac_c" 1>&6
-echo "configure:92750: checking whether rounding works as expected" >&5
+echo "configure:92686: checking whether rounding works as expected" >&5
 if test "$cross_compiling" = yes; then
   
   PHP_ROUND_FUZZ=0.50000000001
@@ -92754,7 +92690,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 92758 "configure"
+#line 92694 "configure"
 #include "confdefs.h"
 
 #include <math.h>
@@ -92767,7 +92703,7 @@ else
   }
 
 EOF
-if { (eval echo configure:92771: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:92707: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   PHP_ROUND_FUZZ=0.5
@@ -92790,19 +92726,15 @@ cat >> confdefs.h <<EOF
 EOF
 
 
-if eval "test \"`echo '$''{'php_can_support_proc_open'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  
 for ac_func in fork CreateProcess
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:92801: checking for $ac_func" >&5
+echo "configure:92733: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 92806 "configure"
+#line 92738 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -92825,7 +92757,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:92829: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:92761: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -92854,10 +92786,9 @@ php_can_support_proc_open=no
 fi
 done
 
-fi
 
 echo $ac_n "checking if your OS can spawn processes with inherited handles""... $ac_c" 1>&6
-echo "configure:92861: checking if your OS can spawn processes with inherited handles" >&5
+echo "configure:92792: checking if your OS can spawn processes with inherited handles" >&5
 if test "$php_can_support_proc_open" = "yes"; then
   echo "$ac_t""yes" 1>&6
   cat >> confdefs.h <<\EOF
@@ -92882,12 +92813,12 @@ fi
   unset found
   
   echo $ac_n "checking for res_nmkquery""... $ac_c" 1>&6
-echo "configure:92886: checking for res_nmkquery" >&5
+echo "configure:92817: checking for res_nmkquery" >&5
 if eval "test \"`echo '$''{'ac_cv_func_res_nmkquery'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 92891 "configure"
+#line 92822 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char res_nmkquery(); below.  */
@@ -92910,7 +92841,7 @@ res_nmkquery();
 
 ; return 0; }
 EOF
-if { (eval echo configure:92914: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:92845: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_res_nmkquery=yes"
 else
@@ -92928,12 +92859,12 @@ if eval "test \"`echo '$ac_cv_func_'res_nmkquery`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
  echo $ac_n "checking for __res_nmkquery""... $ac_c" 1>&6
-echo "configure:92932: checking for __res_nmkquery" >&5
+echo "configure:92863: checking for __res_nmkquery" >&5
 if eval "test \"`echo '$''{'ac_cv_func___res_nmkquery'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 92937 "configure"
+#line 92868 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char __res_nmkquery(); below.  */
@@ -92956,7 +92887,7 @@ __res_nmkquery();
 
 ; return 0; }
 EOF
-if { (eval echo configure:92960: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:92891: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func___res_nmkquery=yes"
 else
@@ -92994,7 +92925,7 @@ EOF
   unset ac_cv_lib_resolv___res_nmkquery
   unset found
   echo $ac_n "checking for res_nmkquery in -lresolv""... $ac_c" 1>&6
-echo "configure:92998: checking for res_nmkquery in -lresolv" >&5
+echo "configure:92929: checking for res_nmkquery in -lresolv" >&5
 ac_lib_var=`echo resolv'_'res_nmkquery | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -93002,7 +92933,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lresolv  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 93006 "configure"
+#line 92937 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -93013,7 +92944,7 @@ int main() {
 res_nmkquery()
 ; return 0; }
 EOF
-if { (eval echo configure:93017: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:92948: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -93033,7 +92964,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __res_nmkquery in -lresolv""... $ac_c" 1>&6
-echo "configure:93037: checking for __res_nmkquery in -lresolv" >&5
+echo "configure:92968: checking for __res_nmkquery in -lresolv" >&5
 ac_lib_var=`echo resolv'_'__res_nmkquery | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -93041,7 +92972,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lresolv  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 93045 "configure"
+#line 92976 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -93052,7 +92983,7 @@ int main() {
 __res_nmkquery()
 ; return 0; }
 EOF
-if { (eval echo configure:93056: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:92987: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -93084,11 +93015,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 93088 "configure"
+#line 93019 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:93092: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:93023: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -93130,7 +93061,7 @@ EOF
   unset ac_cv_lib_bind___res_nmkquery
   unset found
   echo $ac_n "checking for res_nmkquery in -lbind""... $ac_c" 1>&6
-echo "configure:93134: checking for res_nmkquery in -lbind" >&5
+echo "configure:93065: checking for res_nmkquery in -lbind" >&5
 ac_lib_var=`echo bind'_'res_nmkquery | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -93138,7 +93069,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbind  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 93142 "configure"
+#line 93073 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -93149,7 +93080,7 @@ int main() {
 res_nmkquery()
 ; return 0; }
 EOF
-if { (eval echo configure:93153: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:93084: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -93169,7 +93100,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __res_nmkquery in -lbind""... $ac_c" 1>&6
-echo "configure:93173: checking for __res_nmkquery in -lbind" >&5
+echo "configure:93104: checking for __res_nmkquery in -lbind" >&5
 ac_lib_var=`echo bind'_'__res_nmkquery | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -93177,7 +93108,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbind  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 93181 "configure"
+#line 93112 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -93188,7 +93119,7 @@ int main() {
 __res_nmkquery()
 ; return 0; }
 EOF
-if { (eval echo configure:93192: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:93123: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -93220,11 +93151,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 93224 "configure"
+#line 93155 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:93228: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:93159: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -93266,7 +93197,7 @@ EOF
   unset ac_cv_lib_socket___res_nmkquery
   unset found
   echo $ac_n "checking for res_nmkquery in -lsocket""... $ac_c" 1>&6
-echo "configure:93270: checking for res_nmkquery in -lsocket" >&5
+echo "configure:93201: checking for res_nmkquery in -lsocket" >&5
 ac_lib_var=`echo socket'_'res_nmkquery | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -93274,7 +93205,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 93278 "configure"
+#line 93209 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -93285,7 +93216,7 @@ int main() {
 res_nmkquery()
 ; return 0; }
 EOF
-if { (eval echo configure:93289: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:93220: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -93305,7 +93236,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __res_nmkquery in -lsocket""... $ac_c" 1>&6
-echo "configure:93309: checking for __res_nmkquery in -lsocket" >&5
+echo "configure:93240: checking for __res_nmkquery in -lsocket" >&5
 ac_lib_var=`echo socket'_'__res_nmkquery | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -93313,7 +93244,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 93317 "configure"
+#line 93248 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -93324,7 +93255,7 @@ int main() {
 __res_nmkquery()
 ; return 0; }
 EOF
-if { (eval echo configure:93328: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:93259: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -93356,11 +93287,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 93360 "configure"
+#line 93291 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:93364: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:93295: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -93417,12 +93348,12 @@ EOF
   unset found
   
   echo $ac_n "checking for res_nsend""... $ac_c" 1>&6
-echo "configure:93421: checking for res_nsend" >&5
+echo "configure:93352: checking for res_nsend" >&5
 if eval "test \"`echo '$''{'ac_cv_func_res_nsend'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 93426 "configure"
+#line 93357 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char res_nsend(); below.  */
@@ -93445,7 +93376,7 @@ res_nsend();
 
 ; return 0; }
 EOF
-if { (eval echo configure:93449: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:93380: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_res_nsend=yes"
 else
@@ -93463,12 +93394,12 @@ if eval "test \"`echo '$ac_cv_func_'res_nsend`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
  echo $ac_n "checking for __res_nsend""... $ac_c" 1>&6
-echo "configure:93467: checking for __res_nsend" >&5
+echo "configure:93398: checking for __res_nsend" >&5
 if eval "test \"`echo '$''{'ac_cv_func___res_nsend'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 93472 "configure"
+#line 93403 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char __res_nsend(); below.  */
@@ -93491,7 +93422,7 @@ __res_nsend();
 
 ; return 0; }
 EOF
-if { (eval echo configure:93495: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:93426: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func___res_nsend=yes"
 else
@@ -93529,7 +93460,7 @@ EOF
   unset ac_cv_lib_resolv___res_nsend
   unset found
   echo $ac_n "checking for res_nsend in -lresolv""... $ac_c" 1>&6
-echo "configure:93533: checking for res_nsend in -lresolv" >&5
+echo "configure:93464: checking for res_nsend in -lresolv" >&5
 ac_lib_var=`echo resolv'_'res_nsend | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -93537,7 +93468,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lresolv  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 93541 "configure"
+#line 93472 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -93548,7 +93479,7 @@ int main() {
 res_nsend()
 ; return 0; }
 EOF
-if { (eval echo configure:93552: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:93483: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -93568,7 +93499,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __res_nsend in -lresolv""... $ac_c" 1>&6
-echo "configure:93572: checking for __res_nsend in -lresolv" >&5
+echo "configure:93503: checking for __res_nsend in -lresolv" >&5
 ac_lib_var=`echo resolv'_'__res_nsend | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -93576,7 +93507,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lresolv  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 93580 "configure"
+#line 93511 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -93587,7 +93518,7 @@ int main() {
 __res_nsend()
 ; return 0; }
 EOF
-if { (eval echo configure:93591: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:93522: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -93619,11 +93550,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 93623 "configure"
+#line 93554 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:93627: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:93558: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -93665,7 +93596,7 @@ EOF
   unset ac_cv_lib_bind___res_nsend
   unset found
   echo $ac_n "checking for res_nsend in -lbind""... $ac_c" 1>&6
-echo "configure:93669: checking for res_nsend in -lbind" >&5
+echo "configure:93600: checking for res_nsend in -lbind" >&5
 ac_lib_var=`echo bind'_'res_nsend | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -93673,7 +93604,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbind  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 93677 "configure"
+#line 93608 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -93684,7 +93615,7 @@ int main() {
 res_nsend()
 ; return 0; }
 EOF
-if { (eval echo configure:93688: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:93619: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -93704,7 +93635,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __res_nsend in -lbind""... $ac_c" 1>&6
-echo "configure:93708: checking for __res_nsend in -lbind" >&5
+echo "configure:93639: checking for __res_nsend in -lbind" >&5
 ac_lib_var=`echo bind'_'__res_nsend | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -93712,7 +93643,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbind  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 93716 "configure"
+#line 93647 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -93723,7 +93654,7 @@ int main() {
 __res_nsend()
 ; return 0; }
 EOF
-if { (eval echo configure:93727: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:93658: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -93755,11 +93686,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 93759 "configure"
+#line 93690 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:93763: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:93694: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -93801,7 +93732,7 @@ EOF
   unset ac_cv_lib_socket___res_nsend
   unset found
   echo $ac_n "checking for res_nsend in -lsocket""... $ac_c" 1>&6
-echo "configure:93805: checking for res_nsend in -lsocket" >&5
+echo "configure:93736: checking for res_nsend in -lsocket" >&5
 ac_lib_var=`echo socket'_'res_nsend | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -93809,7 +93740,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 93813 "configure"
+#line 93744 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -93820,7 +93751,7 @@ int main() {
 res_nsend()
 ; return 0; }
 EOF
-if { (eval echo configure:93824: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:93755: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -93840,7 +93771,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __res_nsend in -lsocket""... $ac_c" 1>&6
-echo "configure:93844: checking for __res_nsend in -lsocket" >&5
+echo "configure:93775: checking for __res_nsend in -lsocket" >&5
 ac_lib_var=`echo socket'_'__res_nsend | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -93848,7 +93779,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 93852 "configure"
+#line 93783 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -93859,7 +93790,7 @@ int main() {
 __res_nsend()
 ; return 0; }
 EOF
-if { (eval echo configure:93863: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:93794: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -93891,11 +93822,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 93895 "configure"
+#line 93826 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:93899: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:93830: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -93952,12 +93883,12 @@ EOF
   unset found
   
   echo $ac_n "checking for dn_expand""... $ac_c" 1>&6
-echo "configure:93956: checking for dn_expand" >&5
+echo "configure:93887: checking for dn_expand" >&5
 if eval "test \"`echo '$''{'ac_cv_func_dn_expand'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 93961 "configure"
+#line 93892 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char dn_expand(); below.  */
@@ -93980,7 +93911,7 @@ dn_expand();
 
 ; return 0; }
 EOF
-if { (eval echo configure:93984: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:93915: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_dn_expand=yes"
 else
@@ -93998,12 +93929,12 @@ if eval "test \"`echo '$ac_cv_func_'dn_expand`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
  echo $ac_n "checking for __dn_expand""... $ac_c" 1>&6
-echo "configure:94002: checking for __dn_expand" >&5
+echo "configure:93933: checking for __dn_expand" >&5
 if eval "test \"`echo '$''{'ac_cv_func___dn_expand'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 94007 "configure"
+#line 93938 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char __dn_expand(); below.  */
@@ -94026,7 +93957,7 @@ __dn_expand();
 
 ; return 0; }
 EOF
-if { (eval echo configure:94030: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:93961: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func___dn_expand=yes"
 else
@@ -94064,7 +93995,7 @@ EOF
   unset ac_cv_lib_resolv___dn_expand
   unset found
   echo $ac_n "checking for dn_expand in -lresolv""... $ac_c" 1>&6
-echo "configure:94068: checking for dn_expand in -lresolv" >&5
+echo "configure:93999: checking for dn_expand in -lresolv" >&5
 ac_lib_var=`echo resolv'_'dn_expand | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -94072,7 +94003,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lresolv  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 94076 "configure"
+#line 94007 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -94083,7 +94014,7 @@ int main() {
 dn_expand()
 ; return 0; }
 EOF
-if { (eval echo configure:94087: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:94018: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -94103,7 +94034,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __dn_expand in -lresolv""... $ac_c" 1>&6
-echo "configure:94107: checking for __dn_expand in -lresolv" >&5
+echo "configure:94038: checking for __dn_expand in -lresolv" >&5
 ac_lib_var=`echo resolv'_'__dn_expand | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -94111,7 +94042,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lresolv  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 94115 "configure"
+#line 94046 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -94122,7 +94053,7 @@ int main() {
 __dn_expand()
 ; return 0; }
 EOF
-if { (eval echo configure:94126: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:94057: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -94154,11 +94085,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 94158 "configure"
+#line 94089 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:94162: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:94093: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -94200,7 +94131,7 @@ EOF
   unset ac_cv_lib_bind___dn_expand
   unset found
   echo $ac_n "checking for dn_expand in -lbind""... $ac_c" 1>&6
-echo "configure:94204: checking for dn_expand in -lbind" >&5
+echo "configure:94135: checking for dn_expand in -lbind" >&5
 ac_lib_var=`echo bind'_'dn_expand | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -94208,7 +94139,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbind  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 94212 "configure"
+#line 94143 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -94219,7 +94150,7 @@ int main() {
 dn_expand()
 ; return 0; }
 EOF
-if { (eval echo configure:94223: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:94154: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -94239,7 +94170,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __dn_expand in -lbind""... $ac_c" 1>&6
-echo "configure:94243: checking for __dn_expand in -lbind" >&5
+echo "configure:94174: checking for __dn_expand in -lbind" >&5
 ac_lib_var=`echo bind'_'__dn_expand | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -94247,7 +94178,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbind  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 94251 "configure"
+#line 94182 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -94258,7 +94189,7 @@ int main() {
 __dn_expand()
 ; return 0; }
 EOF
-if { (eval echo configure:94262: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:94193: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -94290,11 +94221,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 94294 "configure"
+#line 94225 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:94298: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:94229: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -94336,7 +94267,7 @@ EOF
   unset ac_cv_lib_socket___dn_expand
   unset found
   echo $ac_n "checking for dn_expand in -lsocket""... $ac_c" 1>&6
-echo "configure:94340: checking for dn_expand in -lsocket" >&5
+echo "configure:94271: checking for dn_expand in -lsocket" >&5
 ac_lib_var=`echo socket'_'dn_expand | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -94344,7 +94275,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 94348 "configure"
+#line 94279 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -94355,7 +94286,7 @@ int main() {
 dn_expand()
 ; return 0; }
 EOF
-if { (eval echo configure:94359: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:94290: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -94375,7 +94306,7 @@ else
   echo "$ac_t""no" 1>&6
 
     echo $ac_n "checking for __dn_expand in -lsocket""... $ac_c" 1>&6
-echo "configure:94379: checking for __dn_expand in -lsocket" >&5
+echo "configure:94310: checking for __dn_expand in -lsocket" >&5
 ac_lib_var=`echo socket'_'__dn_expand | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -94383,7 +94314,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 94387 "configure"
+#line 94318 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -94394,7 +94325,7 @@ int main() {
 __dn_expand()
 ; return 0; }
 EOF
-if { (eval echo configure:94398: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:94329: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -94426,11 +94357,11 @@ fi
   found=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 94430 "configure"
+#line 94361 "configure"
 #include "confdefs.h"
 main() { return (0); }
 EOF
-if { (eval echo configure:94434: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:94365: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   found=yes
 else
@@ -94482,8 +94413,19 @@ EOF
   esac
 
 
+case $host_alias in
+  *darwin*)
+    macosx_major=`sw_vers -productVersion | cut -d . -f 1`
+    macosx_minor=`sw_vers -productVersion | cut -d . -f 2`
+
+    if test "$macosx_major" -ge "10" && test "$macosx_minor" -ge "6" ; then
+      LIBS="$LIBS -lresolv"
+    fi
+  ;;
+esac
+
 echo $ac_n "checking whether atof() accepts NAN""... $ac_c" 1>&6
-echo "configure:94487: checking whether atof() accepts NAN" >&5
+echo "configure:94429: checking whether atof() accepts NAN" >&5
 if eval "test \"`echo '$''{'ac_cv_atof_accept_nan'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -94494,7 +94436,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 94498 "configure"
+#line 94440 "configure"
 #include "confdefs.h"
 
 #include <math.h>
@@ -94514,7 +94456,7 @@ int main(int argc, char** argv)
 }
 
 EOF
-if { (eval echo configure:94518: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:94460: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   ac_cv_atof_accept_nan=yes
@@ -94541,7 +94483,7 @@ EOF
 fi
 
 echo $ac_n "checking whether atof() accepts INF""... $ac_c" 1>&6
-echo "configure:94545: checking whether atof() accepts INF" >&5
+echo "configure:94487: checking whether atof() accepts INF" >&5
 if eval "test \"`echo '$''{'ac_cv_atof_accept_inf'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -94552,7 +94494,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 94556 "configure"
+#line 94498 "configure"
 #include "confdefs.h"
 
 #include <math.h>
@@ -94575,7 +94517,7 @@ int main(int argc, char** argv)
 }
 
 EOF
-if { (eval echo configure:94579: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:94521: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   ac_cv_atof_accept_inf=yes
@@ -94602,7 +94544,7 @@ EOF
 fi
 
 echo $ac_n "checking whether HUGE_VAL == INF""... $ac_c" 1>&6
-echo "configure:94606: checking whether HUGE_VAL == INF" >&5
+echo "configure:94548: checking whether HUGE_VAL == INF" >&5
 if eval "test \"`echo '$''{'ac_cv_huge_val_inf'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -94613,7 +94555,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 94617 "configure"
+#line 94559 "configure"
 #include "confdefs.h"
 
 #include <math.h>
@@ -94636,7 +94578,7 @@ int main(int argc, char** argv)
 }
 
 EOF
-if { (eval echo configure:94640: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:94582: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   ac_cv_huge_val_inf=yes
@@ -94663,7 +94605,7 @@ EOF
 fi
 
 echo $ac_n "checking whether HUGE_VAL + -HUGEVAL == NAN""... $ac_c" 1>&6
-echo "configure:94667: checking whether HUGE_VAL + -HUGEVAL == NAN" >&5
+echo "configure:94609: checking whether HUGE_VAL + -HUGEVAL == NAN" >&5
 if eval "test \"`echo '$''{'ac_cv_huge_val_nan'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -94674,7 +94616,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 94678 "configure"
+#line 94620 "configure"
 #include "confdefs.h"
 
 #include <math.h>
@@ -94699,7 +94641,7 @@ int main(int argc, char** argv)
 }
 
 EOF
-if { (eval echo configure:94703: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:94645: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   ac_cv_huge_val_nan=yes
@@ -94726,13 +94668,13 @@ EOF
 fi
 
 echo $ac_n "checking whether strptime() declaration fails""... $ac_c" 1>&6
-echo "configure:94730: checking whether strptime() declaration fails" >&5
+echo "configure:94672: checking whether strptime() declaration fails" >&5
 if eval "test \"`echo '$''{'ac_cv_strptime_decl_fails'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 94736 "configure"
+#line 94678 "configure"
 #include "confdefs.h"
 
 #include <time.h>
@@ -94748,7 +94690,7 @@ int strptime(const char *s, const char *format, struct tm *tm);
 
 ; return 0; }
 EOF
-if { (eval echo configure:94752: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:94694: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
   ac_cv_strptime_decl_fails=no
@@ -94776,17 +94718,17 @@ for ac_hdr in wchar.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:94780: checking for $ac_hdr" >&5
+echo "configure:94722: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 94785 "configure"
+#line 94727 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:94790: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:94732: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -94815,12 +94757,12 @@ done
 for ac_func in mblen
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:94819: checking for $ac_func" >&5
+echo "configure:94761: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 94824 "configure"
+#line 94766 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -94843,7 +94785,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:94847: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:94789: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -94870,12 +94812,12 @@ done
 for ac_func in mbrlen mbsinit
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:94874: checking for $ac_func" >&5
+echo "configure:94816: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 94879 "configure"
+#line 94821 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -94898,7 +94840,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:94902: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:94844: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -94923,13 +94865,13 @@ fi
 done
 
 echo $ac_n "checking for mbstate_t""... $ac_c" 1>&6
-echo "configure:94927: checking for mbstate_t" >&5
+echo "configure:94869: checking for mbstate_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_mbstate_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 94933 "configure"
+#line 94875 "configure"
 #include "confdefs.h"
 
 #ifdef HAVE_WCHAR_H
@@ -94942,7 +94884,7 @@ int __tmp__() { mbstate_t a; }
 
 ; return 0; }
 EOF
-if { (eval echo configure:94946: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:94888: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
   ac_cv_type_mbstate_t=yes
@@ -95329,7 +95271,7 @@ EOF
 php_with_sybase=no
 
 echo $ac_n "checking for Sybase support""... $ac_c" 1>&6
-echo "configure:95333: checking for Sybase support" >&5
+echo "configure:95275: checking for Sybase support" >&5
 # Check whether --with-sybase or --without-sybase was given.
 if test "${with_sybase+set}" = set; then
   withval="$with_sybase"
@@ -95801,7 +95743,7 @@ EOF
   fi
 
   echo $ac_n "checking for dnet_addr in -ldnet_stub""... $ac_c" 1>&6
-echo "configure:95805: checking for dnet_addr in -ldnet_stub" >&5
+echo "configure:95747: checking for dnet_addr in -ldnet_stub" >&5
 ac_lib_var=`echo dnet_stub'_'dnet_addr | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -95809,7 +95751,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldnet_stub  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 95813 "configure"
+#line 95755 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -95820,7 +95762,7 @@ int main() {
 dnet_addr()
 ; return 0; }
 EOF
-if { (eval echo configure:95824: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:95766: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -95946,7 +95888,7 @@ fi
 EOF
 
   echo $ac_n "checking for tdsdbopen in -lsybdb""... $ac_c" 1>&6
-echo "configure:95950: checking for tdsdbopen in -lsybdb" >&5
+echo "configure:95892: checking for tdsdbopen in -lsybdb" >&5
 ac_lib_var=`echo sybdb'_'tdsdbopen | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -95954,7 +95896,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsybdb  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 95958 "configure"
+#line 95900 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -95965,7 +95907,7 @@ int main() {
 tdsdbopen()
 ; return 0; }
 EOF
-if { (eval echo configure:95969: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:95911: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -96007,7 +95949,7 @@ fi
 php_with_sybase_ct=no
 
 echo $ac_n "checking for Sybase-CT support""... $ac_c" 1>&6
-echo "configure:96011: checking for Sybase-CT support" >&5
+echo "configure:95953: checking for Sybase-CT support" >&5
 # Check whether --with-sybase-ct or --without-sybase-ct was given.
 if test "${with_sybase_ct+set}" = set; then
   withval="$with_sybase_ct"
@@ -96657,7 +96599,7 @@ EOF
   done
 
   echo $ac_n "checking for netg_errstr in -ltcl""... $ac_c" 1>&6
-echo "configure:96661: checking for netg_errstr in -ltcl" >&5
+echo "configure:96603: checking for netg_errstr in -ltcl" >&5
 ac_lib_var=`echo tcl'_'netg_errstr | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -96665,7 +96607,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ltcl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 96669 "configure"
+#line 96611 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -96676,7 +96618,7 @@ int main() {
 netg_errstr()
 ; return 0; }
 EOF
-if { (eval echo configure:96680: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:96622: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -96851,7 +96793,7 @@ fi
   done
 
   echo $ac_n "checking for insck__getVdate in -linsck""... $ac_c" 1>&6
-echo "configure:96855: checking for insck__getVdate in -linsck" >&5
+echo "configure:96797: checking for insck__getVdate in -linsck" >&5
 ac_lib_var=`echo insck'_'insck__getVdate | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -96859,7 +96801,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-linsck  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 96863 "configure"
+#line 96805 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -96870,7 +96812,7 @@ int main() {
 insck__getVdate()
 ; return 0; }
 EOF
-if { (eval echo configure:96874: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:96816: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -97018,7 +96960,7 @@ fi
   done
 
   echo $ac_n "checking for bsd_tcp in -linsck""... $ac_c" 1>&6
-echo "configure:97022: checking for bsd_tcp in -linsck" >&5
+echo "configure:96964: checking for bsd_tcp in -linsck" >&5
 ac_lib_var=`echo insck'_'bsd_tcp | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -97026,7 +96968,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-linsck  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 97030 "configure"
+#line 96972 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -97037,7 +96979,7 @@ int main() {
 bsd_tcp()
 ; return 0; }
 EOF
-if { (eval echo configure:97041: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:96983: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -97097,7 +97039,7 @@ fi
 php_enable_sysvmsg=no
 
 echo $ac_n "checking whether to enable System V IPC support""... $ac_c" 1>&6
-echo "configure:97101: checking whether to enable System V IPC support" >&5
+echo "configure:97043: checking whether to enable System V IPC support" >&5
 # Check whether --enable-sysvmsg or --disable-sysvmsg was given.
 if test "${enable_sysvmsg+set}" = set; then
   enableval="$enable_sysvmsg"
@@ -97143,17 +97085,17 @@ echo "$ac_t""$ext_output" 1>&6
 if test "$PHP_SYSVMSG" != "no"; then
   ac_safe=`echo "sys/msg.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for sys/msg.h""... $ac_c" 1>&6
-echo "configure:97147: checking for sys/msg.h" >&5
+echo "configure:97089: checking for sys/msg.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 97152 "configure"
+#line 97094 "configure"
 #include "confdefs.h"
 #include <sys/msg.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:97157: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:97099: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -97480,7 +97422,7 @@ fi
 php_enable_sysvsem=no
 
 echo $ac_n "checking whether to enable System V semaphore support""... $ac_c" 1>&6
-echo "configure:97484: checking whether to enable System V semaphore support" >&5
+echo "configure:97426: checking whether to enable System V semaphore support" >&5
 # Check whether --enable-sysvsem or --disable-sysvsem was given.
 if test "${enable_sysvsem+set}" = set; then
   enableval="$enable_sysvsem"
@@ -97821,12 +97763,12 @@ EOF
 EOF
 
  echo $ac_n "checking for union semun""... $ac_c" 1>&6
-echo "configure:97825: checking for union semun" >&5
+echo "configure:97767: checking for union semun" >&5
 if eval "test \"`echo '$''{'php_cv_semun'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 97830 "configure"
+#line 97772 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -97837,7 +97779,7 @@ int main() {
 union semun x;
 ; return 0; }
 EOF
-if { (eval echo configure:97841: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:97783: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
      php_cv_semun=yes
@@ -97873,7 +97815,7 @@ fi
 php_enable_sysvshm=no
 
 echo $ac_n "checking whether to enable System V shared memory support""... $ac_c" 1>&6
-echo "configure:97877: checking whether to enable System V shared memory support" >&5
+echo "configure:97819: checking whether to enable System V shared memory support" >&5
 # Check whether --enable-sysvshm or --disable-sysvshm was given.
 if test "${enable_sysvshm+set}" = set; then
   enableval="$enable_sysvshm"
@@ -98220,7 +98162,7 @@ fi
 php_with_tidy=no
 
 echo $ac_n "checking for TIDY support""... $ac_c" 1>&6
-echo "configure:98224: checking for TIDY support" >&5
+echo "configure:98166: checking for TIDY support" >&5
 # Check whether --with-tidy or --without-tidy was given.
 if test "${with_tidy+set}" = set; then
   withval="$with_tidy"
@@ -98512,7 +98454,7 @@ if test "$PHP_TIDY" != "no"; then
   done
 
   echo $ac_n "checking for tidyOptGetDoc in -ltidy""... $ac_c" 1>&6
-echo "configure:98516: checking for tidyOptGetDoc in -ltidy" >&5
+echo "configure:98458: checking for tidyOptGetDoc in -ltidy" >&5
 ac_lib_var=`echo tidy'_'tidyOptGetDoc | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -98520,7 +98462,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ltidy  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 98524 "configure"
+#line 98466 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -98531,7 +98473,7 @@ int main() {
 tidyOptGetDoc()
 ; return 0; }
 EOF
-if { (eval echo configure:98535: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:98477: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -98875,7 +98817,7 @@ fi
 php_enable_tokenizer=yes
 
 echo $ac_n "checking whether to enable tokenizer support""... $ac_c" 1>&6
-echo "configure:98879: checking whether to enable tokenizer support" >&5
+echo "configure:98821: checking whether to enable tokenizer support" >&5
 # Check whether --enable-tokenizer or --disable-tokenizer was given.
 if test "${enable_tokenizer+set}" = set; then
   enableval="$enable_tokenizer"
@@ -99224,7 +99166,7 @@ fi
 php_enable_wddx=no
 
 echo $ac_n "checking whether to enable WDDX support""... $ac_c" 1>&6
-echo "configure:99228: checking whether to enable WDDX support" >&5
+echo "configure:99170: checking whether to enable WDDX support" >&5
 # Check whether --enable-wddx or --disable-wddx was given.
 if test "${enable_wddx+set}" = set; then
   enableval="$enable_wddx"
@@ -99272,7 +99214,7 @@ if test -z "$PHP_LIBXML_DIR"; then
 php_with_libxml_dir=no
 
 echo $ac_n "checking libxml2 install dir""... $ac_c" 1>&6
-echo "configure:99276: checking libxml2 install dir" >&5
+echo "configure:99218: checking libxml2 install dir" >&5
 # Check whether --with-libxml-dir or --without-libxml-dir was given.
 if test "${with_libxml_dir+set}" = set; then
   withval="$with_libxml_dir"
@@ -99299,7 +99241,7 @@ fi
 php_with_libexpat_dir=no
 
 echo $ac_n "checking libexpat dir for WDDX""... $ac_c" 1>&6
-echo "configure:99303: checking libexpat dir for WDDX" >&5
+echo "configure:99245: checking libexpat dir for WDDX" >&5
 # Check whether --with-libexpat-dir or --without-libexpat-dir was given.
 if test "${with_libexpat_dir+set}" = set; then
   withval="$with_libexpat_dir"
@@ -99330,7 +99272,7 @@ if test "$PHP_WDDX" != "no"; then
 
     
 echo $ac_n "checking for xml2-config path""... $ac_c" 1>&6
-echo "configure:99334: checking for xml2-config path" >&5
+echo "configure:99276: checking for xml2-config path" >&5
 if eval "test \"`echo '$''{'ac_cv_php_xml2_config_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -99488,7 +99430,7 @@ echo "$ac_t""$ac_cv_php_xml2_config_path" 1>&6
 
 
             echo $ac_n "checking whether libxml build works""... $ac_c" 1>&6
-echo "configure:99492: checking whether libxml build works" >&5
+echo "configure:99434: checking whether libxml build works" >&5
 if eval "test \"`echo '$''{'php_cv_libxml_build_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -99504,7 +99446,7 @@ else
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 99508 "configure"
+#line 99450 "configure"
 #include "confdefs.h"
 
     
@@ -99515,7 +99457,7 @@ else
     }
   
 EOF
-if { (eval echo configure:99519: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:99461: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     LIBS=$old_LIBS
@@ -100082,7 +100024,7 @@ fi
 php_enable_xml=yes
 
 echo $ac_n "checking whether to enable XML support""... $ac_c" 1>&6
-echo "configure:100086: checking whether to enable XML support" >&5
+echo "configure:100028: checking whether to enable XML support" >&5
 # Check whether --enable-xml or --disable-xml was given.
 if test "${enable_xml+set}" = set; then
   enableval="$enable_xml"
@@ -100130,7 +100072,7 @@ if test -z "$PHP_LIBXML_DIR"; then
 php_with_libxml_dir=no
 
 echo $ac_n "checking libxml2 install dir""... $ac_c" 1>&6
-echo "configure:100134: checking libxml2 install dir" >&5
+echo "configure:100076: checking libxml2 install dir" >&5
 # Check whether --with-libxml-dir or --without-libxml-dir was given.
 if test "${with_libxml_dir+set}" = set; then
   withval="$with_libxml_dir"
@@ -100157,7 +100099,7 @@ fi
 php_with_libexpat_dir=no
 
 echo $ac_n "checking libexpat install dir""... $ac_c" 1>&6
-echo "configure:100161: checking libexpat install dir" >&5
+echo "configure:100103: checking libexpat install dir" >&5
 # Check whether --with-libexpat-dir or --without-libexpat-dir was given.
 if test "${with_libexpat_dir+set}" = set; then
   withval="$with_libexpat_dir"
@@ -100189,7 +100131,7 @@ if test "$PHP_XML" != "no"; then
 
     
 echo $ac_n "checking for xml2-config path""... $ac_c" 1>&6
-echo "configure:100193: checking for xml2-config path" >&5
+echo "configure:100135: checking for xml2-config path" >&5
 if eval "test \"`echo '$''{'ac_cv_php_xml2_config_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -100347,7 +100289,7 @@ echo "$ac_t""$ac_cv_php_xml2_config_path" 1>&6
 
 
             echo $ac_n "checking whether libxml build works""... $ac_c" 1>&6
-echo "configure:100351: checking whether libxml build works" >&5
+echo "configure:100293: checking whether libxml build works" >&5
 if eval "test \"`echo '$''{'php_cv_libxml_build_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -100363,7 +100305,7 @@ else
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 100367 "configure"
+#line 100309 "configure"
 #include "confdefs.h"
 
     
@@ -100374,7 +100316,7 @@ else
     }
   
 EOF
-if { (eval echo configure:100378: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:100320: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     LIBS=$old_LIBS
@@ -100910,7 +100852,7 @@ fi
 php_enable_xmlreader=yes
 
 echo $ac_n "checking whether to enable XMLReader support""... $ac_c" 1>&6
-echo "configure:100914: checking whether to enable XMLReader support" >&5
+echo "configure:100856: checking whether to enable XMLReader support" >&5
 # Check whether --enable-xmlreader or --disable-xmlreader was given.
 if test "${enable_xmlreader+set}" = set; then
   enableval="$enable_xmlreader"
@@ -100958,7 +100900,7 @@ if test -z "$PHP_LIBXML_DIR"; then
 php_with_libxml_dir=no
 
 echo $ac_n "checking libxml2 install dir""... $ac_c" 1>&6
-echo "configure:100962: checking libxml2 install dir" >&5
+echo "configure:100904: checking libxml2 install dir" >&5
 # Check whether --with-libxml-dir or --without-libxml-dir was given.
 if test "${with_libxml_dir+set}" = set; then
   withval="$with_libxml_dir"
@@ -100989,7 +100931,7 @@ if test "$PHP_XMLREADER" != "no"; then
 
   
 echo $ac_n "checking for xml2-config path""... $ac_c" 1>&6
-echo "configure:100993: checking for xml2-config path" >&5
+echo "configure:100935: checking for xml2-config path" >&5
 if eval "test \"`echo '$''{'ac_cv_php_xml2_config_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -101147,7 +101089,7 @@ echo "$ac_t""$ac_cv_php_xml2_config_path" 1>&6
 
 
             echo $ac_n "checking whether libxml build works""... $ac_c" 1>&6
-echo "configure:101151: checking whether libxml build works" >&5
+echo "configure:101093: checking whether libxml build works" >&5
 if eval "test \"`echo '$''{'php_cv_libxml_build_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -101163,7 +101105,7 @@ else
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 101167 "configure"
+#line 101109 "configure"
 #include "confdefs.h"
 
     
@@ -101174,7 +101116,7 @@ else
     }
   
 EOF
-if { (eval echo configure:101178: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:101120: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     LIBS=$old_LIBS
@@ -101556,7 +101498,7 @@ fi
 php_with_xmlrpc=no
 
 echo $ac_n "checking for XMLRPC-EPI support""... $ac_c" 1>&6
-echo "configure:101560: checking for XMLRPC-EPI support" >&5
+echo "configure:101502: checking for XMLRPC-EPI support" >&5
 # Check whether --with-xmlrpc or --without-xmlrpc was given.
 if test "${with_xmlrpc+set}" = set; then
   withval="$with_xmlrpc"
@@ -101604,7 +101546,7 @@ if test -z "$PHP_LIBXML_DIR"; then
 php_with_libxml_dir=no
 
 echo $ac_n "checking libxml2 install dir""... $ac_c" 1>&6
-echo "configure:101608: checking libxml2 install dir" >&5
+echo "configure:101550: checking libxml2 install dir" >&5
 # Check whether --with-libxml-dir or --without-libxml-dir was given.
 if test "${with_libxml_dir+set}" = set; then
   withval="$with_libxml_dir"
@@ -101631,7 +101573,7 @@ fi
 php_with_libexpat_dir=no
 
 echo $ac_n "checking libexpat dir for XMLRPC-EPI""... $ac_c" 1>&6
-echo "configure:101635: checking libexpat dir for XMLRPC-EPI" >&5
+echo "configure:101577: checking libexpat dir for XMLRPC-EPI" >&5
 # Check whether --with-libexpat-dir or --without-libexpat-dir was given.
 if test "${with_libexpat_dir+set}" = set; then
   withval="$with_libexpat_dir"
@@ -101657,7 +101599,7 @@ echo "$ac_t""$ext_output" 1>&6
 php_with_iconv_dir=no
 
 echo $ac_n "checking iconv dir for XMLRPC-EPI""... $ac_c" 1>&6
-echo "configure:101661: checking iconv dir for XMLRPC-EPI" >&5
+echo "configure:101603: checking iconv dir for XMLRPC-EPI" >&5
 # Check whether --with-iconv-dir or --without-iconv-dir was given.
 if test "${with_iconv_dir+set}" = set; then
   withval="$with_iconv_dir"
@@ -101716,7 +101658,7 @@ EOF
 
     
 echo $ac_n "checking for xml2-config path""... $ac_c" 1>&6
-echo "configure:101720: checking for xml2-config path" >&5
+echo "configure:101662: checking for xml2-config path" >&5
 if eval "test \"`echo '$''{'ac_cv_php_xml2_config_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -101874,7 +101816,7 @@ echo "$ac_t""$ac_cv_php_xml2_config_path" 1>&6
 
 
             echo $ac_n "checking whether libxml build works""... $ac_c" 1>&6
-echo "configure:101878: checking whether libxml build works" >&5
+echo "configure:101820: checking whether libxml build works" >&5
 if eval "test \"`echo '$''{'php_cv_libxml_build_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -101890,7 +101832,7 @@ else
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 101894 "configure"
+#line 101836 "configure"
 #include "confdefs.h"
 
     
@@ -101901,7 +101843,7 @@ else
     }
   
 EOF
-if { (eval echo configure:101905: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:101847: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     LIBS=$old_LIBS
@@ -102169,12 +102111,12 @@ EOF
 
         if test "$PHP_ICONV" = "yes"; then
     echo $ac_n "checking for iconv""... $ac_c" 1>&6
-echo "configure:102173: checking for iconv" >&5
+echo "configure:102115: checking for iconv" >&5
 if eval "test \"`echo '$''{'ac_cv_func_iconv'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 102178 "configure"
+#line 102120 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char iconv(); below.  */
@@ -102197,7 +102139,7 @@ iconv();
 
 ; return 0; }
 EOF
-if { (eval echo configure:102201: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:102143: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_iconv=yes"
 else
@@ -102218,12 +102160,12 @@ else
   echo "$ac_t""no" 1>&6
 
       echo $ac_n "checking for libiconv""... $ac_c" 1>&6
-echo "configure:102222: checking for libiconv" >&5
+echo "configure:102164: checking for libiconv" >&5
 if eval "test \"`echo '$''{'ac_cv_func_libiconv'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 102227 "configure"
+#line 102169 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char libiconv(); below.  */
@@ -102246,7 +102188,7 @@ libiconv();
 
 ; return 0; }
 EOF
-if { (eval echo configure:102250: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:102192: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_libiconv=yes"
 else
@@ -102402,7 +102344,7 @@ EOF
   done
 
   echo $ac_n "checking for libiconv in -l$iconv_lib_name""... $ac_c" 1>&6
-echo "configure:102406: checking for libiconv in -l$iconv_lib_name" >&5
+echo "configure:102348: checking for libiconv in -l$iconv_lib_name" >&5
 ac_lib_var=`echo $iconv_lib_name'_'libiconv | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -102410,7 +102352,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$iconv_lib_name  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 102414 "configure"
+#line 102356 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -102421,7 +102363,7 @@ int main() {
 libiconv()
 ; return 0; }
 EOF
-if { (eval echo configure:102425: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:102367: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -102555,7 +102497,7 @@ else
   done
 
   echo $ac_n "checking for iconv in -l$iconv_lib_name""... $ac_c" 1>&6
-echo "configure:102559: checking for iconv in -l$iconv_lib_name" >&5
+echo "configure:102501: checking for iconv in -l$iconv_lib_name" >&5
 ac_lib_var=`echo $iconv_lib_name'_'iconv | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -102563,7 +102505,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$iconv_lib_name  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 102567 "configure"
+#line 102509 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -102574,7 +102516,7 @@ int main() {
 iconv()
 ; return 0; }
 EOF
-if { (eval echo configure:102578: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:102520: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -102764,7 +102706,7 @@ if test "$PHP_XMLRPC" = "yes"; then
   # Extract the first word of "ranlib", so it can be a program name with args.
 set dummy ranlib; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:102768: checking for $ac_word" >&5
+echo "configure:102710: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -102792,21 +102734,21 @@ else
 fi
 
 echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:102796: checking for inline" >&5
+echo "configure:102738: checking for inline" >&5
 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   ac_cv_c_inline=no
 for ac_kw in inline __inline__ __inline; do
   cat > conftest.$ac_ext <<EOF
-#line 102803 "configure"
+#line 102745 "configure"
 #include "confdefs.h"
 
 int main() {
 } $ac_kw foo() {
 ; return 0; }
 EOF
-if { (eval echo configure:102810: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:102752: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_inline=$ac_kw; break
 else
@@ -102844,12 +102786,12 @@ EOF
 
 
 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:102848: checking for ANSI C header files" >&5
+echo "configure:102790: checking for ANSI C header files" >&5
 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 102853 "configure"
+#line 102795 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 #include <stdarg.h>
@@ -102857,7 +102799,7 @@ else
 #include <float.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:102861: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:102803: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -102874,7 +102816,7 @@ rm -f conftest*
 if test $ac_cv_header_stdc = yes; then
   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 102878 "configure"
+#line 102820 "configure"
 #include "confdefs.h"
 #include <string.h>
 EOF
@@ -102892,7 +102834,7 @@ fi
 if test $ac_cv_header_stdc = yes; then
   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 102896 "configure"
+#line 102838 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 EOF
@@ -102913,7 +102855,7 @@ if test "$cross_compiling" = yes; then
   :
 else
   cat > conftest.$ac_ext <<EOF
-#line 102917 "configure"
+#line 102859 "configure"
 #include "confdefs.h"
 #include <ctype.h>
 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -102924,7 +102866,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
 exit (0); }
 
 EOF
-if { (eval echo configure:102928: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:102870: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   :
 else
@@ -102951,17 +102893,17 @@ for ac_hdr in xmlparse.h xmltok.h stdlib.h strings.h string.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:102955: checking for $ac_hdr" >&5
+echo "configure:102897: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 102960 "configure"
+#line 102902 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:102965: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:102907: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -102993,7 +102935,7 @@ done
 
 
 echo $ac_n "checking size of char""... $ac_c" 1>&6
-echo "configure:102997: checking size of char" >&5
+echo "configure:102939: checking size of char" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_char'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -103001,7 +102943,7 @@ else
   ac_cv_sizeof_char=1
 else
   cat > conftest.$ac_ext <<EOF
-#line 103005 "configure"
+#line 102947 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -103012,7 +102954,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:103016: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:102958: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_char=`cat conftestval`
 else
@@ -103033,7 +102975,7 @@ EOF
 
 
 echo $ac_n "checking size of int""... $ac_c" 1>&6
-echo "configure:103037: checking size of int" >&5
+echo "configure:102979: checking size of int" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -103041,7 +102983,7 @@ else
   ac_cv_sizeof_int=4
 else
   cat > conftest.$ac_ext <<EOF
-#line 103045 "configure"
+#line 102987 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -103052,7 +102994,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:103056: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:102998: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_int=`cat conftestval`
 else
@@ -103072,7 +103014,7 @@ EOF
 
 
 echo $ac_n "checking size of long""... $ac_c" 1>&6
-echo "configure:103076: checking size of long" >&5
+echo "configure:103018: checking size of long" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -103080,7 +103022,7 @@ else
   ac_cv_sizeof_long=4
 else
   cat > conftest.$ac_ext <<EOF
-#line 103084 "configure"
+#line 103026 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -103091,7 +103033,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:103095: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:103037: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long=`cat conftestval`
 else
@@ -103111,7 +103053,7 @@ EOF
 
 
 echo $ac_n "checking size of long long""... $ac_c" 1>&6
-echo "configure:103115: checking size of long long" >&5
+echo "configure:103057: checking size of long long" >&5
 if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -103119,7 +103061,7 @@ else
   ac_cv_sizeof_long_long=8
 else
   cat > conftest.$ac_ext <<EOF
-#line 103123 "configure"
+#line 103065 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main()
@@ -103130,7 +103072,7 @@ int main()
   return(0);
 }
 EOF
-if { (eval echo configure:103134: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:103076: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_sizeof_long_long=`cat conftestval`
 else
@@ -103150,12 +103092,12 @@ EOF
 
 
 echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:103154: checking for size_t" >&5
+echo "configure:103096: checking for size_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 103159 "configure"
+#line 103101 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -103183,12 +103125,12 @@ EOF
 fi
 
 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
-echo "configure:103187: checking whether time.h and sys/time.h may both be included" >&5
+echo "configure:103129: checking whether time.h and sys/time.h may both be included" >&5
 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 103192 "configure"
+#line 103134 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/time.h>
@@ -103197,7 +103139,7 @@ int main() {
 struct tm *tp;
 ; return 0; }
 EOF
-if { (eval echo configure:103201: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:103143: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_header_time=yes
 else
@@ -103218,12 +103160,12 @@ EOF
 fi
 
 echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
-echo "configure:103222: checking for uid_t in sys/types.h" >&5
+echo "configure:103164: checking for uid_t in sys/types.h" >&5
 if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 103227 "configure"
+#line 103169 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 EOF
@@ -103263,12 +103205,12 @@ for ac_func in \
  memcpy memmove
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:103267: checking for $ac_func" >&5
+echo "configure:103209: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 103272 "configure"
+#line 103214 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -103291,7 +103233,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:103295: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:103237: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -103645,7 +103587,7 @@ elif test "$PHP_XMLRPC" != "no"; then
     XMLRPC_DIR=$PHP_XMLRPC/include/xmlrpc-epi
   else
     echo $ac_n "checking for XMLRPC-EPI in default path""... $ac_c" 1>&6
-echo "configure:103649: checking for XMLRPC-EPI in default path" >&5
+echo "configure:103591: checking for XMLRPC-EPI in default path" >&5
     for i in /usr/local /usr; do
       if test -r $i/include/xmlrpc.h; then
         XMLRPC_DIR=$i/include
@@ -104088,7 +104030,7 @@ fi
 php_enable_xmlwriter=yes
 
 echo $ac_n "checking whether to enable XMLWriter support""... $ac_c" 1>&6
-echo "configure:104092: checking whether to enable XMLWriter support" >&5
+echo "configure:104034: checking whether to enable XMLWriter support" >&5
 # Check whether --enable-xmlwriter or --disable-xmlwriter was given.
 if test "${enable_xmlwriter+set}" = set; then
   enableval="$enable_xmlwriter"
@@ -104136,7 +104078,7 @@ if test -z "$PHP_LIBXML_DIR"; then
 php_with_libxml_dir=no
 
 echo $ac_n "checking libxml2 install dir""... $ac_c" 1>&6
-echo "configure:104140: checking libxml2 install dir" >&5
+echo "configure:104082: checking libxml2 install dir" >&5
 # Check whether --with-libxml-dir or --without-libxml-dir was given.
 if test "${with_libxml_dir+set}" = set; then
   withval="$with_libxml_dir"
@@ -104167,7 +104109,7 @@ if test "$PHP_XMLWRITER" != "no"; then
 
   
 echo $ac_n "checking for xml2-config path""... $ac_c" 1>&6
-echo "configure:104171: checking for xml2-config path" >&5
+echo "configure:104113: checking for xml2-config path" >&5
 if eval "test \"`echo '$''{'ac_cv_php_xml2_config_path'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -104325,7 +104267,7 @@ echo "$ac_t""$ac_cv_php_xml2_config_path" 1>&6
 
 
             echo $ac_n "checking whether libxml build works""... $ac_c" 1>&6
-echo "configure:104329: checking whether libxml build works" >&5
+echo "configure:104271: checking whether libxml build works" >&5
 if eval "test \"`echo '$''{'php_cv_libxml_build_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -104341,7 +104283,7 @@ else
   
 else
   cat > conftest.$ac_ext <<EOF
-#line 104345 "configure"
+#line 104287 "configure"
 #include "confdefs.h"
 
     
@@ -104352,7 +104294,7 @@ else
     }
   
 EOF
-if { (eval echo configure:104356: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:104298: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
     LIBS=$old_LIBS
@@ -104702,7 +104644,7 @@ fi
 php_with_xsl=no
 
 echo $ac_n "checking for XSL support""... $ac_c" 1>&6
-echo "configure:104706: checking for XSL support" >&5
+echo "configure:104648: checking for XSL support" >&5
 # Check whether --with-xsl or --without-xsl was given.
 if test "${with_xsl+set}" = set; then
   withval="$with_xsl"
@@ -104905,7 +104847,7 @@ if test "$PHP_XSL" != "no"; then
 
       
       echo $ac_n "checking for EXSLT support""... $ac_c" 1>&6
-echo "configure:104909: checking for EXSLT support" >&5
+echo "configure:104851: checking for EXSLT support" >&5
       for i in $PHP_XSL /usr/local /usr; do
         if test -r "$i/include/libexslt/exslt.h"; then
           PHP_XSL_EXSL_DIR=$i
@@ -105381,7 +105323,7 @@ fi
 php_enable_zip=no
 
 echo $ac_n "checking for zip archive read/writesupport""... $ac_c" 1>&6
-echo "configure:105385: checking for zip archive read/writesupport" >&5
+echo "configure:105327: checking for zip archive read/writesupport" >&5
 # Check whether --enable-zip or --disable-zip was given.
 if test "${enable_zip+set}" = set; then
   enableval="$enable_zip"
@@ -105429,7 +105371,7 @@ if test -z "$PHP_ZLIB_DIR"; then
 php_with_zlib_dir=no
 
 echo $ac_n "checking for the location of libz""... $ac_c" 1>&6
-echo "configure:105433: checking for the location of libz" >&5
+echo "configure:105375: checking for the location of libz" >&5
 # Check whether --with-zlib-dir or --without-zlib-dir was given.
 if test "${with_zlib_dir+set}" = set; then
   withval="$with_zlib_dir"
@@ -105477,7 +105419,7 @@ if test "$PHP_ZIP" != "no"; then
 	fi
 
 		echo $ac_n "checking for the location of zlib""... $ac_c" 1>&6
-echo "configure:105481: checking for the location of zlib" >&5
+echo "configure:105423: checking for the location of zlib" >&5
 	if test "$PHP_ZLIB_DIR" = "no"; then
 		{ echo "configure: error: zip support requires ZLIB. Use --with-zlib-dir=<DIR> to specify prefix where ZLIB include and library are located" 1>&2; exit 1; }
 	else
@@ -105977,6 +105919,7 @@ case $php_build_target in
 esac
 
 EXTRA_LIBS="$EXTRA_LIBS $DLIBS $LIBS"
+EXTRA_LDFLAGS="$EXTRA_LDFLAGS $LDFLAGS"
 
 if test "$ac_cv_lib_crypt_crypt" = "yes"; then
   EXTRA_LIBS="-lcrypt $EXTRA_LIBS -lcrypt"
@@ -106012,7 +105955,7 @@ fi
 php_with_pear=DEFAULT
 
 echo $ac_n "checking whether to install PEAR""... $ac_c" 1>&6
-echo "configure:106016: checking whether to install PEAR" >&5
+echo "configure:105959: checking whether to install PEAR" >&5
 # Check whether --with-pear or --without-pear was given.
 if test "${with_pear+set}" = set; then
   withval="$with_pear"
@@ -106122,7 +106065,7 @@ fi
   bison_version=none
   if test "$YACC"; then
     echo $ac_n "checking for bison version""... $ac_c" 1>&6
-echo "configure:106126: checking for bison version" >&5
+echo "configure:106069: checking for bison version" >&5
 if eval "test \"`echo '$''{'php_cv_bison_version'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -106179,17 +106122,17 @@ dlfcn.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:106183: checking for $ac_hdr" >&5
+echo "configure:106126: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 106188 "configure"
+#line 106131 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:106193: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:106136: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -106217,12 +106160,12 @@ done
 
 
 echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:106221: checking for size_t" >&5
+echo "configure:106164: checking for size_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 106226 "configure"
+#line 106169 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -106250,12 +106193,12 @@ EOF
 fi
 
 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
-echo "configure:106254: checking return type of signal handlers" >&5
+echo "configure:106197: checking return type of signal handlers" >&5
 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 106259 "configure"
+#line 106202 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <signal.h>
@@ -106272,7 +106215,7 @@ int main() {
 int i;
 ; return 0; }
 EOF
-if { (eval echo configure:106276: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:106219: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_type_signal=void
 else
@@ -106296,12 +106239,12 @@ EOF
 
 
 echo $ac_n "checking for uint""... $ac_c" 1>&6
-echo "configure:106300: checking for uint" >&5
+echo "configure:106243: checking for uint" >&5
 if eval "test \"`echo '$''{'ac_cv_type_uint'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 106305 "configure"
+#line 106248 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -106329,12 +106272,12 @@ EOF
 fi
 
 echo $ac_n "checking for ulong""... $ac_c" 1>&6
-echo "configure:106333: checking for ulong" >&5
+echo "configure:106276: checking for ulong" >&5
 if eval "test \"`echo '$''{'ac_cv_type_ulong'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 106338 "configure"
+#line 106281 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -106364,9 +106307,9 @@ fi
 
 
 echo $ac_n "checking for int32_t""... $ac_c" 1>&6
-echo "configure:106368: checking for int32_t" >&5
+echo "configure:106311: checking for int32_t" >&5
 cat > conftest.$ac_ext <<EOF
-#line 106370 "configure"
+#line 106313 "configure"
 #include "confdefs.h"
 
 #if HAVE_SYS_TYPES_H  
@@ -106385,7 +106328,7 @@ if (sizeof (int32_t))
 
 ; return 0; }
 EOF
-if { (eval echo configure:106389: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:106332: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
   cat >> confdefs.h <<EOF
@@ -106404,9 +106347,9 @@ fi
 rm -f conftest*
 
 echo $ac_n "checking for uint32_t""... $ac_c" 1>&6
-echo "configure:106408: checking for uint32_t" >&5
+echo "configure:106351: checking for uint32_t" >&5
 cat > conftest.$ac_ext <<EOF
-#line 106410 "configure"
+#line 106353 "configure"
 #include "confdefs.h"
 
 #if HAVE_SYS_TYPES_H  
@@ -106425,7 +106368,7 @@ if (sizeof (uint32_t))
 
 ; return 0; }
 EOF
-if { (eval echo configure:106429: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:106372: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
   cat >> confdefs.h <<EOF
@@ -106444,12 +106387,12 @@ fi
 rm -f conftest*
 
 echo $ac_n "checking for vprintf""... $ac_c" 1>&6
-echo "configure:106448: checking for vprintf" >&5
+echo "configure:106391: checking for vprintf" >&5
 if eval "test \"`echo '$''{'ac_cv_func_vprintf'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 106453 "configure"
+#line 106396 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char vprintf(); below.  */
@@ -106472,7 +106415,7 @@ vprintf();
 
 ; return 0; }
 EOF
-if { (eval echo configure:106476: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:106419: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_vprintf=yes"
 else
@@ -106496,12 +106439,12 @@ fi
 
 if test "$ac_cv_func_vprintf" != yes; then
 echo $ac_n "checking for _doprnt""... $ac_c" 1>&6
-echo "configure:106500: checking for _doprnt" >&5
+echo "configure:106443: checking for _doprnt" >&5
 if eval "test \"`echo '$''{'ac_cv_func__doprnt'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 106505 "configure"
+#line 106448 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char _doprnt(); below.  */
@@ -106524,7 +106467,7 @@ _doprnt();
 
 ; return 0; }
 EOF
-if { (eval echo configure:106528: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:106471: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func__doprnt=yes"
 else
@@ -106549,7 +106492,7 @@ fi
 fi
 
 echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6
-echo "configure:106553: checking for 8-bit clean memcmp" >&5
+echo "configure:106496: checking for 8-bit clean memcmp" >&5
 if eval "test \"`echo '$''{'ac_cv_func_memcmp_clean'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -106557,7 +106500,7 @@ else
   ac_cv_func_memcmp_clean=no
 else
   cat > conftest.$ac_ext <<EOF
-#line 106561 "configure"
+#line 106504 "configure"
 #include "confdefs.h"
 
 main()
@@ -106567,7 +106510,7 @@ main()
 }
 
 EOF
-if { (eval echo configure:106571: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:106514: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_memcmp_clean=yes
 else
@@ -106587,19 +106530,19 @@ test $ac_cv_func_memcmp_clean = no && LIBOBJS="$LIBOBJS memcmp.${ac_objext}"
 # The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
 # for constant arguments.  Useless!
 echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:106591: checking for working alloca.h" >&5
+echo "configure:106534: checking for working alloca.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 106596 "configure"
+#line 106539 "configure"
 #include "confdefs.h"
 #include <alloca.h>
 int main() {
 char *p = alloca(2 * sizeof(int));
 ; return 0; }
 EOF
-if { (eval echo configure:106603: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:106546: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_cv_header_alloca_h=yes
 else
@@ -106620,12 +106563,12 @@ EOF
 fi
 
 echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:106624: checking for alloca" >&5
+echo "configure:106567: checking for alloca" >&5
 if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 106629 "configure"
+#line 106572 "configure"
 #include "confdefs.h"
 
 #ifdef __GNUC__
@@ -106653,7 +106596,7 @@ int main() {
 char *p = (char *) alloca(1);
 ; return 0; }
 EOF
-if { (eval echo configure:106657: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:106600: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_cv_func_alloca_works=yes
 else
@@ -106685,12 +106628,12 @@ EOF
 
 
 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:106689: checking whether alloca needs Cray hooks" >&5
+echo "configure:106632: checking whether alloca needs Cray hooks" >&5
 if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 106694 "configure"
+#line 106637 "configure"
 #include "confdefs.h"
 #if defined(CRAY) && ! defined(CRAY2)
 webecray
@@ -106715,12 +106658,12 @@ echo "$ac_t""$ac_cv_os_cray" 1>&6
 if test $ac_cv_os_cray = yes; then
 for ac_func in _getb67 GETB67 getb67; do
   echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:106719: checking for $ac_func" >&5
+echo "configure:106662: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 106724 "configure"
+#line 106667 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -106743,7 +106686,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:106747: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:106690: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -106770,7 +106713,7 @@ done
 fi
 
 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:106774: checking stack direction for C alloca" >&5
+echo "configure:106717: checking stack direction for C alloca" >&5
 if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -106778,7 +106721,7 @@ else
   ac_cv_c_stack_direction=0
 else
   cat > conftest.$ac_ext <<EOF
-#line 106782 "configure"
+#line 106725 "configure"
 #include "confdefs.h"
 find_stack_direction ()
 {
@@ -106797,7 +106740,7 @@ main ()
   exit (find_stack_direction() < 0);
 }
 EOF
-if { (eval echo configure:106801: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:106744: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_c_stack_direction=1
 else
@@ -106821,12 +106764,12 @@ fi
 for ac_func in memcpy strdup getpid kill strtod strtol finite fpclass
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:106825: checking for $ac_func" >&5
+echo "configure:106768: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 106830 "configure"
+#line 106773 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -106849,7 +106792,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:106853: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:106796: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -106875,7 +106818,7 @@ done
 
 
   echo $ac_n "checking whether sprintf is broken""... $ac_c" 1>&6
-echo "configure:106879: checking whether sprintf is broken" >&5
+echo "configure:106822: checking whether sprintf is broken" >&5
 if eval "test \"`echo '$''{'ac_cv_broken_sprintf'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -106886,11 +106829,11 @@ else
     
 else
   cat > conftest.$ac_ext <<EOF
-#line 106890 "configure"
+#line 106833 "configure"
 #include "confdefs.h"
 main() {char buf[20];exit(sprintf(buf,"testing 123")!=11); }
 EOF
-if { (eval echo configure:106894: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:106837: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
       ac_cv_broken_sprintf=no
@@ -106924,12 +106867,12 @@ EOF
 for ac_func in finite isfinite isinf isnan
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:106928: checking for $ac_func" >&5
+echo "configure:106871: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 106933 "configure"
+#line 106876 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -106952,7 +106895,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:106956: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:106899: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -106979,13 +106922,13 @@ done
 
 
   echo $ac_n "checking whether fp_except is defined""... $ac_c" 1>&6
-echo "configure:106983: checking whether fp_except is defined" >&5
+echo "configure:106926: checking whether fp_except is defined" >&5
 if eval "test \"`echo '$''{'ac_cv_type_fp_except'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     cat > conftest.$ac_ext <<EOF
-#line 106989 "configure"
+#line 106932 "configure"
 #include "confdefs.h"
 
 #include <floatingpoint.h>
@@ -106996,7 +106939,7 @@ fp_except x = (fp_except) 0;
 
 ; return 0; }
 EOF
-if { (eval echo configure:107000: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:106943: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
      ac_cv_type_fp_except=yes
@@ -107026,17 +106969,17 @@ for ac_hdr in dlfcn.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:107030: checking for $ac_hdr" >&5
+echo "configure:106973: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 107035 "configure"
+#line 106978 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:107040: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:106983: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -107064,14 +107007,14 @@ done
 
 
 echo $ac_n "checking whether dlsym() requires a leading underscore in symbol names""... $ac_c" 1>&6
-echo "configure:107068: checking whether dlsym() requires a leading underscore in symbol names" >&5
+echo "configure:107011: checking whether dlsym() requires a leading underscore in symbol names" >&5
 if test "$cross_compiling" = yes; then :
   
 else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<EOF
-#line 107075 "configure"
+#line 107018 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -107128,11 +107071,13 @@ int main ()
       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
       /* dlclose (self); */
     }
+  else
+    puts (dlerror ());
 
     exit (status);
 }
 EOF
-  if { (eval echo configure:107136: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} 2>/dev/null; then
+  if { (eval echo configure:107081: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} 2>/dev/null; then
     (./conftest; exit; ) >&5 2>/dev/null
     lt_status=$?
     case x$lt_status in
@@ -107146,7 +107091,7 @@ EOF
 EOF
 
  ;;
-      x$lt_unknown|x*) 
+      x$lt_dlunknown|x*) 
   echo "$ac_t""no" 1>&6
  ;;
     esac
@@ -107215,23 +107160,23 @@ fi
 
 
 echo $ac_n "checking virtual machine dispatch method""... $ac_c" 1>&6
-echo "configure:107219: checking virtual machine dispatch method" >&5
+echo "configure:107164: checking virtual machine dispatch method" >&5
 echo "$ac_t""$PHP_ZEND_VM" 1>&6
 
 echo $ac_n "checking whether to enable thread-safety""... $ac_c" 1>&6
-echo "configure:107223: checking whether to enable thread-safety" >&5
+echo "configure:107168: checking whether to enable thread-safety" >&5
 echo "$ac_t""$ZEND_MAINTAINER_ZTS" 1>&6
 
 echo $ac_n "checking whether to enable inline optimization for GCC""... $ac_c" 1>&6
-echo "configure:107227: checking whether to enable inline optimization for GCC" >&5
+echo "configure:107172: checking whether to enable inline optimization for GCC" >&5
 echo "$ac_t""$ZEND_INLINE_OPTIMIZATION" 1>&6
 
 echo $ac_n "checking whether to enable Zend debugging""... $ac_c" 1>&6
-echo "configure:107231: checking whether to enable Zend debugging" >&5
+echo "configure:107176: checking whether to enable Zend debugging" >&5
 echo "$ac_t""$ZEND_DEBUG" 1>&6
 
 echo $ac_n "checking whether to enable Zend multibyte""... $ac_c" 1>&6
-echo "configure:107235: checking whether to enable Zend multibyte" >&5
+echo "configure:107180: checking whether to enable Zend multibyte" >&5
 echo "$ac_t""$ZEND_MULTIBYTE" 1>&6
 	
 case $PHP_ZEND_VM in
@@ -107304,21 +107249,21 @@ fi
 
 
 echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:107308: checking for inline" >&5
+echo "configure:107253: checking for inline" >&5
 if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   ac_cv_c_inline=no
 for ac_kw in inline __inline__ __inline; do
   cat > conftest.$ac_ext <<EOF
-#line 107315 "configure"
+#line 107260 "configure"
 #include "confdefs.h"
 
 int main() {
 } $ac_kw foo() {
 ; return 0; }
 EOF
-if { (eval echo configure:107322: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:107267: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_inline=$ac_kw; break
 else
@@ -107347,7 +107292,7 @@ esac
 
 
 echo $ac_n "checking target system is Darwin""... $ac_c" 1>&6
-echo "configure:107351: checking target system is Darwin" >&5
+echo "configure:107296: checking target system is Darwin" >&5
 if echo "$target" | grep "darwin" > /dev/null; then
   cat >> confdefs.h <<\EOF
 #define DARWIN 1
@@ -107359,7 +107304,7 @@ else
 fi
 
 echo $ac_n "checking for MM alignment and log values""... $ac_c" 1>&6
-echo "configure:107363: checking for MM alignment and log values" >&5
+echo "configure:107308: checking for MM alignment and log values" >&5
 
 if test "$cross_compiling" = yes; then
   
@@ -107367,7 +107312,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 107371 "configure"
+#line 107316 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -107403,7 +107348,7 @@ int main()
 }
 
 EOF
-if { (eval echo configure:107407: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:107352: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   LIBZEND_MM_ALIGN=`cat conftest.zend | cut -d ' ' -f 1`
@@ -107428,7 +107373,7 @@ fi
 echo "$ac_t""done" 1>&6
 
 echo $ac_n "checking for memory allocation using mmap(MAP_ANON)""... $ac_c" 1>&6
-echo "configure:107432: checking for memory allocation using mmap(MAP_ANON)" >&5
+echo "configure:107377: checking for memory allocation using mmap(MAP_ANON)" >&5
 
 if test "$cross_compiling" = yes; then
   
@@ -107436,7 +107381,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 107440 "configure"
+#line 107385 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -107472,7 +107417,7 @@ int main()
 }
 
 EOF
-if { (eval echo configure:107476: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:107421: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   cat >> confdefs.h <<\EOF
@@ -107494,7 +107439,7 @@ fi
 
 
 echo $ac_n "checking for memory allocation using mmap("/dev/zero")""... $ac_c" 1>&6
-echo "configure:107498: checking for memory allocation using mmap("/dev/zero")" >&5
+echo "configure:107443: checking for memory allocation using mmap("/dev/zero")" >&5
 
 if test "$cross_compiling" = yes; then
   
@@ -107502,7 +107447,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 107506 "configure"
+#line 107451 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -107548,7 +107493,7 @@ int main()
 }
 
 EOF
-if { (eval echo configure:107552: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:107497: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   cat >> confdefs.h <<\EOF
@@ -107572,12 +107517,12 @@ fi
 for ac_func in mremap
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:107576: checking for $ac_func" >&5
+echo "configure:107521: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 107581 "configure"
+#line 107526 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -107600,7 +107545,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:107604: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:107549: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -107667,17 +107612,17 @@ for ac_hdr in stdarg.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:107671: checking for $ac_hdr" >&5
+echo "configure:107616: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 107676 "configure"
+#line 107621 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:107681: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:107626: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -107754,7 +107699,7 @@ if test "$TSRM_PTH" != "no"; then
   
 
 echo $ac_n "checking for GNU Pth""... $ac_c" 1>&6
-echo "configure:107758: checking for GNU Pth" >&5
+echo "configure:107703: checking for GNU Pth" >&5
 PTH_PREFIX="`$TSRM_PTH --prefix`"
 if test -z "$PTH_PREFIX"; then
   echo "$ac_t""Please check your Pth installation" 1>&6
@@ -107784,17 +107729,17 @@ elif test "$TSRM_ST" != "no"; then
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:107788: checking for $ac_hdr" >&5
+echo "configure:107733: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 107793 "configure"
+#line 107738 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:107798: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:107743: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -107824,7 +107769,7 @@ done
 
   LIBS="$LIBS -lst"
   echo $ac_n "checking for SGI's State Threads""... $ac_c" 1>&6
-echo "configure:107828: checking for SGI's State Threads" >&5
+echo "configure:107773: checking for SGI's State Threads" >&5
   echo "$ac_t""yes" 1>&6
   cat >> confdefs.h <<\EOF
 #define TSRM_ST 1
@@ -107863,7 +107808,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 107867 "configure"
+#line 107812 "configure"
 #include "confdefs.h"
 
 #include <pthread.h>
@@ -107881,7 +107826,7 @@ int main() {
     return pthread_create(&thd, NULL, thread_routine, &data);
 } 
 EOF
-if { (eval echo configure:107885: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:107830: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   pthreads_working=yes
@@ -107901,7 +107846,7 @@ fi
   CFLAGS=$save_CFLAGS
 
   echo $ac_n "checking for pthreads_cflags""... $ac_c" 1>&6
-echo "configure:107905: checking for pthreads_cflags" >&5
+echo "configure:107850: checking for pthreads_cflags" >&5
 if eval "test \"`echo '$''{'ac_cv_pthreads_cflags'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -107923,7 +107868,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 107927 "configure"
+#line 107872 "configure"
 #include "confdefs.h"
 
 #include <pthread.h>
@@ -107941,7 +107886,7 @@ int main() {
     return pthread_create(&thd, NULL, thread_routine, &data);
 } 
 EOF
-if { (eval echo configure:107945: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:107890: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   pthreads_working=yes
@@ -107971,7 +107916,7 @@ fi
 echo "$ac_t""$ac_cv_pthreads_cflags" 1>&6
 
 echo $ac_n "checking for pthreads_lib""... $ac_c" 1>&6
-echo "configure:107975: checking for pthreads_lib" >&5
+echo "configure:107920: checking for pthreads_lib" >&5
 if eval "test \"`echo '$''{'ac_cv_pthreads_lib'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -107993,7 +107938,7 @@ if test "$cross_compiling" = yes; then
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 107997 "configure"
+#line 107942 "configure"
 #include "confdefs.h"
 
 #include <pthread.h>
@@ -108011,7 +107956,7 @@ int main() {
     return pthread_create(&thd, NULL, thread_routine, &data);
 } 
 EOF
-if { (eval echo configure:108015: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:107960: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
   pthreads_working=yes
@@ -108062,7 +108007,7 @@ EOF
 
 
   echo $ac_n "checking for POSIX threads""... $ac_c" 1>&6
-echo "configure:108066: checking for POSIX threads" >&5
+echo "configure:108011: checking for POSIX threads" >&5
   echo "$ac_t""yes" 1>&6
 fi
 
@@ -108146,6 +108091,7 @@ EXPANDED_PEAR_INSTALLDIR=`eval echo $PEAR_INSTALLDIR`
 EXPANDED_EXTENSION_DIR=`eval echo $EXTENSION_DIR`
 EXPANDED_LOCALSTATEDIR=`eval echo $localstatedir`
 EXPANDED_BINDIR=`eval echo $bindir`
+EXPANDED_SBINDIR=`eval echo $sbindir`
 EXPANDED_LIBDIR=$libdir
 EXPANDED_SYSCONFDIR=`eval echo $sysconfdir`
 EXPANDED_DATADIR=$datadir
@@ -108168,6 +108114,7 @@ datadir=$old_datadir
 
 
 
+
 if test -n "$php_ldflags_add_usr_lib"; then
   PHP_RPATHS="$PHP_RPATHS /usr/lib"
 fi
@@ -108294,6 +108241,7 @@ EOF
 
 
   PHP_INSTALLED_SAPIS="cli $PHP_SAPI"
+  PHP_EXECUTABLE="\$(top_builddir)/\$(SAPI_CLI_PATH)"
 else
   PHP_INSTALLED_SAPIS="$PHP_SAPI"
 fi
@@ -108306,6 +108254,9 @@ fi
 
 
 
+  PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_EXECUTABLE"
+
+
   PHP_VAR_SUBST="$PHP_VAR_SUBST PHP_CLI_TARGET"
 
 
@@ -108358,6 +108309,9 @@ fi
   PHP_VAR_SUBST="$PHP_VAR_SUBST bindir"
 
 
+  PHP_VAR_SUBST="$PHP_VAR_SUBST sbindir"
+
+
   PHP_VAR_SUBST="$PHP_VAR_SUBST exec_prefix"
 
 
@@ -108612,6 +108566,12 @@ fi
 
 LDFLAGS="$LDFLAGS $PHP_AIX_LDFLAGS"
 
+case $host_alias in
+*darwin9*|*darwin10*)
+	ac_cv_exeext=
+	;;
+esac
+
 
   
   
@@ -108694,7 +108654,7 @@ fi
 
 
 echo $ac_n "checking build system type""... $ac_c" 1>&6
-echo "configure:108698: checking build system type" >&5
+echo "configure:108658: checking build system type" >&5
 
 build_alias=$build
 case "$build_alias" in
@@ -108723,7 +108683,7 @@ ac_prog=ld
 if test "$GCC" = yes; then
   # Check if gcc -print-prog-name=ld gives a path.
   echo $ac_n "checking for ld used by $CC""... $ac_c" 1>&6
-echo "configure:108727: checking for ld used by $CC" >&5
+echo "configure:108687: checking for ld used by $CC" >&5
   case $host in
   *-*-mingw*)
     # gcc leaves a trailing carriage return which upsets mingw
@@ -108753,10 +108713,10 @@ echo "configure:108727: checking for ld used by $CC" >&5
   esac
 elif test "$with_gnu_ld" = yes; then
   echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
-echo "configure:108757: checking for GNU ld" >&5
+echo "configure:108717: checking for GNU ld" >&5
 else
   echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
-echo "configure:108760: checking for non-GNU ld" >&5
+echo "configure:108720: checking for non-GNU ld" >&5
 fi
 if eval "test \"`echo '$''{'lt_cv_path_LD'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -108795,7 +108755,7 @@ else
 fi
 test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
 echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
-echo "configure:108799: checking if the linker ($LD) is GNU ld" >&5
+echo "configure:108759: checking if the linker ($LD) is GNU ld" >&5
 if eval "test \"`echo '$''{'lt_cv_prog_gnu_ld'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -108815,7 +108775,7 @@ with_gnu_ld=$lt_cv_prog_gnu_ld
 
 
 echo $ac_n "checking for $LD option to reload object files""... $ac_c" 1>&6
-echo "configure:108819: checking for $LD option to reload object files" >&5
+echo "configure:108779: checking for $LD option to reload object files" >&5
 if eval "test \"`echo '$''{'lt_cv_ld_reload_flag'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -108832,7 +108792,7 @@ reload_cmds='$LD$reload_flag -o $output$reload_objs'
 case $host_os in
   darwin*)
     if test "$GCC" = yes; then
-      reload_cmds='$CC -nostdlib ${wl}-r -o $output$reload_objs'
+      reload_cmds='$LTCC $LTCFLAGS -nostdlib ${wl}-r -o $output$reload_objs'
     else
       reload_cmds='$LD$reload_flag -o $output$reload_objs'
     fi
@@ -108840,7 +108800,7 @@ case $host_os in
 esac
 
 echo $ac_n "checking for BSD-compatible nm""... $ac_c" 1>&6
-echo "configure:108844: checking for BSD-compatible nm" >&5
+echo "configure:108804: checking for BSD-compatible nm" >&5
 if eval "test \"`echo '$''{'lt_cv_path_NM'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -108848,36 +108808,43 @@ else
   # Let the user override the test.
   lt_cv_path_NM="$NM"
 else
-  lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
-  for ac_dir in $PATH /usr/ccs/bin /usr/ucb /bin; do
-    IFS="$lt_save_ifs"
-    test -z "$ac_dir" && ac_dir=.
-    tmp_nm="$ac_dir/${ac_tool_prefix}nm"
-    if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
-      # Check to see if the nm accepts a BSD-compat flag.
-      # Adding the `sed 1q' prevents false positives on HP-UX, which says:
-      #   nm: unknown option "B" ignored
-      # Tru64's nm complains that /dev/null is an invalid object file
-      case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
-      */dev/null* | *'Invalid file or object type'*)
-	lt_cv_path_NM="$tmp_nm -B"
-	break
-        ;;
-      *)
-	case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
-	*/dev/null*)
-	  lt_cv_path_NM="$tmp_nm -p"
+  lt_nm_to_check="${ac_tool_prefix}nm"
+  if test -n "$ac_tool_prefix" && test "$build" = "$host"; then
+    lt_nm_to_check="$lt_nm_to_check nm"
+  fi
+  for lt_tmp_nm in $lt_nm_to_check; do
+    lt_save_ifs="$IFS"; IFS=$PATH_SEPARATOR
+    for ac_dir in $PATH /usr/ccs/bin/elf /usr/ccs/bin /usr/ucb /bin; do
+      IFS="$lt_save_ifs"
+      test -z "$ac_dir" && ac_dir=.
+      tmp_nm="$ac_dir/$lt_tmp_nm"
+      if test -f "$tmp_nm" || test -f "$tmp_nm$ac_exeext" ; then
+	# Check to see if the nm accepts a BSD-compat flag.
+	# Adding the `sed 1q' prevents false positives on HP-UX, which says:
+	#   nm: unknown option "B" ignored
+	# Tru64's nm complains that /dev/null is an invalid object file
+	case `"$tmp_nm" -B /dev/null 2>&1 | sed '1q'` in
+	*/dev/null* | *'Invalid file or object type'*)
+	  lt_cv_path_NM="$tmp_nm -B"
 	  break
 	  ;;
 	*)
-	  lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
-	  continue # so that we can try to find one that supports BSD flags
+	  case `"$tmp_nm" -p /dev/null 2>&1 | sed '1q'` in
+	  */dev/null*)
+	    lt_cv_path_NM="$tmp_nm -p"
+	    break
+	    ;;
+	  *)
+	    lt_cv_path_NM=${lt_cv_path_NM="$tmp_nm"} # keep the first match, but
+	    continue # so that we can try to find one that supports BSD flags
+	    ;;
+	  esac
 	  ;;
 	esac
-      esac
-    fi
+      fi
+    done
+    IFS="$lt_save_ifs"
   done
-  IFS="$lt_save_ifs"
   test -z "$lt_cv_path_NM" && lt_cv_path_NM=nm
 fi
 fi
@@ -108885,8 +108852,8 @@ fi
 echo "$ac_t""$lt_cv_path_NM" 1>&6
 NM="$lt_cv_path_NM"
 
-echo $ac_n "checking how to recognise dependent libraries""... $ac_c" 1>&6
-echo "configure:108890: checking how to recognise dependent libraries" >&5
+echo $ac_n "checking how to recognize dependent libraries""... $ac_c" 1>&6
+echo "configure:108857: checking how to recognize dependent libraries" >&5
 if eval "test \"`echo '$''{'lt_cv_deplibs_check_method'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -108905,7 +108872,7 @@ lt_cv_deplibs_check_method='unknown'
 # whether `pass_all' will *always* work, you probably want this one.
 
 case $host_os in
-aix4* | aix5*)
+aix[4-9]*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
@@ -108927,16 +108894,22 @@ cygwin*)
 
 mingw* | pw32*)
   # Base MSYS/MinGW do not provide the 'file' command needed by
-  # func_win32_libid shell function, so use a weaker test based on 'objdump'.
-  lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
-  lt_cv_file_magic_cmd='$OBJDUMP -f'
+  # func_win32_libid shell function, so use a weaker test based on 'objdump',
+  # unless we find 'file', for example because we are cross-compiling.
+  if ( file / ) >/dev/null 2>&1; then
+    lt_cv_deplibs_check_method='file_magic ^x86 archive import|^x86 DLL'
+    lt_cv_file_magic_cmd='func_win32_libid'
+  else
+    lt_cv_deplibs_check_method='file_magic file format pei*-i386(.*architecture: i386)?'
+    lt_cv_file_magic_cmd='$OBJDUMP -f'
+  fi
   ;;
 
 darwin* | rhapsody*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
-freebsd* | kfreebsd*-gnu | dragonfly*)
+freebsd* | dragonfly*)
   if echo __ELF__ | $CC -E - | grep __ELF__ > /dev/null; then
     case $host_cpu in
     i*86 )
@@ -108974,6 +108947,11 @@ hpux10.20* | hpux11*)
   esac
   ;;
 
+interix[3-9]*)
+  # PIC code is broken on Interix 3.x, that's why |\.a not |_pic\.a here
+  lt_cv_deplibs_check_method='match_pattern /lib[^/]+(\.so|\.a)$'
+  ;;
+
 irix5* | irix6* | nonstopux*)
   case $LD in
   *-32|*"-32 ") libmagic=32-bit;;
@@ -108985,7 +108963,7 @@ irix5* | irix6* | nonstopux*)
   ;;
 
 # This must be Linux ELF.
-linux*)
+linux* | k*bsd*-gnu)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
@@ -109019,7 +108997,7 @@ osf3* | osf4* | osf5*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
-sco3.2v5*)
+rdos*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
@@ -109027,7 +109005,7 @@ solaris*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 
-sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
+sysv4 | sysv4.3*)
   case $host_vendor in
   motorola)
     lt_cv_deplibs_check_method='file_magic ELF [0-9][0-9]*-bit [ML]SB (shared object|dynamic lib) M[0-9][0-9]* Version [0-9]'
@@ -109048,10 +109026,13 @@ sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
   siemens)
     lt_cv_deplibs_check_method=pass_all
     ;;
+  pc)
+    lt_cv_deplibs_check_method=pass_all
+    ;;
   esac
   ;;
 
-sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7* | sysv4*uw2*)
+sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
   lt_cv_deplibs_check_method=pass_all
   ;;
 esac
@@ -109064,13 +109045,13 @@ deplibs_check_method=$lt_cv_deplibs_check_method
 test -z "$deplibs_check_method" && deplibs_check_method=unknown
 
 echo $ac_n "checking for object suffix""... $ac_c" 1>&6
-echo "configure:109068: checking for object suffix" >&5
+echo "configure:109049: checking for object suffix" >&5
 if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   rm -f conftest*
 echo 'int i = 1;' > conftest.$ac_ext
-if { (eval echo configure:109074: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:109055: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   for ac_file in conftest.*; do
     case $ac_file in
     *.c) ;;
@@ -109090,7 +109071,7 @@ ac_objext=$ac_cv_objext
 
 
 echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:109094: checking for executable suffix" >&5
+echo "configure:109075: checking for executable suffix" >&5
 if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -109100,7 +109081,7 @@ else
   rm -f conftest*
   echo 'int main () { return 0; }' > conftest.$ac_ext
   ac_cv_exeext=
-  if { (eval echo configure:109104: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+  if { (eval echo configure:109085: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
     for file in conftest.*; do
       case $file in
       *.c | *.o | *.obj) ;;
@@ -109124,6 +109105,9 @@ ac_exeext=$EXEEXT
 # If no C compiler was specified, use CC.
 LTCC=${LTCC-"$CC"}
 
+# If no C compiler flags were specified, use CFLAGS.
+LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
+
 # Allow CC to be a program name with arguments.
 compiler=$CC
 
@@ -109143,7 +109127,7 @@ case $host in
 ia64-*-hpux*)
   # Find out which ABI we are using.
   echo 'int i;' > conftest.$ac_ext
-  if { (eval echo configure:109147: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  if { (eval echo configure:109131: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     case `/usr/bin/file conftest.$ac_objext` in
     *ELF-32*)
       HPUX_IA64_MODE="32"
@@ -109157,8 +109141,8 @@ ia64-*-hpux*)
   ;;
 *-*-irix6*)
   # Find out which ABI we are using.
-  echo '#line 109161 "configure"' > conftest.$ac_ext
-  if { (eval echo configure:109162: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  echo '#line 109145 "configure"' > conftest.$ac_ext
+  if { (eval echo configure:109146: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
    if test "$lt_cv_prog_gnu_ld" = yes; then
     case `/usr/bin/file conftest.$ac_objext` in
     *32-bit*)
@@ -109188,13 +109172,17 @@ ia64-*-hpux*)
   rm -rf conftest*
   ;;
 
-x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
+x86_64-*kfreebsd*-gnu|x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*| \
+s390*-*linux*|sparc*-*linux*)
   # Find out which ABI we are using.
   echo 'int i;' > conftest.$ac_ext
-  if { (eval echo configure:109195: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  if { (eval echo configure:109180: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     case `/usr/bin/file conftest.o` in
     *32-bit*)
       case $host in
+        x86_64-*kfreebsd*-gnu)
+          LD="${LD-ld} -m elf_i386_fbsd"
+          ;;
         x86_64-*linux*)
           LD="${LD-ld} -m elf_i386"
           ;;
@@ -109211,6 +109199,9 @@ x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
       ;;
     *64-bit*)
       case $host in
+        x86_64-*kfreebsd*-gnu)
+          LD="${LD-ld} -m elf_x86_64_fbsd"
+          ;;
         x86_64-*linux*)
           LD="${LD-ld} -m elf_x86_64"
           ;;
@@ -109235,7 +109226,7 @@ x86_64-*linux*|ppc*-*linux*|powerpc*-*linux*|s390*-*linux*|sparc*-*linux*)
   SAVE_CFLAGS="$CFLAGS"
   CFLAGS="$CFLAGS -belf"
   echo $ac_n "checking whether the C compiler needs -belf""... $ac_c" 1>&6
-echo "configure:109239: checking whether the C compiler needs -belf" >&5
+echo "configure:109230: checking whether the C compiler needs -belf" >&5
 if eval "test \"`echo '$''{'lt_cv_cc_needs_belf'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -109248,14 +109239,14 @@ ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$a
 cross_compiling=$ac_cv_prog_cc_cross
 
      cat > conftest.$ac_ext <<EOF
-#line 109252 "configure"
+#line 109243 "configure"
 #include "confdefs.h"
 
 int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:109259: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:109250: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   lt_cv_cc_needs_belf=yes
 else
@@ -109280,6 +109271,26 @@ echo "$ac_t""$lt_cv_cc_needs_belf" 1>&6
     CFLAGS="$SAVE_CFLAGS"
   fi
   ;;
+sparc*-*solaris*)
+  # Find out which ABI we are using.
+  echo 'int i;' > conftest.$ac_ext
+  if { (eval echo configure:109278: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+    case `/usr/bin/file conftest.o` in
+    *64-bit*)
+      case $lt_cv_prog_gnu_ld in
+      yes*) LD="${LD-ld} -m elf64_sparc" ;;
+      *)
+        if ${LD-ld} -64 -r -o conftest2.o conftest.o >/dev/null 2>&1; then
+	  LD="${LD-ld} -64"
+	fi
+	;;
+      esac
+      ;;
+    esac
+  fi
+  rm -rf conftest*
+  ;;
+
 
 esac
 
@@ -109297,10 +109308,9 @@ fi
 
 
 # Autoconf 2.13's AC_OBJEXT and AC_EXEEXT macros only works for C compilers!
-
 # find the maximum length of command line arguments
 echo $ac_n "checking the maximum length of command line arguments""... $ac_c" 1>&6
-echo "configure:109304: checking the maximum length of command line arguments" >&5
+echo "configure:109314: checking the maximum length of command line arguments" >&5
 if eval "test \"`echo '$''{'lt_cv_sys_max_cmd_len'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -109347,44 +109357,64 @@ else
     elif test -x /usr/sbin/sysctl; then
       lt_cv_sys_max_cmd_len=`/usr/sbin/sysctl -n kern.argmax`
     else
-      lt_cv_sys_max_cmd_len=65536     # usable default for all BSDs
+      lt_cv_sys_max_cmd_len=65536	# usable default for all BSDs
     fi
     # And add a safety zone
     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
     lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
     ;;
+
+  interix*)
+    # We know the value 262144 and hardcode it with a safety zone (like BSD)
+    lt_cv_sys_max_cmd_len=196608
+    ;;
+
   osf*)
     # Dr. Hans Ekkehard Plesser reports seeing a kernel panic running configure
     # due to this test when exec_disable_arg_limit is 1 on Tru64. It is not
     # nice to cause kernel panics so lets avoid the loop below.
     # First set a reasonable default.
     lt_cv_sys_max_cmd_len=16384
-    # 
+    #
     if test -x /sbin/sysconfig; then
       case `/sbin/sysconfig -q proc exec_disable_arg_limit` in
         *1*) lt_cv_sys_max_cmd_len=-1 ;;
       esac
     fi
     ;;
+  sco3.2v5*)
+    lt_cv_sys_max_cmd_len=102400
+    ;;
+  sysv5* | sco5v6* | sysv4.2uw2*)
+    kargmax=`grep ARG_MAX /etc/conf/cf.d/stune 2>/dev/null`
+    if test -n "$kargmax"; then
+      lt_cv_sys_max_cmd_len=`echo $kargmax | sed 's/.*[ 	]//'`
+    else
+      lt_cv_sys_max_cmd_len=32768
+    fi
+    ;;
   *)
-    # If test is not a shell built-in, we'll probably end up computing a
-    # maximum length that is only half of the actual maximum length, but
-    # we can't tell.
-    SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
-    while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \
+    lt_cv_sys_max_cmd_len=`(getconf ARG_MAX) 2> /dev/null`
+    if test -n "$lt_cv_sys_max_cmd_len"; then
+      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 4`
+      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \* 3`
+    else
+      SHELL=${SHELL-${CONFIG_SHELL-/bin/sh}}
+      while (test "X"`$SHELL $0 --fallback-echo "X$teststring" 2>/dev/null` \
 	       = "XX$teststring") >/dev/null 2>&1 &&
-	    new_result=`expr "X$teststring" : ".*" 2>&1` &&
-	    lt_cv_sys_max_cmd_len=$new_result &&
-	    test $i != 17 # 1/2 MB should be enough
-    do
-      i=`expr $i + 1`
-      teststring=$teststring$teststring
-    done
-    teststring=
-    # Add a significant safety factor because C++ compilers can tack on massive
-    # amounts of additional arguments before passing them to the linker.
-    # It appears as though 1/2 is a usable value.
-    lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
+	      new_result=`expr "X$teststring" : ".*" 2>&1` &&
+	      lt_cv_sys_max_cmd_len=$new_result &&
+	      test $i != 17 # 1/2 MB should be enough
+      do
+        i=`expr $i + 1`
+        teststring=$teststring$teststring
+      done
+      teststring=
+      # Add a significant safety factor because C++ compilers can tack on massive
+      # amounts of additional arguments before passing them to the linker.
+      # It appears as though 1/2 is a usable value.
+      lt_cv_sys_max_cmd_len=`expr $lt_cv_sys_max_cmd_len \/ 2`
+    fi
     ;;
   esac
 
@@ -109399,9 +109429,10 @@ fi
 
 
 
+
 # Check for command to grab the raw symbol name followed by C symbol from nm.
 echo $ac_n "checking command to parse $NM output from $compiler object""... $ac_c" 1>&6
-echo "configure:109405: checking command to parse $NM output from $compiler object" >&5
+echo "configure:109436: checking command to parse $NM output from $compiler object" >&5
 if eval "test \"`echo '$''{'lt_cv_sys_global_symbol_pipe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -109436,7 +109467,7 @@ hpux*) # Its linker distinguishes data from code symbols
   lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
   lt_cv_sys_global_symbol_to_c_name_address="sed -n -e 's/^: \([^ ]*\) $/  {\\\"\1\\\", (lt_ptr) 0},/p' -e 's/^$symcode* \([^ ]*\) \([^ ]*\)$/  {\"\2\", (lt_ptr) \&\2},/p'"
   ;;
-linux*)
+linux* | k*bsd*-gnu)
   if test "$host_cpu" = ia64; then
     symcode='[ABCDGIRSTW]'
     lt_cv_sys_global_symbol_to_cdecl="sed -n -e 's/^T .* \(.*\)$/extern int \1();/p' -e 's/^$symcode* .* \(.*\)$/extern char \1;/p'"
@@ -109449,9 +109480,18 @@ irix* | nonstopux*)
 osf*)
   symcode='[BCDEGQRST]'
   ;;
-solaris* | sysv5*)
+solaris*)
   symcode='[BDRT]'
   ;;
+sco3.2v5*)
+  symcode='[DT]'
+  ;;
+sysv4.2uw2*)
+  symcode='[DT]'
+  ;;
+sysv5* | sco5v6* | unixware* | OpenUNIX*)
+  symcode='[ABDT]'
+  ;;
 sysv4)
   symcode='[DFNSTU]'
   ;;
@@ -109496,10 +109536,10 @@ void nm_test_func(){}
 int main(){nm_test_var='a';nm_test_func();return(0);}
 EOF
 
-  if { (eval echo configure:109500: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  if { (eval echo configure:109540: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     # Now try to grab the symbols.
     nlist=conftest.nm
-    if { (eval echo configure:109503: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\") 1>&5; (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5; } && test -s "$nlist"; then
+    if { (eval echo configure:109543: \"$NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist\") 1>&5; (eval $NM conftest.$ac_objext \| $lt_cv_sys_global_symbol_pipe \> $nlist) 2>&5; } && test -s "$nlist"; then
       # Try sorting and uniquifying the output.
       if sort "$nlist" | uniq > "$nlist"T; then
 	mv -f "$nlist"T "$nlist"
@@ -109550,7 +109590,7 @@ EOF
 	  lt_save_CFLAGS="$CFLAGS"
 	  LIBS="conftstm.$ac_objext"
 	  CFLAGS="$CFLAGS$lt_prog_compiler_no_builtin_flag"
-	  if { (eval echo configure:109554: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+	  if { (eval echo configure:109594: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
 	    pipe_works=yes
 	  fi
 	  LIBS="$lt_save_LIBS"
@@ -109568,7 +109608,7 @@ EOF
     echo "$progname: failed program was:" >&5
     cat conftest.$ac_ext >&5
   fi
-  rm -f conftest* conftst*
+  rm -rf conftest* conftst*
 
   # Do not use the global_symbol_pipe unless it works.
   if test "$pipe_works" = yes; then
@@ -109590,7 +109630,7 @@ else
 fi
 
 echo $ac_n "checking for objdir""... $ac_c" 1>&6
-echo "configure:109594: checking for objdir" >&5
+echo "configure:109634: checking for objdir" >&5
 if eval "test \"`echo '$''{'lt_cv_objdir'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -109656,7 +109696,7 @@ with_gnu_ld="$lt_cv_prog_gnu_ld"
 # 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 $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:109660: checking for $ac_word" >&5
+echo "configure:109700: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -109688,7 +109728,7 @@ if test -n "$ac_tool_prefix"; then
   # Extract the first word of "ar", so it can be a program name with args.
 set dummy ar; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:109692: checking for $ac_word" >&5
+echo "configure:109732: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_AR'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -109723,7 +109763,7 @@ fi
 # 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 $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:109727: checking for $ac_word" >&5
+echo "configure:109767: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -109755,7 +109795,7 @@ if test -n "$ac_tool_prefix"; then
   # Extract the first word of "ranlib", so it can be a program name with args.
 set dummy ranlib; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:109759: checking for $ac_word" >&5
+echo "configure:109799: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -109790,7 +109830,7 @@ fi
 # 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 $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:109794: checking for $ac_word" >&5
+echo "configure:109834: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -109822,7 +109862,7 @@ if test -n "$ac_tool_prefix"; then
   # Extract the first word of "strip", so it can be a program name with args.
 set dummy strip; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:109826: checking for $ac_word" >&5
+echo "configure:109866: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_STRIP'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -109864,6 +109904,7 @@ test -z "$AR_FLAGS" && AR_FLAGS=cru
 test -z "$AS" && AS=as
 test -z "$CC" && CC=cc
 test -z "$LTCC" && LTCC=$CC
+test -z "$LTCFLAGS" && LTCFLAGS=$CFLAGS
 test -z "$DLLTOOL" && DLLTOOL=dlltool
 test -z "$LD" && LD=ld
 test -z "$LN_S" && LN_S="ln -s"
@@ -109876,17 +109917,17 @@ test -z "$STRIP" && STRIP=:
 test -z "$ac_objext" && ac_objext=o
 
 # Determine commands to create old-style static archives.
-old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs$old_deplibs'
+old_archive_cmds='$AR $AR_FLAGS $oldlib$oldobjs'
 old_postinstall_cmds='chmod 644 $oldlib'
 old_postuninstall_cmds=
 
 if test -n "$RANLIB"; then
   case $host_os in
   openbsd*)
-    old_postinstall_cmds="\$RANLIB -t \$oldlib~$old_postinstall_cmds"
+    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB -t \$oldlib"
     ;;
   *)
-    old_postinstall_cmds="\$RANLIB \$oldlib~$old_postinstall_cmds"
+    old_postinstall_cmds="$old_postinstall_cmds~\$RANLIB \$oldlib"
     ;;
   esac
   old_archive_cmds="$old_archive_cmds~\$RANLIB \$oldlib"
@@ -109908,7 +109949,7 @@ case $deplibs_check_method in
 file_magic*)
   if test "$file_magic_cmd" = '$MAGIC_CMD'; then
     echo $ac_n "checking for ${ac_tool_prefix}file""... $ac_c" 1>&6
-echo "configure:109912: checking for ${ac_tool_prefix}file" >&5
+echo "configure:109953: checking for ${ac_tool_prefix}file" >&5
 if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -109968,7 +110009,7 @@ fi
 if test -z "$lt_cv_path_MAGIC_CMD"; then
   if test -n "$ac_tool_prefix"; then
     echo $ac_n "checking for file""... $ac_c" 1>&6
-echo "configure:109972: checking for file" >&5
+echo "configure:110013: checking for file" >&5
 if eval "test \"`echo '$''{'lt_cv_path_MAGIC_CMD'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -110034,6 +110075,234 @@ fi
   ;;
 esac
 
+
+  case $host_os in
+    rhapsody* | darwin*)
+    # Extract the first word of "${ac_tool_prefix}dsymutil", so it can be a program name with args.
+set dummy ${ac_tool_prefix}dsymutil; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:110085: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_DSYMUTIL'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$DSYMUTIL"; then
+  ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
+else
+  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_DSYMUTIL="${ac_tool_prefix}dsymutil"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+fi
+fi
+DSYMUTIL="$ac_cv_prog_DSYMUTIL"
+if test -n "$DSYMUTIL"; then
+  echo "$ac_t""$DSYMUTIL" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+
+if test -z "$ac_cv_prog_DSYMUTIL"; then
+if test -n "$ac_tool_prefix"; then
+  # Extract the first word of "dsymutil", so it can be a program name with args.
+set dummy dsymutil; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:110117: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_DSYMUTIL'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$DSYMUTIL"; then
+  ac_cv_prog_DSYMUTIL="$DSYMUTIL" # Let the user override the test.
+else
+  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_DSYMUTIL="dsymutil"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+  test -z "$ac_cv_prog_DSYMUTIL" && ac_cv_prog_DSYMUTIL=":"
+fi
+fi
+DSYMUTIL="$ac_cv_prog_DSYMUTIL"
+if test -n "$DSYMUTIL"; then
+  echo "$ac_t""$DSYMUTIL" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+else
+  DSYMUTIL=":"
+fi
+fi
+
+    # Extract the first word of "${ac_tool_prefix}nmedit", so it can be a program name with args.
+set dummy ${ac_tool_prefix}nmedit; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:110152: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_NMEDIT'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$NMEDIT"; then
+  ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
+else
+  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_NMEDIT="${ac_tool_prefix}nmedit"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+fi
+fi
+NMEDIT="$ac_cv_prog_NMEDIT"
+if test -n "$NMEDIT"; then
+  echo "$ac_t""$NMEDIT" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+
+if test -z "$ac_cv_prog_NMEDIT"; then
+if test -n "$ac_tool_prefix"; then
+  # Extract the first word of "nmedit", so it can be a program name with args.
+set dummy nmedit; ac_word=$2
+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
+echo "configure:110184: checking for $ac_word" >&5
+if eval "test \"`echo '$''{'ac_cv_prog_NMEDIT'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  if test -n "$NMEDIT"; then
+  ac_cv_prog_NMEDIT="$NMEDIT" # Let the user override the test.
+else
+  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
+  ac_dummy="$PATH"
+  for ac_dir in $ac_dummy; do
+    test -z "$ac_dir" && ac_dir=.
+    if test -f $ac_dir/$ac_word; then
+      ac_cv_prog_NMEDIT="nmedit"
+      break
+    fi
+  done
+  IFS="$ac_save_ifs"
+  test -z "$ac_cv_prog_NMEDIT" && ac_cv_prog_NMEDIT=":"
+fi
+fi
+NMEDIT="$ac_cv_prog_NMEDIT"
+if test -n "$NMEDIT"; then
+  echo "$ac_t""$NMEDIT" 1>&6
+else
+  echo "$ac_t""no" 1>&6
+fi
+
+else
+  NMEDIT=":"
+fi
+fi
+
+
+    echo $ac_n "checking for -single_module linker flag""... $ac_c" 1>&6
+echo "configure:110218: checking for -single_module linker flag" >&5
+if eval "test \"`echo '$''{'lt_cv_apple_cc_single_mod'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  lt_cv_apple_cc_single_mod=no
+      if test -z "${LT_MULTI_MODULE}"; then
+   # By default we will add the -single_module flag. You can override
+   # by either setting the environment variable LT_MULTI_MODULE
+   # non-empty at configure time, or by adding -multi_module to the
+   # link flags.
+   echo "int foo(void){return 1;}" > conftest.c
+   $LTCC $LTCFLAGS $LDFLAGS -o libconftest.dylib \
+     -dynamiclib ${wl}-single_module conftest.c
+   if test -f libconftest.dylib; then
+     lt_cv_apple_cc_single_mod=yes
+     rm -rf libconftest.dylib*
+   fi
+   rm conftest.c
+      fi
+fi
+
+echo "$ac_t""$lt_cv_apple_cc_single_mod" 1>&6
+    echo $ac_n "checking for -exported_symbols_list linker flag""... $ac_c" 1>&6
+echo "configure:110241: checking for -exported_symbols_list linker flag" >&5
+if eval "test \"`echo '$''{'lt_cv_ld_exported_symbols_list'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  lt_cv_ld_exported_symbols_list=no
+      save_LDFLAGS=$LDFLAGS
+      echo "_main" > conftest.sym
+      LDFLAGS="$LDFLAGS -Wl,-exported_symbols_list,conftest.sym"
+      
+cat > conftest.$ac_ext <<EOF
+#line 110251 "configure"
+#include "confdefs.h"
+int main() {
+; return 0; }
+EOF
+if { (eval echo configure:110256: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ lt_cv_ld_exported_symbols_list=yes
+  rm -rf conftest*
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&6
+lt_cv_ld_exported_symbols_list=no
+  rm -rf conftest*
+fi
+rm -f conftest*
+   LDFLAGS="$save_LDFLAGS"
+    
+fi
+
+echo "$ac_t""$lt_cv_ld_exported_symbols_list" 1>&6
+    case $host_os in
+    rhapsody* | darwin1.[0123])
+      _lt_dar_allow_undefined='${wl}-undefined ${wl}suppress' ;;
+    darwin1.*)
+     _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
+    darwin*)
+      # if running on 10.5 or later, the deployment target defaults
+      # to the OS version, if on x86, and 10.4, the deployment
+      # target defaults to 10.4. Don't you love it?
+      case ${MACOSX_DEPLOYMENT_TARGET-10.0},$host in
+   10.0,*86*-darwin8*|10.0,*-darwin[91]*)
+     _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
+   10.[012]*)
+     _lt_dar_allow_undefined='${wl}-flat_namespace ${wl}-undefined ${wl}suppress' ;;
+   10.*)
+     _lt_dar_allow_undefined='${wl}-undefined ${wl}dynamic_lookup' ;;
+      esac
+    ;;
+  esac
+    if test "$lt_cv_apple_cc_single_mod" = "yes"; then
+      _lt_dar_single_mod='$single_module'
+    fi
+    if test "$lt_cv_ld_exported_symbols_list" = "yes"; then
+      _lt_dar_export_syms=' ${wl}-exported_symbols_list,$output_objdir/${libname}-symbols.expsym'
+    else
+      _lt_dar_export_syms="~$NMEDIT -s \$output_objdir/\${libname}-symbols.expsym \${lib}"
+    fi
+    if test "$DSYMUTIL" != ":"; then
+      _lt_dsymutil="~$DSYMUTIL \$lib || :"
+    else
+      _lt_dsymutil=
+    fi
+    ;;
+  esac
+
+
 enable_dlopen=no
 enable_win32_dll=no
 
@@ -110075,94 +110344,34 @@ objext=o
 objext=$objext
 
 # Code to be used in simple compile tests
-lt_simple_compile_test_code="int some_variable = 0;\n"
+lt_simple_compile_test_code="int some_variable = 0;"
 
 # Code to be used in simple link tests
-lt_simple_link_test_code='int main(){return(0);}\n'
+lt_simple_link_test_code='int main(){return(0);}'
 
 
 # If no C compiler was specified, use CC.
 LTCC=${LTCC-"$CC"}
 
+# If no C compiler flags were specified, use CFLAGS.
+LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
+
 # Allow CC to be a program name with arguments.
 compiler=$CC
 
 
 # save warnings/boilerplate of simple test code
 ac_outfile=conftest.$ac_objext
-printf "$lt_simple_compile_test_code" >conftest.$ac_ext
-eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
+echo "$lt_simple_compile_test_code" >conftest.$ac_ext
+eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
 _lt_compiler_boilerplate=`cat conftest.err`
 $rm conftest*
 
 ac_outfile=conftest.$ac_objext
-printf "$lt_simple_link_test_code" >conftest.$ac_ext
-eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
+echo "$lt_simple_link_test_code" >conftest.$ac_ext
+eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
 _lt_linker_boilerplate=`cat conftest.err`
-$rm conftest*
-
-
-#
-# Check for any special shared library compilation flags.
-#
-lt_prog_cc_shlib=
-if test "$GCC" = no; then
-  case $host_os in
-  sco3.2v5*)
-    lt_prog_cc_shlib='-belf'
-    ;;
-  esac
-fi
-if test -n "$lt_prog_cc_shlib"; then
-  echo "configure: warning: \`$CC' requires \`$lt_prog_cc_shlib' to build shared libraries" 1>&2
-  if echo "$old_CC $old_CFLAGS " | grep "[ 	]$lt_prog_cc_shlib[ 	]" >/dev/null; then :
-  else
-    echo "configure: warning: add \`$lt_prog_cc_shlib' to the CC or CFLAGS env variable and reconfigure" 1>&2
-    lt_cv_prog_cc_can_build_shared=no
-  fi
-fi
-
-
-#
-# Check to make sure the static flag actually works.
-#
-echo $ac_n "checking if $compiler static flag $lt_prog_compiler_static works""... $ac_c" 1>&6
-echo "configure:110131: checking if $compiler static flag $lt_prog_compiler_static works" >&5
-if eval "test \"`echo '$''{'lt_prog_compiler_static_works'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  lt_prog_compiler_static_works=no
-   save_LDFLAGS="$LDFLAGS"
-   LDFLAGS="$LDFLAGS $lt_prog_compiler_static"
-   printf "$lt_simple_link_test_code" > conftest.$ac_ext
-   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
-     # The linker can only warn and ignore the option if not recognized
-     # So say no if there are warnings
-     if test -s conftest.err; then
-       # Append any errors to the config.log.
-       cat conftest.err 1>&5
-       $echo "X$_lt_linker_boilerplate" | $Xsed > conftest.exp
-       $SED '/^$/d' conftest.err >conftest.er2
-       if diff conftest.exp conftest.er2 >/dev/null; then
-         lt_prog_compiler_static_works=yes
-       fi
-     else
-       lt_prog_compiler_static_works=yes
-     fi
-   fi
-   $rm conftest*
-   LDFLAGS="$save_LDFLAGS"
-
-fi
-
-echo "$ac_t""$lt_prog_compiler_static_works" 1>&6
-
-if test x"$lt_prog_compiler_static_works" = xyes; then
-    :
-else
-    lt_prog_compiler_static=
-fi
-
+$rm -r conftest*
 
 
 ## CAVEAT EMPTOR:
@@ -110177,13 +110386,13 @@ if test "$GCC" = yes; then
 
   
 echo $ac_n "checking if $compiler supports -fno-rtti -fno-exceptions""... $ac_c" 1>&6
-echo "configure:110181: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
+echo "configure:110390: checking if $compiler supports -fno-rtti -fno-exceptions" >&5
 if eval "test \"`echo '$''{'lt_cv_prog_compiler_rtti_exceptions'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   lt_cv_prog_compiler_rtti_exceptions=no
   ac_outfile=conftest.$ac_objext
-   printf "$lt_simple_compile_test_code" > conftest.$ac_ext
+   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
    lt_compiler_flag="-fno-rtti -fno-exceptions"
    # Insert the option either (1) after the last *FLAGS variable, or
    # (2) before a word containing "conftest.", or (3) at the end.
@@ -110194,17 +110403,17 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"configure:110198: $lt_compile\"" >&5)
+   (eval echo "\"configure:110407: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "configure:110202: \$? = $ac_status" >&5
+   echo "configure:110411: \$? = $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.
-     $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
-     $SED '/^$/d' conftest.err >conftest.er2
-     if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
+     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
+     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
+     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
        lt_cv_prog_compiler_rtti_exceptions=yes
      fi
    fi
@@ -110227,7 +110436,7 @@ lt_prog_compiler_pic=
 lt_prog_compiler_static=
 
 echo $ac_n "checking for $compiler option to produce PIC""... $ac_c" 1>&6
-echo "configure:110231: checking for $compiler option to produce PIC" >&5
+echo "configure:110440: checking for $compiler option to produce PIC" >&5
  
   if test "$GCC" = yes; then
     lt_prog_compiler_wl='-Wl,'
@@ -110249,14 +110458,16 @@ echo "configure:110231: checking for $compiler option to produce PIC" >&5
       lt_prog_compiler_pic='-m68020 -resident32 -malways-restore-a4'
       ;;
 
-    beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
+    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
       # PIC is the default for these OSes.
       ;;
 
-    mingw* | pw32* | os2*)
+    mingw* | cygwin* | pw32* | os2*)
       # This hack is so that the source file can tell whether it is being
       # built for inclusion in a dll (and should export symbols for example).
-      lt_prog_compiler_pic='-DDLL_EXPORT'
+      # Although the cygwin gcc ignores -fPIC, still need this for old-style
+      # (--disable-auto-import) libraries
+	  lt_prog_compiler_pic='-DDLL_EXPORT'
       ;;
 
     darwin* | rhapsody*)
@@ -110265,6 +110476,11 @@ echo "configure:110231: checking for $compiler option to produce PIC" >&5
       lt_prog_compiler_pic='-fno-common'
       ;;
 
+    interix[3-9]*)
+      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
+      # Instead, we relocate shared libraries at runtime.
+      ;;
+
     msdosdjgpp*)
       # Just because we use GCC doesn't mean we suddenly get shared libraries
       # on systems that don't support them.
@@ -110318,10 +110534,10 @@ echo "configure:110231: checking for $compiler option to produce PIC" >&5
        esac
        ;;
 
-    mingw* | pw32* | os2*)
+    mingw* | cygwin* | pw32* | os2*)
       # This hack is so that the source file can tell whether it is being
       # built for inclusion in a dll (and should export symbols for example).
-      lt_prog_compiler_pic='-DDLL_EXPORT'
+	  lt_prog_compiler_pic='-DDLL_EXPORT'
       ;;
 
     hpux9* | hpux10* | hpux11*)
@@ -110351,7 +110567,7 @@ echo "configure:110231: checking for $compiler option to produce PIC" >&5
       lt_prog_compiler_static='-Bstatic'
       ;;
 
-    linux*)
+    linux* | k*bsd*-gnu)
       case $cc_basename in
       # old Intel for x86_64 which still supported -KPIC.
       ecc*)
@@ -110378,6 +110594,22 @@ echo "configure:110231: checking for $compiler option to produce PIC" >&5
         # All Alpha code is PIC.
         lt_prog_compiler_static='-non_shared'
         ;;
+      *)
+        case `$CC -V 2>&1 | sed 5q` in
+	*Sun\ C*)
+	  # Sun C 5.9
+	  lt_prog_compiler_pic='-KPIC'
+	  lt_prog_compiler_static='-Bstatic'
+	  lt_prog_compiler_wl='-Wl,'
+	  ;;
+	*Sun\ F*)
+	  # Sun Fortran 8.3 passes all unrecognized flags to the linker
+	  lt_prog_compiler_pic='-KPIC'
+	  lt_prog_compiler_static='-Bstatic'
+	  lt_prog_compiler_wl=''
+	  ;;
+	esac
+	;;
       esac
       ;;
 
@@ -110387,9 +110619,8 @@ echo "configure:110231: checking for $compiler option to produce PIC" >&5
       lt_prog_compiler_static='-non_shared'
       ;;
 
-    sco3.2v5*)
-      lt_prog_compiler_pic='-Kpic'
-      lt_prog_compiler_static='-dn'
+    rdos*)
+      lt_prog_compiler_static='-non_shared'
       ;;
 
     solaris*)
@@ -110409,7 +110640,7 @@ echo "configure:110231: checking for $compiler option to produce PIC" >&5
       lt_prog_compiler_static='-Bstatic'
       ;;
 
-    sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
+    sysv4 | sysv4.2uw2* | sysv4.3*)
       lt_prog_compiler_wl='-Wl,'
       lt_prog_compiler_pic='-KPIC'
       lt_prog_compiler_static='-Bstatic'
@@ -110422,6 +110653,12 @@ echo "configure:110231: checking for $compiler option to produce PIC" >&5
       fi
       ;;
 
+    sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
+      lt_prog_compiler_wl='-Wl,'
+      lt_prog_compiler_pic='-KPIC'
+      lt_prog_compiler_static='-Bstatic'
+      ;;
+
     unicos*)
       lt_prog_compiler_wl='-Wl,'
       lt_prog_compiler_can_build_shared=no
@@ -110446,13 +110683,13 @@ echo "$ac_t""$lt_prog_compiler_pic" 1>&6
 if test -n "$lt_prog_compiler_pic"; then
   
 echo $ac_n "checking if $compiler PIC flag $lt_prog_compiler_pic works""... $ac_c" 1>&6
-echo "configure:110450: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
-if eval "test \"`echo '$''{'lt_prog_compiler_pic_works'+set}'`\" = set"; then
+echo "configure:110687: checking if $compiler PIC flag $lt_prog_compiler_pic works" >&5
+if eval "test \"`echo '$''{'lt_cv_prog_compiler_pic_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
-  lt_prog_compiler_pic_works=no
+  lt_cv_prog_compiler_pic_works=no
   ac_outfile=conftest.$ac_objext
-   printf "$lt_simple_compile_test_code" > conftest.$ac_ext
+   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
    lt_compiler_flag="$lt_prog_compiler_pic -DPIC"
    # Insert the option either (1) after the last *FLAGS variable, or
    # (2) before a word containing "conftest.", or (3) at the end.
@@ -110463,27 +110700,27 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"configure:110467: $lt_compile\"" >&5)
+   (eval echo "\"configure:110704: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "configure:110471: \$? = $ac_status" >&5
+   echo "configure:110708: \$? = $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.
-     $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
-     $SED '/^$/d' conftest.err >conftest.er2
-     if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
-       lt_prog_compiler_pic_works=yes
+     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
+     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
+     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
+       lt_cv_prog_compiler_pic_works=yes
      fi
    fi
    $rm conftest*
 
 fi
 
-echo "$ac_t""$lt_prog_compiler_pic_works" 1>&6
+echo "$ac_t""$lt_cv_prog_compiler_pic_works" 1>&6
 
-if test x"$lt_prog_compiler_pic_works" = xyes; then
+if test x"$lt_cv_prog_compiler_pic_works" = xyes; then
     case $lt_prog_compiler_pic in
      "" | " "*) ;;
      *) lt_prog_compiler_pic=" $lt_prog_compiler_pic" ;;
@@ -110504,8 +110741,50 @@ case $host_os in
     ;;
 esac
 
+#
+# Check to make sure the static flag actually works.
+#
+wl=$lt_prog_compiler_wl eval lt_tmp_static_flag=\"$lt_prog_compiler_static\"
+echo $ac_n "checking if $compiler static flag $lt_tmp_static_flag works""... $ac_c" 1>&6
+echo "configure:110750: checking if $compiler static flag $lt_tmp_static_flag works" >&5
+if eval "test \"`echo '$''{'lt_cv_prog_compiler_static_works'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  lt_cv_prog_compiler_static_works=no
+   save_LDFLAGS="$LDFLAGS"
+   LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
+   echo "$lt_simple_link_test_code" > conftest.$ac_ext
+   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
+     # The linker can only warn and ignore the option if not recognized
+     # So say no if there are warnings
+     if test -s conftest.err; then
+       # Append any errors to the config.log.
+       cat conftest.err 1>&5
+       $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
+       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
+       if diff conftest.exp conftest.er2 >/dev/null; then
+         lt_cv_prog_compiler_static_works=yes
+       fi
+     else
+       lt_cv_prog_compiler_static_works=yes
+     fi
+   fi
+   $rm -r conftest*
+   LDFLAGS="$save_LDFLAGS"
+
+fi
+
+echo "$ac_t""$lt_cv_prog_compiler_static_works" 1>&6
+
+if test x"$lt_cv_prog_compiler_static_works" = xyes; then
+    :
+else
+    lt_prog_compiler_static=
+fi
+
+
 echo $ac_n "checking if $compiler supports -c -o file.$ac_objext""... $ac_c" 1>&6
-echo "configure:110509: checking if $compiler supports -c -o file.$ac_objext" >&5
+echo "configure:110788: checking if $compiler supports -c -o file.$ac_objext" >&5
 if eval "test \"`echo '$''{'lt_cv_prog_compiler_c_o'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -110514,7 +110793,7 @@ else
    mkdir conftest
    cd conftest
    mkdir out
-   printf "$lt_simple_compile_test_code" > conftest.$ac_ext
+   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
    lt_compiler_flag="-o out/conftest2.$ac_objext"
    # Insert the option either (1) after the last *FLAGS variable, or
@@ -110525,18 +110804,18 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"configure:110529: $lt_compile\"" >&5)
+   (eval echo "\"configure:110808: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "configure:110533: \$? = $ac_status" >&5
+   echo "configure:110812: \$? = $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
      # So say no if there are warnings
-     $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp
-     $SED '/^$/d' out/conftest.err >out/conftest.er2
-     if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then
+     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
+     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
+     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
        lt_cv_prog_compiler_c_o=yes
      fi
    fi
@@ -110559,7 +110838,7 @@ 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 $ac_n "checking if we can lock with hard links""... $ac_c" 1>&6
-echo "configure:110563: checking if we can lock with hard links" >&5
+echo "configure:110842: checking if we can lock with hard links" >&5
   hard_links=yes
   $rm conftest*
   ln conftest.a conftest.b 2>/dev/null && hard_links=no
@@ -110576,7 +110855,7 @@ else
 fi
 
 echo $ac_n "checking whether the $compiler linker ($LD) supports shared libraries""... $ac_c" 1>&6
-echo "configure:110580: checking whether the $compiler linker ($LD) supports shared libraries" >&5
+echo "configure:110859: checking whether the $compiler linker ($LD) supports shared libraries" >&5
 
   runpath_var=
   allow_undefined_flag=
@@ -110607,12 +110886,13 @@ echo "configure:110580: checking whether the $compiler linker ($LD) supports sha
   # it will be wrapped by ` (' and `)$', so one must not match beginning or
   # end of line.  Example: `a|bc|.*d.*' will exclude the symbols `a' and `bc',
   # as well as any symbol that contains `d'.
-  exclude_expsyms="_GLOBAL_OFFSET_TABLE_"
+  exclude_expsyms='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
   # Although _GLOBAL_OFFSET_TABLE_ is a valid symbol C name, most a.out
   # platforms (ab)use it in PIC code, but their linkers get confused if
   # the symbol is explicitly referenced.  Since portable code cannot
   # rely on this symbol name, it's probably fine to never include it in
   # preloaded symbol tables.
+  # Exclude shared library initialization/finalization symbols.
   extract_expsyms_cmds=
   # Just being paranoid about ensuring that cc_basename is set.
   for cc_temp in $compiler""; do
@@ -110634,6 +110914,10 @@ cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
       with_gnu_ld=no
     fi
     ;;
+  interix*)
+    # we just hope/assume this is gcc and not c89 (= MSVC++)
+    with_gnu_ld=yes
+    ;;
   openbsd*)
     with_gnu_ld=no
     ;;
@@ -110643,7 +110927,7 @@ cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
   if test "$with_gnu_ld" = yes; then
     # If archive_cmds runs LD, not CC, wlarc should be empty
     wlarc='${wl}'
-    
+
     # Set some defaults for GNU ld with shared library support. These
     # are reset later if shared libraries are not supported. Putting them
     # here allows them to be overridden if necessary.
@@ -110664,10 +110948,10 @@ cc_basename=`$echo "X$cc_temp" | $Xsed -e 's%.*/%%' -e "s%^$host_alias-%%"`
       *\ 2.11.*) ;; # other 2.11 versions
       *) supports_anon_versioning=yes ;;
     esac
-    
+
     # See if GNU ld supports shared libraries.
     case $host_os in
-    aix3* | aix4* | aix5*)
+    aix[3-9]*)
       # On AIX/PPC, the GNU linker is very broken
       if test "$host_cpu" != ia64; then
 	ld_shlibs=no
@@ -110715,10 +110999,10 @@ EOF
       allow_undefined_flag=unsupported
       always_export_symbols=no
       enable_shared_with_static_runtimes=yes
-      export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS] /s/.* \([^ ]*\)/\1 DATA/'\'' | $SED -e '\''/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols'
+      export_symbols_cmds='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/'\'' -e '\''/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
 
       if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
-        archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
+        archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
 	# If the export-symbols file already is a .def file (1st line
 	# is EXPORTS), use it as is; otherwise, prepend...
 	archive_expsym_cmds='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
@@ -110727,13 +111011,28 @@ EOF
 	  echo EXPORTS > $output_objdir/$soname.def;
 	  cat $export_symbols >> $output_objdir/$soname.def;
 	fi~
-	$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000  ${wl}--out-implib,$lib'
+	$CC -shared $output_objdir/$soname.def $libobjs $deplibs $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
       else
 	ld_shlibs=no
       fi
       ;;
 
-    linux*)
+    interix[3-9]*)
+      hardcode_direct=no
+      hardcode_shlibpath_var=no
+      hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
+      export_dynamic_flag_spec='${wl}-E'
+      # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
+      # Instead, shared libraries are loaded at an image base (0x10000000 by
+      # default) and relocated if they conflict, which is a slow very memory
+      # consuming and fragmenting process.  To avoid this, we pick a random,
+      # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
+      # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
+      archive_cmds='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
+      archive_expsym_cmds='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
+      ;;
+
+    gnu* | linux* | k*bsd*-gnu)
       if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
 	tmp_addflag=
 	case $cc_basename,$host_cpu in
@@ -110741,7 +111040,7 @@ EOF
 	  whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
 	  tmp_addflag=' $pic_flag'
 	  ;;
-	pgf77* | pgf90* | pgf95*)			# Portland Group f77 and f90 compilers
+	pgf77* | pgf90* | pgf95*)	# Portland Group f77 and f90 compilers
 	  whole_archive_flag_spec='${wl}--whole-archive`for conv in $convenience\"\"; do test  -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
 	  tmp_addflag=' $pic_flag -Mnomain' ;;
 	ecc*,ia64* | icc*,ia64*)		# Intel C compiler on ia64
@@ -110751,13 +111050,22 @@ EOF
 	ifc* | ifort*)			# Intel Fortran compiler
 	  tmp_addflag=' -nofor_main' ;;
 	esac
-	archive_cmds='$CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+	case `$CC -V 2>&1 | sed 5q` in
+	*Sun\ C*)			# Sun C 5.9
+	  whole_archive_flag_spec='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
+	  tmp_sharedflag='-G' ;;
+	*Sun\ F*)			# Sun Fortran 8.3
+	  tmp_sharedflag='-G' ;;
+	*)
+	  tmp_sharedflag='-shared' ;;
+	esac
+	archive_cmds='$CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
 
 	if test $supports_anon_versioning = yes; then
 	  archive_expsym_cmds='$echo "{ global:" > $output_objdir/$libname.ver~
   cat $export_symbols | sed -e "s/\(.*\)/\1;/" >> $output_objdir/$libname.ver~
   $echo "local: *; };" >> $output_objdir/$libname.ver~
-	  $CC -shared'"$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
+	  $CC '"$tmp_sharedflag""$tmp_addflag"' $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname ${wl}-version-script ${wl}$output_objdir/$libname.ver -o $lib'
 	fi
       else
 	ld_shlibs=no
@@ -110774,7 +111082,7 @@ EOF
       fi
       ;;
 
-    solaris* | sysv5*)
+    solaris*)
       if $LD -v 2>&1 | grep 'BFD 2\.8' > /dev/null; then
 	ld_shlibs=no
 	cat <<EOF 1>&2
@@ -110795,6 +111103,33 @@ EOF
       fi
       ;;
 
+    sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX*)
+      case `$LD -v 2>&1` in
+        *\ [01].* | *\ 2.[0-9].* | *\ 2.1[0-5].*)
+	ld_shlibs=no
+	cat <<_LT_EOF 1>&2
+
+*** Warning: Releases of the GNU linker prior to 2.16.91.0.3 can not
+*** reliably create shared libraries on SCO systems.  Therefore, libtool
+*** is disabling shared libraries support.  We urge you to upgrade GNU
+*** binutils to release 2.16.91.0.3 or newer.  Another option is to modify
+*** your PATH or compiler configuration so that the native linker is
+*** used, and then restart.
+
+_LT_EOF
+	;;
+	*)
+	  if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
+	    hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-rpath,$libdir`'
+	    archive_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib'
+	    archive_expsym_cmds='$CC -shared $libobjs $deplibs $compiler_flags ${wl}-soname,\${SCOABSPATH:+${install_libdir}/}$soname,-retain-symbols-file,$export_symbols -o $lib'
+	  else
+	    ld_shlibs=no
+	  fi
+	;;
+      esac
+      ;;
+
     sunos4*)
       archive_cmds='$LD -assert pure-text -Bshareable -o $lib $libobjs $deplibs $linker_flags'
       wlarc=
@@ -110828,14 +111163,14 @@ EOF
       # Note: this linker hardcodes the directories in LIBPATH if there
       # are no directories specified by -L.
       hardcode_minus_L=yes
-      if test "$GCC" = yes && test -z "$link_static_flag"; then
+      if test "$GCC" = yes && test -z "$lt_prog_compiler_static"; then
 	# Neither direct hardcoding nor static linking is supported with a
 	# broken collect2.
 	hardcode_direct=unsupported
       fi
       ;;
 
-    aix4* | aix5*)
+    aix[4-9]*)
       if test "$host_cpu" = ia64; then
 	# On IA64, the linker does run time linking by default, so we don't
 	# have to do anything special.
@@ -110855,13 +111190,14 @@ EOF
 	# Test if we are trying to use run time linking or normal
 	# AIX style linking. If -brtl is somewhere in LDFLAGS, we
 	# need to do runtime linking.
-	case $host_os in aix4.[23]|aix4.[23].*|aix5*)
+	case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
 	  for ld_flag in $LDFLAGS; do
   	  if (test $ld_flag = "-brtl" || test $ld_flag = "-Wl,-brtl"); then
   	    aix_use_runtimelinking=yes
   	    break
   	  fi
 	  done
+	  ;;
 	esac
 
 	exp_sym_flag='-bexport'
@@ -110888,7 +111224,7 @@ EOF
   	   strings "$collect2name" | grep resolve_lib_name >/dev/null
 	  then
   	  # We have reworked collect2
-  	  hardcode_direct=yes
+  	  :
 	  else
   	  # We have old collect2
   	  hardcode_direct=unsupported
@@ -110899,6 +111235,7 @@ EOF
   	  hardcode_libdir_flag_spec='-L$libdir'
   	  hardcode_libdir_separator=
 	  fi
+	  ;;
 	esac
 	shared_flag='-shared'
 	if test "$aix_use_runtimelinking" = yes; then
@@ -110911,11 +111248,11 @@ EOF
   	# chokes on -Wl,-G. The following line is correct:
 	  shared_flag='-G'
 	else
-  	if test "$aix_use_runtimelinking" = yes; then
+	  if test "$aix_use_runtimelinking" = yes; then
 	    shared_flag='${wl}-G'
 	  else
 	    shared_flag='${wl}-bM:SRE'
-  	fi
+	  fi
 	fi
       fi
 
@@ -110929,18 +111266,25 @@ EOF
        # Determine the default libpath from the value encoded in an empty executable.
        
 cat > conftest.$ac_ext <<EOF
-#line 110933 "configure"
+#line 111270 "configure"
 #include "confdefs.h"
 int main() {
 ; return 0; }
 EOF
-if { (eval echo configure:110938: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
-}'`
+if { (eval echo configure:111275: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ 
+lt_aix_libpath_sed='
+    /Import File Strings/,/^$/ {
+	/^0/ {
+	    s/^0  *\(.*\)$/\1/
+	    p
+	}
+    }'
+aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
 # Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
-}'`; fi
+if test -z "$aix_libpath"; then
+  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+fi
   rm -rf conftest*
 else
   echo "configure: failed program was:" >&5
@@ -110950,28 +111294,35 @@ rm -f conftest*
 if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 
        hardcode_libdir_flag_spec='${wl}-blibpath:$libdir:'"$aix_libpath"
-	archive_expsym_cmds="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
+	archive_expsym_cmds="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
        else
 	if test "$host_cpu" = ia64; then
 	  hardcode_libdir_flag_spec='${wl}-R $libdir:/usr/lib:/lib'
 	  allow_undefined_flag="-z nodefs"
-	  archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
+	  archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
 	else
 	 # Determine the default libpath from the value encoded in an empty executable.
 	 
 cat > conftest.$ac_ext <<EOF
-#line 110964 "configure"
+#line 111308 "configure"
 #include "confdefs.h"
 int main() {
 ; return 0; }
 EOF
-if { (eval echo configure:110969: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
-}'`
+if { (eval echo configure:111313: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ 
+lt_aix_libpath_sed='
+    /Import File Strings/,/^$/ {
+	/^0/ {
+	    s/^0  *\(.*\)$/\1/
+	    p
+	}
+    }'
+aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
 # Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
-}'`; fi
+if test -z "$aix_libpath"; then
+  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+fi
   rm -rf conftest*
 else
   echo "configure: failed program was:" >&5
@@ -110985,13 +111336,11 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 	  # -berok will link without error, but may produce a broken library.
 	  no_undefined_flag=' ${wl}-bernotok'
 	  allow_undefined_flag=' ${wl}-berok'
-	  # -bexpall does not export symbols beginning with underscore (_)
-	  always_export_symbols=yes
 	  # Exported symbols can be pulled into shared objects from archives
-	  whole_archive_flag_spec=' '
+	  whole_archive_flag_spec='$convenience'
 	  archive_cmds_need_lc=yes
 	  # This is similar to how AIX traditionally builds its shared libraries.
-	  archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
+	  archive_expsym_cmds="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
 	fi
       fi
       ;;
@@ -111024,7 +111373,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       # The linker will automatically build a .lib file if we build a DLL.
       old_archive_From_new_cmds='true'
       # FIXME: Should let the user specify the lib program.
-      old_archive_cmds='lib /OUT:$oldlib$oldobjs$old_deplibs'
+      old_archive_cmds='lib -OUT:$oldlib$oldobjs$old_deplibs'
       fix_srcfile_path='`cygpath -w "$srcfile"`'
       enable_shared_with_static_runtimes=yes
       ;;
@@ -111057,19 +111406,18 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       link_all_deplibs=yes
     if test "$GCC" = yes ; then
     	output_verbose_link_cmd='echo'
-        archive_cmds='$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
-      module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
-      # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
-      archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
-      module_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
+        archive_cmds="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
+        module_cmds="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
+        archive_expsym_cmds="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
+        module_expsym_cmds="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
     else
       case $cc_basename in
         xlc*)
          output_verbose_link_cmd='echo'
-         archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
+         archive_cmds='$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
          module_cmds='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
           # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
-         archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
+         archive_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
           module_expsym_cmds='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
           ;;
        *)
@@ -111109,7 +111457,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       ;;
 
     # FreeBSD 3 and greater uses gcc -shared to do shared libraries.
-    freebsd* | kfreebsd*-gnu | dragonfly*)
+    freebsd* | dragonfly*)
       archive_cmds='$CC -shared -o $lib $libobjs $deplibs $compiler_flags'
       hardcode_libdir_flag_spec='-R$libdir'
       hardcode_direct=yes
@@ -111132,47 +111480,62 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       export_dynamic_flag_spec='${wl}-E'
       ;;
 
-    hpux10* | hpux11*)
+    hpux10*)
+      if test "$GCC" = yes -a "$with_gnu_ld" = no; then
+	archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
+      else
+	archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
+      fi
+      if test "$with_gnu_ld" = no; then
+	hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
+	hardcode_libdir_separator=:
+
+	hardcode_direct=yes
+	export_dynamic_flag_spec='${wl}-E'
+
+	# hardcode_minus_L: Not really in the search PATH,
+	# but as the default location of the library.
+	hardcode_minus_L=yes
+      fi
+      ;;
+
+    hpux11*)
       if test "$GCC" = yes -a "$with_gnu_ld" = no; then
 	case $host_cpu in
-	hppa*64*|ia64*)
+	hppa*64*)
 	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
+	ia64*)
+	  archive_cmds='$CC -shared ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
+	  ;;
 	*)
 	  archive_cmds='$CC -shared -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	esac
       else
 	case $host_cpu in
-	hppa*64*|ia64*)
-	  archive_cmds='$LD -b +h $soname -o $lib $libobjs $deplibs $linker_flags'
+	hppa*64*)
+	  archive_cmds='$CC -b ${wl}+h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	  ;;
+	ia64*)
+	  archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	*)
-	  archive_cmds='$LD -b +h $soname +b $install_libdir -o $lib $libobjs $deplibs $linker_flags'
+	  archive_cmds='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $libobjs $deplibs $compiler_flags'
 	  ;;
 	esac
       fi
       if test "$with_gnu_ld" = no; then
+	hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
+	hardcode_libdir_separator=:
+
 	case $host_cpu in
-	hppa*64*)
-	  hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
+	hppa*64*|ia64*)
 	  hardcode_libdir_flag_spec_ld='+b $libdir'
-	  hardcode_libdir_separator=:
 	  hardcode_direct=no
 	  hardcode_shlibpath_var=no
 	  ;;
-	ia64*)
-	  hardcode_libdir_flag_spec='-L$libdir'
-	  hardcode_direct=no
-	  hardcode_shlibpath_var=no
-
-	  # hardcode_minus_L: Not really in the search PATH,
-	  # but as the default location of the library.
-	  hardcode_minus_L=yes
-	  ;;
 	*)
-	  hardcode_libdir_flag_spec='${wl}+b ${wl}$libdir'
-	  hardcode_libdir_separator=:
 	  hardcode_direct=yes
 	  export_dynamic_flag_spec='${wl}-E'
 
@@ -111216,24 +111579,28 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       ;;
 
     openbsd*)
-      hardcode_direct=yes
-      hardcode_shlibpath_var=no
-      if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
-	archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
-	archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
-	hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
-	export_dynamic_flag_spec='${wl}-E'
+      if test -f /usr/libexec/ld.so; then
+	hardcode_direct=yes
+	hardcode_shlibpath_var=no
+	if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
+	  archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
+	  archive_expsym_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-retain-symbols-file,$export_symbols'
+	  hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
+	  export_dynamic_flag_spec='${wl}-E'
+	else
+	  case $host_os in
+	   openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
+	     archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
+	     hardcode_libdir_flag_spec='-R$libdir'
+	     ;;
+	   *)
+	     archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
+	     hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
+	     ;;
+	  esac
+        fi
       else
-       case $host_os in
-	 openbsd[01].* | openbsd2.[0-7] | openbsd2.[0-7].*)
-	   archive_cmds='$LD -Bshareable -o $lib $libobjs $deplibs $linker_flags'
-	   hardcode_libdir_flag_spec='-R$libdir'
-	   ;;
-	 *)
-	   archive_cmds='$CC -shared $pic_flag -o $lib $libobjs $deplibs $compiler_flags'
-	   hardcode_libdir_flag_spec='${wl}-rpath,$libdir'
-	   ;;
-       esac
+	ld_shlibs=no
       fi
       ;;
 
@@ -111274,14 +111641,6 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       hardcode_libdir_separator=:
       ;;
 
-    sco3.2v5*)
-      archive_cmds='$LD -G -h $soname -o $lib $libobjs $deplibs $linker_flags'
-      hardcode_shlibpath_var=no
-      export_dynamic_flag_spec='${wl}-Bexport'
-      runpath_var=LD_RUN_PATH
-      hardcode_runpath_var=yes
-      ;;
-
     solaris*)
       no_undefined_flag=' -z text'
       if test "$GCC" = yes; then
@@ -111300,17 +111659,16 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       case $host_os in
       solaris2.[0-5] | solaris2.[0-5].*) ;;
       *)
- 	# The compiler driver will combine linker options so we
- 	# cannot just pass the convience library names through
- 	# without $wl, iff we do not link with $LD.
- 	# Luckily, gcc supports the same syntax we need for Sun Studio.
+	# The compiler driver will combine and reorder linker options,
+	# but understands `-z linker_flag'.  GCC discards it without `$wl',
+	# but is careful enough not to reorder.
  	# Supported since Solaris 2.6 (maybe 2.5.1?)
- 	case $wlarc in
- 	'')
- 	  whole_archive_flag_spec='-z allextract$convenience -z defaultextract' ;;
- 	*)
- 	  whole_archive_flag_spec='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract' ;;
- 	esac ;;
+	if test "$GCC" = yes; then
+	  whole_archive_flag_spec='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
+	else
+	  whole_archive_flag_spec='-z allextract$convenience -z defaultextract'
+	fi
+	;;
       esac
       link_all_deplibs=yes
       ;;
@@ -111367,36 +111725,45 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
       fi
       ;;
 
-    sysv4.2uw2*)
-      archive_cmds='$LD -G -o $lib $libobjs $deplibs $linker_flags'
-      hardcode_direct=yes
-      hardcode_minus_L=no
+    sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
+      no_undefined_flag='${wl}-z,text'
+      archive_cmds_need_lc=no
       hardcode_shlibpath_var=no
-      hardcode_runpath_var=yes
-      runpath_var=LD_RUN_PATH
-      ;;
+      runpath_var='LD_RUN_PATH'
 
-   sysv5OpenUNIX8* | sysv5UnixWare7* |  sysv5uw[78]* | unixware7*)
-      no_undefined_flag='${wl}-z ${wl}text'
       if test "$GCC" = yes; then
-	archive_cmds='$CC -shared ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	archive_cmds='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
       else
-	archive_cmds='$CC -G ${wl}-h ${wl}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	archive_cmds='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
       fi
-      runpath_var='LD_RUN_PATH'
-      hardcode_shlibpath_var=no
       ;;
 
-    sysv5*)
-      no_undefined_flag=' -z text'
-      # $CC -shared without GNU ld will not create a library from C++
-      # object files and a static libstdc++, better avoid it by now
-      archive_cmds='$LD -G${allow_undefined_flag} -h $soname -o $lib $libobjs $deplibs $linker_flags'
-      archive_expsym_cmds='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
-  		$LD -G${allow_undefined_flag} -M $lib.exp -h $soname -o $lib $libobjs $deplibs $linker_flags~$rm $lib.exp'
-      hardcode_libdir_flag_spec=
+    sysv5* | sco3.2v5* | sco5v6*)
+      # Note: We can NOT use -z defs as we might desire, because we do not
+      # link with -lc, and that would cause any symbols used from libc to
+      # always be unresolved, which means just about no library would
+      # ever link correctly.  If we're not using GNU ld we use -z text
+      # though, which does catch some bad symbols but isn't as heavy-handed
+      # as -z defs.
+      no_undefined_flag='${wl}-z,text'
+      allow_undefined_flag='${wl}-z,nodefs'
+      archive_cmds_need_lc=no
       hardcode_shlibpath_var=no
+      hardcode_libdir_flag_spec='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
+      hardcode_libdir_separator=':'
+      link_all_deplibs=yes
+      export_dynamic_flag_spec='${wl}-Bexport'
       runpath_var='LD_RUN_PATH'
+
+      if test "$GCC" = yes; then
+	archive_cmds='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	archive_expsym_cmds='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+      else
+	archive_cmds='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	archive_expsym_cmds='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+      fi
       ;;
 
     uts4*)
@@ -111414,11 +111781,6 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 echo "$ac_t""$ld_shlibs" 1>&6
 test "$ld_shlibs" = no && can_build_shared=no
 
-variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
-if test "$GCC" = yes; then
-  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
-fi
-
 #
 # Do we need to explicitly link libc?
 #
@@ -111437,16 +111799,17 @@ x|xyes)
       # systems, -lgcc has to come before -lc. If gcc already passes -lc
       # to ld, don't add -lc before -lgcc.
       echo $ac_n "checking whether -lc should be explicitly linked in""... $ac_c" 1>&6
-echo "configure:111441: checking whether -lc should be explicitly linked in" >&5
+echo "configure:111803: checking whether -lc should be explicitly linked in" >&5
       $rm conftest*
-      printf "$lt_simple_compile_test_code" > conftest.$ac_ext
+      echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
-      if { (eval echo configure:111445: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; } 2>conftest.err; then
+      if { (eval echo configure:111807: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; } 2>conftest.err; then
         soname=conftest
         lib=conftest
         libobjs=conftest.$ac_objext
         deplibs=
         wl=$lt_prog_compiler_wl
+	pic_flag=$lt_prog_compiler_pic
         compiler_flags=-v
         linker_flags=-v
         verstring=
@@ -111454,7 +111817,7 @@ echo "configure:111441: checking whether -lc should be explicitly linked in" >&5
         libname=conftest
         lt_save_allow_undefined_flag=$allow_undefined_flag
         allow_undefined_flag=
-        if { (eval echo configure:111458: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\") 1>&5; (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5; }
+        if { (eval echo configure:111821: \"$archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\") 1>&5; (eval $archive_cmds 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5; }
         then
 	  archive_cmds_need_lc=no
         else
@@ -111473,7 +111836,7 @@ echo "configure:111441: checking whether -lc should be explicitly linked in" >&5
 esac
 
 echo $ac_n "checking dynamic linker characteristics""... $ac_c" 1>&6
-echo "configure:111477: checking dynamic linker characteristics" >&5
+echo "configure:111840: checking dynamic linker characteristics" >&5
 library_names_spec=
 libname_spec='lib$name'
 soname_spec=
@@ -111487,17 +111850,55 @@ shlibpath_overrides_runpath=unknown
 version_type=none
 dynamic_linker="$host_os ld.so"
 sys_lib_dlsearch_path_spec="/lib /usr/lib"
+
 if test "$GCC" = yes; then
-  sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
-  if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
+  case $host_os in
+    darwin*) lt_awk_arg="/^libraries:/,/LR/" ;;
+    *) lt_awk_arg="/^libraries:/" ;;
+  esac
+  lt_search_path_spec=`$CC -print-search-dirs | awk $lt_awk_arg | $SED -e "s/^libraries://" -e "s,=/,/,g"`
+  if echo "$lt_search_path_spec" | grep ';' >/dev/null ; then
     # if the path contains ";" then we assume it to be the separator
     # otherwise default to the standard path separator (i.e. ":") - it is
     # assumed that no part of a normal pathname contains ";" but that should
     # okay in the real world where ";" in dirpaths is itself problematic.
-    sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
+    lt_search_path_spec=`echo "$lt_search_path_spec" | $SED -e 's/;/ /g'`
   else
-    sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
+    lt_search_path_spec=`echo "$lt_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
   fi
+  # Ok, now we have the path, separated by spaces, we can step through it
+  # and add multilib dir if necessary.
+  lt_tmp_lt_search_path_spec=
+  lt_multi_os_dir=`$CC $CPPFLAGS $CFLAGS $LDFLAGS -print-multi-os-directory 2>/dev/null`
+  for lt_sys_path in $lt_search_path_spec; do
+    if test -d "$lt_sys_path/$lt_multi_os_dir"; then
+      lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path/$lt_multi_os_dir"
+    else
+      test -d "$lt_sys_path" && \
+	lt_tmp_lt_search_path_spec="$lt_tmp_lt_search_path_spec $lt_sys_path"
+    fi
+  done
+  lt_search_path_spec=`echo $lt_tmp_lt_search_path_spec | awk '
+BEGIN {RS=" "; FS="/|\n";} {
+  lt_foo="";
+  lt_count=0;
+  for (lt_i = NF; lt_i > 0; lt_i--) {
+    if ($lt_i != "" && $lt_i != ".") {
+      if ($lt_i == "..") {
+        lt_count++;
+      } else {
+        if (lt_count == 0) {
+          lt_foo="/" $lt_i lt_foo;
+        } else {
+          lt_count--;
+        }
+      }
+    }
+  }
+  if (lt_foo != "") { lt_freq[lt_foo]++; }
+  if (lt_freq[lt_foo] == 1) { print lt_foo; }
+}'`
+  sys_lib_search_path_spec=`echo $lt_search_path_spec`
 else
   sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
 fi
@@ -111518,7 +111919,7 @@ aix3*)
   soname_spec='${libname}${release}${shared_ext}$major'
   ;;
 
-aix4* | aix5*)
+aix[4-9]*)
   version_type=linux
   need_lib_prefix=no
   need_version=no
@@ -111657,12 +112058,8 @@ darwin* | rhapsody*)
   shlibpath_overrides_runpath=yes
   shlibpath_var=DYLD_LIBRARY_PATH
   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
-  # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
-  if test "$GCC" = yes; then
-    sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"`
-  else
-    sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
-  fi
+  
+  sys_lib_search_path_spec="$sys_lib_search_path_spec /usr/local/lib" 
   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
   ;;
 
@@ -111679,18 +112076,6 @@ freebsd1*)
   dynamic_linker=no
   ;;
 
-kfreebsd*-gnu)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=no
-  hardcode_into_libs=yes
-  dynamic_linker='GNU ld.so'
-  ;;
-
 freebsd* | dragonfly*)
   # DragonFly does not have aout.  When/if they implement a new
   # versioning mechanism, adjust this.
@@ -111723,10 +112108,15 @@ freebsd* | dragonfly*)
     shlibpath_overrides_runpath=yes
     hardcode_into_libs=yes
     ;;
-  *) # from 3.2 on
+  freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
+  freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
     shlibpath_overrides_runpath=no
     hardcode_into_libs=yes
     ;;
+  *) # from 4.6 on, and DragonFly
+    shlibpath_overrides_runpath=yes
+    hardcode_into_libs=yes
+    ;;
   esac
   ;;
 
@@ -111786,6 +112176,18 @@ hpux9* | hpux10* | hpux11*)
   postinstall_cmds='chmod 555 $lib'
   ;;
 
+interix[3-9]*)
+  version_type=linux
+  need_lib_prefix=no
+  need_version=no
+  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
+  soname_spec='${libname}${release}${shared_ext}$major'
+  dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
+  shlibpath_var=LD_LIBRARY_PATH
+  shlibpath_overrides_runpath=no
+  hardcode_into_libs=yes
+  ;;
+
 irix5* | irix6* | nonstopux*)
   case $host_os in
     nonstopux*) version_type=nonstopux ;;
@@ -111829,7 +112231,7 @@ linux*oldld* | linux*aout* | linux*coff*)
   ;;
 
 # This must be Linux ELF.
-linux*)
+linux* | k*bsd*-gnu)
   version_type=linux
   need_lib_prefix=no
   need_version=no
@@ -111843,27 +112245,10 @@ linux*)
   # before this can be enabled.
   hardcode_into_libs=yes
 
-  # find out which ABI we are using
-  libsuff=
-  case $host_cpu in
-  x86_64*|s390x*|powerpc64*)
-    echo '#line 111851 "configure"' > conftest.$ac_ext
-    if { (eval echo configure:111852: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-      case `/usr/bin/file conftest.$ac_objext` in
-      *64-bit*)
-        libsuff=64
-        sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
-        ;;
-      esac
-    fi
-    rm -rf conftest*
-    ;;
-  esac
-
   # Append ld.so.conf contents to the search path
   if test -f /etc/ld.so.conf; then
-    lt_ld_extra=`$SED -e 's/:,\t/ /g;s/=^=*$//;s/=^= * / /g' /etc/ld.so.conf | tr '\n' ' '`
-    sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
+    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ 	]*hwcap[ 	]/d;s/[:,	]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
+    sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
   fi
 
   # We used to test for /lib/ld.so.1 and disable shared libraries on
@@ -111875,18 +112260,6 @@ linux*)
   dynamic_linker='GNU/Linux ld.so'
   ;;
 
-knetbsd*-gnu)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=no
-  hardcode_into_libs=yes
-  dynamic_linker='GNU ld.so'
-  ;;
-
 netbsd*)
   version_type=sunos
   need_lib_prefix=no
@@ -111924,6 +112297,7 @@ nto-qnx*)
 
 openbsd*)
   version_type=sunos
+  sys_lib_dlsearch_path_spec="/usr/lib"
   need_lib_prefix=no
   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
   case $host_os in
@@ -111967,11 +112341,8 @@ osf3* | osf4* | osf5*)
   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
   ;;
 
-sco3.2v5*)
-  version_type=osf
-  soname_spec='${libname}${release}${shared_ext}$major'
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-  shlibpath_var=LD_LIBRARY_PATH
+rdos*)
+  dynamic_linker=no
   ;;
 
 solaris*)
@@ -111999,7 +112370,7 @@ sunos4*)
   need_version=yes
   ;;
 
-sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
+sysv4 | sysv4.3*)
   version_type=linux
   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
   soname_spec='${libname}${release}${shared_ext}$major'
@@ -112032,6 +112403,29 @@ sysv4*MP*)
   fi
   ;;
 
+sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
+  version_type=freebsd-elf
+  need_lib_prefix=no
+  need_version=no
+  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
+  soname_spec='${libname}${release}${shared_ext}$major'
+  shlibpath_var=LD_LIBRARY_PATH
+  hardcode_into_libs=yes
+  if test "$with_gnu_ld" = yes; then
+    sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
+    shlibpath_overrides_runpath=no
+  else
+    sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
+    shlibpath_overrides_runpath=yes
+    case $host_os in
+      sco3.2v5*)
+        sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
+	;;
+    esac
+  fi
+  sys_lib_dlsearch_path_spec='/usr/lib'
+  ;;
+
 uts4*)
   version_type=linux
   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
@@ -112046,8 +112440,28 @@ esac
 echo "$ac_t""$dynamic_linker" 1>&6
 test "$dynamic_linker" = no && can_build_shared=no
 
+if eval "test \"`echo '$''{'lt_cv_sys_lib_search_path_spec'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec"
+fi
+
+sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
+if eval "test \"`echo '$''{'lt_cv_sys_lib_dlsearch_path_spec'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec"
+fi
+
+sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
+
+variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
+if test "$GCC" = yes; then
+  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
+fi
+
 echo $ac_n "checking how to hardcode library paths into programs""... $ac_c" 1>&6
-echo "configure:112051: checking how to hardcode library paths into programs" >&5
+echo "configure:112465: checking how to hardcode library paths into programs" >&5
 hardcode_action=
 if test -n "$hardcode_libdir_flag_spec" || \
    test -n "$runpath_var" || \
@@ -112085,7 +112499,7 @@ fi
 striplib=
 old_striplib=
 echo $ac_n "checking whether stripping libraries is possible""... $ac_c" 1>&6
-echo "configure:112089: checking whether stripping libraries is possible" >&5
+echo "configure:112503: checking whether stripping libraries is possible" >&5
 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"
@@ -112096,6 +112510,7 @@ else
    darwin*)
        if test -n "$STRIP" ; then
          striplib="$STRIP -x"
+         old_striplib="$STRIP -S"
          echo "$ac_t""yes" 1>&6
        else
   echo "$ac_t""no" 1>&6
@@ -112135,7 +112550,7 @@ else
   darwin*)
   # if libdl is installed we need to link against it
     echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
-echo "configure:112139: checking for dlopen in -ldl" >&5
+echo "configure:112554: checking for dlopen in -ldl" >&5
 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -112143,7 +112558,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 112147 "configure"
+#line 112562 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -112154,7 +112569,7 @@ int main() {
 dlopen()
 ; return 0; }
 EOF
-if { (eval echo configure:112158: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:112573: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -112183,12 +112598,12 @@ fi
 
   *)
     echo $ac_n "checking for shl_load""... $ac_c" 1>&6
-echo "configure:112187: checking for shl_load" >&5
+echo "configure:112602: checking for shl_load" >&5
 if eval "test \"`echo '$''{'ac_cv_func_shl_load'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 112192 "configure"
+#line 112607 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char shl_load(); below.  */
@@ -112211,7 +112626,7 @@ shl_load();
 
 ; return 0; }
 EOF
-if { (eval echo configure:112215: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:112630: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_shl_load=yes"
 else
@@ -112229,7 +112644,7 @@ if eval "test \"`echo '$ac_cv_func_'shl_load`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
 echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6
-echo "configure:112233: checking for shl_load in -ldld" >&5
+echo "configure:112648: checking for shl_load in -ldld" >&5
 ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -112237,7 +112652,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldld  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 112241 "configure"
+#line 112656 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -112248,7 +112663,7 @@ int main() {
 shl_load()
 ; return 0; }
 EOF
-if { (eval echo configure:112252: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:112667: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -112263,16 +112678,16 @@ LIBS="$ac_save_LIBS"
 fi
 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
   echo "$ac_t""yes" 1>&6
-  lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"
+  lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-ldld"
 else
   echo "$ac_t""no" 1>&6
 echo $ac_n "checking for dlopen""... $ac_c" 1>&6
-echo "configure:112271: checking for dlopen" >&5
+echo "configure:112686: checking for dlopen" >&5
 if eval "test \"`echo '$''{'ac_cv_func_dlopen'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 112276 "configure"
+#line 112691 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char dlopen(); below.  */
@@ -112295,7 +112710,7 @@ dlopen();
 
 ; return 0; }
 EOF
-if { (eval echo configure:112299: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:112714: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_dlopen=yes"
 else
@@ -112313,7 +112728,7 @@ if eval "test \"`echo '$ac_cv_func_'dlopen`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
 echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
-echo "configure:112317: checking for dlopen in -ldl" >&5
+echo "configure:112732: checking for dlopen in -ldl" >&5
 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -112321,7 +112736,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 112325 "configure"
+#line 112740 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -112332,7 +112747,7 @@ int main() {
 dlopen()
 ; return 0; }
 EOF
-if { (eval echo configure:112336: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:112751: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -112351,7 +112766,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
 echo $ac_n "checking for dlopen in -lsvld""... $ac_c" 1>&6
-echo "configure:112355: checking for dlopen in -lsvld" >&5
+echo "configure:112770: checking for dlopen in -lsvld" >&5
 ac_lib_var=`echo svld'_'dlopen | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -112359,7 +112774,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsvld  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 112363 "configure"
+#line 112778 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -112370,7 +112785,7 @@ int main() {
 dlopen()
 ; return 0; }
 EOF
-if { (eval echo configure:112374: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:112789: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -112389,7 +112804,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
 else
   echo "$ac_t""no" 1>&6
 echo $ac_n "checking for dld_link in -ldld""... $ac_c" 1>&6
-echo "configure:112393: checking for dld_link in -ldld" >&5
+echo "configure:112808: checking for dld_link in -ldld" >&5
 ac_lib_var=`echo dld'_'dld_link | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -112397,7 +112812,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldld  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 112401 "configure"
+#line 112816 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -112408,7 +112823,7 @@ int main() {
 dld_link()
 ; return 0; }
 EOF
-if { (eval echo configure:112412: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:112827: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -112423,7 +112838,7 @@ LIBS="$ac_save_LIBS"
 fi
 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
   echo "$ac_t""yes" 1>&6
-  lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"
+  lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-ldld"
 else
   echo "$ac_t""no" 1>&6
 fi
@@ -112458,13 +112873,13 @@ fi
     test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
 
     save_LDFLAGS="$LDFLAGS"
-    eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
+    wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
 
     save_LIBS="$LIBS"
     LIBS="$lt_cv_dlopen_libs $LIBS"
 
     echo $ac_n "checking whether a program can dlopen itself""... $ac_c" 1>&6
-echo "configure:112468: checking whether a program can dlopen itself" >&5
+echo "configure:112883: checking whether a program can dlopen itself" >&5
 if eval "test \"`echo '$''{'lt_cv_dlopen_self'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -112474,7 +112889,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<EOF
-#line 112478 "configure"
+#line 112893 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -112531,17 +112946,19 @@ int main ()
       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
       /* dlclose (self); */
     }
+  else
+    puts (dlerror ());
 
     exit (status);
 }
 EOF
-  if { (eval echo configure:112539: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} 2>/dev/null; then
+  if { (eval echo configure:112956: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} 2>/dev/null; then
     (./conftest; exit; ) >&5 2>/dev/null
     lt_status=$?
     case x$lt_status in
       x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
       x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
-      x$lt_unknown|x*) lt_cv_dlopen_self=no ;;
+      x$lt_dlunknown|x*) lt_cv_dlopen_self=no ;;
     esac
   else :
     # compilation failed
@@ -112556,9 +112973,9 @@ fi
 echo "$ac_t""$lt_cv_dlopen_self" 1>&6
 
     if test "x$lt_cv_dlopen_self" = xyes; then
-      LDFLAGS="$LDFLAGS $link_static_flag"
+      wl=$lt_prog_compiler_wl eval LDFLAGS=\"\$LDFLAGS $lt_prog_compiler_static\"
       echo $ac_n "checking whether a statically linked program can dlopen itself""... $ac_c" 1>&6
-echo "configure:112562: checking whether a statically linked program can dlopen itself" >&5
+echo "configure:112979: checking whether a statically linked program can dlopen itself" >&5
 if eval "test \"`echo '$''{'lt_cv_dlopen_self_static'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -112568,7 +112985,7 @@ else
   lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
   lt_status=$lt_dlunknown
   cat > conftest.$ac_ext <<EOF
-#line 112572 "configure"
+#line 112989 "configure"
 #include "confdefs.h"
 
 #if HAVE_DLFCN_H
@@ -112625,17 +113042,19 @@ int main ()
       else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
       /* dlclose (self); */
     }
+  else
+    puts (dlerror ());
 
     exit (status);
 }
 EOF
-  if { (eval echo configure:112633: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} 2>/dev/null; then
+  if { (eval echo configure:113052: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} 2>/dev/null; then
     (./conftest; exit; ) >&5 2>/dev/null
     lt_status=$?
     case x$lt_status in
       x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
       x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
-      x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;;
+      x$lt_dlunknown|x*) lt_cv_dlopen_self_static=no ;;
     esac
   else :
     # compilation failed
@@ -112668,13 +113087,13 @@ echo "$ac_t""$lt_cv_dlopen_self_static" 1>&6
 fi
 
 
-# Report which librarie types wil actually be built
+# Report which library types will actually be built
 echo $ac_n "checking if libtool supports shared libraries""... $ac_c" 1>&6
-echo "configure:112674: checking if libtool supports shared libraries" >&5
+echo "configure:113093: checking if libtool supports shared libraries" >&5
 echo "$ac_t""$can_build_shared" 1>&6
 
 echo $ac_n "checking whether to build shared libraries""... $ac_c" 1>&6
-echo "configure:112678: checking whether to build shared libraries" >&5
+echo "configure:113097: checking whether to build shared libraries" >&5
 test "$can_build_shared" = "no" && enable_shared=no
 
 # On AIX, shared libraries and static libraries use the same namespace, and
@@ -112688,7 +113107,7 @@ aix3*)
   fi
   ;;
 
-aix4* | aix5*)
+aix[4-9]*)
   if test "$host_cpu" != ia64 && test "$aix_use_runtimelinking" = no ; then
     test "$enable_shared" = yes && enable_static=no
   fi
@@ -112697,7 +113116,7 @@ esac
 echo "$ac_t""$enable_shared" 1>&6
 
 echo $ac_n "checking whether to build static libraries""... $ac_c" 1>&6
-echo "configure:112701: checking whether to build static libraries" >&5
+echo "configure:113120: checking whether to build static libraries" >&5
 # Make sure either enable_shared or enable_static is yes.
 test "$enable_shared" = yes || enable_static=yes
 echo "$ac_t""$enable_static" 1>&6
@@ -112715,7 +113134,7 @@ if test -f "$ltmain"; then
   # Now quote all the things that may contain metacharacters while being
   # careful not to overquote the AC_SUBSTed values.  We take copies of the
   # variables and quote the copies for generation of the libtool script.
-  for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
+  for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
     SED SHELL STRIP \
     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
@@ -112742,6 +113161,7 @@ if test -f "$ltmain"; then
     predeps \
     postdeps \
     compiler_lib_search_path \
+    compiler_lib_search_dirs \
     archive_cmds \
     archive_expsym_cmds \
     postinstall_cmds \
@@ -112757,6 +113177,7 @@ if test -f "$ltmain"; then
     module_cmds \
     module_expsym_cmds \
     lt_cv_prog_compiler_c_o \
+    fix_srcfile_path \
     exclude_expsyms \
     include_expsyms; do
 
@@ -112801,7 +113222,7 @@ creating $ofile" 1>&6
 # Generated automatically by $PROGRAM (GNU $PACKAGE $VERSION$TIMESTAMP)
 # NOTE: Changes made to this file will be lost: look at ltmain.sh.
 #
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001
+# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
 # Free Software Foundation, Inc.
 #
 # This file is part of GNU Libtool:
@@ -112881,6 +113302,9 @@ AR_FLAGS=$lt_AR_FLAGS
 # A C compiler.
 LTCC=$lt_LTCC
 
+# LTCC compiler flags.
+LTCFLAGS=$lt_LTCFLAGS
+
 # A language-specific compiler.
 CC=$lt_compiler
 
@@ -113034,6 +113458,10 @@ predeps=$lt_predeps
 # shared library.
 postdeps=$lt_postdeps
 
+# The directories searched by this compiler when creating a shared
+# library
+compiler_lib_search_dirs=$lt_compiler_lib_search_dirs
+
 # The library search path used internally by the compiler when linking
 # a shared library.
 compiler_lib_search_path=$lt_compiler_lib_search_path
@@ -113122,7 +113550,7 @@ sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
 
 # Fix the shell variable \$srcfile for the compiler.
-fix_srcfile_path="$fix_srcfile_path"
+fix_srcfile_path=$lt_fix_srcfile_path
 
 # Set to yes if exported symbols are required.
 always_export_symbols=$always_export_symbols
@@ -113209,6 +113637,9 @@ if test -f "$ltmain" && test -n "$tagnames"; then
       echo "configure: warning: using \`LTCC=$LTCC', extracted from \`$ofile'" 1>&2
     fi
   fi
+  if test -z "$LTCFLAGS"; then
+    eval "`$SHELL ${ofile} --config | grep '^LTCFLAGS='`"
+  fi
 
   # Extract list of available tagged configurations in $ofile.
   # Note that this assumes the entire list is on one line.
@@ -113259,6 +113690,7 @@ hardcode_libdir_flag_spec_CXX=
 hardcode_libdir_flag_spec_ld_CXX=
 hardcode_libdir_separator_CXX=
 hardcode_minus_L_CXX=no
+hardcode_shlibpath_var_CXX=unsupported
 hardcode_automatic_CXX=no
 module_cmds_CXX=
 module_expsym_cmds_CXX=
@@ -113274,6 +113706,7 @@ postdep_objects_CXX=
 predeps_CXX=
 postdeps_CXX=
 compiler_lib_search_path_CXX=
+compiler_lib_search_dirs_CXX=
 
 # Source file extension for C++ test sources.
 ac_ext=cpp
@@ -113283,32 +113716,35 @@ objext=o
 objext_CXX=$objext
 
 # Code to be used in simple compile tests
-lt_simple_compile_test_code="int some_variable = 0;\n"
+lt_simple_compile_test_code="int some_variable = 0;"
 
 # Code to be used in simple link tests
-lt_simple_link_test_code='int main(int, char *) { return(0); }\n'
+lt_simple_link_test_code='int main(int, char *[]) { return(0); }'
 
 # ltmain only uses $CC for tagged configurations so make sure $CC is set.
 
 # If no C compiler was specified, use CC.
 LTCC=${LTCC-"$CC"}
 
+# If no C compiler flags were specified, use CFLAGS.
+LTCFLAGS=${LTCFLAGS-"$CFLAGS"}
+
 # Allow CC to be a program name with arguments.
 compiler=$CC
 
 
 # save warnings/boilerplate of simple test code
 ac_outfile=conftest.$ac_objext
-printf "$lt_simple_compile_test_code" >conftest.$ac_ext
-eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
+echo "$lt_simple_compile_test_code" >conftest.$ac_ext
+eval "$ac_compile" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
 _lt_compiler_boilerplate=`cat conftest.err`
 $rm conftest*
 
 ac_outfile=conftest.$ac_objext
-printf "$lt_simple_link_test_code" >conftest.$ac_ext
-eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d' >conftest.err
+echo "$lt_simple_link_test_code" >conftest.$ac_ext
+eval "$ac_link" 2>&1 >/dev/null | $SED '/^$/d; /^ *+/d' >conftest.err
 _lt_linker_boilerplate=`cat conftest.err`
-$rm conftest*
+$rm -r conftest*
 
 
 # Allow CC to be a program name with arguments.
@@ -113366,7 +113802,7 @@ ac_prog=ld
 if test "$GCC" = yes; then
   # Check if gcc -print-prog-name=ld gives a path.
   echo $ac_n "checking for ld used by $CC""... $ac_c" 1>&6
-echo "configure:113370: checking for ld used by $CC" >&5
+echo "configure:113806: checking for ld used by $CC" >&5
   case $host in
   *-*-mingw*)
     # gcc leaves a trailing carriage return which upsets mingw
@@ -113396,10 +113832,10 @@ echo "configure:113370: checking for ld used by $CC" >&5
   esac
 elif test "$with_gnu_ld" = yes; then
   echo $ac_n "checking for GNU ld""... $ac_c" 1>&6
-echo "configure:113400: checking for GNU ld" >&5
+echo "configure:113836: checking for GNU ld" >&5
 else
   echo $ac_n "checking for non-GNU ld""... $ac_c" 1>&6
-echo "configure:113403: checking for non-GNU ld" >&5
+echo "configure:113839: checking for non-GNU ld" >&5
 fi
 if eval "test \"`echo '$''{'lt_cv_path_LD'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -113438,7 +113874,7 @@ else
 fi
 test -z "$LD" && { echo "configure: error: no acceptable ld found in \$PATH" 1>&2; exit 1; }
 echo $ac_n "checking if the linker ($LD) is GNU ld""... $ac_c" 1>&6
-echo "configure:113442: checking if the linker ($LD) is GNU ld" >&5
+echo "configure:113878: checking if the linker ($LD) is GNU ld" >&5
 if eval "test \"`echo '$''{'lt_cv_prog_gnu_ld'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -113504,14 +113940,14 @@ fi
 
 # PORTME: fill in a description of your system's C++ link characteristics
 echo $ac_n "checking whether the $compiler linker ($LD) supports shared libraries""... $ac_c" 1>&6
-echo "configure:113508: checking whether the $compiler linker ($LD) supports shared libraries" >&5
+echo "configure:113944: checking whether the $compiler linker ($LD) supports shared libraries" >&5
 ld_shlibs_CXX=yes
 case $host_os in
   aix3*)
     # FIXME: insert proper C++ library support
     ld_shlibs_CXX=no
     ;;
-  aix4* | aix5*)
+  aix[4-9]*)
     if test "$host_cpu" = ia64; then
       # On IA64, the linker does run time linking by default, so we don't
       # have to do anything special.
@@ -113524,7 +113960,7 @@ case $host_os in
       # Test if we are trying to use run time linking or normal
       # AIX style linking. If -brtl is somewhere in LDFLAGS, we
       # need to do runtime linking.
-      case $host_os in aix4.[23]|aix4.[23].*|aix5*)
+      case $host_os in aix4.[23]|aix4.[23].*|aix[5-9]*)
 	for ld_flag in $LDFLAGS; do
 	  case $ld_flag in
 	  *-brtl*)
@@ -113533,6 +113969,7 @@ case $host_os in
 	    ;;
 	  esac
 	done
+	;;
       esac
 
       exp_sym_flag='-bexport'
@@ -113559,7 +113996,7 @@ case $host_os in
 	   strings "$collect2name" | grep resolve_lib_name >/dev/null
 	then
 	  # We have reworked collect2
-	  hardcode_direct_CXX=yes
+	  :
 	else
 	  # We have old collect2
 	  hardcode_direct_CXX=unsupported
@@ -113570,6 +114007,7 @@ case $host_os in
 	  hardcode_libdir_flag_spec_CXX='-L$libdir'
 	  hardcode_libdir_separator_CXX=
 	fi
+	;;
       esac
       shared_flag='-shared'
       if test "$aix_use_runtimelinking" = yes; then
@@ -113600,18 +114038,25 @@ case $host_os in
       # Determine the default libpath from the value encoded in an empty executable.
       
 cat > conftest.$ac_ext <<EOF
-#line 113604 "configure"
+#line 114042 "configure"
 #include "confdefs.h"
 int main() {
 ; return 0; }
 EOF
-if { (eval echo configure:113609: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
-}'`
+if { (eval echo configure:114047: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ 
+lt_aix_libpath_sed='
+    /Import File Strings/,/^$/ {
+	/^0/ {
+	    s/^0  *\(.*\)$/\1/
+	    p
+	}
+    }'
+aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
 # Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
-}'`; fi
+if test -z "$aix_libpath"; then
+  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+fi
   rm -rf conftest*
 else
   echo "configure: failed program was:" >&5
@@ -113622,28 +114067,35 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 
       hardcode_libdir_flag_spec_CXX='${wl}-blibpath:$libdir:'"$aix_libpath"
 
-      archive_expsym_cmds_CXX="\$CC"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols $shared_flag"
+      archive_expsym_cmds_CXX="\$CC"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags `if test "x${allow_undefined_flag}" != "x"; then echo "${wl}${allow_undefined_flag}"; else :; fi` '"\${wl}$exp_sym_flag:\$export_symbols $shared_flag"
      else
       if test "$host_cpu" = ia64; then
 	hardcode_libdir_flag_spec_CXX='${wl}-R $libdir:/usr/lib:/lib'
 	allow_undefined_flag_CXX="-z nodefs"
-	archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$no_entry_flag \${wl}$exp_sym_flag:\$export_symbols"
+	archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs '"\${wl}$no_entry_flag"' $compiler_flags ${wl}${allow_undefined_flag} '"\${wl}$exp_sym_flag:\$export_symbols"
       else
 	# Determine the default libpath from the value encoded in an empty executable.
 	
 cat > conftest.$ac_ext <<EOF
-#line 113636 "configure"
+#line 114081 "configure"
 #include "confdefs.h"
 int main() {
 ; return 0; }
 EOF
-if { (eval echo configure:113641: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  
-aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
-}'`
+if { (eval echo configure:114086: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+ 
+lt_aix_libpath_sed='
+    /Import File Strings/,/^$/ {
+	/^0/ {
+	    s/^0  *\(.*\)$/\1/
+	    p
+	}
+    }'
+aix_libpath=`dump -H conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
 # Check for a 64-bit object if we didn't find anything.
-if test -z "$aix_libpath"; then aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e '/Import File Strings/,/^$/ { /^0/ { s/^0  *\(.*\)$/\1/; p; }
-}'`; fi
+if test -z "$aix_libpath"; then
+  aix_libpath=`dump -HX64 conftest$ac_exeext 2>/dev/null | $SED -n -e "$lt_aix_libpath_sed"`
+fi
   rm -rf conftest*
 else
   echo "configure: failed program was:" >&5
@@ -113657,16 +114109,26 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 	# -berok will link without error, but may produce a broken library.
 	no_undefined_flag_CXX=' ${wl}-bernotok'
 	allow_undefined_flag_CXX=' ${wl}-berok'
-	# -bexpall does not export symbols beginning with underscore (_)
-	always_export_symbols_CXX=yes
 	# Exported symbols can be pulled into shared objects from archives
-	whole_archive_flag_spec_CXX=' '
+	whole_archive_flag_spec_CXX='$convenience'
 	archive_cmds_need_lc_CXX=yes
 	# This is similar to how AIX traditionally builds its shared libraries.
-	archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs $compiler_flags ${wl}-bE:$export_symbols ${wl}-bnoentry${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
+	archive_expsym_cmds_CXX="\$CC $shared_flag"' -o $output_objdir/$soname $libobjs $deplibs ${wl}-bnoentry $compiler_flags ${wl}-bE:$export_symbols${allow_undefined_flag}~$AR $AR_FLAGS $output_objdir/$libname$release.a $output_objdir/$soname'
       fi
     fi
     ;;
+
+  beos*)
+    if $LD --help 2>&1 | grep ': supported targets:.* elf' > /dev/null; then
+      allow_undefined_flag_CXX=unsupported
+      # Joseph Beckenbach <jrb3 at best.com> says some releases of gcc
+      # support --undefined.  This deserves some investigation.  FIXME
+      archive_cmds_CXX='$CC -nostart $libobjs $deplibs $compiler_flags ${wl}-soname $wl$soname -o $lib'
+    else
+      ld_shlibs_CXX=no
+    fi
+    ;;
+
   chorus*)
     case $cc_basename in
       *)
@@ -113676,7 +114138,6 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
     esac
     ;;
 
-
   cygwin* | mingw* | pw32*)
     # _LT_AC_TAGVAR(hardcode_libdir_flag_spec, CXX) is actually meaningless,
     # as there is no search path for DLLs.
@@ -113686,7 +114147,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
     enable_shared_with_static_runtimes_CXX=yes
 
     if $LD --help 2>&1 | grep 'auto-import' > /dev/null; then
-      archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
+      archive_cmds_CXX='$CC -shared -nostdlib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
       # If the export-symbols file already is a .def file (1st line
       # is EXPORTS), use it as is; otherwise, prepend...
       archive_expsym_cmds_CXX='if test "x`$SED 1q $export_symbols`" = xEXPORTS; then
@@ -113695,65 +114156,37 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 	echo EXPORTS > $output_objdir/$soname.def;
 	cat $export_symbols >> $output_objdir/$soname.def;
       fi~
-      $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--image-base=0x10000000 ${wl}--out-implib,$lib'
+      $CC -shared -nostdlib $output_objdir/$soname.def $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $output_objdir/$soname ${wl}--enable-auto-image-base -Xlinker --out-implib -Xlinker $lib'
     else
       ld_shlibs_CXX=no
     fi
   ;;
       darwin* | rhapsody*)
-        case $host_os in
-        rhapsody* | darwin1.[012])
-         allow_undefined_flag_CXX='${wl}-undefined ${wl}suppress'
-         ;;
-       *) # Darwin 1.3 on
-         if test -z ${MACOSX_DEPLOYMENT_TARGET} ; then
-           allow_undefined_flag_CXX='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
-         else
-           case ${MACOSX_DEPLOYMENT_TARGET} in
-             10.[012])
-               allow_undefined_flag_CXX='${wl}-flat_namespace ${wl}-undefined ${wl}suppress'
-               ;;
-             10.*)
-               allow_undefined_flag_CXX='${wl}-undefined ${wl}dynamic_lookup'
-               ;;
-           esac
-         fi
-         ;;
-        esac
       archive_cmds_need_lc_CXX=no
       hardcode_direct_CXX=no
       hardcode_automatic_CXX=yes
       hardcode_shlibpath_var_CXX=unsupported
       whole_archive_flag_spec_CXX=''
       link_all_deplibs_CXX=yes
-
-    if test "$GXX" = yes ; then
-      lt_int_apple_cc_single_mod=no
+      allow_undefined_flag_CXX="$_lt_dar_allow_undefined"
+      if test "$GXX" = yes ; then
       output_verbose_link_cmd='echo'
-      if $CC -dumpspecs 2>&1 | $EGREP 'single_module' >/dev/null ; then
-       lt_int_apple_cc_single_mod=yes
+      archive_cmds_CXX="\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring $_lt_dar_single_mod${_lt_dsymutil}"
+      module_cmds_CXX="\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dsymutil}"
+      archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \$libobjs \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring ${_lt_dar_single_mod}${_lt_dar_export_syms}${_lt_dsymutil}"
+      module_expsym_cmds_CXX="sed -e 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC \$allow_undefined_flag -o \$lib -bundle \$libobjs \$deplibs \$compiler_flags${_lt_dar_export_syms}${_lt_dsymutil}"
+      if test "$lt_cv_apple_cc_single_mod" != "yes"; then
+        archive_cmds_CXX="\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dsymutil}"
+        archive_expsym_cmds_CXX="sed 's,^,_,' < \$export_symbols > \$output_objdir/\${libname}-symbols.expsym~\$CC -r -keep_private_externs -nostdlib -o \${lib}-master.o \$libobjs~\$CC -dynamiclib \$allow_undefined_flag -o \$lib \${lib}-master.o \$deplibs \$compiler_flags -install_name \$rpath/\$soname \$verstring${_lt_dar_export_syms}${_lt_dsymutil}"
       fi
-      if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
-       archive_cmds_CXX='$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
-      else
-          archive_cmds_CXX='$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring'
-        fi
-        module_cmds_CXX='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
-        # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
-          if test "X$lt_int_apple_cc_single_mod" = Xyes ; then
-            archive_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -dynamiclib -single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
-          else
-            archive_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -r -keep_private_externs -nostdlib -o ${lib}-master.o $libobjs~$CC -dynamiclib $allow_undefined_flag -o $lib ${lib}-master.o $deplibs $compiler_flags -install_name $rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
-          fi
-            module_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
       else
       case $cc_basename in
         xlc*)
          output_verbose_link_cmd='echo'
-          archive_cmds_CXX='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $verstring'
+          archive_cmds_CXX='$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}`echo $rpath/$soname` $xlcverstring'
           module_cmds_CXX='$CC $allow_undefined_flag -o $lib -bundle $libobjs $deplibs$compiler_flags'
           # Don't fix this by using the ld -exported_symbols_list flag, it doesn't exist in older darwin lds
-          archive_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $verstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
+          archive_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC -qmkshrobj ${wl}-single_module $allow_undefined_flag -o $lib $libobjs $deplibs $compiler_flags ${wl}-install_name ${wl}$rpath/$soname $xlcverstring~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
           module_expsym_cmds_CXX='sed -e "s,#.*,," -e "s,^[    ]*,," -e "s,^\(..*\),_&," < $export_symbols > $output_objdir/${libname}-symbols.expsym~$CC $allow_undefined_flag  -o $lib -bundle $libobjs $deplibs$compiler_flags~nmedit -s $output_objdir/${libname}-symbols.expsym ${lib}'
           ;;
        *)
@@ -113787,7 +114220,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
   freebsd-elf*)
     archive_cmds_need_lc_CXX=no
     ;;
-  freebsd* | kfreebsd*-gnu | dragonfly*)
+  freebsd* | dragonfly*)
     # FreeBSD 3 and later use GNU C++ and GNU ld with standard ELF
     # conventions
     ld_shlibs_CXX=yes
@@ -113832,34 +114265,21 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
     ;;
   hpux10*|hpux11*)
     if test $with_gnu_ld = no; then
+      hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
+      hardcode_libdir_separator_CXX=:
+
       case $host_cpu in
-      hppa*64*)
-	hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
-	hardcode_libdir_flag_spec_ld_CXX='+b $libdir'
-	hardcode_libdir_separator_CXX=:
-        ;;
-      ia64*)
-	hardcode_libdir_flag_spec_CXX='-L$libdir'
-        ;;
+      hppa*64*|ia64*) ;;
       *)
-	hardcode_libdir_flag_spec_CXX='${wl}+b ${wl}$libdir'
-	hardcode_libdir_separator_CXX=:
 	export_dynamic_flag_spec_CXX='${wl}-E'
         ;;
       esac
     fi
     case $host_cpu in
-    hppa*64*)
+    hppa*64*|ia64*)
       hardcode_direct_CXX=no
       hardcode_shlibpath_var_CXX=no
       ;;
-    ia64*)
-      hardcode_direct_CXX=no
-      hardcode_shlibpath_var_CXX=no
-      hardcode_minus_L_CXX=yes # Not in the search PATH,
-					      # but as the default
-					      # location of the library.
-      ;;
     *)
       hardcode_direct_CXX=yes
       hardcode_minus_L_CXX=yes # Not in the search PATH,
@@ -113875,8 +114295,11 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 	;;
       aCC*)
 	case $host_cpu in
-	hppa*64*|ia64*)
-	  archive_cmds_CXX='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
+	hppa*64*)
+	  archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+	  ;;
+	ia64*)
+	  archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 	  ;;
 	*)
 	  archive_cmds_CXX='$CC -b ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
@@ -113896,8 +114319,11 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 	if test "$GXX" = yes; then
 	  if test $with_gnu_ld = no; then
 	    case $host_cpu in
-	    ia64*|hppa*64*)
-	      archive_cmds_CXX='$LD -b +h $soname -o $lib $linker_flags $libobjs $deplibs'
+	    hppa*64*)
+	      archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+	      ;;
+	    ia64*)
+	      archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+nodefaultrpath -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 	      ;;
 	    *)
 	      archive_cmds_CXX='$CC -shared -nostdlib -fPIC ${wl}+h ${wl}$soname ${wl}+b ${wl}$install_libdir -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
@@ -113911,6 +114337,20 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 	;;
     esac
     ;;
+  interix[3-9]*)
+    hardcode_direct_CXX=no
+    hardcode_shlibpath_var_CXX=no
+    hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
+    export_dynamic_flag_spec_CXX='${wl}-E'
+    # Hack: On Interix 3.x, we cannot compile PIC because of a broken gcc.
+    # Instead, shared libraries are loaded at an image base (0x10000000 by
+    # default) and relocated if they conflict, which is a slow very memory
+    # consuming and fragmenting process.  To avoid this, we pick a random,
+    # 256 KiB-aligned image base between 0x50000000 and 0x6FFC0000 at link
+    # time.  Moving up from 0x10000000 also allows more sbrk(2) space.
+    archive_cmds_CXX='$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
+    archive_expsym_cmds_CXX='sed "s,^,_," $export_symbols >$output_objdir/$soname.expsym~$CC -shared $pic_flag $libobjs $deplibs $compiler_flags ${wl}-h,$soname ${wl}--retain-symbols-file,$output_objdir/$soname.expsym ${wl}--image-base,`expr ${RANDOM-$$} % 4096 / 2 \* 262144 + 1342177280` -o $lib'
+    ;;
   irix5* | irix6*)
     case $cc_basename in
       CC*)
@@ -113937,7 +114377,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
     hardcode_libdir_flag_spec_CXX='${wl}-rpath ${wl}$libdir'
     hardcode_libdir_separator_CXX=:
     ;;
-  linux*)
+  linux* | k*bsd*-gnu)
     case $cc_basename in
       KCC*)
 	# Kuck and Associates, Inc. (KAI) C++ Compiler
@@ -113989,7 +114429,7 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 	export_dynamic_flag_spec_CXX='${wl}--export-dynamic'
 	whole_archive_flag_spec_CXX='${wl}--whole-archive$convenience ${wl}--no-whole-archive'
 	;;
-      pgCC*)
+      pgCC* | pgcpp*)
         # Portland Group C++ compiler
 	archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname -o $lib'
   	archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-soname ${wl}$soname ${wl}-retain-symbols-file ${wl}$export_symbols -o $lib'
@@ -114017,6 +114457,29 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 	# dependencies.
 	output_verbose_link_cmd='templist=`$CC -shared $CFLAGS -v conftest.$objext 2>&1 | grep "ld"`; templist=`echo $templist | $SED "s/\(^.*ld.*\)\( .*ld .*$\)/\1/"`; list=""; for z in $templist; do case $z in conftest.$objext) list="$list $z";; *.$objext);; *) list="$list $z";;esac; done; echo $list'
 	;;
+      *)
+	case `$CC -V 2>&1 | sed 5q` in
+	*Sun\ C*)
+	  # Sun C++ 5.9
+	  no_undefined_flag_CXX=' -zdefs'
+	  archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+	  archive_expsym_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file ${wl}$export_symbols'
+	  hardcode_libdir_flag_spec_CXX='-R$libdir'
+	  whole_archive_flag_spec_CXX='${wl}--whole-archive`new_convenience=; for conv in $convenience\"\"; do test -z \"$conv\" || new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}--no-whole-archive'
+
+	  # Not sure whether something based on
+	  # $CC $CFLAGS -v conftest.$objext -o libconftest$shared_ext 2>&1
+	  # would be better.
+	  output_verbose_link_cmd='echo'
+
+	  # Archives containing C++ object files must be created using
+	  # "CC -xar", where "CC" is the Sun C++ compiler.  This is
+	  # necessary to make sure instantiated templates are included
+	  # in the archive.
+	  old_archive_cmds_CXX='$CC -xar -o $oldlib $oldobjs'
+	  ;;
+	esac
+	;;
     esac
     ;;
   lynxos*)
@@ -114055,16 +114518,20 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
     ld_shlibs_CXX=no
     ;;
   openbsd*)
-    hardcode_direct_CXX=yes
-    hardcode_shlibpath_var_CXX=no
-    archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
-    hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
-    if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
-      archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
-      export_dynamic_flag_spec_CXX='${wl}-E'
-      whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
+    if test -f /usr/libexec/ld.so; then
+      hardcode_direct_CXX=yes
+      hardcode_shlibpath_var_CXX=no
+      archive_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags -o $lib'
+      hardcode_libdir_flag_spec_CXX='${wl}-rpath,$libdir'
+      if test -z "`echo __ELF__ | $CC -E - | grep __ELF__`" || test "$host_os-$host_cpu" = "openbsd2.8-powerpc"; then
+	archive_expsym_cmds_CXX='$CC -shared $pic_flag $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags ${wl}-retain-symbols-file,$export_symbols -o $lib'
+	export_dynamic_flag_spec_CXX='${wl}-E'
+	whole_archive_flag_spec_CXX="$wlarc"'--whole-archive$convenience '"$wlarc"'--no-whole-archive'
+      fi
+      output_verbose_link_cmd='echo'
+    else
+      ld_shlibs_CXX=no
     fi
-    output_verbose_link_cmd='echo'
     ;;
   osf3*)
     case $cc_basename in
@@ -114193,19 +114660,6 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
     # FIXME: insert proper C++ library support
     ld_shlibs_CXX=no
     ;;
-  sco*)
-    archive_cmds_need_lc_CXX=no
-    case $cc_basename in
-      CC*)
-	# FIXME: insert proper C++ library support
-	ld_shlibs_CXX=no
-	;;
-      *)
-	# FIXME: insert proper C++ library support
-	ld_shlibs_CXX=no
-	;;
-    esac
-    ;;
   sunos4*)
     case $cc_basename in
       CC*)
@@ -114228,26 +114682,21 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
     case $cc_basename in
       CC*)
 	# Sun C++ 4.2, 5.x and Centerline C++
-     archive_cmds_need_lc_CXX=yes
+        archive_cmds_need_lc_CXX=yes
 	no_undefined_flag_CXX=' -zdefs'
-	archive_cmds_CXX='$CC -G${allow_undefined_flag} -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
+	archive_cmds_CXX='$CC -G${allow_undefined_flag}  -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags'
 	archive_expsym_cmds_CXX='$echo "{ global:" > $lib.exp~cat $export_symbols | $SED -e "s/\(.*\)/\1;/" >> $lib.exp~$echo "local: *; };" >> $lib.exp~
-	$CC -G${allow_undefined_flag} ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
+	$CC -G${allow_undefined_flag}  ${wl}-M ${wl}$lib.exp -h$soname -o $lib $predep_objects $libobjs $deplibs $postdep_objects $compiler_flags~$rm $lib.exp'
 
 	hardcode_libdir_flag_spec_CXX='-R$libdir'
 	hardcode_shlibpath_var_CXX=no
 	case $host_os in
 	  solaris2.[0-5] | solaris2.[0-5].*) ;;
 	  *)
-	    # The C++ compiler is used as linker so we must use $wl
-	    # flag to pass the commands to the underlying system
-	    # linker. We must also pass each convience library through
-	    # to the system linker between allextract/defaultextract.
-	    # The C++ compiler will combine linker options so we
-	    # cannot just pass the convience library names through
-	    # without $wl.
+	    # The compiler driver will combine and reorder linker options,
+	    # but understands `-z linker_flag'.
 	    # Supported since Solaris 2.6 (maybe 2.5.1?)
-	    whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract`for conv in $convenience\"\"; do test -n \"$conv\" && new_convenience=\"$new_convenience,$conv\"; done; $echo \"$new_convenience\"` ${wl}-z ${wl}defaultextract'
+	    whole_archive_flag_spec_CXX='-z allextract$convenience -z defaultextract'
 	    ;;
 	esac
 	link_all_deplibs_CXX=yes
@@ -114294,12 +114743,69 @@ if test -z "$aix_libpath"; then aix_libpath="/usr/lib:/lib"; fi
 	  fi
 
 	  hardcode_libdir_flag_spec_CXX='${wl}-R $wl$libdir'
+	  case $host_os in
+	  solaris2.[0-5] | solaris2.[0-5].*) ;;
+	  *)
+	    whole_archive_flag_spec_CXX='${wl}-z ${wl}allextract$convenience ${wl}-z ${wl}defaultextract'
+	    ;;
+	  esac
 	fi
 	;;
     esac
     ;;
-  sysv5OpenUNIX8* | sysv5UnixWare7* | sysv5uw[78]* | unixware7*)
+  sysv4*uw2* | sysv5OpenUNIX* | sysv5UnixWare7.[01].[10]* | unixware7* | sco3.2v5.0.[024]*)
+    no_undefined_flag_CXX='${wl}-z,text'
+    archive_cmds_need_lc_CXX=no
+    hardcode_shlibpath_var_CXX=no
+    runpath_var='LD_RUN_PATH'
+
+    case $cc_basename in
+      CC*)
+	archive_cmds_CXX='$CC -G ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	;;
+      *)
+	archive_cmds_CXX='$CC -shared ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,$soname -o $lib $libobjs $deplibs $compiler_flags'
+	;;
+    esac
+    ;;
+  sysv5* | sco3.2v5* | sco5v6*)
+    # Note: We can NOT use -z defs as we might desire, because we do not
+    # link with -lc, and that would cause any symbols used from libc to
+    # always be unresolved, which means just about no library would
+    # ever link correctly.  If we're not using GNU ld we use -z text
+    # though, which does catch some bad symbols but isn't as heavy-handed
+    # as -z defs.
+    # For security reasons, it is highly recommended that you always
+    # use absolute paths for naming shared libraries, and exclude the
+    # DT_RUNPATH tag from executables and libraries.  But doing so
+    # requires that you compile everything twice, which is a pain.
+    # So that behaviour is only enabled if SCOABSPATH is set to a
+    # non-empty value in the environment.  Most likely only useful for
+    # creating official distributions of packages.
+    # This is a hack until libtool officially supports absolute path
+    # names for shared libraries.
+    no_undefined_flag_CXX='${wl}-z,text'
+    allow_undefined_flag_CXX='${wl}-z,nodefs'
     archive_cmds_need_lc_CXX=no
+    hardcode_shlibpath_var_CXX=no
+    hardcode_libdir_flag_spec_CXX='`test -z "$SCOABSPATH" && echo ${wl}-R,$libdir`'
+    hardcode_libdir_separator_CXX=':'
+    link_all_deplibs_CXX=yes
+    export_dynamic_flag_spec_CXX='${wl}-Bexport'
+    runpath_var='LD_RUN_PATH'
+
+    case $cc_basename in
+      CC*)
+	archive_cmds_CXX='$CC -G ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	archive_expsym_cmds_CXX='$CC -G ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	;;
+      *)
+	archive_cmds_CXX='$CC -shared ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	archive_expsym_cmds_CXX='$CC -shared ${wl}-Bexport:$export_symbols ${wl}-h,\${SCOABSPATH:+${install_libdir}/}$soname -o $lib $libobjs $deplibs $compiler_flags'
+	;;
+    esac
     ;;
   tandem*)
     case $cc_basename in
@@ -114333,7 +114839,6 @@ LD_CXX="$LD"
 ## There is no encapsulation within the following macros, do not change
 ## the running order or otherwise move them around unless you know exactly
 ## what you are doing...
-
 cat > conftest.$ac_ext <<EOF
 class Foo
 {
@@ -114344,7 +114849,7 @@ private:
 };
 EOF
 
-if { (eval echo configure:114348: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:114853: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   # Parse the compiler output and extract the necessary
   # objects, libraries and library flags.
 
@@ -114431,20 +114936,66 @@ fi
 
 $rm -f confest.$objext
 
+compiler_lib_search_dirs_CXX=
+if test -n "$compiler_lib_search_path_CXX"; then
+  compiler_lib_search_dirs_CXX=`echo " ${compiler_lib_search_path_CXX}" | ${SED} -e 's! -L! !g' -e 's!^ !!'`
+fi
+
 # PORTME: override above test on systems where it is broken
 case $host_os in
+interix[3-9]*)
+  # Interix 3.5 installs completely hosed .la files for C++, so rather than
+  # hack all around it, let's just trust "g++" to DTRT.
+  predep_objects_CXX=
+  postdep_objects_CXX=
+  postdeps_CXX=
+  ;;
+
+linux*)
+  case `$CC -V 2>&1 | sed 5q` in
+  *Sun\ C*)
+    # Sun C++ 5.9
+    #
+    # The more standards-conforming stlport4 library is
+    # incompatible with the Cstd library. Avoid specifying
+    # it if it's in CXXFLAGS. Ignore libCrun as
+    # -library=stlport4 depends on it.
+    case " $CXX $CXXFLAGS " in
+    *" -library=stlport4 "*)
+      solaris_use_stlport4=yes
+      ;;
+    esac
+    if test "$solaris_use_stlport4" != yes; then
+      postdeps_CXX='-library=Cstd -library=Crun'
+    fi
+    ;;
+  esac
+  ;;
+
 solaris*)
   case $cc_basename in
   CC*)
+    # The more standards-conforming stlport4 library is
+    # incompatible with the Cstd library. Avoid specifying
+    # it if it's in CXXFLAGS. Ignore libCrun as
+    # -library=stlport4 depends on it.
+    case " $CXX $CXXFLAGS " in
+    *" -library=stlport4 "*)
+      solaris_use_stlport4=yes
+      ;;
+    esac
+
     # Adding this requires a known-good setup of shared libraries for
     # Sun compiler versions before 5.6, else PIC objects from an old
     # archive will be linked into the output, leading to subtle bugs.
-    postdeps_CXX='-lCstd -lCrun'
+    if test "$solaris_use_stlport4" != yes; then
+      postdeps_CXX='-library=Cstd -library=Crun'
+    fi
     ;;
   esac
+  ;;
 esac
 
-
 case " $postdeps_CXX " in
 *" -lc "*) archive_cmds_need_lc_CXX=no ;;
 esac
@@ -114454,7 +115005,7 @@ lt_prog_compiler_pic_CXX=
 lt_prog_compiler_static_CXX=
 
 echo $ac_n "checking for $compiler option to produce PIC""... $ac_c" 1>&6
-echo "configure:114458: checking for $compiler option to produce PIC" >&5
+echo "configure:115009: checking for $compiler option to produce PIC" >&5
  
   # C++ specific cases for pic, static, wl, etc.
   if test "$GXX" = yes; then
@@ -114475,13 +115026,15 @@ echo "configure:114458: checking for $compiler option to produce PIC" >&5
       # like `-m68040'.
       lt_prog_compiler_pic_CXX='-m68020 -resident32 -malways-restore-a4'
       ;;
-    beos* | cygwin* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
+    beos* | irix5* | irix6* | nonstopux* | osf3* | osf4* | osf5*)
       # PIC is the default for these OSes.
       ;;
-    mingw* | os2* | pw32*)
+    mingw* | cygwin* | os2* | pw32*)
       # This hack is so that the source file can tell whether it is being
       # built for inclusion in a dll (and should export symbols for example).
-      lt_prog_compiler_pic_CXX='-DDLL_EXPORT'
+      # Although the cygwin gcc ignores -fPIC, still need this for old-style
+      # (--disable-auto-import) libraries
+	  lt_prog_compiler_pic_CXX='-DDLL_EXPORT'
       ;;
     darwin* | rhapsody*)
       # PIC is the default on this platform
@@ -114492,6 +115045,10 @@ echo "configure:114458: checking for $compiler option to produce PIC" >&5
       # DJGPP does not support shared libraries at all
       lt_prog_compiler_pic_CXX=
       ;;
+    interix[3-9]*)
+      # Interix 3.x gcc -fpic/-fPIC options generate broken code.
+      # Instead, we relocate shared libraries at runtime.
+      ;;
     sysv4*MP*)
       if test -d /usr/nec; then
 	lt_prog_compiler_pic_CXX=-Kconform_pic
@@ -114514,7 +115071,7 @@ echo "configure:114458: checking for $compiler option to produce PIC" >&5
     esac
   else
     case $host_os in
-      aix4* | aix5*)
+      aix[4-9]*)
 	# All AIX code is PIC.
 	if test "$host_cpu" = ia64; then
 	  # AIX 5 now supports IA64 processor
@@ -114554,21 +115111,21 @@ echo "configure:114458: checking for $compiler option to produce PIC" >&5
 	    ;;
 	esac
 	;;
-      freebsd* | kfreebsd*-gnu | dragonfly*)
+      freebsd* | dragonfly*)
 	# FreeBSD uses GNU C++
 	;;
       hpux9* | hpux10* | hpux11*)
 	case $cc_basename in
 	  CC*)
 	    lt_prog_compiler_wl_CXX='-Wl,'
-	    lt_prog_compiler_static_CXX="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
+	    lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
 	    if test "$host_cpu" != ia64; then
 	      lt_prog_compiler_pic_CXX='+Z'
 	    fi
 	    ;;
 	  aCC*)
 	    lt_prog_compiler_wl_CXX='-Wl,'
-	    lt_prog_compiler_static_CXX="${ac_cv_prog_cc_wl}-a ${ac_cv_prog_cc_wl}archive"
+	    lt_prog_compiler_static_CXX='${wl}-a ${wl}archive'
 	    case $host_cpu in
 	    hppa*64*|ia64*)
 	      # +Z the default
@@ -114582,6 +115139,10 @@ echo "configure:114458: checking for $compiler option to produce PIC" >&5
 	    ;;
 	esac
 	;;
+      interix*)
+	# This is c89, which is MS Visual C++ (no shared libs)
+	# Anyone wants to do a port?
+	;;
       irix5* | irix6* | nonstopux*)
 	case $cc_basename in
 	  CC*)
@@ -114593,7 +115154,7 @@ echo "configure:114458: checking for $compiler option to produce PIC" >&5
 	    ;;
 	esac
 	;;
-      linux*)
+      linux* | k*bsd*-gnu)
 	case $cc_basename in
 	  KCC*)
 	    # KAI C++ Compiler
@@ -114612,7 +115173,7 @@ echo "configure:114458: checking for $compiler option to produce PIC" >&5
         lt_prog_compiler_pic_CXX='-fPIC'
         lt_prog_compiler_static_CXX='-static'
         ;;
-	  pgCC*)
+	  pgCC* | pgcpp*)
 	    # Portland Group C++ compiler.
 	    lt_prog_compiler_wl_CXX='-Wl,'
 	    lt_prog_compiler_pic_CXX='-fpic'
@@ -114626,6 +115187,14 @@ echo "configure:114458: checking for $compiler option to produce PIC" >&5
 	    lt_prog_compiler_static_CXX='-non_shared'
 	    ;;
 	  *)
+	    case `$CC -V 2>&1 | sed 5q` in
+	    *Sun\ C*)
+	      # Sun C++ 5.9
+	      lt_prog_compiler_pic_CXX='-KPIC'
+	      lt_prog_compiler_static_CXX='-Bstatic'
+	      lt_prog_compiler_wl_CXX='-Qoption ld '
+	      ;;
+	    esac
 	    ;;
 	esac
 	;;
@@ -114667,15 +115236,6 @@ echo "configure:114458: checking for $compiler option to produce PIC" >&5
 	;;
       psos*)
 	;;
-      sco*)
-	case $cc_basename in
-	  CC*)
-	    lt_prog_compiler_pic_CXX='-fPIC'
-	    ;;
-	  *)
-	    ;;
-	esac
-	;;
       solaris*)
 	case $cc_basename in
 	  CC*)
@@ -114717,7 +115277,14 @@ echo "configure:114458: checking for $compiler option to produce PIC" >&5
 	    ;;
 	esac
 	;;
-      unixware*)
+      sysv5* | unixware* | sco3.2v5* | sco5v6* | OpenUNIX*)
+	case $cc_basename in
+	  CC*)
+	    lt_prog_compiler_wl_CXX='-Wl,'
+	    lt_prog_compiler_pic_CXX='-KPIC'
+	    lt_prog_compiler_static_CXX='-Bstatic'
+	    ;;
+	esac
 	;;
       vxworks*)
 	;;
@@ -114735,13 +115302,13 @@ echo "$ac_t""$lt_prog_compiler_pic_CXX" 1>&6
 if test -n "$lt_prog_compiler_pic_CXX"; then
   
 echo $ac_n "checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works""... $ac_c" 1>&6
-echo "configure:114739: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5
-if eval "test \"`echo '$''{'lt_prog_compiler_pic_works_CXX'+set}'`\" = set"; then
+echo "configure:115306: checking if $compiler PIC flag $lt_prog_compiler_pic_CXX works" >&5
+if eval "test \"`echo '$''{'lt_cv_prog_compiler_pic_works_CXX'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
-  lt_prog_compiler_pic_works_CXX=no
+  lt_cv_prog_compiler_pic_works_CXX=no
   ac_outfile=conftest.$ac_objext
-   printf "$lt_simple_compile_test_code" > conftest.$ac_ext
+   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
    lt_compiler_flag="$lt_prog_compiler_pic_CXX -DPIC"
    # Insert the option either (1) after the last *FLAGS variable, or
    # (2) before a word containing "conftest.", or (3) at the end.
@@ -114752,27 +115319,27 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"configure:114756: $lt_compile\"" >&5)
+   (eval echo "\"configure:115323: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>conftest.err)
    ac_status=$?
    cat conftest.err >&5
-   echo "configure:114760: \$? = $ac_status" >&5
+   echo "configure:115327: \$? = $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.
-     $echo "X$_lt_compiler_boilerplate" | $Xsed >conftest.exp
-     $SED '/^$/d' conftest.err >conftest.er2
-     if test ! -s conftest.err || diff conftest.exp conftest.er2 >/dev/null; then
-       lt_prog_compiler_pic_works_CXX=yes
+     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' >conftest.exp
+     $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
+     if test ! -s conftest.er2 || diff conftest.exp conftest.er2 >/dev/null; then
+       lt_cv_prog_compiler_pic_works_CXX=yes
      fi
    fi
    $rm conftest*
 
 fi
 
-echo "$ac_t""$lt_prog_compiler_pic_works_CXX" 1>&6
+echo "$ac_t""$lt_cv_prog_compiler_pic_works_CXX" 1>&6
 
-if test x"$lt_prog_compiler_pic_works_CXX" = xyes; then
+if test x"$lt_cv_prog_compiler_pic_works_CXX" = xyes; then
     case $lt_prog_compiler_pic_CXX in
      "" | " "*) ;;
      *) lt_prog_compiler_pic_CXX=" $lt_prog_compiler_pic_CXX" ;;
@@ -114793,8 +115360,50 @@ case $host_os in
     ;;
 esac
 
+#
+# 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 $ac_n "checking if $compiler static flag $lt_tmp_static_flag works""... $ac_c" 1>&6
+echo "configure:115369: checking if $compiler static flag $lt_tmp_static_flag works" >&5
+if eval "test \"`echo '$''{'lt_cv_prog_compiler_static_works_CXX'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  lt_cv_prog_compiler_static_works_CXX=no
+   save_LDFLAGS="$LDFLAGS"
+   LDFLAGS="$LDFLAGS $lt_tmp_static_flag"
+   echo "$lt_simple_link_test_code" > conftest.$ac_ext
+   if (eval $ac_link 2>conftest.err) && test -s conftest$ac_exeext; then
+     # The linker can only warn and ignore the option if not recognized
+     # So say no if there are warnings
+     if test -s conftest.err; then
+       # Append any errors to the config.log.
+       cat conftest.err 1>&5
+       $echo "X$_lt_linker_boilerplate" | $Xsed -e '/^$/d' > conftest.exp
+       $SED '/^$/d; /^ *+/d' conftest.err >conftest.er2
+       if diff conftest.exp conftest.er2 >/dev/null; then
+         lt_cv_prog_compiler_static_works_CXX=yes
+       fi
+     else
+       lt_cv_prog_compiler_static_works_CXX=yes
+     fi
+   fi
+   $rm -r conftest*
+   LDFLAGS="$save_LDFLAGS"
+
+fi
+
+echo "$ac_t""$lt_cv_prog_compiler_static_works_CXX" 1>&6
+
+if test x"$lt_cv_prog_compiler_static_works_CXX" = xyes; then
+    :
+else
+    lt_prog_compiler_static_CXX=
+fi
+
+
 echo $ac_n "checking if $compiler supports -c -o file.$ac_objext""... $ac_c" 1>&6
-echo "configure:114798: checking if $compiler supports -c -o file.$ac_objext" >&5
+echo "configure:115407: checking if $compiler supports -c -o file.$ac_objext" >&5
 if eval "test \"`echo '$''{'lt_cv_prog_compiler_c_o_CXX'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -114803,7 +115412,7 @@ else
    mkdir conftest
    cd conftest
    mkdir out
-   printf "$lt_simple_compile_test_code" > conftest.$ac_ext
+   echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
    lt_compiler_flag="-o out/conftest2.$ac_objext"
    # Insert the option either (1) after the last *FLAGS variable, or
@@ -114814,18 +115423,18 @@ else
    -e 's:.*FLAGS}\{0,1\} :&$lt_compiler_flag :; t' \
    -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
    -e 's:$: $lt_compiler_flag:'`
-   (eval echo "\"configure:114818: $lt_compile\"" >&5)
+   (eval echo "\"configure:115427: $lt_compile\"" >&5)
    (eval "$lt_compile" 2>out/conftest.err)
    ac_status=$?
    cat out/conftest.err >&5
-   echo "configure:114822: \$? = $ac_status" >&5
+   echo "configure:115431: \$? = $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
      # So say no if there are warnings
-     $echo "X$_lt_compiler_boilerplate" | $Xsed > out/conftest.exp
-     $SED '/^$/d' out/conftest.err >out/conftest.er2
-     if test ! -s out/conftest.err || diff out/conftest.exp out/conftest.er2 >/dev/null; then
+     $echo "X$_lt_compiler_boilerplate" | $Xsed -e '/^$/d' > out/conftest.exp
+     $SED '/^$/d; /^ *+/d' out/conftest.err >out/conftest.er2
+     if test ! -s out/conftest.er2 || diff out/conftest.exp out/conftest.er2 >/dev/null; then
        lt_cv_prog_compiler_c_o_CXX=yes
      fi
    fi
@@ -114848,7 +115457,7 @@ 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 $ac_n "checking if we can lock with hard links""... $ac_c" 1>&6
-echo "configure:114852: checking if we can lock with hard links" >&5
+echo "configure:115461: checking if we can lock with hard links" >&5
   hard_links=yes
   $rm conftest*
   ln conftest.a conftest.b 2>/dev/null && hard_links=no
@@ -114865,11 +115474,11 @@ else
 fi
 
 echo $ac_n "checking whether the $compiler linker ($LD) supports shared libraries""... $ac_c" 1>&6
-echo "configure:114869: checking whether the $compiler linker ($LD) supports shared libraries" >&5
+echo "configure:115478: checking whether the $compiler linker ($LD) supports shared libraries" >&5
 
   export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
   case $host_os in
-  aix4* | aix5*)
+  aix[4-9]*)
     # If we're using GNU nm, then we don't want the "-C" option.
     # -C means demangle to AIX nm, but means don't demangle with GNU nm
     if $NM -V 2>&1 | grep 'GNU' > /dev/null; then
@@ -114882,21 +115491,17 @@ echo "configure:114869: checking whether the $compiler linker ($LD) supports sha
     export_symbols_cmds_CXX="$ltdll_cmds"
   ;;
   cygwin* | mingw*)
-    export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS] /s/.* \([^ ]*\)/\1 DATA/;/^.* __nm__/s/^.* __nm__\([^ ]*\) [^ ]*/\1 DATA/;/^I /d;/^[AITW] /s/.* //'\'' | sort | uniq > $export_symbols'
+    export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED -e '\''/^[BCDGRS][ ]/s/.*[ ]\([^ ]*\)/\1 DATA/;/^.*[ ]__nm__/s/^.*[ ]__nm__\([^ ]*\)[ ][^ ]*/\1 DATA/;/^I[ ]/d;/^[AITW][ ]/s/.*[ ]//'\'' | sort | uniq > $export_symbols'
   ;;
   *)
     export_symbols_cmds_CXX='$NM $libobjs $convenience | $global_symbol_pipe | $SED '\''s/.* //'\'' | sort | uniq > $export_symbols'
   ;;
   esac
+  exclude_expsyms_CXX='_GLOBAL_OFFSET_TABLE_|_GLOBAL__F[ID]_.*'
 
 echo "$ac_t""$ld_shlibs_CXX" 1>&6
 test "$ld_shlibs_CXX" = no && can_build_shared=no
 
-variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
-if test "$GCC" = yes; then
-  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
-fi
-
 #
 # Do we need to explicitly link libc?
 #
@@ -114915,16 +115520,17 @@ x|xyes)
       # systems, -lgcc has to come before -lc. If gcc already passes -lc
       # to ld, don't add -lc before -lgcc.
       echo $ac_n "checking whether -lc should be explicitly linked in""... $ac_c" 1>&6
-echo "configure:114919: checking whether -lc should be explicitly linked in" >&5
+echo "configure:115524: checking whether -lc should be explicitly linked in" >&5
       $rm conftest*
-      printf "$lt_simple_compile_test_code" > conftest.$ac_ext
+      echo "$lt_simple_compile_test_code" > conftest.$ac_ext
 
-      if { (eval echo configure:114923: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; } 2>conftest.err; then
+      if { (eval echo configure:115528: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; } 2>conftest.err; then
         soname=conftest
         lib=conftest
         libobjs=conftest.$ac_objext
         deplibs=
         wl=$lt_prog_compiler_wl_CXX
+	pic_flag=$lt_prog_compiler_pic_CXX
         compiler_flags=-v
         linker_flags=-v
         verstring=
@@ -114932,7 +115538,7 @@ echo "configure:114919: checking whether -lc should be explicitly linked in" >&5
         libname=conftest
         lt_save_allow_undefined_flag=$allow_undefined_flag_CXX
         allow_undefined_flag_CXX=
-        if { (eval echo configure:114936: \"$archive_cmds_CXX 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\") 1>&5; (eval $archive_cmds_CXX 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5; }
+        if { (eval echo configure:115542: \"$archive_cmds_CXX 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1\") 1>&5; (eval $archive_cmds_CXX 2\>\&1 \| grep \" -lc \" \>/dev/null 2\>\&1) 2>&5; }
         then
 	  archive_cmds_need_lc_CXX=no
         else
@@ -114951,7 +115557,7 @@ echo "configure:114919: checking whether -lc should be explicitly linked in" >&5
 esac
 
 echo $ac_n "checking dynamic linker characteristics""... $ac_c" 1>&6
-echo "configure:114955: checking dynamic linker characteristics" >&5
+echo "configure:115561: checking dynamic linker characteristics" >&5
 library_names_spec=
 libname_spec='lib$name'
 soname_spec=
@@ -114965,20 +115571,7 @@ shlibpath_overrides_runpath=unknown
 version_type=none
 dynamic_linker="$host_os ld.so"
 sys_lib_dlsearch_path_spec="/lib /usr/lib"
-if test "$GCC" = yes; then
-  sys_lib_search_path_spec=`$CC -print-search-dirs | grep "^libraries:" | $SED -e "s/^libraries://" -e "s,=/,/,g"`
-  if echo "$sys_lib_search_path_spec" | grep ';' >/dev/null ; then
-    # if the path contains ";" then we assume it to be the separator
-    # otherwise default to the standard path separator (i.e. ":") - it is
-    # assumed that no part of a normal pathname contains ";" but that should
-    # okay in the real world where ";" in dirpaths is itself problematic.
-    sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED -e 's/;/ /g'`
-  else
-    sys_lib_search_path_spec=`echo "$sys_lib_search_path_spec" | $SED  -e "s/$PATH_SEPARATOR/ /g"`
-  fi
-else
-  sys_lib_search_path_spec="/lib /usr/lib /usr/local/lib"
-fi
+
 need_lib_prefix=unknown
 hardcode_into_libs=no
 
@@ -114996,7 +115589,7 @@ aix3*)
   soname_spec='${libname}${release}${shared_ext}$major'
   ;;
 
-aix4* | aix5*)
+aix[4-9]*)
   version_type=linux
   need_lib_prefix=no
   need_version=no
@@ -115135,12 +115728,7 @@ darwin* | rhapsody*)
   shlibpath_overrides_runpath=yes
   shlibpath_var=DYLD_LIBRARY_PATH
   shrext_cmds='`test .$module = .yes && echo .so || echo .dylib`'
-  # Apple's gcc prints 'gcc -print-search-dirs' doesn't operate the same.
-  if test "$GCC" = yes; then
-    sys_lib_search_path_spec=`$CC -print-search-dirs | tr "\n" "$PATH_SEPARATOR" | sed -e 's/libraries:/@libraries:/' | tr "@" "\n" | grep "^libraries:" | sed -e "s/^libraries://" -e "s,=/,/,g" -e "s,$PATH_SEPARATOR, ,g" -e "s,.*,& /lib /usr/lib /usr/local/lib,g"`
-  else
-    sys_lib_search_path_spec='/lib /usr/lib /usr/local/lib'
-  fi
+   
   sys_lib_dlsearch_path_spec='/usr/local/lib /lib /usr/lib'
   ;;
 
@@ -115157,18 +115745,6 @@ freebsd1*)
   dynamic_linker=no
   ;;
 
-kfreebsd*-gnu)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=no
-  hardcode_into_libs=yes
-  dynamic_linker='GNU ld.so'
-  ;;
-
 freebsd* | dragonfly*)
   # DragonFly does not have aout.  When/if they implement a new
   # versioning mechanism, adjust this.
@@ -115201,10 +115777,15 @@ freebsd* | dragonfly*)
     shlibpath_overrides_runpath=yes
     hardcode_into_libs=yes
     ;;
-  *) # from 3.2 on
+  freebsd3.[2-9]* | freebsdelf3.[2-9]* | \
+  freebsd4.[0-5] | freebsdelf4.[0-5] | freebsd4.1.1 | freebsdelf4.1.1)
     shlibpath_overrides_runpath=no
     hardcode_into_libs=yes
     ;;
+  *) # from 4.6 on, and DragonFly
+    shlibpath_overrides_runpath=yes
+    hardcode_into_libs=yes
+    ;;
   esac
   ;;
 
@@ -115264,6 +115845,18 @@ hpux9* | hpux10* | hpux11*)
   postinstall_cmds='chmod 555 $lib'
   ;;
 
+interix[3-9]*)
+  version_type=linux
+  need_lib_prefix=no
+  need_version=no
+  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
+  soname_spec='${libname}${release}${shared_ext}$major'
+  dynamic_linker='Interix 3.x ld.so.1 (PE, like ELF)'
+  shlibpath_var=LD_LIBRARY_PATH
+  shlibpath_overrides_runpath=no
+  hardcode_into_libs=yes
+  ;;
+
 irix5* | irix6* | nonstopux*)
   case $host_os in
     nonstopux*) version_type=nonstopux ;;
@@ -115307,7 +115900,7 @@ linux*oldld* | linux*aout* | linux*coff*)
   ;;
 
 # This must be Linux ELF.
-linux*)
+linux* | k*bsd*-gnu)
   version_type=linux
   need_lib_prefix=no
   need_version=no
@@ -115321,27 +115914,10 @@ linux*)
   # before this can be enabled.
   hardcode_into_libs=yes
 
-  # find out which ABI we are using
-  libsuff=
-  case $host_cpu in
-  x86_64*|s390x*|powerpc64*)
-    echo '#line 115329 "configure"' > conftest.$ac_ext
-    if { (eval echo configure:115330: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
-      case `/usr/bin/file conftest.$ac_objext` in
-      *64-bit*)
-        libsuff=64
-        sys_lib_search_path_spec="/lib${libsuff} /usr/lib${libsuff} /usr/local/lib${libsuff}"
-        ;;
-      esac
-    fi
-    rm -rf conftest*
-    ;;
-  esac
-
   # Append ld.so.conf contents to the search path
   if test -f /etc/ld.so.conf; then
-    lt_ld_extra=`$SED -e 's/:,\t/ /g;s/=^=*$//;s/=^= * / /g' /etc/ld.so.conf | tr '\n' ' '`
-    sys_lib_dlsearch_path_spec="/lib${libsuff} /usr/lib${libsuff} $lt_ld_extra"
+    lt_ld_extra=`awk '/^include / { system(sprintf("cd /etc; cat %s 2>/dev/null", \$2)); skip = 1; } { if (!skip) print \$0; skip = 0; }' < /etc/ld.so.conf | $SED -e 's/#.*//;/^[ 	]*hwcap[ 	]/d;s/[:,	]/ /g;s/=[^=]*$//;s/=[^= ]* / /g;/^$/d' | tr '\n' ' '`
+    sys_lib_dlsearch_path_spec="/lib /usr/lib $lt_ld_extra"
   fi
 
   # We used to test for /lib/ld.so.1 and disable shared libraries on
@@ -115353,18 +115929,6 @@ linux*)
   dynamic_linker='GNU/Linux ld.so'
   ;;
 
-knetbsd*-gnu)
-  version_type=linux
-  need_lib_prefix=no
-  need_version=no
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major ${libname}${shared_ext}'
-  soname_spec='${libname}${release}${shared_ext}$major'
-  shlibpath_var=LD_LIBRARY_PATH
-  shlibpath_overrides_runpath=no
-  hardcode_into_libs=yes
-  dynamic_linker='GNU ld.so'
-  ;;
-
 netbsd*)
   version_type=sunos
   need_lib_prefix=no
@@ -115402,6 +115966,7 @@ nto-qnx*)
 
 openbsd*)
   version_type=sunos
+  sys_lib_dlsearch_path_spec="/usr/lib"
   need_lib_prefix=no
   # Some older versions of OpenBSD (3.3 at least) *do* need versioned libs.
   case $host_os in
@@ -115445,11 +116010,8 @@ osf3* | osf4* | osf5*)
   sys_lib_dlsearch_path_spec="$sys_lib_search_path_spec"
   ;;
 
-sco3.2v5*)
-  version_type=osf
-  soname_spec='${libname}${release}${shared_ext}$major'
-  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
-  shlibpath_var=LD_LIBRARY_PATH
+rdos*)
+  dynamic_linker=no
   ;;
 
 solaris*)
@@ -115477,7 +116039,7 @@ sunos4*)
   need_version=yes
   ;;
 
-sysv4 | sysv4.2uw2* | sysv4.3* | sysv5*)
+sysv4 | sysv4.3*)
   version_type=linux
   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
   soname_spec='${libname}${release}${shared_ext}$major'
@@ -115510,6 +116072,29 @@ sysv4*MP*)
   fi
   ;;
 
+sysv5* | sco3.2v5* | sco5v6* | unixware* | OpenUNIX* | sysv4*uw2*)
+  version_type=freebsd-elf
+  need_lib_prefix=no
+  need_version=no
+  library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext} $libname${shared_ext}'
+  soname_spec='${libname}${release}${shared_ext}$major'
+  shlibpath_var=LD_LIBRARY_PATH
+  hardcode_into_libs=yes
+  if test "$with_gnu_ld" = yes; then
+    sys_lib_search_path_spec='/usr/local/lib /usr/gnu/lib /usr/ccs/lib /usr/lib /lib'
+    shlibpath_overrides_runpath=no
+  else
+    sys_lib_search_path_spec='/usr/ccs/lib /usr/lib'
+    shlibpath_overrides_runpath=yes
+    case $host_os in
+      sco3.2v5*)
+        sys_lib_search_path_spec="$sys_lib_search_path_spec /lib"
+	;;
+    esac
+  fi
+  sys_lib_dlsearch_path_spec='/usr/lib'
+  ;;
+
 uts4*)
   version_type=linux
   library_names_spec='${libname}${release}${shared_ext}$versuffix ${libname}${release}${shared_ext}$major $libname${shared_ext}'
@@ -115524,8 +116109,28 @@ esac
 echo "$ac_t""$dynamic_linker" 1>&6
 test "$dynamic_linker" = no && can_build_shared=no
 
+if eval "test \"`echo '$''{'lt_cv_sys_lib_search_path_spec'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  lt_cv_sys_lib_search_path_spec="$sys_lib_search_path_spec"
+fi
+
+sys_lib_search_path_spec="$lt_cv_sys_lib_search_path_spec"
+if eval "test \"`echo '$''{'lt_cv_sys_lib_dlsearch_path_spec'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  lt_cv_sys_lib_dlsearch_path_spec="$sys_lib_dlsearch_path_spec"
+fi
+
+sys_lib_dlsearch_path_spec="$lt_cv_sys_lib_dlsearch_path_spec"
+
+variables_saved_for_relink="PATH $shlibpath_var $runpath_var"
+if test "$GCC" = yes; then
+  variables_saved_for_relink="$variables_saved_for_relink GCC_EXEC_PREFIX COMPILER_PATH LIBRARY_PATH"
+fi
+
 echo $ac_n "checking how to hardcode library paths into programs""... $ac_c" 1>&6
-echo "configure:115529: checking how to hardcode library paths into programs" >&5
+echo "configure:116134: checking how to hardcode library paths into programs" >&5
 hardcode_action_CXX=
 if test -n "$hardcode_libdir_flag_spec_CXX" || \
    test -n "$runpath_var_CXX" || \
@@ -115560,612 +116165,6 @@ elif test "$shlibpath_overrides_runpath" = yes ||
   enable_fast_install=needless
 fi
 
-striplib=
-old_striplib=
-echo $ac_n "checking whether stripping libraries is possible""... $ac_c" 1>&6
-echo "configure:115567: checking whether stripping libraries is possible" >&5
-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 "$ac_t""yes" 1>&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 "$ac_t""yes" 1>&6
-       else
-  echo "$ac_t""no" 1>&6
-fi
-       ;;
-   *)
-  echo "$ac_t""no" 1>&6
-    ;;
-  esac
-fi
-
-if test "x$enable_dlopen" != xyes; then
-  enable_dlopen=unknown
-  enable_dlopen_self=unknown
-  enable_dlopen_self_static=unknown
-else
-  lt_cv_dlopen=no
-  lt_cv_dlopen_libs=
-
-  case $host_os in
-  beos*)
-    lt_cv_dlopen="load_add_on"
-    lt_cv_dlopen_libs=
-    lt_cv_dlopen_self=yes
-    ;;
-
-  mingw* | pw32*)
-    lt_cv_dlopen="LoadLibrary"
-    lt_cv_dlopen_libs=
-   ;;
-
-  cygwin*)
-    lt_cv_dlopen="dlopen"
-    lt_cv_dlopen_libs=
-   ;;
-
-  darwin*)
-  # if libdl is installed we need to link against it
-    echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
-echo "configure:115617: checking for dlopen in -ldl" >&5
-ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  ac_save_LIBS="$LIBS"
-LIBS="-ldl  $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 115625 "configure"
-#include "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 dlopen();
-
-int main() {
-dlopen()
-; return 0; }
-EOF
-if { (eval echo configure:115639: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
-else
-  echo "$ac_t""no" 1>&6
-
-    lt_cv_dlopen="dyld"
-    lt_cv_dlopen_libs=
-    lt_cv_dlopen_self=yes
-    
-fi
-
-   ;;
-
-  *)
-    echo $ac_n "checking for shl_load""... $ac_c" 1>&6
-echo "configure:115668: checking for shl_load" >&5
-if eval "test \"`echo '$''{'ac_cv_func_shl_load'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 115673 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char shl_load(); below.  */
-#include <assert.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 shl_load();
-
-int main() {
-
-/* 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)
-choke me
-#else
-shl_load();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:115699: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_func_shl_load=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_func_shl_load=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'shl_load`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  lt_cv_dlopen="shl_load"
-else
-  echo "$ac_t""no" 1>&6
-echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6
-echo "configure:115717: checking for shl_load in -ldld" >&5
-ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  ac_save_LIBS="$LIBS"
-LIBS="-ldld  $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 115725 "configure"
-#include "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 shl_load();
-
-int main() {
-shl_load()
-; return 0; }
-EOF
-if { (eval echo configure:115739: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  lt_cv_dlopen="shl_load" lt_cv_dlopen_libs="-dld"
-else
-  echo "$ac_t""no" 1>&6
-echo $ac_n "checking for dlopen""... $ac_c" 1>&6
-echo "configure:115758: checking for dlopen" >&5
-if eval "test \"`echo '$''{'ac_cv_func_dlopen'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  cat > conftest.$ac_ext <<EOF
-#line 115763 "configure"
-#include "confdefs.h"
-/* System header to define __stub macros and hopefully few prototypes,
-    which can conflict with char dlopen(); below.  */
-#include <assert.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 dlopen();
-
-int main() {
-
-/* 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)
-choke me
-#else
-dlopen();
-#endif
-
-; return 0; }
-EOF
-if { (eval echo configure:115789: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_func_dlopen=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_func_dlopen=no"
-fi
-rm -f conftest*
-fi
-
-if eval "test \"`echo '$ac_cv_func_'dlopen`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  lt_cv_dlopen="dlopen"
-else
-  echo "$ac_t""no" 1>&6
-echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
-echo "configure:115807: checking for dlopen in -ldl" >&5
-ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  ac_save_LIBS="$LIBS"
-LIBS="-ldl  $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 115815 "configure"
-#include "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 dlopen();
-
-int main() {
-dlopen()
-; return 0; }
-EOF
-if { (eval echo configure:115829: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-ldl"
-else
-  echo "$ac_t""no" 1>&6
-echo $ac_n "checking for dlopen in -lsvld""... $ac_c" 1>&6
-echo "configure:115848: checking for dlopen in -lsvld" >&5
-ac_lib_var=`echo svld'_'dlopen | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  ac_save_LIBS="$LIBS"
-LIBS="-lsvld  $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 115856 "configure"
-#include "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 dlopen();
-
-int main() {
-dlopen()
-; return 0; }
-EOF
-if { (eval echo configure:115870: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  lt_cv_dlopen="dlopen" lt_cv_dlopen_libs="-lsvld"
-else
-  echo "$ac_t""no" 1>&6
-echo $ac_n "checking for dld_link in -ldld""... $ac_c" 1>&6
-echo "configure:115889: checking for dld_link in -ldld" >&5
-ac_lib_var=`echo dld'_'dld_link | sed 'y%./+-%__p_%'`
-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  ac_save_LIBS="$LIBS"
-LIBS="-ldld  $LIBS"
-cat > conftest.$ac_ext <<EOF
-#line 115897 "configure"
-#include "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 dld_link();
-
-int main() {
-dld_link()
-; return 0; }
-EOF
-if { (eval echo configure:115911: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=yes"
-else
-  echo "configure: failed program was:" >&5
-  cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  eval "ac_cv_lib_$ac_lib_var=no"
-fi
-rm -f conftest*
-LIBS="$ac_save_LIBS"
-
-fi
-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
-  echo "$ac_t""yes" 1>&6
-  lt_cv_dlopen="dld_link" lt_cv_dlopen_libs="-dld"
-else
-  echo "$ac_t""no" 1>&6
-fi
-
-	      
-fi
-
-	    
-fi
-
-	  
-fi
-
-	
-fi
-
-      
-fi
-
-    ;;
-  esac
-
-  if test "x$lt_cv_dlopen" != xno; then
-    enable_dlopen=yes
-  else
-    enable_dlopen=no
-  fi
-
-  case $lt_cv_dlopen in
-  dlopen)
-    save_CPPFLAGS="$CPPFLAGS"
-    test "x$ac_cv_header_dlfcn_h" = xyes && CPPFLAGS="$CPPFLAGS -DHAVE_DLFCN_H"
-
-    save_LDFLAGS="$LDFLAGS"
-    eval LDFLAGS=\"\$LDFLAGS $export_dynamic_flag_spec\"
-
-    save_LIBS="$LIBS"
-    LIBS="$lt_cv_dlopen_libs $LIBS"
-
-    echo $ac_n "checking whether a program can dlopen itself""... $ac_c" 1>&6
-echo "configure:115967: checking whether a program can dlopen itself" >&5
-if eval "test \"`echo '$''{'lt_cv_dlopen_self'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  	  if test "$cross_compiling" = yes; then :
-  lt_cv_dlopen_self=cross
-else
-  lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
-  lt_status=$lt_dlunknown
-  cat > conftest.$ac_ext <<EOF
-#line 115977 "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-#  define LT_DLGLOBAL		RTLD_GLOBAL
-#else
-#  ifdef DL_GLOBAL
-#    define LT_DLGLOBAL		DL_GLOBAL
-#  else
-#    define LT_DLGLOBAL		0
-#  endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
-   find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-#  ifdef RTLD_LAZY
-#    define LT_DLLAZY_OR_NOW		RTLD_LAZY
-#  else
-#    ifdef DL_LAZY
-#      define LT_DLLAZY_OR_NOW		DL_LAZY
-#    else
-#      ifdef RTLD_NOW
-#        define LT_DLLAZY_OR_NOW	RTLD_NOW
-#      else
-#        ifdef DL_NOW
-#          define LT_DLLAZY_OR_NOW	DL_NOW
-#        else
-#          define LT_DLLAZY_OR_NOW	0
-#        endif
-#      endif
-#    endif
-#  endif
-#endif
-
-#ifdef __cplusplus
-extern "C" void exit (int);
-#endif
-
-void fnord() { int i=42;}
-int main ()
-{
-  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-  int status = $lt_dlunknown;
-
-  if (self)
-    {
-      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
-      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
-      /* dlclose (self); */
-    }
-
-    exit (status);
-}
-EOF
-  if { (eval echo configure:116038: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} 2>/dev/null; then
-    (./conftest; exit; ) >&5 2>/dev/null
-    lt_status=$?
-    case x$lt_status in
-      x$lt_dlno_uscore) lt_cv_dlopen_self=yes ;;
-      x$lt_dlneed_uscore) lt_cv_dlopen_self=yes ;;
-      x$lt_unknown|x*) lt_cv_dlopen_self=no ;;
-    esac
-  else :
-    # compilation failed
-    lt_cv_dlopen_self=no
-  fi
-fi
-rm -fr conftest*
-
-    
-fi
-
-echo "$ac_t""$lt_cv_dlopen_self" 1>&6
-
-    if test "x$lt_cv_dlopen_self" = xyes; then
-      LDFLAGS="$LDFLAGS $link_static_flag"
-      echo $ac_n "checking whether a statically linked program can dlopen itself""... $ac_c" 1>&6
-echo "configure:116061: checking whether a statically linked program can dlopen itself" >&5
-if eval "test \"`echo '$''{'lt_cv_dlopen_self_static'+set}'`\" = set"; then
-  echo $ac_n "(cached) $ac_c" 1>&6
-else
-  	  if test "$cross_compiling" = yes; then :
-  lt_cv_dlopen_self_static=cross
-else
-  lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
-  lt_status=$lt_dlunknown
-  cat > conftest.$ac_ext <<EOF
-#line 116071 "configure"
-#include "confdefs.h"
-
-#if HAVE_DLFCN_H
-#include <dlfcn.h>
-#endif
-
-#include <stdio.h>
-
-#ifdef RTLD_GLOBAL
-#  define LT_DLGLOBAL		RTLD_GLOBAL
-#else
-#  ifdef DL_GLOBAL
-#    define LT_DLGLOBAL		DL_GLOBAL
-#  else
-#    define LT_DLGLOBAL		0
-#  endif
-#endif
-
-/* We may have to define LT_DLLAZY_OR_NOW in the command line if we
-   find out it does not work in some platform. */
-#ifndef LT_DLLAZY_OR_NOW
-#  ifdef RTLD_LAZY
-#    define LT_DLLAZY_OR_NOW		RTLD_LAZY
-#  else
-#    ifdef DL_LAZY
-#      define LT_DLLAZY_OR_NOW		DL_LAZY
-#    else
-#      ifdef RTLD_NOW
-#        define LT_DLLAZY_OR_NOW	RTLD_NOW
-#      else
-#        ifdef DL_NOW
-#          define LT_DLLAZY_OR_NOW	DL_NOW
-#        else
-#          define LT_DLLAZY_OR_NOW	0
-#        endif
-#      endif
-#    endif
-#  endif
-#endif
-
-#ifdef __cplusplus
-extern "C" void exit (int);
-#endif
-
-void fnord() { int i=42;}
-int main ()
-{
-  void *self = dlopen (0, LT_DLGLOBAL|LT_DLLAZY_OR_NOW);
-  int status = $lt_dlunknown;
-
-  if (self)
-    {
-      if (dlsym (self,"fnord"))       status = $lt_dlno_uscore;
-      else if (dlsym( self,"_fnord")) status = $lt_dlneed_uscore;
-      /* dlclose (self); */
-    }
-
-    exit (status);
-}
-EOF
-  if { (eval echo configure:116132: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} 2>/dev/null; then
-    (./conftest; exit; ) >&5 2>/dev/null
-    lt_status=$?
-    case x$lt_status in
-      x$lt_dlno_uscore) lt_cv_dlopen_self_static=yes ;;
-      x$lt_dlneed_uscore) lt_cv_dlopen_self_static=yes ;;
-      x$lt_unknown|x*) lt_cv_dlopen_self_static=no ;;
-    esac
-  else :
-    # compilation failed
-    lt_cv_dlopen_self_static=no
-  fi
-fi
-rm -fr conftest*
-
-      
-fi
-
-echo "$ac_t""$lt_cv_dlopen_self_static" 1>&6
-    fi
-
-    CPPFLAGS="$save_CPPFLAGS"
-    LDFLAGS="$save_LDFLAGS"
-    LIBS="$save_LIBS"
-    ;;
-  esac
-
-  case $lt_cv_dlopen_self in
-  yes|no) enable_dlopen_self=$lt_cv_dlopen_self ;;
-  *) enable_dlopen_self=unknown ;;
-  esac
-
-  case $lt_cv_dlopen_self_static in
-  yes|no) enable_dlopen_self_static=$lt_cv_dlopen_self_static ;;
-  *) enable_dlopen_self_static=unknown ;;
-  esac
-fi
-
 
 # The else clause should only fire when bootstrapping the
 # libtool distribution, otherwise you forgot to ship ltmain.sh
@@ -116180,7 +116179,7 @@ if test -f "$ltmain"; then
   # Now quote all the things that may contain metacharacters while being
   # careful not to overquote the AC_SUBSTed values.  We take copies of the
   # variables and quote the copies for generation of the libtool script.
-  for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC NM \
+  for var in echo old_CC old_CFLAGS AR AR_FLAGS EGREP RANLIB LN_S LTCC LTCFLAGS NM \
     SED SHELL STRIP \
     libname_spec library_names_spec soname_spec extract_expsyms_cmds \
     old_striplib striplib file_magic_cmd finish_cmds finish_eval \
@@ -116207,6 +116206,7 @@ if test -f "$ltmain"; then
     predeps_CXX \
     postdeps_CXX \
     compiler_lib_search_path_CXX \
+    compiler_lib_search_dirs_CXX \
     archive_cmds_CXX \
     archive_expsym_cmds_CXX \
     postinstall_cmds_CXX \
@@ -116222,6 +116222,7 @@ if test -f "$ltmain"; then
     module_cmds_CXX \
     module_expsym_cmds_CXX \
     lt_cv_prog_compiler_c_o_CXX \
+    fix_srcfile_path_CXX \
     exclude_expsyms_CXX \
     include_expsyms_CXX; do
 
@@ -116298,6 +116299,9 @@ AR_FLAGS=$lt_AR_FLAGS
 # A C compiler.
 LTCC=$lt_LTCC
 
+# LTCC compiler flags.
+LTCFLAGS=$lt_LTCFLAGS
+
 # A language-specific compiler.
 CC=$lt_compiler_CXX
 
@@ -116451,6 +116455,10 @@ predeps=$lt_predeps_CXX
 # shared library.
 postdeps=$lt_postdeps_CXX
 
+# The directories searched by this compiler when creating a shared
+# library
+compiler_lib_search_dirs=$lt_compiler_lib_search_dirs_CXX
+
 # The library search path used internally by the compiler when linking
 # a shared library.
 compiler_lib_search_path=$lt_compiler_lib_search_path_CXX
@@ -116539,7 +116547,7 @@ sys_lib_search_path_spec=$lt_sys_lib_search_path_spec
 sys_lib_dlsearch_path_spec=$lt_sys_lib_dlsearch_path_spec
 
 # Fix the shell variable \$srcfile for the compiler.
-fix_srcfile_path="$fix_srcfile_path_CXX"
+fix_srcfile_path=$lt_fix_srcfile_path
 
 # Set to yes if exported symbols are required.
 always_export_symbols=$always_export_symbols_CXX
@@ -116595,26 +116603,6 @@ lt_cv_prog_gnu_ld=$lt_save_with_gnu_ld
 	fi
 	;;
 
-#      F77)
-#	if test -n "$F77" && test "X$F77" != "Xno"; then
-#	  AC_LIBTOOL_LANG_F77_CONFIG
-#	else
-#	  tagname=""
-#	fi
-#	;;
-#
-#      GCJ)
-#	if test -n "$GCJ" && test "X$GCJ" != "Xno"; then
-#	  AC_LIBTOOL_LANG_GCJ_CONFIG
-#	else
-#	  tagname=""
-#	fi
-#	;;
-#
-#      RC)
-#	AC_LIBTOOL_LANG_RC_CONFIG
-#	;;
-
       *)
 	{ echo "configure: error: Unsupported tag name: $tagname" 1>&2; exit 1; }
 	;;
@@ -116658,8 +116646,6 @@ LIBTOOL='$(SHELL) $(top_builddir)/libtool'
 
 
 
-
-
 if test "$enable_debug" != "yes"; then
   
   if test -z "$LIBTOOL"; then
@@ -116684,14 +116670,6 @@ SHARED_LIBTOOL='$(LIBTOOL)'
 
 CC=$old_CC
 
-if test "$php_did_darwin9_cheat" -eq 1; then
-  if test "$PHP_DEBUG" = "1"; then
-    CFLAGS=`echo "$CFLAGS" | $SED -e 's/-gstabs/-g/g'`
-  else
-    CFLAGS=`echo "-O2 $CFLAGS" | $SED -e 's/-gstabs//g'`
-  fi
-fi
-
 
   echo "$ac_t""" 1>&6
   echo "$ac_t""${T_MD}Generating files${T_ME}" 1>&6
@@ -117445,6 +117423,7 @@ s%@INCLUDE_PATH@%$INCLUDE_PATH%g
 s%@EXPANDED_PEAR_INSTALLDIR@%$EXPANDED_PEAR_INSTALLDIR%g
 s%@EXPANDED_EXTENSION_DIR@%$EXPANDED_EXTENSION_DIR%g
 s%@EXPANDED_BINDIR@%$EXPANDED_BINDIR%g
+s%@EXPANDED_SBINDIR@%$EXPANDED_SBINDIR%g
 s%@EXPANDED_LIBDIR@%$EXPANDED_LIBDIR%g
 s%@EXPANDED_DATADIR@%$EXPANDED_DATADIR%g
 s%@EXPANDED_SYSCONFDIR@%$EXPANDED_SYSCONFDIR%g
@@ -117483,6 +117462,8 @@ s%@EXEEXT@%$EXEEXT%g
 s%@ECHO@%$ECHO%g
 s%@AR@%$AR%g
 s%@STRIP@%$STRIP%g
+s%@DSYMUTIL@%$DSYMUTIL%g
+s%@NMEDIT@%$NMEDIT%g
 s%@LIBTOOL@%$LIBTOOL%g
 
 CEOF
diff --git a/configure.in b/configure.in
index 74f3446..528798a 100644
--- a/configure.in
+++ b/configure.in
@@ -1,4 +1,4 @@
-## $Id: configure.in 288372 2009-09-16 12:54:51Z iliaa $ -*- autoconf -*-
+## $Id: configure.in 292200 2009-12-16 12:45:18Z iliaa $ -*- autoconf -*-
 dnl ## Process this file with autoconf to produce a configure script.
 
 divert(1)
@@ -41,7 +41,7 @@ AC_CONFIG_HEADER(main/php_config.h)
 
 PHP_MAJOR_VERSION=5
 PHP_MINOR_VERSION=2
-PHP_RELEASE_VERSION=11
+PHP_RELEASE_VERSION=12
 PHP_EXTRA_VERSION=""
 PHP_VERSION="$PHP_MAJOR_VERSION.$PHP_MINOR_VERSION.$PHP_RELEASE_VERSION$PHP_EXTRA_VERSION"
 PHP_VERSION_ID=`expr [$]PHP_MAJOR_VERSION \* 10000 + [$]PHP_MINOR_VERSION \* 100 + [$]PHP_RELEASE_VERSION`
@@ -122,21 +122,6 @@ dnl or the contents of libs.
 $php_shtool mkdir -p libs
 rm -f libs/*
 
-dnl Darwin 9 hack
-dnl Because the default debugging format used by Apple's GCC on Mac OS 10.5
-dnl causes errors in all current and past versions of Autoconf, we do a little
-dnl messing with the CFLAGS here to trick it.
-php_did_darwin9_cheat=0
-case $host_alias in
-*darwin9*)
-  hasg=`echo $CFLAGS | grep -E '(^-g)|([[:space:]]-g)'`
-  if test x"$hasg" = "x"; then
-    php_did_darwin9_cheat=1
-    CFLAGS="$CFLAGS -gstabs"
-  fi
-  ;;
-esac
-
 dnl Checks for programs.
 dnl -------------------------------------------------------------------------
 
@@ -192,6 +177,7 @@ case $host_cpu in
     if test "$SUNCC" = "yes"; then
       CFLAGS="$CFLAGS -xmemalign=8s"
     fi
+    ;;
 esac
 
 case $host_alias in
@@ -211,7 +197,14 @@ case $host_alias in
         CPPFLAGS="$CPPFLAGS -no-cpp-precomp"
       fi
     fi
-    AC_DEFINE(BIND_8_COMPAT, 1, [Enabling BIND8 compatibility for Panther])
+
+    macosx_major=`sw_vers -productVersion | cut -d . -f 1`
+    macosx_minor=`sw_vers -productVersion | cut -d . -f 2`
+
+    if test "$macosx_major" -ge "10" && test "$macosx_minor" -lt "6" ; then
+      AC_DEFINE(BIND_8_COMPAT, 1, [Enabling BIND8 compatibility for Panther])
+    fi
+
     php_multiple_shlib_versions_ok=yes
     ;;
   *beos*)
@@ -366,7 +359,6 @@ dnl in -lc, -lbind and -lresolv
 PHP_CHECK_FUNC(inet_aton, resolv, bind)
 PHP_CHECK_FUNC(dn_skipname, resolv, bind)
 
-
 dnl Then headers.
 dnl -------------------------------------------------------------------------
 
@@ -386,6 +378,7 @@ sys/time.h \
 netinet/in.h \
 alloca.h \
 arpa/inet.h \
+arpa/nameser_compat.h \
 arpa/nameser.h \
 assert.h \
 crypt.h \
@@ -594,11 +587,13 @@ tzset \
 unlockpt \
 unsetenv \
 usleep \
-nanosleep \
 utime \
 vsnprintf \
 )
 
+dnl Some systems (like OpenSolaris) do not have nanosleep in libc
+AC_CACHE_CHECK([for nanosleep], ac_cv_func_nanosleep, [PHP_CHECK_FUNC_LIB(nanosleep, rt)])
+
 dnl Check for getaddrinfo, should be a better way, but...
 dnl Also check for working getaddrinfo
 AC_CACHE_CHECK([for getaddrinfo], ac_cv_func_getaddrinfo,
@@ -736,15 +731,6 @@ if test "$PHP_GCOV" = "yes"; then
   dnl Add the special gcc flags
   CFLAGS="$CFLAGS -O0 -fprofile-arcs -ftest-coverage"
   CXXFLAGS="$CXXFLAGS -O0 -fprofile-arcs -ftest-coverage"
-  if test "$SUNCC" = "yes"; then
-    if test -n "$auto_cflags"; then
-      CFLAGS="-g"
-      CXXFLAGS="-g"
-    else
-      CFLAGS="$CFLAGS -g"
-      CXXFLAGS="$CFLAGS -g"
-    fi
-  fi
 fi
 
 PHP_ARG_ENABLE(debug, whether to include debugging symbols,
@@ -759,8 +745,17 @@ if test "$PHP_DEBUG" = "yes"; then
   changequote([,])
   dnl add -O0 only if GCC or ICC is used
   if test "$GCC" = "yes" || test "$ICC" = "yes"; then
-    CFLAGS="$CFLAGS -O0"
-    CXXFLAGS="$CXXFLAGS -O0"
+    CFLAGS="$CFLAGS -g -O0"
+    CXXFLAGS="$CXXFLAGS -g -O0"
+  fi
+  if test "$SUNCC" = "yes"; then
+    if test -n "$auto_cflags"; then
+      CFLAGS="-g"
+      CXXFLAGS="-g"
+    else
+      CFLAGS="$CFLAGS -g"
+      CXXFLAGS="$CFLAGS -g"
+    fi
   fi
 else
   PHP_DEBUG=0
@@ -965,6 +960,7 @@ case $php_build_target in
 esac
 
 EXTRA_LIBS="$EXTRA_LIBS $DLIBS $LIBS"
+EXTRA_LDFLAGS="$EXTRA_LDFLAGS $LDFLAGS"
 
 dnl this has to be here to prevent the openssl crypt() from
 dnl overriding the system provided crypt().
@@ -1145,6 +1141,7 @@ EXPANDED_PEAR_INSTALLDIR=`eval echo $PEAR_INSTALLDIR`
 EXPANDED_EXTENSION_DIR=`eval echo $EXTENSION_DIR`
 EXPANDED_LOCALSTATEDIR=`eval echo $localstatedir`
 EXPANDED_BINDIR=`eval echo $bindir`
+EXPANDED_SBINDIR=`eval echo $sbindir`
 EXPANDED_LIBDIR=$libdir
 EXPANDED_SYSCONFDIR=`eval echo $sysconfdir`
 EXPANDED_DATADIR=$datadir
@@ -1160,6 +1157,7 @@ AC_SUBST(INCLUDE_PATH)
 AC_SUBST(EXPANDED_PEAR_INSTALLDIR)
 AC_SUBST(EXPANDED_EXTENSION_DIR)
 AC_SUBST(EXPANDED_BINDIR)
+AC_SUBST(EXPANDED_SBINDIR)
 AC_SUBST(EXPANDED_LIBDIR)
 AC_SUBST(EXPANDED_DATADIR)
 AC_SUBST(EXPANDED_SYSCONFDIR)
@@ -1204,12 +1202,14 @@ if test "$PHP_CLI" != "no"; then
   PHP_INSTALL_CLI_TARGET="install-cli"
   PHP_ADD_SOURCES(sapi/cli, php_cli.c php_cli_readline.c getopt.c,, cli)
   PHP_INSTALLED_SAPIS="cli $PHP_SAPI"
+  PHP_EXECUTABLE="\$(top_builddir)/\$(SAPI_CLI_PATH)"
 else
   PHP_INSTALLED_SAPIS="$PHP_SAPI"
 fi
 
 PHP_SUBST_OLD(PHP_INSTALLED_SAPIS)
 
+PHP_SUBST(PHP_EXECUTABLE)
 PHP_SUBST(PHP_CLI_TARGET)
 PHP_SUBST(PHP_SAPI_OBJS)
 PHP_SUBST(PHP_CLI_OBJS)
@@ -1226,6 +1226,7 @@ PHP_SUBST_OLD(php_abs_top_builddir)
 PHP_SUBST_OLD(php_abs_top_srcdir)
 
 PHP_SUBST(bindir)
+PHP_SUBST(sbindir)
 PHP_SUBST(exec_prefix)
 PHP_SUBST_OLD(program_prefix)
 PHP_SUBST_OLD(program_suffix)
@@ -1318,6 +1319,14 @@ PHP_CONFIGURE_PART(Configuring libtool)
 
 LDFLAGS="$LDFLAGS $PHP_AIX_LDFLAGS"
 
+dnl Autoconf 2.13's libtool checks go slightly nuts on Mac OS X 10.5 and 10.6.
+dnl This hack works around it. Ugly.
+case $host_alias in
+*darwin9*|*darwin10*)
+	ac_cv_exeext=
+	;;
+esac
+
 dnl Only allow AC_PROG_CXX and AC_PROG_CXXCPP if they are explicitly called (by PHP_REQUIRE_CXX).
 dnl Otherwise AC_PROG_LIBTOOL fails if there is no working C++ compiler.
 AC_PROVIDE_IFELSE([PHP_REQUIRE_CXX], [], [
@@ -1341,15 +1350,6 @@ SHARED_LIBTOOL='$(LIBTOOL)'
 
 CC=$old_CC
 
-dnl Finish the Darwin hack
-if test "$php_did_darwin9_cheat" -eq 1; then
-  if test "$PHP_DEBUG" = "1"; then
-    CFLAGS=`echo "$CFLAGS" | $SED -e 's/-gstabs/-g/g'`
-  else
-    CFLAGS=`echo "-O2 $CFLAGS" | $SED -e 's/-gstabs//g'`
-  fi
-fi
-
 PHP_CONFIGURE_PART(Generating files)
 
 CXXFLAGS_CLEAN=$CXXFLAGS
diff --git a/ext/com_dotnet/com_typeinfo.c b/ext/com_dotnet/com_typeinfo.c
index 41b54dc..a26175d 100644
--- a/ext/com_dotnet/com_typeinfo.c
+++ b/ext/com_dotnet/com_typeinfo.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: com_typeinfo.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: com_typeinfo.c 289996 2009-10-27 19:16:55Z pajoye $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -309,7 +309,7 @@ ITypeInfo *php_com_locate_typeinfo(char *typelibname, php_com_dotnet_object *obj
 		}
 	} else if (typelibname) {
 		/* Fetch the typelibrary and use that to look things up */
-		typelib = php_com_load_typelib(typelibname, obj->code_page TSRMLS_CC);
+		typelib = php_com_load_typelib(typelibname, CP_THREAD_ACP TSRMLS_CC);
 	} 
 
 	if (!gotguid && dispname && typelib) {
diff --git a/ext/curl/interface.c b/ext/curl/interface.c
index 625a142..8263fc4 100644
--- a/ext/curl/interface.c
+++ b/ext/curl/interface.c
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: interface.c 287784 2009-08-26 22:24:10Z pajoye $ */
+/* $Id: interface.c 289934 2009-10-26 12:57:01Z iliaa $ */
 
 #define ZEND_INCLUDE_FULL_WINDOWS_HEADERS
 
@@ -1228,10 +1228,22 @@ PHP_FUNCTION(curl_copy_handle)
 
 	dupch->cp = cp;
 	dupch->uses = 0;
+	if (ch->handlers->write->stream) {
+		zval_add_ref(dupch->handlers->write->stream);
+		dupch->handlers->write->stream = ch->handlers->write->stream;
+	}
 	dupch->handlers->write->method = ch->handlers->write->method;
 	dupch->handlers->write->type   = ch->handlers->write->type;
+	if (ch->handlers->read->stream) {
+		zval_add_ref(ch->handlers->read->stream);
+	}
+	dupch->handlers->read->stream  = ch->handlers->read->stream;
 	dupch->handlers->read->method  = ch->handlers->read->method;
 	dupch->handlers->write_header->method = ch->handlers->write_header->method;
+	if (ch->handlers->write_header->stream) {
+		zval_add_ref(ch->handlers->write_header->stream);
+	}
+	dupch->handlers->write_header->stream = ch->handlers->write_header->stream;
 
 	dupch->handlers->write->fp = ch->handlers->write->fp;
 	dupch->handlers->write_header->fp = ch->handlers->write_header->fp;
@@ -1361,7 +1373,8 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu
 #endif
 			convert_to_long_ex(zvalue);
 #if LIBCURL_VERSION_NUM >= 0x71304
-			if (((PG(open_basedir) && *PG(open_basedir)) || PG(safe_mode)) && (Z_LVAL_PP(zvalue) & CURLPROTO_FILE)) {
+			if ((option == CURLOPT_PROTOCOLS || option == CURLOPT_REDIR_PROTOCOLS) &&
+				((PG(open_basedir) && *PG(open_basedir)) || PG(safe_mode)) && (Z_LVAL_PP(zvalue) & CURLPROTO_FILE)) {
 					php_error_docref(NULL TSRMLS_CC, E_WARNING, "CURLPROTO_FILE cannot be activated when in safe_mode or an open_basedir is set");
 					RETVAL_FALSE;
 					return 1;
@@ -1456,9 +1469,10 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu
 			switch (option) {
 				case CURLOPT_FILE:
 					if (((php_stream *) what)->mode[0] != 'r' || ((php_stream *) what)->mode[1] == '+') {
-						zend_list_addref(Z_LVAL_PP(zvalue));
+						zval_add_ref(zvalue);
 						ch->handlers->write->fp = fp;
 						ch->handlers->write->method = PHP_CURL_FILE;
+						ch->handlers->write->stream = *zvalue;
 					} else {
 						php_error_docref(NULL TSRMLS_CC, E_WARNING, "the provided file handle is not writable");
 						RETVAL_FALSE;
@@ -1467,9 +1481,10 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu
 					break;
 				case CURLOPT_WRITEHEADER:
 					if (((php_stream *) what)->mode[0] != 'r' || ((php_stream *) what)->mode[1] == '+') {
-						zend_list_addref(Z_LVAL_PP(zvalue));
+						zval_add_ref(zvalue);
 						ch->handlers->write_header->fp = fp;
 						ch->handlers->write_header->method = PHP_CURL_FILE;
+						ch->handlers->write_header->stream = *zvalue;
 					} else {
 						php_error_docref(NULL TSRMLS_CC, E_WARNING, "the provided file handle is not writable");
 						RETVAL_FALSE;
@@ -1477,9 +1492,10 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu
 					}
 					break;
 				case CURLOPT_INFILE:
-					zend_list_addref(Z_LVAL_PP(zvalue));
+					zval_add_ref(zvalue);
 					ch->handlers->read->fp = fp;
 					ch->handlers->read->fd = Z_LVAL_PP(zvalue);
+					ch->handlers->read->stream = *zvalue;
 					break;
 				case CURLOPT_STDERR:
 					if (((php_stream *) what)->mode[0] != 'r' || ((php_stream *) what)->mode[1] == '+') {
@@ -1609,7 +1625,7 @@ static int _php_curl_setopt(php_curl *ch, long option, zval **zvalue, zval *retu
 						error = curl_formadd(&first, &last,
 										CURLFORM_COPYNAME, string_key,
 										CURLFORM_NAMELENGTH, (long)string_key_len - 1,
-										CURLFORM_FILENAME, filename ? filename : postval,
+										CURLFORM_FILENAME, filename ? filename + sizeof(";filename=") - 1 : postval,
 										CURLFORM_CONTENTTYPE, type ? type + sizeof(";type=") - 1 : "application/octet-stream",
 										CURLFORM_FILE, postval,
 										CURLFORM_END);
@@ -2128,6 +2144,16 @@ static void _php_curl_close_ex(php_curl *ch TSRMLS_DC)
 		efree(ch->header.str);
 	}
 
+	if (ch->handlers->write_header->stream) {
+		zval_ptr_dtor(&ch->handlers->write_header->stream);
+	}
+	if (ch->handlers->write->stream) {
+		zval_ptr_dtor(&ch->handlers->write->stream);
+	}
+	if (ch->handlers->read->stream) {
+		zval_ptr_dtor(&ch->handlers->read->stream);
+	}
+
 	efree(ch->handlers->write);
 	efree(ch->handlers->write_header);
 	efree(ch->handlers->read);
diff --git a/ext/curl/php_curl.h b/ext/curl/php_curl.h
index 56e3ad8..07d9dfa 100644
--- a/ext/curl/php_curl.h
+++ b/ext/curl/php_curl.h
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: php_curl.h 284557 2009-07-21 20:32:32Z srinatar $ */
+/* $Id: php_curl.h 288973 2009-09-30 02:34:17Z iliaa $ */
 
 #ifndef _PHP_CURL_H
 #define _PHP_CURL_H
@@ -86,6 +86,7 @@ typedef struct {
 	smart_str       buf;
 	int             method;
 	int             type;
+	zval		*stream;
 } php_curl_write;
 
 typedef struct {
@@ -94,6 +95,7 @@ typedef struct {
 	FILE            *fp;
 	long            fd;
 	int             method;
+	zval		*stream;
 } php_curl_read;
 
 typedef struct {
diff --git a/ext/date/config0.m4 b/ext/date/config0.m4
index 884c157..b6034f6 100644
--- a/ext/date/config0.m4
+++ b/ext/date/config0.m4
@@ -1,4 +1,4 @@
-dnl $Id: config0.m4 280533 2009-05-14 18:34:27Z jani $
+dnl $Id: config0.m4 291371 2009-11-28 00:38:05Z jani $
 dnl config.m4 for date extension
 
 sinclude(ext/date/lib/timelib.m4)
@@ -16,6 +16,8 @@ PHP_ADD_INCLUDE([$ext_srcdir/lib])
 
 PHP_INSTALL_HEADERS([ext/date], [php_date.h lib/timelib.h lib/timelib_structs.h lib/timelib_config.h])
 
+AC_CHECK_FUNCS([llabs])
+
 cat > $ext_builddir/lib/timelib_config.h <<EOF
 #ifdef PHP_WIN32
 # include "config.w32.h"
diff --git a/ext/date/lib/timezonedb.h b/ext/date/lib/timezonedb.h
index 9732cba..f087526 100644
--- a/ext/date/lib/timezonedb.h
+++ b/ext/date/lib/timezonedb.h
@@ -1,4 +1,4 @@
-const timelib_tzdb_index_entry timezonedb_idx_builtin[560] = {
+const timelib_tzdb_index_entry timezonedb_idx_builtin[561] = {
 	{ "Africa/Abidjan"                    , 0x000000 },
 	{ "Africa/Accra"                      , 0x000055 },
 	{ "Africa/Addis_Ababa"                , 0x0000FD },
@@ -58,510 +58,511 @@ const timelib_tzdb_index_entry timezonedb_idx_builtin[560] = {
 	{ "America/Antigua"                   , 0x002837 },
 	{ "America/Araguaina"                 , 0x00289D },
 	{ "America/Argentina/Buenos_Aires"    , 0x0029F8 },
-	{ "America/Argentina/Catamarca"       , 0x002CC3 },
-	{ "America/Argentina/ComodRivadavia"  , 0x002E84 },
-	{ "America/Argentina/Cordoba"         , 0x00302A },
-	{ "America/Argentina/Jujuy"           , 0x00331C },
-	{ "America/Argentina/La_Rioja"        , 0x0034D0 },
-	{ "America/Argentina/Mendoza"         , 0x003688 },
-	{ "America/Argentina/Rio_Gallegos"    , 0x003848 },
-	{ "America/Argentina/Salta"           , 0x0039FD },
-	{ "America/Argentina/San_Juan"        , 0x003BA9 },
-	{ "America/Argentina/San_Luis"        , 0x003D61 },
-	{ "America/Argentina/Tucuman"         , 0x004035 },
-	{ "America/Argentina/Ushuaia"         , 0x00430E },
-	{ "America/Aruba"                     , 0x0044C9 },
-	{ "America/Asuncion"                  , 0x00452F },
-	{ "America/Atikokan"                  , 0x004814 },
-	{ "America/Atka"                      , 0x0048EA },
-	{ "America/Bahia"                     , 0x004C50 },
-	{ "America/Barbados"                  , 0x004DD9 },
-	{ "America/Belem"                     , 0x004E73 },
-	{ "America/Belize"                    , 0x004F6E },
-	{ "America/Blanc-Sablon"              , 0x0050EA },
-	{ "America/Boa_Vista"                 , 0x00519E },
-	{ "America/Bogota"                    , 0x0052A7 },
-	{ "America/Boise"                     , 0x005313 },
-	{ "America/Buenos_Aires"              , 0x0056AA },
-	{ "America/Cambridge_Bay"             , 0x005960 },
-	{ "America/Campo_Grande"              , 0x005C88 },
-	{ "America/Cancun"                    , 0x005F77 },
-	{ "America/Caracas"                   , 0x0061B9 },
-	{ "America/Catamarca"                 , 0x006220 },
-	{ "America/Cayenne"                   , 0x0063C6 },
-	{ "America/Cayman"                    , 0x006428 },
-	{ "America/Chicago"                   , 0x00647D },
-	{ "America/Chihuahua"                 , 0x006994 },
-	{ "America/Coral_Harbour"             , 0x006BE3 },
-	{ "America/Cordoba"                   , 0x006C75 },
-	{ "America/Costa_Rica"                , 0x006F38 },
-	{ "America/Cuiaba"                    , 0x006FC2 },
-	{ "America/Curacao"                   , 0x0072A0 },
-	{ "America/Danmarkshavn"              , 0x007306 },
-	{ "America/Dawson"                    , 0x00744A },
-	{ "America/Dawson_Creek"              , 0x007767 },
-	{ "America/Denver"                    , 0x007941 },
-	{ "America/Detroit"                   , 0x007CC7 },
-	{ "America/Dominica"                  , 0x008026 },
-	{ "America/Edmonton"                  , 0x00807B },
-	{ "America/Eirunepe"                  , 0x008433 },
-	{ "America/El_Salvador"               , 0x008546 },
-	{ "America/Ensenada"                  , 0x0085BB },
-	{ "America/Fort_Wayne"                , 0x008A62 },
-	{ "America/Fortaleza"                 , 0x008924 },
-	{ "America/Glace_Bay"                 , 0x008CCC },
-	{ "America/Godthab"                   , 0x009043 },
-	{ "America/Goose_Bay"                 , 0x009307 },
-	{ "America/Grand_Turk"                , 0x0097C4 },
-	{ "America/Grenada"                   , 0x009A73 },
-	{ "America/Guadeloupe"                , 0x009AC8 },
-	{ "America/Guatemala"                 , 0x009B1D },
-	{ "America/Guayaquil"                 , 0x009BA6 },
-	{ "America/Guyana"                    , 0x009C03 },
-	{ "America/Halifax"                   , 0x009C84 },
-	{ "America/Havana"                    , 0x00A19A },
-	{ "America/Hermosillo"                , 0x00A50D },
-	{ "America/Indiana/Indianapolis"      , 0x00A5EB },
-	{ "America/Indiana/Knox"              , 0x00A87C },
-	{ "America/Indiana/Marengo"           , 0x00AC13 },
-	{ "America/Indiana/Petersburg"        , 0x00AEB9 },
-	{ "America/Indiana/Tell_City"         , 0x00B406 },
-	{ "America/Indiana/Vevay"             , 0x00B69F },
-	{ "America/Indiana/Vincennes"         , 0x00B8DA },
-	{ "America/Indiana/Winamac"           , 0x00BB8E },
-	{ "America/Indianapolis"              , 0x00B19C },
-	{ "America/Inuvik"                    , 0x00BE47 },
-	{ "America/Iqaluit"                   , 0x00C13E },
-	{ "America/Jamaica"                   , 0x00C460 },
-	{ "America/Jujuy"                     , 0x00C525 },
-	{ "America/Juneau"                    , 0x00C6CF },
-	{ "America/Kentucky/Louisville"       , 0x00CA4D },
-	{ "America/Kentucky/Monticello"       , 0x00CE6B },
-	{ "America/Knox_IN"                   , 0x00D1F0 },
-	{ "America/La_Paz"                    , 0x00D561 },
-	{ "America/Lima"                      , 0x00D5C8 },
-	{ "America/Los_Angeles"               , 0x00D670 },
-	{ "America/Louisville"                , 0x00DA81 },
-	{ "America/Maceio"                    , 0x00DE76 },
-	{ "America/Managua"                   , 0x00DFB0 },
-	{ "America/Manaus"                    , 0x00E063 },
-	{ "America/Marigot"                   , 0x00E165 },
-	{ "America/Martinique"                , 0x00E1BA },
-	{ "America/Mazatlan"                  , 0x00E226 },
-	{ "America/Mendoza"                   , 0x00E493 },
-	{ "America/Menominee"                 , 0x00E647 },
-	{ "America/Merida"                    , 0x00E9C8 },
-	{ "America/Mexico_City"               , 0x00EC03 },
-	{ "America/Miquelon"                  , 0x00EE7E },
-	{ "America/Moncton"                   , 0x00F0F0 },
-	{ "America/Monterrey"                 , 0x00F587 },
-	{ "America/Montevideo"                , 0x00F7CE },
-	{ "America/Montreal"                  , 0x00FAE0 },
-	{ "America/Montserrat"                , 0x00FFF6 },
-	{ "America/Nassau"                    , 0x01004B },
-	{ "America/New_York"                  , 0x010390 },
-	{ "America/Nipigon"                   , 0x01089B },
-	{ "America/Nome"                      , 0x010BEC },
-	{ "America/Noronha"                   , 0x010F6A },
-	{ "America/North_Dakota/Center"       , 0x01109A },
-	{ "America/North_Dakota/New_Salem"    , 0x01142E },
-	{ "America/Panama"                    , 0x0117D7 },
-	{ "America/Pangnirtung"               , 0x01182C },
-	{ "America/Paramaribo"                , 0x011B62 },
-	{ "America/Phoenix"                   , 0x011BF4 },
-	{ "America/Port-au-Prince"            , 0x011CA2 },
-	{ "America/Port_of_Spain"             , 0x011EBD },
-	{ "America/Porto_Acre"                , 0x011DBE },
-	{ "America/Porto_Velho"               , 0x011F12 },
-	{ "America/Puerto_Rico"               , 0x012008 },
-	{ "America/Rainy_River"               , 0x012073 },
-	{ "America/Rankin_Inlet"              , 0x0123AB },
-	{ "America/Recife"                    , 0x012691 },
-	{ "America/Regina"                    , 0x0127BB },
-	{ "America/Resolute"                  , 0x012979 },
-	{ "America/Rio_Branco"                , 0x012C72 },
-	{ "America/Rosario"                   , 0x012D75 },
-	{ "America/Santarem"                  , 0x013038 },
-	{ "America/Santiago"                  , 0x01313D },
-	{ "America/Santo_Domingo"             , 0x0134E6 },
-	{ "America/Sao_Paulo"                 , 0x0135AC },
-	{ "America/Scoresbysund"              , 0x0138BB },
-	{ "America/Shiprock"                  , 0x013BA9 },
-	{ "America/St_Barthelemy"             , 0x013F38 },
-	{ "America/St_Johns"                  , 0x013F8D },
-	{ "America/St_Kitts"                  , 0x0144E0 },
-	{ "America/St_Lucia"                  , 0x014535 },
-	{ "America/St_Thomas"                 , 0x01458A },
-	{ "America/St_Vincent"                , 0x0145DF },
-	{ "America/Swift_Current"             , 0x014634 },
-	{ "America/Tegucigalpa"               , 0x014755 },
-	{ "America/Thule"                     , 0x0147D4 },
-	{ "America/Thunder_Bay"               , 0x014A1B },
-	{ "America/Tijuana"                   , 0x014D64 },
-	{ "America/Toronto"                   , 0x0150D9 },
-	{ "America/Tortola"                   , 0x0155F0 },
-	{ "America/Vancouver"                 , 0x015645 },
-	{ "America/Virgin"                    , 0x015A82 },
-	{ "America/Whitehorse"                , 0x015AD7 },
-	{ "America/Winnipeg"                  , 0x015DF4 },
-	{ "America/Yakutat"                   , 0x016234 },
-	{ "America/Yellowknife"               , 0x01659F },
-	{ "Antarctica/Casey"                  , 0x0168AF },
-	{ "Antarctica/Davis"                  , 0x016923 },
-	{ "Antarctica/DumontDUrville"         , 0x0169A0 },
-	{ "Antarctica/Mawson"                 , 0x016A32 },
-	{ "Antarctica/McMurdo"                , 0x016AA1 },
-	{ "Antarctica/Palmer"                 , 0x016DA3 },
-	{ "Antarctica/Rothera"                , 0x0170BF },
-	{ "Antarctica/South_Pole"             , 0x017135 },
-	{ "Antarctica/Syowa"                  , 0x01743D },
-	{ "Antarctica/Vostok"                 , 0x0174AB },
-	{ "Arctic/Longyearbyen"               , 0x017520 },
-	{ "Asia/Aden"                         , 0x017852 },
-	{ "Asia/Almaty"                       , 0x0178A7 },
-	{ "Asia/Amman"                        , 0x017A26 },
-	{ "Asia/Anadyr"                       , 0x017CE6 },
-	{ "Asia/Aqtau"                        , 0x017FD4 },
-	{ "Asia/Aqtobe"                       , 0x0181D3 },
-	{ "Asia/Ashgabat"                     , 0x01838B },
-	{ "Asia/Ashkhabad"                    , 0x0184A8 },
-	{ "Asia/Baghdad"                      , 0x0185C5 },
-	{ "Asia/Bahrain"                      , 0x01873A },
-	{ "Asia/Baku"                         , 0x0187A0 },
-	{ "Asia/Bangkok"                      , 0x018A88 },
-	{ "Asia/Beirut"                       , 0x018ADD },
-	{ "Asia/Bishkek"                      , 0x018DEA },
-	{ "Asia/Brunei"                       , 0x018F96 },
-	{ "Asia/Calcutta"                     , 0x018FF8 },
-	{ "Asia/Choibalsan"                   , 0x019071 },
-	{ "Asia/Chongqing"                    , 0x0191EA },
-	{ "Asia/Chungking"                    , 0x0192D9 },
-	{ "Asia/Colombo"                      , 0x019388 },
-	{ "Asia/Dacca"                        , 0x019424 },
-	{ "Asia/Damascus"                     , 0x0194CA },
-	{ "Asia/Dhaka"                        , 0x01981A },
-	{ "Asia/Dili"                         , 0x0198C0 },
-	{ "Asia/Dubai"                        , 0x019949 },
-	{ "Asia/Dushanbe"                     , 0x01999E },
-	{ "Asia/Gaza"                         , 0x019AA1 },
-	{ "Asia/Harbin"                       , 0x019DEA },
-	{ "Asia/Ho_Chi_Minh"                  , 0x019ED1 },
-	{ "Asia/Hong_Kong"                    , 0x019F49 },
-	{ "Asia/Hovd"                         , 0x01A0FF },
-	{ "Asia/Irkutsk"                      , 0x01A277 },
-	{ "Asia/Istanbul"                     , 0x01A55E },
-	{ "Asia/Jakarta"                      , 0x01A94B },
-	{ "Asia/Jayapura"                     , 0x01A9F5 },
-	{ "Asia/Jerusalem"                    , 0x01AA79 },
-	{ "Asia/Kabul"                        , 0x01ADA8 },
-	{ "Asia/Kamchatka"                    , 0x01ADF9 },
-	{ "Asia/Karachi"                      , 0x01B0DE },
-	{ "Asia/Kashgar"                      , 0x01B193 },
-	{ "Asia/Kathmandu"                    , 0x01B264 },
-	{ "Asia/Katmandu"                     , 0x01B2CA },
-	{ "Asia/Kolkata"                      , 0x01B330 },
-	{ "Asia/Krasnoyarsk"                  , 0x01B3A9 },
-	{ "Asia/Kuala_Lumpur"                 , 0x01B692 },
-	{ "Asia/Kuching"                      , 0x01B74F },
-	{ "Asia/Kuwait"                       , 0x01B83D },
-	{ "Asia/Macao"                        , 0x01B892 },
-	{ "Asia/Macau"                        , 0x01B9CD },
-	{ "Asia/Magadan"                      , 0x01BB08 },
-	{ "Asia/Makassar"                     , 0x01BDEB },
-	{ "Asia/Manila"                       , 0x01BEA4 },
-	{ "Asia/Muscat"                       , 0x01BF29 },
-	{ "Asia/Nicosia"                      , 0x01BF7E },
-	{ "Asia/Novosibirsk"                  , 0x01C266 },
-	{ "Asia/Omsk"                         , 0x01C55A },
-	{ "Asia/Oral"                         , 0x01C842 },
-	{ "Asia/Phnom_Penh"                   , 0x01CA12 },
-	{ "Asia/Pontianak"                    , 0x01CA8A },
-	{ "Asia/Pyongyang"                    , 0x01CB4B },
-	{ "Asia/Qatar"                        , 0x01CBB8 },
-	{ "Asia/Qyzylorda"                    , 0x01CC1E },
-	{ "Asia/Rangoon"                      , 0x01CDF4 },
-	{ "Asia/Riyadh"                       , 0x01CE6C },
-	{ "Asia/Saigon"                       , 0x01CEC1 },
-	{ "Asia/Sakhalin"                     , 0x01CF39 },
-	{ "Asia/Samarkand"                    , 0x01D239 },
-	{ "Asia/Seoul"                        , 0x01D36F },
-	{ "Asia/Shanghai"                     , 0x01D413 },
-	{ "Asia/Singapore"                    , 0x01D4F3 },
-	{ "Asia/Taipei"                       , 0x01D5AA },
-	{ "Asia/Tashkent"                     , 0x01D6C2 },
-	{ "Asia/Tbilisi"                      , 0x01D7F3 },
-	{ "Asia/Tehran"                       , 0x01D9AD },
-	{ "Asia/Tel_Aviv"                     , 0x01DC1B },
-	{ "Asia/Thimbu"                       , 0x01DF4A },
-	{ "Asia/Thimphu"                      , 0x01DFB0 },
-	{ "Asia/Tokyo"                        , 0x01E016 },
-	{ "Asia/Ujung_Pandang"                , 0x01E09F },
-	{ "Asia/Ulaanbaatar"                  , 0x01E11B },
-	{ "Asia/Ulan_Bator"                   , 0x01E276 },
-	{ "Asia/Urumqi"                       , 0x01E3C3 },
-	{ "Asia/Vientiane"                    , 0x01E48A },
-	{ "Asia/Vladivostok"                  , 0x01E502 },
-	{ "Asia/Yakutsk"                      , 0x01E7EF },
-	{ "Asia/Yekaterinburg"                , 0x01EAD5 },
-	{ "Asia/Yerevan"                      , 0x01EDE1 },
-	{ "Atlantic/Azores"                   , 0x01F0E5 },
-	{ "Atlantic/Bermuda"                  , 0x01F5E8 },
-	{ "Atlantic/Canary"                   , 0x01F8C9 },
-	{ "Atlantic/Cape_Verde"               , 0x01FB9F },
-	{ "Atlantic/Faeroe"                   , 0x01FC18 },
-	{ "Atlantic/Faroe"                    , 0x01FEBC },
-	{ "Atlantic/Jan_Mayen"                , 0x020160 },
-	{ "Atlantic/Madeira"                  , 0x020492 },
-	{ "Atlantic/Reykjavik"                , 0x02099B },
-	{ "Atlantic/South_Georgia"            , 0x020B54 },
-	{ "Atlantic/St_Helena"                , 0x020E6C },
-	{ "Atlantic/Stanley"                  , 0x020B98 },
-	{ "Australia/ACT"                     , 0x020EC1 },
-	{ "Australia/Adelaide"                , 0x0211DE },
-	{ "Australia/Brisbane"                , 0x02150A },
-	{ "Australia/Broken_Hill"             , 0x0215D1 },
-	{ "Australia/Canberra"                , 0x02190F },
-	{ "Australia/Currie"                  , 0x021C2C },
-	{ "Australia/Darwin"                  , 0x021F5F },
-	{ "Australia/Eucla"                   , 0x021FE5 },
-	{ "Australia/Hobart"                  , 0x0220BA },
-	{ "Australia/LHI"                     , 0x022418 },
-	{ "Australia/Lindeman"                , 0x0226B3 },
-	{ "Australia/Lord_Howe"               , 0x022794 },
-	{ "Australia/Melbourne"               , 0x022A3F },
-	{ "Australia/North"                   , 0x022D64 },
-	{ "Australia/NSW"                     , 0x022DD8 },
-	{ "Australia/Perth"                   , 0x0230F5 },
-	{ "Australia/Queensland"              , 0x0231CD },
-	{ "Australia/South"                   , 0x023279 },
-	{ "Australia/Sydney"                  , 0x023596 },
-	{ "Australia/Tasmania"                , 0x0238D3 },
-	{ "Australia/Victoria"                , 0x023C18 },
-	{ "Australia/West"                    , 0x023F35 },
-	{ "Australia/Yancowinna"              , 0x023FEB },
-	{ "Brazil/Acre"                       , 0x02430D },
-	{ "Brazil/DeNoronha"                  , 0x02440C },
-	{ "Brazil/East"                       , 0x02452C },
-	{ "Brazil/West"                       , 0x024809 },
-	{ "Canada/Atlantic"                   , 0x024901 },
-	{ "Canada/Central"                    , 0x024DE9 },
-	{ "Canada/East-Saskatchewan"          , 0x0256F3 },
-	{ "Canada/Eastern"                    , 0x025203 },
-	{ "Canada/Mountain"                   , 0x02587C },
-	{ "Canada/Newfoundland"               , 0x025BF2 },
-	{ "Canada/Pacific"                    , 0x02611D },
-	{ "Canada/Saskatchewan"               , 0x026536 },
-	{ "Canada/Yukon"                      , 0x0266BF },
-	{ "CET"                               , 0x0269C2 },
-	{ "Chile/Continental"                 , 0x026CCB },
-	{ "Chile/EasterIsland"                , 0x027066 },
-	{ "CST6CDT"                           , 0x0273A8 },
-	{ "Cuba"                              , 0x0276F9 },
-	{ "EET"                               , 0x027A6C },
-	{ "Egypt"                             , 0x027D1F },
-	{ "Eire"                              , 0x0280E6 },
-	{ "EST"                               , 0x0285F7 },
-	{ "EST5EDT"                           , 0x02863B },
-	{ "Etc/GMT"                           , 0x02898C },
-	{ "Etc/GMT+0"                         , 0x028A58 },
-	{ "Etc/GMT+1"                         , 0x028AE2 },
-	{ "Etc/GMT+10"                        , 0x028B6F },
-	{ "Etc/GMT+11"                        , 0x028BFD },
-	{ "Etc/GMT+12"                        , 0x028C8B },
-	{ "Etc/GMT+2"                         , 0x028DA6 },
-	{ "Etc/GMT+3"                         , 0x028E32 },
-	{ "Etc/GMT+4"                         , 0x028EBE },
-	{ "Etc/GMT+5"                         , 0x028F4A },
-	{ "Etc/GMT+6"                         , 0x028FD6 },
-	{ "Etc/GMT+7"                         , 0x029062 },
-	{ "Etc/GMT+8"                         , 0x0290EE },
-	{ "Etc/GMT+9"                         , 0x02917A },
-	{ "Etc/GMT-0"                         , 0x028A14 },
-	{ "Etc/GMT-1"                         , 0x028A9C },
-	{ "Etc/GMT-10"                        , 0x028B28 },
-	{ "Etc/GMT-11"                        , 0x028BB6 },
-	{ "Etc/GMT-12"                        , 0x028C44 },
-	{ "Etc/GMT-13"                        , 0x028CD2 },
-	{ "Etc/GMT-14"                        , 0x028D19 },
-	{ "Etc/GMT-2"                         , 0x028D60 },
-	{ "Etc/GMT-3"                         , 0x028DEC },
-	{ "Etc/GMT-4"                         , 0x028E78 },
-	{ "Etc/GMT-5"                         , 0x028F04 },
-	{ "Etc/GMT-6"                         , 0x028F90 },
-	{ "Etc/GMT-7"                         , 0x02901C },
-	{ "Etc/GMT-8"                         , 0x0290A8 },
-	{ "Etc/GMT-9"                         , 0x029134 },
-	{ "Etc/GMT0"                          , 0x0289D0 },
-	{ "Etc/Greenwich"                     , 0x0291C0 },
-	{ "Etc/UCT"                           , 0x029204 },
-	{ "Etc/Universal"                     , 0x029248 },
-	{ "Etc/UTC"                           , 0x02928C },
-	{ "Etc/Zulu"                          , 0x0292D0 },
-	{ "Europe/Amsterdam"                  , 0x029314 },
-	{ "Europe/Andorra"                    , 0x029752 },
-	{ "Europe/Athens"                     , 0x0299CE },
-	{ "Europe/Belfast"                    , 0x029D11 },
-	{ "Europe/Belgrade"                   , 0x02A248 },
-	{ "Europe/Berlin"                     , 0x02A511 },
-	{ "Europe/Bratislava"                 , 0x02A867 },
-	{ "Europe/Brussels"                   , 0x02AB99 },
-	{ "Europe/Bucharest"                  , 0x02AFD0 },
-	{ "Europe/Budapest"                   , 0x02B2FA },
-	{ "Europe/Chisinau"                   , 0x02B66D },
-	{ "Europe/Copenhagen"                 , 0x02B9FB },
-	{ "Europe/Dublin"                     , 0x02BD05 },
-	{ "Europe/Gibraltar"                  , 0x02C216 },
-	{ "Europe/Guernsey"                   , 0x02C66D },
-	{ "Europe/Helsinki"                   , 0x02CBA4 },
-	{ "Europe/Isle_of_Man"                , 0x02CE5A },
-	{ "Europe/Istanbul"                   , 0x02D391 },
-	{ "Europe/Jersey"                     , 0x02D77E },
-	{ "Europe/Kaliningrad"                , 0x02DCB5 },
-	{ "Europe/Kiev"                       , 0x02E018 },
-	{ "Europe/Lisbon"                     , 0x02E32F },
-	{ "Europe/Ljubljana"                  , 0x02E833 },
-	{ "Europe/London"                     , 0x02EAFC },
-	{ "Europe/Luxembourg"                 , 0x02F033 },
-	{ "Europe/Madrid"                     , 0x02F489 },
-	{ "Europe/Malta"                      , 0x02F84F },
-	{ "Europe/Mariehamn"                  , 0x02FC08 },
-	{ "Europe/Minsk"                      , 0x02FEBE },
-	{ "Europe/Monaco"                     , 0x0301C9 },
-	{ "Europe/Moscow"                     , 0x030604 },
-	{ "Europe/Nicosia"                    , 0x030956 },
-	{ "Europe/Oslo"                       , 0x030C3E },
-	{ "Europe/Paris"                      , 0x030F70 },
-	{ "Europe/Podgorica"                  , 0x0313B6 },
-	{ "Europe/Prague"                     , 0x03167F },
-	{ "Europe/Riga"                       , 0x0319B1 },
-	{ "Europe/Rome"                       , 0x031CF6 },
-	{ "Europe/Samara"                     , 0x0320B9 },
-	{ "Europe/San_Marino"                 , 0x0323E5 },
-	{ "Europe/Sarajevo"                   , 0x0327A8 },
-	{ "Europe/Simferopol"                 , 0x032A71 },
-	{ "Europe/Skopje"                     , 0x032D9C },
-	{ "Europe/Sofia"                      , 0x033065 },
-	{ "Europe/Stockholm"                  , 0x03336D },
-	{ "Europe/Tallinn"                    , 0x03361C },
-	{ "Europe/Tirane"                     , 0x033956 },
-	{ "Europe/Tiraspol"                   , 0x033C5C },
-	{ "Europe/Uzhgorod"                   , 0x033FEA },
-	{ "Europe/Vaduz"                      , 0x034301 },
-	{ "Europe/Vatican"                    , 0x034594 },
-	{ "Europe/Vienna"                     , 0x034957 },
-	{ "Europe/Vilnius"                    , 0x034C84 },
-	{ "Europe/Volgograd"                  , 0x034FC3 },
-	{ "Europe/Warsaw"                     , 0x0352CC },
-	{ "Europe/Zagreb"                     , 0x0356AD },
-	{ "Europe/Zaporozhye"                 , 0x035976 },
-	{ "Europe/Zurich"                     , 0x035CB7 },
-	{ "Factory"                           , 0x035F66 },
-	{ "GB"                                , 0x035FD7 },
-	{ "GB-Eire"                           , 0x03650E },
-	{ "GMT"                               , 0x036A45 },
-	{ "GMT+0"                             , 0x036B11 },
-	{ "GMT-0"                             , 0x036ACD },
-	{ "GMT0"                              , 0x036A89 },
-	{ "Greenwich"                         , 0x036B55 },
-	{ "Hongkong"                          , 0x036B99 },
-	{ "HST"                               , 0x036D4F },
-	{ "Iceland"                           , 0x036D93 },
-	{ "Indian/Antananarivo"               , 0x036F4C },
-	{ "Indian/Chagos"                     , 0x036FC0 },
-	{ "Indian/Christmas"                  , 0x037022 },
-	{ "Indian/Cocos"                      , 0x037066 },
-	{ "Indian/Comoro"                     , 0x0370AA },
-	{ "Indian/Kerguelen"                  , 0x0370FF },
-	{ "Indian/Mahe"                       , 0x037154 },
-	{ "Indian/Maldives"                   , 0x0371A9 },
-	{ "Indian/Mauritius"                  , 0x0371FE },
-	{ "Indian/Mayotte"                    , 0x037274 },
-	{ "Indian/Reunion"                    , 0x0372C9 },
-	{ "Iran"                              , 0x03731E },
-	{ "Israel"                            , 0x03758C },
-	{ "Jamaica"                           , 0x0378BB },
-	{ "Japan"                             , 0x037980 },
-	{ "Kwajalein"                         , 0x037A09 },
-	{ "Libya"                             , 0x037A6C },
-	{ "MET"                               , 0x037B66 },
-	{ "Mexico/BajaNorte"                  , 0x037E6F },
-	{ "Mexico/BajaSur"                    , 0x0381D8 },
-	{ "Mexico/General"                    , 0x03841D },
-	{ "MST"                               , 0x03867B },
-	{ "MST7MDT"                           , 0x0386BF },
-	{ "Navajo"                            , 0x038A10 },
-	{ "NZ"                                , 0x038D89 },
-	{ "NZ-CHAT"                           , 0x039107 },
-	{ "Pacific/Apia"                      , 0x0393EF },
-	{ "Pacific/Auckland"                  , 0x03946D },
-	{ "Pacific/Chatham"                   , 0x0397F9 },
-	{ "Pacific/Easter"                    , 0x039AF0 },
-	{ "Pacific/Efate"                     , 0x039E4E },
-	{ "Pacific/Enderbury"                 , 0x039F14 },
-	{ "Pacific/Fakaofo"                   , 0x039F82 },
-	{ "Pacific/Fiji"                      , 0x039FC6 },
-	{ "Pacific/Funafuti"                  , 0x03A03C },
-	{ "Pacific/Galapagos"                 , 0x03A080 },
-	{ "Pacific/Gambier"                   , 0x03A0F8 },
-	{ "Pacific/Guadalcanal"               , 0x03A15D },
-	{ "Pacific/Guam"                      , 0x03A1B2 },
-	{ "Pacific/Honolulu"                  , 0x03A208 },
-	{ "Pacific/Johnston"                  , 0x03A29C },
-	{ "Pacific/Kiritimati"                , 0x03A2EE },
-	{ "Pacific/Kosrae"                    , 0x03A359 },
-	{ "Pacific/Kwajalein"                 , 0x03A3B6 },
-	{ "Pacific/Majuro"                    , 0x03A422 },
-	{ "Pacific/Marquesas"                 , 0x03A481 },
-	{ "Pacific/Midway"                    , 0x03A4E8 },
-	{ "Pacific/Nauru"                     , 0x03A572 },
-	{ "Pacific/Niue"                      , 0x03A5EA },
-	{ "Pacific/Norfolk"                   , 0x03A648 },
-	{ "Pacific/Noumea"                    , 0x03A69D },
-	{ "Pacific/Pago_Pago"                 , 0x03A72D },
-	{ "Pacific/Palau"                     , 0x03A7B6 },
-	{ "Pacific/Pitcairn"                  , 0x03A7FA },
-	{ "Pacific/Ponape"                    , 0x03A84F },
-	{ "Pacific/Port_Moresby"              , 0x03A8A4 },
-	{ "Pacific/Rarotonga"                 , 0x03A8E8 },
-	{ "Pacific/Saipan"                    , 0x03A9C4 },
-	{ "Pacific/Samoa"                     , 0x03AA27 },
-	{ "Pacific/Tahiti"                    , 0x03AAB0 },
-	{ "Pacific/Tarawa"                    , 0x03AB15 },
-	{ "Pacific/Tongatapu"                 , 0x03AB69 },
-	{ "Pacific/Truk"                      , 0x03ABF5 },
-	{ "Pacific/Wake"                      , 0x03AC4E },
-	{ "Pacific/Wallis"                    , 0x03AC9E },
-	{ "Pacific/Yap"                       , 0x03ACE2 },
-	{ "Poland"                            , 0x03AD27 },
-	{ "Portugal"                          , 0x03B108 },
-	{ "PRC"                               , 0x03B604 },
-	{ "PST8PDT"                           , 0x03B6B5 },
-	{ "ROC"                               , 0x03BA06 },
-	{ "ROK"                               , 0x03BB1E },
-	{ "Singapore"                         , 0x03BBC2 },
-	{ "Turkey"                            , 0x03BC79 },
-	{ "UCT"                               , 0x03C066 },
-	{ "Universal"                         , 0x03C0AA },
-	{ "US/Alaska"                         , 0x03C0EE },
-	{ "US/Aleutian"                       , 0x03C457 },
-	{ "US/Arizona"                        , 0x03C7BD },
-	{ "US/Central"                        , 0x03C84B },
-	{ "US/East-Indiana"                   , 0x03D255 },
-	{ "US/Eastern"                        , 0x03CD56 },
-	{ "US/Hawaii"                         , 0x03D4BF },
-	{ "US/Indiana-Starke"                 , 0x03D54D },
-	{ "US/Michigan"                       , 0x03D8BE },
-	{ "US/Mountain"                       , 0x03DBF5 },
-	{ "US/Pacific"                        , 0x03DF6E },
-	{ "US/Pacific-New"                    , 0x03E373 },
-	{ "US/Samoa"                          , 0x03E778 },
-	{ "UTC"                               , 0x03E801 },
-	{ "W-SU"                              , 0x03EAF8 },
-	{ "WET"                               , 0x03E845 },
-	{ "Zulu"                              , 0x03EE33 },
+	{ "America/Argentina/Catamarca"       , 0x002BA6 },
+	{ "America/Argentina/ComodRivadavia"  , 0x002D67 },
+	{ "America/Argentina/Cordoba"         , 0x002F0D },
+	{ "America/Argentina/Jujuy"           , 0x0030E2 },
+	{ "America/Argentina/La_Rioja"        , 0x003296 },
+	{ "America/Argentina/Mendoza"         , 0x00344E },
+	{ "America/Argentina/Rio_Gallegos"    , 0x00360E },
+	{ "America/Argentina/Salta"           , 0x0037C3 },
+	{ "America/Argentina/San_Juan"        , 0x00396F },
+	{ "America/Argentina/San_Luis"        , 0x003B27 },
+	{ "America/Argentina/Tucuman"         , 0x003E05 },
+	{ "America/Argentina/Ushuaia"         , 0x003FC1 },
+	{ "America/Aruba"                     , 0x00417C },
+	{ "America/Asuncion"                  , 0x0041E2 },
+	{ "America/Atikokan"                  , 0x0044C7 },
+	{ "America/Atka"                      , 0x00459D },
+	{ "America/Bahia"                     , 0x004903 },
+	{ "America/Barbados"                  , 0x004A8C },
+	{ "America/Belem"                     , 0x004B26 },
+	{ "America/Belize"                    , 0x004C21 },
+	{ "America/Blanc-Sablon"              , 0x004D9D },
+	{ "America/Boa_Vista"                 , 0x004E51 },
+	{ "America/Bogota"                    , 0x004F5A },
+	{ "America/Boise"                     , 0x004FC6 },
+	{ "America/Buenos_Aires"              , 0x00535D },
+	{ "America/Cambridge_Bay"             , 0x0054F6 },
+	{ "America/Campo_Grande"              , 0x00581E },
+	{ "America/Cancun"                    , 0x005B0D },
+	{ "America/Caracas"                   , 0x005D4F },
+	{ "America/Catamarca"                 , 0x005DB6 },
+	{ "America/Cayenne"                   , 0x005F5C },
+	{ "America/Cayman"                    , 0x005FBE },
+	{ "America/Chicago"                   , 0x006013 },
+	{ "America/Chihuahua"                 , 0x00652A },
+	{ "America/Coral_Harbour"             , 0x006779 },
+	{ "America/Cordoba"                   , 0x00680B },
+	{ "America/Costa_Rica"                , 0x0069B1 },
+	{ "America/Cuiaba"                    , 0x006A3B },
+	{ "America/Curacao"                   , 0x006D19 },
+	{ "America/Danmarkshavn"              , 0x006D7F },
+	{ "America/Dawson"                    , 0x006EC3 },
+	{ "America/Dawson_Creek"              , 0x0071E0 },
+	{ "America/Denver"                    , 0x0073BA },
+	{ "America/Detroit"                   , 0x007740 },
+	{ "America/Dominica"                  , 0x007A9F },
+	{ "America/Edmonton"                  , 0x007AF4 },
+	{ "America/Eirunepe"                  , 0x007EAC },
+	{ "America/El_Salvador"               , 0x007FBF },
+	{ "America/Ensenada"                  , 0x008034 },
+	{ "America/Fort_Wayne"                , 0x0084DB },
+	{ "America/Fortaleza"                 , 0x00839D },
+	{ "America/Glace_Bay"                 , 0x008745 },
+	{ "America/Godthab"                   , 0x008ABC },
+	{ "America/Goose_Bay"                 , 0x008D80 },
+	{ "America/Grand_Turk"                , 0x00923D },
+	{ "America/Grenada"                   , 0x0094EC },
+	{ "America/Guadeloupe"                , 0x009541 },
+	{ "America/Guatemala"                 , 0x009596 },
+	{ "America/Guayaquil"                 , 0x00961F },
+	{ "America/Guyana"                    , 0x00967C },
+	{ "America/Halifax"                   , 0x0096FD },
+	{ "America/Havana"                    , 0x009C13 },
+	{ "America/Hermosillo"                , 0x009F86 },
+	{ "America/Indiana/Indianapolis"      , 0x00A064 },
+	{ "America/Indiana/Knox"              , 0x00A2F5 },
+	{ "America/Indiana/Marengo"           , 0x00A68C },
+	{ "America/Indiana/Petersburg"        , 0x00A932 },
+	{ "America/Indiana/Tell_City"         , 0x00AE7F },
+	{ "America/Indiana/Vevay"             , 0x00B118 },
+	{ "America/Indiana/Vincennes"         , 0x00B353 },
+	{ "America/Indiana/Winamac"           , 0x00B607 },
+	{ "America/Indianapolis"              , 0x00AC15 },
+	{ "America/Inuvik"                    , 0x00B8C0 },
+	{ "America/Iqaluit"                   , 0x00BBB7 },
+	{ "America/Jamaica"                   , 0x00BED9 },
+	{ "America/Jujuy"                     , 0x00BF9E },
+	{ "America/Juneau"                    , 0x00C148 },
+	{ "America/Kentucky/Louisville"       , 0x00C4C6 },
+	{ "America/Kentucky/Monticello"       , 0x00C8E4 },
+	{ "America/Knox_IN"                   , 0x00CC69 },
+	{ "America/La_Paz"                    , 0x00CFDA },
+	{ "America/Lima"                      , 0x00D041 },
+	{ "America/Los_Angeles"               , 0x00D0E9 },
+	{ "America/Louisville"                , 0x00D4FA },
+	{ "America/Maceio"                    , 0x00D8EF },
+	{ "America/Managua"                   , 0x00DA29 },
+	{ "America/Manaus"                    , 0x00DADC },
+	{ "America/Marigot"                   , 0x00DBDE },
+	{ "America/Martinique"                , 0x00DC33 },
+	{ "America/Mazatlan"                  , 0x00DC9F },
+	{ "America/Mendoza"                   , 0x00DF0C },
+	{ "America/Menominee"                 , 0x00E0C0 },
+	{ "America/Merida"                    , 0x00E441 },
+	{ "America/Mexico_City"               , 0x00E67C },
+	{ "America/Miquelon"                  , 0x00E8F7 },
+	{ "America/Moncton"                   , 0x00EB69 },
+	{ "America/Monterrey"                 , 0x00F000 },
+	{ "America/Montevideo"                , 0x00F247 },
+	{ "America/Montreal"                  , 0x00F559 },
+	{ "America/Montserrat"                , 0x00FA6F },
+	{ "America/Nassau"                    , 0x00FAC4 },
+	{ "America/New_York"                  , 0x00FE09 },
+	{ "America/Nipigon"                   , 0x010314 },
+	{ "America/Nome"                      , 0x010665 },
+	{ "America/Noronha"                   , 0x0109E3 },
+	{ "America/North_Dakota/Center"       , 0x010B13 },
+	{ "America/North_Dakota/New_Salem"    , 0x010EA7 },
+	{ "America/Panama"                    , 0x011250 },
+	{ "America/Pangnirtung"               , 0x0112A5 },
+	{ "America/Paramaribo"                , 0x0115DB },
+	{ "America/Phoenix"                   , 0x01166D },
+	{ "America/Port-au-Prince"            , 0x01171B },
+	{ "America/Port_of_Spain"             , 0x011936 },
+	{ "America/Porto_Acre"                , 0x011837 },
+	{ "America/Porto_Velho"               , 0x01198B },
+	{ "America/Puerto_Rico"               , 0x011A81 },
+	{ "America/Rainy_River"               , 0x011AEC },
+	{ "America/Rankin_Inlet"              , 0x011E24 },
+	{ "America/Recife"                    , 0x01210A },
+	{ "America/Regina"                    , 0x012234 },
+	{ "America/Resolute"                  , 0x0123F2 },
+	{ "America/Rio_Branco"                , 0x0126EB },
+	{ "America/Rosario"                   , 0x0127EE },
+	{ "America/Santarem"                  , 0x012994 },
+	{ "America/Santiago"                  , 0x012A99 },
+	{ "America/Santo_Domingo"             , 0x012E42 },
+	{ "America/Sao_Paulo"                 , 0x012F08 },
+	{ "America/Scoresbysund"              , 0x013217 },
+	{ "America/Shiprock"                  , 0x013505 },
+	{ "America/St_Barthelemy"             , 0x013894 },
+	{ "America/St_Johns"                  , 0x0138E9 },
+	{ "America/St_Kitts"                  , 0x013E3C },
+	{ "America/St_Lucia"                  , 0x013E91 },
+	{ "America/St_Thomas"                 , 0x013EE6 },
+	{ "America/St_Vincent"                , 0x013F3B },
+	{ "America/Swift_Current"             , 0x013F90 },
+	{ "America/Tegucigalpa"               , 0x0140B1 },
+	{ "America/Thule"                     , 0x014130 },
+	{ "America/Thunder_Bay"               , 0x014377 },
+	{ "America/Tijuana"                   , 0x0146C0 },
+	{ "America/Toronto"                   , 0x014A35 },
+	{ "America/Tortola"                   , 0x014F4C },
+	{ "America/Vancouver"                 , 0x014FA1 },
+	{ "America/Virgin"                    , 0x0153DE },
+	{ "America/Whitehorse"                , 0x015433 },
+	{ "America/Winnipeg"                  , 0x015750 },
+	{ "America/Yakutat"                   , 0x015B90 },
+	{ "America/Yellowknife"               , 0x015EFB },
+	{ "Antarctica/Casey"                  , 0x01620B },
+	{ "Antarctica/Davis"                  , 0x016291 },
+	{ "Antarctica/DumontDUrville"         , 0x01631B },
+	{ "Antarctica/Mawson"                 , 0x0163AD },
+	{ "Antarctica/McMurdo"                , 0x016429 },
+	{ "Antarctica/Palmer"                 , 0x01672B },
+	{ "Antarctica/Rothera"                , 0x016A47 },
+	{ "Antarctica/South_Pole"             , 0x016ABD },
+	{ "Antarctica/Syowa"                  , 0x016DC5 },
+	{ "Antarctica/Vostok"                 , 0x016E33 },
+	{ "Arctic/Longyearbyen"               , 0x016EA8 },
+	{ "Asia/Aden"                         , 0x0171DA },
+	{ "Asia/Almaty"                       , 0x01722F },
+	{ "Asia/Amman"                        , 0x0173AE },
+	{ "Asia/Anadyr"                       , 0x01766E },
+	{ "Asia/Aqtau"                        , 0x01795C },
+	{ "Asia/Aqtobe"                       , 0x017B5B },
+	{ "Asia/Ashgabat"                     , 0x017D13 },
+	{ "Asia/Ashkhabad"                    , 0x017E30 },
+	{ "Asia/Baghdad"                      , 0x017F4D },
+	{ "Asia/Bahrain"                      , 0x0180C2 },
+	{ "Asia/Baku"                         , 0x018128 },
+	{ "Asia/Bangkok"                      , 0x018410 },
+	{ "Asia/Beirut"                       , 0x018465 },
+	{ "Asia/Bishkek"                      , 0x018772 },
+	{ "Asia/Brunei"                       , 0x01891E },
+	{ "Asia/Calcutta"                     , 0x018980 },
+	{ "Asia/Choibalsan"                   , 0x0189F9 },
+	{ "Asia/Chongqing"                    , 0x018B72 },
+	{ "Asia/Chungking"                    , 0x018C61 },
+	{ "Asia/Colombo"                      , 0x018D10 },
+	{ "Asia/Dacca"                        , 0x018DAC },
+	{ "Asia/Damascus"                     , 0x018E4D },
+	{ "Asia/Dhaka"                        , 0x01919D },
+	{ "Asia/Dili"                         , 0x01923E },
+	{ "Asia/Dubai"                        , 0x0192C7 },
+	{ "Asia/Dushanbe"                     , 0x01931C },
+	{ "Asia/Gaza"                         , 0x01941F },
+	{ "Asia/Harbin"                       , 0x019768 },
+	{ "Asia/Ho_Chi_Minh"                  , 0x01984F },
+	{ "Asia/Hong_Kong"                    , 0x0198C7 },
+	{ "Asia/Hovd"                         , 0x019A93 },
+	{ "Asia/Irkutsk"                      , 0x019C0B },
+	{ "Asia/Istanbul"                     , 0x019EF2 },
+	{ "Asia/Jakarta"                      , 0x01A2DF },
+	{ "Asia/Jayapura"                     , 0x01A389 },
+	{ "Asia/Jerusalem"                    , 0x01A40D },
+	{ "Asia/Kabul"                        , 0x01A73C },
+	{ "Asia/Kamchatka"                    , 0x01A78D },
+	{ "Asia/Karachi"                      , 0x01AA72 },
+	{ "Asia/Kashgar"                      , 0x01AC3F },
+	{ "Asia/Kathmandu"                    , 0x01AD10 },
+	{ "Asia/Katmandu"                     , 0x01AD76 },
+	{ "Asia/Kolkata"                      , 0x01ADDC },
+	{ "Asia/Krasnoyarsk"                  , 0x01AE55 },
+	{ "Asia/Kuala_Lumpur"                 , 0x01B13E },
+	{ "Asia/Kuching"                      , 0x01B1FB },
+	{ "Asia/Kuwait"                       , 0x01B2E9 },
+	{ "Asia/Macao"                        , 0x01B33E },
+	{ "Asia/Macau"                        , 0x01B479 },
+	{ "Asia/Magadan"                      , 0x01B5B4 },
+	{ "Asia/Makassar"                     , 0x01B897 },
+	{ "Asia/Manila"                       , 0x01B950 },
+	{ "Asia/Muscat"                       , 0x01B9D5 },
+	{ "Asia/Nicosia"                      , 0x01BA2A },
+	{ "Asia/Novokuznetsk"                 , 0x01BD12 },
+	{ "Asia/Novosibirsk"                  , 0x01C015 },
+	{ "Asia/Omsk"                         , 0x01C309 },
+	{ "Asia/Oral"                         , 0x01C5F1 },
+	{ "Asia/Phnom_Penh"                   , 0x01C7C1 },
+	{ "Asia/Pontianak"                    , 0x01C839 },
+	{ "Asia/Pyongyang"                    , 0x01C8FA },
+	{ "Asia/Qatar"                        , 0x01C967 },
+	{ "Asia/Qyzylorda"                    , 0x01C9CD },
+	{ "Asia/Rangoon"                      , 0x01CBA3 },
+	{ "Asia/Riyadh"                       , 0x01CC1B },
+	{ "Asia/Saigon"                       , 0x01CC70 },
+	{ "Asia/Sakhalin"                     , 0x01CCE8 },
+	{ "Asia/Samarkand"                    , 0x01CFE8 },
+	{ "Asia/Seoul"                        , 0x01D11E },
+	{ "Asia/Shanghai"                     , 0x01D1C2 },
+	{ "Asia/Singapore"                    , 0x01D2A2 },
+	{ "Asia/Taipei"                       , 0x01D359 },
+	{ "Asia/Tashkent"                     , 0x01D471 },
+	{ "Asia/Tbilisi"                      , 0x01D5A2 },
+	{ "Asia/Tehran"                       , 0x01D75C },
+	{ "Asia/Tel_Aviv"                     , 0x01D9CA },
+	{ "Asia/Thimbu"                       , 0x01DCF9 },
+	{ "Asia/Thimphu"                      , 0x01DD5F },
+	{ "Asia/Tokyo"                        , 0x01DDC5 },
+	{ "Asia/Ujung_Pandang"                , 0x01DE4E },
+	{ "Asia/Ulaanbaatar"                  , 0x01DECA },
+	{ "Asia/Ulan_Bator"                   , 0x01E025 },
+	{ "Asia/Urumqi"                       , 0x01E172 },
+	{ "Asia/Vientiane"                    , 0x01E239 },
+	{ "Asia/Vladivostok"                  , 0x01E2B1 },
+	{ "Asia/Yakutsk"                      , 0x01E59E },
+	{ "Asia/Yekaterinburg"                , 0x01E884 },
+	{ "Asia/Yerevan"                      , 0x01EB90 },
+	{ "Atlantic/Azores"                   , 0x01EE94 },
+	{ "Atlantic/Bermuda"                  , 0x01F397 },
+	{ "Atlantic/Canary"                   , 0x01F678 },
+	{ "Atlantic/Cape_Verde"               , 0x01F94E },
+	{ "Atlantic/Faeroe"                   , 0x01F9C7 },
+	{ "Atlantic/Faroe"                    , 0x01FC6B },
+	{ "Atlantic/Jan_Mayen"                , 0x01FF0F },
+	{ "Atlantic/Madeira"                  , 0x020241 },
+	{ "Atlantic/Reykjavik"                , 0x02074A },
+	{ "Atlantic/South_Georgia"            , 0x020903 },
+	{ "Atlantic/St_Helena"                , 0x020C1B },
+	{ "Atlantic/Stanley"                  , 0x020947 },
+	{ "Australia/ACT"                     , 0x020C70 },
+	{ "Australia/Adelaide"                , 0x020F8D },
+	{ "Australia/Brisbane"                , 0x0212B9 },
+	{ "Australia/Broken_Hill"             , 0x021380 },
+	{ "Australia/Canberra"                , 0x0216BE },
+	{ "Australia/Currie"                  , 0x0219DB },
+	{ "Australia/Darwin"                  , 0x021D0E },
+	{ "Australia/Eucla"                   , 0x021D94 },
+	{ "Australia/Hobart"                  , 0x021E69 },
+	{ "Australia/LHI"                     , 0x0221C7 },
+	{ "Australia/Lindeman"                , 0x022462 },
+	{ "Australia/Lord_Howe"               , 0x022543 },
+	{ "Australia/Melbourne"               , 0x0227EE },
+	{ "Australia/North"                   , 0x022B13 },
+	{ "Australia/NSW"                     , 0x022B87 },
+	{ "Australia/Perth"                   , 0x022EA4 },
+	{ "Australia/Queensland"              , 0x022F7C },
+	{ "Australia/South"                   , 0x023028 },
+	{ "Australia/Sydney"                  , 0x023345 },
+	{ "Australia/Tasmania"                , 0x023682 },
+	{ "Australia/Victoria"                , 0x0239C7 },
+	{ "Australia/West"                    , 0x023CE4 },
+	{ "Australia/Yancowinna"              , 0x023D9A },
+	{ "Brazil/Acre"                       , 0x0240BC },
+	{ "Brazil/DeNoronha"                  , 0x0241BB },
+	{ "Brazil/East"                       , 0x0242DB },
+	{ "Brazil/West"                       , 0x0245B8 },
+	{ "Canada/Atlantic"                   , 0x0246B0 },
+	{ "Canada/Central"                    , 0x024B98 },
+	{ "Canada/East-Saskatchewan"          , 0x0254A2 },
+	{ "Canada/Eastern"                    , 0x024FB2 },
+	{ "Canada/Mountain"                   , 0x02562B },
+	{ "Canada/Newfoundland"               , 0x0259A1 },
+	{ "Canada/Pacific"                    , 0x025ECC },
+	{ "Canada/Saskatchewan"               , 0x0262E5 },
+	{ "Canada/Yukon"                      , 0x02646E },
+	{ "CET"                               , 0x026771 },
+	{ "Chile/Continental"                 , 0x026A7A },
+	{ "Chile/EasterIsland"                , 0x026E15 },
+	{ "CST6CDT"                           , 0x027157 },
+	{ "Cuba"                              , 0x0274A8 },
+	{ "EET"                               , 0x02781B },
+	{ "Egypt"                             , 0x027ACE },
+	{ "Eire"                              , 0x027E95 },
+	{ "EST"                               , 0x0283A6 },
+	{ "EST5EDT"                           , 0x0283EA },
+	{ "Etc/GMT"                           , 0x02873B },
+	{ "Etc/GMT+0"                         , 0x028807 },
+	{ "Etc/GMT+1"                         , 0x028891 },
+	{ "Etc/GMT+10"                        , 0x02891E },
+	{ "Etc/GMT+11"                        , 0x0289AC },
+	{ "Etc/GMT+12"                        , 0x028A3A },
+	{ "Etc/GMT+2"                         , 0x028B55 },
+	{ "Etc/GMT+3"                         , 0x028BE1 },
+	{ "Etc/GMT+4"                         , 0x028C6D },
+	{ "Etc/GMT+5"                         , 0x028CF9 },
+	{ "Etc/GMT+6"                         , 0x028D85 },
+	{ "Etc/GMT+7"                         , 0x028E11 },
+	{ "Etc/GMT+8"                         , 0x028E9D },
+	{ "Etc/GMT+9"                         , 0x028F29 },
+	{ "Etc/GMT-0"                         , 0x0287C3 },
+	{ "Etc/GMT-1"                         , 0x02884B },
+	{ "Etc/GMT-10"                        , 0x0288D7 },
+	{ "Etc/GMT-11"                        , 0x028965 },
+	{ "Etc/GMT-12"                        , 0x0289F3 },
+	{ "Etc/GMT-13"                        , 0x028A81 },
+	{ "Etc/GMT-14"                        , 0x028AC8 },
+	{ "Etc/GMT-2"                         , 0x028B0F },
+	{ "Etc/GMT-3"                         , 0x028B9B },
+	{ "Etc/GMT-4"                         , 0x028C27 },
+	{ "Etc/GMT-5"                         , 0x028CB3 },
+	{ "Etc/GMT-6"                         , 0x028D3F },
+	{ "Etc/GMT-7"                         , 0x028DCB },
+	{ "Etc/GMT-8"                         , 0x028E57 },
+	{ "Etc/GMT-9"                         , 0x028EE3 },
+	{ "Etc/GMT0"                          , 0x02877F },
+	{ "Etc/Greenwich"                     , 0x028F6F },
+	{ "Etc/UCT"                           , 0x028FB3 },
+	{ "Etc/Universal"                     , 0x028FF7 },
+	{ "Etc/UTC"                           , 0x02903B },
+	{ "Etc/Zulu"                          , 0x02907F },
+	{ "Europe/Amsterdam"                  , 0x0290C3 },
+	{ "Europe/Andorra"                    , 0x029501 },
+	{ "Europe/Athens"                     , 0x02977D },
+	{ "Europe/Belfast"                    , 0x029AC0 },
+	{ "Europe/Belgrade"                   , 0x029FF7 },
+	{ "Europe/Berlin"                     , 0x02A2C0 },
+	{ "Europe/Bratislava"                 , 0x02A616 },
+	{ "Europe/Brussels"                   , 0x02A948 },
+	{ "Europe/Bucharest"                  , 0x02AD7F },
+	{ "Europe/Budapest"                   , 0x02B0A9 },
+	{ "Europe/Chisinau"                   , 0x02B41C },
+	{ "Europe/Copenhagen"                 , 0x02B7AA },
+	{ "Europe/Dublin"                     , 0x02BAB4 },
+	{ "Europe/Gibraltar"                  , 0x02BFC5 },
+	{ "Europe/Guernsey"                   , 0x02C41C },
+	{ "Europe/Helsinki"                   , 0x02C953 },
+	{ "Europe/Isle_of_Man"                , 0x02CC09 },
+	{ "Europe/Istanbul"                   , 0x02D140 },
+	{ "Europe/Jersey"                     , 0x02D52D },
+	{ "Europe/Kaliningrad"                , 0x02DA64 },
+	{ "Europe/Kiev"                       , 0x02DDC7 },
+	{ "Europe/Lisbon"                     , 0x02E0DE },
+	{ "Europe/Ljubljana"                  , 0x02E5E2 },
+	{ "Europe/London"                     , 0x02E8AB },
+	{ "Europe/Luxembourg"                 , 0x02EDE2 },
+	{ "Europe/Madrid"                     , 0x02F238 },
+	{ "Europe/Malta"                      , 0x02F5FE },
+	{ "Europe/Mariehamn"                  , 0x02F9B7 },
+	{ "Europe/Minsk"                      , 0x02FC6D },
+	{ "Europe/Monaco"                     , 0x02FF78 },
+	{ "Europe/Moscow"                     , 0x0303B3 },
+	{ "Europe/Nicosia"                    , 0x030705 },
+	{ "Europe/Oslo"                       , 0x0309ED },
+	{ "Europe/Paris"                      , 0x030D1F },
+	{ "Europe/Podgorica"                  , 0x031165 },
+	{ "Europe/Prague"                     , 0x03142E },
+	{ "Europe/Riga"                       , 0x031760 },
+	{ "Europe/Rome"                       , 0x031AA5 },
+	{ "Europe/Samara"                     , 0x031E68 },
+	{ "Europe/San_Marino"                 , 0x032194 },
+	{ "Europe/Sarajevo"                   , 0x032557 },
+	{ "Europe/Simferopol"                 , 0x032820 },
+	{ "Europe/Skopje"                     , 0x032B4B },
+	{ "Europe/Sofia"                      , 0x032E14 },
+	{ "Europe/Stockholm"                  , 0x03311C },
+	{ "Europe/Tallinn"                    , 0x0333CB },
+	{ "Europe/Tirane"                     , 0x033705 },
+	{ "Europe/Tiraspol"                   , 0x033A0B },
+	{ "Europe/Uzhgorod"                   , 0x033D99 },
+	{ "Europe/Vaduz"                      , 0x0340B0 },
+	{ "Europe/Vatican"                    , 0x034343 },
+	{ "Europe/Vienna"                     , 0x034706 },
+	{ "Europe/Vilnius"                    , 0x034A33 },
+	{ "Europe/Volgograd"                  , 0x034D72 },
+	{ "Europe/Warsaw"                     , 0x03507B },
+	{ "Europe/Zagreb"                     , 0x03545C },
+	{ "Europe/Zaporozhye"                 , 0x035725 },
+	{ "Europe/Zurich"                     , 0x035A66 },
+	{ "Factory"                           , 0x035D15 },
+	{ "GB"                                , 0x035D86 },
+	{ "GB-Eire"                           , 0x0362BD },
+	{ "GMT"                               , 0x0367F4 },
+	{ "GMT+0"                             , 0x0368C0 },
+	{ "GMT-0"                             , 0x03687C },
+	{ "GMT0"                              , 0x036838 },
+	{ "Greenwich"                         , 0x036904 },
+	{ "Hongkong"                          , 0x036948 },
+	{ "HST"                               , 0x036B14 },
+	{ "Iceland"                           , 0x036B58 },
+	{ "Indian/Antananarivo"               , 0x036D11 },
+	{ "Indian/Chagos"                     , 0x036D85 },
+	{ "Indian/Christmas"                  , 0x036DE7 },
+	{ "Indian/Cocos"                      , 0x036E2B },
+	{ "Indian/Comoro"                     , 0x036E6F },
+	{ "Indian/Kerguelen"                  , 0x036EC4 },
+	{ "Indian/Mahe"                       , 0x036F19 },
+	{ "Indian/Maldives"                   , 0x036F6E },
+	{ "Indian/Mauritius"                  , 0x036FC3 },
+	{ "Indian/Mayotte"                    , 0x037039 },
+	{ "Indian/Reunion"                    , 0x03708E },
+	{ "Iran"                              , 0x0370E3 },
+	{ "Israel"                            , 0x037351 },
+	{ "Jamaica"                           , 0x037680 },
+	{ "Japan"                             , 0x037745 },
+	{ "Kwajalein"                         , 0x0377CE },
+	{ "Libya"                             , 0x037831 },
+	{ "MET"                               , 0x03792B },
+	{ "Mexico/BajaNorte"                  , 0x037C34 },
+	{ "Mexico/BajaSur"                    , 0x037F9D },
+	{ "Mexico/General"                    , 0x0381E2 },
+	{ "MST"                               , 0x038440 },
+	{ "MST7MDT"                           , 0x038484 },
+	{ "Navajo"                            , 0x0387D5 },
+	{ "NZ"                                , 0x038B4E },
+	{ "NZ-CHAT"                           , 0x038ECC },
+	{ "Pacific/Apia"                      , 0x0391B4 },
+	{ "Pacific/Auckland"                  , 0x039232 },
+	{ "Pacific/Chatham"                   , 0x0395BE },
+	{ "Pacific/Easter"                    , 0x0398B5 },
+	{ "Pacific/Efate"                     , 0x039C13 },
+	{ "Pacific/Enderbury"                 , 0x039CD9 },
+	{ "Pacific/Fakaofo"                   , 0x039D47 },
+	{ "Pacific/Fiji"                      , 0x039D8B },
+	{ "Pacific/Funafuti"                  , 0x039E0B },
+	{ "Pacific/Galapagos"                 , 0x039E4F },
+	{ "Pacific/Gambier"                   , 0x039EC7 },
+	{ "Pacific/Guadalcanal"               , 0x039F2C },
+	{ "Pacific/Guam"                      , 0x039F81 },
+	{ "Pacific/Honolulu"                  , 0x039FD7 },
+	{ "Pacific/Johnston"                  , 0x03A06B },
+	{ "Pacific/Kiritimati"                , 0x03A0BD },
+	{ "Pacific/Kosrae"                    , 0x03A128 },
+	{ "Pacific/Kwajalein"                 , 0x03A185 },
+	{ "Pacific/Majuro"                    , 0x03A1F1 },
+	{ "Pacific/Marquesas"                 , 0x03A250 },
+	{ "Pacific/Midway"                    , 0x03A2B7 },
+	{ "Pacific/Nauru"                     , 0x03A341 },
+	{ "Pacific/Niue"                      , 0x03A3B9 },
+	{ "Pacific/Norfolk"                   , 0x03A417 },
+	{ "Pacific/Noumea"                    , 0x03A46C },
+	{ "Pacific/Pago_Pago"                 , 0x03A4FC },
+	{ "Pacific/Palau"                     , 0x03A585 },
+	{ "Pacific/Pitcairn"                  , 0x03A5C9 },
+	{ "Pacific/Ponape"                    , 0x03A61E },
+	{ "Pacific/Port_Moresby"              , 0x03A673 },
+	{ "Pacific/Rarotonga"                 , 0x03A6B7 },
+	{ "Pacific/Saipan"                    , 0x03A793 },
+	{ "Pacific/Samoa"                     , 0x03A7F6 },
+	{ "Pacific/Tahiti"                    , 0x03A87F },
+	{ "Pacific/Tarawa"                    , 0x03A8E4 },
+	{ "Pacific/Tongatapu"                 , 0x03A938 },
+	{ "Pacific/Truk"                      , 0x03A9C4 },
+	{ "Pacific/Wake"                      , 0x03AA1D },
+	{ "Pacific/Wallis"                    , 0x03AA6D },
+	{ "Pacific/Yap"                       , 0x03AAB1 },
+	{ "Poland"                            , 0x03AAF6 },
+	{ "Portugal"                          , 0x03AED7 },
+	{ "PRC"                               , 0x03B3D3 },
+	{ "PST8PDT"                           , 0x03B484 },
+	{ "ROC"                               , 0x03B7D5 },
+	{ "ROK"                               , 0x03B8ED },
+	{ "Singapore"                         , 0x03B991 },
+	{ "Turkey"                            , 0x03BA48 },
+	{ "UCT"                               , 0x03BE35 },
+	{ "Universal"                         , 0x03BE79 },
+	{ "US/Alaska"                         , 0x03BEBD },
+	{ "US/Aleutian"                       , 0x03C226 },
+	{ "US/Arizona"                        , 0x03C58C },
+	{ "US/Central"                        , 0x03C61A },
+	{ "US/East-Indiana"                   , 0x03D024 },
+	{ "US/Eastern"                        , 0x03CB25 },
+	{ "US/Hawaii"                         , 0x03D28E },
+	{ "US/Indiana-Starke"                 , 0x03D31C },
+	{ "US/Michigan"                       , 0x03D68D },
+	{ "US/Mountain"                       , 0x03D9C4 },
+	{ "US/Pacific"                        , 0x03DD3D },
+	{ "US/Pacific-New"                    , 0x03E142 },
+	{ "US/Samoa"                          , 0x03E547 },
+	{ "UTC"                               , 0x03E5D0 },
+	{ "W-SU"                              , 0x03E8C7 },
+	{ "WET"                               , 0x03E614 },
+	{ "Zulu"                              , 0x03EC02 },
 };
 /* This is a generated file, do not modify */
-const unsigned char timelib_timezone_db_data_builtin[257655] = {
+const unsigned char timelib_timezone_db_data_builtin[257094] = {
 
 
 /* Africa/Abidjan */
@@ -1385,7 +1386,7 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 /* America/Argentina/Buenos_Aires */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x52, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x0D, 0xA2, 0x92, 0x8F, 0x30, 
+0x00, 0x00, 0x00, 0x3C, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x0D, 0xA2, 0x92, 0x8F, 0x30, 
 0xB6, 0x7B, 0x52, 0x40, 0xB7, 0x1A, 0xC9, 0xB0, 0xB8, 0x1E, 0x8F, 0x40, 0xB8, 0xD4, 0x70, 0x30, 
 0xBA, 0x17, 0x7D, 0xC0, 0xBA, 0xB5, 0xA3, 0xB0, 0xBB, 0xF8, 0xB1, 0x40, 0xBC, 0x96, 0xD7, 0x30, 
 0xBD, 0xD9, 0xE4, 0xC0, 0xBE, 0x78, 0x0A, 0xB0, 0xBF, 0xBB, 0x18, 0x40, 0xC0, 0x5A, 0x8F, 0xB0, 
@@ -1400,34 +1401,16 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 0x24, 0x10, 0x94, 0xA0, 0x25, 0x37, 0xF2, 0xB0, 0x25, 0xF0, 0x76, 0xA0, 0x27, 0x21, 0x0F, 0x30, 
 0x27, 0xD0, 0x58, 0xA0, 0x29, 0x00, 0xF1, 0x30, 0x29, 0xB0, 0x3A, 0xA0, 0x2A, 0xE0, 0xD3, 0x30, 
 0x2B, 0x99, 0x57, 0x20, 0x37, 0xF6, 0xC6, 0xB0, 0x38, 0xBF, 0x2A, 0xB0, 0x47, 0x77, 0x09, 0xB0, 
-0x47, 0xDC, 0x7F, 0x20, 0x48, 0xFA, 0xA2, 0xB0, 0x49, 0xBC, 0x61, 0x20, 0x4A, 0xDA, 0x84, 0xB0, 
-0x4B, 0xA5, 0x7D, 0xA0, 0x4C, 0xBA, 0x66, 0xB0, 0x4D, 0x85, 0x5F, 0xA0, 0x4E, 0x9A, 0x48, 0xB0, 
-0x4F, 0x65, 0x41, 0xA0, 0x50, 0x83, 0x65, 0x30, 0x51, 0x45, 0x23, 0xA0, 0x52, 0x63, 0x47, 0x30, 
-0x53, 0x25, 0x05, 0xA0, 0x54, 0x43, 0x29, 0x30, 0x55, 0x04, 0xE7, 0xA0, 0x56, 0x23, 0x0B, 0x30, 
-0x56, 0xEE, 0x04, 0x20, 0x58, 0x02, 0xED, 0x30, 0x58, 0xCD, 0xE6, 0x20, 0x59, 0xE2, 0xCF, 0x30, 
-0x5A, 0xAD, 0xC8, 0x20, 0x5B, 0xCB, 0xEB, 0xB0, 0x5C, 0x8D, 0xAA, 0x20, 0x5D, 0xAB, 0xCD, 0xB0, 
-0x5E, 0x6D, 0x8C, 0x20, 0x5F, 0x8B, 0xAF, 0xB0, 0x60, 0x56, 0xA8, 0xA0, 0x61, 0x6B, 0x91, 0xB0, 
-0x62, 0x36, 0x8A, 0xA0, 0x63, 0x4B, 0x73, 0xB0, 0x64, 0x16, 0x6C, 0xA0, 0x65, 0x2B, 0x55, 0xB0, 
-0x65, 0xF6, 0x4E, 0xA0, 0x67, 0x14, 0x72, 0x30, 0x67, 0xD6, 0x30, 0xA0, 0x68, 0xF4, 0x54, 0x30, 
-0x69, 0xB6, 0x12, 0xA0, 0x6A, 0xD4, 0x36, 0x30, 0x6B, 0x9F, 0x2F, 0x20, 0x6C, 0xB4, 0x18, 0x30, 
-0x6D, 0x7F, 0x11, 0x20, 0x6E, 0x93, 0xFA, 0x30, 0x6F, 0x5E, 0xF3, 0x20, 0x70, 0x7D, 0x16, 0xB0, 
-0x71, 0x3E, 0xD5, 0x20, 0x72, 0x5C, 0xF8, 0xB0, 0x73, 0x1E, 0xB7, 0x20, 0x74, 0x3C, 0xDA, 0xB0, 
-0x75, 0x07, 0xD3, 0xA0, 0x76, 0x1C, 0xBC, 0xB0, 0x76, 0xE7, 0xB5, 0xA0, 0x77, 0xFC, 0x9E, 0xB0, 
-0x78, 0xC7, 0x97, 0xA0, 0x79, 0xDC, 0x80, 0xB0, 0x7A, 0xA7, 0x79, 0xA0, 0x7B, 0xC5, 0x9D, 0x30, 
-0x7C, 0x87, 0x5B, 0xA0, 0x7D, 0xA5, 0x7F, 0x30, 0x7E, 0x67, 0x3D, 0xA0, 0x7F, 0x85, 0x61, 0x30, 
+0x47, 0xDC, 0x7F, 0x20, 0x48, 0xFA, 0xA2, 0xB0, 0x49, 0xBC, 0x61, 0x20, 0x01, 0x02, 0x01, 0x02, 
 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
-0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x02, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0xFF, 0xFF, 0xC3, 0xD0, 0x00, 0x00, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 
-0x04, 0xFF, 0xFF, 0xD5, 0xD0, 0x01, 0x08, 0xFF, 0xFF, 0xE3, 0xE0, 0x01, 0x08, 0xFF, 0xFF, 0xD5, 
-0xD0, 0x00, 0x04, 0x43, 0x4D, 0x54, 0x00, 0x41, 0x52, 0x54, 0x00, 0x41, 0x52, 0x53, 0x54, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x54, 0x88, 0xA0, 0x00, 0xB9, 
-0x78, 0x78, 0x00, 0x00, 0x00, 0x15, 0x42, 0x75, 0x65, 0x6E, 0x6F, 0x73, 0x20, 0x41, 0x69, 0x72, 
-0x65, 0x73, 0x20, 0x28, 0x42, 0x41, 0x2C, 0x20, 0x43, 0x46, 0x29, 
+0x01, 0x02, 0x01, 0x02, 0x01, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
+0x03, 0x04, 0x02, 0x04, 0x03, 0x04, 0x03, 0x04, 0xFF, 0xFF, 0xC3, 0xD0, 0x00, 0x00, 0xFF, 0xFF, 
+0xC7, 0xC0, 0x00, 0x04, 0xFF, 0xFF, 0xD5, 0xD0, 0x01, 0x08, 0xFF, 0xFF, 0xE3, 0xE0, 0x01, 0x08, 
+0xFF, 0xFF, 0xD5, 0xD0, 0x00, 0x04, 0x43, 0x4D, 0x54, 0x00, 0x41, 0x52, 0x54, 0x00, 0x41, 0x52, 
+0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x54, 0x88, 
+0xA0, 0x00, 0xB9, 0x78, 0x78, 0x00, 0x00, 0x00, 0x15, 0x42, 0x75, 0x65, 0x6E, 0x6F, 0x73, 0x20, 
+0x41, 0x69, 0x72, 0x65, 0x73, 0x20, 0x28, 0x42, 0x41, 0x2C, 0x20, 0x43, 0x46, 0x29, 
 
 /* America/Argentina/Catamarca */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x52, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
@@ -1492,7 +1475,7 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 /* America/Argentina/Cordoba */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x52, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x12, 0xA2, 0x92, 0x8F, 0x30, 
+0x00, 0x00, 0x00, 0x3C, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x12, 0xA2, 0x92, 0x8F, 0x30, 
 0xB6, 0x7B, 0x52, 0x40, 0xB7, 0x1A, 0xC9, 0xB0, 0xB8, 0x1E, 0x8F, 0x40, 0xB8, 0xD4, 0x70, 0x30, 
 0xBA, 0x17, 0x7D, 0xC0, 0xBA, 0xB5, 0xA3, 0xB0, 0xBB, 0xF8, 0xB1, 0x40, 0xBC, 0x96, 0xD7, 0x30, 
 0xBD, 0xD9, 0xE4, 0xC0, 0xBE, 0x78, 0x0A, 0xB0, 0xBF, 0xBB, 0x18, 0x40, 0xC0, 0x5A, 0x8F, 0xB0, 
@@ -1507,37 +1490,19 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 0x24, 0x10, 0x94, 0xA0, 0x25, 0x37, 0xF2, 0xB0, 0x25, 0xF0, 0x76, 0xA0, 0x27, 0x21, 0x0F, 0x30, 
 0x27, 0xD0, 0x58, 0xA0, 0x29, 0x00, 0xFF, 0x40, 0x29, 0xB0, 0x3A, 0xA0, 0x2A, 0xE0, 0xD3, 0x30, 
 0x2B, 0x99, 0x57, 0x20, 0x37, 0xF6, 0xC6, 0xB0, 0x38, 0xBF, 0x2A, 0xB0, 0x47, 0x77, 0x09, 0xB0, 
-0x47, 0xDC, 0x7F, 0x20, 0x48, 0xFA, 0xA2, 0xB0, 0x49, 0xBC, 0x61, 0x20, 0x4A, 0xDA, 0x84, 0xB0, 
-0x4B, 0xA5, 0x7D, 0xA0, 0x4C, 0xBA, 0x66, 0xB0, 0x4D, 0x85, 0x5F, 0xA0, 0x4E, 0x9A, 0x48, 0xB0, 
-0x4F, 0x65, 0x41, 0xA0, 0x50, 0x83, 0x65, 0x30, 0x51, 0x45, 0x23, 0xA0, 0x52, 0x63, 0x47, 0x30, 
-0x53, 0x25, 0x05, 0xA0, 0x54, 0x43, 0x29, 0x30, 0x55, 0x04, 0xE7, 0xA0, 0x56, 0x23, 0x0B, 0x30, 
-0x56, 0xEE, 0x04, 0x20, 0x58, 0x02, 0xED, 0x30, 0x58, 0xCD, 0xE6, 0x20, 0x59, 0xE2, 0xCF, 0x30, 
-0x5A, 0xAD, 0xC8, 0x20, 0x5B, 0xCB, 0xEB, 0xB0, 0x5C, 0x8D, 0xAA, 0x20, 0x5D, 0xAB, 0xCD, 0xB0, 
-0x5E, 0x6D, 0x8C, 0x20, 0x5F, 0x8B, 0xAF, 0xB0, 0x60, 0x56, 0xA8, 0xA0, 0x61, 0x6B, 0x91, 0xB0, 
-0x62, 0x36, 0x8A, 0xA0, 0x63, 0x4B, 0x73, 0xB0, 0x64, 0x16, 0x6C, 0xA0, 0x65, 0x2B, 0x55, 0xB0, 
-0x65, 0xF6, 0x4E, 0xA0, 0x67, 0x14, 0x72, 0x30, 0x67, 0xD6, 0x30, 0xA0, 0x68, 0xF4, 0x54, 0x30, 
-0x69, 0xB6, 0x12, 0xA0, 0x6A, 0xD4, 0x36, 0x30, 0x6B, 0x9F, 0x2F, 0x20, 0x6C, 0xB4, 0x18, 0x30, 
-0x6D, 0x7F, 0x11, 0x20, 0x6E, 0x93, 0xFA, 0x30, 0x6F, 0x5E, 0xF3, 0x20, 0x70, 0x7D, 0x16, 0xB0, 
-0x71, 0x3E, 0xD5, 0x20, 0x72, 0x5C, 0xF8, 0xB0, 0x73, 0x1E, 0xB7, 0x20, 0x74, 0x3C, 0xDA, 0xB0, 
-0x75, 0x07, 0xD3, 0xA0, 0x76, 0x1C, 0xBC, 0xB0, 0x76, 0xE7, 0xB5, 0xA0, 0x77, 0xFC, 0x9E, 0xB0, 
-0x78, 0xC7, 0x97, 0xA0, 0x79, 0xDC, 0x80, 0xB0, 0x7A, 0xA7, 0x79, 0xA0, 0x7B, 0xC5, 0x9D, 0x30, 
-0x7C, 0x87, 0x5B, 0xA0, 0x7D, 0xA5, 0x7F, 0x30, 0x7E, 0x67, 0x3D, 0xA0, 0x7F, 0x85, 0x61, 0x30, 
+0x47, 0xDC, 0x7F, 0x20, 0x48, 0xFA, 0xA2, 0xB0, 0x49, 0xBC, 0x61, 0x20, 0x01, 0x02, 0x01, 0x02, 
 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
-0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x05, 0x03, 0x04, 0x03, 0x04, 0x02, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0xFF, 0xFF, 0xC3, 0xD0, 0x00, 0x00, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 
-0x04, 0xFF, 0xFF, 0xD5, 0xD0, 0x01, 0x08, 0xFF, 0xFF, 0xE3, 0xE0, 0x01, 0x08, 0xFF, 0xFF, 0xD5, 
-0xD0, 0x00, 0x04, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 0x0D, 0x43, 0x4D, 0x54, 0x00, 0x41, 0x52, 0x54, 
-0x00, 0x41, 0x52, 0x53, 0x54, 0x00, 0x57, 0x41, 0x52, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x59, 0x6A, 0xA0, 0x00, 0xB0, 0xB8, 0xE2, 0x00, 
-0x00, 0x00, 0x2F, 0x6D, 0x6F, 0x73, 0x74, 0x20, 0x6C, 0x6F, 0x63, 0x61, 0x74, 0x69, 0x6F, 0x6E, 
-0x73, 0x20, 0x28, 0x43, 0x42, 0x2C, 0x20, 0x43, 0x43, 0x2C, 0x20, 0x43, 0x4E, 0x2C, 0x20, 0x45, 
-0x52, 0x2C, 0x20, 0x46, 0x4D, 0x2C, 0x20, 0x4D, 0x4E, 0x2C, 0x20, 0x53, 0x45, 0x2C, 0x20, 0x53, 
-0x46, 0x29, 
+0x01, 0x02, 0x01, 0x02, 0x01, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x05, 0x03, 0x04, 
+0x03, 0x04, 0x02, 0x04, 0x03, 0x04, 0x03, 0x04, 0xFF, 0xFF, 0xC3, 0xD0, 0x00, 0x00, 0xFF, 0xFF, 
+0xC7, 0xC0, 0x00, 0x04, 0xFF, 0xFF, 0xD5, 0xD0, 0x01, 0x08, 0xFF, 0xFF, 0xE3, 0xE0, 0x01, 0x08, 
+0xFF, 0xFF, 0xD5, 0xD0, 0x00, 0x04, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 0x0D, 0x43, 0x4D, 0x54, 0x00, 
+0x41, 0x52, 0x54, 0x00, 0x41, 0x52, 0x53, 0x54, 0x00, 0x57, 0x41, 0x52, 0x54, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x59, 0x6A, 0xA0, 0x00, 0xB0, 
+0xB8, 0xE2, 0x00, 0x00, 0x00, 0x2F, 0x6D, 0x6F, 0x73, 0x74, 0x20, 0x6C, 0x6F, 0x63, 0x61, 0x74, 
+0x69, 0x6F, 0x6E, 0x73, 0x20, 0x28, 0x43, 0x42, 0x2C, 0x20, 0x43, 0x43, 0x2C, 0x20, 0x43, 0x4E, 
+0x2C, 0x20, 0x45, 0x52, 0x2C, 0x20, 0x46, 0x4D, 0x2C, 0x20, 0x4D, 0x4E, 0x2C, 0x20, 0x53, 0x45, 
+0x2C, 0x20, 0x53, 0x46, 0x29, 
 
 /* America/Argentina/Jujuy */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x52, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
@@ -1722,7 +1687,7 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 /* America/Argentina/San_Luis */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x52, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x73, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x18, 0xA2, 0x92, 0x8F, 0x30, 
+0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x18, 0xA2, 0x92, 0x8F, 0x30, 
 0xB6, 0x7B, 0x52, 0x40, 0xB7, 0x1A, 0xC9, 0xB0, 0xB8, 0x1E, 0x8F, 0x40, 0xB8, 0xD4, 0x70, 0x30, 
 0xBA, 0x17, 0x7D, 0xC0, 0xBA, 0xB5, 0xA3, 0xB0, 0xBB, 0xF8, 0xB1, 0x40, 0xBC, 0x96, 0xD7, 0x30, 
 0xBD, 0xD9, 0xE4, 0xC0, 0xBE, 0x78, 0x0A, 0xB0, 0xBF, 0xBB, 0x18, 0x40, 0xC0, 0x5A, 0x8F, 0xB0, 
@@ -1737,40 +1702,40 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 0x24, 0x10, 0x94, 0xA0, 0x25, 0x37, 0xF2, 0xB0, 0x25, 0xFD, 0xA5, 0xA0, 0x27, 0x19, 0x34, 0x40, 
 0x27, 0xCD, 0xC3, 0xB0, 0x28, 0x47, 0x1B, 0xC0, 0x37, 0xF6, 0xC6, 0xB0, 0x38, 0xBF, 0x2A, 0xB0, 
 0x40, 0xBA, 0x9F, 0xB0, 0x41, 0x03, 0x30, 0x40, 0x47, 0x77, 0x09, 0xB0, 0x47, 0x93, 0xFC, 0xA0, 
-0x49, 0xBC, 0x6F, 0x30, 0x4A, 0xDA, 0x92, 0xC0, 0x4B, 0xA5, 0x8B, 0xB0, 0x4C, 0xBA, 0x74, 0xC0, 
-0x4D, 0x85, 0x6D, 0xB0, 0x4E, 0x9A, 0x56, 0xC0, 0x4F, 0x65, 0x4F, 0xB0, 0x50, 0x83, 0x73, 0x40, 
-0x51, 0x45, 0x31, 0xB0, 0x52, 0x63, 0x55, 0x40, 0x53, 0x25, 0x13, 0xB0, 0x54, 0x43, 0x37, 0x40, 
-0x55, 0x04, 0xF5, 0xB0, 0x56, 0x23, 0x19, 0x40, 0x56, 0xEE, 0x12, 0x30, 0x58, 0x02, 0xFB, 0x40, 
-0x58, 0xCD, 0xF4, 0x30, 0x59, 0xE2, 0xDD, 0x40, 0x5A, 0xAD, 0xD6, 0x30, 0x5B, 0xCB, 0xF9, 0xC0, 
-0x5C, 0x8D, 0xB8, 0x30, 0x5D, 0xAB, 0xDB, 0xC0, 0x5E, 0x6D, 0x9A, 0x30, 0x5F, 0x8B, 0xBD, 0xC0, 
-0x60, 0x56, 0xB6, 0xB0, 0x61, 0x6B, 0x9F, 0xC0, 0x62, 0x36, 0x98, 0xB0, 0x63, 0x4B, 0x81, 0xC0, 
-0x64, 0x16, 0x7A, 0xB0, 0x65, 0x2B, 0x63, 0xC0, 0x65, 0xF6, 0x5C, 0xB0, 0x67, 0x14, 0x80, 0x40, 
-0x67, 0xD6, 0x3E, 0xB0, 0x68, 0xF4, 0x62, 0x40, 0x69, 0xB6, 0x20, 0xB0, 0x6A, 0xD4, 0x44, 0x40, 
-0x6B, 0x9F, 0x3D, 0x30, 0x6C, 0xB4, 0x26, 0x40, 0x6D, 0x7F, 0x1F, 0x30, 0x6E, 0x94, 0x08, 0x40, 
-0x6F, 0x5F, 0x01, 0x30, 0x70, 0x7D, 0x24, 0xC0, 0x71, 0x3E, 0xE3, 0x30, 0x72, 0x5D, 0x06, 0xC0, 
-0x73, 0x1E, 0xC5, 0x30, 0x74, 0x3C, 0xE8, 0xC0, 0x75, 0x07, 0xE1, 0xB0, 0x76, 0x1C, 0xCA, 0xC0, 
-0x76, 0xE7, 0xC3, 0xB0, 0x77, 0xFC, 0xAC, 0xC0, 0x78, 0xC7, 0xA5, 0xB0, 0x79, 0xDC, 0x8E, 0xC0, 
-0x7A, 0xA7, 0x87, 0xB0, 0x7B, 0xC5, 0xAB, 0x40, 0x7C, 0x87, 0x69, 0xB0, 0x7D, 0xA5, 0x8D, 0x40, 
-0x7E, 0x67, 0x4B, 0xB0, 0x7F, 0x85, 0x6F, 0x40, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
+0x47, 0xD3, 0x52, 0xB0, 0x48, 0xF1, 0x76, 0x40, 0x49, 0xB3, 0x34, 0xB0, 0x4A, 0xD1, 0x58, 0x40, 
+0x4B, 0x9C, 0x51, 0x30, 0x4C, 0xB1, 0x3A, 0x40, 0x4D, 0x7C, 0x33, 0x30, 0x4E, 0x91, 0x1C, 0x40, 
+0x4F, 0x5C, 0x15, 0x30, 0x50, 0x7A, 0x38, 0xC0, 0x51, 0x3B, 0xF7, 0x30, 0x52, 0x5A, 0x1A, 0xC0, 
+0x53, 0x1B, 0xD9, 0x30, 0x54, 0x39, 0xFC, 0xC0, 0x54, 0xFB, 0xBB, 0x30, 0x56, 0x19, 0xDE, 0xC0, 
+0x56, 0xE4, 0xD7, 0xB0, 0x57, 0xF9, 0xC0, 0xC0, 0x58, 0xC4, 0xB9, 0xB0, 0x59, 0xD9, 0xA2, 0xC0, 
+0x5A, 0xA4, 0x9B, 0xB0, 0x5B, 0xC2, 0xBF, 0x40, 0x5C, 0x84, 0x7D, 0xB0, 0x5D, 0xA2, 0xA1, 0x40, 
+0x5E, 0x64, 0x5F, 0xB0, 0x5F, 0x82, 0x83, 0x40, 0x60, 0x4D, 0x7C, 0x30, 0x61, 0x62, 0x65, 0x40, 
+0x62, 0x2D, 0x5E, 0x30, 0x63, 0x42, 0x47, 0x40, 0x64, 0x0D, 0x40, 0x30, 0x65, 0x22, 0x29, 0x40, 
+0x65, 0xED, 0x22, 0x30, 0x67, 0x0B, 0x45, 0xC0, 0x67, 0xCD, 0x04, 0x30, 0x68, 0xEB, 0x27, 0xC0, 
+0x69, 0xAC, 0xE6, 0x30, 0x6A, 0xCB, 0x09, 0xC0, 0x6B, 0x96, 0x02, 0xB0, 0x6C, 0xAA, 0xEB, 0xC0, 
+0x6D, 0x75, 0xE4, 0xB0, 0x6E, 0x8A, 0xCD, 0xC0, 0x6F, 0x55, 0xC6, 0xB0, 0x70, 0x73, 0xEA, 0x40, 
+0x71, 0x35, 0xA8, 0xB0, 0x72, 0x53, 0xCC, 0x40, 0x73, 0x15, 0x8A, 0xB0, 0x74, 0x33, 0xAE, 0x40, 
+0x74, 0xFE, 0xA7, 0x30, 0x76, 0x13, 0x90, 0x40, 0x76, 0xDE, 0x89, 0x30, 0x77, 0xF3, 0x72, 0x40, 
+0x78, 0xBE, 0x6B, 0x30, 0x79, 0xD3, 0x54, 0x40, 0x7A, 0x9E, 0x4D, 0x30, 0x7B, 0xBC, 0x70, 0xC0, 
+0x7C, 0x7E, 0x2F, 0x30, 0x7D, 0x9C, 0x52, 0xC0, 0x7E, 0x5E, 0x11, 0x30, 0x7F, 0x7C, 0x34, 0xC0, 
 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
-0x01, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x05, 0x06, 0x05, 0x04, 0x06, 0x04, 0x05, 0x04, 0x03, 
-0x04, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 
+0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x05, 
+0x06, 0x05, 0x04, 0x06, 0x04, 0x05, 0x04, 0x03, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 
+0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 
 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 
 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 
-0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0x05, 0x06, 0xFF, 0xFF, 0xC3, 0xD0, 0x00, 
-0x00, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 0x04, 0xFF, 0xFF, 0xD5, 0xD0, 0x01, 0x08, 0xFF, 0xFF, 0xE3, 
-0xE0, 0x01, 0x08, 0xFF, 0xFF, 0xD5, 0xD0, 0x00, 0x04, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 0x0D, 0xFF, 
-0xFF, 0xD5, 0xD0, 0x01, 0x12, 0x43, 0x4D, 0x54, 0x00, 0x41, 0x52, 0x54, 0x00, 0x41, 0x52, 0x53, 
-0x54, 0x00, 0x57, 0x41, 0x52, 0x54, 0x00, 0x57, 0x41, 0x52, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x56, 0x7D, 0xED, 0x00, 
-0xAD, 0x6A, 0x88, 0x00, 0x00, 0x00, 0x0D, 0x53, 0x61, 0x6E, 0x20, 0x4C, 0x75, 0x69, 0x73, 0x20, 
-0x28, 0x53, 0x4C, 0x29, 
+0x06, 0x05, 0x06, 0x05, 0x06, 0xFF, 0xFF, 0xC3, 0xD0, 0x00, 0x00, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 
+0x04, 0xFF, 0xFF, 0xD5, 0xD0, 0x01, 0x08, 0xFF, 0xFF, 0xE3, 0xE0, 0x01, 0x08, 0xFF, 0xFF, 0xD5, 
+0xD0, 0x00, 0x04, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 0x0D, 0xFF, 0xFF, 0xD5, 0xD0, 0x01, 0x12, 0x43, 
+0x4D, 0x54, 0x00, 0x41, 0x52, 0x54, 0x00, 0x41, 0x52, 0x53, 0x54, 0x00, 0x57, 0x41, 0x52, 0x54, 
+0x00, 0x57, 0x41, 0x52, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x56, 0x7D, 0xED, 0x00, 0xAD, 0x6A, 0x88, 0x00, 0x00, 0x00, 
+0x0D, 0x53, 0x61, 0x6E, 0x20, 0x4C, 0x75, 0x69, 0x73, 0x20, 0x28, 0x53, 0x4C, 0x29, 
 
 /* America/Argentina/Tucuman */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x52, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x77, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x12, 0xA2, 0x92, 0x8F, 0x30, 
+0x00, 0x00, 0x00, 0x3E, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x12, 0xA2, 0x92, 0x8F, 0x30, 
 0xB6, 0x7B, 0x52, 0x40, 0xB7, 0x1A, 0xC9, 0xB0, 0xB8, 0x1E, 0x8F, 0x40, 0xB8, 0xD4, 0x70, 0x30, 
 0xBA, 0x17, 0x7D, 0xC0, 0xBA, 0xB5, 0xA3, 0xB0, 0xBB, 0xF8, 0xB1, 0x40, 0xBC, 0x96, 0xD7, 0x30, 
 0xBD, 0xD9, 0xE4, 0xC0, 0xBE, 0x78, 0x0A, 0xB0, 0xBF, 0xBB, 0x18, 0x40, 0xC0, 0x5A, 0x8F, 0xB0, 
@@ -1786,34 +1751,16 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 0x27, 0xD0, 0x58, 0xA0, 0x29, 0x00, 0xFF, 0x40, 0x29, 0xB0, 0x3A, 0xA0, 0x2A, 0xE0, 0xD3, 0x30, 
 0x2B, 0x99, 0x57, 0x20, 0x37, 0xF6, 0xC6, 0xB0, 0x38, 0xBF, 0x2A, 0xB0, 0x40, 0xBB, 0xF1, 0x30, 
 0x40, 0xCB, 0xD1, 0x40, 0x47, 0x77, 0x09, 0xB0, 0x47, 0xDC, 0x7F, 0x20, 0x48, 0xFA, 0xA2, 0xB0, 
-0x49, 0xBC, 0x61, 0x20, 0x4A, 0xDA, 0x84, 0xB0, 0x4B, 0xA5, 0x7D, 0xA0, 0x4C, 0xBA, 0x66, 0xB0, 
-0x4D, 0x85, 0x5F, 0xA0, 0x4E, 0x9A, 0x48, 0xB0, 0x4F, 0x65, 0x41, 0xA0, 0x50, 0x83, 0x65, 0x30, 
-0x51, 0x45, 0x23, 0xA0, 0x52, 0x63, 0x47, 0x30, 0x53, 0x25, 0x05, 0xA0, 0x54, 0x43, 0x29, 0x30, 
-0x55, 0x04, 0xE7, 0xA0, 0x56, 0x23, 0x0B, 0x30, 0x56, 0xEE, 0x04, 0x20, 0x58, 0x02, 0xED, 0x30, 
-0x58, 0xCD, 0xE6, 0x20, 0x59, 0xE2, 0xCF, 0x30, 0x5A, 0xAD, 0xC8, 0x20, 0x5B, 0xCB, 0xEB, 0xB0, 
-0x5C, 0x8D, 0xAA, 0x20, 0x5D, 0xAB, 0xCD, 0xB0, 0x5E, 0x6D, 0x8C, 0x20, 0x5F, 0x8B, 0xAF, 0xB0, 
-0x60, 0x56, 0xA8, 0xA0, 0x61, 0x6B, 0x91, 0xB0, 0x62, 0x36, 0x8A, 0xA0, 0x63, 0x4B, 0x73, 0xB0, 
-0x64, 0x16, 0x6C, 0xA0, 0x65, 0x2B, 0x55, 0xB0, 0x65, 0xF6, 0x4E, 0xA0, 0x67, 0x14, 0x72, 0x30, 
-0x67, 0xD6, 0x30, 0xA0, 0x68, 0xF4, 0x54, 0x30, 0x69, 0xB6, 0x12, 0xA0, 0x6A, 0xD4, 0x36, 0x30, 
-0x6B, 0x9F, 0x2F, 0x20, 0x6C, 0xB4, 0x18, 0x30, 0x6D, 0x7F, 0x11, 0x20, 0x6E, 0x93, 0xFA, 0x30, 
-0x6F, 0x5E, 0xF3, 0x20, 0x70, 0x7D, 0x16, 0xB0, 0x71, 0x3E, 0xD5, 0x20, 0x72, 0x5C, 0xF8, 0xB0, 
-0x73, 0x1E, 0xB7, 0x20, 0x74, 0x3C, 0xDA, 0xB0, 0x75, 0x07, 0xD3, 0xA0, 0x76, 0x1C, 0xBC, 0xB0, 
-0x76, 0xE7, 0xB5, 0xA0, 0x77, 0xFC, 0x9E, 0xB0, 0x78, 0xC7, 0x97, 0xA0, 0x79, 0xDC, 0x80, 0xB0, 
-0x7A, 0xA7, 0x79, 0xA0, 0x7B, 0xC5, 0x9D, 0x30, 0x7C, 0x87, 0x5B, 0xA0, 0x7D, 0xA5, 0x7F, 0x30, 
-0x7E, 0x67, 0x3D, 0xA0, 0x7F, 0x85, 0x61, 0x30, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
-0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
+0x49, 0xBC, 0x61, 0x20, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
-0x01, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x05, 0x03, 0x04, 0x03, 0x04, 0x02, 0x04, 
-0x05, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0xFF, 
-0xFF, 0xC3, 0xD0, 0x00, 0x00, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 0x04, 0xFF, 0xFF, 0xD5, 0xD0, 0x01, 
-0x08, 0xFF, 0xFF, 0xE3, 0xE0, 0x01, 0x08, 0xFF, 0xFF, 0xD5, 0xD0, 0x00, 0x04, 0xFF, 0xFF, 0xC7, 
-0xC0, 0x00, 0x0D, 0x43, 0x4D, 0x54, 0x00, 0x41, 0x52, 0x54, 0x00, 0x41, 0x52, 0x53, 0x54, 0x00, 
-0x57, 0x41, 0x52, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x60, 0x68, 0xFD, 0x00, 0xAF, 0x25, 0x3D, 0x00, 0x00, 0x00, 0x0C, 0x54, 0x75, 0x63, 
-0x75, 0x6D, 0x61, 0x6E, 0x20, 0x28, 0x54, 0x4D, 0x29, 
+0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x04, 0x03, 0x04, 
+0x03, 0x04, 0x03, 0x04, 0x03, 0x05, 0x03, 0x04, 0x03, 0x04, 0x02, 0x04, 0x05, 0x04, 0x03, 0x04, 
+0x03, 0x04, 0xFF, 0xFF, 0xC3, 0xD0, 0x00, 0x00, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 0x04, 0xFF, 0xFF, 
+0xD5, 0xD0, 0x01, 0x08, 0xFF, 0xFF, 0xE3, 0xE0, 0x01, 0x08, 0xFF, 0xFF, 0xD5, 0xD0, 0x00, 0x04, 
+0xFF, 0xFF, 0xC7, 0xC0, 0x00, 0x0D, 0x43, 0x4D, 0x54, 0x00, 0x41, 0x52, 0x54, 0x00, 0x41, 0x52, 
+0x53, 0x54, 0x00, 0x57, 0x41, 0x52, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x68, 0xFD, 0x00, 0xAF, 0x25, 0x3D, 0x00, 0x00, 0x00, 0x0C, 
+0x54, 0x75, 0x63, 0x75, 0x6D, 0x61, 0x6E, 0x20, 0x28, 0x54, 0x4D, 0x29, 
 
 /* America/Argentina/Ushuaia */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x52, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
@@ -2164,7 +2111,7 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 /* America/Buenos_Aires */
 0x50, 0x48, 0x50, 0x31, 0x00, 0x3F, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x0D, 0xA2, 0x92, 0x8F, 0x30, 
+0x00, 0x00, 0x00, 0x3C, 0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x0D, 0xA2, 0x92, 0x8F, 0x30, 
 0xB6, 0x7B, 0x52, 0x40, 0xB7, 0x1A, 0xC9, 0xB0, 0xB8, 0x1E, 0x8F, 0x40, 0xB8, 0xD4, 0x70, 0x30, 
 0xBA, 0x17, 0x7D, 0xC0, 0xBA, 0xB5, 0xA3, 0xB0, 0xBB, 0xF8, 0xB1, 0x40, 0xBC, 0x96, 0xD7, 0x30, 
 0xBD, 0xD9, 0xE4, 0xC0, 0xBE, 0x78, 0x0A, 0xB0, 0xBF, 0xBB, 0x18, 0x40, 0xC0, 0x5A, 0x8F, 0xB0, 
@@ -2179,33 +2126,15 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 0x24, 0x10, 0x94, 0xA0, 0x25, 0x37, 0xF2, 0xB0, 0x25, 0xF0, 0x76, 0xA0, 0x27, 0x21, 0x0F, 0x30, 
 0x27, 0xD0, 0x58, 0xA0, 0x29, 0x00, 0xF1, 0x30, 0x29, 0xB0, 0x3A, 0xA0, 0x2A, 0xE0, 0xD3, 0x30, 
 0x2B, 0x99, 0x57, 0x20, 0x37, 0xF6, 0xC6, 0xB0, 0x38, 0xBF, 0x2A, 0xB0, 0x47, 0x77, 0x09, 0xB0, 
-0x47, 0xDC, 0x7F, 0x20, 0x48, 0xFA, 0xA2, 0xB0, 0x49, 0xBC, 0x61, 0x20, 0x4A, 0xDA, 0x84, 0xB0, 
-0x4B, 0xA5, 0x7D, 0xA0, 0x4C, 0xBA, 0x66, 0xB0, 0x4D, 0x85, 0x5F, 0xA0, 0x4E, 0x9A, 0x48, 0xB0, 
-0x4F, 0x65, 0x41, 0xA0, 0x50, 0x83, 0x65, 0x30, 0x51, 0x45, 0x23, 0xA0, 0x52, 0x63, 0x47, 0x30, 
-0x53, 0x25, 0x05, 0xA0, 0x54, 0x43, 0x29, 0x30, 0x55, 0x04, 0xE7, 0xA0, 0x56, 0x23, 0x0B, 0x30, 
-0x56, 0xEE, 0x04, 0x20, 0x58, 0x02, 0xED, 0x30, 0x58, 0xCD, 0xE6, 0x20, 0x59, 0xE2, 0xCF, 0x30, 
-0x5A, 0xAD, 0xC8, 0x20, 0x5B, 0xCB, 0xEB, 0xB0, 0x5C, 0x8D, 0xAA, 0x20, 0x5D, 0xAB, 0xCD, 0xB0, 
-0x5E, 0x6D, 0x8C, 0x20, 0x5F, 0x8B, 0xAF, 0xB0, 0x60, 0x56, 0xA8, 0xA0, 0x61, 0x6B, 0x91, 0xB0, 
-0x62, 0x36, 0x8A, 0xA0, 0x63, 0x4B, 0x73, 0xB0, 0x64, 0x16, 0x6C, 0xA0, 0x65, 0x2B, 0x55, 0xB0, 
-0x65, 0xF6, 0x4E, 0xA0, 0x67, 0x14, 0x72, 0x30, 0x67, 0xD6, 0x30, 0xA0, 0x68, 0xF4, 0x54, 0x30, 
-0x69, 0xB6, 0x12, 0xA0, 0x6A, 0xD4, 0x36, 0x30, 0x6B, 0x9F, 0x2F, 0x20, 0x6C, 0xB4, 0x18, 0x30, 
-0x6D, 0x7F, 0x11, 0x20, 0x6E, 0x93, 0xFA, 0x30, 0x6F, 0x5E, 0xF3, 0x20, 0x70, 0x7D, 0x16, 0xB0, 
-0x71, 0x3E, 0xD5, 0x20, 0x72, 0x5C, 0xF8, 0xB0, 0x73, 0x1E, 0xB7, 0x20, 0x74, 0x3C, 0xDA, 0xB0, 
-0x75, 0x07, 0xD3, 0xA0, 0x76, 0x1C, 0xBC, 0xB0, 0x76, 0xE7, 0xB5, 0xA0, 0x77, 0xFC, 0x9E, 0xB0, 
-0x78, 0xC7, 0x97, 0xA0, 0x79, 0xDC, 0x80, 0xB0, 0x7A, 0xA7, 0x79, 0xA0, 0x7B, 0xC5, 0x9D, 0x30, 
-0x7C, 0x87, 0x5B, 0xA0, 0x7D, 0xA5, 0x7F, 0x30, 0x7E, 0x67, 0x3D, 0xA0, 0x7F, 0x85, 0x61, 0x30, 
+0x47, 0xDC, 0x7F, 0x20, 0x48, 0xFA, 0xA2, 0xB0, 0x49, 0xBC, 0x61, 0x20, 0x01, 0x02, 0x01, 0x02, 
 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
-0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x02, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0xFF, 0xFF, 0xC3, 0xD0, 0x00, 0x00, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 
-0x04, 0xFF, 0xFF, 0xD5, 0xD0, 0x01, 0x08, 0xFF, 0xFF, 0xE3, 0xE0, 0x01, 0x08, 0xFF, 0xFF, 0xD5, 
-0xD0, 0x00, 0x04, 0x43, 0x4D, 0x54, 0x00, 0x41, 0x52, 0x54, 0x00, 0x41, 0x52, 0x53, 0x54, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 
-0xA8, 0x80, 0x00, 0x00, 0x00, 0x00, 
+0x01, 0x02, 0x01, 0x02, 0x01, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
+0x03, 0x04, 0x02, 0x04, 0x03, 0x04, 0x03, 0x04, 0xFF, 0xFF, 0xC3, 0xD0, 0x00, 0x00, 0xFF, 0xFF, 
+0xC7, 0xC0, 0x00, 0x04, 0xFF, 0xFF, 0xD5, 0xD0, 0x01, 0x08, 0xFF, 0xFF, 0xE3, 0xE0, 0x01, 0x08, 
+0xFF, 0xFF, 0xD5, 0xD0, 0x00, 0x04, 0x43, 0x4D, 0x54, 0x00, 0x41, 0x52, 0x54, 0x00, 0x41, 0x52, 
+0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 
+0x40, 0x01, 0x12, 0xA8, 0x80, 0x00, 0x00, 0x00, 0x00, 
 
 /* America/Cambridge_Bay */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x43, 0x41, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
@@ -2541,7 +2470,7 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 /* America/Cordoba */
 0x50, 0x48, 0x50, 0x31, 0x00, 0x3F, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x12, 0xA2, 0x92, 0x8F, 0x30, 
+0x00, 0x00, 0x00, 0x3C, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x12, 0xA2, 0x92, 0x8F, 0x30, 
 0xB6, 0x7B, 0x52, 0x40, 0xB7, 0x1A, 0xC9, 0xB0, 0xB8, 0x1E, 0x8F, 0x40, 0xB8, 0xD4, 0x70, 0x30, 
 0xBA, 0x17, 0x7D, 0xC0, 0xBA, 0xB5, 0xA3, 0xB0, 0xBB, 0xF8, 0xB1, 0x40, 0xBC, 0x96, 0xD7, 0x30, 
 0xBD, 0xD9, 0xE4, 0xC0, 0xBE, 0x78, 0x0A, 0xB0, 0xBF, 0xBB, 0x18, 0x40, 0xC0, 0x5A, 0x8F, 0xB0, 
@@ -2556,34 +2485,16 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 0x24, 0x10, 0x94, 0xA0, 0x25, 0x37, 0xF2, 0xB0, 0x25, 0xF0, 0x76, 0xA0, 0x27, 0x21, 0x0F, 0x30, 
 0x27, 0xD0, 0x58, 0xA0, 0x29, 0x00, 0xFF, 0x40, 0x29, 0xB0, 0x3A, 0xA0, 0x2A, 0xE0, 0xD3, 0x30, 
 0x2B, 0x99, 0x57, 0x20, 0x37, 0xF6, 0xC6, 0xB0, 0x38, 0xBF, 0x2A, 0xB0, 0x47, 0x77, 0x09, 0xB0, 
-0x47, 0xDC, 0x7F, 0x20, 0x48, 0xFA, 0xA2, 0xB0, 0x49, 0xBC, 0x61, 0x20, 0x4A, 0xDA, 0x84, 0xB0, 
-0x4B, 0xA5, 0x7D, 0xA0, 0x4C, 0xBA, 0x66, 0xB0, 0x4D, 0x85, 0x5F, 0xA0, 0x4E, 0x9A, 0x48, 0xB0, 
-0x4F, 0x65, 0x41, 0xA0, 0x50, 0x83, 0x65, 0x30, 0x51, 0x45, 0x23, 0xA0, 0x52, 0x63, 0x47, 0x30, 
-0x53, 0x25, 0x05, 0xA0, 0x54, 0x43, 0x29, 0x30, 0x55, 0x04, 0xE7, 0xA0, 0x56, 0x23, 0x0B, 0x30, 
-0x56, 0xEE, 0x04, 0x20, 0x58, 0x02, 0xED, 0x30, 0x58, 0xCD, 0xE6, 0x20, 0x59, 0xE2, 0xCF, 0x30, 
-0x5A, 0xAD, 0xC8, 0x20, 0x5B, 0xCB, 0xEB, 0xB0, 0x5C, 0x8D, 0xAA, 0x20, 0x5D, 0xAB, 0xCD, 0xB0, 
-0x5E, 0x6D, 0x8C, 0x20, 0x5F, 0x8B, 0xAF, 0xB0, 0x60, 0x56, 0xA8, 0xA0, 0x61, 0x6B, 0x91, 0xB0, 
-0x62, 0x36, 0x8A, 0xA0, 0x63, 0x4B, 0x73, 0xB0, 0x64, 0x16, 0x6C, 0xA0, 0x65, 0x2B, 0x55, 0xB0, 
-0x65, 0xF6, 0x4E, 0xA0, 0x67, 0x14, 0x72, 0x30, 0x67, 0xD6, 0x30, 0xA0, 0x68, 0xF4, 0x54, 0x30, 
-0x69, 0xB6, 0x12, 0xA0, 0x6A, 0xD4, 0x36, 0x30, 0x6B, 0x9F, 0x2F, 0x20, 0x6C, 0xB4, 0x18, 0x30, 
-0x6D, 0x7F, 0x11, 0x20, 0x6E, 0x93, 0xFA, 0x30, 0x6F, 0x5E, 0xF3, 0x20, 0x70, 0x7D, 0x16, 0xB0, 
-0x71, 0x3E, 0xD5, 0x20, 0x72, 0x5C, 0xF8, 0xB0, 0x73, 0x1E, 0xB7, 0x20, 0x74, 0x3C, 0xDA, 0xB0, 
-0x75, 0x07, 0xD3, 0xA0, 0x76, 0x1C, 0xBC, 0xB0, 0x76, 0xE7, 0xB5, 0xA0, 0x77, 0xFC, 0x9E, 0xB0, 
-0x78, 0xC7, 0x97, 0xA0, 0x79, 0xDC, 0x80, 0xB0, 0x7A, 0xA7, 0x79, 0xA0, 0x7B, 0xC5, 0x9D, 0x30, 
-0x7C, 0x87, 0x5B, 0xA0, 0x7D, 0xA5, 0x7F, 0x30, 0x7E, 0x67, 0x3D, 0xA0, 0x7F, 0x85, 0x61, 0x30, 
+0x47, 0xDC, 0x7F, 0x20, 0x48, 0xFA, 0xA2, 0xB0, 0x49, 0xBC, 0x61, 0x20, 0x01, 0x02, 0x01, 0x02, 
 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
-0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x05, 0x03, 0x04, 0x03, 0x04, 0x02, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0xFF, 0xFF, 0xC3, 0xD0, 0x00, 0x00, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 
-0x04, 0xFF, 0xFF, 0xD5, 0xD0, 0x01, 0x08, 0xFF, 0xFF, 0xE3, 0xE0, 0x01, 0x08, 0xFF, 0xFF, 0xD5, 
-0xD0, 0x00, 0x04, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 0x0D, 0x43, 0x4D, 0x54, 0x00, 0x41, 0x52, 0x54, 
-0x00, 0x41, 0x52, 0x53, 0x54, 0x00, 0x57, 0x41, 0x52, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 0xA8, 0x80, 0x00, 
-0x00, 0x00, 0x00, 
+0x01, 0x02, 0x01, 0x02, 0x01, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x05, 0x03, 0x04, 
+0x03, 0x04, 0x02, 0x04, 0x03, 0x04, 0x03, 0x04, 0xFF, 0xFF, 0xC3, 0xD0, 0x00, 0x00, 0xFF, 0xFF, 
+0xC7, 0xC0, 0x00, 0x04, 0xFF, 0xFF, 0xD5, 0xD0, 0x01, 0x08, 0xFF, 0xFF, 0xE3, 0xE0, 0x01, 0x08, 
+0xFF, 0xFF, 0xD5, 0xD0, 0x00, 0x04, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 0x0D, 0x43, 0x4D, 0x54, 0x00, 
+0x41, 0x52, 0x54, 0x00, 0x41, 0x52, 0x53, 0x54, 0x00, 0x57, 0x41, 0x52, 0x54, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 
+0xA8, 0x80, 0x00, 0x00, 0x00, 0x00, 
 
 /* America/Costa_Rica */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x43, 0x52, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
@@ -5850,7 +5761,7 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 /* America/Rosario */
 0x50, 0x48, 0x50, 0x31, 0x00, 0x3F, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x12, 0xA2, 0x92, 0x8F, 0x30, 
+0x00, 0x00, 0x00, 0x3C, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x12, 0xA2, 0x92, 0x8F, 0x30, 
 0xB6, 0x7B, 0x52, 0x40, 0xB7, 0x1A, 0xC9, 0xB0, 0xB8, 0x1E, 0x8F, 0x40, 0xB8, 0xD4, 0x70, 0x30, 
 0xBA, 0x17, 0x7D, 0xC0, 0xBA, 0xB5, 0xA3, 0xB0, 0xBB, 0xF8, 0xB1, 0x40, 0xBC, 0x96, 0xD7, 0x30, 
 0xBD, 0xD9, 0xE4, 0xC0, 0xBE, 0x78, 0x0A, 0xB0, 0xBF, 0xBB, 0x18, 0x40, 0xC0, 0x5A, 0x8F, 0xB0, 
@@ -5865,34 +5776,16 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 0x24, 0x10, 0x94, 0xA0, 0x25, 0x37, 0xF2, 0xB0, 0x25, 0xF0, 0x76, 0xA0, 0x27, 0x21, 0x0F, 0x30, 
 0x27, 0xD0, 0x58, 0xA0, 0x29, 0x00, 0xFF, 0x40, 0x29, 0xB0, 0x3A, 0xA0, 0x2A, 0xE0, 0xD3, 0x30, 
 0x2B, 0x99, 0x57, 0x20, 0x37, 0xF6, 0xC6, 0xB0, 0x38, 0xBF, 0x2A, 0xB0, 0x47, 0x77, 0x09, 0xB0, 
-0x47, 0xDC, 0x7F, 0x20, 0x48, 0xFA, 0xA2, 0xB0, 0x49, 0xBC, 0x61, 0x20, 0x4A, 0xDA, 0x84, 0xB0, 
-0x4B, 0xA5, 0x7D, 0xA0, 0x4C, 0xBA, 0x66, 0xB0, 0x4D, 0x85, 0x5F, 0xA0, 0x4E, 0x9A, 0x48, 0xB0, 
-0x4F, 0x65, 0x41, 0xA0, 0x50, 0x83, 0x65, 0x30, 0x51, 0x45, 0x23, 0xA0, 0x52, 0x63, 0x47, 0x30, 
-0x53, 0x25, 0x05, 0xA0, 0x54, 0x43, 0x29, 0x30, 0x55, 0x04, 0xE7, 0xA0, 0x56, 0x23, 0x0B, 0x30, 
-0x56, 0xEE, 0x04, 0x20, 0x58, 0x02, 0xED, 0x30, 0x58, 0xCD, 0xE6, 0x20, 0x59, 0xE2, 0xCF, 0x30, 
-0x5A, 0xAD, 0xC8, 0x20, 0x5B, 0xCB, 0xEB, 0xB0, 0x5C, 0x8D, 0xAA, 0x20, 0x5D, 0xAB, 0xCD, 0xB0, 
-0x5E, 0x6D, 0x8C, 0x20, 0x5F, 0x8B, 0xAF, 0xB0, 0x60, 0x56, 0xA8, 0xA0, 0x61, 0x6B, 0x91, 0xB0, 
-0x62, 0x36, 0x8A, 0xA0, 0x63, 0x4B, 0x73, 0xB0, 0x64, 0x16, 0x6C, 0xA0, 0x65, 0x2B, 0x55, 0xB0, 
-0x65, 0xF6, 0x4E, 0xA0, 0x67, 0x14, 0x72, 0x30, 0x67, 0xD6, 0x30, 0xA0, 0x68, 0xF4, 0x54, 0x30, 
-0x69, 0xB6, 0x12, 0xA0, 0x6A, 0xD4, 0x36, 0x30, 0x6B, 0x9F, 0x2F, 0x20, 0x6C, 0xB4, 0x18, 0x30, 
-0x6D, 0x7F, 0x11, 0x20, 0x6E, 0x93, 0xFA, 0x30, 0x6F, 0x5E, 0xF3, 0x20, 0x70, 0x7D, 0x16, 0xB0, 
-0x71, 0x3E, 0xD5, 0x20, 0x72, 0x5C, 0xF8, 0xB0, 0x73, 0x1E, 0xB7, 0x20, 0x74, 0x3C, 0xDA, 0xB0, 
-0x75, 0x07, 0xD3, 0xA0, 0x76, 0x1C, 0xBC, 0xB0, 0x76, 0xE7, 0xB5, 0xA0, 0x77, 0xFC, 0x9E, 0xB0, 
-0x78, 0xC7, 0x97, 0xA0, 0x79, 0xDC, 0x80, 0xB0, 0x7A, 0xA7, 0x79, 0xA0, 0x7B, 0xC5, 0x9D, 0x30, 
-0x7C, 0x87, 0x5B, 0xA0, 0x7D, 0xA5, 0x7F, 0x30, 0x7E, 0x67, 0x3D, 0xA0, 0x7F, 0x85, 0x61, 0x30, 
+0x47, 0xDC, 0x7F, 0x20, 0x48, 0xFA, 0xA2, 0xB0, 0x49, 0xBC, 0x61, 0x20, 0x01, 0x02, 0x01, 0x02, 
 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 
-0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x05, 0x03, 0x04, 0x03, 0x04, 0x02, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 
-0x03, 0x04, 0x03, 0x04, 0x03, 0xFF, 0xFF, 0xC3, 0xD0, 0x00, 0x00, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 
-0x04, 0xFF, 0xFF, 0xD5, 0xD0, 0x01, 0x08, 0xFF, 0xFF, 0xE3, 0xE0, 0x01, 0x08, 0xFF, 0xFF, 0xD5, 
-0xD0, 0x00, 0x04, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 0x0D, 0x43, 0x4D, 0x54, 0x00, 0x41, 0x52, 0x54, 
-0x00, 0x41, 0x52, 0x53, 0x54, 0x00, 0x57, 0x41, 0x52, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 0xA8, 0x80, 0x00, 
-0x00, 0x00, 0x00, 
+0x01, 0x02, 0x01, 0x02, 0x01, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x04, 0x03, 0x05, 0x03, 0x04, 
+0x03, 0x04, 0x02, 0x04, 0x03, 0x04, 0x03, 0x04, 0xFF, 0xFF, 0xC3, 0xD0, 0x00, 0x00, 0xFF, 0xFF, 
+0xC7, 0xC0, 0x00, 0x04, 0xFF, 0xFF, 0xD5, 0xD0, 0x01, 0x08, 0xFF, 0xFF, 0xE3, 0xE0, 0x01, 0x08, 
+0xFF, 0xFF, 0xD5, 0xD0, 0x00, 0x04, 0xFF, 0xFF, 0xC7, 0xC0, 0x00, 0x0D, 0x43, 0x4D, 0x54, 0x00, 
+0x41, 0x52, 0x54, 0x00, 0x41, 0x52, 0x53, 0x54, 0x00, 0x57, 0x41, 0x52, 0x54, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 
+0xA8, 0x80, 0x00, 0x00, 0x00, 0x00, 
 
 /* America/Santarem */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x42, 0x52, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
@@ -6863,23 +6756,25 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 
 /* Antarctica/Casey */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x51, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x08, 0xFE, 0x1E, 0xCC, 0x80, 
-0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x80, 0x00, 0x04, 0x7A, 0x7A, 0x7A, 
-0x00, 0x57, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x24, 0x30, 0x52, 0x01, 0xBB, 0x4B, 
-0x12, 0x00, 0x00, 0x00, 0x1F, 0x43, 0x61, 0x73, 0x65, 0x79, 0x20, 0x53, 0x74, 0x61, 0x74, 0x69, 
-0x6F, 0x6E, 0x2C, 0x20, 0x42, 0x61, 0x69, 0x6C, 0x65, 0x79, 0x20, 0x50, 0x65, 0x6E, 0x69, 0x6E, 
-0x73, 0x75, 0x6C, 0x61, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0D, 0xFE, 0x1E, 0xCC, 0x80, 
+0x4A, 0xDA, 0x06, 0x20, 0x01, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x70, 0x80, 
+0x00, 0x04, 0x00, 0x00, 0x9A, 0xB0, 0x00, 0x08, 0x7A, 0x7A, 0x7A, 0x00, 0x57, 0x53, 0x54, 0x00, 
+0x43, 0x41, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x24, 0x30, 0x52, 0x01, 
+0xBB, 0x4B, 0x12, 0x00, 0x00, 0x00, 0x1F, 0x43, 0x61, 0x73, 0x65, 0x79, 0x20, 0x53, 0x74, 0x61, 
+0x74, 0x69, 0x6F, 0x6E, 0x2C, 0x20, 0x42, 0x61, 0x69, 0x6C, 0x65, 0x79, 0x20, 0x50, 0x65, 0x6E, 
+0x69, 0x6E, 0x73, 0x75, 0x6C, 0x61, 
 
 /* Antarctica/Davis */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x51, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x09, 0xE7, 0x9C, 0x40, 0x00, 
-0xF6, 0x47, 0xDF, 0x10, 0xFE, 0x47, 0xAB, 0x00, 0x01, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x62, 0x70, 0x00, 0x04, 0x7A, 0x7A, 0x7A, 0x00, 0x44, 0x41, 0x56, 0x54, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0xAD, 0xE2, 0x01, 0x89, 0xA0, 0x3A, 0x00, 0x00, 0x00, 0x1D, 
-0x44, 0x61, 0x76, 0x69, 0x73, 0x20, 0x53, 0x74, 0x61, 0x74, 0x69, 0x6F, 0x6E, 0x2C, 0x20, 0x56, 
-0x65, 0x73, 0x74, 0x66, 0x6F, 0x6C, 0x64, 0x20, 0x48, 0x69, 0x6C, 0x6C, 0x73, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x09, 0xE7, 0x9C, 0x40, 0x00, 
+0xF6, 0x47, 0xDF, 0x10, 0xFE, 0x47, 0xAB, 0x00, 0x4A, 0xDA, 0x14, 0x30, 0x01, 0x00, 0x01, 0x02, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x62, 0x70, 0x00, 0x04, 0x00, 0x00, 0x46, 0x50, 
+0x00, 0x04, 0x7A, 0x7A, 0x7A, 0x00, 0x44, 0x41, 0x56, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x20, 0xAD, 0xE2, 0x01, 0x89, 0xA0, 0x3A, 0x00, 0x00, 0x00, 0x1D, 0x44, 0x61, 0x76, 
+0x69, 0x73, 0x20, 0x53, 0x74, 0x61, 0x74, 0x69, 0x6F, 0x6E, 0x2C, 0x20, 0x56, 0x65, 0x73, 0x74, 
+0x66, 0x6F, 0x6C, 0x64, 0x20, 0x48, 0x69, 0x6C, 0x6C, 0x73, 
 
 /* Antarctica/DumontDUrville */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x51, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
@@ -6895,12 +6790,13 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 
 /* Antarctica/Mawson */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x51, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x09, 0xE2, 0x20, 0x32, 0x80, 
-0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x54, 0x60, 0x00, 0x04, 0x7A, 0x7A, 0x7A, 
-0x00, 0x4D, 0x41, 0x57, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x22, 0x2E, 0x00, 0x01, 0x72, 
-0x9C, 0x4D, 0x00, 0x00, 0x00, 0x19, 0x4D, 0x61, 0x77, 0x73, 0x6F, 0x6E, 0x20, 0x53, 0x74, 0x61, 
-0x74, 0x69, 0x6F, 0x6E, 0x2C, 0x20, 0x48, 0x6F, 0x6C, 0x6D, 0x65, 0x20, 0x42, 0x61, 0x79, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x09, 0xE2, 0x20, 0x32, 0x80, 
+0x4A, 0xDA, 0x22, 0x40, 0x01, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x54, 0x60, 
+0x00, 0x04, 0x00, 0x00, 0x46, 0x50, 0x00, 0x04, 0x7A, 0x7A, 0x7A, 0x00, 0x4D, 0x41, 0x57, 0x54, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x22, 0x2E, 0x00, 0x01, 0x72, 0x9C, 0x4D, 0x00, 
+0x00, 0x00, 0x19, 0x4D, 0x61, 0x77, 0x73, 0x6F, 0x6E, 0x20, 0x53, 0x74, 0x61, 0x74, 0x69, 0x6F, 
+0x6E, 0x2C, 0x20, 0x48, 0x6F, 0x6C, 0x6D, 0x65, 0x20, 0x42, 0x61, 0x79, 
 
 /* Antarctica/McMurdo */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x41, 0x51, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
@@ -7635,15 +7531,15 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 /* Asia/Dacca */
 0x50, 0x48, 0x50, 0x31, 0x00, 0x3F, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x1B, 0xCA, 0xDB, 0x86, 0xB0, 
+0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x1B, 0xCA, 0xDB, 0x86, 0xB0, 
 0xCC, 0x05, 0x71, 0x18, 0xCC, 0x95, 0x32, 0xA8, 0xDD, 0xA8, 0xD2, 0x98, 0x02, 0x4F, 0x9D, 0x20, 
-0x4A, 0x3B, 0xC4, 0x10, 0x4B, 0x3C, 0xD8, 0x90, 0x01, 0x02, 0x01, 0x03, 0x04, 0x05, 0x04, 0x00, 
-0x00, 0x52, 0xD0, 0x00, 0x00, 0x00, 0x00, 0x5B, 0x68, 0x00, 0x04, 0x00, 0x00, 0x4D, 0x58, 0x00, 
-0x09, 0x00, 0x00, 0x54, 0x60, 0x00, 0x0D, 0x00, 0x00, 0x54, 0x60, 0x00, 0x12, 0x00, 0x00, 0x62, 
-0x70, 0x01, 0x16, 0x48, 0x4D, 0x54, 0x00, 0x42, 0x55, 0x52, 0x54, 0x00, 0x49, 0x53, 0x54, 0x00, 
-0x44, 0x41, 0x43, 0x54, 0x00, 0x42, 0x44, 0x54, 0x00, 0x42, 0x44, 0x53, 0x54, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 
-0xA8, 0x80, 0x00, 0x00, 0x00, 0x00, 
+0x4A, 0x3B, 0xC4, 0x10, 0x01, 0x02, 0x01, 0x03, 0x04, 0x05, 0x00, 0x00, 0x52, 0xD0, 0x00, 0x00, 
+0x00, 0x00, 0x5B, 0x68, 0x00, 0x04, 0x00, 0x00, 0x4D, 0x58, 0x00, 0x09, 0x00, 0x00, 0x54, 0x60, 
+0x00, 0x0D, 0x00, 0x00, 0x54, 0x60, 0x00, 0x12, 0x00, 0x00, 0x62, 0x70, 0x01, 0x16, 0x48, 0x4D, 
+0x54, 0x00, 0x42, 0x55, 0x52, 0x54, 0x00, 0x49, 0x53, 0x54, 0x00, 0x44, 0x41, 0x43, 0x54, 0x00, 
+0x42, 0x44, 0x54, 0x00, 0x42, 0x44, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 0xA8, 0x80, 0x00, 0x00, 0x00, 
+0x00, 
 
 /* Asia/Damascus */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x53, 0x59, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
@@ -7672,21 +7568,21 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 0x3E, 0x88, 0xBA, 0x60, 0x3F, 0x79, 0xEE, 0xD0, 0x40, 0x6B, 0x3F, 0x60, 0x41, 0x5C, 0x73, 0xD0, 
 0x42, 0x4C, 0x72, 0xE0, 0x43, 0x3D, 0xA7, 0x50, 0x44, 0x2D, 0xA6, 0x60, 0x45, 0x12, 0xFD, 0x50, 
 0x46, 0x0C, 0x36, 0xE0, 0x47, 0x2A, 0x3E, 0x50, 0x47, 0xF5, 0x53, 0x60, 0x49, 0x0B, 0x71, 0xD0, 
-0x49, 0xCB, 0xFA, 0xE0, 0x4A, 0xEC, 0xA5, 0x50, 0x4B, 0xAB, 0xDC, 0xE0, 0x4C, 0xCD, 0xD8, 0xD0, 
-0x4D, 0x8B, 0xBE, 0xE0, 0x4E, 0xAF, 0x0C, 0x50, 0x4F, 0x74, 0xDB, 0x60, 0x50, 0x91, 0x91, 0x50, 
-0x51, 0x54, 0xBD, 0x60, 0x52, 0x72, 0xC4, 0xD0, 0x53, 0x34, 0x9F, 0x60, 0x54, 0x53, 0xF8, 0x50, 
-0x55, 0x14, 0x81, 0x60, 0x56, 0x35, 0x2B, 0xD0, 0x56, 0xF4, 0x63, 0x60, 0x58, 0x17, 0xB0, 0xD0, 
-0x58, 0xDD, 0x7F, 0xE0, 0x59, 0xF8, 0xE4, 0x50, 0x5A, 0xBD, 0x61, 0xE0, 0x5B, 0xDA, 0x17, 0xD0, 
-0x5C, 0x9D, 0x43, 0xE0, 0x5D, 0xBB, 0x4B, 0x50, 0x5E, 0x7D, 0x25, 0xE0, 0x5F, 0x9D, 0xD0, 0x50, 
-0x60, 0x5D, 0x07, 0xE0, 0x61, 0x7F, 0x03, 0xD0, 0x62, 0x3C, 0xE9, 0xE0, 0x63, 0x60, 0x37, 0x50, 
-0x64, 0x26, 0x06, 0x60, 0x65, 0x41, 0x6A, 0xD0, 0x66, 0x05, 0xE8, 0x60, 0x67, 0x23, 0xEF, 0xD0, 
-0x67, 0xE5, 0xCA, 0x60, 0x69, 0x05, 0x23, 0x50, 0x69, 0xC5, 0xAC, 0x60, 0x6A, 0xE6, 0x56, 0xD0, 
-0x6B, 0xA5, 0x8E, 0x60, 0x6C, 0xC7, 0x8A, 0x50, 0x6D, 0x8E, 0xAA, 0xE0, 0x6E, 0xAA, 0x0F, 0x50, 
-0x6F, 0x6E, 0x8C, 0xE0, 0x70, 0x8B, 0x42, 0xD0, 0x71, 0x4E, 0x6E, 0xE0, 0x72, 0x6C, 0x76, 0x50, 
-0x73, 0x2E, 0x50, 0xE0, 0x74, 0x4D, 0xA9, 0xD0, 0x75, 0x0E, 0x32, 0xE0, 0x76, 0x30, 0x2E, 0xD0, 
-0x76, 0xEE, 0x14, 0xE0, 0x78, 0x11, 0x62, 0x50, 0x78, 0xD7, 0x31, 0x60, 0x79, 0xF2, 0x95, 0xD0, 
-0x7A, 0xB7, 0x13, 0x60, 0x7B, 0xD3, 0xC9, 0x50, 0x7C, 0x96, 0xF5, 0x60, 0x7D, 0xB6, 0x4E, 0x50, 
-0x7E, 0x76, 0xD7, 0x60, 0x7F, 0x97, 0x81, 0xD0, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 
+0x49, 0xCB, 0xFA, 0xE0, 0x4A, 0xEA, 0x02, 0x50, 0x4B, 0xAB, 0xDC, 0xE0, 0x4C, 0xC9, 0xE4, 0x50, 
+0x4D, 0x8B, 0xBE, 0xE0, 0x4E, 0xA9, 0xC6, 0x50, 0x4F, 0x74, 0xDB, 0x60, 0x50, 0x89, 0xA8, 0x50, 
+0x51, 0x54, 0xBD, 0x60, 0x52, 0x69, 0x8A, 0x50, 0x53, 0x34, 0x9F, 0x60, 0x54, 0x52, 0xA6, 0xD0, 
+0x55, 0x14, 0x81, 0x60, 0x56, 0x32, 0x88, 0xD0, 0x56, 0xF4, 0x63, 0x60, 0x58, 0x12, 0x6A, 0xD0, 
+0x58, 0xDD, 0x7F, 0xE0, 0x59, 0xF2, 0x4C, 0xD0, 0x5A, 0xBD, 0x61, 0xE0, 0x5B, 0xD2, 0x2E, 0xD0, 
+0x5C, 0x9D, 0x43, 0xE0, 0x5D, 0xB2, 0x10, 0xD0, 0x5E, 0x7D, 0x25, 0xE0, 0x5F, 0x9B, 0x2D, 0x50, 
+0x60, 0x5D, 0x07, 0xE0, 0x61, 0x7B, 0x0F, 0x50, 0x62, 0x3C, 0xE9, 0xE0, 0x63, 0x5A, 0xF1, 0x50, 
+0x64, 0x26, 0x06, 0x60, 0x65, 0x3A, 0xD3, 0x50, 0x66, 0x05, 0xE8, 0x60, 0x67, 0x1A, 0xB5, 0x50, 
+0x67, 0xE5, 0xCA, 0x60, 0x69, 0x03, 0xD1, 0xD0, 0x69, 0xC5, 0xAC, 0x60, 0x6A, 0xE3, 0xB3, 0xD0, 
+0x6B, 0xA5, 0x8E, 0x60, 0x6C, 0xC3, 0x95, 0xD0, 0x6D, 0x8E, 0xAA, 0xE0, 0x6E, 0xA3, 0x77, 0xD0, 
+0x6F, 0x6E, 0x8C, 0xE0, 0x70, 0x83, 0x59, 0xD0, 0x71, 0x4E, 0x6E, 0xE0, 0x72, 0x63, 0x3B, 0xD0, 
+0x73, 0x2E, 0x50, 0xE0, 0x74, 0x4C, 0x58, 0x50, 0x75, 0x0E, 0x32, 0xE0, 0x76, 0x2C, 0x3A, 0x50, 
+0x76, 0xEE, 0x14, 0xE0, 0x78, 0x0C, 0x1C, 0x50, 0x78, 0xD7, 0x31, 0x60, 0x79, 0xEB, 0xFE, 0x50, 
+0x7A, 0xB7, 0x13, 0x60, 0x7B, 0xCB, 0xE0, 0x50, 0x7C, 0x96, 0xF5, 0x60, 0x7D, 0xB4, 0xFC, 0xD0, 
+0x7E, 0x76, 0xD7, 0x60, 0x7F, 0x94, 0xDE, 0xD0, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 
 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 
 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 
 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 
@@ -7704,15 +7600,15 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 /* Asia/Dhaka */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x42, 0x44, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x1B, 0xCA, 0xDB, 0x86, 0xB0, 
+0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x1B, 0xCA, 0xDB, 0x86, 0xB0, 
 0xCC, 0x05, 0x71, 0x18, 0xCC, 0x95, 0x32, 0xA8, 0xDD, 0xA8, 0xD2, 0x98, 0x02, 0x4F, 0x9D, 0x20, 
-0x4A, 0x3B, 0xC4, 0x10, 0x4B, 0x3C, 0xD8, 0x90, 0x01, 0x02, 0x01, 0x03, 0x04, 0x05, 0x04, 0x00, 
-0x00, 0x52, 0xD0, 0x00, 0x00, 0x00, 0x00, 0x5B, 0x68, 0x00, 0x04, 0x00, 0x00, 0x4D, 0x58, 0x00, 
-0x09, 0x00, 0x00, 0x54, 0x60, 0x00, 0x0D, 0x00, 0x00, 0x54, 0x60, 0x00, 0x12, 0x00, 0x00, 0x62, 
-0x70, 0x01, 0x16, 0x48, 0x4D, 0x54, 0x00, 0x42, 0x55, 0x52, 0x54, 0x00, 0x49, 0x53, 0x54, 0x00, 
-0x44, 0x41, 0x43, 0x54, 0x00, 0x42, 0x44, 0x54, 0x00, 0x42, 0x44, 0x53, 0x54, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xAD, 0x84, 0x92, 0x01, 0x9C, 
-0x9F, 0x82, 0x00, 0x00, 0x00, 0x00, 
+0x4A, 0x3B, 0xC4, 0x10, 0x01, 0x02, 0x01, 0x03, 0x04, 0x05, 0x00, 0x00, 0x52, 0xD0, 0x00, 0x00, 
+0x00, 0x00, 0x5B, 0x68, 0x00, 0x04, 0x00, 0x00, 0x4D, 0x58, 0x00, 0x09, 0x00, 0x00, 0x54, 0x60, 
+0x00, 0x0D, 0x00, 0x00, 0x54, 0x60, 0x00, 0x12, 0x00, 0x00, 0x62, 0x70, 0x01, 0x16, 0x48, 0x4D, 
+0x54, 0x00, 0x42, 0x55, 0x52, 0x54, 0x00, 0x49, 0x53, 0x54, 0x00, 0x44, 0x41, 0x43, 0x54, 0x00, 
+0x42, 0x44, 0x54, 0x00, 0x42, 0x44, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xAD, 0x84, 0x92, 0x01, 0x9C, 0x9F, 0x82, 0x00, 0x00, 0x00, 
+0x00, 
 
 /* Asia/Dili */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x54, 0x4C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
@@ -7836,12 +7732,13 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 
 /* Asia/Hong_Kong */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x48, 0x4B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x45, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0D, 0x85, 0x69, 0x5A, 0xFC, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x47, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x85, 0x69, 0x5A, 0xFC, 
+0xC9, 0xEA, 0x57, 0xB8, 0xCA, 0xDA, 0x3A, 0xA8, 0xCB, 0x4B, 0x78, 0x80, 0xD2, 0x4C, 0x62, 0x70, 
 0xD3, 0x6A, 0xB7, 0x38, 0xD4, 0x93, 0x4A, 0xA8, 0xD5, 0x42, 0xB0, 0x38, 0xD6, 0x9A, 0xB9, 0xA8, 
 0xD7, 0x3E, 0x41, 0xB8, 0xD8, 0x2E, 0x24, 0xA8, 0xD8, 0xF9, 0x39, 0xB8, 0xDA, 0x0E, 0x06, 0xA8, 
 0xDA, 0xD9, 0x1B, 0xB8, 0xDB, 0xED, 0xE8, 0xA8, 0xDC, 0xB8, 0xFD, 0xB8, 0xDD, 0xCD, 0xCA, 0xA8, 
-0xDE, 0xA2, 0x1A, 0x38, 0xDF, 0xAD, 0xAC, 0xA8, 0xE0, 0x81, 0xFC, 0x38, 0xE1, 0x96, 0xC9, 0x28, 
+0xDE, 0xA2, 0x1A, 0x38, 0xDF, 0xAC, 0x5B, 0x28, 0xE0, 0x81, 0xFC, 0x38, 0xE1, 0x96, 0xC9, 0x28, 
 0xE2, 0x4F, 0x69, 0x38, 0xE3, 0x76, 0xAB, 0x28, 0xE4, 0x2F, 0x4B, 0x38, 0xE5, 0x5F, 0xC7, 0xA8, 
 0xE6, 0x0F, 0x2D, 0x38, 0xE7, 0x3F, 0xA9, 0xA8, 0xE7, 0xF8, 0x49, 0xB8, 0xE9, 0x1F, 0x8B, 0xA8, 
 0xE9, 0xD8, 0x2B, 0xB8, 0xEA, 0xFF, 0x6D, 0xA8, 0xEB, 0xB8, 0x0D, 0xB8, 0xEC, 0xDF, 0x4F, 0xA8, 
@@ -7852,17 +7749,17 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 0xFC, 0xCE, 0x5E, 0xB8, 0xFD, 0xBE, 0x41, 0xA8, 0xFE, 0xAE, 0x40, 0xB8, 0xFF, 0x9E, 0x23, 0xA8, 
 0x00, 0x8E, 0x22, 0xB8, 0x01, 0x7E, 0x05, 0xA8, 0x02, 0x6E, 0x04, 0xB8, 0x03, 0x5D, 0xE7, 0xA8, 
 0x04, 0x4D, 0xE6, 0xB8, 0x05, 0x47, 0x04, 0x28, 0x06, 0x37, 0x03, 0x38, 0x07, 0x26, 0xE6, 0x28, 
-0x08, 0x16, 0xE5, 0x38, 0x09, 0x06, 0xC8, 0x28, 0x09, 0xF6, 0xC7, 0x38, 0x0A, 0xE6, 0xAA, 0x28, 
+0x07, 0x83, 0x3D, 0x38, 0x09, 0x06, 0xC8, 0x28, 0x09, 0xF6, 0xC7, 0x38, 0x0A, 0xE6, 0xAA, 0x28, 
 0x0B, 0xD6, 0xA9, 0x38, 0x0C, 0xC6, 0x8C, 0x28, 0x0D, 0xB6, 0x8B, 0x38, 0x0E, 0xA6, 0x6E, 0x28, 
-0x11, 0x9B, 0x39, 0x38, 0x12, 0x6F, 0x6C, 0xA8, 0x13, 0x7B, 0x1B, 0x38, 0x14, 0x4F, 0x4E, 0xA8, 
+0x11, 0x9B, 0x39, 0x38, 0x12, 0x6F, 0x6C, 0xA8, 0x02, 0x01, 0x02, 0x03, 0x02, 0x01, 0x02, 0x01, 
 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 
 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 
 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 
-0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 
-0x02, 0x01, 0x02, 0x01, 0x02, 0x00, 0x00, 0x6B, 0x04, 0x00, 0x00, 0x00, 0x00, 0x7E, 0x90, 0x01, 
-0x04, 0x00, 0x00, 0x70, 0x80, 0x00, 0x09, 0x4C, 0x4D, 0x54, 0x00, 0x48, 0x4B, 0x53, 0x54, 0x00, 
-0x48, 0x4B, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xAB, 0x54, 0xAD, 0x01, 0xC0, 
-0xD6, 0x57, 0x00, 0x00, 0x00, 0x00, 
+0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x00, 
+0x00, 0x6B, 0x04, 0x00, 0x00, 0x00, 0x00, 0x7E, 0x90, 0x01, 0x04, 0x00, 0x00, 0x70, 0x80, 0x00, 
+0x09, 0x00, 0x00, 0x7E, 0x90, 0x00, 0x0D, 0x4C, 0x4D, 0x54, 0x00, 0x48, 0x4B, 0x53, 0x54, 0x00, 
+0x48, 0x4B, 0x54, 0x00, 0x4A, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0xAB, 0x54, 0xAD, 0x01, 0xC0, 0xD6, 0x57, 0x00, 0x00, 0x00, 0x00, 
 
 /* Asia/Hovd */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x4D, 0x4E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
@@ -8141,16 +8038,33 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 /* Asia/Karachi */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x50, 0x4B, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x0B, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x16, 0x89, 0x7E, 0xFC, 0xA4, 
+0x00, 0x00, 0x00, 0x43, 0x00, 0x00, 0x00, 0x06, 0x00, 0x00, 0x00, 0x16, 0x89, 0x7E, 0xFC, 0xA4, 
 0xCC, 0x95, 0x32, 0xA8, 0xD2, 0x74, 0x12, 0x98, 0xDD, 0xA8, 0xE0, 0xA8, 0x02, 0x4F, 0xAB, 0x30, 
 0x3C, 0xAF, 0x45, 0xEC, 0x3D, 0x9F, 0x28, 0xDC, 0x48, 0x41, 0xA0, 0x30, 0x49, 0x0B, 0x47, 0xA0, 
-0x49, 0xE4, 0xDD, 0x30, 0x4A, 0xEC, 0x7B, 0x20, 0x01, 0x02, 0x01, 0x03, 0x05, 0x04, 0x05, 0x04, 
-0x05, 0x04, 0x05, 0x00, 0x00, 0x3E, 0xDC, 0x00, 0x00, 0x00, 0x00, 0x4D, 0x58, 0x00, 0x04, 0x00, 
-0x00, 0x5B, 0x68, 0x01, 0x04, 0x00, 0x00, 0x46, 0x50, 0x00, 0x08, 0x00, 0x00, 0x54, 0x60, 0x01, 
-0x0D, 0x00, 0x00, 0x46, 0x50, 0x00, 0x12, 0x4C, 0x4D, 0x54, 0x00, 0x49, 0x53, 0x54, 0x00, 0x4B, 
-0x41, 0x52, 0x54, 0x00, 0x50, 0x4B, 0x53, 0x54, 0x00, 0x50, 0x4B, 0x54, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xAF, 0x45, 0xCA, 0x01, 0x78, 0xF7, 
-0xE8, 0x00, 0x00, 0x00, 0x00, 
+0x49, 0xE4, 0xDD, 0x30, 0x4A, 0xEC, 0x7B, 0x20, 0x4B, 0xC6, 0x10, 0xB0, 0x4C, 0xCD, 0xAE, 0xA0, 
+0x4D, 0xA7, 0x44, 0x30, 0x4E, 0xAE, 0xE2, 0x20, 0x4F, 0x89, 0xC9, 0x30, 0x50, 0x91, 0x67, 0x20, 
+0x51, 0x6A, 0xFC, 0xB0, 0x52, 0x72, 0x9A, 0xA0, 0x53, 0x4C, 0x30, 0x30, 0x54, 0x53, 0xCE, 0x20, 
+0x55, 0x2D, 0x63, 0xB0, 0x56, 0x35, 0x01, 0xA0, 0x57, 0x0F, 0xE8, 0xB0, 0x58, 0x17, 0x86, 0xA0, 
+0x58, 0xF1, 0x1C, 0x30, 0x59, 0xF8, 0xBA, 0x20, 0x5A, 0xD2, 0x4F, 0xB0, 0x5B, 0xD9, 0xED, 0xA0, 
+0x5C, 0xB3, 0x83, 0x30, 0x5D, 0xBB, 0x21, 0x20, 0x5E, 0x96, 0x08, 0x30, 0x5F, 0x9D, 0xA6, 0x20, 
+0x60, 0x77, 0x3B, 0xB0, 0x61, 0x7E, 0xD9, 0xA0, 0x62, 0x58, 0x6F, 0x30, 0x63, 0x60, 0x0D, 0x20, 
+0x64, 0x39, 0xA2, 0xB0, 0x65, 0x41, 0x40, 0xA0, 0x66, 0x1C, 0x27, 0xB0, 0x67, 0x23, 0xC5, 0xA0, 
+0x67, 0xFD, 0x5B, 0x30, 0x69, 0x04, 0xF9, 0x20, 0x69, 0xDE, 0x8E, 0xB0, 0x6A, 0xE6, 0x2C, 0xA0, 
+0x6B, 0xBF, 0xC2, 0x30, 0x6C, 0xC7, 0x60, 0x20, 0x6D, 0xA2, 0x47, 0x30, 0x6E, 0xA9, 0xE5, 0x20, 
+0x6F, 0x83, 0x7A, 0xB0, 0x70, 0x8B, 0x18, 0xA0, 0x71, 0x64, 0xAE, 0x30, 0x72, 0x6C, 0x4C, 0x20, 
+0x73, 0x45, 0xE1, 0xB0, 0x74, 0x4D, 0x7F, 0xA0, 0x75, 0x28, 0x66, 0xB0, 0x76, 0x30, 0x04, 0xA0, 
+0x77, 0x09, 0x9A, 0x30, 0x78, 0x11, 0x38, 0x20, 0x78, 0xEA, 0xCD, 0xB0, 0x79, 0xF2, 0x6B, 0xA0, 
+0x7A, 0xCC, 0x01, 0x30, 0x7B, 0xD3, 0x9F, 0x20, 0x7C, 0xAE, 0x86, 0x30, 0x7D, 0xB6, 0x24, 0x20, 
+0x7E, 0x8F, 0xB9, 0xB0, 0x7F, 0x97, 0x57, 0xA0, 0x01, 0x02, 0x01, 0x03, 0x05, 0x04, 0x05, 0x04, 
+0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 
+0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 
+0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 
+0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x00, 0x00, 0x3E, 0xDC, 0x00, 
+0x00, 0x00, 0x00, 0x4D, 0x58, 0x00, 0x04, 0x00, 0x00, 0x5B, 0x68, 0x01, 0x04, 0x00, 0x00, 0x46, 
+0x50, 0x00, 0x08, 0x00, 0x00, 0x54, 0x60, 0x01, 0x0D, 0x00, 0x00, 0x46, 0x50, 0x00, 0x12, 0x4C, 
+0x4D, 0x54, 0x00, 0x49, 0x53, 0x54, 0x00, 0x4B, 0x41, 0x52, 0x54, 0x00, 0x50, 0x4B, 0x53, 0x54, 
+0x00, 0x50, 0x4B, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0xAF, 0x45, 0xCA, 0x01, 0x78, 0xF7, 0xE8, 0x00, 0x00, 0x00, 0x00, 
 
 /* Asia/Kashgar */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x43, 0x4E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
@@ -8459,6 +8373,57 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 0x54, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0xBE, 0xFD, 0x3A, 
 0x01, 0x45, 0x92, 0x5A, 0x00, 0x00, 0x00, 0x00, 
 
+/* Asia/Novokuznetsk */
+0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0A, 0x00, 0x00, 0x00, 0x0A, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x75, 0x00, 0x00, 0x00, 0x0A, 0x00, 0x00, 0x00, 0x1A, 0xA1, 0xF9, 0x13, 0x40, 
+0xB5, 0xA3, 0xE1, 0x20, 0x15, 0x27, 0x6F, 0x90, 0x16, 0x18, 0xA4, 0x00, 0x17, 0x08, 0xA3, 0x10, 
+0x17, 0xF9, 0xD7, 0x80, 0x18, 0xE9, 0xD6, 0x90, 0x19, 0xDB, 0x0B, 0x00, 0x1A, 0xCC, 0x5B, 0x90, 
+0x1B, 0xBC, 0x68, 0xB0, 0x1C, 0xAC, 0x59, 0xB0, 0x1D, 0x9C, 0x4A, 0xB0, 0x1E, 0x8C, 0x3B, 0xB0, 
+0x1F, 0x7C, 0x2C, 0xB0, 0x20, 0x6C, 0x1D, 0xB0, 0x21, 0x5C, 0x0E, 0xB0, 0x22, 0x4B, 0xFF, 0xB0, 
+0x23, 0x3B, 0xF0, 0xB0, 0x24, 0x2B, 0xE1, 0xB0, 0x25, 0x1B, 0xD2, 0xB0, 0x26, 0x0B, 0xC3, 0xB0, 
+0x27, 0x04, 0xEF, 0x30, 0x27, 0xF4, 0xE0, 0x30, 0x28, 0xE4, 0xDF, 0x40, 0x29, 0x78, 0x87, 0x40, 
+0x29, 0xD4, 0x98, 0x00, 0x2A, 0xC4, 0x7A, 0xF0, 0x2B, 0xB4, 0xA4, 0x30, 0x2C, 0xA4, 0x95, 0x30, 
+0x2D, 0x94, 0x86, 0x30, 0x2E, 0x84, 0x77, 0x30, 0x2F, 0x74, 0x68, 0x30, 0x30, 0x64, 0x59, 0x30, 
+0x31, 0x5D, 0x84, 0xB0, 0x32, 0x72, 0x5F, 0xB0, 0x33, 0x3D, 0x66, 0xB0, 0x34, 0x52, 0x41, 0xB0, 
+0x35, 0x1D, 0x48, 0xB0, 0x36, 0x32, 0x23, 0xB0, 0x36, 0xFD, 0x2A, 0xB0, 0x38, 0x1B, 0x40, 0x30, 
+0x38, 0xDD, 0x0C, 0xB0, 0x39, 0xFB, 0x22, 0x30, 0x3A, 0xBC, 0xEE, 0xB0, 0x3B, 0xDB, 0x04, 0x30, 
+0x3C, 0xA6, 0x0B, 0x30, 0x3D, 0xBA, 0xE6, 0x30, 0x3E, 0x85, 0xED, 0x30, 0x3F, 0x9A, 0xC8, 0x30, 
+0x40, 0x65, 0xCF, 0x30, 0x41, 0x83, 0xE4, 0xB0, 0x42, 0x45, 0xB1, 0x30, 0x43, 0x63, 0xC6, 0xB0, 
+0x44, 0x25, 0x93, 0x30, 0x45, 0x43, 0xA8, 0xB0, 0x46, 0x05, 0x75, 0x30, 0x47, 0x23, 0x8A, 0xB0, 
+0x47, 0xEE, 0x91, 0xB0, 0x49, 0x03, 0x6C, 0xB0, 0x49, 0xCE, 0x73, 0xB0, 0x4A, 0xE3, 0x4E, 0xB0, 
+0x4B, 0xAE, 0x55, 0xB0, 0x4C, 0xCC, 0x79, 0x40, 0x4D, 0x8E, 0x45, 0xC0, 0x4E, 0xAC, 0x5B, 0x40, 
+0x4F, 0x6E, 0x27, 0xC0, 0x50, 0x8C, 0x3D, 0x40, 0x51, 0x57, 0x44, 0x40, 0x52, 0x6C, 0x1F, 0x40, 
+0x53, 0x37, 0x26, 0x40, 0x54, 0x4C, 0x01, 0x40, 0x55, 0x17, 0x08, 0x40, 0x56, 0x2B, 0xE3, 0x40, 
+0x56, 0xF6, 0xEA, 0x40, 0x58, 0x14, 0xFF, 0xC0, 0x58, 0xD6, 0xCC, 0x40, 0x59, 0xF4, 0xE1, 0xC0, 
+0x5A, 0xB6, 0xAE, 0x40, 0x5B, 0xD4, 0xC3, 0xC0, 0x5C, 0x9F, 0xCA, 0xC0, 0x5D, 0xB4, 0xA5, 0xC0, 
+0x5E, 0x7F, 0xAC, 0xC0, 0x5F, 0x94, 0x87, 0xC0, 0x60, 0x5F, 0x8E, 0xC0, 0x61, 0x7D, 0xA4, 0x40, 
+0x62, 0x3F, 0x70, 0xC0, 0x63, 0x5D, 0x86, 0x40, 0x64, 0x1F, 0x52, 0xC0, 0x65, 0x3D, 0x68, 0x40, 
+0x66, 0x08, 0x6F, 0x40, 0x67, 0x1D, 0x4A, 0x40, 0x67, 0xE8, 0x51, 0x40, 0x68, 0xFD, 0x2C, 0x40, 
+0x69, 0xC8, 0x33, 0x40, 0x6A, 0xDD, 0x0E, 0x40, 0x6B, 0xA8, 0x15, 0x40, 0x6C, 0xC6, 0x2A, 0xC0, 
+0x6D, 0x87, 0xF7, 0x40, 0x6E, 0xA6, 0x0C, 0xC0, 0x6F, 0x67, 0xD9, 0x40, 0x70, 0x85, 0xEE, 0xC0, 
+0x71, 0x50, 0xF5, 0xC0, 0x72, 0x65, 0xD0, 0xC0, 0x73, 0x30, 0xD7, 0xC0, 0x74, 0x45, 0xB2, 0xC0, 
+0x75, 0x10, 0xB9, 0xC0, 0x76, 0x2E, 0xCF, 0x40, 0x76, 0xF0, 0x9B, 0xC0, 0x78, 0x0E, 0xB1, 0x40, 
+0x78, 0xD0, 0x7D, 0xC0, 0x79, 0xEE, 0x93, 0x40, 0x7A, 0xB0, 0x5F, 0xC0, 0x7B, 0xCE, 0x75, 0x40, 
+0x7C, 0x99, 0x7C, 0x40, 0x7D, 0xAE, 0x57, 0x40, 0x7E, 0x79, 0x5E, 0x40, 0x7F, 0x8E, 0x39, 0x40, 
+0x01, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x03, 0x02, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 
+0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x06, 0x07, 0x04, 0x02, 0x03, 0x05, 0x04, 0x05, 0x04, 0x05, 
+0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 
+0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x05, 0x04, 0x08, 0x09, 0x08, 
+0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 
+0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 
+0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 0x09, 0x08, 
+0x09, 0x08, 0x09, 0x08, 0x09, 0x00, 0x00, 0x51, 0xC0, 0x00, 0x00, 0x00, 0x00, 0x54, 0x60, 0x00, 
+0x04, 0x00, 0x00, 0x70, 0x80, 0x01, 0x09, 0x00, 0x00, 0x62, 0x70, 0x00, 0x04, 0x00, 0x00, 0x62, 
+0x70, 0x00, 0x04, 0x00, 0x00, 0x70, 0x80, 0x01, 0x09, 0x00, 0x00, 0x62, 0x70, 0x01, 0x09, 0x00, 
+0x00, 0x54, 0x60, 0x00, 0x04, 0x00, 0x00, 0x62, 0x70, 0x01, 0x0F, 0x00, 0x00, 0x54, 0x60, 0x00, 
+0x15, 0x4E, 0x4D, 0x54, 0x00, 0x4B, 0x52, 0x41, 0x54, 0x00, 0x4B, 0x52, 0x41, 0x53, 0x54, 0x00, 
+0x4E, 0x4F, 0x56, 0x53, 0x54, 0x00, 0x4E, 0x4F, 0x56, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 
+0x01, 0x01, 0x01, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0xDB, 0x58, 0x58, 0x01, 0x97, 0x96, 0x72, 0x00, 0x00, 0x00, 0x18, 0x4D, 0x6F, 0x73, 0x63, 0x6F, 
+0x77, 0x2B, 0x30, 0x33, 0x20, 0x2D, 0x20, 0x4E, 0x6F, 0x76, 0x6F, 0x6B, 0x75, 0x7A, 0x6E, 0x65, 
+0x74, 0x73, 0x6B, 
+
 /* Asia/Novosibirsk */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x52, 0x55, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x09, 0x00, 0x00, 0x00, 0x00, 
@@ -15758,12 +15723,13 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 
 /* Hongkong */
 0x50, 0x48, 0x50, 0x31, 0x00, 0x3F, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x45, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0D, 0x85, 0x69, 0x5A, 0xFC, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x47, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0x11, 0x85, 0x69, 0x5A, 0xFC, 
+0xC9, 0xEA, 0x57, 0xB8, 0xCA, 0xDA, 0x3A, 0xA8, 0xCB, 0x4B, 0x78, 0x80, 0xD2, 0x4C, 0x62, 0x70, 
 0xD3, 0x6A, 0xB7, 0x38, 0xD4, 0x93, 0x4A, 0xA8, 0xD5, 0x42, 0xB0, 0x38, 0xD6, 0x9A, 0xB9, 0xA8, 
 0xD7, 0x3E, 0x41, 0xB8, 0xD8, 0x2E, 0x24, 0xA8, 0xD8, 0xF9, 0x39, 0xB8, 0xDA, 0x0E, 0x06, 0xA8, 
 0xDA, 0xD9, 0x1B, 0xB8, 0xDB, 0xED, 0xE8, 0xA8, 0xDC, 0xB8, 0xFD, 0xB8, 0xDD, 0xCD, 0xCA, 0xA8, 
-0xDE, 0xA2, 0x1A, 0x38, 0xDF, 0xAD, 0xAC, 0xA8, 0xE0, 0x81, 0xFC, 0x38, 0xE1, 0x96, 0xC9, 0x28, 
+0xDE, 0xA2, 0x1A, 0x38, 0xDF, 0xAC, 0x5B, 0x28, 0xE0, 0x81, 0xFC, 0x38, 0xE1, 0x96, 0xC9, 0x28, 
 0xE2, 0x4F, 0x69, 0x38, 0xE3, 0x76, 0xAB, 0x28, 0xE4, 0x2F, 0x4B, 0x38, 0xE5, 0x5F, 0xC7, 0xA8, 
 0xE6, 0x0F, 0x2D, 0x38, 0xE7, 0x3F, 0xA9, 0xA8, 0xE7, 0xF8, 0x49, 0xB8, 0xE9, 0x1F, 0x8B, 0xA8, 
 0xE9, 0xD8, 0x2B, 0xB8, 0xEA, 0xFF, 0x6D, 0xA8, 0xEB, 0xB8, 0x0D, 0xB8, 0xEC, 0xDF, 0x4F, 0xA8, 
@@ -15774,17 +15740,17 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 0xFC, 0xCE, 0x5E, 0xB8, 0xFD, 0xBE, 0x41, 0xA8, 0xFE, 0xAE, 0x40, 0xB8, 0xFF, 0x9E, 0x23, 0xA8, 
 0x00, 0x8E, 0x22, 0xB8, 0x01, 0x7E, 0x05, 0xA8, 0x02, 0x6E, 0x04, 0xB8, 0x03, 0x5D, 0xE7, 0xA8, 
 0x04, 0x4D, 0xE6, 0xB8, 0x05, 0x47, 0x04, 0x28, 0x06, 0x37, 0x03, 0x38, 0x07, 0x26, 0xE6, 0x28, 
-0x08, 0x16, 0xE5, 0x38, 0x09, 0x06, 0xC8, 0x28, 0x09, 0xF6, 0xC7, 0x38, 0x0A, 0xE6, 0xAA, 0x28, 
+0x07, 0x83, 0x3D, 0x38, 0x09, 0x06, 0xC8, 0x28, 0x09, 0xF6, 0xC7, 0x38, 0x0A, 0xE6, 0xAA, 0x28, 
 0x0B, 0xD6, 0xA9, 0x38, 0x0C, 0xC6, 0x8C, 0x28, 0x0D, 0xB6, 0x8B, 0x38, 0x0E, 0xA6, 0x6E, 0x28, 
-0x11, 0x9B, 0x39, 0x38, 0x12, 0x6F, 0x6C, 0xA8, 0x13, 0x7B, 0x1B, 0x38, 0x14, 0x4F, 0x4E, 0xA8, 
-0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 
+0x11, 0x9B, 0x39, 0x38, 0x12, 0x6F, 0x6C, 0xA8, 0x02, 0x01, 0x02, 0x03, 0x02, 0x01, 0x02, 0x01, 
 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 
 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 
 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 
-0x02, 0x01, 0x02, 0x01, 0x02, 0x00, 0x00, 0x6B, 0x04, 0x00, 0x00, 0x00, 0x00, 0x7E, 0x90, 0x01, 
-0x04, 0x00, 0x00, 0x70, 0x80, 0x00, 0x09, 0x4C, 0x4D, 0x54, 0x00, 0x48, 0x4B, 0x53, 0x54, 0x00, 
-0x48, 0x4B, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 
-0xA8, 0x80, 0x00, 0x00, 0x00, 0x00, 
+0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x00, 
+0x00, 0x6B, 0x04, 0x00, 0x00, 0x00, 0x00, 0x7E, 0x90, 0x01, 0x04, 0x00, 0x00, 0x70, 0x80, 0x00, 
+0x09, 0x00, 0x00, 0x7E, 0x90, 0x00, 0x0D, 0x4C, 0x4D, 0x54, 0x00, 0x48, 0x4B, 0x53, 0x54, 0x00, 
+0x48, 0x4B, 0x54, 0x00, 0x4A, 0x53, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
+0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 0xA8, 0x80, 0x00, 0x00, 0x00, 0x00, 
 
 /* HST */
 0x50, 0x48, 0x50, 0x31, 0x00, 0x3F, 0x3F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
@@ -16685,12 +16651,13 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 /* Pacific/Fiji */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x46, 0x4A, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x00, 
-0x00, 0x00, 0x00, 0x05, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0D, 0x9A, 0x13, 0xB2, 0x3C, 
+0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0D, 0x9A, 0x13, 0xB2, 0x3C, 
 0x36, 0x3B, 0x17, 0xE0, 0x36, 0xD7, 0xFA, 0x60, 0x38, 0x24, 0x34, 0x60, 0x38, 0xB7, 0xDC, 0x60, 
-0x02, 0x01, 0x02, 0x01, 0x02, 0x00, 0x00, 0xA7, 0x44, 0x00, 0x00, 0x00, 0x00, 0xB6, 0xD0, 0x01, 
-0x04, 0x00, 0x00, 0xA8, 0xC0, 0x00, 0x09, 0x4C, 0x4D, 0x54, 0x00, 0x46, 0x4A, 0x53, 0x54, 0x00, 
-0x46, 0x4A, 0x54, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x6D, 0xA8, 0xEA, 0x02, 0x22, 
-0xE6, 0x82, 0x00, 0x00, 0x00, 0x00, 
+0x4B, 0x11, 0x2C, 0xE0, 0x4B, 0xD2, 0xF9, 0x60, 0x02, 0x01, 0x02, 0x01, 0x02, 0x01, 0x02, 0x00, 
+0x00, 0xA7, 0x44, 0x00, 0x00, 0x00, 0x00, 0xB6, 0xD0, 0x01, 0x04, 0x00, 0x00, 0xA8, 0xC0, 0x00, 
+0x09, 0x4C, 0x4D, 0x54, 0x00, 0x46, 0x4A, 0x53, 0x54, 0x00, 0x46, 0x4A, 0x54, 0x00, 0x00, 0x00, 
+0x00, 0x00, 0x00, 0x00, 0x00, 0x6D, 0xA8, 0xEA, 0x02, 0x22, 0xE6, 0x82, 0x00, 0x00, 0x00, 0x00, 
+
 
 /* Pacific/Funafuti */
 0x50, 0x48, 0x50, 0x31, 0x01, 0x54, 0x56, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 
@@ -18095,4 +18062,4 @@ const unsigned char timelib_timezone_db_data_builtin[257655] = {
 0x00, 0x00, 0x55, 0x54, 0x43, 0x00, 0x00, 0x00, 0x00, 0x89, 0x54, 0x40, 0x01, 0x12, 0xA8, 0x80, 
 0x00, 0x00, 0x00, 0x00, };
 
-const timelib_tzdb timezonedb_builtin = { "2009.13", 560, timezonedb_idx_builtin, timelib_timezone_db_data_builtin };
+const timelib_tzdb timezonedb_builtin = { "2009.19", 561, timezonedb_idx_builtin, timelib_timezone_db_data_builtin };
diff --git a/ext/date/php_date.c b/ext/date/php_date.c
index 472496d..beeb28a 100644
--- a/ext/date/php_date.c
+++ b/ext/date/php_date.c
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: php_date.c 288356 2009-09-15 20:34:54Z rasmus $ */
+/* $Id: php_date.c 291371 2009-11-28 00:38:05Z jani $ */
 
 #include "php.h"
 #include "php_streams.h"
@@ -30,16 +30,14 @@
 #include "lib/timelib.h"
 #include <time.h>
 
-#ifdef PHP_WIN32
+#ifndef HAVE_LLABS
+# ifdef PHP_WIN32
 static __inline __int64 llabs( __int64 i ) { return i >= 0? i: -i; }
-#endif
-
-#if defined(__GNUC__) && __GNUC__ < 3
+# elif defined(__GNUC__) && __GNUC__ < 3
 static __inline __int64_t llabs( __int64_t i ) { return i >= 0 ? i : -i; }
-#endif
-
-#if defined(NETWARE) && defined(__MWERKS__)
+# elif defined(NETWARE) && defined(__MWERKS__)
 static __inline long long llabs( long long i ) { return i >= 0 ? i : -i; }
+# endif
 #endif
 
 /* {{{ arginfo */
@@ -388,6 +386,7 @@ PHP_RSHUTDOWN_FUNCTION(date)
 		FREE_HASHTABLE(DATEG(tzcache));
 		DATEG(tzcache) = NULL;
 	}
+
 	return SUCCESS;
 }
 /* }}} */
@@ -596,7 +595,17 @@ static char* guess_timezone(const timelib_tzdb *tzdb TSRMLS_DC)
 		return env;
 	}
 	/* Check config setting for default timezone */
-	if (DATEG(default_timezone) && (strlen(DATEG(default_timezone)) > 0) && timelib_timezone_id_is_valid(DATEG(default_timezone), tzdb)) {
+	if (!DATEG(default_timezone)) {
+		/* Special case: ext/date wasn't initialized yet */
+		zval ztz;
+		
+		if (SUCCESS == zend_get_configuration_directive("date.timezone", sizeof("date.timezone"), &ztz) &&
+		    Z_TYPE(ztz) == IS_STRING &&
+		    Z_STRLEN(ztz) > 0 &&
+		    timelib_timezone_id_is_valid(Z_STRVAL(ztz), tzdb)) {
+			return Z_STRVAL(ztz);
+		}
+	} else if (*DATEG(default_timezone) && timelib_timezone_id_is_valid(DATEG(default_timezone), tzdb)) {
 		return DATEG(default_timezone);
 	}
 #if HAVE_TM_ZONE
@@ -2456,7 +2465,7 @@ static void php_do_date_sunrise_sunset(INTERNAL_FUNCTION_PARAMETERS, int calc_su
 	}
 
 	timelib_unixtime2local(t, time);
-	rs = timelib_astro_rise_set_altitude(t, longitude, latitude, altitude, calc_sunset?0:1, &h_rise, &h_set, &rise, &set, &transit);
+	rs = timelib_astro_rise_set_altitude(t, longitude, latitude, altitude, 1, &h_rise, &h_set, &rise, &set, &transit);
 	timelib_time_dtor(t);
 	
 	if (rs != 0) {
diff --git a/ext/date/tests/DateTimeZone_listIdentifiers_basic1.phpt b/ext/date/tests/DateTimeZone_listIdentifiers_basic1.phpt
index e9b6116..7eebfa8 100644
--- a/ext/date/tests/DateTimeZone_listIdentifiers_basic1.phpt
+++ b/ext/date/tests/DateTimeZone_listIdentifiers_basic1.phpt
@@ -13,1132 +13,24 @@ echo "*** Testing DateTimeZone::listIdentifiers() : basic functionality ***\n";
 //Set the default time zone 
 date_default_timezone_set("GMT");
 
-var_dump( DateTimeZone::listIdentifiers() );
+$zones = DateTimeZone::listIdentifiers();
+echo "Check return tpe is ARRAY\n";
+var_dump(is_array($zones));
+
+echo "Check array contains some common timezones\n";
+var_dump(in_array("Europe/London", $zones));
+var_dump(in_array("America/New_York", $zones));
+var_dump(in_array("UTC", $zones));
 
 ?>
 ===DONE===
 --EXPECT--
 *** Testing DateTimeZone::listIdentifiers() : basic functionality ***
-array(560) {
-  [0]=>
-  string(14) "Africa/Abidjan"
-  [1]=>
-  string(12) "Africa/Accra"
-  [2]=>
-  string(18) "Africa/Addis_Ababa"
-  [3]=>
-  string(14) "Africa/Algiers"
-  [4]=>
-  string(13) "Africa/Asmara"
-  [5]=>
-  string(13) "Africa/Asmera"
-  [6]=>
-  string(13) "Africa/Bamako"
-  [7]=>
-  string(13) "Africa/Bangui"
-  [8]=>
-  string(13) "Africa/Banjul"
-  [9]=>
-  string(13) "Africa/Bissau"
-  [10]=>
-  string(15) "Africa/Blantyre"
-  [11]=>
-  string(18) "Africa/Brazzaville"
-  [12]=>
-  string(16) "Africa/Bujumbura"
-  [13]=>
-  string(12) "Africa/Cairo"
-  [14]=>
-  string(17) "Africa/Casablanca"
-  [15]=>
-  string(12) "Africa/Ceuta"
-  [16]=>
-  string(14) "Africa/Conakry"
-  [17]=>
-  string(12) "Africa/Dakar"
-  [18]=>
-  string(20) "Africa/Dar_es_Salaam"
-  [19]=>
-  string(15) "Africa/Djibouti"
-  [20]=>
-  string(13) "Africa/Douala"
-  [21]=>
-  string(15) "Africa/El_Aaiun"
-  [22]=>
-  string(15) "Africa/Freetown"
-  [23]=>
-  string(15) "Africa/Gaborone"
-  [24]=>
-  string(13) "Africa/Harare"
-  [25]=>
-  string(19) "Africa/Johannesburg"
-  [26]=>
-  string(14) "Africa/Kampala"
-  [27]=>
-  string(15) "Africa/Khartoum"
-  [28]=>
-  string(13) "Africa/Kigali"
-  [29]=>
-  string(15) "Africa/Kinshasa"
-  [30]=>
-  string(12) "Africa/Lagos"
-  [31]=>
-  string(17) "Africa/Libreville"
-  [32]=>
-  string(11) "Africa/Lome"
-  [33]=>
-  string(13) "Africa/Luanda"
-  [34]=>
-  string(17) "Africa/Lubumbashi"
-  [35]=>
-  string(13) "Africa/Lusaka"
-  [36]=>
-  string(13) "Africa/Malabo"
-  [37]=>
-  string(13) "Africa/Maputo"
-  [38]=>
-  string(13) "Africa/Maseru"
-  [39]=>
-  string(14) "Africa/Mbabane"
-  [40]=>
-  string(16) "Africa/Mogadishu"
-  [41]=>
-  string(15) "Africa/Monrovia"
-  [42]=>
-  string(14) "Africa/Nairobi"
-  [43]=>
-  string(15) "Africa/Ndjamena"
-  [44]=>
-  string(13) "Africa/Niamey"
-  [45]=>
-  string(17) "Africa/Nouakchott"
-  [46]=>
-  string(18) "Africa/Ouagadougou"
-  [47]=>
-  string(17) "Africa/Porto-Novo"
-  [48]=>
-  string(15) "Africa/Sao_Tome"
-  [49]=>
-  string(15) "Africa/Timbuktu"
-  [50]=>
-  string(14) "Africa/Tripoli"
-  [51]=>
-  string(12) "Africa/Tunis"
-  [52]=>
-  string(15) "Africa/Windhoek"
-  [53]=>
-  string(12) "America/Adak"
-  [54]=>
-  string(17) "America/Anchorage"
-  [55]=>
-  string(16) "America/Anguilla"
-  [56]=>
-  string(15) "America/Antigua"
-  [57]=>
-  string(17) "America/Araguaina"
-  [58]=>
-  string(30) "America/Argentina/Buenos_Aires"
-  [59]=>
-  string(27) "America/Argentina/Catamarca"
-  [60]=>
-  string(32) "America/Argentina/ComodRivadavia"
-  [61]=>
-  string(25) "America/Argentina/Cordoba"
-  [62]=>
-  string(23) "America/Argentina/Jujuy"
-  [63]=>
-  string(26) "America/Argentina/La_Rioja"
-  [64]=>
-  string(25) "America/Argentina/Mendoza"
-  [65]=>
-  string(30) "America/Argentina/Rio_Gallegos"
-  [66]=>
-  string(23) "America/Argentina/Salta"
-  [67]=>
-  string(26) "America/Argentina/San_Juan"
-  [68]=>
-  string(26) "America/Argentina/San_Luis"
-  [69]=>
-  string(25) "America/Argentina/Tucuman"
-  [70]=>
-  string(25) "America/Argentina/Ushuaia"
-  [71]=>
-  string(13) "America/Aruba"
-  [72]=>
-  string(16) "America/Asuncion"
-  [73]=>
-  string(16) "America/Atikokan"
-  [74]=>
-  string(12) "America/Atka"
-  [75]=>
-  string(13) "America/Bahia"
-  [76]=>
-  string(16) "America/Barbados"
-  [77]=>
-  string(13) "America/Belem"
-  [78]=>
-  string(14) "America/Belize"
-  [79]=>
-  string(20) "America/Blanc-Sablon"
-  [80]=>
-  string(17) "America/Boa_Vista"
-  [81]=>
-  string(14) "America/Bogota"
-  [82]=>
-  string(13) "America/Boise"
-  [83]=>
-  string(20) "America/Buenos_Aires"
-  [84]=>
-  string(21) "America/Cambridge_Bay"
-  [85]=>
-  string(20) "America/Campo_Grande"
-  [86]=>
-  string(14) "America/Cancun"
-  [87]=>
-  string(15) "America/Caracas"
-  [88]=>
-  string(17) "America/Catamarca"
-  [89]=>
-  string(15) "America/Cayenne"
-  [90]=>
-  string(14) "America/Cayman"
-  [91]=>
-  string(15) "America/Chicago"
-  [92]=>
-  string(17) "America/Chihuahua"
-  [93]=>
-  string(21) "America/Coral_Harbour"
-  [94]=>
-  string(15) "America/Cordoba"
-  [95]=>
-  string(18) "America/Costa_Rica"
-  [96]=>
-  string(14) "America/Cuiaba"
-  [97]=>
-  string(15) "America/Curacao"
-  [98]=>
-  string(20) "America/Danmarkshavn"
-  [99]=>
-  string(14) "America/Dawson"
-  [100]=>
-  string(20) "America/Dawson_Creek"
-  [101]=>
-  string(14) "America/Denver"
-  [102]=>
-  string(15) "America/Detroit"
-  [103]=>
-  string(16) "America/Dominica"
-  [104]=>
-  string(16) "America/Edmonton"
-  [105]=>
-  string(16) "America/Eirunepe"
-  [106]=>
-  string(19) "America/El_Salvador"
-  [107]=>
-  string(16) "America/Ensenada"
-  [108]=>
-  string(18) "America/Fort_Wayne"
-  [109]=>
-  string(17) "America/Fortaleza"
-  [110]=>
-  string(17) "America/Glace_Bay"
-  [111]=>
-  string(15) "America/Godthab"
-  [112]=>
-  string(17) "America/Goose_Bay"
-  [113]=>
-  string(18) "America/Grand_Turk"
-  [114]=>
-  string(15) "America/Grenada"
-  [115]=>
-  string(18) "America/Guadeloupe"
-  [116]=>
-  string(17) "America/Guatemala"
-  [117]=>
-  string(17) "America/Guayaquil"
-  [118]=>
-  string(14) "America/Guyana"
-  [119]=>
-  string(15) "America/Halifax"
-  [120]=>
-  string(14) "America/Havana"
-  [121]=>
-  string(18) "America/Hermosillo"
-  [122]=>
-  string(28) "America/Indiana/Indianapolis"
-  [123]=>
-  string(20) "America/Indiana/Knox"
-  [124]=>
-  string(23) "America/Indiana/Marengo"
-  [125]=>
-  string(26) "America/Indiana/Petersburg"
-  [126]=>
-  string(25) "America/Indiana/Tell_City"
-  [127]=>
-  string(21) "America/Indiana/Vevay"
-  [128]=>
-  string(25) "America/Indiana/Vincennes"
-  [129]=>
-  string(23) "America/Indiana/Winamac"
-  [130]=>
-  string(20) "America/Indianapolis"
-  [131]=>
-  string(14) "America/Inuvik"
-  [132]=>
-  string(15) "America/Iqaluit"
-  [133]=>
-  string(15) "America/Jamaica"
-  [134]=>
-  string(13) "America/Jujuy"
-  [135]=>
-  string(14) "America/Juneau"
-  [136]=>
-  string(27) "America/Kentucky/Louisville"
-  [137]=>
-  string(27) "America/Kentucky/Monticello"
-  [138]=>
-  string(15) "America/Knox_IN"
-  [139]=>
-  string(14) "America/La_Paz"
-  [140]=>
-  string(12) "America/Lima"
-  [141]=>
-  string(19) "America/Los_Angeles"
-  [142]=>
-  string(18) "America/Louisville"
-  [143]=>
-  string(14) "America/Maceio"
-  [144]=>
-  string(15) "America/Managua"
-  [145]=>
-  string(14) "America/Manaus"
-  [146]=>
-  string(15) "America/Marigot"
-  [147]=>
-  string(18) "America/Martinique"
-  [148]=>
-  string(16) "America/Mazatlan"
-  [149]=>
-  string(15) "America/Mendoza"
-  [150]=>
-  string(17) "America/Menominee"
-  [151]=>
-  string(14) "America/Merida"
-  [152]=>
-  string(19) "America/Mexico_City"
-  [153]=>
-  string(16) "America/Miquelon"
-  [154]=>
-  string(15) "America/Moncton"
-  [155]=>
-  string(17) "America/Monterrey"
-  [156]=>
-  string(18) "America/Montevideo"
-  [157]=>
-  string(16) "America/Montreal"
-  [158]=>
-  string(18) "America/Montserrat"
-  [159]=>
-  string(14) "America/Nassau"
-  [160]=>
-  string(16) "America/New_York"
-  [161]=>
-  string(15) "America/Nipigon"
-  [162]=>
-  string(12) "America/Nome"
-  [163]=>
-  string(15) "America/Noronha"
-  [164]=>
-  string(27) "America/North_Dakota/Center"
-  [165]=>
-  string(30) "America/North_Dakota/New_Salem"
-  [166]=>
-  string(14) "America/Panama"
-  [167]=>
-  string(19) "America/Pangnirtung"
-  [168]=>
-  string(18) "America/Paramaribo"
-  [169]=>
-  string(15) "America/Phoenix"
-  [170]=>
-  string(22) "America/Port-au-Prince"
-  [171]=>
-  string(21) "America/Port_of_Spain"
-  [172]=>
-  string(18) "America/Porto_Acre"
-  [173]=>
-  string(19) "America/Porto_Velho"
-  [174]=>
-  string(19) "America/Puerto_Rico"
-  [175]=>
-  string(19) "America/Rainy_River"
-  [176]=>
-  string(20) "America/Rankin_Inlet"
-  [177]=>
-  string(14) "America/Recife"
-  [178]=>
-  string(14) "America/Regina"
-  [179]=>
-  string(16) "America/Resolute"
-  [180]=>
-  string(18) "America/Rio_Branco"
-  [181]=>
-  string(15) "America/Rosario"
-  [182]=>
-  string(16) "America/Santarem"
-  [183]=>
-  string(16) "America/Santiago"
-  [184]=>
-  string(21) "America/Santo_Domingo"
-  [185]=>
-  string(17) "America/Sao_Paulo"
-  [186]=>
-  string(20) "America/Scoresbysund"
-  [187]=>
-  string(16) "America/Shiprock"
-  [188]=>
-  string(21) "America/St_Barthelemy"
-  [189]=>
-  string(16) "America/St_Johns"
-  [190]=>
-  string(16) "America/St_Kitts"
-  [191]=>
-  string(16) "America/St_Lucia"
-  [192]=>
-  string(17) "America/St_Thomas"
-  [193]=>
-  string(18) "America/St_Vincent"
-  [194]=>
-  string(21) "America/Swift_Current"
-  [195]=>
-  string(19) "America/Tegucigalpa"
-  [196]=>
-  string(13) "America/Thule"
-  [197]=>
-  string(19) "America/Thunder_Bay"
-  [198]=>
-  string(15) "America/Tijuana"
-  [199]=>
-  string(15) "America/Toronto"
-  [200]=>
-  string(15) "America/Tortola"
-  [201]=>
-  string(17) "America/Vancouver"
-  [202]=>
-  string(14) "America/Virgin"
-  [203]=>
-  string(18) "America/Whitehorse"
-  [204]=>
-  string(16) "America/Winnipeg"
-  [205]=>
-  string(15) "America/Yakutat"
-  [206]=>
-  string(19) "America/Yellowknife"
-  [207]=>
-  string(16) "Antarctica/Casey"
-  [208]=>
-  string(16) "Antarctica/Davis"
-  [209]=>
-  string(25) "Antarctica/DumontDUrville"
-  [210]=>
-  string(17) "Antarctica/Mawson"
-  [211]=>
-  string(18) "Antarctica/McMurdo"
-  [212]=>
-  string(17) "Antarctica/Palmer"
-  [213]=>
-  string(18) "Antarctica/Rothera"
-  [214]=>
-  string(21) "Antarctica/South_Pole"
-  [215]=>
-  string(16) "Antarctica/Syowa"
-  [216]=>
-  string(17) "Antarctica/Vostok"
-  [217]=>
-  string(19) "Arctic/Longyearbyen"
-  [218]=>
-  string(9) "Asia/Aden"
-  [219]=>
-  string(11) "Asia/Almaty"
-  [220]=>
-  string(10) "Asia/Amman"
-  [221]=>
-  string(11) "Asia/Anadyr"
-  [222]=>
-  string(10) "Asia/Aqtau"
-  [223]=>
-  string(11) "Asia/Aqtobe"
-  [224]=>
-  string(13) "Asia/Ashgabat"
-  [225]=>
-  string(14) "Asia/Ashkhabad"
-  [226]=>
-  string(12) "Asia/Baghdad"
-  [227]=>
-  string(12) "Asia/Bahrain"
-  [228]=>
-  string(9) "Asia/Baku"
-  [229]=>
-  string(12) "Asia/Bangkok"
-  [230]=>
-  string(11) "Asia/Beirut"
-  [231]=>
-  string(12) "Asia/Bishkek"
-  [232]=>
-  string(11) "Asia/Brunei"
-  [233]=>
-  string(13) "Asia/Calcutta"
-  [234]=>
-  string(15) "Asia/Choibalsan"
-  [235]=>
-  string(14) "Asia/Chongqing"
-  [236]=>
-  string(14) "Asia/Chungking"
-  [237]=>
-  string(12) "Asia/Colombo"
-  [238]=>
-  string(10) "Asia/Dacca"
-  [239]=>
-  string(13) "Asia/Damascus"
-  [240]=>
-  string(10) "Asia/Dhaka"
-  [241]=>
-  string(9) "Asia/Dili"
-  [242]=>
-  string(10) "Asia/Dubai"
-  [243]=>
-  string(13) "Asia/Dushanbe"
-  [244]=>
-  string(9) "Asia/Gaza"
-  [245]=>
-  string(11) "Asia/Harbin"
-  [246]=>
-  string(16) "Asia/Ho_Chi_Minh"
-  [247]=>
-  string(14) "Asia/Hong_Kong"
-  [248]=>
-  string(9) "Asia/Hovd"
-  [249]=>
-  string(12) "Asia/Irkutsk"
-  [250]=>
-  string(13) "Asia/Istanbul"
-  [251]=>
-  string(12) "Asia/Jakarta"
-  [252]=>
-  string(13) "Asia/Jayapura"
-  [253]=>
-  string(14) "Asia/Jerusalem"
-  [254]=>
-  string(10) "Asia/Kabul"
-  [255]=>
-  string(14) "Asia/Kamchatka"
-  [256]=>
-  string(12) "Asia/Karachi"
-  [257]=>
-  string(12) "Asia/Kashgar"
-  [258]=>
-  string(14) "Asia/Kathmandu"
-  [259]=>
-  string(13) "Asia/Katmandu"
-  [260]=>
-  string(12) "Asia/Kolkata"
-  [261]=>
-  string(16) "Asia/Krasnoyarsk"
-  [262]=>
-  string(17) "Asia/Kuala_Lumpur"
-  [263]=>
-  string(12) "Asia/Kuching"
-  [264]=>
-  string(11) "Asia/Kuwait"
-  [265]=>
-  string(10) "Asia/Macao"
-  [266]=>
-  string(10) "Asia/Macau"
-  [267]=>
-  string(12) "Asia/Magadan"
-  [268]=>
-  string(13) "Asia/Makassar"
-  [269]=>
-  string(11) "Asia/Manila"
-  [270]=>
-  string(11) "Asia/Muscat"
-  [271]=>
-  string(12) "Asia/Nicosia"
-  [272]=>
-  string(16) "Asia/Novosibirsk"
-  [273]=>
-  string(9) "Asia/Omsk"
-  [274]=>
-  string(9) "Asia/Oral"
-  [275]=>
-  string(15) "Asia/Phnom_Penh"
-  [276]=>
-  string(14) "Asia/Pontianak"
-  [277]=>
-  string(14) "Asia/Pyongyang"
-  [278]=>
-  string(10) "Asia/Qatar"
-  [279]=>
-  string(14) "Asia/Qyzylorda"
-  [280]=>
-  string(12) "Asia/Rangoon"
-  [281]=>
-  string(11) "Asia/Riyadh"
-  [282]=>
-  string(11) "Asia/Saigon"
-  [283]=>
-  string(13) "Asia/Sakhalin"
-  [284]=>
-  string(14) "Asia/Samarkand"
-  [285]=>
-  string(10) "Asia/Seoul"
-  [286]=>
-  string(13) "Asia/Shanghai"
-  [287]=>
-  string(14) "Asia/Singapore"
-  [288]=>
-  string(11) "Asia/Taipei"
-  [289]=>
-  string(13) "Asia/Tashkent"
-  [290]=>
-  string(12) "Asia/Tbilisi"
-  [291]=>
-  string(11) "Asia/Tehran"
-  [292]=>
-  string(13) "Asia/Tel_Aviv"
-  [293]=>
-  string(11) "Asia/Thimbu"
-  [294]=>
-  string(12) "Asia/Thimphu"
-  [295]=>
-  string(10) "Asia/Tokyo"
-  [296]=>
-  string(18) "Asia/Ujung_Pandang"
-  [297]=>
-  string(16) "Asia/Ulaanbaatar"
-  [298]=>
-  string(15) "Asia/Ulan_Bator"
-  [299]=>
-  string(11) "Asia/Urumqi"
-  [300]=>
-  string(14) "Asia/Vientiane"
-  [301]=>
-  string(16) "Asia/Vladivostok"
-  [302]=>
-  string(12) "Asia/Yakutsk"
-  [303]=>
-  string(18) "Asia/Yekaterinburg"
-  [304]=>
-  string(12) "Asia/Yerevan"
-  [305]=>
-  string(15) "Atlantic/Azores"
-  [306]=>
-  string(16) "Atlantic/Bermuda"
-  [307]=>
-  string(15) "Atlantic/Canary"
-  [308]=>
-  string(19) "Atlantic/Cape_Verde"
-  [309]=>
-  string(15) "Atlantic/Faeroe"
-  [310]=>
-  string(14) "Atlantic/Faroe"
-  [311]=>
-  string(18) "Atlantic/Jan_Mayen"
-  [312]=>
-  string(16) "Atlantic/Madeira"
-  [313]=>
-  string(18) "Atlantic/Reykjavik"
-  [314]=>
-  string(22) "Atlantic/South_Georgia"
-  [315]=>
-  string(18) "Atlantic/St_Helena"
-  [316]=>
-  string(16) "Atlantic/Stanley"
-  [317]=>
-  string(13) "Australia/ACT"
-  [318]=>
-  string(18) "Australia/Adelaide"
-  [319]=>
-  string(18) "Australia/Brisbane"
-  [320]=>
-  string(21) "Australia/Broken_Hill"
-  [321]=>
-  string(18) "Australia/Canberra"
-  [322]=>
-  string(16) "Australia/Currie"
-  [323]=>
-  string(16) "Australia/Darwin"
-  [324]=>
-  string(15) "Australia/Eucla"
-  [325]=>
-  string(16) "Australia/Hobart"
-  [326]=>
-  string(13) "Australia/LHI"
-  [327]=>
-  string(18) "Australia/Lindeman"
-  [328]=>
-  string(19) "Australia/Lord_Howe"
-  [329]=>
-  string(19) "Australia/Melbourne"
-  [330]=>
-  string(15) "Australia/North"
-  [331]=>
-  string(13) "Australia/NSW"
-  [332]=>
-  string(15) "Australia/Perth"
-  [333]=>
-  string(20) "Australia/Queensland"
-  [334]=>
-  string(15) "Australia/South"
-  [335]=>
-  string(16) "Australia/Sydney"
-  [336]=>
-  string(18) "Australia/Tasmania"
-  [337]=>
-  string(18) "Australia/Victoria"
-  [338]=>
-  string(14) "Australia/West"
-  [339]=>
-  string(20) "Australia/Yancowinna"
-  [340]=>
-  string(11) "Brazil/Acre"
-  [341]=>
-  string(16) "Brazil/DeNoronha"
-  [342]=>
-  string(11) "Brazil/East"
-  [343]=>
-  string(11) "Brazil/West"
-  [344]=>
-  string(15) "Canada/Atlantic"
-  [345]=>
-  string(14) "Canada/Central"
-  [346]=>
-  string(24) "Canada/East-Saskatchewan"
-  [347]=>
-  string(14) "Canada/Eastern"
-  [348]=>
-  string(15) "Canada/Mountain"
-  [349]=>
-  string(19) "Canada/Newfoundland"
-  [350]=>
-  string(14) "Canada/Pacific"
-  [351]=>
-  string(19) "Canada/Saskatchewan"
-  [352]=>
-  string(12) "Canada/Yukon"
-  [353]=>
-  string(3) "CET"
-  [354]=>
-  string(17) "Chile/Continental"
-  [355]=>
-  string(18) "Chile/EasterIsland"
-  [356]=>
-  string(7) "CST6CDT"
-  [357]=>
-  string(4) "Cuba"
-  [358]=>
-  string(3) "EET"
-  [359]=>
-  string(5) "Egypt"
-  [360]=>
-  string(4) "Eire"
-  [361]=>
-  string(3) "EST"
-  [362]=>
-  string(7) "EST5EDT"
-  [363]=>
-  string(7) "Etc/GMT"
-  [364]=>
-  string(9) "Etc/GMT+0"
-  [365]=>
-  string(9) "Etc/GMT+1"
-  [366]=>
-  string(10) "Etc/GMT+10"
-  [367]=>
-  string(10) "Etc/GMT+11"
-  [368]=>
-  string(10) "Etc/GMT+12"
-  [369]=>
-  string(9) "Etc/GMT+2"
-  [370]=>
-  string(9) "Etc/GMT+3"
-  [371]=>
-  string(9) "Etc/GMT+4"
-  [372]=>
-  string(9) "Etc/GMT+5"
-  [373]=>
-  string(9) "Etc/GMT+6"
-  [374]=>
-  string(9) "Etc/GMT+7"
-  [375]=>
-  string(9) "Etc/GMT+8"
-  [376]=>
-  string(9) "Etc/GMT+9"
-  [377]=>
-  string(9) "Etc/GMT-0"
-  [378]=>
-  string(9) "Etc/GMT-1"
-  [379]=>
-  string(10) "Etc/GMT-10"
-  [380]=>
-  string(10) "Etc/GMT-11"
-  [381]=>
-  string(10) "Etc/GMT-12"
-  [382]=>
-  string(10) "Etc/GMT-13"
-  [383]=>
-  string(10) "Etc/GMT-14"
-  [384]=>
-  string(9) "Etc/GMT-2"
-  [385]=>
-  string(9) "Etc/GMT-3"
-  [386]=>
-  string(9) "Etc/GMT-4"
-  [387]=>
-  string(9) "Etc/GMT-5"
-  [388]=>
-  string(9) "Etc/GMT-6"
-  [389]=>
-  string(9) "Etc/GMT-7"
-  [390]=>
-  string(9) "Etc/GMT-8"
-  [391]=>
-  string(9) "Etc/GMT-9"
-  [392]=>
-  string(8) "Etc/GMT0"
-  [393]=>
-  string(13) "Etc/Greenwich"
-  [394]=>
-  string(7) "Etc/UCT"
-  [395]=>
-  string(13) "Etc/Universal"
-  [396]=>
-  string(7) "Etc/UTC"
-  [397]=>
-  string(8) "Etc/Zulu"
-  [398]=>
-  string(16) "Europe/Amsterdam"
-  [399]=>
-  string(14) "Europe/Andorra"
-  [400]=>
-  string(13) "Europe/Athens"
-  [401]=>
-  string(14) "Europe/Belfast"
-  [402]=>
-  string(15) "Europe/Belgrade"
-  [403]=>
-  string(13) "Europe/Berlin"
-  [404]=>
-  string(17) "Europe/Bratislava"
-  [405]=>
-  string(15) "Europe/Brussels"
-  [406]=>
-  string(16) "Europe/Bucharest"
-  [407]=>
-  string(15) "Europe/Budapest"
-  [408]=>
-  string(15) "Europe/Chisinau"
-  [409]=>
-  string(17) "Europe/Copenhagen"
-  [410]=>
-  string(13) "Europe/Dublin"
-  [411]=>
-  string(16) "Europe/Gibraltar"
-  [412]=>
-  string(15) "Europe/Guernsey"
-  [413]=>
-  string(15) "Europe/Helsinki"
-  [414]=>
-  string(18) "Europe/Isle_of_Man"
-  [415]=>
-  string(15) "Europe/Istanbul"
-  [416]=>
-  string(13) "Europe/Jersey"
-  [417]=>
-  string(18) "Europe/Kaliningrad"
-  [418]=>
-  string(11) "Europe/Kiev"
-  [419]=>
-  string(13) "Europe/Lisbon"
-  [420]=>
-  string(16) "Europe/Ljubljana"
-  [421]=>
-  string(13) "Europe/London"
-  [422]=>
-  string(17) "Europe/Luxembourg"
-  [423]=>
-  string(13) "Europe/Madrid"
-  [424]=>
-  string(12) "Europe/Malta"
-  [425]=>
-  string(16) "Europe/Mariehamn"
-  [426]=>
-  string(12) "Europe/Minsk"
-  [427]=>
-  string(13) "Europe/Monaco"
-  [428]=>
-  string(13) "Europe/Moscow"
-  [429]=>
-  string(14) "Europe/Nicosia"
-  [430]=>
-  string(11) "Europe/Oslo"
-  [431]=>
-  string(12) "Europe/Paris"
-  [432]=>
-  string(16) "Europe/Podgorica"
-  [433]=>
-  string(13) "Europe/Prague"
-  [434]=>
-  string(11) "Europe/Riga"
-  [435]=>
-  string(11) "Europe/Rome"
-  [436]=>
-  string(13) "Europe/Samara"
-  [437]=>
-  string(17) "Europe/San_Marino"
-  [438]=>
-  string(15) "Europe/Sarajevo"
-  [439]=>
-  string(17) "Europe/Simferopol"
-  [440]=>
-  string(13) "Europe/Skopje"
-  [441]=>
-  string(12) "Europe/Sofia"
-  [442]=>
-  string(16) "Europe/Stockholm"
-  [443]=>
-  string(14) "Europe/Tallinn"
-  [444]=>
-  string(13) "Europe/Tirane"
-  [445]=>
-  string(15) "Europe/Tiraspol"
-  [446]=>
-  string(15) "Europe/Uzhgorod"
-  [447]=>
-  string(12) "Europe/Vaduz"
-  [448]=>
-  string(14) "Europe/Vatican"
-  [449]=>
-  string(13) "Europe/Vienna"
-  [450]=>
-  string(14) "Europe/Vilnius"
-  [451]=>
-  string(16) "Europe/Volgograd"
-  [452]=>
-  string(13) "Europe/Warsaw"
-  [453]=>
-  string(13) "Europe/Zagreb"
-  [454]=>
-  string(17) "Europe/Zaporozhye"
-  [455]=>
-  string(13) "Europe/Zurich"
-  [456]=>
-  string(7) "Factory"
-  [457]=>
-  string(2) "GB"
-  [458]=>
-  string(7) "GB-Eire"
-  [459]=>
-  string(3) "GMT"
-  [460]=>
-  string(5) "GMT+0"
-  [461]=>
-  string(5) "GMT-0"
-  [462]=>
-  string(4) "GMT0"
-  [463]=>
-  string(9) "Greenwich"
-  [464]=>
-  string(8) "Hongkong"
-  [465]=>
-  string(3) "HST"
-  [466]=>
-  string(7) "Iceland"
-  [467]=>
-  string(19) "Indian/Antananarivo"
-  [468]=>
-  string(13) "Indian/Chagos"
-  [469]=>
-  string(16) "Indian/Christmas"
-  [470]=>
-  string(12) "Indian/Cocos"
-  [471]=>
-  string(13) "Indian/Comoro"
-  [472]=>
-  string(16) "Indian/Kerguelen"
-  [473]=>
-  string(11) "Indian/Mahe"
-  [474]=>
-  string(15) "Indian/Maldives"
-  [475]=>
-  string(16) "Indian/Mauritius"
-  [476]=>
-  string(14) "Indian/Mayotte"
-  [477]=>
-  string(14) "Indian/Reunion"
-  [478]=>
-  string(4) "Iran"
-  [479]=>
-  string(6) "Israel"
-  [480]=>
-  string(7) "Jamaica"
-  [481]=>
-  string(5) "Japan"
-  [482]=>
-  string(9) "Kwajalein"
-  [483]=>
-  string(5) "Libya"
-  [484]=>
-  string(3) "MET"
-  [485]=>
-  string(16) "Mexico/BajaNorte"
-  [486]=>
-  string(14) "Mexico/BajaSur"
-  [487]=>
-  string(14) "Mexico/General"
-  [488]=>
-  string(3) "MST"
-  [489]=>
-  string(7) "MST7MDT"
-  [490]=>
-  string(6) "Navajo"
-  [491]=>
-  string(2) "NZ"
-  [492]=>
-  string(7) "NZ-CHAT"
-  [493]=>
-  string(12) "Pacific/Apia"
-  [494]=>
-  string(16) "Pacific/Auckland"
-  [495]=>
-  string(15) "Pacific/Chatham"
-  [496]=>
-  string(14) "Pacific/Easter"
-  [497]=>
-  string(13) "Pacific/Efate"
-  [498]=>
-  string(17) "Pacific/Enderbury"
-  [499]=>
-  string(15) "Pacific/Fakaofo"
-  [500]=>
-  string(12) "Pacific/Fiji"
-  [501]=>
-  string(16) "Pacific/Funafuti"
-  [502]=>
-  string(17) "Pacific/Galapagos"
-  [503]=>
-  string(15) "Pacific/Gambier"
-  [504]=>
-  string(19) "Pacific/Guadalcanal"
-  [505]=>
-  string(12) "Pacific/Guam"
-  [506]=>
-  string(16) "Pacific/Honolulu"
-  [507]=>
-  string(16) "Pacific/Johnston"
-  [508]=>
-  string(18) "Pacific/Kiritimati"
-  [509]=>
-  string(14) "Pacific/Kosrae"
-  [510]=>
-  string(17) "Pacific/Kwajalein"
-  [511]=>
-  string(14) "Pacific/Majuro"
-  [512]=>
-  string(17) "Pacific/Marquesas"
-  [513]=>
-  string(14) "Pacific/Midway"
-  [514]=>
-  string(13) "Pacific/Nauru"
-  [515]=>
-  string(12) "Pacific/Niue"
-  [516]=>
-  string(15) "Pacific/Norfolk"
-  [517]=>
-  string(14) "Pacific/Noumea"
-  [518]=>
-  string(17) "Pacific/Pago_Pago"
-  [519]=>
-  string(13) "Pacific/Palau"
-  [520]=>
-  string(16) "Pacific/Pitcairn"
-  [521]=>
-  string(14) "Pacific/Ponape"
-  [522]=>
-  string(20) "Pacific/Port_Moresby"
-  [523]=>
-  string(17) "Pacific/Rarotonga"
-  [524]=>
-  string(14) "Pacific/Saipan"
-  [525]=>
-  string(13) "Pacific/Samoa"
-  [526]=>
-  string(14) "Pacific/Tahiti"
-  [527]=>
-  string(14) "Pacific/Tarawa"
-  [528]=>
-  string(17) "Pacific/Tongatapu"
-  [529]=>
-  string(12) "Pacific/Truk"
-  [530]=>
-  string(12) "Pacific/Wake"
-  [531]=>
-  string(14) "Pacific/Wallis"
-  [532]=>
-  string(11) "Pacific/Yap"
-  [533]=>
-  string(6) "Poland"
-  [534]=>
-  string(8) "Portugal"
-  [535]=>
-  string(3) "PRC"
-  [536]=>
-  string(7) "PST8PDT"
-  [537]=>
-  string(3) "ROC"
-  [538]=>
-  string(3) "ROK"
-  [539]=>
-  string(9) "Singapore"
-  [540]=>
-  string(6) "Turkey"
-  [541]=>
-  string(3) "UCT"
-  [542]=>
-  string(9) "Universal"
-  [543]=>
-  string(9) "US/Alaska"
-  [544]=>
-  string(11) "US/Aleutian"
-  [545]=>
-  string(10) "US/Arizona"
-  [546]=>
-  string(10) "US/Central"
-  [547]=>
-  string(15) "US/East-Indiana"
-  [548]=>
-  string(10) "US/Eastern"
-  [549]=>
-  string(9) "US/Hawaii"
-  [550]=>
-  string(17) "US/Indiana-Starke"
-  [551]=>
-  string(11) "US/Michigan"
-  [552]=>
-  string(11) "US/Mountain"
-  [553]=>
-  string(10) "US/Pacific"
-  [554]=>
-  string(14) "US/Pacific-New"
-  [555]=>
-  string(8) "US/Samoa"
-  [556]=>
-  string(3) "UTC"
-  [557]=>
-  string(4) "W-SU"
-  [558]=>
-  string(3) "WET"
-  [559]=>
-  string(4) "Zulu"
-}
-===DONE===
\ No newline at end of file
+Check return tpe is ARRAY
+bool(true)
+Check array contains some common timezones
+bool(true)
+bool(true)
+bool(true)
+===DONE===
+	
\ No newline at end of file
diff --git a/ext/date/tests/date_sunrise_variation5.phpt b/ext/date/tests/date_sunrise_variation5.phpt
index e697836..4267478 100644
--- a/ext/date/tests/date_sunrise_variation5.phpt
+++ b/ext/date/tests/date_sunrise_variation5.phpt
@@ -113,13 +113,13 @@ bool(false)
 bool(false)
 
 --int 12345--
-string(5) "09:52"
-float(9.882%d)
-int(1218169377)
+string(5) "09:51"
+float(9.855%d)
+int(1218169278)
 
 --int -12345--
 string(5) "09:54"
-float(9.909%d)
+float(9.9097820911118)
 int(1218169475)
 
 --empty array--
diff --git a/ext/date/tests/date_sunset_variation5.phpt b/ext/date/tests/date_sunset_variation5.phpt
index 26bf4cc..0719633 100644
--- a/ext/date/tests/date_sunset_variation5.phpt
+++ b/ext/date/tests/date_sunset_variation5.phpt
@@ -113,9 +113,9 @@ bool(false)
 bool(false)
 
 --int 12345--
-string(5) "19:19"
-float(19.319%d)
-int(1218203349)
+string(5) "19:20"
+float(19.340%d)
+int(1218203424)
 
 --int -12345--
 bool(false)
diff --git a/ext/date/tests/sunfuncts.phpt b/ext/date/tests/sunfuncts.phpt
new file mode 100644
index 0000000..4d95c59
--- /dev/null
+++ b/ext/date/tests/sunfuncts.phpt
@@ -0,0 +1,44 @@
+--TEST--
+date_sunrise() and date_sunset() functions
+--INI--
+precision=13
+--FILE--
+<?php
+
+putenv ("TZ=Asia/Jerusalem");
+
+for($a=1;$a<=12;$a++){
+	echo date_sunrise(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_TIMESTAMP,31.76670,35.23330,90.83,2)." ";
+	echo date_sunrise(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_STRING,31.76670,35.23330,90.83,2)." ";
+	echo date_sunrise(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_DOUBLE,31.76670,35.23330,90.83,2)."\n";
+	
+	echo date_sunset(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_TIMESTAMP,31.76670,35.23330,90.83,2)." ";
+	echo date_sunset(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_STRING,31.76670,35.23330,90.83,2)." ";
+	echo date_sunset(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_DOUBLE,31.76670,35.23330,90.83,2)."\n";
+}
+?>
+--EXPECTF--
+1041395864 06:37 6.6290131458%d
+1041432452 16:47 16.792451114%d
+1044073855 06:30 6.5154089279%d
+1044112463 17:14 17.239870289%d
+1046491495 06:04 6.0822145033%d
+1046533075 17:37 17.632011035%d
+1049167581 05:26 5.4394438111%d
+1049212774 17:59 17.993035729%d
+1051757532 04:52 4.8701934126%d
+1051806007 18:20 18.335390508%d
+1054434776 04:32 4.5489827182%d
+1054485647 18:40 18.679812949%d
+1057026949 04:35 4.5971956372%d
+1057078197 18:49 18.832563396%d
+1059706409 04:53 4.8916575089%d
+1059755837 18:37 18.621440704%d
+1062385999 05:13 5.2220951121%d
+1062432291 18:04 18.080957168%d
+1064979098 05:31 5.5273199215%d
+1065021952 17:25 17.431339135%d
+1067658845 05:54 5.9016292870%d
+1067698274 16:51 16.853902453%d
+1070252387 06:19 6.3299242689%d
+1070289382 16:36 16.606312600%d
diff --git a/ext/date/tests/timezone_identifiers_list_basic1.phpt b/ext/date/tests/timezone_identifiers_list_basic1.phpt
index 0e87b80..4476da2 100644
--- a/ext/date/tests/timezone_identifiers_list_basic1.phpt
+++ b/ext/date/tests/timezone_identifiers_list_basic1.phpt
@@ -13,1132 +13,24 @@ echo "*** Testing timezone_identifiers_list() : basic functionality ***\n";
 //Set the default time zone 
 date_default_timezone_set("GMT");
 
-var_dump (timezone_identifiers_list() );
+$zones = timezone_identifiers_list();
+echo "Check return tpe is ARRAY\n";
+var_dump(is_array($zones));
+
+echo "Check array contains some common timezones\n";
+var_dump(in_array("Europe/London", $zones));
+var_dump(in_array("America/New_York", $zones));
+var_dump(in_array("UTC", $zones));
 
 ?>
 ===DONE===
 --EXPECTF--
 *** Testing timezone_identifiers_list() : basic functionality ***
-array(560) {
-  [0]=>
-  string(14) "Africa/Abidjan"
-  [1]=>
-  string(12) "Africa/Accra"
-  [2]=>
-  string(18) "Africa/Addis_Ababa"
-  [3]=>
-  string(14) "Africa/Algiers"
-  [4]=>
-  string(13) "Africa/Asmara"
-  [5]=>
-  string(13) "Africa/Asmera"
-  [6]=>
-  string(13) "Africa/Bamako"
-  [7]=>
-  string(13) "Africa/Bangui"
-  [8]=>
-  string(13) "Africa/Banjul"
-  [9]=>
-  string(13) "Africa/Bissau"
-  [10]=>
-  string(15) "Africa/Blantyre"
-  [11]=>
-  string(18) "Africa/Brazzaville"
-  [12]=>
-  string(16) "Africa/Bujumbura"
-  [13]=>
-  string(12) "Africa/Cairo"
-  [14]=>
-  string(17) "Africa/Casablanca"
-  [15]=>
-  string(12) "Africa/Ceuta"
-  [16]=>
-  string(14) "Africa/Conakry"
-  [17]=>
-  string(12) "Africa/Dakar"
-  [18]=>
-  string(20) "Africa/Dar_es_Salaam"
-  [19]=>
-  string(15) "Africa/Djibouti"
-  [20]=>
-  string(13) "Africa/Douala"
-  [21]=>
-  string(15) "Africa/El_Aaiun"
-  [22]=>
-  string(15) "Africa/Freetown"
-  [23]=>
-  string(15) "Africa/Gaborone"
-  [24]=>
-  string(13) "Africa/Harare"
-  [25]=>
-  string(19) "Africa/Johannesburg"
-  [26]=>
-  string(14) "Africa/Kampala"
-  [27]=>
-  string(15) "Africa/Khartoum"
-  [28]=>
-  string(13) "Africa/Kigali"
-  [29]=>
-  string(15) "Africa/Kinshasa"
-  [30]=>
-  string(12) "Africa/Lagos"
-  [31]=>
-  string(17) "Africa/Libreville"
-  [32]=>
-  string(11) "Africa/Lome"
-  [33]=>
-  string(13) "Africa/Luanda"
-  [34]=>
-  string(17) "Africa/Lubumbashi"
-  [35]=>
-  string(13) "Africa/Lusaka"
-  [36]=>
-  string(13) "Africa/Malabo"
-  [37]=>
-  string(13) "Africa/Maputo"
-  [38]=>
-  string(13) "Africa/Maseru"
-  [39]=>
-  string(14) "Africa/Mbabane"
-  [40]=>
-  string(16) "Africa/Mogadishu"
-  [41]=>
-  string(15) "Africa/Monrovia"
-  [42]=>
-  string(14) "Africa/Nairobi"
-  [43]=>
-  string(15) "Africa/Ndjamena"
-  [44]=>
-  string(13) "Africa/Niamey"
-  [45]=>
-  string(17) "Africa/Nouakchott"
-  [46]=>
-  string(18) "Africa/Ouagadougou"
-  [47]=>
-  string(17) "Africa/Porto-Novo"
-  [48]=>
-  string(15) "Africa/Sao_Tome"
-  [49]=>
-  string(15) "Africa/Timbuktu"
-  [50]=>
-  string(14) "Africa/Tripoli"
-  [51]=>
-  string(12) "Africa/Tunis"
-  [52]=>
-  string(15) "Africa/Windhoek"
-  [53]=>
-  string(12) "America/Adak"
-  [54]=>
-  string(17) "America/Anchorage"
-  [55]=>
-  string(16) "America/Anguilla"
-  [56]=>
-  string(15) "America/Antigua"
-  [57]=>
-  string(17) "America/Araguaina"
-  [58]=>
-  string(30) "America/Argentina/Buenos_Aires"
-  [59]=>
-  string(27) "America/Argentina/Catamarca"
-  [60]=>
-  string(32) "America/Argentina/ComodRivadavia"
-  [61]=>
-  string(25) "America/Argentina/Cordoba"
-  [62]=>
-  string(23) "America/Argentina/Jujuy"
-  [63]=>
-  string(26) "America/Argentina/La_Rioja"
-  [64]=>
-  string(25) "America/Argentina/Mendoza"
-  [65]=>
-  string(30) "America/Argentina/Rio_Gallegos"
-  [66]=>
-  string(23) "America/Argentina/Salta"
-  [67]=>
-  string(26) "America/Argentina/San_Juan"
-  [68]=>
-  string(26) "America/Argentina/San_Luis"
-  [69]=>
-  string(25) "America/Argentina/Tucuman"
-  [70]=>
-  string(25) "America/Argentina/Ushuaia"
-  [71]=>
-  string(13) "America/Aruba"
-  [72]=>
-  string(16) "America/Asuncion"
-  [73]=>
-  string(16) "America/Atikokan"
-  [74]=>
-  string(12) "America/Atka"
-  [75]=>
-  string(13) "America/Bahia"
-  [76]=>
-  string(16) "America/Barbados"
-  [77]=>
-  string(13) "America/Belem"
-  [78]=>
-  string(14) "America/Belize"
-  [79]=>
-  string(20) "America/Blanc-Sablon"
-  [80]=>
-  string(17) "America/Boa_Vista"
-  [81]=>
-  string(14) "America/Bogota"
-  [82]=>
-  string(13) "America/Boise"
-  [83]=>
-  string(20) "America/Buenos_Aires"
-  [84]=>
-  string(21) "America/Cambridge_Bay"
-  [85]=>
-  string(20) "America/Campo_Grande"
-  [86]=>
-  string(14) "America/Cancun"
-  [87]=>
-  string(15) "America/Caracas"
-  [88]=>
-  string(17) "America/Catamarca"
-  [89]=>
-  string(15) "America/Cayenne"
-  [90]=>
-  string(14) "America/Cayman"
-  [91]=>
-  string(15) "America/Chicago"
-  [92]=>
-  string(17) "America/Chihuahua"
-  [93]=>
-  string(21) "America/Coral_Harbour"
-  [94]=>
-  string(15) "America/Cordoba"
-  [95]=>
-  string(18) "America/Costa_Rica"
-  [96]=>
-  string(14) "America/Cuiaba"
-  [97]=>
-  string(15) "America/Curacao"
-  [98]=>
-  string(20) "America/Danmarkshavn"
-  [99]=>
-  string(14) "America/Dawson"
-  [100]=>
-  string(20) "America/Dawson_Creek"
-  [101]=>
-  string(14) "America/Denver"
-  [102]=>
-  string(15) "America/Detroit"
-  [103]=>
-  string(16) "America/Dominica"
-  [104]=>
-  string(16) "America/Edmonton"
-  [105]=>
-  string(16) "America/Eirunepe"
-  [106]=>
-  string(19) "America/El_Salvador"
-  [107]=>
-  string(16) "America/Ensenada"
-  [108]=>
-  string(18) "America/Fort_Wayne"
-  [109]=>
-  string(17) "America/Fortaleza"
-  [110]=>
-  string(17) "America/Glace_Bay"
-  [111]=>
-  string(15) "America/Godthab"
-  [112]=>
-  string(17) "America/Goose_Bay"
-  [113]=>
-  string(18) "America/Grand_Turk"
-  [114]=>
-  string(15) "America/Grenada"
-  [115]=>
-  string(18) "America/Guadeloupe"
-  [116]=>
-  string(17) "America/Guatemala"
-  [117]=>
-  string(17) "America/Guayaquil"
-  [118]=>
-  string(14) "America/Guyana"
-  [119]=>
-  string(15) "America/Halifax"
-  [120]=>
-  string(14) "America/Havana"
-  [121]=>
-  string(18) "America/Hermosillo"
-  [122]=>
-  string(28) "America/Indiana/Indianapolis"
-  [123]=>
-  string(20) "America/Indiana/Knox"
-  [124]=>
-  string(23) "America/Indiana/Marengo"
-  [125]=>
-  string(26) "America/Indiana/Petersburg"
-  [126]=>
-  string(25) "America/Indiana/Tell_City"
-  [127]=>
-  string(21) "America/Indiana/Vevay"
-  [128]=>
-  string(25) "America/Indiana/Vincennes"
-  [129]=>
-  string(23) "America/Indiana/Winamac"
-  [130]=>
-  string(20) "America/Indianapolis"
-  [131]=>
-  string(14) "America/Inuvik"
-  [132]=>
-  string(15) "America/Iqaluit"
-  [133]=>
-  string(15) "America/Jamaica"
-  [134]=>
-  string(13) "America/Jujuy"
-  [135]=>
-  string(14) "America/Juneau"
-  [136]=>
-  string(27) "America/Kentucky/Louisville"
-  [137]=>
-  string(27) "America/Kentucky/Monticello"
-  [138]=>
-  string(15) "America/Knox_IN"
-  [139]=>
-  string(14) "America/La_Paz"
-  [140]=>
-  string(12) "America/Lima"
-  [141]=>
-  string(19) "America/Los_Angeles"
-  [142]=>
-  string(18) "America/Louisville"
-  [143]=>
-  string(14) "America/Maceio"
-  [144]=>
-  string(15) "America/Managua"
-  [145]=>
-  string(14) "America/Manaus"
-  [146]=>
-  string(15) "America/Marigot"
-  [147]=>
-  string(18) "America/Martinique"
-  [148]=>
-  string(16) "America/Mazatlan"
-  [149]=>
-  string(15) "America/Mendoza"
-  [150]=>
-  string(17) "America/Menominee"
-  [151]=>
-  string(14) "America/Merida"
-  [152]=>
-  string(19) "America/Mexico_City"
-  [153]=>
-  string(16) "America/Miquelon"
-  [154]=>
-  string(15) "America/Moncton"
-  [155]=>
-  string(17) "America/Monterrey"
-  [156]=>
-  string(18) "America/Montevideo"
-  [157]=>
-  string(16) "America/Montreal"
-  [158]=>
-  string(18) "America/Montserrat"
-  [159]=>
-  string(14) "America/Nassau"
-  [160]=>
-  string(16) "America/New_York"
-  [161]=>
-  string(15) "America/Nipigon"
-  [162]=>
-  string(12) "America/Nome"
-  [163]=>
-  string(15) "America/Noronha"
-  [164]=>
-  string(27) "America/North_Dakota/Center"
-  [165]=>
-  string(30) "America/North_Dakota/New_Salem"
-  [166]=>
-  string(14) "America/Panama"
-  [167]=>
-  string(19) "America/Pangnirtung"
-  [168]=>
-  string(18) "America/Paramaribo"
-  [169]=>
-  string(15) "America/Phoenix"
-  [170]=>
-  string(22) "America/Port-au-Prince"
-  [171]=>
-  string(21) "America/Port_of_Spain"
-  [172]=>
-  string(18) "America/Porto_Acre"
-  [173]=>
-  string(19) "America/Porto_Velho"
-  [174]=>
-  string(19) "America/Puerto_Rico"
-  [175]=>
-  string(19) "America/Rainy_River"
-  [176]=>
-  string(20) "America/Rankin_Inlet"
-  [177]=>
-  string(14) "America/Recife"
-  [178]=>
-  string(14) "America/Regina"
-  [179]=>
-  string(16) "America/Resolute"
-  [180]=>
-  string(18) "America/Rio_Branco"
-  [181]=>
-  string(15) "America/Rosario"
-  [182]=>
-  string(16) "America/Santarem"
-  [183]=>
-  string(16) "America/Santiago"
-  [184]=>
-  string(21) "America/Santo_Domingo"
-  [185]=>
-  string(17) "America/Sao_Paulo"
-  [186]=>
-  string(20) "America/Scoresbysund"
-  [187]=>
-  string(16) "America/Shiprock"
-  [188]=>
-  string(21) "America/St_Barthelemy"
-  [189]=>
-  string(16) "America/St_Johns"
-  [190]=>
-  string(16) "America/St_Kitts"
-  [191]=>
-  string(16) "America/St_Lucia"
-  [192]=>
-  string(17) "America/St_Thomas"
-  [193]=>
-  string(18) "America/St_Vincent"
-  [194]=>
-  string(21) "America/Swift_Current"
-  [195]=>
-  string(19) "America/Tegucigalpa"
-  [196]=>
-  string(13) "America/Thule"
-  [197]=>
-  string(19) "America/Thunder_Bay"
-  [198]=>
-  string(15) "America/Tijuana"
-  [199]=>
-  string(15) "America/Toronto"
-  [200]=>
-  string(15) "America/Tortola"
-  [201]=>
-  string(17) "America/Vancouver"
-  [202]=>
-  string(14) "America/Virgin"
-  [203]=>
-  string(18) "America/Whitehorse"
-  [204]=>
-  string(16) "America/Winnipeg"
-  [205]=>
-  string(15) "America/Yakutat"
-  [206]=>
-  string(19) "America/Yellowknife"
-  [207]=>
-  string(16) "Antarctica/Casey"
-  [208]=>
-  string(16) "Antarctica/Davis"
-  [209]=>
-  string(25) "Antarctica/DumontDUrville"
-  [210]=>
-  string(17) "Antarctica/Mawson"
-  [211]=>
-  string(18) "Antarctica/McMurdo"
-  [212]=>
-  string(17) "Antarctica/Palmer"
-  [213]=>
-  string(18) "Antarctica/Rothera"
-  [214]=>
-  string(21) "Antarctica/South_Pole"
-  [215]=>
-  string(16) "Antarctica/Syowa"
-  [216]=>
-  string(17) "Antarctica/Vostok"
-  [217]=>
-  string(19) "Arctic/Longyearbyen"
-  [218]=>
-  string(9) "Asia/Aden"
-  [219]=>
-  string(11) "Asia/Almaty"
-  [220]=>
-  string(10) "Asia/Amman"
-  [221]=>
-  string(11) "Asia/Anadyr"
-  [222]=>
-  string(10) "Asia/Aqtau"
-  [223]=>
-  string(11) "Asia/Aqtobe"
-  [224]=>
-  string(13) "Asia/Ashgabat"
-  [225]=>
-  string(14) "Asia/Ashkhabad"
-  [226]=>
-  string(12) "Asia/Baghdad"
-  [227]=>
-  string(12) "Asia/Bahrain"
-  [228]=>
-  string(9) "Asia/Baku"
-  [229]=>
-  string(12) "Asia/Bangkok"
-  [230]=>
-  string(11) "Asia/Beirut"
-  [231]=>
-  string(12) "Asia/Bishkek"
-  [232]=>
-  string(11) "Asia/Brunei"
-  [233]=>
-  string(13) "Asia/Calcutta"
-  [234]=>
-  string(15) "Asia/Choibalsan"
-  [235]=>
-  string(14) "Asia/Chongqing"
-  [236]=>
-  string(14) "Asia/Chungking"
-  [237]=>
-  string(12) "Asia/Colombo"
-  [238]=>
-  string(10) "Asia/Dacca"
-  [239]=>
-  string(13) "Asia/Damascus"
-  [240]=>
-  string(10) "Asia/Dhaka"
-  [241]=>
-  string(9) "Asia/Dili"
-  [242]=>
-  string(10) "Asia/Dubai"
-  [243]=>
-  string(13) "Asia/Dushanbe"
-  [244]=>
-  string(9) "Asia/Gaza"
-  [245]=>
-  string(11) "Asia/Harbin"
-  [246]=>
-  string(16) "Asia/Ho_Chi_Minh"
-  [247]=>
-  string(14) "Asia/Hong_Kong"
-  [248]=>
-  string(9) "Asia/Hovd"
-  [249]=>
-  string(12) "Asia/Irkutsk"
-  [250]=>
-  string(13) "Asia/Istanbul"
-  [251]=>
-  string(12) "Asia/Jakarta"
-  [252]=>
-  string(13) "Asia/Jayapura"
-  [253]=>
-  string(14) "Asia/Jerusalem"
-  [254]=>
-  string(10) "Asia/Kabul"
-  [255]=>
-  string(14) "Asia/Kamchatka"
-  [256]=>
-  string(12) "Asia/Karachi"
-  [257]=>
-  string(12) "Asia/Kashgar"
-  [258]=>
-  string(14) "Asia/Kathmandu"
-  [259]=>
-  string(13) "Asia/Katmandu"
-  [260]=>
-  string(12) "Asia/Kolkata"
-  [261]=>
-  string(16) "Asia/Krasnoyarsk"
-  [262]=>
-  string(17) "Asia/Kuala_Lumpur"
-  [263]=>
-  string(12) "Asia/Kuching"
-  [264]=>
-  string(11) "Asia/Kuwait"
-  [265]=>
-  string(10) "Asia/Macao"
-  [266]=>
-  string(10) "Asia/Macau"
-  [267]=>
-  string(12) "Asia/Magadan"
-  [268]=>
-  string(13) "Asia/Makassar"
-  [269]=>
-  string(11) "Asia/Manila"
-  [270]=>
-  string(11) "Asia/Muscat"
-  [271]=>
-  string(12) "Asia/Nicosia"
-  [272]=>
-  string(16) "Asia/Novosibirsk"
-  [273]=>
-  string(9) "Asia/Omsk"
-  [274]=>
-  string(9) "Asia/Oral"
-  [275]=>
-  string(15) "Asia/Phnom_Penh"
-  [276]=>
-  string(14) "Asia/Pontianak"
-  [277]=>
-  string(14) "Asia/Pyongyang"
-  [278]=>
-  string(10) "Asia/Qatar"
-  [279]=>
-  string(14) "Asia/Qyzylorda"
-  [280]=>
-  string(12) "Asia/Rangoon"
-  [281]=>
-  string(11) "Asia/Riyadh"
-  [282]=>
-  string(11) "Asia/Saigon"
-  [283]=>
-  string(13) "Asia/Sakhalin"
-  [284]=>
-  string(14) "Asia/Samarkand"
-  [285]=>
-  string(10) "Asia/Seoul"
-  [286]=>
-  string(13) "Asia/Shanghai"
-  [287]=>
-  string(14) "Asia/Singapore"
-  [288]=>
-  string(11) "Asia/Taipei"
-  [289]=>
-  string(13) "Asia/Tashkent"
-  [290]=>
-  string(12) "Asia/Tbilisi"
-  [291]=>
-  string(11) "Asia/Tehran"
-  [292]=>
-  string(13) "Asia/Tel_Aviv"
-  [293]=>
-  string(11) "Asia/Thimbu"
-  [294]=>
-  string(12) "Asia/Thimphu"
-  [295]=>
-  string(10) "Asia/Tokyo"
-  [296]=>
-  string(18) "Asia/Ujung_Pandang"
-  [297]=>
-  string(16) "Asia/Ulaanbaatar"
-  [298]=>
-  string(15) "Asia/Ulan_Bator"
-  [299]=>
-  string(11) "Asia/Urumqi"
-  [300]=>
-  string(14) "Asia/Vientiane"
-  [301]=>
-  string(16) "Asia/Vladivostok"
-  [302]=>
-  string(12) "Asia/Yakutsk"
-  [303]=>
-  string(18) "Asia/Yekaterinburg"
-  [304]=>
-  string(12) "Asia/Yerevan"
-  [305]=>
-  string(15) "Atlantic/Azores"
-  [306]=>
-  string(16) "Atlantic/Bermuda"
-  [307]=>
-  string(15) "Atlantic/Canary"
-  [308]=>
-  string(19) "Atlantic/Cape_Verde"
-  [309]=>
-  string(15) "Atlantic/Faeroe"
-  [310]=>
-  string(14) "Atlantic/Faroe"
-  [311]=>
-  string(18) "Atlantic/Jan_Mayen"
-  [312]=>
-  string(16) "Atlantic/Madeira"
-  [313]=>
-  string(18) "Atlantic/Reykjavik"
-  [314]=>
-  string(22) "Atlantic/South_Georgia"
-  [315]=>
-  string(18) "Atlantic/St_Helena"
-  [316]=>
-  string(16) "Atlantic/Stanley"
-  [317]=>
-  string(13) "Australia/ACT"
-  [318]=>
-  string(18) "Australia/Adelaide"
-  [319]=>
-  string(18) "Australia/Brisbane"
-  [320]=>
-  string(21) "Australia/Broken_Hill"
-  [321]=>
-  string(18) "Australia/Canberra"
-  [322]=>
-  string(16) "Australia/Currie"
-  [323]=>
-  string(16) "Australia/Darwin"
-  [324]=>
-  string(15) "Australia/Eucla"
-  [325]=>
-  string(16) "Australia/Hobart"
-  [326]=>
-  string(13) "Australia/LHI"
-  [327]=>
-  string(18) "Australia/Lindeman"
-  [328]=>
-  string(19) "Australia/Lord_Howe"
-  [329]=>
-  string(19) "Australia/Melbourne"
-  [330]=>
-  string(15) "Australia/North"
-  [331]=>
-  string(13) "Australia/NSW"
-  [332]=>
-  string(15) "Australia/Perth"
-  [333]=>
-  string(20) "Australia/Queensland"
-  [334]=>
-  string(15) "Australia/South"
-  [335]=>
-  string(16) "Australia/Sydney"
-  [336]=>
-  string(18) "Australia/Tasmania"
-  [337]=>
-  string(18) "Australia/Victoria"
-  [338]=>
-  string(14) "Australia/West"
-  [339]=>
-  string(20) "Australia/Yancowinna"
-  [340]=>
-  string(11) "Brazil/Acre"
-  [341]=>
-  string(16) "Brazil/DeNoronha"
-  [342]=>
-  string(11) "Brazil/East"
-  [343]=>
-  string(11) "Brazil/West"
-  [344]=>
-  string(15) "Canada/Atlantic"
-  [345]=>
-  string(14) "Canada/Central"
-  [346]=>
-  string(24) "Canada/East-Saskatchewan"
-  [347]=>
-  string(14) "Canada/Eastern"
-  [348]=>
-  string(15) "Canada/Mountain"
-  [349]=>
-  string(19) "Canada/Newfoundland"
-  [350]=>
-  string(14) "Canada/Pacific"
-  [351]=>
-  string(19) "Canada/Saskatchewan"
-  [352]=>
-  string(12) "Canada/Yukon"
-  [353]=>
-  string(3) "CET"
-  [354]=>
-  string(17) "Chile/Continental"
-  [355]=>
-  string(18) "Chile/EasterIsland"
-  [356]=>
-  string(7) "CST6CDT"
-  [357]=>
-  string(4) "Cuba"
-  [358]=>
-  string(3) "EET"
-  [359]=>
-  string(5) "Egypt"
-  [360]=>
-  string(4) "Eire"
-  [361]=>
-  string(3) "EST"
-  [362]=>
-  string(7) "EST5EDT"
-  [363]=>
-  string(7) "Etc/GMT"
-  [364]=>
-  string(9) "Etc/GMT+0"
-  [365]=>
-  string(9) "Etc/GMT+1"
-  [366]=>
-  string(10) "Etc/GMT+10"
-  [367]=>
-  string(10) "Etc/GMT+11"
-  [368]=>
-  string(10) "Etc/GMT+12"
-  [369]=>
-  string(9) "Etc/GMT+2"
-  [370]=>
-  string(9) "Etc/GMT+3"
-  [371]=>
-  string(9) "Etc/GMT+4"
-  [372]=>
-  string(9) "Etc/GMT+5"
-  [373]=>
-  string(9) "Etc/GMT+6"
-  [374]=>
-  string(9) "Etc/GMT+7"
-  [375]=>
-  string(9) "Etc/GMT+8"
-  [376]=>
-  string(9) "Etc/GMT+9"
-  [377]=>
-  string(9) "Etc/GMT-0"
-  [378]=>
-  string(9) "Etc/GMT-1"
-  [379]=>
-  string(10) "Etc/GMT-10"
-  [380]=>
-  string(10) "Etc/GMT-11"
-  [381]=>
-  string(10) "Etc/GMT-12"
-  [382]=>
-  string(10) "Etc/GMT-13"
-  [383]=>
-  string(10) "Etc/GMT-14"
-  [384]=>
-  string(9) "Etc/GMT-2"
-  [385]=>
-  string(9) "Etc/GMT-3"
-  [386]=>
-  string(9) "Etc/GMT-4"
-  [387]=>
-  string(9) "Etc/GMT-5"
-  [388]=>
-  string(9) "Etc/GMT-6"
-  [389]=>
-  string(9) "Etc/GMT-7"
-  [390]=>
-  string(9) "Etc/GMT-8"
-  [391]=>
-  string(9) "Etc/GMT-9"
-  [392]=>
-  string(8) "Etc/GMT0"
-  [393]=>
-  string(13) "Etc/Greenwich"
-  [394]=>
-  string(7) "Etc/UCT"
-  [395]=>
-  string(13) "Etc/Universal"
-  [396]=>
-  string(7) "Etc/UTC"
-  [397]=>
-  string(8) "Etc/Zulu"
-  [398]=>
-  string(16) "Europe/Amsterdam"
-  [399]=>
-  string(14) "Europe/Andorra"
-  [400]=>
-  string(13) "Europe/Athens"
-  [401]=>
-  string(14) "Europe/Belfast"
-  [402]=>
-  string(15) "Europe/Belgrade"
-  [403]=>
-  string(13) "Europe/Berlin"
-  [404]=>
-  string(17) "Europe/Bratislava"
-  [405]=>
-  string(15) "Europe/Brussels"
-  [406]=>
-  string(16) "Europe/Bucharest"
-  [407]=>
-  string(15) "Europe/Budapest"
-  [408]=>
-  string(15) "Europe/Chisinau"
-  [409]=>
-  string(17) "Europe/Copenhagen"
-  [410]=>
-  string(13) "Europe/Dublin"
-  [411]=>
-  string(16) "Europe/Gibraltar"
-  [412]=>
-  string(15) "Europe/Guernsey"
-  [413]=>
-  string(15) "Europe/Helsinki"
-  [414]=>
-  string(18) "Europe/Isle_of_Man"
-  [415]=>
-  string(15) "Europe/Istanbul"
-  [416]=>
-  string(13) "Europe/Jersey"
-  [417]=>
-  string(18) "Europe/Kaliningrad"
-  [418]=>
-  string(11) "Europe/Kiev"
-  [419]=>
-  string(13) "Europe/Lisbon"
-  [420]=>
-  string(16) "Europe/Ljubljana"
-  [421]=>
-  string(13) "Europe/London"
-  [422]=>
-  string(17) "Europe/Luxembourg"
-  [423]=>
-  string(13) "Europe/Madrid"
-  [424]=>
-  string(12) "Europe/Malta"
-  [425]=>
-  string(16) "Europe/Mariehamn"
-  [426]=>
-  string(12) "Europe/Minsk"
-  [427]=>
-  string(13) "Europe/Monaco"
-  [428]=>
-  string(13) "Europe/Moscow"
-  [429]=>
-  string(14) "Europe/Nicosia"
-  [430]=>
-  string(11) "Europe/Oslo"
-  [431]=>
-  string(12) "Europe/Paris"
-  [432]=>
-  string(16) "Europe/Podgorica"
-  [433]=>
-  string(13) "Europe/Prague"
-  [434]=>
-  string(11) "Europe/Riga"
-  [435]=>
-  string(11) "Europe/Rome"
-  [436]=>
-  string(13) "Europe/Samara"
-  [437]=>
-  string(17) "Europe/San_Marino"
-  [438]=>
-  string(15) "Europe/Sarajevo"
-  [439]=>
-  string(17) "Europe/Simferopol"
-  [440]=>
-  string(13) "Europe/Skopje"
-  [441]=>
-  string(12) "Europe/Sofia"
-  [442]=>
-  string(16) "Europe/Stockholm"
-  [443]=>
-  string(14) "Europe/Tallinn"
-  [444]=>
-  string(13) "Europe/Tirane"
-  [445]=>
-  string(15) "Europe/Tiraspol"
-  [446]=>
-  string(15) "Europe/Uzhgorod"
-  [447]=>
-  string(12) "Europe/Vaduz"
-  [448]=>
-  string(14) "Europe/Vatican"
-  [449]=>
-  string(13) "Europe/Vienna"
-  [450]=>
-  string(14) "Europe/Vilnius"
-  [451]=>
-  string(16) "Europe/Volgograd"
-  [452]=>
-  string(13) "Europe/Warsaw"
-  [453]=>
-  string(13) "Europe/Zagreb"
-  [454]=>
-  string(17) "Europe/Zaporozhye"
-  [455]=>
-  string(13) "Europe/Zurich"
-  [456]=>
-  string(7) "Factory"
-  [457]=>
-  string(2) "GB"
-  [458]=>
-  string(7) "GB-Eire"
-  [459]=>
-  string(3) "GMT"
-  [460]=>
-  string(5) "GMT+0"
-  [461]=>
-  string(5) "GMT-0"
-  [462]=>
-  string(4) "GMT0"
-  [463]=>
-  string(9) "Greenwich"
-  [464]=>
-  string(8) "Hongkong"
-  [465]=>
-  string(3) "HST"
-  [466]=>
-  string(7) "Iceland"
-  [467]=>
-  string(19) "Indian/Antananarivo"
-  [468]=>
-  string(13) "Indian/Chagos"
-  [469]=>
-  string(16) "Indian/Christmas"
-  [470]=>
-  string(12) "Indian/Cocos"
-  [471]=>
-  string(13) "Indian/Comoro"
-  [472]=>
-  string(16) "Indian/Kerguelen"
-  [473]=>
-  string(11) "Indian/Mahe"
-  [474]=>
-  string(15) "Indian/Maldives"
-  [475]=>
-  string(16) "Indian/Mauritius"
-  [476]=>
-  string(14) "Indian/Mayotte"
-  [477]=>
-  string(14) "Indian/Reunion"
-  [478]=>
-  string(4) "Iran"
-  [479]=>
-  string(6) "Israel"
-  [480]=>
-  string(7) "Jamaica"
-  [481]=>
-  string(5) "Japan"
-  [482]=>
-  string(9) "Kwajalein"
-  [483]=>
-  string(5) "Libya"
-  [484]=>
-  string(3) "MET"
-  [485]=>
-  string(16) "Mexico/BajaNorte"
-  [486]=>
-  string(14) "Mexico/BajaSur"
-  [487]=>
-  string(14) "Mexico/General"
-  [488]=>
-  string(3) "MST"
-  [489]=>
-  string(7) "MST7MDT"
-  [490]=>
-  string(6) "Navajo"
-  [491]=>
-  string(2) "NZ"
-  [492]=>
-  string(7) "NZ-CHAT"
-  [493]=>
-  string(12) "Pacific/Apia"
-  [494]=>
-  string(16) "Pacific/Auckland"
-  [495]=>
-  string(15) "Pacific/Chatham"
-  [496]=>
-  string(14) "Pacific/Easter"
-  [497]=>
-  string(13) "Pacific/Efate"
-  [498]=>
-  string(17) "Pacific/Enderbury"
-  [499]=>
-  string(15) "Pacific/Fakaofo"
-  [500]=>
-  string(12) "Pacific/Fiji"
-  [501]=>
-  string(16) "Pacific/Funafuti"
-  [502]=>
-  string(17) "Pacific/Galapagos"
-  [503]=>
-  string(15) "Pacific/Gambier"
-  [504]=>
-  string(19) "Pacific/Guadalcanal"
-  [505]=>
-  string(12) "Pacific/Guam"
-  [506]=>
-  string(16) "Pacific/Honolulu"
-  [507]=>
-  string(16) "Pacific/Johnston"
-  [508]=>
-  string(18) "Pacific/Kiritimati"
-  [509]=>
-  string(14) "Pacific/Kosrae"
-  [510]=>
-  string(17) "Pacific/Kwajalein"
-  [511]=>
-  string(14) "Pacific/Majuro"
-  [512]=>
-  string(17) "Pacific/Marquesas"
-  [513]=>
-  string(14) "Pacific/Midway"
-  [514]=>
-  string(13) "Pacific/Nauru"
-  [515]=>
-  string(12) "Pacific/Niue"
-  [516]=>
-  string(15) "Pacific/Norfolk"
-  [517]=>
-  string(14) "Pacific/Noumea"
-  [518]=>
-  string(17) "Pacific/Pago_Pago"
-  [519]=>
-  string(13) "Pacific/Palau"
-  [520]=>
-  string(16) "Pacific/Pitcairn"
-  [521]=>
-  string(14) "Pacific/Ponape"
-  [522]=>
-  string(20) "Pacific/Port_Moresby"
-  [523]=>
-  string(17) "Pacific/Rarotonga"
-  [524]=>
-  string(14) "Pacific/Saipan"
-  [525]=>
-  string(13) "Pacific/Samoa"
-  [526]=>
-  string(14) "Pacific/Tahiti"
-  [527]=>
-  string(14) "Pacific/Tarawa"
-  [528]=>
-  string(17) "Pacific/Tongatapu"
-  [529]=>
-  string(12) "Pacific/Truk"
-  [530]=>
-  string(12) "Pacific/Wake"
-  [531]=>
-  string(14) "Pacific/Wallis"
-  [532]=>
-  string(11) "Pacific/Yap"
-  [533]=>
-  string(6) "Poland"
-  [534]=>
-  string(8) "Portugal"
-  [535]=>
-  string(3) "PRC"
-  [536]=>
-  string(7) "PST8PDT"
-  [537]=>
-  string(3) "ROC"
-  [538]=>
-  string(3) "ROK"
-  [539]=>
-  string(9) "Singapore"
-  [540]=>
-  string(6) "Turkey"
-  [541]=>
-  string(3) "UCT"
-  [542]=>
-  string(9) "Universal"
-  [543]=>
-  string(9) "US/Alaska"
-  [544]=>
-  string(11) "US/Aleutian"
-  [545]=>
-  string(10) "US/Arizona"
-  [546]=>
-  string(10) "US/Central"
-  [547]=>
-  string(15) "US/East-Indiana"
-  [548]=>
-  string(10) "US/Eastern"
-  [549]=>
-  string(9) "US/Hawaii"
-  [550]=>
-  string(17) "US/Indiana-Starke"
-  [551]=>
-  string(11) "US/Michigan"
-  [552]=>
-  string(11) "US/Mountain"
-  [553]=>
-  string(10) "US/Pacific"
-  [554]=>
-  string(14) "US/Pacific-New"
-  [555]=>
-  string(8) "US/Samoa"
-  [556]=>
-  string(3) "UTC"
-  [557]=>
-  string(4) "W-SU"
-  [558]=>
-  string(3) "WET"
-  [559]=>
-  string(4) "Zulu"
-}
-===DONE===
\ No newline at end of file
+Check return tpe is ARRAY
+bool(true)
+Check array contains some common timezones
+bool(true)
+bool(true)
+bool(true)
+===DONE===
+	
\ No newline at end of file
diff --git a/ext/dom/document.c b/ext/dom/document.c
index d65ca32..14bb9e7 100644
--- a/ext/dom/document.c
+++ b/ext/dom/document.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: document.c 278373 2009-04-07 15:33:20Z rrichards $ */
+/* $Id: document.c 291669 2009-12-03 20:19:38Z rrichards $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -1252,6 +1252,18 @@ PHP_FUNCTION(dom_document_import_node)
 		if (!retnodep) {
 			RETURN_FALSE;
 		}
+
+		if ((retnodep->type == XML_ATTRIBUTE_NODE) && (nodep->ns != NULL)) {
+			xmlNsPtr nsptr = NULL;
+			xmlNodePtr root = xmlDocGetRootElement(docp);
+
+			nsptr = xmlSearchNsByHref (nodep->doc, root, nodep->ns->href);
+			if (nsptr == NULL) {
+				int errorcode;
+				nsptr = dom_get_ns(root, nodep->ns->href, &errorcode, nodep->ns->prefix);
+			}
+			xmlSetNs(retnodep, nsptr);
+		}
 		
 	}
 
diff --git a/ext/dom/documenttype.c b/ext/dom/documenttype.c
index cb00435..6c8c727 100644
--- a/ext/dom/documenttype.c
+++ b/ext/dom/documenttype.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: documenttype.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: documenttype.c 288652 2009-09-24 12:40:59Z rrichards $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -200,7 +200,6 @@ int dom_documenttype_internal_subset_read(dom_object *obj, zval **retval TSRMLS_
 	xmlDtdPtr dtdptr;
 	xmlDtd *intsubset;
 	xmlOutputBuffer *buff = NULL;
-	xmlChar *strintsubset;
 
 	dtdptr = (xmlDtdPtr) dom_object_get_node(obj);
 
@@ -216,9 +215,8 @@ int dom_documenttype_internal_subset_read(dom_object *obj, zval **retval TSRMLS_
 		if (buff != NULL) {
 			xmlNodeDumpOutput (buff, NULL, (xmlNodePtr) intsubset, 0, 0, NULL);
 			xmlOutputBufferFlush(buff);
-			strintsubset = xmlStrndup(buff->buffer->content, buff->buffer->use);
+			ZVAL_STRINGL(*retval, buff->buffer->content, buff->buffer->use, 1);
 			(void)xmlOutputBufferClose(buff);
-			ZVAL_STRING(*retval, (char *) strintsubset, 1);
 			return SUCCESS;
 		}
 	}
diff --git a/ext/dom/node.c b/ext/dom/node.c
index 4a61e5e..703ba5f 100644
--- a/ext/dom/node.c
+++ b/ext/dom/node.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: node.c 277100 2009-03-13 13:41:42Z rrichards $ */
+/* $Id: node.c 288658 2009-09-24 15:10:21Z rrichards $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -1778,7 +1778,7 @@ PHP_FUNCTION(dom_node_get_feature)
 /* }}} end dom_node_get_feature */
 
 
-/* {{{ proto DomUserData dom_node_set_user_data(string key, DomUserData data, userdatahandler handler);
+/* {{{ proto mixed dom_node_set_user_data(string key, mixed data, userdatahandler handler);
 URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Node3-setUserData
 Since: DOM Level 3
 */
@@ -1789,7 +1789,7 @@ PHP_FUNCTION(dom_node_set_user_data)
 /* }}} end dom_node_set_user_data */
 
 
-/* {{{ proto DomUserData dom_node_get_user_data(string key);
+/* {{{ proto mixed dom_node_get_user_data(string key);
 URL: http://www.w3.org/TR/2003/WD-DOM-Level-3-Core-20030226/DOM3-Core.html#Node3-getUserData
 Since: DOM Level 3
 */
diff --git a/ext/dom/tests/bug47848.phpt b/ext/dom/tests/bug47848.phpt
new file mode 100644
index 0000000..b4453c7
--- /dev/null
+++ b/ext/dom/tests/bug47848.phpt
@@ -0,0 +1,25 @@
+--TEST--
+Bug #47848 (importNode doesn't preserve attribute namespaces)
+--SKIPIF--
+<?php require_once('skipif.inc'); ?>
+--FILE--
+<?php 
+
+$aDOM = new DOMDocument();
+$aDOM->appendChild($aDOM->createElementNS('http://friend2friend.net/','f2f:a'));
+
+$fromdom = new DOMDocument();
+$fromdom->loadXML('<data xmlns:ai="http://altruists.org" ai:attr="namespaced" />');
+
+$attr= $fromdom->firstChild->attributes->item(0);
+
+$att = $aDOM->importNode($attr);
+
+$aDOM->documentElement->appendChild($aDOM->importNode($attr, true));
+
+echo $aDOM->saveXML();
+
+?>
+--EXPECT--
+<?xml version="1.0"?>
+<f2f:a xmlns:f2f="http://friend2friend.net/" xmlns:ai="http://altruists.org" ai:attr="namespaced"/>
\ No newline at end of file
diff --git a/ext/exif/exif.c b/ext/exif/exif.c
index 55f3cf2..73bab4f 100644
--- a/ext/exif/exif.c
+++ b/ext/exif/exif.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: exif.c 287371 2009-08-16 14:31:27Z iliaa $ */
+/* $Id: exif.c 290173 2009-11-03 17:11:09Z guenter $ */
 
 /*  ToDos
  *
@@ -142,7 +142,7 @@ zend_function_entry exif_functions[] = {
 };
 /* }}} */
 
-#define EXIF_VERSION "1.4 $Id: exif.c 287371 2009-08-16 14:31:27Z iliaa $"
+#define EXIF_VERSION "1.4 $Id: exif.c 290173 2009-11-03 17:11:09Z guenter $"
 
 /* {{{ PHP_MINFO_FUNCTION
  */
@@ -3881,11 +3881,7 @@ static int exif_read_file(image_info_type *ImageInfo, char *FileName, int read_t
 			}
 
 			/* Store file date/time. */
-#ifdef NETWARE
-			ImageInfo->FileDateTime = st.st_mtime.tv_sec;
-#else
 			ImageInfo->FileDateTime = st.st_mtime;
-#endif
 			ImageInfo->FileSize = st.st_size;
 			/*exif_error_docref(NULL EXIFERR_CC, ImageInfo, E_NOTICE, "Opened stream is file: %d", ImageInfo->FileSize);*/
 		}
diff --git a/ext/filter/logical_filters.c b/ext/filter/logical_filters.c
index cd2c9ee..a941224 100644
--- a/ext/filter/logical_filters.c
+++ b/ext/filter/logical_filters.c
@@ -17,7 +17,7 @@
   +----------------------------------------------------------------------+
 */
 
-/* $Id: logical_filters.c 284213 2009-07-16 23:32:16Z felipe $ */
+/* $Id: logical_filters.c 290791 2009-11-15 16:53:40Z felipe $ */
 
 #include "php_filter.h"
 #include "filter_private.h"
@@ -472,7 +472,7 @@ void php_filter_validate_url(PHP_INPUT_FILTER_PARAM_DECL) /* {{{ */
 void php_filter_validate_email(PHP_INPUT_FILTER_PARAM_DECL) /* {{{ */
 {
 	/* From http://cvs.php.net/co.php/pear/HTML_QuickForm/QuickForm/Rule/Email.php?r=1.4 */
-	const char regexp[] = "/^((\\\"[^\\\"\\f\\n\\r\\t\\b]+\\\")|([A-Za-z0-9_][A-Za-z0-9_\\!\\#\\$\\%\\&\\'\\*\\+\\-\\~\\/\\^\\`\\|\\{\\}]*(\\.[A-Za-z0-9_\\!\\#\\$\\%\\&\\'\\*\\+\\-\\~\\/\\^\\`\\|\\{\\}]*)*))@((\\[(((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9])))\\])|(((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9])))|((([A-Za-z0-9])(([A-Za-z0-9\\-])*([A-Za-z0-9]))?(\\.(?=[A-Za-z0-9\\-]))?)+[A-Za-z]+))$/D";
+	const char regexp[] = "/^((\\\"[^\\\"\\f\\n\\r\\t\\b]+\\\")|([A-Za-z0-9_][A-Za-z0-9_\\!\\#\\$\\%\\&\\'\\*\\+\\-\\~\\/\\=\\?\\^\\`\\|\\{\\}]*(\\.[A-Za-z0-9_\\!\\#\\$\\%\\&\\'\\*\\+\\-\\~\\/\\=\\?\\^\\`\\|\\{\\}]*)*))@((\\[(((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9])))\\])|(((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9]))\\.((25[0-5])|(2[0-4][0-9])|([0-1]?[0-9]?[0-9])))|((([A-Za-z0-9])(([A-Za-z0-9\\-])*([A-Za-z0-9]))?(\\.(?=[A-Za-z0-9\\-]))?)+[A-Za-z]+))$/D";
 
 	pcre       *re = NULL;
 	pcre_extra *pcre_extra = NULL;
diff --git a/ext/filter/tests/033.phpt b/ext/filter/tests/033.phpt
index f965e35..143d0c1 100644
--- a/ext/filter/tests/033.phpt
+++ b/ext/filter/tests/033.phpt
@@ -21,7 +21,7 @@ stripped            PHP  1  foo at bar.com    http://a.b.c        1.2.3.4   123  12
 encoded             PHP  1  foo%40bar.com  http%3A%2F%2Fa.b.c  1.2.3.4   123  123abc%3C%3E%28%29  O%27Henry      %ED%95%98%ED%8D%BC
 special_chars       PHP  1  foo at bar.com    http://a.b.c        1.2.3.4   123  123abc&#60;&#62;()  O&#39;Henry    하퍼    
 unsafe_raw          PHP  1  foo at bar.com    http://a.b.c        1.2.3.4   123  123abc<>()          O'Henry        하퍼    
-email               PHP  1  foo at bar.com    http//a.b.c         1.2.3.4   123  123abc              O'Henry                  
+email               PHP  1  foo at bar.com    httpa.b.c           1.2.3.4   123  123abc              O'Henry                  
 url                 PHP  1  foo at bar.com    http://a.b.c        1.2.3.4   123  123abc<>()          O'Henry                  
 number_int               1                                     1234      123  123                                          
 number_float             1                                     1234      123  123                                          
diff --git a/ext/filter/tests/046.phpt b/ext/filter/tests/046.phpt
index ef26e17..8133289 100755
--- a/ext/filter/tests/046.phpt
+++ b/ext/filter/tests/046.phpt
@@ -12,12 +12,8 @@ var_dump(filter_var($s, FILTER_VALIDATE_INT));
 
 $s = sprintf("%d", -PHP_INT_MAX);
 var_dump(is_long(filter_var($s, FILTER_VALIDATE_INT)));
-
-$s = sprintf("%.0f", ~(PHP_INT_MAX)-1);
-var_dump(filter_var($s, FILTER_VALIDATE_INT));
 ?>
 --EXPECT--
 bool(true)
 bool(false)
 bool(true)
-bool(false)
diff --git a/ext/filter/tests/bug50158.phpt b/ext/filter/tests/bug50158.phpt
new file mode 100644
index 0000000..fbe2ca3
--- /dev/null
+++ b/ext/filter/tests/bug50158.phpt
@@ -0,0 +1,23 @@
+--TEST--
+Bug #50158 (FILTER_VALIDATE_EMAIL fails with valid addresses containing = or ?)
+--FILE--
+<?php
+
+$email_address = "test=mail at example.com";    
+var_dump(filter_var($email_address, FILTER_VALIDATE_EMAIL));    
+                                                                
+$email_address = "test-mail at example.com";    
+var_dump(filter_var($email_address, FILTER_VALIDATE_EMAIL));    
+    
+$email_address = "test+mail at example.com";    
+var_dump(filter_var($email_address, FILTER_VALIDATE_EMAIL));   
+
+$email_address = "test?mail at example.com";    
+var_dump(filter_var($email_address, FILTER_VALIDATE_EMAIL));   
+
+?>
+--EXPECTF--
+%unicode|string%(21) "test=mail at example.com"
+%unicode|string%(21) "test-mail at example.com"
+%unicode|string%(21) "test+mail at example.com"
+%unicode|string%(21) "test?mail at example.com"
diff --git a/ext/ftp/ftp.c b/ext/ftp/ftp.c
index 9e5d17e..9c82fa9 100644
--- a/ext/ftp/ftp.c
+++ b/ext/ftp/ftp.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: ftp.c 288034 2009-09-04 07:59:48Z srinatar $ */
+/* $Id: ftp.c 291264 2009-11-24 13:57:39Z rasmus $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -1699,7 +1699,7 @@ ftp_nb_get(ftpbuf_t *ftp, php_stream *outstream, const char *path, ftptype_t typ
 	char			arg[11];
 
 	if (ftp == NULL) {
-		goto bail;
+		return PHP_FTP_FAILED;
 	}
 
 	if (!ftp_type(ftp, type)) {
diff --git a/ext/gd/gd.c b/ext/gd/gd.c
index a5c66e5..81922b5 100644
--- a/ext/gd/gd.c
+++ b/ext/gd/gd.c
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: gd.c 282456 2009-06-19 22:15:44Z kalle $ */
+/* $Id: gd.c 292109 2009-12-14 04:09:18Z pierrick $ */
 
 /* gd 1.2 is copyright 1994, 1995, Quest Protein Database Center,
    Cold Spring Harbor Labs. */
@@ -4503,7 +4503,7 @@ PHP_FUNCTION(imagepsencodefont)
 	T1_DeleteAllSizes(*f_ind);
 	if (T1_ReencodeFont(*f_ind, enc_vector)) {
 		T1_DeleteEncoding(enc_vector);
-		php_error_docref(NULL TSRMLS_CC, E_WARNING, "Couldn't reencode font");
+		php_error_docref(NULL TSRMLS_CC, E_WARNING, "Couldn't re-encode font");
 		RETURN_FALSE;
 	}
 
diff --git a/ext/gd/libgd/gd_gd.c b/ext/gd/libgd/gd_gd.c
index 55587d4..81a957d 100644
--- a/ext/gd/libgd/gd_gd.c
+++ b/ext/gd/libgd/gd_gd.c
@@ -39,6 +39,9 @@ int _gdGetColors (gdIOCtx * in, gdImagePtr im, int gd2xFlag)
 			if (!gdGetWord(&im->colorsTotal, in)) {
 				goto fail1;
 			}
+			if (im->colorsTotal > gdMaxColors) {
+				goto fail1;
+			}
 		}
 		/* Int to accommodate truecolor single-color transparency */
 		if (!gdGetInt(&im->transparent, in)) {
diff --git a/ext/gd/libgd/gdft.c b/ext/gd/libgd/gdft.c
index ffac3eb..ac2bf34 100644
--- a/ext/gd/libgd/gdft.c
+++ b/ext/gd/libgd/gdft.c
@@ -1090,6 +1090,7 @@ gdImageStringFTEx (gdImage * im, int *brect, int fg, char *fontlist, double ptsi
 
 		if (render) {
 			if (image->format != ft_glyph_format_bitmap && FT_Glyph_To_Bitmap(&image, ft_render_mode_normal, 0, 1)) {
+				FT_Done_Glyph(image);
 				if (tmpstr) {
 					gdFree(tmpstr);
 				}
diff --git a/ext/gd/tests/crafted.gd2 b/ext/gd/tests/crafted.gd2
new file mode 100644
index 0000000000000000000000000000000000000000..45c944cc29fa0925e7f05a9f4f4d34996cb9d724
GIT binary patch
literal 1039
bcmezWpMjBqiQ(Q_hEXsY0;3@?!b1Q6U5^8e

literal 0
HcmV?d00001

diff --git a/ext/gd/tests/crafted_gd2.phpt b/ext/gd/tests/crafted_gd2.phpt
new file mode 100644
index 0000000..7bcbc4e
--- /dev/null
+++ b/ext/gd/tests/crafted_gd2.phpt
@@ -0,0 +1,16 @@
+--TEST--
+Test max colors for a gd image.
+--SKIPIF--
+<?php
+	if (!extension_loaded('gd')) {
+		die("skip gd extension not available\n");
+	}
+?>
+--FILE--
+<?php
+imagecreatefromgd(dirname(__FILE__) . '/crafted.gd2');
+?>
+--EXPECTF--
+
+Warning: imagecreatefromgd(): '%scrafted.gd2' is not a valid GD file in %s on line %d
+
diff --git a/ext/gd/tests/image_type_to_mime_type_basic.phpt b/ext/gd/tests/image_type_to_mime_type_basic.phpt
index 7384c46..2b1de03 100644
--- a/ext/gd/tests/image_type_to_mime_type_basic.phpt
+++ b/ext/gd/tests/image_type_to_mime_type_basic.phpt
@@ -2,8 +2,7 @@
 image_type_to_mime_type()
 --SKIPIF--
 <?php 
-	if (!function_exists('image_type_to_mime_type')) die('skip image_type_to_mime_type() not available'); 
-	require_once('skipif_imagetype.inc');
+	if (!function_exists('image_type_to_mime_type')) die('skip image_type_to_mime_type() not available');
 ?>
 --FILE--
 <?php
@@ -61,4 +60,4 @@ string(18) "image/vnd.wap.wbmp"
 string(24) "application/octet-stream"
 string(9) "image/xbm"
 
-Done image_type_to_mime_type() test
\ No newline at end of file
+Done image_type_to_mime_type() test
diff --git a/ext/gd/tests/imagecopyresampled_basic.phpt b/ext/gd/tests/imagecopyresampled_basic.phpt
index 12ac155..a0454fa 100644
--- a/ext/gd/tests/imagecopyresampled_basic.phpt
+++ b/ext/gd/tests/imagecopyresampled_basic.phpt
@@ -3,7 +3,7 @@ imagecopyresampled()
 --SKIPIF--
 <?php 
 	if (!function_exists('imagecopyresampled')) die('skip imagecopyresampled() not available'); 
-	require_once('skipif_imagetype.inc');
+	if (!(imagetype() & IMG_PNG)) die('skip PNG Support is not enabled');
 ?>
 --FILE--
 <?php
diff --git a/ext/gd/tests/imagedashedline_basic.phpt b/ext/gd/tests/imagedashedline_basic.phpt
index 1d67975..be65af6 100644
--- a/ext/gd/tests/imagedashedline_basic.phpt
+++ b/ext/gd/tests/imagedashedline_basic.phpt
@@ -3,7 +3,7 @@ imagedashedline()
 --SKIPIF--
 <?php 
 	if (!function_exists('imagedashedline')) die('skip imagedashedline() not available'); 
-	require_once('skipif_imagetype.inc');
+	if (!(imagetype() & IMG_PNG)) die('skip PNG Support is not enabled');
 ?>
 --FILE--
 <?php
diff --git a/ext/gd/tests/imagefilledpolygon_basic.phpt b/ext/gd/tests/imagefilledpolygon_basic.phpt
index 6871a28..ded52da 100644
--- a/ext/gd/tests/imagefilledpolygon_basic.phpt
+++ b/ext/gd/tests/imagefilledpolygon_basic.phpt
@@ -3,7 +3,7 @@ imagefilledpolygon()
 --SKIPIF--
 <?php 
 	if (!function_exists('imagefilledpolygon')) die('skip imagefilledpolygon() not available'); 
-	require_once('skipif_imagetype.inc');
+	if (!(imagetype() & IMG_PNG)) die('skip PNG Support is not enabled');
 ?>
 --FILE--
 <?php
diff --git a/ext/gmp/tests/bug50283.phpt b/ext/gmp/tests/bug50283.phpt
new file mode 100644
index 0000000..e8132a7
--- /dev/null
+++ b/ext/gmp/tests/bug50283.phpt
@@ -0,0 +1,36 @@
+--TEST--
+Feature Request #50283 (allow base in gmp_strval to use full range: 2 to 62, and -2 to -36)
+--SKIPIF--
+<?php if (!extension_loaded("gmp")) print "skip"; ?>
+--FILE--
+<?php
+$a = gmp_init("0x41682179fbf5");
+printf("Decimal: %s, -36-based: %s\n", gmp_strval($a), gmp_strval($a,-36));
+printf("Decimal: %s, 36-based: %s\n", gmp_strval($a), gmp_strval($a,36));
+printf("Decimal: %s, -1-based: %s\n", gmp_strval($a), gmp_strval($a,-1));
+printf("Decimal: %s, 1-based: %s\n", gmp_strval($a), gmp_strval($a,1));
+printf("Decimal: %s, -37-based: %s\n", gmp_strval($a), gmp_strval($a,-37));
+printf("Decimal: %s, 37-based: %s\n", gmp_strval($a), gmp_strval($a,37));
+printf("Decimal: %s, 62-based: %s\n", gmp_strval($a), gmp_strval($a,62));
+printf("Decimal: %s, 63-based: %s\n\n", gmp_strval($a), gmp_strval($a,63));
+printf("Base 32 and 62-based: %s\n", gmp_strval(gmp_init("gh82179fbf5", 32), 62));
+?>
+--EXPECTF--
+Decimal: 71915494046709, -36-based: PHPISCOOL
+Decimal: 71915494046709, 36-based: phpiscool
+
+Warning: gmp_strval(): Bad base for conversion: -1 in %s on line 5
+Decimal: 71915494046709, -1-based: 
+
+Warning: gmp_strval(): Bad base for conversion: 1 in %s on line 6
+Decimal: 71915494046709, 1-based: 
+
+Warning: gmp_strval(): Bad base for conversion: -37 in %s on line 7
+Decimal: 71915494046709, -37-based: 
+Decimal: 71915494046709, 37-based: KHKATELJF
+Decimal: 71915494046709, 62-based: KQ6yq741
+
+Warning: gmp_strval(): Bad base for conversion: 63 in %s on line 10
+Decimal: 71915494046709, 63-based: 
+
+Base 32 and 62-based: 1NHkAcdIiD
diff --git a/ext/iconv/tests/iconv_encoding_basic.phpt b/ext/iconv/tests/iconv_encoding_basic.phpt
index 150f49b..7468581 100644
--- a/ext/iconv/tests/iconv_encoding_basic.phpt
+++ b/ext/iconv/tests/iconv_encoding_basic.phpt
@@ -5,6 +5,10 @@ Test iconv_get_encoding()/iconv_set_encoding() function : basic functionality
 extension_loaded('iconv') or die('skip');
 function_exists('iconv_get_encoding') or die("skip iconv_get_encoding() is not available in this build");
 ?>
+--INI--
+iconv.input_encoding=ISO-8859-1
+iconv.internal_encoding=ISO-8859-1
+iconv.output_encoding=ISO-8859-1
 --FILE--
 <?php
 /* Prototype  : mixed iconv_get_encoding([string type])
@@ -91,4 +95,4 @@ array(3) {
   ["internal_encoding"]=>
   string(5) "UTF-8"
 }
-Done
\ No newline at end of file
+Done
diff --git a/ext/iconv/tests/iconv_substr_basic.phpt b/ext/iconv/tests/iconv_substr_basic.phpt
index b8db8a1..0754fc8 100644
--- a/ext/iconv/tests/iconv_substr_basic.phpt
+++ b/ext/iconv/tests/iconv_substr_basic.phpt
@@ -5,6 +5,10 @@ Test iconv_substr() function : basic functionality
 extension_loaded('iconv') or die('skip');
 function_exists('iconv_substr') or die("skip iconv_substr() is not available in this build");
 ?>
+--INI--
+iconv.input_encoding=ISO-8859-1
+iconv.internal_encoding=ISO-8859-1
+iconv.output_encoding=ISO-8859-1
 --FILE--
 <?php
 /* Prototype  : string iconv_substr(string str, int offset, [int length, string charset])
@@ -52,4 +56,4 @@ string(14) "a5e69cace8aa9e"
 
 -- Multibyte string 2 --
 string(42) "e8aa9ee38386e382ade382b9e38388e381a7e38199"
-Done
\ No newline at end of file
+Done
diff --git a/ext/imap/php_imap.c b/ext/imap/php_imap.c
index 7feede2..16714ae 100644
--- a/ext/imap/php_imap.c
+++ b/ext/imap/php_imap.c
@@ -26,7 +26,7 @@
    | PHP 4.0 updates:  Zeev Suraski <zeev at zend.com>                       |
    +----------------------------------------------------------------------+
  */
-/* $Id: php_imap.c 286732 2009-08-03 13:02:53Z jani $ */
+/* $Id: php_imap.c 288585 2009-09-22 18:18:57Z felipe $ */
 
 #define IMAP41
 
@@ -115,6 +115,7 @@ zend_function_entry imap_functions[] = {
 	PHP_FE(imap_delete,								NULL)
 	PHP_FE(imap_undelete,							NULL)
 	PHP_FE(imap_check,								NULL)
+	PHP_FE(imap_listscan,							NULL)
 	PHP_FE(imap_mail_copy,							NULL)
 	PHP_FE(imap_mail_move,							NULL)
 	PHP_FE(imap_mail_compose,						NULL)
diff --git a/ext/ldap/ldap.c b/ext/ldap/ldap.c
index 2841d64..bb7be00 100644
--- a/ext/ldap/ldap.c
+++ b/ext/ldap/ldap.c
@@ -23,7 +23,7 @@
    +----------------------------------------------------------------------+
  */
  
-/* $Id: ldap.c 287936 2009-09-01 08:42:10Z patrickallaert $ */
+/* $Id: ldap.c 290923 2009-11-18 17:44:58Z jani $ */
 #define IS_EXT_MODULE
 
 #ifdef HAVE_CONFIG_H
@@ -323,7 +323,7 @@ PHP_MINFO_FUNCTION(ldap)
 
 	php_info_print_table_start();
 	php_info_print_table_row(2, "LDAP Support", "enabled");
-	php_info_print_table_row(2, "RCS Version", "$Id: ldap.c 287936 2009-09-01 08:42:10Z patrickallaert $");
+	php_info_print_table_row(2, "RCS Version", "$Id: ldap.c 290923 2009-11-18 17:44:58Z jani $");
 
 	if (LDAPG(max_links) == -1) {
 		snprintf(tmp, 31, "%ld/unlimited", LDAPG(num_links));
@@ -1061,17 +1061,21 @@ PHP_FUNCTION(ldap_get_entries)
 	ldap = ld->link;
 	num_entries = ldap_count_entries(ldap, ldap_result);
 
-	if (num_entries == 0) return;
-	num_entries = 0;
-	
-	ldap_result_entry = ldap_first_entry(ldap, ldap_result);
-	if (ldap_result_entry == NULL) RETURN_FALSE;
-
 	array_init(return_value);
 	add_assoc_long(return_value, "count", num_entries);
 
-	while (ldap_result_entry != NULL) {
+	if (num_entries == 0) {
+		return;
+	}
+	
+	ldap_result_entry = ldap_first_entry(ldap, ldap_result);
+	if (ldap_result_entry == NULL) {
+		zval_dtor(return_value);
+		RETURN_FALSE;
+	}
 
+	num_entries = 0;
+	while (ldap_result_entry != NULL) {
 		MAKE_STD_ZVAL(tmp1);
 		array_init(tmp1);
 
diff --git a/ext/ldap/tests/bug48696.phpt b/ext/ldap/tests/bug48696.phpt
index 3cef186..114a8bf 100644
--- a/ext/ldap/tests/bug48696.phpt
+++ b/ext/ldap/tests/bug48696.phpt
@@ -1,5 +1,9 @@
 --TEST--
 Bug #48696 (ldap_read() segfaults with invalid parameters)
+--SKIPIF--
+<?php
+require_once dirname(__FILE__) .'/skipif.inc';
+?>
 --FILE--
 <?php
 
diff --git a/ext/libxml/libxml.c b/ext/libxml/libxml.c
index a8d26ce..06c8753 100644
--- a/ext/libxml/libxml.c
+++ b/ext/libxml/libxml.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: libxml.c 282841 2009-06-26 20:27:44Z rrichards $ */
+/* $Id: libxml.c 291533 2009-12-01 02:05:28Z felipe $ */
 
 #define IS_EXT_MODULE
 
@@ -627,6 +627,9 @@ static PHP_MINIT_FUNCTION(libxml)
 	REGISTER_LONG_CONSTANT("LIBXML_COMPACT",	XML_PARSE_COMPACT,		CONST_CS | CONST_PERSISTENT);
 	REGISTER_LONG_CONSTANT("LIBXML_NOXMLDECL",	XML_SAVE_NO_DECL,		CONST_CS | CONST_PERSISTENT);
 #endif
+#if LIBXML_VERSION >= 20703
+	REGISTER_LONG_CONSTANT("LIBXML_PARSEHUGE",	XML_PARSE_HUGE,			CONST_CS | CONST_PERSISTENT);
+#endif
 	REGISTER_LONG_CONSTANT("LIBXML_NOEMPTYTAG",	LIBXML_SAVE_NOEMPTYTAG,	CONST_CS | CONST_PERSISTENT);
 
 	/* Error levels */
diff --git a/ext/mbstring/config.m4 b/ext/mbstring/config.m4
index c6e4732..e90ac35 100644
--- a/ext/mbstring/config.m4
+++ b/ext/mbstring/config.m4
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: config.m4 262771 2008-07-15 18:07:42Z moriyoshi $
+dnl $Id: config.m4 291283 2009-11-25 01:30:06Z rasmus $
 dnl
 
 AC_DEFUN([PHP_MBSTRING_ADD_SOURCES], [
@@ -60,7 +60,7 @@ EOF
 
 AC_DEFUN([PHP_MBSTRING_SETUP_MBREGEX], [
   if test "$PHP_MBREGEX" = "yes"; then
-    AC_CACHE_CHECK(for variable length prototypes and stdarg.h, cv_php_mbstring_stdarg, [
+    AC_CACHE_CHECK(for variable length prototypes and stdarg.h, php_cv_mbstring_stdarg, [
       AC_TRY_RUN([
 #include <stdarg.h>
 int foo(int x, ...) {
@@ -72,14 +72,14 @@ int foo(int x, ...) {
 	return 0;
 }
 int main() { return foo(10, "", 3.14); }
-      ], [cv_php_mbstring_stdarg=yes], [cv_php_mbstring_stdarg=no], [
+      ], [php_cv_mbstring_stdarg=yes], [php_cv_mbstring_stdarg=no], [
         dnl cross-compile needs something here
         case $host_alias in
         *netware*)
-          cv_php_mbstring_stdarg=yes
+          php_cv_mbstring_stdarg=yes
           ;;
         *)
-          cv_php_mbstring_stdarg=no
+          php_cv_mbstring_stdarg=no
           ;;
         esac
       ])
diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf16.c b/ext/mbstring/libmbfl/filters/mbfilter_utf16.c
index b6c2aed..5df6551 100644
--- a/ext/mbstring/libmbfl/filters/mbfilter_utf16.c
+++ b/ext/mbstring/libmbfl/filters/mbfilter_utf16.c
@@ -127,7 +127,7 @@ int mbfl_filt_conv_utf16_wchar(int c, mbfl_convert_filter *filter)
 	int n, endian;
 
 	endian = filter->status & 0xff00;
-	switch (filter->status & 0xff) {
+	switch (filter->status & 0x0f) {
 	case 0:
 		if (endian) {
 			n = c & 0xff;
@@ -144,15 +144,8 @@ int mbfl_filt_conv_utf16_wchar(int c, mbfl_convert_filter *filter)
 			n = c & 0xff;
 		}
 		n |= filter->cache & 0xffff;
-		filter->status &= ~0xff;
-		if (n == 0xfffe) {
-			if (endian) {
-				filter->status = 0;		/* big-endian */
-			} else {
-				filter->status = 0x100;		/* little-endian */
-			}
-			CK((*filter->output_function)(0xfeff, filter->data));
-		} else if (n >= 0xd800 && n < 0xdc00) {
+		filter->status &= ~0x0f;
+		if (n >= 0xd800 && n < 0xdc00) {
 			filter->cache = ((n & 0x3ff) << 16) + 0x400000;
 		} else if (n >= 0xdc00 && n < 0xe000) {
 			n &= 0x3ff;
@@ -166,7 +159,21 @@ int mbfl_filt_conv_utf16_wchar(int c, mbfl_convert_filter *filter)
 				CK((*filter->output_function)(n, filter->data));
 			}
 		} else {
+			int is_first = filter->status & 0x10;
 			filter->cache = 0;
+			filter->status |= 0x10;
+			if (!is_first) {
+				if (n == 0xfffe) {
+					if (endian) {
+						filter->status &= ~0x100;		/* big-endian */
+					} else {
+						filter->status |= 0x100;		/* little-endian */
+					}
+					break;
+				} else if (n == 0xfeff) {
+					break;
+				}
+			}
 			CK((*filter->output_function)(n, filter->data));
 		}
 		break;
diff --git a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c
index 8b95897..55027dc 100644
--- a/ext/mbstring/libmbfl/filters/mbfilter_utf8.c
+++ b/ext/mbstring/libmbfl/filters/mbfilter_utf8.c
@@ -215,7 +215,7 @@ static int mbfl_filt_ident_utf8(int c, mbfl_identify_filter *filter)
 	if (c < 0x80) {
 		if (c < 0) { 
 			filter->flag = 1;	/* bad */
-		} else if (c != 0 && filter->status) {
+		} else if (filter->status) {
 			filter->flag = 1;	/* bad */
 		}
 		filter->status = 0;
diff --git a/ext/mbstring/libmbfl/mbfl/mbfilter.c b/ext/mbstring/libmbfl/mbfl/mbfilter.c
index 1aeb38c..4997c5a 100644
--- a/ext/mbstring/libmbfl/mbfl/mbfilter.c
+++ b/ext/mbstring/libmbfl/mbfl/mbfilter.c
@@ -622,7 +622,7 @@ mbfl_identify_encoding(mbfl_string *string, enum mbfl_no_encoding *elist, int el
 	if (!encoding) {
 		for (i = 0; i < num; i++) {
 			filter = &flist[i];
-			if (!filter->flag) {
+			if (!filter->flag && (!strict || !filter->status)) {
 				encoding = filter->encoding;
 				break;
 			}
diff --git a/ext/mbstring/mbstring.c b/ext/mbstring/mbstring.c
index e4271d9..ffb141d 100644
--- a/ext/mbstring/mbstring.c
+++ b/ext/mbstring/mbstring.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: mbstring.c 277212 2009-03-15 20:44:17Z moriyoshi $ */
+/* $Id: mbstring.c 288613 2009-09-23 15:22:47Z moriyoshi $ */
 
 /*
  * PHP 4 Multibyte String module "mbstring"
@@ -2272,9 +2272,6 @@ PHP_FUNCTION(mb_strcut)
 	if (from > Z_STRLEN_PP(arg1)) {
 		RETURN_FALSE;
 	}
-	if (((unsigned) from + (unsigned) len) > Z_STRLEN_PP(arg1)) {
-		len = Z_STRLEN_PP(arg1) - from;
-	}
 
 	ret = mbfl_strcut(&string, &result, from, len);
 	if (ret != NULL) {
diff --git a/ext/mbstring/tests/bug43994.phpt b/ext/mbstring/tests/bug43994.phpt
index 39a39f6..9d7aaba 100644
--- a/ext/mbstring/tests/bug43994.phpt
+++ b/ext/mbstring/tests/bug43994.phpt
@@ -38,7 +38,7 @@ foreach($inputs as $input) {
 };
 ?>
 
---EXPECTF---- 
+--EXPECTF--
 
 -- Iteration 1 --
 Without $regs arg:
diff --git a/ext/mbstring/tests/bug45722.phpt b/ext/mbstring/tests/bug45722.phpt
index c05a010..97f6fe5 100644
--- a/ext/mbstring/tests/bug45722.phpt
+++ b/ext/mbstring/tests/bug45722.phpt
@@ -1,5 +1,7 @@
 --TEST--
 Bug #45722 (mb_check_encoding() crashes)
+--SKIPIF--
+<?php extension_loaded('mbstring') or die('skip mbstring not available'); ?>
 --FILE--
 <?php
 var_dump(mb_check_encoding("&\xc2\xb7 TEST TEST TEST TEST TEST TEST", "HTML-ENTITIES"));
diff --git a/ext/mbstring/tests/bug49354.phpt b/ext/mbstring/tests/bug49354.phpt
new file mode 100644
index 0000000..c25b405
--- /dev/null
+++ b/ext/mbstring/tests/bug49354.phpt
@@ -0,0 +1,21 @@
+--TEST--
+Bug #49354 (mb_strcut() cuts wrong length when offset is in the middle of a multibyte character)
+--SKIPIF--
+<?php extension_loaded('mbstring') or die('skip mbstring not available'); ?>
+--FILE--
+<?php
+$crap = 'AåBäCöDü';
+var_dump(mb_strcut($crap, 0, 100, 'UTF-8'));
+var_dump(mb_strcut($crap, 1, 100, 'UTF-8'));
+var_dump(mb_strcut($crap, 2, 100, 'UTF-8'));
+var_dump(mb_strcut($crap, 3, 100, 'UTF-8'));
+var_dump(mb_strcut($crap, 12, 100, 'UTF-8'));
+var_dump(mb_strcut($crap, 13, 100, 'UTF-8'));
+?>
+--EXPECT--
+string(12) "AåBäCöDü"
+string(11) "åBäCöDü"
+string(11) "åBäCöDü"
+string(9) "BäCöDü"
+string(0) ""
+bool(false)
diff --git a/ext/mbstring/tests/bug49528.phpt b/ext/mbstring/tests/bug49528.phpt
new file mode 100644
index 0000000..b06c35f
--- /dev/null
+++ b/ext/mbstring/tests/bug49528.phpt
@@ -0,0 +1,20 @@
+--TEST--
+Bug #49528 (UTF-16 strings prefixed by BOM wrongly converted)
+--SKIPIF--
+<?php extension_loaded('mbstring') or die('skip mbstring not available'); ?>
+--FILE--
+<?php
+var_dump(bin2hex(mb_convert_encoding("\xff\xfe\x01\x02\x03\x04", "UCS-2BE", "UTF-16")));
+var_dump(bin2hex(mb_convert_encoding("\xfe\xff\x01\x02\x03\x04", "UCS-2BE", "UTF-16")));
+var_dump(bin2hex(mb_convert_encoding("\xff\xfe\xff\xfe\x01\x02\x03\x04", "UCS-2BE", "UTF-16")));
+var_dump(bin2hex(mb_convert_encoding("\xff\xfe\xfe\xff\x01\x02\x03\x04", "UCS-2BE", "UTF-16")));
+var_dump(bin2hex(mb_convert_encoding("\xfe\xff\xff\xfe\x01\x02\x03\x04", "UCS-2BE", "UTF-16")));
+var_dump(bin2hex(mb_convert_encoding("\xfe\xff\xfe\xff\x01\x02\x03\x04", "UCS-2BE", "UTF-16")));
+?>
+--EXPECT--
+string(8) "02010403"
+string(8) "01020304"
+string(12) "feff02010403"
+string(12) "fffe02010403"
+string(12) "fffe01020304"
+string(12) "feff01020304"
diff --git a/ext/mbstring/tests/bug49536.phpt b/ext/mbstring/tests/bug49536.phpt
new file mode 100644
index 0000000..32685d2
--- /dev/null
+++ b/ext/mbstring/tests/bug49536.phpt
@@ -0,0 +1,20 @@
+--TEST--
+Bug #49536 (mb_detect_encoding() returns incorrect results when strict_mode is turned on)
+--SKIPIF--
+<?php extension_loaded('mbstring') or die('skip mbstring not available'); ?>
+--FILE--
+<?php
+// non-strict mode
+var_dump(mb_detect_encoding("A\x81", "SJIS", false));
+// strict mode
+var_dump(mb_detect_encoding("A\x81", "SJIS", true));
+// non-strict mode
+var_dump(mb_detect_encoding("\xc0\x00", "UTF-8", false));
+// strict mode
+var_dump(mb_detect_encoding("\xc0\x00", "UTF-8", true));
+?>
+--EXPECT--
+string(4) "SJIS"
+bool(false)
+string(5) "UTF-8"
+bool(false)
diff --git a/ext/mcrypt/mcrypt.c b/ext/mcrypt/mcrypt.c
index be9e638..9b5f9e8 100644
--- a/ext/mcrypt/mcrypt.c
+++ b/ext/mcrypt/mcrypt.c
@@ -16,7 +16,7 @@
    |          Derick Rethans <derick at derickrethans.nl>                    |
    +----------------------------------------------------------------------+
  */
-/* $Id: mcrypt.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: mcrypt.c 289076 2009-10-02 00:13:53Z srinatar $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -613,6 +613,7 @@ PHP_FUNCTION(mcrypt_generic_deinit)
 		php_error_docref(NULL TSRMLS_CC, E_WARNING, "Could not terminate encryption specifier");
 		RETURN_FALSE
 	}
+	pm->init = 0;
 	RETURN_TRUE
 }
 /* }}} */
diff --git a/ext/mcrypt/tests/bug46010.phpt b/ext/mcrypt/tests/bug46010.phpt
index 5aeb311..bacfb59 100644
--- a/ext/mcrypt/tests/bug46010.phpt
+++ b/ext/mcrypt/tests/bug46010.phpt
@@ -1,4 +1,4 @@
---TEST---
+--TEST--
 Bug #46010 (warnings incorrectly generated for iv in ecb mode)
 --FILE--
 <?php
diff --git a/ext/mcrypt/tests/bug49738.phpt b/ext/mcrypt/tests/bug49738.phpt
new file mode 100644
index 0000000..8f01bec
--- /dev/null
+++ b/ext/mcrypt/tests/bug49738.phpt
@@ -0,0 +1,13 @@
+--TEST--
+Bug #49738 (calling mcrypt after mcrypt_generic_deinit crashes)
+--SKIPIF--
+<?php if (!extension_loaded("mcrypt")) print "skip"; ?>
+--FILE--
+<?php
+   $td = mcrypt_module_open(MCRYPT_DES, '', MCRYPT_MODE_ECB, '');
+   mcrypt_generic_init($td, 'aaaaaaaa', 'aaaaaaaa');
+   mcrypt_generic_deinit($td);
+   echo mcrypt_generic($td, 'aaaaaaaa');
+?>
+--EXPECTF--
+Warning: mcrypt_generic(): Operation disallowed prior to mcrypt_generic_init(). in %sbug49738.php on line 5
diff --git a/ext/mime_magic/mime_magic.c b/ext/mime_magic/mime_magic.c
index a7c4dea..67e369c 100644
--- a/ext/mime_magic/mime_magic.c
+++ b/ext/mime_magic/mime_magic.c
@@ -15,7 +15,7 @@
   | Author: Hartmut Holzgraefe  <hholzgra at php.net>                       |
   +----------------------------------------------------------------------+
 
-  $Id: mime_magic.c 272374 2008-12-31 11:17:49Z sebastian $ 
+  $Id: mime_magic.c 290183 2009-11-03 18:44:11Z guenter $ 
 
   This module contains a lot of stuff taken from Apache mod_mime_magic,
   so the license section is a little bit longer than usual:
@@ -166,6 +166,8 @@
 
 #ifdef PHP_WIN32
 #define PHP_MIME_MAGIC_FILE_PATH PHP_PREFIX "\\magic.mime"
+#elif NETWARE
+#define PHP_MIME_MAGIC_FILE_PATH PHP_PREFIX "/magic.mime"
 #endif
 
 #define BYTE	1
diff --git a/ext/mysqli/mysqli.c b/ext/mysqli/mysqli.c
index f161e1f..82f3cb6 100644
--- a/ext/mysqli/mysqli.c
+++ b/ext/mysqli/mysqli.c
@@ -15,7 +15,7 @@
   | Author: Georg Richter <georg at php.net>                                |
   +----------------------------------------------------------------------+
 
-  $Id: mysqli.c 275985 2009-02-17 10:40:18Z johannes $ 
+  $Id: mysqli.c 290573 2009-11-12 08:20:57Z rasmus $ 
 */
 
 #ifdef HAVE_CONFIG_H
@@ -1003,7 +1003,11 @@ PHP_MYSQLI_API void php_mysqli_set_error(long mysql_errno, char *mysql_err TSRML
 	if (MyG(error_msg)) {
 		efree(MyG(error_msg));
 	}
-	MyG(error_msg) = estrdup(mysql_err);
+	if(mysql_err && *mysql_err) {
+		MyG(error_msg) = estrdup(mysql_err);
+	} else {
+		MyG(error_msg) = NULL;
+	}
 }
 /* }}} */
 
diff --git a/ext/mysqli/mysqli_api.c b/ext/mysqli/mysqli_api.c
index d9a0f4b..d07b1bf 100644
--- a/ext/mysqli/mysqli_api.c
+++ b/ext/mysqli/mysqli_api.c
@@ -15,7 +15,7 @@
   | Author: Georg Richter <georg at php.net>                                |
   +----------------------------------------------------------------------+
 
-  $Id: mysqli_api.c 288336 2009-09-14 16:51:11Z uw $ 
+  $Id: mysqli_api.c 288895 2009-09-28 13:11:21Z iliaa $ 
 */
 
 #ifdef HAVE_CONFIG_H
@@ -1848,14 +1848,13 @@ PHP_FUNCTION(mysqli_stmt_attr_set)
 	zval 	*mysql_stmt;
 	ulong   mode;
 	ulong	attr;
-	int		rc;
 
 	if (zend_parse_method_parameters(ZEND_NUM_ARGS() TSRMLS_CC, getThis(), "Oll", &mysql_stmt, mysqli_stmt_class_entry, &attr, &mode) == FAILURE) {
 		return;
 	}
 	MYSQLI_FETCH_RESOURCE(stmt, MY_STMT *, &mysql_stmt, "mysqli_stmt", MYSQLI_STATUS_VALID);
 
-	if ((rc = mysql_stmt_attr_set(stmt->stmt, attr, (void *)&mode))) {
+	if (!mysql_stmt_attr_set(stmt->stmt, attr, (void *)&mode)) {
 		RETURN_FALSE;
 	}
 	RETURN_TRUE;
diff --git a/ext/odbc/php_odbc.c b/ext/odbc/php_odbc.c
index 35b1467..441cfca 100644
--- a/ext/odbc/php_odbc.c
+++ b/ext/odbc/php_odbc.c
@@ -20,7 +20,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: php_odbc.c 280532 2009-05-14 17:25:51Z felipe $ */
+/* $Id: php_odbc.c 291772 2009-12-06 18:53:16Z felipe $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -725,6 +725,10 @@ int odbc_bindcols(odbc_result *result TSRMLS_DC)
 									NULL, 0, NULL, &displaysize);
 				displaysize = displaysize <= result->longreadlen ? displaysize : 
 								result->longreadlen;
+				/* Workaround for Oracle ODBC Driver bug (#50162) when fetching TIMESTAMP column */
+				if (result->values[i].coltype == SQL_TIMESTAMP) {
+					displaysize += 3;
+				}
 				result->values[i].value = (char *)emalloc(displaysize + 1);
 				rc = SQLBindCol(result->stmt, (SQLUSMALLINT)(i+1), SQL_C_CHAR, result->values[i].value,
 							displaysize + 1, &result->values[i].vallen);
@@ -925,13 +929,7 @@ PHP_FUNCTION(odbc_prepare)
 			/* Try to set CURSOR_TYPE to dynamic. Driver will replace this with other
 			   type if not possible.
 			*/
-			int cursortype = ODBCG(default_cursortype);
-			if (SQLSetStmtOption(result->stmt, SQL_CURSOR_TYPE, cursortype) == SQL_ERROR) {
-				odbc_sql_error(conn, result->stmt, " SQLSetStmtOption");
-				SQLFreeStmt(result->stmt, SQL_DROP);
-				efree(result);
-				RETURN_FALSE;
-			}
+			SQLSetStmtOption(result->stmt, SQL_CURSOR_TYPE, ODBCG(default_cursortype));
 		}
 	} else {
 		result->fetch_abs = 0;
@@ -1346,13 +1344,7 @@ PHP_FUNCTION(odbc_exec)
 			/* Try to set CURSOR_TYPE to dynamic. Driver will replace this with other
 			   type if not possible.
 			 */
-			int cursortype = ODBCG(default_cursortype);
-			if (SQLSetStmtOption(result->stmt, SQL_CURSOR_TYPE, cursortype) == SQL_ERROR) {
-				odbc_sql_error(conn, result->stmt, " SQLSetStmtOption");
-				SQLFreeStmt(result->stmt, SQL_DROP);
-				efree(result);
-				RETURN_FALSE;
-			}
+			SQLSetStmtOption(result->stmt, SQL_CURSOR_TYPE, ODBCG(default_cursortype));
 		}
 	} else {
 		result->fetch_abs = 0;
diff --git a/ext/openssl/openssl.c b/ext/openssl/openssl.c
index 7bcf50a..1e36778 100644
--- a/ext/openssl/openssl.c
+++ b/ext/openssl/openssl.c
@@ -20,7 +20,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: openssl.c 288329 2009-09-14 12:50:30Z iliaa $ */
+/* $Id: openssl.c 290180 2009-11-03 18:24:57Z guenter $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -49,6 +49,10 @@
 /* Common */
 #include <time.h>
 
+#ifdef NETWARE
+#define timezone _timezone	/* timezone is called _timezone in LibC */
+#endif
+
 #define DEFAULT_KEY_LENGTH	512
 #define MIN_KEY_LENGTH		384
 
@@ -1444,18 +1448,18 @@ PHP_FUNCTION(openssl_pkcs12_export_to_file)
 	int filename_len;
 	char * pass;
 	int pass_len;
-	zval *zcert = NULL, *zpkey = NULL, *args = NULL;
+	zval **zcert = NULL, *zpkey = NULL, *args = NULL;
 	EVP_PKEY *priv_key = NULL;
 	long certresource, keyresource;
 	zval ** item;
 	STACK_OF(X509) *ca = NULL;
 
-	if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "zszs|a", &zcert, &filename, &filename_len, &zpkey, &pass, &pass_len, &args) == FAILURE)
+	if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "Zszs|a", &zcert, &filename, &filename_len, &zpkey, &pass, &pass_len, &args) == FAILURE)
 		return;
 
 	RETVAL_FALSE;
 	
-	cert = php_openssl_x509_from_zval(&zcert, 0, &certresource TSRMLS_CC);
+	cert = php_openssl_x509_from_zval(zcert, 0, &certresource TSRMLS_CC);
 	if (cert == NULL) {
 		php_error_docref(NULL TSRMLS_CC, E_WARNING, "cannot get cert from parameter 1");
 		return;
diff --git a/ext/openssl/tests/bug48182.phpt b/ext/openssl/tests/bug48182.phpt
index 0af04e1..7471c4c 100644
--- a/ext/openssl/tests/bug48182.phpt
+++ b/ext/openssl/tests/bug48182.phpt
@@ -28,12 +28,12 @@ function ssl_server($port) {
 	$r = array($link);
 	$w = array();
 	$e = array();
-	if (stream_select($r, $w, $e, 0, 1000) != 0)
+	if (stream_select($r, $w, $e, 1, 0) != 0)
 		$data .= fread($link, 8192);
 
 	$r = array();
 	$w = array($link);
-	if (stream_select($r, $w, $e, 0, 1000) != 0)
+	if (stream_select($r, $w, $e, 1, 0) != 0)
 		$wrote = fwrite($link, $data, strlen($data));
 
 	// close stuff
@@ -59,7 +59,7 @@ function ssl_async_client($port) {
 	$r = array($socket);
 	$w = array();
 	$e = array();
-	if (stream_select($r, $w, $e, 0, 10) != 0) 
+	if (stream_select($r, $w, $e, 1, 0) != 0) 
 	{
 		$data .= fread($socket, 1024);
 	}
diff --git a/ext/pdo/pdo.c b/ext/pdo/pdo.c
index d928e34..ca3afe1 100755
--- a/ext/pdo/pdo.c
+++ b/ext/pdo/pdo.c
@@ -18,7 +18,7 @@
   +----------------------------------------------------------------------+
 */
 
-/* $Id: pdo.c 284394 2009-07-19 22:46:03Z felipe $ */
+/* $Id: pdo.c 291781 2009-12-06 21:32:58Z pierrick $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -217,6 +217,7 @@ PDO_API int php_pdo_parse_data_source(const char *data_source,
 	int optstart = 0;
 	int nlen;
 	int n_matches = 0;
+	int n_semicolumns = 0;
 
 	i = 0;
 	while (i < data_source_len) {
@@ -235,14 +236,21 @@ PDO_API int php_pdo_parse_data_source(const char *data_source,
 
 		/* now we're looking for VALUE; or just VALUE<NUL> */
 		semi = -1;
+		n_semicolumns = 0;
 		while (i < data_source_len) {
 			if (data_source[i] == '\0') {
 				semi = i++;
 				break;
 			}
 			if (data_source[i] == ';') {
-				semi = i++;
-				break;
+				if ((i + 1 >= data_source_len) || data_source[i+1] != ';') {
+					semi = i++;
+					break;
+				} else {
+					n_semicolumns++; 
+					i += 2;
+					continue;
+				}
 			}
 			++i;
 		}
@@ -259,7 +267,31 @@ PDO_API int php_pdo_parse_data_source(const char *data_source,
 				if (parsed[j].freeme) {
 					efree(parsed[j].optval);
 				}
-				parsed[j].optval = estrndup(data_source + valstart, semi - valstart);
+
+				if (n_semicolumns == 0) {
+					parsed[j].optval = estrndup(data_source + valstart, semi - valstart - n_semicolumns);
+				} else {
+					int vlen = semi - valstart;
+					char *orig_val = data_source + valstart;
+					char *new_val  = (char *) emalloc(vlen - n_semicolumns + 1);
+				
+					parsed[j].optval = new_val;
+
+					while (vlen && *orig_val) {
+						*new_val = *orig_val;
+						new_val++;
+
+						if (*orig_val == ';') {
+							orig_val+=2; 
+							vlen-=2;
+						} else {
+							orig_val++;
+							vlen--;
+						}
+					}
+					*new_val = '\0';
+				}
+
 				parsed[j].freeme = 1;
 				++n_matches;
 				break;
diff --git a/ext/pdo/pdo_dbh.c b/ext/pdo/pdo_dbh.c
index 5f833cc..d4f3d35 100755
--- a/ext/pdo/pdo_dbh.c
+++ b/ext/pdo/pdo_dbh.c
@@ -18,7 +18,7 @@
   +----------------------------------------------------------------------+
 */
 
-/* $Id: pdo_dbh.c 279722 2009-05-02 15:58:39Z iliaa $ */
+/* $Id: pdo_dbh.c 292083 2009-12-13 19:53:44Z felipe $ */
 
 /* The PDO Database Handle Class */
 
@@ -44,7 +44,7 @@ void pdo_raise_impl_error(pdo_dbh_t *dbh, pdo_stmt_t *stmt, const char *sqlstate
 	char *message = NULL;
 	const char *msg;
 
-	if (dbh->error_mode == PDO_ERRMODE_SILENT) {
+	if (dbh && dbh->error_mode == PDO_ERRMODE_SILENT) {
 #if 0
 		/* BUG: if user is running in silent mode and hits an error at the driver level
 		 * when they use the PDO methods to call up the error information, they may
@@ -71,7 +71,7 @@ void pdo_raise_impl_error(pdo_dbh_t *dbh, pdo_stmt_t *stmt, const char *sqlstate
 		spprintf(&message, 0, "SQLSTATE[%s]: %s", *pdo_err, msg);
 	}
 
-	if (dbh->error_mode != PDO_ERRMODE_EXCEPTION) {
+	if (dbh && dbh->error_mode != PDO_ERRMODE_EXCEPTION) {
 		php_error_docref(NULL TSRMLS_CC, E_WARNING, "%s", message);
 	} else {
 		zval *ex, *info;
@@ -110,7 +110,7 @@ void pdo_handle_error(pdo_dbh_t *dbh, pdo_stmt_t *stmt TSRMLS_DC) /* {{{ */
 	char *message = NULL;
 	zval *info = NULL;
 
-	if (dbh->error_mode == PDO_ERRMODE_SILENT) {
+	if (dbh == NULL || dbh->error_mode == PDO_ERRMODE_SILENT) {
 		return;
 	}
 	
@@ -1091,8 +1091,7 @@ static PHP_METHOD(PDO, quote)
 	char *qstr;
 	int qlen;
 
-	if (FAILURE == zend_parse_parameters(1 TSRMLS_CC, "s|l", &str, &str_len,
-			&paramtype)) {
+	if (FAILURE == zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s|l", &str, &str_len, &paramtype)) {
 		RETURN_FALSE;
 	}
 	
diff --git a/ext/pdo/pdo_stmt.c b/ext/pdo/pdo_stmt.c
index e501d8f..e5feb00 100755
--- a/ext/pdo/pdo_stmt.c
+++ b/ext/pdo/pdo_stmt.c
@@ -18,7 +18,7 @@
   +----------------------------------------------------------------------+
 */
 
-/* $Id: pdo_stmt.c 288013 2009-09-03 22:53:25Z mbeccati $ */
+/* $Id: pdo_stmt.c 292003 2009-12-11 22:30:46Z felipe $ */
 
 /* The PDO Statement Handle Class */
 
@@ -509,6 +509,7 @@ static PHP_METHOD(PDOStatement, execute)
 			/* no changes were made */
 			stmt->active_query_string = stmt->query_string;
 			stmt->active_query_stringlen = stmt->query_stringlen;
+			ret = 1;
 		} else if (ret == -1) {
 			/* something broke */
 			PDO_HANDLE_STMT_ERR();
@@ -1102,6 +1103,32 @@ static int do_fetch(pdo_stmt_t *stmt, int do_bind, zval *return_value,
 			}
 		}
 
+		switch (how) {
+			case PDO_FETCH_CLASS:
+				if (ce->constructor && !(flags & PDO_FETCH_PROPS_LATE)) {
+					stmt->fetch.cls.fci.object_pp = &return_value;
+					stmt->fetch.cls.fcc.object_pp = &return_value;
+					if (zend_call_function(&stmt->fetch.cls.fci, &stmt->fetch.cls.fcc TSRMLS_CC) == FAILURE) {
+						pdo_raise_impl_error(stmt->dbh, stmt, "HY000", "could not call class constructor" TSRMLS_CC);
+						return 0;
+					} else {
+						if (stmt->fetch.cls.retval_ptr) {
+							zval_ptr_dtor(&stmt->fetch.cls.retval_ptr);
+						}
+					}
+				}
+				if (flags & PDO_FETCH_CLASSTYPE) {
+					do_fetch_opt_finish(stmt, 0 TSRMLS_CC);
+					stmt->fetch.cls.ce = old_ce;
+					stmt->fetch.cls.ctor_args = old_ctor_args;
+					stmt->fetch.cls.fci.param_count = old_arg_count;
+				}
+				break;
+
+			default:
+				break;
+		}
+
 		for (idx = 0; i < stmt->column_count; i++, idx++) {
 			zval *val;
 			MAKE_STD_ZVAL(val);
@@ -1235,27 +1262,6 @@ static int do_fetch(pdo_stmt_t *stmt, int do_bind, zval *return_value,
 		}
 		
 		switch (how) {
-			case PDO_FETCH_CLASS:
-				if (ce->constructor && !(flags & PDO_FETCH_PROPS_LATE)) {
-					stmt->fetch.cls.fci.object_pp = &return_value;
-					stmt->fetch.cls.fcc.object_pp = &return_value;
-					if (zend_call_function(&stmt->fetch.cls.fci, &stmt->fetch.cls.fcc TSRMLS_CC) == FAILURE) {
-						pdo_raise_impl_error(stmt->dbh, stmt, "HY000", "could not call class constructor" TSRMLS_CC);
-						return 0;
-					} else {
-						if (stmt->fetch.cls.retval_ptr) {
-							zval_ptr_dtor(&stmt->fetch.cls.retval_ptr);
-						}
-					}
-				}
-				if (flags & PDO_FETCH_CLASSTYPE) {
-					do_fetch_opt_finish(stmt, 0 TSRMLS_CC);
-					stmt->fetch.cls.ce = old_ce;
-					stmt->fetch.cls.ctor_args = old_ctor_args;
-					stmt->fetch.cls.fci.param_count = old_arg_count;
-				}
-				break;
-
 			case PDO_FETCH_FUNC:
 				stmt->fetch.func.fci.param_count = idx;
 				stmt->fetch.func.fci.retval_ptr_ptr = &retval;
@@ -1653,19 +1659,21 @@ static PHP_METHOD(PDOStatement, fetchAll)
 static int register_bound_param(INTERNAL_FUNCTION_PARAMETERS, pdo_stmt_t *stmt, int is_param) /* {{{ */
 {
 	struct pdo_bound_param_data param = {0};
+	long param_type = PDO_PARAM_STR;
 
 	param.paramno = -1;
-	param.param_type = PDO_PARAM_STR;
 
 	if (FAILURE == zend_parse_parameters_ex(ZEND_PARSE_PARAMS_QUIET, ZEND_NUM_ARGS() TSRMLS_CC,
-			"lz|llz!", &param.paramno, &param.parameter, &param.param_type, &param.max_value_len,
+			"lz|llz!", &param.paramno, &param.parameter, &param_type, &param.max_value_len,
 			&param.driver_params)) {
 		if (FAILURE == zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "sz|llz!", &param.name,
-				&param.namelen, &param.parameter, &param.param_type, &param.max_value_len, 
+				&param.namelen, &param.parameter, &param_type, &param.max_value_len, 
 				&param.driver_params)) {
 			return 0;
 		}	
 	}
+	
+	param.param_type = (int) param_type;
 
 	if (param.paramno > 0) {
 		--param.paramno; /* make it zero-based internally */
@@ -2597,26 +2605,28 @@ static zval *row_prop_or_dim_read(zval *object, zval *member, int type TSRMLS_DC
 
 	MAKE_STD_ZVAL(return_value);
 	RETVAL_NULL();
-		
-	if (Z_TYPE_P(member) == IS_LONG) {
-		if (Z_LVAL_P(member) >= 0 && Z_LVAL_P(member) < stmt->column_count) {
-			fetch_value(stmt, return_value, Z_LVAL_P(member), NULL TSRMLS_CC);
-		}
-	} else {
-		convert_to_string(member);
-		/* TODO: replace this with a hash of available column names to column
-		 * numbers */
-		for (colno = 0; colno < stmt->column_count; colno++) {
-			if (strcmp(stmt->columns[colno].name, Z_STRVAL_P(member)) == 0) {
-				fetch_value(stmt, return_value, colno, NULL TSRMLS_CC);
-				return_value->refcount = 0;
-				return_value->is_ref = 0;
-				return return_value;
+	
+	if (stmt) {
+		if (Z_TYPE_P(member) == IS_LONG) {
+			if (Z_LVAL_P(member) >= 0 && Z_LVAL_P(member) < stmt->column_count) {
+				fetch_value(stmt, return_value, Z_LVAL_P(member), NULL TSRMLS_CC);
+			}
+		} else {
+			convert_to_string(member);
+			/* TODO: replace this with a hash of available column names to column
+			 * numbers */
+			for (colno = 0; colno < stmt->column_count; colno++) {
+				if (strcmp(stmt->columns[colno].name, Z_STRVAL_P(member)) == 0) {
+					fetch_value(stmt, return_value, colno, NULL TSRMLS_CC);
+					return_value->refcount = 0;
+					return_value->is_ref = 0;
+					return return_value;
+				}
+			}
+			if (strcmp(Z_STRVAL_P(member), "queryString") == 0) {
+				zval_ptr_dtor(&return_value);
+				return std_object_handlers.read_property(object, member, IS_STRING TSRMLS_CC);
 			}
-		}
-		if (strcmp(Z_STRVAL_P(member), "queryString") == 0) {
-			zval_ptr_dtor(&return_value);
-			return std_object_handlers.read_property(object, member, IS_STRING TSRMLS_CC);
 		}
 	}
 
@@ -2636,16 +2646,18 @@ static int row_prop_or_dim_exists(zval *object, zval *member, int check_empty TS
 	pdo_stmt_t * stmt = (pdo_stmt_t *) zend_object_store_get_object(object TSRMLS_CC);
 	int colno = -1;
 
-	if (Z_TYPE_P(member) == IS_LONG) {
-		return Z_LVAL_P(member) >= 0 && Z_LVAL_P(member) < stmt->column_count;
-	} else {
-		convert_to_string(member);
+	if (stmt) {
+		if (Z_TYPE_P(member) == IS_LONG) {
+			return Z_LVAL_P(member) >= 0 && Z_LVAL_P(member) < stmt->column_count;
+		} else {
+			convert_to_string(member);
 
-		/* TODO: replace this with a hash of available column names to column
-		 * numbers */
-		for (colno = 0; colno < stmt->column_count; colno++) {
-			if (strcmp(stmt->columns[colno].name, Z_STRVAL_P(member)) == 0) {
-				return 1;
+			/* TODO: replace this with a hash of available column names to column
+			 * numbers */
+			for (colno = 0; colno < stmt->column_count; colno++) {
+				if (strcmp(stmt->columns[colno].name, Z_STRVAL_P(member)) == 0) {
+					return 1;
+				}
 			}
 		}
 	}
@@ -2663,6 +2675,10 @@ static HashTable *row_get_properties(zval *object TSRMLS_DC)
 	pdo_stmt_t * stmt = (pdo_stmt_t *) zend_object_store_get_object(object TSRMLS_CC);
 	int i;
 
+	if (stmt == NULL) {
+		return NULL;
+	}
+	
 	for (i = 0; i < stmt->column_count; i++) {
 		zval *val;
 		MAKE_STD_ZVAL(val);
diff --git a/ext/pdo/tests/pdo_005.phpt b/ext/pdo/tests/pdo_005.phpt
index c0264d9..d30fccd 100644
--- a/ext/pdo/tests/pdo_005.phpt
+++ b/ext/pdo/tests/pdo_005.phpt
@@ -34,7 +34,7 @@ class TestDerived extends TestBase
 
 	public function __construct(&$row)
 	{
-		echo __METHOD__ . "($row,{$this->id})\n";
+		echo __METHOD__ . "($row)\n";
 		$this->row = $row++;
 	}
 }
@@ -108,9 +108,9 @@ array(3) {
     string(2) "CC"
   }
 }
-TestDerived::__construct(0,1)
-TestDerived::__construct(1,2)
-TestDerived::__construct(2,3)
+TestDerived::__construct(0)
+TestDerived::__construct(1)
+TestDerived::__construct(2)
 array(3) {
   [0]=>
   object(TestDerived)#%d (5) {
diff --git a/ext/pdo/tests/pdo_036.phpt b/ext/pdo/tests/pdo_036.phpt
new file mode 100644
index 0000000..6bd38cb
--- /dev/null
+++ b/ext/pdo/tests/pdo_036.phpt
@@ -0,0 +1,21 @@
+--TEST--
+Testing PDORow and PDOStatement instances with Reflection
+--FILE--
+<?php
+
+$instance = new reflectionclass('pdorow');
+$x = $instance->newInstance();
+var_dump($x);
+
+$instance = new reflectionclass('pdostatement');
+$x = $instance->newInstance();
+var_dump($x);
+
+?>
+--EXPECTF--
+object(PDORow)#%d (0) {
+}
+object(PDOStatement)#%d (1) {
+  [%u|b%"queryString"]=>
+  NULL
+}
diff --git a/ext/pdo_dblib/config.m4 b/ext/pdo_dblib/config.m4
index 617ed36..69711ce 100644
--- a/ext/pdo_dblib/config.m4
+++ b/ext/pdo_dblib/config.m4
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: config.m4 266963 2008-10-04 13:19:22Z felipe $
+dnl $Id: config.m4 291414 2009-11-29 06:13:22Z rasmus $
 dnl
 
 if test "$PHP_PDO" != "no"; then
diff --git a/ext/pdo_firebird/config.m4 b/ext/pdo_firebird/config.m4
index 76b69fb..45b04b3 100644
--- a/ext/pdo_firebird/config.m4
+++ b/ext/pdo_firebird/config.m4
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: config.m4 240511 2007-07-31 13:02:00Z jani $
+dnl $Id: config.m4 291414 2009-11-29 06:13:22Z rasmus $
 dnl
 
 if test "$PHP_PDO" != "no"; then
diff --git a/ext/pdo_firebird/pdo_firebird.c b/ext/pdo_firebird/pdo_firebird.c
index b8d9cb9..75b4a17 100644
--- a/ext/pdo_firebird/pdo_firebird.c
+++ b/ext/pdo_firebird/pdo_firebird.c
@@ -16,7 +16,7 @@
   +----------------------------------------------------------------------+
 */
 
-/* $Id: pdo_firebird.c 284399 2009-07-19 23:33:50Z felipe $ */
+/* $Id: pdo_firebird.c 289750 2009-10-19 15:34:50Z jani $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -38,7 +38,7 @@ zend_function_entry pdo_firebird_functions[] = { /* {{{ */
 /* {{{ pdo_firebird_deps
  */
 #if ZEND_MODULE_API_NO >= 20050922
-static const zend_module_dep pdo_firebird_deps[] = {
+static zend_module_dep pdo_firebird_deps[] = {
 	ZEND_MOD_REQUIRED("pdo")
 	{NULL, NULL, NULL}
 };
diff --git a/ext/pdo_mysql/config.m4 b/ext/pdo_mysql/config.m4
index 3aeb141..499b89b 100755
--- a/ext/pdo_mysql/config.m4
+++ b/ext/pdo_mysql/config.m4
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: config.m4 240511 2007-07-31 13:02:00Z jani $
+dnl $Id: config.m4 291414 2009-11-29 06:13:22Z rasmus $
 dnl
 
 if test "$PHP_PDO" != "no"; then
diff --git a/ext/pdo_mysql/tests/bug_45120.phpt b/ext/pdo_mysql/tests/bug_45120.phpt
new file mode 100644
index 0000000..db5da82
--- /dev/null
+++ b/ext/pdo_mysql/tests/bug_45120.phpt
@@ -0,0 +1,48 @@
+--TEST--
+Bug #45120 (PDOStatement->execute() returns true then false for same statement)
+--SKIPIF--
+<?php
+if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded');
+require dirname(__FILE__) . '/config.inc';
+require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc';
+PDOTest::skip();
+?>
+--FILE--
+<?php
+require dirname(__FILE__) . '/config.inc';
+require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc';
+$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt');
+
+function bug_45120($db) {
+
+	$stmt = $db->prepare("SELECT 1 AS 'one'");
+	if (true !== $stmt->execute())
+		printf("[001] Execute has failed: %s\n", var_export($stmt->errorInfo(), true));
+
+	$res = $stmt->fetch(PDO::FETCH_ASSOC);
+	if ($res['one'] != 1)
+		printf("[002] Wrong results: %s\n", var_export($res, true));
+
+	if (true !== $stmt->execute())
+		printf("[003] Execute has failed: %s\n", var_export($stmt->errorInfo(), true));
+
+	$res = $stmt->fetch(PDO::FETCH_ASSOC);
+	if ($res['one'] != 1)
+		printf("[004] Wrong results: %s\n", var_export($res, true));
+
+}
+
+print "Emulated Prepared Statements\n";
+$db->setAttribute(PDO::ATTR_EMULATE_PREPARES, 1);
+bug_45120($db);
+
+print "Native Prepared Statements\n";
+$db->setAttribute(PDO::ATTR_EMULATE_PREPARES, 0);
+bug_45120($db);
+
+print "done!";
+?>
+--EXPECT--
+Emulated Prepared Statements
+Native Prepared Statements
+done!
diff --git a/ext/pdo_mysql/tests/bug_50323.phpt b/ext/pdo_mysql/tests/bug_50323.phpt
new file mode 100644
index 0000000..02050fa
--- /dev/null
+++ b/ext/pdo_mysql/tests/bug_50323.phpt
@@ -0,0 +1,61 @@
+--TEST--
+Bug #50323 (No ability to connect to database named 't;', no chance to escape semicolon)
+--SKIPIF--
+<?php
+if (!extension_loaded('pdo') || !extension_loaded('pdo_mysql')) die('skip not loaded');
+require dirname(__FILE__) . '/config.inc';
+require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc';
+PDOTest::skip();
+?>
+--FILE--
+<?php
+require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc';
+$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt');
+
+    function changeDSN($original, $new_options) {
+        $old_options = array();
+        $dsn = substr($original,
+                strpos($original, ':') + 1,
+                strlen($original));
+
+        // no real parser - any excotic setting can fool us
+        $parts = explode(';', $dsn);
+        foreach ($parts as $k => $v) {
+            $tmp = explode('=', $v);
+            if (count($tmp) == 2)
+                    $old_options[$tmp[0]] = $tmp[1];
+        }
+
+        $options = $old_options;
+        foreach ($new_options as $k => $v)
+            $options[$k] = $v;
+
+        $dsn = 'mysql:';
+        foreach ($options as $k => $v)
+            $dsn .= sprintf('%s=%s;', $k, $v);
+
+        $dsn = substr($dsn, 0, strlen($dsn) -1);
+
+        return $dsn;
+    }
+
+
+if (1 === @$db->exec('CREATE DATABASE `crazy;dbname`')) {
+    $dsn = changeDSN(getenv('PDOTEST_DSN'), array('dbname' => 'crazy;;dbname'));
+    $user = getenv('PDOTEST_USER');
+    $pass = getenv('PDOTEST_PASS');
+    
+    new PDO($dsn, $user, $pass);
+}
+echo 'done!';
+?>
+--CLEAN--
+<?php
+require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc';
+$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt');
+
+@$db->exec('DROP DATABASE IF EXISTS `crazy;dbname`');
+?>
+--EXPECTF--
+done!
+
diff --git a/ext/pdo_oci/config.m4 b/ext/pdo_oci/config.m4
index c85fd26..8043d21 100755
--- a/ext/pdo_oci/config.m4
+++ b/ext/pdo_oci/config.m4
@@ -1,4 +1,4 @@
-dnl $Id: config.m4 242010 2007-08-31 21:08:48Z sixd $
+dnl $Id: config.m4 291414 2009-11-29 06:13:22Z rasmus $
 
 if test "$PHP_PDO" != "no"; then
 
diff --git a/ext/pdo_odbc/config.m4 b/ext/pdo_odbc/config.m4
index e9db786..d50c835 100755
--- a/ext/pdo_odbc/config.m4
+++ b/ext/pdo_odbc/config.m4
@@ -1,4 +1,4 @@
-dnl $Id: config.m4 239334 2007-07-09 12:38:02Z jani $
+dnl $Id: config.m4 291414 2009-11-29 06:13:22Z rasmus $
 dnl config.m4 for extension pdo_odbc
 dnl vim:et:sw=2:ts=2:
 
diff --git a/ext/pdo_pgsql/config.m4 b/ext/pdo_pgsql/config.m4
index 5136fdd..e45321a 100644
--- a/ext/pdo_pgsql/config.m4
+++ b/ext/pdo_pgsql/config.m4
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: config.m4 240511 2007-07-31 13:02:00Z jani $
+dnl $Id: config.m4 291414 2009-11-29 06:13:22Z rasmus $
 dnl
 
 if test "$PHP_PDO" != "no"; then
diff --git a/ext/pdo_pgsql/pdo_pgsql.c b/ext/pdo_pgsql/pdo_pgsql.c
index c9d13f4..3a5a5a3 100644
--- a/ext/pdo_pgsql/pdo_pgsql.c
+++ b/ext/pdo_pgsql/pdo_pgsql.c
@@ -16,7 +16,7 @@
   +----------------------------------------------------------------------+
 */
 
-/* $Id: pdo_pgsql.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: pdo_pgsql.c 289287 2009-10-07 17:40:16Z mbeccati $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -80,8 +80,8 @@ ZEND_GET_MODULE(pdo_pgsql)
  */
 PHP_MINIT_FUNCTION(pdo_pgsql)
 {
-	php_pdo_register_driver(&pdo_pgsql_driver);
 	REGISTER_PDO_CLASS_CONST_LONG("PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT", PDO_PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT);
+	php_pdo_register_driver(&pdo_pgsql_driver);
 	return SUCCESS;
 }
 /* }}} */
@@ -123,7 +123,7 @@ PHP_MINFO_FUNCTION(pdo_pgsql)
 	php_info_print_table_row(2, "PostgreSQL(libpq) Version", PG_VERSION);
 #endif	
 	php_info_print_table_row(2, "Module version", pdo_pgsql_module_entry.version);
-	php_info_print_table_row(2, "Revision", " $Id: pdo_pgsql.c 272374 2008-12-31 11:17:49Z sebastian $ ");
+	php_info_print_table_row(2, "Revision", " $Id: pdo_pgsql.c 289287 2009-10-07 17:40:16Z mbeccati $ ");
 
 	php_info_print_table_end();
 }
diff --git a/ext/pdo_pgsql/pgsql_driver.c b/ext/pdo_pgsql/pgsql_driver.c
index 10966f2..4016728 100644
--- a/ext/pdo_pgsql/pgsql_driver.c
+++ b/ext/pdo_pgsql/pgsql_driver.c
@@ -18,7 +18,7 @@
   +----------------------------------------------------------------------+
 */
 
-/* $Id: pgsql_driver.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: pgsql_driver.c 290214 2009-11-04 19:32:27Z mbeccati $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -233,19 +233,18 @@ static int pgsql_handle_preparer(pdo_dbh_t *dbh, const char *sql, long sql_len,
 			efree(S->cursor_name);
 		}
 		/* TODO: check how scrollable cursors related to prepared statements */
-		spprintf(&S->cursor_name, 0, "pdo_pgsql_cursor_%08x", (unsigned int) stmt);
+		spprintf(&S->cursor_name, 0, "pdo_crsr_%08x", ++H->stmt_counter);
 	}
 
 #if HAVE_PQPREPARE
 
 	if (driver_options) {
-		if (pdo_attr_lval(driver_options,
-				PDO_PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT, 0 TSRMLS_CC) == 1) {
-			emulate = 1;
-		} else if (pdo_attr_lval(driver_options, PDO_ATTR_EMULATE_PREPARES,
-				0 TSRMLS_CC) == 1) {
+		if (pdo_attr_lval(driver_options, PDO_PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT, H->disable_native_prepares TSRMLS_CC) == 1 ||
+			pdo_attr_lval(driver_options, PDO_ATTR_EMULATE_PREPARES, H->emulate_prepares TSRMLS_CC) == 1) {
 			emulate = 1;
 		}
+	} else {
+		emulate = H->disable_native_prepares || H->emulate_prepares;
 	}
 
 	if (!emulate && PQprotocolVersion(H->server) > 2) {
@@ -262,7 +261,7 @@ static int pgsql_handle_preparer(pdo_dbh_t *dbh, const char *sql, long sql_len,
 			return 0;
 		}
 
-		spprintf(&S->stmt_name, 0, "pdo_pgsql_stmt_%08x", (unsigned int)stmt);
+		spprintf(&S->stmt_name, 0, "pdo_stmt_%08x", ++H->stmt_counter);
 		/* that's all for now; we'll defer the actual prepare until the first execute call */
 	
 		if (nsql) {
@@ -646,7 +645,21 @@ static zend_function_entry *pdo_pgsql_get_driver_methods(pdo_dbh_t *dbh, int kin
 
 static int pdo_pgsql_set_attr(pdo_dbh_t *dbh, long attr, zval *val TSRMLS_DC)
 {
-	return 0;
+	pdo_pgsql_db_handle *H = (pdo_pgsql_db_handle *)dbh->driver_data;
+
+	switch (attr) {
+#if HAVE_PQPREPARE
+		case PDO_ATTR_EMULATE_PREPARES:
+			H->emulate_prepares = Z_LVAL_P(val);
+			return 1;
+		case PDO_PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT:
+			H->disable_native_prepares = Z_LVAL_P(val);
+			return 1;
+#endif
+
+		default:
+			return 0;
+	}
 }
 
 static struct pdo_dbh_methods pgsql_methods = {
diff --git a/ext/pdo_pgsql/pgsql_statement.c b/ext/pdo_pgsql/pgsql_statement.c
index c350cdd..56df9cc 100644
--- a/ext/pdo_pgsql/pgsql_statement.c
+++ b/ext/pdo_pgsql/pgsql_statement.c
@@ -18,7 +18,7 @@
   +----------------------------------------------------------------------+
 */
 
-/* $Id: pgsql_statement.c 288013 2009-09-03 22:53:25Z mbeccati $ */
+/* $Id: pgsql_statement.c 290214 2009-11-04 19:32:27Z mbeccati $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -157,7 +157,7 @@ stmt_retry:
 					 * deallocate it and retry ONCE (thies 2005.12.15)
 					 */
 					if (!strcmp(sqlstate, "42P05")) {
-						char buf[100]; /* stmt_name == "pdo_pgsql_cursor_%08x" */
+						char buf[100]; /* stmt_name == "pdo_crsr_%08x" */
 						PGresult *res;
 						snprintf(buf, sizeof(buf), "DEALLOCATE %s", S->stmt_name);
 						res = PQexec(H->server, buf);
diff --git a/ext/pdo_pgsql/php_pdo_pgsql_int.h b/ext/pdo_pgsql/php_pdo_pgsql_int.h
index d64034e..97f7eca 100644
--- a/ext/pdo_pgsql/php_pdo_pgsql_int.h
+++ b/ext/pdo_pgsql/php_pdo_pgsql_int.h
@@ -18,7 +18,7 @@
   +----------------------------------------------------------------------+
 */
 
-/* $Id: php_pdo_pgsql_int.h 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: php_pdo_pgsql_int.h 290214 2009-11-04 19:32:27Z mbeccati $ */
 
 #ifndef PHP_PDO_PGSQL_INT_H
 #define PHP_PDO_PGSQL_INT_H
@@ -43,6 +43,14 @@ typedef struct {
 	unsigned 	_reserved:31;
 	pdo_pgsql_error_info	einfo;
 	Oid 		pgoid;
+#if HAVE_PQPREPARE
+	/* The following two variables have the same purpose. Unfortunately we need
+	   to keep track of two different attributes having the same effect.
+	   It might be worth to deprecate the driver specific one soon. */
+	int		emulate_prepares;
+	int		disable_native_prepares;
+#endif
+	unsigned int stmt_counter;
 } pdo_pgsql_db_handle;
 
 typedef struct {
diff --git a/ext/pdo_pgsql/tests/bug48764.phpt b/ext/pdo_pgsql/tests/bug48764.phpt
new file mode 100644
index 0000000..70c8c6f
--- /dev/null
+++ b/ext/pdo_pgsql/tests/bug48764.phpt
@@ -0,0 +1,134 @@
+--TEST--
+Bug #48764 (PDO_pgsql::query always uses implicit prepared statements if v3 proto available)
+--SKIPIF--
+<?php
+if (!extension_loaded('pdo') || !extension_loaded('pdo_pgsql')) die('skip not loaded');
+require dirname(__FILE__) . '/config.inc';
+require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc';
+PDOTest::skip();
+
+$db = PDOTest::factory();
+
+$client_version = $db->getAttribute(PDO::ATTR_CLIENT_VERSION);
+$server_version = $db->getAttribute(PDO::ATTR_SERVER_VERSION);
+
+if (version_compare($server_version, '7.4', '<') || version_compare($client_version, '7.4', '<')) {
+	die('skip');
+}
+
+?>
+--FILE--
+<?php
+require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc';
+$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt');
+$db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
+
+echo "Test 1\n";
+bug($db);
+
+echo "Test 2\n";
+bug($db, array(PDO::ATTR_EMULATE_PREPARES => 0));
+bug($db, array(PDO::ATTR_EMULATE_PREPARES => 1));
+
+echo "Test 3\n";
+bug($db, array(PDO::PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT => 0));
+bug($db, array(PDO::PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT => 1));
+
+echo "Test 4\n";
+$db->setAttribute(PDO::ATTR_EMULATE_PREPARES, 1);
+bug($db);
+$db->setAttribute(PDO::ATTR_EMULATE_PREPARES, 0);
+bug($db);
+
+echo "Test 5\n";
+$db->setAttribute(PDO::PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT, 1);
+bug($db);
+$db->setAttribute(PDO::PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT, 0);
+bug($db);
+
+
+putenv('PDOTEST_ATTR='.serialize(array(
+	PDO::ATTR_EMULATE_PREPARES => 1,
+)));
+$db = PDOTest::factory('PDO', false);
+$db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
+
+echo "Test 6\n";
+bug($db);
+bug($db, array(PDO::ATTR_EMULATE_PREPARES => 0));
+bug($db, array(PDO::PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT => 0));
+
+
+putenv('PDOTEST_ATTR='.serialize(array(
+	PDO::PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT => 1,
+)));
+
+$db = PDOTest::factory('PDO', false);
+$db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
+
+echo "Test 7\n";
+bug($db);
+bug($db, array(PDO::ATTR_EMULATE_PREPARES => 0));
+bug($db, array(PDO::PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT => 0));
+
+
+putenv('PDOTEST_ATTR='.serialize(array(
+	PDO::ATTR_EMULATE_PREPARES => 1,
+	PDO::PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT => 1,
+)));
+
+$db = PDOTest::factory('PDO', false);
+$db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
+
+echo "Test 8\n";
+bug($db);
+bug($db, array(PDO::ATTR_EMULATE_PREPARES => 0));
+bug($db, array(PDO::PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT => 0));
+bug($db, array(
+	PDO::ATTR_EMULATE_PREPARES => 0,
+	PDO::PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT => 0,
+));
+
+
+putenv('PDOTEST_ATTR');
+
+
+function bug($db, $options = array()) {
+	try {
+		$stmt = $db->prepare("SELECT ?", $options);
+		$stmt->execute(array(1));
+		echo "OK\n";
+	} catch (PDOException $e) {
+		// Indetermined data type when using native prepared statements
+		echo $e->getCode()."\n";
+	}
+}
+
+--EXPECT--
+Test 1
+42P18
+Test 2
+42P18
+OK
+Test 3
+42P18
+OK
+Test 4
+OK
+42P18
+Test 5
+OK
+42P18
+Test 6
+OK
+42P18
+OK
+Test 7
+OK
+OK
+42P18
+Test 8
+OK
+OK
+OK
+42P18
diff --git a/ext/pdo_pgsql/tests/bug_49985.phpt b/ext/pdo_pgsql/tests/bug_49985.phpt
new file mode 100644
index 0000000..7ada876
--- /dev/null
+++ b/ext/pdo_pgsql/tests/bug_49985.phpt
@@ -0,0 +1,35 @@
+--TEST--
+Bug #49985 (pdo_pgsql prepare() re-use previous aborted transaction)
+--SKIPIF--
+<?php
+if (!extension_loaded('pdo') || !extension_loaded('pdo_pgsql')) die('skip not loaded');
+require dirname(__FILE__) . '/config.inc';
+require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc';
+PDOTest::skip();
+?>
+--FILE--
+<?php
+require dirname(__FILE__) . '/../../../ext/pdo/tests/pdo_test.inc';
+$db = PDOTest::test_factory(dirname(__FILE__) . '/common.phpt');
+$db->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
+
+$db->exec("CREATE TABLE test (a int PRIMARY KEY)");
+
+for ($i = 0; $i < 3; $i++) {
+    try {
+        $db->beginTransaction();
+        $stmt = $db->prepare("INSERT INTO test (a) VALUES (?)");
+        var_dump($stmt->execute(array(1)));
+        $db->commit();
+    } catch (Exception $e) {
+        echo $e->getMessage()."\n";
+        $db->rollback();
+    }
+}
+
+?>
+--EXPECTF--
+bool(true)
+SQLSTATE[23505]: %s"test_pkey"
+SQLSTATE[23505]: %s"test_pkey"
+
diff --git a/ext/pdo_sqlite/config.m4 b/ext/pdo_sqlite/config.m4
index d233de1..81e3235 100644
--- a/ext/pdo_sqlite/config.m4
+++ b/ext/pdo_sqlite/config.m4
@@ -1,4 +1,4 @@
-dnl $Id: config.m4 239118 2007-07-03 17:25:43Z sniper $
+dnl $Id: config.m4 291414 2009-11-29 06:13:22Z rasmus $
 dnl config.m4 for extension pdo_sqlite
 dnl vim:et:sw=2:ts=2:
 
diff --git a/ext/pdo_sqlite/tests/bug49521.phpt b/ext/pdo_sqlite/tests/bug49521.phpt
new file mode 100644
index 0000000..26cd2b2
--- /dev/null
+++ b/ext/pdo_sqlite/tests/bug49521.phpt
@@ -0,0 +1,39 @@
+--TEST--
+Bug #49521 (PDO fetchObject sets values before calling constructor)
+--SKIPIF--
+<?php
+if (!extension_loaded('pdo_sqlite')) die ("skip Need PDO_SQlite support");
+?>
+--FILE--
+<?php
+
+class Book {
+    public $title = 'test';
+    public $author;
+    
+	public function __construct($x) {
+		$this->title = '';
+		echo __METHOD__,"\n";
+	}
+	public function __set($a, $b) {
+		echo __METHOD__,"\n";
+		var_dump($a);
+	}
+}
+
+$pdo = new PDO('sqlite::memory:');
+$pdo->exec('CREATE TABLE book(title,author)');
+$pdo->exec('INSERT INTO book VALUES ("PHP","Rasmus")');
+$statement = $pdo->prepare('SELECT * FROM book WHERE title="PHP"');
+$statement->execute();
+var_dump($statement->fetchObject('Book', array(1)));
+
+?>
+--EXPECTF--
+Book::__construct
+object(Book)#%d (2) {
+  [%u|b%"title"]=>
+  string(3) "PHP"
+  [%u|b%"author"]=>
+  string(6) "Rasmus"
+}
diff --git a/ext/pgsql/pgsql.c b/ext/pgsql/pgsql.c
index 82c9ab4..2ac674a 100644
--- a/ext/pgsql/pgsql.c
+++ b/ext/pgsql/pgsql.c
@@ -20,7 +20,7 @@
    +----------------------------------------------------------------------+
  */
  
-/* $Id: pgsql.c 277070 2009-03-12 22:54:15Z iliaa $ */
+/* $Id: pgsql.c 291335 2009-11-27 03:02:01Z iliaa $ */
 
 #include <stdlib.h>
 
@@ -363,7 +363,7 @@ static void _php_pgsql_notice_handler(void *resource_id, const char *message)
 		if (PGG(log_notices)) {
 			php_error_docref(NULL TSRMLS_CC, E_NOTICE, "%s", notice->message);
 		}
-		zend_hash_index_update(&PGG(notices), (int)resource_id, (void **)&notice, sizeof(php_pgsql_notice *), NULL);
+		zend_hash_index_update(&PGG(notices), (ulong)resource_id, (void **)&notice, sizeof(php_pgsql_notice *), NULL);
 	}
 }
 /* }}} */
@@ -761,13 +761,14 @@ static void php_pgsql_do_connect(INTERNAL_FUNCTION_PARAMETERS, int persistent)
 		 */
 		if (!(connect_type & PGSQL_CONNECT_FORCE_NEW)
 			&& zend_hash_find(&EG(regular_list),str.c,str.len+1,(void **) &index_ptr)==SUCCESS) {
-			int type,link;
+			int type;
+			ulong link;
 			void *ptr;
 
 			if (Z_TYPE_P(index_ptr) != le_index_ptr) {
 				RETURN_FALSE;
 			}
-			link = (int) index_ptr->ptr;
+			link = (ulong) index_ptr->ptr;
 			ptr = zend_list_find(link,&type);   /* check if the link is still there */
 			if (ptr && (type==le_link || type==le_plink)) {
 				Z_LVAL_P(return_value) = link;
@@ -1754,14 +1755,15 @@ PHP_FUNCTION(pg_field_table)
 
 
 	if (return_oid) {
+#if UINT_MAX > LONG_MAX /* Oid is unsigned int, we don't need this code, where LONG is wider */
 		if (oid > LONG_MAX) {
 			smart_str oidstr = {0};
 			smart_str_append_unsigned(&oidstr, oid);
 			smart_str_0(&oidstr);
 			RETURN_STRINGL(oidstr.c, oidstr.len, 0);
-		} else {
+		} else
+#endif
 			RETURN_LONG((long)oid);
-		}
 	}
 
 	/* try to lookup the table name in the resource list */
@@ -1859,7 +1861,7 @@ static void php_pgsql_get_field_info(INTERNAL_FUNCTION_PARAMETERS, int entry_typ
 		case PHP_PG_FIELD_TYPE_OID:
 			
 			oid = PQftype(pgsql_result, Z_LVAL_PP(field));
-
+#if UINT_MAX > LONG_MAX
 			if (oid > LONG_MAX) {
 				smart_str s = {0};
 				smart_str_append_unsigned(&s, oid);
@@ -1867,8 +1869,8 @@ static void php_pgsql_get_field_info(INTERNAL_FUNCTION_PARAMETERS, int entry_typ
 				Z_STRVAL_P(return_value) = s.c;
 				Z_STRLEN_P(return_value) = s.len;
 				Z_TYPE_P(return_value) = IS_STRING;
-			}
-			else
+			} else
+#endif
 			{
 				Z_LVAL_P(return_value) = (long)oid;
 				Z_TYPE_P(return_value) = IS_LONG;
@@ -3339,7 +3341,11 @@ PHP_FUNCTION(pg_copy_to)
 		pg_null_as = safe_estrdup("\\\\N");
 	}
 
-	spprintf(&query, 0, "COPY \"%s\" TO STDOUT DELIMITERS '%c' WITH NULL AS '%s'", table_name, *pg_delim, pg_null_as);
+	if (memchr(table_name, '.', table_name_len)) {
+		spprintf(&query, 0, "COPY %s TO STDOUT DELIMITERS '%c' WITH NULL AS '%s'", table_name, *pg_delim, pg_null_as);
+	} else {
+		spprintf(&query, 0, "COPY \"%s\" TO STDOUT DELIMITERS '%c' WITH NULL AS '%s'", table_name, *pg_delim, pg_null_as);
+	}
 
 	while ((pgsql_result = PQgetResult(pgsql))) {
 		PQclear(pgsql_result);
@@ -5767,8 +5773,8 @@ PHP_PGSQL_API int php_pgsql_result2array(PGresult *pg_result, zval *ret_array TS
 {
 	zval *row;
 	char *field_name, *element, *data;
-	size_t num_fields, element_len, data_len;
-	int pg_numrows, pg_row;
+	size_t num_fields, element_len;
+	int data_len, pg_numrows, pg_row;
 	uint i;
 	assert(Z_TYPE_P(ret_array) == IS_ARRAY);
 
diff --git a/ext/posix/posix.c b/ext/posix/posix.c
index 9af8d56..695f4d8 100644
--- a/ext/posix/posix.c
+++ b/ext/posix/posix.c
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: posix.c 286880 2009-08-06 11:11:15Z jani $ */
+/* $Id: posix.c 288943 2009-09-29 14:02:50Z rasmus $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -152,7 +152,7 @@ zend_function_entry posix_functions[] = {
 static PHP_MINFO_FUNCTION(posix)
 {
 	php_info_print_table_start();
-	php_info_print_table_row(2, "Revision", "$Revision: 286880 $");
+	php_info_print_table_row(2, "Revision", "$Revision: 288943 $");
 	php_info_print_table_end();
 }
 /* }}} */
@@ -679,7 +679,8 @@ PHP_FUNCTION(posix_mkfifo)
 		RETURN_FALSE;
 	}
 
-	if (PG(safe_mode) && (!php_checkuid(path, NULL, CHECKUID_ALLOW_ONLY_DIR))) {
+	if (php_check_open_basedir_ex(path, 0 TSRMLS_CC) ||
+			(PG(safe_mode) && (!php_checkuid(path, NULL, CHECKUID_ALLOW_ONLY_DIR)))) {
 		RETURN_FALSE;
 	}
 
diff --git a/ext/posix/tests/posix_errno_variation1.phpt b/ext/posix/tests/posix_errno_variation1.phpt
index aa9889f..b57b7c0 100644
--- a/ext/posix/tests/posix_errno_variation1.phpt
+++ b/ext/posix/tests/posix_errno_variation1.phpt
@@ -7,6 +7,7 @@ Francesco Fullone ff at ideato.it
 --SKIPIF--
 <?php 
         if(!extension_loaded("posix")) print "skip - POSIX extension not loaded"; 
+        if(posix_getuid()==0) print "skip - Cannot run test as root.";    
 ?>
 --FILE--
 <?php
diff --git a/ext/posix/tests/posix_errno_variation2.phpt b/ext/posix/tests/posix_errno_variation2.phpt
index f463d78..ad3aa31 100644
--- a/ext/posix/tests/posix_errno_variation2.phpt
+++ b/ext/posix/tests/posix_errno_variation2.phpt
@@ -7,6 +7,7 @@ Francesco Fullone ff at ideato.it
 --SKIPIF--
 <?php 
         if(!extension_loaded("posix")) print "skip - POSIX extension not loaded"; 
+        if(!extension_loaded("pcntl")) print "skip - PCNTL extension required";
 ?>
 --FILE--
 <?php
diff --git a/ext/posix/tests/posix_seteuid_variation2.phpt b/ext/posix/tests/posix_seteuid_variation2.phpt
index 2ab7302..bcba394 100644
--- a/ext/posix/tests/posix_seteuid_variation2.phpt
+++ b/ext/posix/tests/posix_seteuid_variation2.phpt
@@ -3,6 +3,7 @@ Test function posix_seteuid() by substituting argument 1 with boolean values.
 --SKIPIF--
 <?php 
         if(!extension_loaded("posix")) print "skip - POSIX extension not loaded"; 
+        if(posix_geteuid() == 0) print "skip - Cannot run test as root.";
 ?>
 --CREDITS--
 Marco Fabbri mrfabbri at gmail.com
diff --git a/ext/posix/tests/posix_seteuid_variation3.phpt b/ext/posix/tests/posix_seteuid_variation3.phpt
index 70c05c8..8b57864 100644
--- a/ext/posix/tests/posix_seteuid_variation3.phpt
+++ b/ext/posix/tests/posix_seteuid_variation3.phpt
@@ -3,6 +3,7 @@ Test function posix_seteuid() by substituting argument 1 with emptyUnsetUndefNul
 --SKIPIF--
 <?php 
         if(!extension_loaded("posix")) print "skip - POSIX extension not loaded"; 
+        if(posix_geteuid() == 0) print "skip - Cannot run test as root.";
 ?>
 --CREDITS--
 Marco Fabbri mrfabbri at gmail.com
diff --git a/ext/posix/tests/posix_seteuid_variation4.phpt b/ext/posix/tests/posix_seteuid_variation4.phpt
index 6529141..a647328 100644
--- a/ext/posix/tests/posix_seteuid_variation4.phpt
+++ b/ext/posix/tests/posix_seteuid_variation4.phpt
@@ -3,6 +3,7 @@ Test function posix_seteuid() by substituting argument 1 with float values.
 --SKIPIF--
 <?php 
         if(!extension_loaded("posix")) print "skip - POSIX extension not loaded"; 
+        if(posix_geteuid() == 0) print "skip - Cannot run test as root.";
 ?>
 --CREDITS--
 Marco Fabbri mrfabbri at gmail.com
diff --git a/ext/posix/tests/posix_seteuid_variation5.phpt b/ext/posix/tests/posix_seteuid_variation5.phpt
index 91d3a72..8e43e1a 100644
--- a/ext/posix/tests/posix_seteuid_variation5.phpt
+++ b/ext/posix/tests/posix_seteuid_variation5.phpt
@@ -3,6 +3,7 @@ Test function posix_seteuid() by substituting argument 1 with int values.
 --SKIPIF--
 <?php 
         if(!extension_loaded("posix")) print "skip - POSIX extension not loaded"; 
+        if(posix_geteuid() == 0) print "skip - Cannot run test as root.";
 ?>
 --CREDITS--
 Marco Fabbri mrfabbri at gmail.com
diff --git a/ext/posix/tests/posix_setgid_variation2.phpt b/ext/posix/tests/posix_setgid_variation2.phpt
index 6d53b08..b8e50ba 100644
--- a/ext/posix/tests/posix_setgid_variation2.phpt
+++ b/ext/posix/tests/posix_setgid_variation2.phpt
@@ -3,6 +3,7 @@ Test function posix_setgid() by substituting argument 1 with boolean values.
 --SKIPIF--
 <?php 
         if(!extension_loaded("posix")) print "skip - POSIX extension not loaded"; 
+        if(posix_geteuid() == 0) print "skip - Cannot run test as root.";
 ?>
 --CREDITS--
 Marco Fabbri mrfabbri at gmail.com
@@ -36,4 +37,4 @@ bool(false)
 bool(false)
 bool(false)
 ===DONE===
-	
\ No newline at end of file
+	
diff --git a/ext/posix/tests/posix_setgid_variation3.phpt b/ext/posix/tests/posix_setgid_variation3.phpt
index 5855746..cb9da62 100644
--- a/ext/posix/tests/posix_setgid_variation3.phpt
+++ b/ext/posix/tests/posix_setgid_variation3.phpt
@@ -7,6 +7,7 @@ Francesco Fullone ff at ideato.it
 --SKIPIF--
 <?php
         if(!extension_loaded("posix")) print "skip - POSIX extension not loaded";
+        if(posix_geteuid() == 0) print "skip - Cannot run test as root.";
 ?>
 --FILE--
 <?php
diff --git a/ext/posix/tests/posix_setgid_variation4.phpt b/ext/posix/tests/posix_setgid_variation4.phpt
index 2bd209b..faae4d4 100644
--- a/ext/posix/tests/posix_setgid_variation4.phpt
+++ b/ext/posix/tests/posix_setgid_variation4.phpt
@@ -3,6 +3,7 @@ Test function posix_setgid() by substituting argument 1 with float values.
 --SKIPIF--
 <?php 
         if(!extension_loaded("posix")) print "skip - POSIX extension not loaded"; 
+        if(posix_geteuid() == 0) print "skip - Cannot run test as root.";
 ?>
 --CREDITS--
 Marco Fabbri mrfabbri at gmail.com
@@ -38,4 +39,4 @@ bool(false)
 bool(false)
 bool(false)
 ===DONE===
-	
\ No newline at end of file
+	
diff --git a/ext/posix/tests/posix_setgid_variation5.phpt b/ext/posix/tests/posix_setgid_variation5.phpt
index 91f2bb5..49e98ec 100644
--- a/ext/posix/tests/posix_setgid_variation5.phpt
+++ b/ext/posix/tests/posix_setgid_variation5.phpt
@@ -3,6 +3,7 @@ Test function posix_setgid() by substituting argument 1 with int values.
 --SKIPIF--
 <?php 
         if(!extension_loaded("posix")) print "skip - POSIX extension not loaded"; 
+        if(posix_geteuid() == 0) print "skip - Cannot run test as root.";
 ?>
 --CREDITS--
 Marco Fabbri mrfabbri at gmail.com
@@ -34,4 +35,4 @@ bool(false)
 bool(false)
 bool(false)
 ===DONE===
-	
\ No newline at end of file
+	
diff --git a/ext/posix/tests/posix_setuid_variation2.phpt b/ext/posix/tests/posix_setuid_variation2.phpt
index c8ef928..77505a6 100644
--- a/ext/posix/tests/posix_setuid_variation2.phpt
+++ b/ext/posix/tests/posix_setuid_variation2.phpt
@@ -3,6 +3,7 @@ Test function posix_setuid() by substituting argument 1 with boolean values.
 --SKIPIF--
 <?php 
         if(!extension_loaded("posix")) print "skip - POSIX extension not loaded"; 
+        if(posix_geteuid() == 0) print "skip - Cannot run test as root.";
 ?>
 --CREDITS--
 Marco Fabbri mrfabbri at gmail.com
diff --git a/ext/posix/tests/posix_setuid_variation3.phpt b/ext/posix/tests/posix_setuid_variation3.phpt
index 1630cd1..4957229 100644
--- a/ext/posix/tests/posix_setuid_variation3.phpt
+++ b/ext/posix/tests/posix_setuid_variation3.phpt
@@ -3,6 +3,7 @@ Test function posix_setuid() by substituting argument 1 with emptyUnsetUndefNull
 --SKIPIF--
 <?php 
         if(!extension_loaded("posix")) print "skip - POSIX extension not loaded"; 
+        if(posix_geteuid() == 0) print "skip - Cannot run test as root.";
 ?>
 --CREDITS--
 Marco Fabbri mrfabbri at gmail.com
diff --git a/ext/posix/tests/posix_setuid_variation4.phpt b/ext/posix/tests/posix_setuid_variation4.phpt
index 1675964..288ac0d 100644
--- a/ext/posix/tests/posix_setuid_variation4.phpt
+++ b/ext/posix/tests/posix_setuid_variation4.phpt
@@ -3,6 +3,7 @@ Test function posix_setuid() by substituting argument 1 with float values.
 --SKIPIF--
 <?php 
         if(!extension_loaded("posix")) print "skip - POSIX extension not loaded"; 
+        if(posix_geteuid() == 0) print "skip - Cannot run test as root.";
 ?>
 --CREDITS--
 Marco Fabbri mrfabbri at gmail.com
diff --git a/ext/posix/tests/posix_setuid_variation5.phpt b/ext/posix/tests/posix_setuid_variation5.phpt
index e1b7c05..a4ebe63 100644
--- a/ext/posix/tests/posix_setuid_variation5.phpt
+++ b/ext/posix/tests/posix_setuid_variation5.phpt
@@ -3,6 +3,7 @@ Test function posix_setuid() by substituting argument 1 with int values.
 --SKIPIF--
 <?php 
         if(!extension_loaded("posix")) print "skip - POSIX extension not loaded"; 
+        if(posix_geteuid() == 0) print "skip - Cannot run test as root.";
 ?>
 --CREDITS--
 Marco Fabbri mrfabbri at gmail.com
diff --git a/ext/posix/tests/posix_uname.phpt b/ext/posix/tests/posix_uname.phpt
index 12c4bae..3acbdaf 100644
--- a/ext/posix/tests/posix_uname.phpt
+++ b/ext/posix/tests/posix_uname.phpt
@@ -14,7 +14,9 @@ PHP Testfest Berlin 2009-05-10
 ?>
 --FILE--
 <?php
-    var_dump(posix_uname());
+    $uname = posix_uname();
+    unset($uname['domainname']);
+    var_dump($uname);
 ?>
 ===DONE===
 --EXPECTF--
diff --git a/ext/posix/tests/posix_uname_basic.phpt b/ext/posix/tests/posix_uname_basic.phpt
index 7dd3781..6bd5b10 100644
--- a/ext/posix/tests/posix_uname_basic.phpt
+++ b/ext/posix/tests/posix_uname_basic.phpt
@@ -9,7 +9,7 @@ Test posix_uname() function : basic functionality
   echo "Basic test of POSIX uname function\n"; 
   	
   $uname = posix_uname();  
-  
+  unset($uname['domainname']);  
   print_r($uname);
   
 ?>
diff --git a/ext/readline/config.m4 b/ext/readline/config.m4
index 00875c0..0779203 100644
--- a/ext/readline/config.m4
+++ b/ext/readline/config.m4
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: config.m4 286797 2009-08-04 11:20:49Z jani $
+dnl $Id: config.m4 292081 2009-12-13 17:06:47Z felipe $
 dnl
 
 PHP_ARG_WITH(libedit,for libedit readline replacement, 
@@ -65,7 +65,7 @@ if test "$PHP_READLINE" && test "$PHP_READLINE" != "no"; then
 elif test "$PHP_LIBEDIT" != "no"; then
 
   for i in $PHP_LIBEDIT /usr/local /usr; do
-    test -f $i/include/readline/readline.h && LIBEDIT_DIR=$i && break
+    test -f $i/include/editline/readline.h && LIBEDIT_DIR=$i && break
   done
 
   if test -z "$LIBEDIT_DIR"; then
diff --git a/ext/readline/readline.c b/ext/readline/readline.c
index 3e1e3de..5c22850 100644
--- a/ext/readline/readline.c
+++ b/ext/readline/readline.c
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: readline.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: readline.c 292081 2009-12-13 17:06:47Z felipe $ */
 
 /* {{{ includes & prototypes */
 
@@ -33,8 +33,10 @@
 #define rl_completion_matches completion_matches
 #endif
 
+#ifdef HAVE_LIBEDIT
+#include <editline/readline.h>
+#else
 #include <readline/readline.h>
-#ifndef HAVE_LIBEDIT
 #include <readline/history.h>
 #endif
 
diff --git a/ext/readline/tests/readline_add_history_001.phpt b/ext/readline/tests/readline_add_history_001.phpt
index 498db40..0afbe4f 100644
--- a/ext/readline/tests/readline_add_history_001.phpt
+++ b/ext/readline/tests/readline_add_history_001.phpt
@@ -1,7 +1,7 @@
 --TEST--
 readline_add_history(): Basic test
 --SKIPIF--
-<?php if (!extension_loaded("readline")) die("skip"); ?>
+<?php if (!extension_loaded("readline") || !function_exists('readline_list_history')) die("skip"); ?>
 --FILE--
 <?php
 
diff --git a/ext/readline/tests/readline_callback_handler_install_001.phpt b/ext/readline/tests/readline_callback_handler_install_001.phpt
index 6df4429..8bf1d61 100644
--- a/ext/readline/tests/readline_callback_handler_install_001.phpt
+++ b/ext/readline/tests/readline_callback_handler_install_001.phpt
@@ -1,7 +1,7 @@
 --TEST--
 readline_callback_handler_install(): Basic test
 --SKIPIF--
-<?php if (!extension_loaded("readline")) die("skip"); ?>
+<?php if (!extension_loaded("readline") || !function_exists('readline_callback_handler_install')) die("skip"); ?>
 --FILE--
 <?php
 
diff --git a/ext/readline/tests/readline_callback_handler_remove_001.phpt b/ext/readline/tests/readline_callback_handler_remove_001.phpt
index 6688f83..768041a 100644
--- a/ext/readline/tests/readline_callback_handler_remove_001.phpt
+++ b/ext/readline/tests/readline_callback_handler_remove_001.phpt
@@ -1,7 +1,7 @@
 --TEST--
 readline_callback_handler_remove(): Basic test
 --SKIPIF--
-<?php if (!extension_loaded("readline")) die("skip"); ?>
+<?php if (!extension_loaded("readline") || !function_exists('readline_callback_handler_remove')) die("skip"); ?>
 --FILE--
 <?php
 
diff --git a/ext/readline/tests/readline_list_history_001.phpt b/ext/readline/tests/readline_list_history_001.phpt
index 8aa5448..6cb9aa1 100644
--- a/ext/readline/tests/readline_list_history_001.phpt
+++ b/ext/readline/tests/readline_list_history_001.phpt
@@ -1,7 +1,7 @@
 --TEST--
 readline_list_history(): Basic test
 --SKIPIF--
-<?php if (!extension_loaded("readline")) die("skip"); ?>
+<?php if (!extension_loaded("readline") || !function_exists('readline_list_history')) die("skip"); ?>
 --FILE--
 <?php
 
diff --git a/ext/readline/tests/readline_read_history_001.phpt b/ext/readline/tests/readline_read_history_001.phpt
index 2f7c889..fcdb1ae 100644
--- a/ext/readline/tests/readline_read_history_001.phpt
+++ b/ext/readline/tests/readline_read_history_001.phpt
@@ -1,7 +1,7 @@
 --TEST--
 readline_read_history(): Basic test
 --SKIPIF--
-<?php if (!extension_loaded("readline")) die("skip"); ?>
+<?php if (!extension_loaded("readline") || !function_exists('readline_list_history')) die("skip"); ?>
 --FILE--
 <?php
 
diff --git a/ext/readline/tests/readline_write_history_001.phpt b/ext/readline/tests/readline_write_history_001.phpt
index eca831f..fc0ae32 100644
--- a/ext/readline/tests/readline_write_history_001.phpt
+++ b/ext/readline/tests/readline_write_history_001.phpt
@@ -1,7 +1,7 @@
 --TEST--
 readline_write_history(): Basic test
 --SKIPIF--
-<?php if (!extension_loaded("readline")) die("skip"); ?>
+<?php if (!extension_loaded("readline") || !function_exists('readline_add_history')) die("skip"); ?>
 --FILE--
 <?php
 
diff --git a/ext/reflection/php_reflection.c b/ext/reflection/php_reflection.c
index 7299120..f83b6bd 100644
--- a/ext/reflection/php_reflection.c
+++ b/ext/reflection/php_reflection.c
@@ -20,7 +20,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: php_reflection.c 287991 2009-09-03 14:02:51Z sebastian $ */
+/* $Id: php_reflection.c 290127 2009-11-01 15:12:34Z felipe $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -3104,6 +3104,7 @@ ZEND_METHOD(reflection_class, getMethods)
 ZEND_METHOD(reflection_class, hasProperty)
 {
 	reflection_object *intern;
+	zend_property_info *property_info;
 	zend_class_entry *ce;
 	char *name; 
 	int name_len;
@@ -3115,11 +3116,13 @@ ZEND_METHOD(reflection_class, hasProperty)
 	}
 
 	GET_REFLECTION_OBJECT_PTR(ce);
-	if (zend_hash_exists(&ce->properties_info, name, name_len + 1)) {
+	if (zend_hash_find(&ce->properties_info, name, name_len+1, (void **) &property_info) == SUCCESS) {
+		if (property_info->flags & ZEND_ACC_SHADOW) {
+			RETURN_FALSE;
+		}
 		RETURN_TRUE;
 	} else {
-		if (intern->obj && Z_OBJ_HANDLER_P(intern->obj, has_property))
-		{
+		if (intern->obj && Z_OBJ_HANDLER_P(intern->obj, has_property)) {
 			MAKE_STD_ZVAL(property);
 			ZVAL_STRINGL(property, name, name_len, 1);
 			if (Z_OBJ_HANDLER_P(intern->obj, has_property)(intern->obj, property, 2 TSRMLS_CC)) {
@@ -4962,7 +4965,7 @@ PHP_MINFO_FUNCTION(reflection) /* {{{ */
 	php_info_print_table_start();
 	php_info_print_table_header(2, "Reflection", "enabled");
 
-	php_info_print_table_row(2, "Version", "$Id: php_reflection.c 287991 2009-09-03 14:02:51Z sebastian $");
+	php_info_print_table_row(2, "Version", "$Id: php_reflection.c 290127 2009-11-01 15:12:34Z felipe $");
 
 	php_info_print_table_end();
 } /* }}} */
diff --git a/ext/reflection/tests/ReflectionClass_hasProperty_001.phpt b/ext/reflection/tests/ReflectionClass_hasProperty_001.phpt
index 94f739c..88c4cd5 100644
--- a/ext/reflection/tests/ReflectionClass_hasProperty_001.phpt
+++ b/ext/reflection/tests/ReflectionClass_hasProperty_001.phpt
@@ -69,7 +69,7 @@ Reflecting on class privf:
   --> Check for doesntExist: bool(false)
 Reflecting on class subprivf: 
   --> Check for s: bool(true)
-  --> Check for a: bool(true)
+  --> Check for a: bool(false)
   --> Check for A: bool(false)
   --> Check for doesntExist: bool(false)
 
diff --git a/ext/reflection/tests/bug49719.phpt b/ext/reflection/tests/bug49719.phpt
new file mode 100644
index 0000000..36e835d
--- /dev/null
+++ b/ext/reflection/tests/bug49719.phpt
@@ -0,0 +1,30 @@
+--TEST--
+Bug #49719 (ReflectionClass::hasProperty returns true for a private property in base class)
+--FILE--
+<?php
+
+class A {
+	private $a;
+}
+class B extends A {
+	private $b;
+}
+
+try {
+	$b = new B;
+	$ref = new ReflectionClass($b);
+	
+	var_dump(property_exists('b', 'a'));
+	var_dump(property_exists($b, 'a'));
+	var_dump($ref->hasProperty('a'));	
+	var_dump($ref->getProperty('a'));
+} catch (Exception $e) {
+	var_dump($e->getMessage());
+}
+
+?>
+--EXPECTF--
+bool(false)
+bool(false)
+bool(false)
+%string|unicode%(25) "Property a does not exist"
diff --git a/ext/session/mod_files.c b/ext/session/mod_files.c
index 1480644..92cf2c7 100644
--- a/ext/session/mod_files.c
+++ b/ext/session/mod_files.c
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: mod_files.c 281158 2009-05-26 10:15:08Z jani $ */
+/* $Id: mod_files.c 290174 2009-11-03 17:16:45Z guenter $ */
 
 #include "php.h"
 
@@ -244,11 +244,7 @@ static int ps_files_cleanup_dir(const char *dirname, int maxlifetime TSRMLS_DC)
 
 				/* check whether its last access was more than maxlifet ago */
 				if (VCWD_STAT(buf, &sbuf) == 0 &&
-#ifdef NETWARE
-						(now - sbuf.st_mtime.tv_sec) > maxlifetime) {
-#else
 						(now - sbuf.st_mtime) > maxlifetime) {
-#endif
 					VCWD_UNLINK(buf);
 					nrdels++;
 				}
diff --git a/ext/session/mod_mm.c b/ext/session/mod_mm.c
index 1e68700..0d0be5c 100644
--- a/ext/session/mod_mm.c
+++ b/ext/session/mod_mm.c
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: mod_mm.c 280733 2009-05-18 17:23:42Z jani $ */
+/* $Id: mod_mm.c 289338 2009-10-08 10:33:26Z jani $ */
 
 #include "php.h"
 
@@ -219,9 +219,6 @@ static int ps_mm_initialize(ps_mm *data, const char *path)
 	data->owner = getpid();
 	data->mm = mm_create(0, path);
 	if (!data->mm) {
-		TSRMLS_FETCH();
-
-		php_error_docref(NULL TSRMLS_CC, E_WARNING, "mm_create(0, %s) failed, err %s", path, mm_error());
 		return FAILURE;
 	}
 
diff --git a/ext/session/session.c b/ext/session/session.c
index d1279b0..dc746e0 100644
--- a/ext/session/session.c
+++ b/ext/session/session.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: session.c 286443 2009-07-28 08:54:23Z tony2001 $ */
+/* $Id: session.c 291681 2009-12-04 01:21:32Z stas $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -61,12 +61,6 @@ PHPAPI ZEND_DECLARE_MODULE_GLOBALS(ps);
    * Helpers *
    *********** */
 
-#ifdef NETWARE
-# define SESS_SB_MTIME(sb)	((sb).st_mtime.tv_sec)
-#else
-# define SESS_SB_MTIME(sb)	((sb).st_mtime)
-#endif
-
 #define IF_SESSION_VARS() \
 	if (PS(http_session_vars) && PS(http_session_vars)->type == IS_ARRAY)
 
@@ -1013,7 +1007,7 @@ static inline void last_modified(TSRMLS_D) /* {{{ */
 
 #define LAST_MODIFIED "Last-Modified: "
 		memcpy(buf, LAST_MODIFIED, sizeof(LAST_MODIFIED) - 1);
-		strcpy_gmt(buf + sizeof(LAST_MODIFIED) - 1, &SESS_SB_MTIME(sb));
+		strcpy_gmt(buf + sizeof(LAST_MODIFIED) - 1, &sb.st_mtime);
 		ADD_HEADER(buf);
 	}
 }
@@ -1823,7 +1817,10 @@ static PHP_FUNCTION(session_unset)
 	}
 
 	IF_SESSION_VARS() {
-		HashTable *ht = Z_ARRVAL_P(PS(http_session_vars));
+		HashTable *ht;
+
+		SEPARATE_ZVAL_IF_NOT_REF(&PS(http_session_vars));
+		ht = Z_ARRVAL_P(PS(http_session_vars));
 
 		if (PG(register_globals)) {
 			uint str_len;
@@ -1905,7 +1902,10 @@ static PHP_FUNCTION(session_unregister)
 	}
 	convert_to_string_ex(p_name);
 
-	PS_DEL_VARL(Z_STRVAL_PP(p_name), Z_STRLEN_PP(p_name));
+	IF_SESSION_VARS() {
+		SEPARATE_ZVAL_IF_NOT_REF(&PS(http_session_vars));
+		PS_DEL_VARL(Z_STRVAL_PP(p_name), Z_STRLEN_PP(p_name));
+	}
 
 	RETURN_TRUE;
 }
@@ -2107,7 +2107,7 @@ static PHP_MINFO_FUNCTION(session) /* {{{ */
 }
 /* }}} */
 
-static const zend_module_dep session_deps[] = { /* {{{ */
+static zend_module_dep session_deps[] = { /* {{{ */
 	ZEND_MOD_OPTIONAL("hash")
 	{NULL, NULL, NULL}
 };
diff --git a/ext/simplexml/simplexml.c b/ext/simplexml/simplexml.c
index e7de5d1..ae3ddd1 100644
--- a/ext/simplexml/simplexml.c
+++ b/ext/simplexml/simplexml.c
@@ -18,7 +18,7 @@
   +----------------------------------------------------------------------+
 */
 
-/* $Id: simplexml.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: simplexml.c 289327 2009-10-08 02:21:36Z iliaa $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -2450,7 +2450,7 @@ PHP_MINFO_FUNCTION(simplexml)
 {
 	php_info_print_table_start();
 	php_info_print_table_header(2, "Simplexml support", "enabled");
-	php_info_print_table_row(2, "Revision", "$Revision: 272374 $");
+	php_info_print_table_row(2, "Revision", "$Revision: 289327 $");
 	php_info_print_table_row(2, "Schema support",
 #ifdef LIBXML_SCHEMAS_ENABLED
 		"enabled");
diff --git a/ext/snmp/snmp.c b/ext/snmp/snmp.c
index ee88bb2..8f23208 100644
--- a/ext/snmp/snmp.c
+++ b/ext/snmp/snmp.c
@@ -20,7 +20,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: snmp.c 281502 2009-06-01 13:10:57Z iliaa $ */
+/* $Id: snmp.c 289918 2009-10-25 20:17:04Z jani $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -817,7 +817,6 @@ static int netsnmp_session_set_sec_level(struct snmp_session *s, char *level TSR
 			s->securityLevel = SNMP_SEC_LEVEL_AUTHPRIV;
 			return (0);
 		}
-		php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid security level: %s", level);
 	}
 	return (-1);
 }
@@ -836,8 +835,6 @@ static int netsnmp_session_set_auth_protocol(struct snmp_session *s, char *prot
 			s->securityAuthProto = usmHMACSHA1AuthProtocol;
 			s->securityAuthProtoLen = OIDSIZE(usmHMACSHA1AuthProtocol);
 			return (0);
-		} else if (strlen(prot)) {
-			php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid authentication protocol: %s", prot);
 		}
 	}
 	return (-1);
@@ -889,8 +886,6 @@ static int netsnmp_session_set_sec_protocol(struct snmp_session *s, char *prot T
 			return (0);
 #endif
 #endif
-		} else if (strlen(prot)) {
-			php_error_docref(NULL TSRMLS_CC, E_WARNING, "Invalid privacy protocol: %s", prot);
 		}
 	}
 	return (-1);
diff --git a/ext/soap/php_encoding.c b/ext/soap/php_encoding.c
index dd4d4bd..aed4400 100644
--- a/ext/soap/php_encoding.c
+++ b/ext/soap/php_encoding.c
@@ -17,7 +17,7 @@
   |          Dmitry Stogov <dmitry at zend.com>                             |
   +----------------------------------------------------------------------+
 */
-/* $Id: php_encoding.c 282179 2009-06-15 17:36:00Z felipe $ */
+/* $Id: php_encoding.c 291120 2009-11-21 19:43:00Z felipe $ */
 
 #include <time.h>
 
@@ -372,7 +372,7 @@ static xmlNodePtr master_to_xml_int(encodePtr encode, zval *data, int style, xml
 		HashTable *ht = Z_OBJPROP_P(data);
 
 		if (zend_hash_find(ht, "enc_type", sizeof("enc_type"), (void **)&ztype) == FAILURE) {
-			soap_error0(E_ERROR, "Encoding: SoapVar hasn't 'enc_type' propery");
+			soap_error0(E_ERROR, "Encoding: SoapVar hasn't 'enc_type' property");
 		}
 
 		if (zend_hash_find(ht, "enc_stype", sizeof("enc_stype"), (void **)&zstype) == SUCCESS) {
diff --git a/ext/soap/php_http.c b/ext/soap/php_http.c
index 36eea18..b484480 100644
--- a/ext/soap/php_http.c
+++ b/ext/soap/php_http.c
@@ -17,7 +17,7 @@
   |          Dmitry Stogov <dmitry at zend.com>                             |
   +----------------------------------------------------------------------+
 */
-/* $Id: php_http.c 281592 2009-06-03 12:41:46Z iliaa $ */
+/* $Id: php_http.c 291104 2009-11-21 01:22:32Z pierrick $ */
 
 #include "php_soap.h"
 #include "ext/standard/base64.h"
@@ -931,12 +931,20 @@ try_again:
 					new_url->host = phpurl->host ? estrdup(phpurl->host) : NULL;
 					new_url->port = phpurl->port;
 					if (new_url->path && new_url->path[0] != '/') {
-						char *t = phpurl->path;
-						char *p = strrchr(t, '/');
-						if (p) {
-							char *s = emalloc((p - t) + strlen(new_url->path) + 2);
-							strncpy(s, t, (p - t) + 1);
-							s[(p - t) + 1] = 0;
+						if (phpurl->path) {
+							char *t = phpurl->path;
+							char *p = strrchr(t, '/');
+							if (p) {
+								char *s = emalloc((p - t) + strlen(new_url->path) + 2);
+								strncpy(s, t, (p - t) + 1);
+								s[(p - t) + 1] = 0;
+								strcat(s, new_url->path);
+								efree(new_url->path);
+								new_url->path = s;
+							} 
+						} else {
+							char *s = emalloc(strlen(new_url->path) + 2);
+							s[0] = '/'; s[1] = 0;
 							strcat(s, new_url->path);
 							efree(new_url->path);
 							new_url->path = s;
diff --git a/ext/soap/php_xml.c b/ext/soap/php_xml.c
index 66d52de..0947b51 100644
--- a/ext/soap/php_xml.c
+++ b/ext/soap/php_xml.c
@@ -17,7 +17,7 @@
   |          Dmitry Stogov <dmitry at zend.com>                             |
   +----------------------------------------------------------------------+
 */
-/* $Id: php_xml.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: php_xml.c 291533 2009-12-01 02:05:28Z felipe $ */
 
 #include "php_soap.h"
 #include "libxml/parser.h"
@@ -138,6 +138,9 @@ xmlDocPtr soap_xmlParseMemory(const void *buf, size_t buf_size)
 		ctxt->sax->warning = NULL;
 		ctxt->sax->error = NULL;
 		/*ctxt->sax->fatalError = NULL;*/
+#if LIBXML_VERSION >= 20703
+		ctxt->options |= XML_PARSE_HUGE;
+#endif
 		xmlParseDocument(ctxt);
 		if (ctxt->wellFormed) {
 			ret = ctxt->myDoc;
diff --git a/ext/soap/soap.c b/ext/soap/soap.c
index bdf9a75..80b9c18 100644
--- a/ext/soap/soap.c
+++ b/ext/soap/soap.c
@@ -17,7 +17,7 @@
   |          Dmitry Stogov <dmitry at zend.com>                             |
   +----------------------------------------------------------------------+
 */
-/* $Id: soap.c 287746 2009-08-26 14:05:48Z dmitry $ */
+/* $Id: soap.c 291120 2009-11-21 19:43:00Z felipe $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -2335,7 +2335,7 @@ PHP_METHOD(SoapClient, SoapClient)
 			    Z_TYPE_PP(tmp) == IS_STRING) {
 				add_property_stringl(this_ptr, "uri", Z_STRVAL_PP(tmp), Z_STRLEN_PP(tmp), 1);
 			} else {
-				php_error_docref(NULL TSRMLS_CC, E_ERROR, "'uri' option is requred in nonWSDL mode");
+				php_error_docref(NULL TSRMLS_CC, E_ERROR, "'uri' option is required in nonWSDL mode");
 				return;
 			}
 
@@ -2362,7 +2362,7 @@ PHP_METHOD(SoapClient, SoapClient)
 		    Z_TYPE_PP(tmp) == IS_STRING) {
 			add_property_stringl(this_ptr, "location", Z_STRVAL_PP(tmp), Z_STRLEN_PP(tmp), 1);
 		} else if (wsdl == NULL) {
-			php_error_docref(NULL TSRMLS_CC, E_ERROR, "'location' option is requred in nonWSDL mode");
+			php_error_docref(NULL TSRMLS_CC, E_ERROR, "'location' option is required in nonWSDL mode");
 			return;
 		}
 
@@ -2490,7 +2490,7 @@ PHP_METHOD(SoapClient, SoapClient)
 		}
 
 	} else if (wsdl == NULL) {
-		php_error_docref(NULL TSRMLS_CC, E_ERROR, "'location' and 'uri' options are requred in nonWSDL mode");
+		php_error_docref(NULL TSRMLS_CC, E_ERROR, "'location' and 'uri' options are required in nonWSDL mode");
 		return;
 	}
 
diff --git a/ext/sockets/tests/socket_getpeername_ipv6loop.phpt b/ext/sockets/tests/socket_getpeername_ipv6loop.phpt
index ba3c134..e865f3e 100644
--- a/ext/sockets/tests/socket_getpeername_ipv6loop.phpt
+++ b/ext/sockets/tests/socket_getpeername_ipv6loop.phpt
@@ -5,9 +5,10 @@ ext/sockets - socket_getpeername_ipv6loop - basic test
 # $Id: socket_getpeername_ipv6loop.phpt 494 2009-06-09 20:38:05Z tatjana.andersen at redpill-linpro.com $
 --SKIPIF--
 <?php   
-        if (!extension_loaded('sockets')) {
-                die('skip sockets extension not available.');
-        }
+if (!extension_loaded('sockets')) {
+	die('skip sockets extension not available.');
+}
+require 'ipv6_skipif.inc';
 ?>
 --FILE--
 <?php   
diff --git a/ext/sockets/tests/socket_set_option_rcvtimeo.phpt b/ext/sockets/tests/socket_set_option_rcvtimeo.phpt
index 84c533f..ea14fd3 100644
--- a/ext/sockets/tests/socket_set_option_rcvtimeo.phpt
+++ b/ext/sockets/tests/socket_set_option_rcvtimeo.phpt
@@ -1,6 +1,6 @@
 --TEST--
 Test if socket_set_option() works, option:SO_RCVTIMEO
---DESCRIPTION---
+--DESCRIPTION--
 -wrong params 
 -set/get params comparison 
 --SKIPIF--
diff --git a/ext/sockets/tests/socket_set_option_seolinger.phpt b/ext/sockets/tests/socket_set_option_seolinger.phpt
index 05bc213..e49a7eb 100644
--- a/ext/sockets/tests/socket_set_option_seolinger.phpt
+++ b/ext/sockets/tests/socket_set_option_seolinger.phpt
@@ -1,6 +1,6 @@
 --TEST--
 Test if socket_set_option() works, option:SO_SEOLINGER
---DESCRIPTION---
+--DESCRIPTION--
 -wrong params 
 -set/get params comparison 
 -l_linger not given
diff --git a/ext/sockets/tests/socket_set_option_sndtimeo.phpt b/ext/sockets/tests/socket_set_option_sndtimeo.phpt
index c4e4851..6fd008c 100644
--- a/ext/sockets/tests/socket_set_option_sndtimeo.phpt
+++ b/ext/sockets/tests/socket_set_option_sndtimeo.phpt
@@ -1,6 +1,6 @@
 --TEST--
 Test if socket_set_option() works, option:SO_SNDTIMEO
---DESCRIPTION---
+--DESCRIPTION--
 -wrong params 
 -set/get params comparison 
 --SKIPIF--
diff --git a/ext/spl/spl_iterators.c b/ext/spl/spl_iterators.c
index 0748cb9..f77d89b 100755
--- a/ext/spl/spl_iterators.c
+++ b/ext/spl/spl_iterators.c
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: spl_iterators.c 280214 2009-05-09 19:48:15Z scottmac $ */
+/* $Id: spl_iterators.c 290392 2009-11-07 21:27:15Z felipe $ */
 
 #ifdef HAVE_CONFIG_H
 # include "config.h"
@@ -818,7 +818,7 @@ static union _zend_function *spl_dual_it_get_method(zval **object_ptr, char *met
 	intern = (spl_dual_it_object*)zend_object_store_get_object(*object_ptr TSRMLS_CC);
 
 	function_handler = std_object_handlers.get_method(object_ptr, method, method_len TSRMLS_CC);
-	if (!function_handler) {
+	if (!function_handler && intern->inner.ce) {
 		if (zend_hash_find(&intern->inner.ce->function_table, method, method_len+1, (void **) &function_handler) == FAILURE) {
 			if (Z_OBJ_HT_P(intern->inner.zobject)->get_method) {
 				*object_ptr = intern->inner.zobject;
@@ -982,7 +982,7 @@ static spl_dual_it_object* spl_dual_it_construct(INTERNAL_FUNCTION_PARAMETERS, z
 						return NULL;
 					}
 					if (!retval || Z_TYPE_P(retval) != IS_OBJECT || !instanceof_function(Z_OBJCE_P(retval), zend_ce_traversable TSRMLS_CC)) {
-						zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "%s::getIterator() must return an object that implememnts Traversable", ce->name);
+						zend_throw_exception_ex(spl_ce_LogicException, 0 TSRMLS_CC, "%s::getIterator() must return an object that implements Traversable", ce->name);
 						php_set_error_handling(EH_NORMAL, NULL TSRMLS_CC);
 						return NULL;
 					}
@@ -1735,7 +1735,7 @@ static inline void spl_limit_it_seek(spl_dual_it_object *intern, long pos TSRMLS
 		return;
 	}
 	if (pos >= intern->u.limit.offset + intern->u.limit.count && intern->u.limit.count != -1) {
-		zend_throw_exception_ex(spl_ce_OutOfBoundsException, 0 TSRMLS_CC, "Cannot seek to %ld which is behind offest %ld plus count %ld", pos, intern->u.limit.offset, intern->u.limit.count);
+		zend_throw_exception_ex(spl_ce_OutOfBoundsException, 0 TSRMLS_CC, "Cannot seek to %ld which is behind offset %ld plus count %ld", pos, intern->u.limit.offset, intern->u.limit.count);
 		return;
 	}
 	if (instanceof_function(intern->inner.ce, spl_ce_SeekableIterator TSRMLS_CC)) {
diff --git a/ext/spl/spl_observer.c b/ext/spl/spl_observer.c
index 9460461..804bd71 100755
--- a/ext/spl/spl_observer.c
+++ b/ext/spl/spl_observer.c
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: spl_observer.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: spl_observer.c 289250 2009-10-06 13:34:56Z colder $ */
 
 #ifdef HAVE_CONFIG_H
 # include "config.h"
@@ -348,7 +348,7 @@ SPL_METHOD(SplObjectStorage, unserialize)
 	++p;
 
 	ALLOC_INIT_ZVAL(pcount);
-	if (!php_var_unserialize(&pcount, &p, s + buf_len, &var_hash TSRMLS_CC) || Z_TYPE_P(pcount) != IS_LONG) {
+	if (!php_var_unserialize(&pcount, &p, s + buf_len, NULL TSRMLS_CC) || Z_TYPE_P(pcount) != IS_LONG) {
 		zval_ptr_dtor(&pcount);
 		goto outexcept;
 	}
diff --git a/ext/spl/tests/bug49972.phpt b/ext/spl/tests/bug49972.phpt
new file mode 100755
index 0000000..843c251
--- /dev/null
+++ b/ext/spl/tests/bug49972.phpt
@@ -0,0 +1,11 @@
+--TEST--
+Bug #49972 (AppendIterator undefined function crash)
+--FILE--
+<?php
+
+$iterator = new AppendIterator();
+$iterator->undefined();
+
+?>
+--EXPECTF--
+Fatal error: Call to undefined method AppendIterator::undefined() in %s on line %d
diff --git a/ext/spl/tests/iterator_032.phpt b/ext/spl/tests/iterator_032.phpt
index 86695d4..9941a31 100755
--- a/ext/spl/tests/iterator_032.phpt
+++ b/ext/spl/tests/iterator_032.phpt
@@ -47,6 +47,6 @@ int(1)
 int(2)
 Cannot seek to 0 which is below the offset 1
 int(3)
-Cannot seek to 3 which is behind offest 1 plus count 2
+Cannot seek to 3 which is behind offset 1 plus count 2
 bool(false)
 ===DONE===
diff --git a/ext/spl/tests/iterator_056.phpt b/ext/spl/tests/iterator_056.phpt
new file mode 100644
index 0000000..c629087
--- /dev/null
+++ b/ext/spl/tests/iterator_056.phpt
@@ -0,0 +1,21 @@
+--TEST--
+SPL: FilterIterator::__construct(void)
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--CREDITS--
+Sebastian Schürmann
+--FILE--
+<?php
+class myFilterIterator extends FilterIterator {
+	function accept() {
+		
+	}
+}
+try {
+	$it = new myFilterIterator();	
+} catch (InvalidArgumentException $e) {
+	echo 'InvalidArgumentException thrown';
+}
+?>
+--EXPECT--
+InvalidArgumentException thrown
diff --git a/ext/spl/tests/iterator_057.phpt b/ext/spl/tests/iterator_057.phpt
new file mode 100644
index 0000000..b15cbb7
--- /dev/null
+++ b/ext/spl/tests/iterator_057.phpt
@@ -0,0 +1,23 @@
+--TEST--
+SPL: ArrayIterator::__construct(void)
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--CREDITS--
+Sebastian Schürmann
+--FILE--
+<?php
+/**
+ * From Docs: Construct a new array iterator from anything that has a hash table. 
+ * NULL, NOTHING is not a hash table ;) 
+ */
+class myArrayIterator extends ArrayIterator {
+}
+try {
+	$it = new myArrayIterator();
+} catch (InvalidArgumentException $e) {
+	echo 'InvalidArgumentException thrown';
+}
+echo 'no Exception thrown'
+?>
+--EXPECT--
+no Exception thrown
diff --git a/ext/spl/tests/iterator_058.phpt b/ext/spl/tests/iterator_058.phpt
new file mode 100644
index 0000000..6b58fcd
--- /dev/null
+++ b/ext/spl/tests/iterator_058.phpt
@@ -0,0 +1,26 @@
+--TEST--
+SPL: Iterator::__construct(void)
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--CREDITS--
+Sebastian Schürmann
+--FILE--
+<?php
+class myIterator implements Iterator {
+	
+	function current() {}
+	function next() {}
+	function key() {}	
+	function valid() {}
+	function rewind() {}
+	
+}
+try {
+	$it = new myIterator();	
+} catch (InvalidArgumentException $e) {
+	echo 'InvalidArgumentException thrown';
+}
+echo 'no Exception thrown';
+?>
+--EXPECT--
+no Exception thrown
diff --git a/ext/spl/tests/iterator_059.phpt b/ext/spl/tests/iterator_059.phpt
new file mode 100644
index 0000000..8a0fce5
--- /dev/null
+++ b/ext/spl/tests/iterator_059.phpt
@@ -0,0 +1,19 @@
+--TEST--
+SPL: CachingIterator::__construct(void)
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--CREDITS--
+Sebastian Schürmann
+--FILE--
+<?php
+class myCachingIterator extends CachingIterator {
+	
+}
+try {
+	$it = new myCachingIterator();	
+} catch (InvalidArgumentException $e) {
+	echo 'InvalidArgumentException thrown';
+}
+?>
+--EXPECT--
+InvalidArgumentException thrown
diff --git a/ext/spl/tests/iterator_060.phpt b/ext/spl/tests/iterator_060.phpt
new file mode 100644
index 0000000..ef835a3
--- /dev/null
+++ b/ext/spl/tests/iterator_060.phpt
@@ -0,0 +1,19 @@
+--TEST--
+SPL: RecursiveCachingIterator::__construct(void)
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--CREDITS--
+Sebastian Schürmann
+--FILE--
+<?php
+class myRecursiveCachingIterator extends RecursiveCachingIterator {
+	
+}
+try {
+	$it = new myRecursiveCachingIterator();	
+} catch (InvalidArgumentException $e) {
+	echo 'InvalidArgumentException thrown';
+}
+?>
+--EXPECT--
+InvalidArgumentException thrown
diff --git a/ext/spl/tests/iterator_061.phpt b/ext/spl/tests/iterator_061.phpt
new file mode 100644
index 0000000..7a30c6b
--- /dev/null
+++ b/ext/spl/tests/iterator_061.phpt
@@ -0,0 +1,19 @@
+--TEST--
+SPL: ParentIterator::__construct(void)
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--CREDITS--
+Sebastian Schürmann
+--FILE--
+<?php
+class myParentIterator extends ParentIterator {
+	
+}
+try {
+	$it = new myParentIterator();	
+} catch (InvalidArgumentException $e) {
+	echo 'InvalidArgumentException thrown';
+}
+?>
+--EXPECT--
+InvalidArgumentException thrown
diff --git a/ext/spl/tests/iterator_062.phpt b/ext/spl/tests/iterator_062.phpt
new file mode 100644
index 0000000..55be4e9
--- /dev/null
+++ b/ext/spl/tests/iterator_062.phpt
@@ -0,0 +1,20 @@
+--TEST--
+SPL: RecursiveIteratorIterator::__construct(void)
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--CREDITS--
+Sebastian Schürmann
+--FILE--
+<?php
+class myRecursiveIteratorIterator extends RecursiveIteratorIterator {
+	
+}
+
+try {
+	$it = new myRecursiveIteratorIterator();
+} catch (InvalidArgumentException $e) {
+	echo 'InvalidArgumentException thrown';
+}
+?>
+--EXPECT--
+InvalidArgumentException thrown
\ No newline at end of file
diff --git a/ext/spl/tests/iterator_063.phpt b/ext/spl/tests/iterator_063.phpt
new file mode 100644
index 0000000..f6ab61b
--- /dev/null
+++ b/ext/spl/tests/iterator_063.phpt
@@ -0,0 +1,19 @@
+--TEST--
+SPL: LimitIterator::__construct(void)
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--CREDITS--
+Sebastian Schürmann
+--FILE--
+<?php
+class myLimitIterator extends LimitIterator {
+	
+}
+try {
+	$it = new myLimitIterator();
+} catch (InvalidArgumentException $e) {
+	echo 'InvalidArgumentException thrown';
+}
+?>
+--EXPECT--
+InvalidArgumentException thrown
\ No newline at end of file
diff --git a/ext/spl/tests/iterator_064.phpt b/ext/spl/tests/iterator_064.phpt
new file mode 100644
index 0000000..1ed06a0
--- /dev/null
+++ b/ext/spl/tests/iterator_064.phpt
@@ -0,0 +1,17 @@
+--TEST--
+SPL: CachingIterator::__construct(void)
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--CREDITS--
+Sebastian Schürmann
+--FILE--
+<?php
+class myCachingIterator  extends CachingIterator  {}
+try {
+	$it = new myCachingIterator();
+} catch (InvalidArgumentException $e) {
+	echo 'InvalidArgumentException thrown';
+}
+?>
+--EXPECT--
+InvalidArgumentException thrown
diff --git a/ext/spl/tests/iterator_065.phpt b/ext/spl/tests/iterator_065.phpt
new file mode 100644
index 0000000..78c2689
--- /dev/null
+++ b/ext/spl/tests/iterator_065.phpt
@@ -0,0 +1,17 @@
+--TEST--
+SPL: RecursiveCachingIterator::__construct(void)
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--CREDITS--
+Sebastian Schürmann
+--FILE--
+<?php
+class myRecursiveCachingIterator  extends RecursiveCachingIterator  {}
+try {
+	$it = new myRecursiveCachingIterator();
+} catch (InvalidArgumentException $e) {
+	echo 'InvalidArgumentException thrown';
+}
+?>
+--EXPECT--
+InvalidArgumentException thrown
diff --git a/ext/spl/tests/iterator_066.phpt b/ext/spl/tests/iterator_066.phpt
new file mode 100644
index 0000000..8f08ff4
--- /dev/null
+++ b/ext/spl/tests/iterator_066.phpt
@@ -0,0 +1,17 @@
+--TEST--
+SPL: NoRewindIterator::__construct(void)
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--CREDITS--
+Sebastian Schürmann
+--FILE--
+<?php
+class myNoRewindIterator extends NoRewindIterator  {}
+try {
+	$it = new myNoRewindIterator();
+} catch (InvalidArgumentException $e) {
+	echo 'InvalidArgumentException thrown';
+}
+?>
+--EXPECT--
+InvalidArgumentException thrown
diff --git a/ext/spl/tests/iterator_067.phpt b/ext/spl/tests/iterator_067.phpt
new file mode 100644
index 0000000..65db114
--- /dev/null
+++ b/ext/spl/tests/iterator_067.phpt
@@ -0,0 +1,18 @@
+--TEST--
+SPL: AppendIterator::__construct(void)
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--CREDITS--
+Sebastian Schürmann
+--FILE--
+<?php
+class myAppendIterator extends AppendIterator {}
+try {
+	$it = new myAppendIterator();
+	echo "no exception";
+} catch (InvalidArgumentException $e) {
+	echo 'InvalidArgumentException thrown';
+}
+?>
+--EXPECT--
+no exception
diff --git a/ext/spl/tests/iterator_069.phpt b/ext/spl/tests/iterator_069.phpt
new file mode 100644
index 0000000..e842da9
--- /dev/null
+++ b/ext/spl/tests/iterator_069.phpt
@@ -0,0 +1,19 @@
+--TEST--
+SPL: RecursiveIteratorIterator cannot be used with foreach by reference
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--FILE--
+<?php 
+
+$arr = array(array(1,2));
+$arrOb = new ArrayObject($arr);
+
+$recArrIt = new RecursiveArrayIterator($arrOb->getIterator());
+
+$recItIt = new RecursiveIteratorIterator($recArrIt);
+
+foreach ($recItIt as &$val) echo "$val\n";
+
+?>
+--EXPECTF--
+Fatal error: An iterator cannot be used with foreach by reference in %s on line %d
diff --git a/ext/spl/tests/iterator_070.phpt b/ext/spl/tests/iterator_070.phpt
new file mode 100644
index 0000000..3175385
--- /dev/null
+++ b/ext/spl/tests/iterator_070.phpt
@@ -0,0 +1,22 @@
+--TEST--
+SPL: RecursiveIteratorIterator - Ensure that non-overriden methods execute problem free.
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--FILE--
+<?php
+
+$array = array();
+$recArrIt = new RecursiveArrayIterator($array);
+
+$recItIt = new RecursiveIteratorIterator($recArrIt);
+
+var_dump($recItIt->beginIteration());
+var_dump($recItIt->endIteration());
+var_dump($recItIt->nextElement());
+
+?>
+
+--EXPECTF--
+NULL
+NULL
+NULL
\ No newline at end of file
diff --git a/ext/spl/tests/iterator_071.phpt b/ext/spl/tests/iterator_071.phpt
new file mode 100644
index 0000000..62bc5fe
--- /dev/null
+++ b/ext/spl/tests/iterator_071.phpt
@@ -0,0 +1,34 @@
+--TEST--
+SPL: RecursiveIteratorIterator - Test where the case is RS_SELF and mode is CHILD_FIRST
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--FILE--
+<?php 
+
+$arr = array(array(1,2),2);
+$arrOb = new ArrayObject($arr);
+
+$recArrIt = new RecursiveArrayIterator($arrOb->getIterator());
+
+class MyRecursiveIteratorIterator extends RecursiveIteratorIterator {
+    
+    function nextelement() {
+    	echo __METHOD__."\n";
+    }
+}
+
+
+$recItIt = new MyRecursiveIteratorIterator($recArrIt, RecursiveIteratorIterator::CHILD_FIRST);
+
+foreach ($recItIt as $key => $val) echo "$key\n";
+
+?>
+--EXPECTF--
+MyRecursiveIteratorIterator::nextelement
+0
+MyRecursiveIteratorIterator::nextelement
+1
+MyRecursiveIteratorIterator::nextelement
+0
+MyRecursiveIteratorIterator::nextelement
+1
\ No newline at end of file
diff --git a/ext/spl/tests/recursiveIteratorIterator_beginchildren_error.phpt b/ext/spl/tests/recursiveIteratorIterator_beginchildren_error.phpt
new file mode 100644
index 0000000..2ef68a5
--- /dev/null
+++ b/ext/spl/tests/recursiveIteratorIterator_beginchildren_error.phpt
@@ -0,0 +1,38 @@
+--TEST--
+SPL: RecursiveIteratorIterator - Exception thrown in beginchildren which should be handled in next()
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--FILE--
+<?php 
+
+$arr = array(array(1,2),2);
+$arrOb = new ArrayObject($arr);
+
+$recArrIt = new RecursiveArrayIterator($arrOb->getIterator());
+
+class MyRecursiveIteratorIterator extends RecursiveIteratorIterator {
+    
+    function beginchildren() {
+    	throw new Exception;
+    }
+}
+
+
+$recItIt = new MyRecursiveIteratorIterator($recArrIt, RecursiveIteratorIterator::LEAVES_ONLY, RecursiveIteratorIterator::CATCH_GET_CHILD);
+
+var_dump($recItIt->next());
+
+$recItIt2 = new MyRecursiveIteratorIterator($recArrIt, RecursiveIteratorIterator::LEAVES_ONLY);
+
+var_dump($recItIt2->next());
+
+?>
+--EXPECTF--
+NULL
+
+Fatal error: Uncaught exception 'Exception' in %s
+Stack trace:
+#0 [internal function]: MyRecursiveIteratorIterator->beginchildren()
+#1 %s: RecursiveIteratorIterator->next()
+#2 {main}
+  thrown in %s on line %d
diff --git a/ext/spl/tests/recursiveIteratorIterator_callHasChildren_error.phpt b/ext/spl/tests/recursiveIteratorIterator_callHasChildren_error.phpt
new file mode 100644
index 0000000..acae9db
--- /dev/null
+++ b/ext/spl/tests/recursiveIteratorIterator_callHasChildren_error.phpt
@@ -0,0 +1,38 @@
+--TEST--
+SPL: RecursiveIteratorIterator - Exception thrown in callHasChildren which should be handled in next()
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--FILE--
+<?php 
+
+$arr = array(1,2);
+$arrOb = new ArrayObject($arr);
+
+$recArrIt = new RecursiveArrayIterator($arrOb->getIterator());
+
+class MyRecursiveIteratorIterator extends RecursiveIteratorIterator {
+    
+    function callHasChildren() {
+    	throw new Exception;
+    }
+}
+
+
+$recItIt = new MyRecursiveIteratorIterator($recArrIt, RecursiveIteratorIterator::LEAVES_ONLY, RecursiveIteratorIterator::CATCH_GET_CHILD);
+
+var_dump($recItIt->next());
+
+$recItIt2 = new MyRecursiveIteratorIterator($recArrIt, RecursiveIteratorIterator::LEAVES_ONLY);
+
+var_dump($recItIt2->next());
+
+?>
+--EXPECTF--
+NULL
+
+Fatal error: Uncaught exception 'Exception' in %s
+Stack trace:
+#0 [internal function]: MyRecursiveIteratorIterator->callHasChildren()
+#1 %s: RecursiveIteratorIterator->next()
+#2 {main}
+  thrown in %s on line %d
diff --git a/ext/spl/tests/recursiveIteratorIterator_endchildren_error.phpt b/ext/spl/tests/recursiveIteratorIterator_endchildren_error.phpt
new file mode 100644
index 0000000..ef51dfa
--- /dev/null
+++ b/ext/spl/tests/recursiveIteratorIterator_endchildren_error.phpt
@@ -0,0 +1,44 @@
+--TEST--
+SPL: RecursiveIteratorIterator - Exception thrown in endchildren which should be handled in next()
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--FILE--
+<?php 
+
+$arr = array(array(1,2));
+$arrOb = new ArrayObject($arr);
+
+$recArrIt = new RecursiveArrayIterator($arrOb->getIterator());
+
+class MyRecursiveIteratorIterator extends RecursiveIteratorIterator {
+    
+    function endchildren() {
+    	throw new Exception;
+    }
+}
+
+
+$recItIt = new MyRecursiveIteratorIterator($recArrIt, RecursiveIteratorIterator::LEAVES_ONLY, RecursiveIteratorIterator::CATCH_GET_CHILD);
+
+foreach ($recItIt as $val) echo "$val\n";
+
+$recItIt2 = new MyRecursiveIteratorIterator($recArrIt, RecursiveIteratorIterator::LEAVES_ONLY);
+
+echo "===NEXT LOOP===\n";
+
+foreach ($recItIt2 as $val) echo "$val\n";
+
+?>
+--EXPECTF--
+1
+2
+===NEXT LOOP===
+1
+2
+
+Fatal error: Uncaught exception 'Exception' in %s
+Stack trace:
+#0 [internal function]: MyRecursiveIteratorIterator->endchildren()
+#1 %s: RecursiveIteratorIterator->next()
+#2 {main}
+  thrown in %s on line %d
diff --git a/ext/spl/tests/recursiveIteratorIterator_nextelement_error.phpt b/ext/spl/tests/recursiveIteratorIterator_nextelement_error.phpt
new file mode 100644
index 0000000..25cf709
--- /dev/null
+++ b/ext/spl/tests/recursiveIteratorIterator_nextelement_error.phpt
@@ -0,0 +1,38 @@
+--TEST--
+SPL: RecursiveIteratorIterator - Exception thrown in nextelement which should be handled in next()
+--SKIPIF--
+<?php if (!extension_loaded("spl")) print "skip"; ?>
+--FILE--
+<?php 
+
+$arr = array(1,2);
+$arrOb = new ArrayObject($arr);
+
+$recArrIt = new RecursiveArrayIterator($arrOb->getIterator());
+
+class MyRecursiveIteratorIterator extends RecursiveIteratorIterator {
+    
+    function nextelement() {
+    	throw new Exception;
+    }
+}
+
+
+$recItIt = new MyRecursiveIteratorIterator($recArrIt, RecursiveIteratorIterator::LEAVES_ONLY, RecursiveIteratorIterator::CATCH_GET_CHILD);
+
+var_dump($recItIt->next());
+
+$recItIt = new MyRecursiveIteratorIterator($recArrIt, RecursiveIteratorIterator::LEAVES_ONLY);
+
+var_dump($recItIt->next());
+
+?>
+--EXPECTF--
+NULL
+
+Fatal error: Uncaught exception 'Exception' in %s
+Stack trace:
+#0 [internal function]: MyRecursiveIteratorIterator->nextelement()
+#1 %s: RecursiveIteratorIterator->next()
+#2 {main}
+  thrown in %s on line %d
diff --git a/ext/sqlite/config.m4 b/ext/sqlite/config.m4
index 5bacbea..4f7b72c 100644
--- a/ext/sqlite/config.m4
+++ b/ext/sqlite/config.m4
@@ -1,4 +1,4 @@
-dnl $Id: config.m4 266234 2008-09-13 00:24:12Z moriyoshi $
+dnl $Id: config.m4 291414 2009-11-29 06:13:22Z rasmus $
 dnl config.m4 for extension sqlite
 dnl vim:et:ts=2:sw=2
 
diff --git a/ext/sqlite/sqlite.c b/ext/sqlite/sqlite.c
index 453fb94..f5c0aa9 100644
--- a/ext/sqlite/sqlite.c
+++ b/ext/sqlite/sqlite.c
@@ -17,7 +17,7 @@
    |          Marcus Boerger <helly at php.net>                              |
    +----------------------------------------------------------------------+
 
-   $Id: sqlite.c 282740 2009-06-25 00:07:20Z scottmac $
+   $Id: sqlite.c 289587 2009-10-12 19:04:00Z felipe $
 */
 
 #ifdef HAVE_CONFIG_H
@@ -125,7 +125,7 @@ PHP_INI_END()
 	}
 
 #define PHP_SQLITE_EMPTY_QUERY \
-	if (!sql_len) { \
+	if (!sql_len || !*sql) { \
 		php_error_docref(NULL TSRMLS_CC, E_WARNING, "Cannot execute empty query."); \
 		RETURN_FALSE; \
 	}
@@ -1128,7 +1128,7 @@ PHP_MINFO_FUNCTION(sqlite)
 {
 	php_info_print_table_start();
 	php_info_print_table_header(2, "SQLite support", "enabled");
-	php_info_print_table_row(2, "PECL Module version", PHP_SQLITE_MODULE_VERSION " $Id: sqlite.c 282740 2009-06-25 00:07:20Z scottmac $");
+	php_info_print_table_row(2, "PECL Module version", PHP_SQLITE_MODULE_VERSION " $Id: sqlite.c 289587 2009-10-12 19:04:00Z felipe $");
 	php_info_print_table_row(2, "SQLite Library", sqlite_libversion());
 	php_info_print_table_row(2, "SQLite Encoding", sqlite_libencoding());
 	php_info_print_table_end();
diff --git a/ext/sqlite/tests/sqlitedatabase_arrayquery.phpt b/ext/sqlite/tests/sqlitedatabase_arrayquery.phpt
new file mode 100644
index 0000000..1e3084c
--- /dev/null
+++ b/ext/sqlite/tests/sqlitedatabase_arrayquery.phpt
@@ -0,0 +1,23 @@
+--TEST--
+Testing SQLiteDatabase::ArrayQuery with NULL-byte string
+--SKIPIF--
+<?php
+if (!extension_loaded("sqlite")) print "skip";
+?>
+--FILE--
+<?php
+
+$method = new ReflectionMethod('sqlitedatabase::arrayquery');
+
+$class = $method->getDeclaringClass()->newInstanceArgs(array(':memory:'));
+
+$p = "\0";
+
+$method->invokeArgs($class, array_fill(0, 2, $p));
+$method->invokeArgs($class, array_fill(0, 1, $p));
+
+?>
+--EXPECTF--
+Warning: SQLiteDatabase::arrayQuery() expects parameter 2 to be long, string given in %s on line %d
+
+Warning: SQLiteDatabase::arrayQuery(): Cannot execute empty query. in %s on line %d
diff --git a/ext/standard/array.c b/ext/standard/array.c
index 1a8b9d6..c0615ca 100644
--- a/ext/standard/array.c
+++ b/ext/standard/array.c
@@ -21,7 +21,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: array.c 287274 2009-08-14 06:18:47Z dmitry $ */
+/* $Id: array.c 291415 2009-11-29 08:35:01Z stas $ */
 
 #include "php.h"
 #include "php_ini.h"
@@ -656,20 +656,22 @@ static int array_user_compare(const void *a, const void *b TSRMLS_DC) /* {{{ */
    Sort an array by values using a user-defined comparison function */
 PHP_FUNCTION(usort)
 {
-	zval **array;
+	zval **array_ptr, *array;
 	int refcount;
 	HashTable *target_hash;
+	zval *func_name;
 	PHP_ARRAY_CMP_FUNC_VARS;
 
 	PHP_ARRAY_CMP_FUNC_BACKUP();
 
 
-	if (ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, &array, &BG(user_compare_func_name)) == FAILURE) {
+	if (ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, &array_ptr, &BG(user_compare_func_name)) == FAILURE) {
 		PHP_ARRAY_CMP_FUNC_RESTORE();
 		WRONG_PARAM_COUNT;
 	}
+	array = *array_ptr;
 
-	target_hash = HASH_OF(*array);
+	target_hash = HASH_OF(array);
 	if (!target_hash) {
 		php_error_docref(NULL TSRMLS_CC, E_WARNING, "The argument should be an array");
 		PHP_ARRAY_CMP_FUNC_RESTORE();
@@ -677,6 +679,8 @@ PHP_FUNCTION(usort)
 	}
 
 	PHP_ARRAY_CMP_FUNC_CHECK(BG(user_compare_func_name))
+	func_name = *BG(user_compare_func_name);
+	BG(user_compare_func_name) = &func_name;
 	BG(user_compare_fci_cache).initialized = 0;
 	
 	/* Clear the is_ref flag, so the attemts to modify the array in user
@@ -685,13 +689,13 @@ PHP_FUNCTION(usort)
 	 * comparison. The result of sorting in such case is undefined and the
 	 * function returns FALSE.
 	 */
-	(*array)->is_ref = 0;
-	refcount = (*array)->refcount;
+	array->is_ref = 0;
+	refcount = array->refcount;
 
 	if (zend_hash_sort(target_hash, zend_qsort, array_user_compare, 1 TSRMLS_CC) == FAILURE) {
 		RETVAL_FALSE;
 	} else {
-		if (refcount > (*array)->refcount) {
+		if (refcount > array->refcount) {
 			php_error_docref(NULL TSRMLS_CC, E_WARNING, "Array was modified by the user comparison function");
 			RETVAL_FALSE;
 		} else {
@@ -699,8 +703,8 @@ PHP_FUNCTION(usort)
 		}
 	}
 
-	if ((*array)->refcount > 1) {
-		(*array)->is_ref = 1;
+	if (array->refcount > 1) {
+		array->is_ref = 1;
 	}
 	
 	PHP_ARRAY_CMP_FUNC_RESTORE();
@@ -711,18 +715,20 @@ PHP_FUNCTION(usort)
    Sort an array with a user-defined comparison function and maintain index association */
 PHP_FUNCTION(uasort)
 {
-	zval **array;
+	zval **array_ptr, *array;
 	int refcount;
 	HashTable *target_hash;
+	zval *func_name;
 	PHP_ARRAY_CMP_FUNC_VARS;
 
 	PHP_ARRAY_CMP_FUNC_BACKUP();
 
-	if (ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, &array, &BG(user_compare_func_name)) == FAILURE) {
+	if (ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, &array_ptr, &BG(user_compare_func_name)) == FAILURE) {
 		PHP_ARRAY_CMP_FUNC_RESTORE();
 		WRONG_PARAM_COUNT;
 	}
-	target_hash = HASH_OF(*array);
+	array = *array_ptr;
+	target_hash = HASH_OF(array);
 	if (!target_hash) {
 		php_error_docref(NULL TSRMLS_CC, E_WARNING, "The argument should be an array");
 		PHP_ARRAY_CMP_FUNC_RESTORE();
@@ -730,6 +736,8 @@ PHP_FUNCTION(uasort)
 	}
 
 	PHP_ARRAY_CMP_FUNC_CHECK(BG(user_compare_func_name))
+	func_name = *BG(user_compare_func_name);
+	BG(user_compare_func_name) = &func_name;
 	BG(user_compare_fci_cache).initialized = 0;
 
 	/* Clear the is_ref flag, so the attemts to modify the array in user
@@ -738,13 +746,13 @@ PHP_FUNCTION(uasort)
 	 * comparison. The result of sorting in such case is undefined and the
 	 * function returns FALSE.
 	 */
-	(*array)->is_ref = 0;
-	refcount = (*array)->refcount;
+	array->is_ref = 0;
+	refcount = array->refcount;
 
 	if (zend_hash_sort(target_hash, zend_qsort, array_user_compare, 0 TSRMLS_CC) == FAILURE) {
 		RETVAL_FALSE;
 	} else {
-		if (refcount > (*array)->refcount) {
+		if (refcount > array->refcount) {
 			php_error_docref(NULL TSRMLS_CC, E_WARNING, "Array was modified by the user comparison function");
 			RETVAL_FALSE;
 		} else {
@@ -752,8 +760,8 @@ PHP_FUNCTION(uasort)
 		}
 	}
 
-	if ((*array)->refcount > 1) {
-		(*array)->is_ref = 1;
+	if (array->refcount > 1) {
+		array->is_ref = 1;
 	}
 
 	PHP_ARRAY_CMP_FUNC_RESTORE();
@@ -762,17 +770,17 @@ PHP_FUNCTION(uasort)
 
 static int array_user_key_compare(const void *a, const void *b TSRMLS_DC) /* {{{ */
 {
+	zend_fcall_info fci;
 	Bucket *f;
 	Bucket *s;
 	zval *key1, *key2;
-	zval *args[2];
-	zval retval;
-	int status;
+	zval **args[2];
+	zval *retval_ptr = NULL;
 
 	ALLOC_INIT_ZVAL(key1);
 	ALLOC_INIT_ZVAL(key2);
-	args[0] = key1;
-	args[1] = key2;
+	args[0] = &key1;
+	args[1] = &key2;
 	
 	f = *((Bucket **) a);
 	s = *((Bucket **) b);
@@ -793,16 +801,30 @@ static int array_user_key_compare(const void *a, const void *b TSRMLS_DC) /* {{{
 		Z_LVAL_P(key2) = s->h;
 		Z_TYPE_P(key2) = IS_LONG;
 	}
-
-	status = call_user_function(EG(function_table), NULL, *BG(user_compare_func_name), &retval, 2, args TSRMLS_CC);
-	
-	zval_ptr_dtor(&key1);
-	zval_ptr_dtor(&key2);
 	
-	if (status == SUCCESS) {
-		convert_to_long(&retval);
-		return Z_LVAL(retval);
+	fci.size = sizeof(fci);
+	fci.function_table = EG(function_table);
+	fci.function_name = *BG(user_compare_func_name);
+	fci.symbol_table = NULL;
+	fci.object_pp = NULL;
+	fci.retval_ptr_ptr = &retval_ptr;
+	fci.param_count = 2;
+	fci.params = args;
+	fci.no_separation = 0;
+
+	if (zend_call_function(&fci, &BG(user_compare_fci_cache) TSRMLS_CC)== SUCCESS
+		&& retval_ptr) {
+		long retval;
+
+		convert_to_long_ex(&retval_ptr);
+		retval = Z_LVAL_P(retval_ptr);
+		zval_ptr_dtor(&retval_ptr);
+		zval_ptr_dtor(&key1);
+		zval_ptr_dtor(&key2);
+		return retval;
 	} else {
+		zval_ptr_dtor(&key1);
+		zval_ptr_dtor(&key2);
 		return 0;
 	}
 }
@@ -812,18 +834,21 @@ static int array_user_key_compare(const void *a, const void *b TSRMLS_DC) /* {{{
    Sort an array by keys using a user-defined comparison function */
 PHP_FUNCTION(uksort)
 {
-	zval **array;
+	zval **array_ptr, *array;
+	int refcount;
 	HashTable *target_hash;
+	zval *func_name;
 	PHP_ARRAY_CMP_FUNC_VARS;
 
 
 	PHP_ARRAY_CMP_FUNC_BACKUP();
 
-	if (ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, &array, &BG(user_compare_func_name)) == FAILURE) {
+	if (ZEND_NUM_ARGS() != 2 || zend_get_parameters_ex(2, &array_ptr, &BG(user_compare_func_name)) == FAILURE) {
 		PHP_ARRAY_CMP_FUNC_RESTORE();
 		WRONG_PARAM_COUNT;
 	}
-	target_hash = HASH_OF(*array);
+	array = *array_ptr;
+	target_hash = HASH_OF(array);
 	if (!target_hash) {
 		php_error_docref(NULL TSRMLS_CC, E_WARNING, "The argument should be an array");
 		PHP_ARRAY_CMP_FUNC_RESTORE();
@@ -832,16 +857,35 @@ PHP_FUNCTION(uksort)
 	}
 
 	PHP_ARRAY_CMP_FUNC_CHECK(BG(user_compare_func_name))
+	func_name = *BG(user_compare_func_name);
+	BG(user_compare_func_name) = &func_name;
 	BG(user_compare_fci_cache).initialized = 0;
 
+	/* Clear the is_ref flag, so the attemts to modify the array in user
+	 * comaprison function will create a copy of array and won't affect the
+	 * original array. The fact of modification is detected using refcount
+	 * comparison. The result of sorting in such case is undefined and the
+	 * function returns FALSE.
+	 */
+	array->is_ref = 0;
+	refcount = array->refcount;
+
 	if (zend_hash_sort(target_hash, zend_qsort, array_user_key_compare, 0 TSRMLS_CC) == FAILURE) {
-		PHP_ARRAY_CMP_FUNC_RESTORE();
+		RETVAL_FALSE;
+	} else {
+		if (refcount > array->refcount) {
+			php_error_docref(NULL TSRMLS_CC, E_WARNING, "Array was modified by the user comparison function");
+			RETVAL_FALSE;
+		} else {
+			RETVAL_TRUE;
+		}
+	}
 
-		RETURN_FALSE;
+	if (array->refcount > 1) {
+		array->is_ref = 1;
 	}
 
 	PHP_ARRAY_CMP_FUNC_RESTORE();
-	RETURN_TRUE;
 }
 /* }}} */
 
diff --git a/ext/standard/basic_functions.c b/ext/standard/basic_functions.c
index e0daf6d..78afe7f 100644
--- a/ext/standard/basic_functions.c
+++ b/ext/standard/basic_functions.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: basic_functions.c 286890 2009-08-06 14:07:16Z scottmac $ */
+/* $Id: basic_functions.c 291144 2009-11-22 18:31:01Z jani $ */
 
 #include "php.h"
 #include "php_streams.h"
@@ -4375,6 +4375,9 @@ PHP_FUNCTION(long2ip)
 	int ip_len;
 	unsigned long n;
 	struct in_addr myaddr;
+#ifdef HAVE_INET_PTON
+	char str[40];
+#endif
 
 	if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "s", &ip, &ip_len) == FAILURE) {
 		return;
@@ -4383,7 +4386,15 @@ PHP_FUNCTION(long2ip)
 	n = strtoul(ip, NULL, 0);
 
 	myaddr.s_addr = htonl(n);
+#ifdef HAVE_INET_PTON
+	if (inet_ntop(AF_INET, &myaddr, str, sizeof(str))) {
+		RETURN_STRING(str, 1);
+	} else {
+		RETURN_FALSE;
+	}
+#else
 	RETURN_STRING(inet_ntoa(myaddr), 1);
+#endif
 }
 /* }}} */
 
@@ -4963,7 +4974,7 @@ error options:
 PHP_FUNCTION(error_log)
 {
 	zval **string, **erropt = NULL, **option = NULL, **emailhead = NULL;
-	int opt_err = 0;
+	int opt_err = 0, message_len = 0;
 	char *message, *opt = NULL, *headers = NULL;
 
 	switch (ZEND_NUM_ARGS()) {
@@ -5007,6 +5018,7 @@ PHP_FUNCTION(error_log)
 
 	convert_to_string_ex(string);
 	message = Z_STRVAL_PP(string);
+	message_len = Z_STRLEN_PP(string);
 
 	if (erropt != NULL) {
 		convert_to_long_ex(erropt);
@@ -5023,7 +5035,7 @@ PHP_FUNCTION(error_log)
 		headers = Z_STRVAL_PP(emailhead);
 	}
 
-	if (_php_error_log(opt_err, message, opt, headers TSRMLS_CC) == FAILURE) {
+	if (_php_error_log_ex(opt_err, message, message_len, opt, headers TSRMLS_CC) == FAILURE) {
 		RETURN_FALSE;
 	}
 	
@@ -5031,18 +5043,21 @@ PHP_FUNCTION(error_log)
 }
 /* }}} */
 
-
+/* For BC (not binary safe!) */
 PHPAPI int _php_error_log(int opt_err, char *message, char *opt, char *headers TSRMLS_DC)
 {
-	php_stream *stream = NULL;
+	return _php_error_log_ex(opt_err, message, (opt_err == 3) ? strlen(message) : 0, opt, headers TSRMLS_CC);
+}
 
-	switch (opt_err) {
+PHPAPI int _php_error_log_ex(int opt_err, char *message, int message_len, char *opt, char *headers TSRMLS_DC)
+{
+	php_stream *stream = NULL;
 
+	switch (opt_err)
+	{
 		case 1:		/*send an email */
-			{
-				if (!php_mail(opt, "PHP error_log message", message, headers, NULL TSRMLS_CC)) {
-					return FAILURE;
-				}
+			if (!php_mail(opt, "PHP error_log message", message, headers, NULL TSRMLS_CC)) {
+				return FAILURE;
 			}
 			break;
 
@@ -5053,11 +5068,13 @@ PHPAPI int _php_error_log(int opt_err, char *message, char *opt, char *headers T
 
 		case 3:		/*save to a file */
 			stream = php_stream_open_wrapper(opt, "a", IGNORE_URL_WIN | ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL);
-			if (!stream)
+			if (!stream) {
 				return FAILURE;
-			php_stream_write(stream, message, strlen(message));
+			}
+			php_stream_write(stream, message, message_len);
 			php_stream_close(stream);
 			break;
+
 		case 4: /* send to SAPI */
 			if (sapi_module.log_message) {
 				sapi_module.log_message(message);
@@ -5065,6 +5082,7 @@ PHPAPI int _php_error_log(int opt_err, char *message, char *opt, char *headers T
 				return FAILURE;
 			}
 			break;
+
 		default:
 			php_log_err(message TSRMLS_CC);
 			break;
@@ -6381,6 +6399,7 @@ PHP_FUNCTION(import_request_variables)
 	char *types, *prefix;
 	uint prefix_len;
 	char *p;
+	zend_bool ok = 0;
 
 	switch (ZEND_NUM_ARGS()) {
 
@@ -6418,20 +6437,24 @@ PHP_FUNCTION(import_request_variables)
 			case 'g':
 			case 'G':
 				zend_hash_apply_with_arguments(Z_ARRVAL_P(PG(http_globals)[TRACK_VARS_GET]), (apply_func_args_t) copy_request_variable, 2, prefix, prefix_len);
+				ok = 1;
 				break;
 	
 			case 'p':
 			case 'P':
 				zend_hash_apply_with_arguments(Z_ARRVAL_P(PG(http_globals)[TRACK_VARS_POST]), (apply_func_args_t) copy_request_variable, 2, prefix, prefix_len);
 				zend_hash_apply_with_arguments(Z_ARRVAL_P(PG(http_globals)[TRACK_VARS_FILES]), (apply_func_args_t) copy_request_variable, 2, prefix, prefix_len);
+				ok = 1;
 				break;
 
 			case 'c':
 			case 'C':
 				zend_hash_apply_with_arguments(Z_ARRVAL_P(PG(http_globals)[TRACK_VARS_COOKIE]), (apply_func_args_t) copy_request_variable, 2, prefix, prefix_len);
+				ok = 1;
 				break;
 		}
 	}
+	RETURN_BOOL(ok);
 }
 /* }}} */
 
diff --git a/ext/standard/basic_functions.h b/ext/standard/basic_functions.h
index a2337fa..9835666 100644
--- a/ext/standard/basic_functions.h
+++ b/ext/standard/basic_functions.h
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: basic_functions.h 286378 2009-07-26 22:59:46Z jani $ */
+/* $Id: basic_functions.h 291144 2009-11-22 18:31:01Z jani $ */
 
 #ifndef BASIC_FUNCTIONS_H
 #define BASIC_FUNCTIONS_H
@@ -135,7 +135,9 @@ PHP_FUNCTION(stream_bucket_new);
 PHP_MINIT_FUNCTION(user_filters);
 PHP_RSHUTDOWN_FUNCTION(user_filters);
 
+/* Left for BC (not binary safe!) */
 PHPAPI int _php_error_log(int opt_err, char *message, char *opt, char *headers TSRMLS_DC);
+PHPAPI int _php_error_log_ex(int opt_err, char *message, int message_len, char *opt, char *headers TSRMLS_DC);
 
 #if SIZEOF_INT == 4
 /* Most 32-bit and 64-bit systems have 32-bit ints */
diff --git a/ext/standard/config.m4 b/ext/standard/config.m4
index 6ec3151..38602c0 100644
--- a/ext/standard/config.m4
+++ b/ext/standard/config.m4
@@ -1,4 +1,4 @@
-dnl $Id: config.m4 286890 2009-08-06 14:07:16Z scottmac $ -*- autoconf -*-
+dnl $Id: config.m4 291364 2009-11-27 23:41:13Z rasmus $ -*- autoconf -*-
 
 divert(3)dnl
 
@@ -282,13 +282,13 @@ dnl
 dnl Check if there is a support means of creating a new process
 dnl and defining which handles it receives
 dnl
-AC_CACHE_VAL(php_can_support_proc_open,[
 AC_CHECK_FUNCS(fork CreateProcess, [
   php_can_support_proc_open=yes
   break
 ],[
   php_can_support_proc_open=no
-])])
+])
+
 AC_MSG_CHECKING([if your OS can spawn processes with inherited handles])
 if test "$php_can_support_proc_open" = "yes"; then
   AC_MSG_RESULT(yes)
@@ -315,6 +315,18 @@ PHP_CHECK_FUNC(res_nmkquery, resolv, bind, socket)
 PHP_CHECK_FUNC(res_nsend, resolv, bind, socket)
 PHP_CHECK_FUNC(dn_expand, resolv, bind, socket)
 
+dnl OSX has the dns functions in libc but remaps them in resolv.h for bind so linking fails
+case $host_alias in
+  *darwin*)
+    macosx_major=`sw_vers -productVersion | cut -d . -f 1`
+    macosx_minor=`sw_vers -productVersion | cut -d . -f 2`
+
+    if test "$macosx_major" -ge "10" && test "$macosx_minor" -ge "6" ; then
+      LIBS="$LIBS -lresolv"
+    fi
+  ;;
+esac
+
 dnl
 dnl Check if atof() accepts NAN
 dnl
diff --git a/ext/standard/dns.c b/ext/standard/dns.c
index 0e7246f..018f05e 100644
--- a/ext/standard/dns.c
+++ b/ext/standard/dns.c
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: dns.c 286890 2009-08-06 14:07:16Z scottmac $ */
+/* $Id: dns.c 289700 2009-10-16 16:09:49Z scottmac $ */
 
 /* {{{ includes */
 #include "php.h"
@@ -55,6 +55,9 @@
 #undef STATUS
 #undef T_UNSPEC
 #endif
+#if HAVE_ARPA_NAMESER_COMPAT_H
+#include <arpa/nameser_compat.h>
+#endif
 #if HAVE_ARPA_NAMESER_H
 #include <arpa/nameser.h>
 #endif
diff --git a/ext/standard/exec.c b/ext/standard/exec.c
index 4cee27a..120838a 100644
--- a/ext/standard/exec.c
+++ b/ext/standard/exec.c
@@ -16,7 +16,7 @@
    |         Ilia Alshanetsky <iliaa at php.net>                             |
    +----------------------------------------------------------------------+
  */
-/* $Id: exec.c 279616 2009-04-30 15:25:05Z pajoye $ */
+/* $Id: exec.c 289624 2009-10-14 01:32:07Z iliaa $ */
 
 #include <stdio.h>
 #include "php.h"
@@ -62,7 +62,7 @@ int php_exec(int type, char *cmd, zval *array, zval *return_value TSRMLS_DC)
 {
 	FILE *fp;
 	char *buf, *tmp=NULL;
-	int l, pclose_return;
+	int l = 0, pclose_return;
 	char *cmd_p, *b, *c, *d=NULL;
 	php_stream *stream;
 	size_t buflen, bufl = 0;
@@ -154,13 +154,16 @@ int php_exec(int type, char *cmd, zval *array, zval *return_value TSRMLS_DC)
 		}
 		if (bufl) {
 			/* strip trailing whitespaces if we have not done so already */	
-			if (type != 2) {
+			if ((type == 2 && bufl && !l) || type != 2) {
 				l = bufl;
 				while (l-- && isspace(((unsigned char *)buf)[l]));
 				if (l != (int)(bufl - 1)) {
 					bufl = l + 1;
 					buf[bufl] = '\0';
 				}
+				if (type == 2) {
+					add_next_index_stringl(array, buf, bufl, 1);
+				}
 			}
 
 			/* Return last line from the shell command */
diff --git a/ext/standard/file.c b/ext/standard/file.c
index 6e108c4..a59a442 100644
--- a/ext/standard/file.c
+++ b/ext/standard/file.c
@@ -21,7 +21,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: file.c 281040 2009-05-24 16:02:22Z iliaa $ */
+/* $Id: file.c 290184 2009-11-03 18:56:47Z guenter $ */
 
 /* Synced with php 3.0 revision 1.218 1999-06-16 [ssb] */
 
@@ -48,16 +48,6 @@
 #define O_RDONLY _O_RDONLY
 #include "win32/param.h"
 #include "win32/winutil.h"
-#elif defined(NETWARE)
-#include <sys/param.h>
-#include <sys/select.h>
-#ifdef USE_WINSOCK
-#include <novsock2.h>
-#else
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include <netdb.h>
-#endif
 #else
 #if HAVE_SYS_PARAM_H
 #include <sys/param.h>
@@ -838,6 +828,10 @@ PHP_FUNCTION(tempnam)
 	convert_to_string_ex(arg1);
 	convert_to_string_ex(arg2);
 
+	if (PG(safe_mode) &&(!php_checkuid(Z_STRVAL_PP(arg1), NULL, CHECKUID_ALLOW_ONLY_DIR))) {
+		RETURN_FALSE;
+	}
+
 	if (php_check_open_basedir(Z_STRVAL_PP(arg1) TSRMLS_CC)) {
 		RETURN_FALSE;
 	}
@@ -1689,16 +1683,9 @@ PHP_NAMED_FUNCTION(php_if_fstat)
 	MAKE_LONG_ZVAL_INCREF(stat_rdev, -1); 
 #endif
 	MAKE_LONG_ZVAL_INCREF(stat_size, stat_ssb.sb.st_size);
-#ifdef NETWARE
-	MAKE_LONG_ZVAL_INCREF(stat_atime, stat_ssb.sb.st_atime.tv_sec);
-	MAKE_LONG_ZVAL_INCREF(stat_mtime, stat_ssb.sb.st_mtime.tv_sec);
-	MAKE_LONG_ZVAL_INCREF(stat_ctime, stat_ssb.sb.st_ctime.tv_sec);
-#else
 	MAKE_LONG_ZVAL_INCREF(stat_atime, stat_ssb.sb.st_atime);
 	MAKE_LONG_ZVAL_INCREF(stat_mtime, stat_ssb.sb.st_mtime);
 	MAKE_LONG_ZVAL_INCREF(stat_ctime, stat_ssb.sb.st_ctime);
-#endif
-
 #ifdef HAVE_ST_BLKSIZE
 	MAKE_LONG_ZVAL_INCREF(stat_blksize, stat_ssb.sb.st_blksize); 
 #else
diff --git a/ext/standard/filestat.c b/ext/standard/filestat.c
index 344cec1..26fc0be 100644
--- a/ext/standard/filestat.c
+++ b/ext/standard/filestat.c
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: filestat.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: filestat.c 290177 2009-11-03 17:50:10Z guenter $ */
 
 #include "php.h"
 #include "safe_mode.h"
@@ -386,7 +386,7 @@ PHP_FUNCTION(disk_free_space)
 }
 /* }}} */
 
-#if !defined(WINDOWS)
+#if !defined(WINDOWS) && !defined(NETWARE)
 static void php_do_chgrp(INTERNAL_FUNCTION_PARAMETERS, int do_lchgrp) /* {{{ */
 {
 	zval **filename, **group;
@@ -871,23 +871,11 @@ PHPAPI void php_stat(const char *filename, php_stat_len filename_length, int typ
 	case FS_GROUP:
 		RETURN_LONG((long)ssb.sb.st_gid);
 	case FS_ATIME:
-#ifdef NETWARE
-		RETURN_LONG((long)ssb.sb.st_atime.tv_sec);
-#else
 		RETURN_LONG((long)ssb.sb.st_atime);
-#endif
 	case FS_MTIME:
-#ifdef NETWARE
-		RETURN_LONG((long)ssb.sb.st_mtime.tv_sec);
-#else
 		RETURN_LONG((long)ssb.sb.st_mtime);
-#endif
 	case FS_CTIME:
-#ifdef NETWARE
-		RETURN_LONG((long)ssb.sb.st_ctime.tv_sec);
-#else
 		RETURN_LONG((long)ssb.sb.st_ctime);
-#endif
 	case FS_TYPE:
 		if (S_ISLNK(ssb.sb.st_mode)) {
 			RETURN_STRING("link", 1);
@@ -935,15 +923,9 @@ PHPAPI void php_stat(const char *filename, php_stat_len filename_length, int typ
 		MAKE_LONG_ZVAL_INCREF(stat_rdev, -1); 
 #endif
 		MAKE_LONG_ZVAL_INCREF(stat_size, stat_sb->st_size);
-#ifdef NETWARE
-		MAKE_LONG_ZVAL_INCREF(stat_atime, (stat_sb->st_atime).tv_sec);
-		MAKE_LONG_ZVAL_INCREF(stat_mtime, (stat_sb->st_mtime).tv_sec);
-		MAKE_LONG_ZVAL_INCREF(stat_ctime, (stat_sb->st_ctime).tv_sec);
-#else
 		MAKE_LONG_ZVAL_INCREF(stat_atime, stat_sb->st_atime);
 		MAKE_LONG_ZVAL_INCREF(stat_mtime, stat_sb->st_mtime);
 		MAKE_LONG_ZVAL_INCREF(stat_ctime, stat_sb->st_ctime);
-#endif
 #ifdef HAVE_ST_BLKSIZE
 		MAKE_LONG_ZVAL_INCREF(stat_blksize, stat_sb->st_blksize); 
 #else
diff --git a/ext/standard/formatted_print.c b/ext/standard/formatted_print.c
index 243e6e5..e2752d5 100644
--- a/ext/standard/formatted_print.c
+++ b/ext/standard/formatted_print.c
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: formatted_print.c 284649 2009-07-23 14:54:04Z jani $ */
+/* $Id: formatted_print.c 290150 2009-11-02 17:37:32Z felipe $ */
 
 #include <math.h>				/* modf() */
 #include "php.h"
@@ -232,14 +232,14 @@ php_sprintf_appenddouble(char **buffer, int *pos,
 	if (zend_isnan(number)) {
 		is_negative = (number<0);
 		php_sprintf_appendstring(buffer, pos, size, "NaN", 3, 0, padding,
-								 alignment, precision, is_negative, 0, always_sign);
+								 alignment, 3, is_negative, 0, always_sign);
 		return;
 	}
 
 	if (zend_isinf(number)) {
 		is_negative = (number<0);
 		php_sprintf_appendstring(buffer, pos, size, "INF", 3, 0, padding,
-								 alignment, precision, is_negative, 0, always_sign);
+								 alignment, 3, is_negative, 0, always_sign);
 		return;
 	}
 
diff --git a/ext/standard/ftp_fopen_wrapper.c b/ext/standard/ftp_fopen_wrapper.c
index 61a02c2..03ac0c8 100644
--- a/ext/standard/ftp_fopen_wrapper.c
+++ b/ext/standard/ftp_fopen_wrapper.c
@@ -18,7 +18,7 @@
    |          Sara Golemon <pollita at php.net>                              |
    +----------------------------------------------------------------------+
  */
-/* $Id: ftp_fopen_wrapper.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: ftp_fopen_wrapper.c 290178 2009-11-03 17:58:17Z guenter $ */
 
 #include "php.h"
 #include "php_globals.h"
@@ -836,32 +836,19 @@ static int php_stream_ftp_url_stat(php_stream_wrapper *wrapper, char *url, int f
 		tm.tm_sec += stamp - mktime(gmt);
 		tm.tm_isdst = gmt->tm_isdst;
 
-#ifdef NETWARE
-		ssb->sb.st_mtime.tv_sec = mktime(&tm);
-#else
 		ssb->sb.st_mtime = mktime(&tm);
-#endif
 	} else {
 		/* error or unsupported command */
 mdtm_error:
-#ifdef NETWARE
-		ssb->sb.st_mtime.tv_sec = -1;
-#else
 		ssb->sb.st_mtime = -1;
-#endif
 	}
 
 	ssb->sb.st_ino = 0;						/* Unknown values */
 	ssb->sb.st_dev = 0;
 	ssb->sb.st_uid = 0;
 	ssb->sb.st_gid = 0;
-#ifdef NETWARE
-	ssb->sb.st_atime.tv_sec = -1;
-	ssb->sb.st_ctime.tv_sec = -1;
-#else
 	ssb->sb.st_atime = -1;
 	ssb->sb.st_ctime = -1;
-#endif
 
 	ssb->sb.st_nlink = 1;
 	ssb->sb.st_rdev = -1;
diff --git a/ext/standard/html.c b/ext/standard/html.c
index 3266c22..d1f1ba4 100644
--- a/ext/standard/html.c
+++ b/ext/standard/html.c
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: html.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: html.c 291821 2009-12-07 15:41:43Z moriyoshi $ */
 
 /*
  * HTML entity resources:
@@ -484,15 +484,31 @@ struct basic_entities_dec {
 			}                        \
 			mbseq[mbpos++] = (mbchar); }
 
+/* skip one byte and return */
+#define MB_FAILURE(pos) do { \
+	*newpos = pos + 1; \
+	*status = FAILURE; \
+	return 0; \
+} while (0)
+
 #define CHECK_LEN(pos, chars_need)			\
-	if((str_len - (pos)) < chars_need) {	\
-		*status = FAILURE;					\
-		return 0;							\
+	if (chars_need < 1) {						\
+		if((str_len - (pos)) < chars_need) {	\
+			*newpos = pos;						\
+			*status = FAILURE;					\
+			return 0;							\
+		}										\
+	} else {									\
+		if((str_len - (pos)) < chars_need) {	\
+			*newpos = pos + 1;					\
+			*status = FAILURE;					\
+			return 0;							\
+		}										\
 	}
 
 /* {{{ get_next_char
  */
-inline static unsigned short get_next_char(enum entity_charset charset,
+inline static unsigned int get_next_char(enum entity_charset charset,
 		unsigned char * str,
 		int str_len,
 		int * newpos,
@@ -503,205 +519,191 @@ inline static unsigned short get_next_char(enum entity_charset charset,
 	int pos = *newpos;
 	int mbpos = 0;
 	int mbspace = *mbseqlen;
-	unsigned short this_char = str[pos++];
+	unsigned int this_char = 0;
 	unsigned char next_char;
 
 	*status = SUCCESS;
-	
+
 	if (mbspace <= 0) {
 		*mbseqlen = 0;
-		return this_char;
+		CHECK_LEN(pos, 1);
+		*newpos = pos + 1;
+		return str[pos];
 	}
-	
-	MB_WRITE((unsigned char)this_char);
-	
+
 	switch (charset) {
 		case cs_utf_8:
 			{
-				unsigned long utf = 0;
-				int stat = 0;
-				int more = 1;
-
-				/* unpack utf-8 encoding into a wide char.
-				 * Code stolen from the mbstring extension */
-
-				do {
+				unsigned char c;
+				CHECK_LEN(pos, 1);
+				c = str[pos];
+				if (c < 0x80) {
+					MB_WRITE(c);
+					this_char = c;
+					pos++;
+				} else if (c < 0xc0) {
+					MB_FAILURE(pos);
+				} else if (c < 0xe0) {
+					CHECK_LEN(pos, 2);
+					if (str[pos + 1] < 0x80 || str[pos + 1] > 0xbf) {
+						MB_FAILURE(pos);
+					}
+					this_char = ((c & 0x1f) << 6) | (str[pos + 1] & 0x3f);
 					if (this_char < 0x80) {
-						more = 0;
-						if(stat) {
-							/* we didn't finish the UTF sequence correctly */
-							*status = FAILURE;
-						}
-						break;
-					} else if (this_char < 0xc0) {
-						switch (stat) {
-							case 0x10:	/* 2, 2nd */
-							case 0x21:	/* 3, 3rd */
-							case 0x32:	/* 4, 4th */
-							case 0x43:	/* 5, 5th */
-							case 0x54:	/* 6, 6th */
-								/* last byte in sequence */
-								more = 0;
-								utf |= (this_char & 0x3f);
-								this_char = (unsigned short)utf;
-								break;
-							case 0x20:	/* 3, 2nd */
-							case 0x31:	/* 4, 3rd */
-							case 0x42:	/* 5, 4th */
-							case 0x53:	/* 6, 5th */
-								/* penultimate char */
-								utf |= ((this_char & 0x3f) << 6);
-								stat++;
-								break;
-							case 0x30:	/* 4, 2nd */
-							case 0x41:	/* 5, 3rd */
-							case 0x52:	/* 6, 4th */
-								utf |= ((this_char & 0x3f) << 12);
-								stat++;
-								break;
-							case 0x40:	/* 5, 2nd */
-							case 0x51:
-								utf |= ((this_char & 0x3f) << 18);
-								stat++;
-								break;
-							case 0x50:	/* 6, 2nd */
-								utf |= ((this_char & 0x3f) << 24);
-								stat++;
-								break;
-							default:
-								/* invalid */
-								*status = FAILURE;
-								more = 0;
-						}
+						MB_FAILURE(pos);
 					}
-					/* lead byte */
-					else if (this_char < 0xe0) {
-						stat = 0x10;	/* 2 byte */
-						utf = (this_char & 0x1f) << 6;
-						CHECK_LEN(pos, 1);
-					} else if (this_char < 0xf0) {
-						stat = 0x20;	/* 3 byte */
-						utf = (this_char & 0xf) << 12;
-						CHECK_LEN(pos, 2);
-					} else if (this_char < 0xf8) {
-						stat = 0x30;	/* 4 byte */
-						utf = (this_char & 0x7) << 18;
-						CHECK_LEN(pos, 3);
-					} else if (this_char < 0xfc) {
-						stat = 0x40;	/* 5 byte */
-						utf = (this_char & 0x3) << 24;
-						CHECK_LEN(pos, 4);
-					} else if (this_char < 0xfe) {
-						stat = 0x50;	/* 6 byte */
-						utf = (this_char & 0x1) << 30;
-						CHECK_LEN(pos, 5);
-					} else {
-						/* invalid; bail */
-						more = 0;
-						*status = FAILURE;
-						break;
+					MB_WRITE((unsigned char)c);
+					MB_WRITE((unsigned char)str[pos + 1]);
+					pos += 2;
+				} else if (c < 0xf0) {
+					CHECK_LEN(pos, 3);
+					if (str[pos + 1] < 0x80 || str[pos + 1] > 0xbf) {
+						MB_FAILURE(pos);
 					}
-
-					if (more) {
-						this_char = str[pos++];
-						MB_WRITE((unsigned char)this_char);
+					if (str[pos + 2] < 0x80 || str[pos + 2] > 0xbf) {
+						MB_FAILURE(pos);
+					}
+					this_char = ((c & 0x0f) << 12) | ((str[pos + 1] & 0x3f) << 6) | (str[pos + 2] & 0x3f);
+					if (this_char < 0x800) {
+						MB_FAILURE(pos);
+					} else if (this_char >= 0xd800 && this_char <= 0xdfff) {
+						MB_FAILURE(pos);
+					}
+					MB_WRITE((unsigned char)c);
+					MB_WRITE((unsigned char)str[pos + 1]);
+					MB_WRITE((unsigned char)str[pos + 2]);
+					pos += 3;
+				} else if (c < 0xf8) {
+					CHECK_LEN(pos, 4);
+					if (str[pos + 1] < 0x80 || str[pos + 1] > 0xbf) {
+						MB_FAILURE(pos);
+					}
+					if (str[pos + 2] < 0x80 || str[pos + 2] > 0xbf) {
+						MB_FAILURE(pos);
 					}
-				} while (more);
+					if (str[pos + 3] < 0x80 || str[pos + 3] > 0xbf) {
+						MB_FAILURE(pos);
+					}
+					this_char = ((c & 0x07) << 18) | ((str[pos + 1] & 0x3f) << 12) | ((str[pos + 2] & 0x3f) << 6) | (str[pos + 3] & 0x3f);
+					if (this_char < 0x10000) {
+						MB_FAILURE(pos);
+					}
+					MB_WRITE((unsigned char)c);
+					MB_WRITE((unsigned char)str[pos + 1]);
+					MB_WRITE((unsigned char)str[pos + 2]);
+					MB_WRITE((unsigned char)str[pos + 3]);
+					pos += 4;
+				} else {
+					MB_FAILURE(pos);
+				}
 			}
 			break;
 		case cs_big5:
 		case cs_gb2312:
 		case cs_big5hkscs:
 			{
+				CHECK_LEN(pos, 1);
+				this_char = str[pos++];
 				/* check if this is the first of a 2-byte sequence */
-				if (this_char >= 0xa1 && this_char <= 0xfe) {
+				if (this_char >= 0x81 && this_char <= 0xfe) {
 					/* peek at the next char */
 					CHECK_LEN(pos, 1);
-					next_char = str[pos];
+					next_char = str[pos++];
 					if ((next_char >= 0x40 && next_char <= 0x7e) ||
 							(next_char >= 0xa1 && next_char <= 0xfe)) {
 						/* yes, this a wide char */
-						this_char <<= 8;
+						MB_WRITE(this_char);
 						MB_WRITE(next_char);
-						this_char |= next_char;
-						pos++;
+						this_char = (this_char << 8) | next_char;
+					} else {
+						MB_FAILURE(pos);
 					}
-					
+				} else {
+					MB_WRITE(this_char);
 				}
-				break;
 			}
+			break;
 		case cs_sjis:
 			{
+				CHECK_LEN(pos, 1);
+				this_char = str[pos++];
 				/* check if this is the first of a 2-byte sequence */
-				if ( (this_char >= 0x81 && this_char <= 0x9f) ||
-					 (this_char >= 0xe0 && this_char <= 0xef)
-					) {
+				if ((this_char >= 0x81 && this_char <= 0x9f) ||
+					(this_char >= 0xe0 && this_char <= 0xfc)) {
 					/* peek at the next char */
 					CHECK_LEN(pos, 1);
-					next_char = str[pos];
+					next_char = str[pos++];
 					if ((next_char >= 0x40 && next_char <= 0x7e) ||
 						(next_char >= 0x80 && next_char <= 0xfc))
 					{
 						/* yes, this a wide char */
-						this_char <<= 8;
+						MB_WRITE(this_char);
 						MB_WRITE(next_char);
-						this_char |= next_char;
-						pos++;
+						this_char = (this_char << 8) | next_char;
+					} else {
+						MB_FAILURE(pos);
 					}
-					
+				} else {
+					MB_WRITE(this_char);
 				}
 				break;
 			}
 		case cs_eucjp:
 			{
+				CHECK_LEN(pos, 1);
+				this_char = str[pos++];
 				/* check if this is the first of a multi-byte sequence */
 				if (this_char >= 0xa1 && this_char <= 0xfe) {
 					/* peek at the next char */
 					CHECK_LEN(pos, 1);
-					next_char = str[pos];
+					next_char = str[pos++];
 					if (next_char >= 0xa1 && next_char <= 0xfe) {
 						/* yes, this a jis kanji char */
-						this_char <<= 8;
+						MB_WRITE(this_char);
 						MB_WRITE(next_char);
-						this_char |= next_char;
-						pos++;
+						this_char = (this_char << 8) | next_char;
+					} else {
+						MB_FAILURE(pos);
 					}
-					
 				} else if (this_char == 0x8e) {
 					/* peek at the next char */
 					CHECK_LEN(pos, 1);
-					next_char = str[pos];
+					next_char = str[pos++];
 					if (next_char >= 0xa1 && next_char <= 0xdf) {
 						/* JIS X 0201 kana */
-						this_char <<= 8;
+						MB_WRITE(this_char);
 						MB_WRITE(next_char);
-						this_char |= next_char;
-						pos++;
+						this_char = (this_char << 8) | next_char;
+					} else {
+						MB_FAILURE(pos);
 					}
-					
 				} else if (this_char == 0x8f) {
 					/* peek at the next two char */
 					unsigned char next2_char;
 					CHECK_LEN(pos, 2);
 					next_char = str[pos];
-					next2_char = str[pos+1];
+					next2_char = str[pos + 1];
+					pos += 2;
 					if ((next_char >= 0xa1 && next_char <= 0xfe) &&
 						(next2_char >= 0xa1 && next2_char <= 0xfe)) {
 						/* JIS X 0212 hojo-kanji */
-						this_char <<= 8;
+						MB_WRITE(this_char);
 						MB_WRITE(next_char);
-						this_char |= next_char;
-						pos++;
-						this_char <<= 8;
 						MB_WRITE(next2_char);
-						this_char |= next2_char;
-						pos++;
+						this_char = (this_char << 16) | (next_char << 8) | next2_char;
+					} else {
+						MB_FAILURE(pos);
 					}
-					
+				} else {
+					MB_WRITE(this_char);
 				}
 				break;
 			}
 		default:
+			/* single-byte charsets */
+			CHECK_LEN(pos, 1);
+			this_char = str[pos++];
+			MB_WRITE(this_char);
 			break;
 	}
 	MB_RETURN;
@@ -1132,7 +1134,7 @@ PHPAPI char *php_escape_html_entities_ex(unsigned char *old, int oldlen, int *ne
 		unsigned char mbsequence[16];	/* allow up to 15 characters in a multibyte sequence */
 		int mbseqlen = sizeof(mbsequence);
 		int status = SUCCESS;
-		unsigned short this_char = get_next_char(charset, old, oldlen, &i, mbsequence, &mbseqlen, &status);
+		unsigned int this_char = get_next_char(charset, old, oldlen, &i, mbsequence, &mbseqlen, &status);
 
 		if(status == FAILURE) {
 			/* invalid MB sequence */
diff --git a/ext/standard/pageinfo.c b/ext/standard/pageinfo.c
index b77ff7a..b047ed1 100644
--- a/ext/standard/pageinfo.c
+++ b/ext/standard/pageinfo.c
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: pageinfo.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: pageinfo.c 290179 2009-11-03 18:03:02Z guenter $ */
 
 #include "php.h"
 #include "pageinfo.h"
@@ -68,11 +68,7 @@ PHPAPI void php_statpage(TSRMLS_D)
 			BG(page_uid)   = pstat->st_uid;
 			BG(page_gid)   = pstat->st_gid;
 			BG(page_inode) = pstat->st_ino;
-#ifdef NETWARE
-			BG(page_mtime) = (pstat->st_mtime).tv_sec;
-#else
 			BG(page_mtime) = pstat->st_mtime;
-#endif
 		} else { /* handler for situations where there is no source file, ex. php -r */
 			BG(page_uid) = getuid();
 			BG(page_gid) = getgid();
diff --git a/ext/standard/strnatcmp.c b/ext/standard/strnatcmp.c
index 9a3b4e7..e1c6960 100644
--- a/ext/standard/strnatcmp.c
+++ b/ext/standard/strnatcmp.c
@@ -38,7 +38,7 @@
 
 #if 0
 static char const *version UNUSED =
-    "$Id: strnatcmp.c 286930 2009-08-08 14:39:34Z rasmus $";
+    "$Id: strnatcmp.c 288896 2009-09-28 13:29:53Z rasmus $";
 #endif
 /* {{{ compare_right
  */
@@ -116,12 +116,12 @@ PHPAPI int strnatcmp_ex(char const *a, size_t a_len, char const *b, size_t b_len
 	while (1) {
 		ca = *ap; cb = *bp;
 
-		/* skip over leading zeros unless they are followed by punctuation */
-		while (leading && ca == '0' && (ap+1 < aend) && !ispunct(*(ap+1))) {
+		/* skip over leading zeros */
+		while (leading && ca == '0' && (ap+1 < aend) && isdigit(*(ap+1))) {
 			ca = *++ap;
 		}
 
-		while (leading && cb == '0' && (bp+1 < bend) && !ispunct(*(bp+1))) {
+		while (leading && cb == '0' && (bp+1 < bend) && isdigit(*(bp+1))) {
 			cb = *++bp;
 		}
 
diff --git a/ext/standard/tests/array/bug50006.phpt b/ext/standard/tests/array/bug50006.phpt
new file mode 100644
index 0000000..f03a002
--- /dev/null
+++ b/ext/standard/tests/array/bug50006.phpt
@@ -0,0 +1,29 @@
+--TEST--
+Bug #50006 (Segfault caused by uksort())
+--FILE--
+<?php
+
+$data = array(
+    'bar-bazbazbaz.' => 0,
+    'bar-bazbazbaz-' => 0,
+    'foo' => 0,
+);
+uksort($data, 'magic_sort_cmp');
+print_r($data);
+
+function magic_sort_cmp($a, $b) {
+  $a = substr($a, 1);
+  $b = substr($b, 1);
+  if (!$a) return $b ? -1 : 0;
+  if (!$b) return 1;
+  return magic_sort_cmp($a, $b);
+}
+
+?>
+--EXPECTF--
+Array
+(
+    [foo] => 0
+    [bar-bazbazbaz-] => 0
+    [bar-bazbazbaz.] => 0
+)
diff --git a/ext/standard/tests/array/bug50006_1.phpt b/ext/standard/tests/array/bug50006_1.phpt
new file mode 100644
index 0000000..fbb7ddd
--- /dev/null
+++ b/ext/standard/tests/array/bug50006_1.phpt
@@ -0,0 +1,29 @@
+--TEST--
+Bug #50006 (Segfault caused by uksort()) - usort variant
+--FILE--
+<?php
+
+$data = array(
+    'bar-bazbazbaz.',
+    'bar-bazbazbaz-', 
+    'foo'
+);
+usort($data, 'magic_sort_cmp');
+print_r($data);
+
+function magic_sort_cmp($a, $b) {
+  $a = substr($a, 1);
+  $b = substr($b, 1);
+  if (!$a) return $b ? -1 : 0;
+  if (!$b) return 1;
+  return magic_sort_cmp($a, $b);
+}
+
+?>
+--EXPECTF--
+Array
+(
+    [0] => foo
+    [1] => bar-bazbazbaz-
+    [2] => bar-bazbazbaz.
+)
diff --git a/ext/standard/tests/array/bug50006_2.phpt b/ext/standard/tests/array/bug50006_2.phpt
new file mode 100644
index 0000000..19c0d14
--- /dev/null
+++ b/ext/standard/tests/array/bug50006_2.phpt
@@ -0,0 +1,29 @@
+--TEST--
+Bug #50006 (Segfault caused by uksort()) - uasort variant
+--FILE--
+<?php
+
+$data = array(
+    'bar-bazbazbaz.',
+    'bar-bazbazbaz-', 
+    'foo'
+);
+uasort($data, 'magic_sort_cmp');
+print_r($data);
+
+function magic_sort_cmp($a, $b) {
+  $a = substr($a, 1);
+  $b = substr($b, 1);
+  if (!$a) return $b ? -1 : 0;
+  if (!$b) return 1;
+  return magic_sort_cmp($a, $b);
+}
+
+?>
+--EXPECTF--
+Array
+(
+    [2] => foo
+    [1] => bar-bazbazbaz-
+    [0] => bar-bazbazbaz.
+)
diff --git a/ext/standard/tests/bug49244.phpt b/ext/standard/tests/bug49244.phpt
new file mode 100644
index 0000000..1ba24fb
--- /dev/null
+++ b/ext/standard/tests/bug49244.phpt
@@ -0,0 +1,32 @@
+--TEST--
+Bug #49244 (Floating point NaN cause garbage characters)
+--FILE--
+<?php
+
+for ($i = 0; $i < 10; $i++) {
+	printf("{%f} %1\$f\n", pow(-1.0, 0.3));
+	printf(b"{%f} %1\$f\n", pow(-1.0, 0.3));
+}
+
+?>
+--EXPECT--
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
+{NaN} NaN
diff --git a/ext/standard/tests/file/bug26615.phpt b/ext/standard/tests/file/bug26615.phpt
index 9fee92a..3689fdf 100644
--- a/ext/standard/tests/file/bug26615.phpt
+++ b/ext/standard/tests/file/bug26615.phpt
@@ -1,6 +1,6 @@
 --TEST--
 Bug #26615 (exec crash on long input lines)
---INI---
+--INI--
 variables_order=E
 --FILE--
 <?php
diff --git a/ext/standard/tests/general_functions/bug49692.ini b/ext/standard/tests/general_functions/bug49692.ini
new file mode 100644
index 0000000..5def69a
--- /dev/null
+++ b/ext/standard/tests/general_functions/bug49692.ini
@@ -0,0 +1,4 @@
+//my.ini file
+[sitemap]
+/home    = default:index
+/info    = default:info
diff --git a/ext/standard/tests/general_functions/bug49692.phpt b/ext/standard/tests/general_functions/bug49692.phpt
new file mode 100644
index 0000000..80a1612
--- /dev/null
+++ b/ext/standard/tests/general_functions/bug49692.phpt
@@ -0,0 +1,20 @@
+--TEST--
+Bug #49692: parse_ini_file() throws errors when key contains '/' (forward slash)
+--CREDITS--
+Rafael Dohms <rdohms [at] gmail [dot] com>
+--FILE--
+<?php
+
+var_dump(parse_ini_file('bug49692.ini', true));
+
+?>
+--EXPECTF--
+array(1) {
+  ["sitemap"]=>
+  array(2) {
+    ["/home"]=>
+    string(13) "default:index"
+    ["/info"]=>
+    string(12) "default:info"
+  }
+}
diff --git a/ext/standard/tests/general_functions/import_request.phpt b/ext/standard/tests/general_functions/import_request.phpt
index d9f43e9..e5aceb6 100644
--- a/ext/standard/tests/general_functions/import_request.phpt
+++ b/ext/standard/tests/general_functions/import_request.phpt
@@ -32,24 +32,24 @@ Warning: Wrong parameter count for import_request_variables() in %s on line %d
 NULL
 
 Notice: import_request_variables(): No prefix specified - possible security hazard in %s on line %d
-NULL
+bool(false)
 
 Notice: import_request_variables(): No prefix specified - possible security hazard in %s on line %d
-NULL
+bool(false)
 
 Notice: import_request_variables(): No prefix specified - possible security hazard in %s on line %d
 
 Warning: import_request_variables(): Attempted GLOBALS variable overwrite in %s on line %d
 
 Warning: import_request_variables(): Numeric key detected - possible security hazard in %s on line %d
-NULL
+bool(true)
 
 Notice: Undefined variable: ap in %s on line %d
 string(1) "1"
 string(3) "heh"
 string(1) "3"
 NULL
-NULL
+bool(true)
 
 Notice: Undefined variable: g_ap in %s on line %d
 string(1) "1"
@@ -57,7 +57,7 @@ string(3) "heh"
 string(1) "3"
 NULL
 string(2) "hm"
-NULL
+bool(true)
 string(1) "1"
 string(3) "heh"
 string(1) "3"
@@ -68,7 +68,7 @@ array(1) {
   [0]=>
   string(2) "ar"
 }
-NULL
+bool(true)
 
 Notice: Undefined variable: r_ap in %s on line %d
 string(1) "1"
diff --git a/ext/standard/tests/general_functions/is_callable_basic1.phpt b/ext/standard/tests/general_functions/is_callable_basic1.phpt
index e836d73..fe4d6e2 100644
--- a/ext/standard/tests/general_functions/is_callable_basic1.phpt
+++ b/ext/standard/tests/general_functions/is_callable_basic1.phpt
@@ -64,7 +64,7 @@ check_iscallable($defined_functions);
 
 ?>
 ===DONE===
---EXPECT---
+--EXPECT--
 *** Testing is_callable() on defined functions ***
 -- Iteration  1 --
 bool(true)
@@ -106,4 +106,4 @@ Hello_World
 bool(true)
 bool(true)
 Hello_World
-===DONE===
\ No newline at end of file
+===DONE===
diff --git a/ext/standard/tests/general_functions/proc_nice_variation5.phpt b/ext/standard/tests/general_functions/proc_nice_variation5.phpt
index d832510..efce8cf 100644
--- a/ext/standard/tests/general_functions/proc_nice_variation5.phpt
+++ b/ext/standard/tests/general_functions/proc_nice_variation5.phpt
@@ -5,6 +5,10 @@ Italian PHP TestFest 2009 Cesena 19-20-21 june
 Fabio Fabbrucci (fabbrucci at grupporetina.com)
 Michele Orselli (mo at ideato.it)
 Simone Gentili (sensorario at gmail.com)
+--SKIPIF--
+<?php
+        if(posix_geteuid() == 0) print "skip - Cannot run test as root.";
+?>
 --FILE--
 <?php
 
diff --git a/ext/standard/tests/general_functions/sunfuncts.phpt b/ext/standard/tests/general_functions/sunfuncts.phpt
deleted file mode 100644
index 4d95c59..0000000
--- a/ext/standard/tests/general_functions/sunfuncts.phpt
+++ /dev/null
@@ -1,44 +0,0 @@
---TEST--
-date_sunrise() and date_sunset() functions
---INI--
-precision=13
---FILE--
-<?php
-
-putenv ("TZ=Asia/Jerusalem");
-
-for($a=1;$a<=12;$a++){
-	echo date_sunrise(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_TIMESTAMP,31.76670,35.23330,90.83,2)." ";
-	echo date_sunrise(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_STRING,31.76670,35.23330,90.83,2)." ";
-	echo date_sunrise(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_DOUBLE,31.76670,35.23330,90.83,2)."\n";
-	
-	echo date_sunset(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_TIMESTAMP,31.76670,35.23330,90.83,2)." ";
-	echo date_sunset(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_STRING,31.76670,35.23330,90.83,2)." ";
-	echo date_sunset(mktime(1,1,1,$a,1,2003),SUNFUNCS_RET_DOUBLE,31.76670,35.23330,90.83,2)."\n";
-}
-?>
---EXPECTF--
-1041395864 06:37 6.6290131458%d
-1041432452 16:47 16.792451114%d
-1044073855 06:30 6.5154089279%d
-1044112463 17:14 17.239870289%d
-1046491495 06:04 6.0822145033%d
-1046533075 17:37 17.632011035%d
-1049167581 05:26 5.4394438111%d
-1049212774 17:59 17.993035729%d
-1051757532 04:52 4.8701934126%d
-1051806007 18:20 18.335390508%d
-1054434776 04:32 4.5489827182%d
-1054485647 18:40 18.679812949%d
-1057026949 04:35 4.5971956372%d
-1057078197 18:49 18.832563396%d
-1059706409 04:53 4.8916575089%d
-1059755837 18:37 18.621440704%d
-1062385999 05:13 5.2220951121%d
-1062432291 18:04 18.080957168%d
-1064979098 05:31 5.5273199215%d
-1065021952 17:25 17.431339135%d
-1067658845 05:54 5.9016292870%d
-1067698274 16:51 16.853902453%d
-1070252387 06:19 6.3299242689%d
-1070289382 16:36 16.606312600%d
diff --git a/ext/standard/tests/mail/mail_basic2.phpt b/ext/standard/tests/mail/mail_basic2.phpt
index 8f9ef64..f5d9857 100644
--- a/ext/standard/tests/mail/mail_basic2.phpt
+++ b/ext/standard/tests/mail/mail_basic2.phpt
@@ -6,7 +6,7 @@ if(substr(PHP_OS, 0, 3) == "WIN")
   die("skip Won't run on Windows");
 ?>
 --INI--
-sendmail_path="echo --- > /tmp/php_test_mailBasic2.out"
+sendmail_path="sed > /tmp/php_test_mailBasic2.out"
 --FILE--
 <?php
 /* Prototype  : int mail(string to, string subject, string message [, string additional_headers [, string additional_parameters]])
@@ -23,7 +23,7 @@ $to = 'user at company.com';
 $subject = 'Test Subject';
 $message = 'A Message';
 $additional_headers = 'KHeaders';
-$additional_parameters = "Extras";
+$additional_parameters = "-e '5 a--- Extras'";
 $outFile = "/tmp/php_test_mailBasic2.out";
 @unlink($outFile);
 
@@ -31,11 +31,6 @@ echo "-- extra parameters --\n";
 // Calling mail() with all possible arguments
 var_dump( mail($to, $subject, $message, $additional_headers, $additional_parameters) );
 
-//This test is just using a shell command (see the INI setting). The sleep()
-//is used because that can take a while. If you see the test failing sometimes try 
-//increasing the length of the sleep. 
-
-sleep(5);
 echo file_get_contents($outFile);
 unlink($outFile);
 ?>
@@ -44,5 +39,10 @@ unlink($outFile);
 *** Testing mail() : basic functionality ***
 -- extra parameters --
 bool(true)
+To: user at company.com
+Subject: Test Subject
+KHeaders
+
+A Message
 --- Extras
 ===DONE===
diff --git a/ext/standard/tests/mail/mail_variation2.phpt b/ext/standard/tests/mail/mail_variation2.phpt
index 59ef1d9..736b05f 100644
--- a/ext/standard/tests/mail/mail_variation2.phpt
+++ b/ext/standard/tests/mail/mail_variation2.phpt
@@ -1,8 +1,8 @@
 --TEST--
 Test mail() function : variation force extra parameters
 --INI--
-sendmail_path="echo --- > /tmp/php_test_mailVariation2.out"
-mail.force_extra_parameters="forced params"
+sendmail_path="sed > /tmp/php_test_mailVariation2.out"
+mail.force_extra_parameters="-e4a---forced-params"
 --SKIPIF--
 <?php
 if(substr(PHP_OS, 0, 3) == "WIN")
@@ -35,5 +35,9 @@ unlink($outFile);
 --EXPECT--
 *** Testing mail() : basic functionality ***
 bool(true)
---- forced params
+To: user at company.com
+Subject: Test Subject
+
+A Message
+---forced-params
 ===DONE===
diff --git a/ext/standard/tests/strings/bug49785.phpt b/ext/standard/tests/strings/bug49785.phpt
new file mode 100644
index 0000000..3f60e9f
--- /dev/null
+++ b/ext/standard/tests/strings/bug49785.phpt
@@ -0,0 +1,4114 @@
+--TEST--
+Bug #49785 (insufficient input string validation of htmlspecialchars())
+--FILE--
+<?php
+function _bin2hex($val) {
+    return is_string($val) ? bin2hex($val): $val;
+}
+
+// UTF-8: basic tests
+var_dump(_bin2hex(htmlentities("\xc1\xbf", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xc2\x80", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xc2\x00", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xc2\xc0", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xce\x91", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xce\xb1", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xdf\xbf", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xe0\xa0\x80", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xe0\x9f\xbf", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xe0\x9f\xbf", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xe0\x1f\xbf", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xe0\x9f\x3f", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xe0\x1f\x3f", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xe2\x99\xa5", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xef\xbf\xbf", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xef\xff\xbf", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xef\xbf\xff", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xf0\x8f\xbf\xbf", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xf0\x90\x80\x80", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xf7\xbf\xbf\xbf", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xf7\x3f\xbf\xbf", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xf7\xbf\x3f\xbf", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xf7\xbf\xbf\x3f", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xf7\xff\xbf\xbf", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xf7\xbf\xff\xbf", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xf7\xbf\xbf\xff", ENT_QUOTES, "UTF-8")));
+var_dump(_bin2hex(htmlentities("\xf8\x88\x80\x80\x80", ENT_QUOTES, "UTF-8")));
+
+echo "--\n";
+// UTF-8: alternative (invalid) UTF-8 sequence / surrogate pairs
+var_dump(_bin2hex(htmlspecialchars("\xc0\xa6", ENT_QUOTES, 'UTF-8')));
+var_dump(_bin2hex(htmlspecialchars("\xe0\x80\xa6", ENT_QUOTES, 'UTF-8')));
+var_dump(_bin2hex(htmlspecialchars("\xf0\x80\x80\xa6", ENT_QUOTES, 'UTF-8')));
+var_dump(_bin2hex(htmlspecialchars("\xec\xbf\xbf", ENT_QUOTES, 'UTF-8')));
+var_dump(_bin2hex(htmlspecialchars("\xed\xa0\x80", ENT_QUOTES, 'UTF-8')));
+var_dump(_bin2hex(htmlspecialchars("\xed\xbf\xbf", ENT_QUOTES, 'UTF-8')));
+var_dump(_bin2hex(htmlspecialchars("\xee\x80\x80", ENT_QUOTES, 'UTF-8')));
+
+// Shift_JIS: non-lead byte >= 0x80
+var_dump(_bin2hex(htmlspecialchars("\x80", ENT_QUOTES, 'Shift_JIS')));
+foreach (array_map('chr', range(0xa0, 0xdf)) as $c) {
+    var_dump(_bin2hex(htmlspecialchars($c, ENT_QUOTES, 'Shift_JIS')));
+}
+var_dump(_bin2hex(htmlspecialchars("\xfd", ENT_QUOTES, 'Shift_JIS')));
+var_dump(_bin2hex(htmlspecialchars("\xfe", ENT_QUOTES, 'Shift_JIS')));
+var_dump(_bin2hex(htmlspecialchars("\xff", ENT_QUOTES, 'Shift_JIS')));
+
+echo "--\n";
+// Shift_JIS: incomplete / invalid multibyte sequences
+foreach (array_map('chr', array_merge(range(0x81, 0x9f), range(0xe0, 0xfc))) as $c) {
+    var_dump(_bin2hex(htmlspecialchars("$c", ENT_QUOTES, 'Shift_JIS')));
+    var_dump(_bin2hex(htmlspecialchars("$c\x3f", ENT_QUOTES, 'Shift_JIS')));
+    var_dump(_bin2hex(htmlspecialchars("$c\x40", ENT_QUOTES, 'Shift_JIS')));
+    var_dump(_bin2hex(htmlspecialchars("$c\x7e", ENT_QUOTES, 'Shift_JIS')));
+    var_dump(_bin2hex(htmlspecialchars("$c\x7f", ENT_QUOTES, 'Shift_JIS')));
+    var_dump(_bin2hex(htmlspecialchars("$c\x80", ENT_QUOTES, 'Shift_JIS')));
+    var_dump(_bin2hex(htmlspecialchars("$c\xfc", ENT_QUOTES, 'Shift_JIS')));
+    var_dump(_bin2hex(htmlspecialchars("$c\xfd", ENT_QUOTES, 'Shift_JIS')));
+    var_dump(_bin2hex(htmlspecialchars("$c\xfe", ENT_QUOTES, 'Shift_JIS')));
+    var_dump(_bin2hex(htmlspecialchars("$c\xff", ENT_QUOTES, 'Shift_JIS')));
+}
+
+echo "--\n";
+// EUC-JP: non-lead byte >= 0x80
+foreach (array_map('chr', array_merge(range(0x80, 0x8d), range(0x90, 0x9f))) as $c) {
+    var_dump(_bin2hex(htmlspecialchars($c, ENT_QUOTES, 'EUC-JP')));
+}
+var_dump(_bin2hex(htmlspecialchars("\xff", ENT_QUOTES, 'EUC-JP')));
+
+// EUC-JP: control codes that are virtually lead bytes
+var_dump(_bin2hex(htmlspecialchars("\x8e", ENT_QUOTES, 'EUC-JP')));
+var_dump(_bin2hex(htmlspecialchars("\x8f", ENT_QUOTES, 'EUC-JP')));
+var_dump(_bin2hex(htmlspecialchars("\x8e\xa1", ENT_QUOTES, 'EUC-JP')));
+var_dump(_bin2hex(htmlspecialchars("\x8f\xa1", ENT_QUOTES, 'EUC-JP')));
+var_dump(_bin2hex(htmlspecialchars("\x8e\xa1\xa3", ENT_QUOTES, 'EUC-JP')));
+var_dump(_bin2hex(htmlspecialchars("\x8f\xa1\xa3", ENT_QUOTES, 'EUC-JP')));
+
+echo "--\n";
+// EUC-JP: incomplete / invalid multibyte sequences
+foreach (array_map('chr', array_merge(range(0xa1, 0xfe))) as $c) {
+    var_dump(_bin2hex(htmlspecialchars("$c", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("$c\x26", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("$c\x80", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("$c\xa0", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("$c\xa1", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("$c\xfe", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("$c\xff", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("\x8e$c", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("\x8e$c\x26", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("\x8e$c\x80", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("\x8e$c\xa0", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("\x8e$c\xa1", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("\x8e$c\xfe", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("\x8e$c\xff", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("\x8f$c", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("\x8f$c\x26", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("\x8f$c\x80", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("\x8f$c\xa0", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("\x8f$c\xa1", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("\x8f$c\xfe", ENT_QUOTES, 'EUC-JP')));
+    var_dump(_bin2hex(htmlspecialchars("\x8f$c\xff", ENT_QUOTES, 'EUC-JP')));
+}
+
+echo "--\n";
+// BIG5: non-lead byte >= 0x80
+var_dump(_bin2hex(htmlspecialchars("\x80", ENT_QUOTES, 'BIG5')));
+var_dump(_bin2hex(htmlspecialchars("\xff", ENT_QUOTES, 'BIG5')));
+
+echo "--\n";
+// BIG5: incomplete / invalid multibyte sequences
+foreach (array_map('chr', range(0x81, 0xfe)) as $c) {
+    var_dump(_bin2hex(htmlspecialchars("$c", ENT_QUOTES, 'BIG5')));
+    var_dump(_bin2hex(htmlspecialchars("$c\x3f", ENT_QUOTES, 'BIG5')));
+    var_dump(_bin2hex(htmlspecialchars("$c\x40", ENT_QUOTES, 'BIG5')));
+    var_dump(_bin2hex(htmlspecialchars("$c\x7e", ENT_QUOTES, 'BIG5')));
+    var_dump(_bin2hex(htmlspecialchars("$c\x7f", ENT_QUOTES, 'BIG5')));
+    var_dump(_bin2hex(htmlspecialchars("$c\x80", ENT_QUOTES, 'BIG5')));
+    var_dump(_bin2hex(htmlspecialchars("$c\xa0", ENT_QUOTES, 'BIG5')));
+    var_dump(_bin2hex(htmlspecialchars("$c\xa1", ENT_QUOTES, 'BIG5')));
+    var_dump(_bin2hex(htmlspecialchars("$c\xfe", ENT_QUOTES, 'BIG5')));
+    var_dump(_bin2hex(htmlspecialchars("$c\xff", ENT_QUOTES, 'BIG5')));
+}
+?>
+--EXPECT--
+string(0) ""
+string(4) "c280"
+string(0) ""
+string(0) ""
+string(14) "26416c7068613b"
+string(14) "26616c7068613b"
+string(4) "dfbf"
+string(6) "e0a080"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(16) "266865617274733b"
+string(6) "efbfbf"
+string(0) ""
+string(0) ""
+string(0) ""
+string(8) "f0908080"
+string(8) "f7bfbfbf"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+--
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "ecbfbf"
+string(0) ""
+string(0) ""
+string(6) "ee8080"
+string(2) "80"
+string(2) "a0"
+string(2) "a1"
+string(2) "a2"
+string(2) "a3"
+string(2) "a4"
+string(2) "a5"
+string(2) "a6"
+string(2) "a7"
+string(2) "a8"
+string(2) "a9"
+string(2) "aa"
+string(2) "ab"
+string(2) "ac"
+string(2) "ad"
+string(2) "ae"
+string(2) "af"
+string(2) "b0"
+string(2) "b1"
+string(2) "b2"
+string(2) "b3"
+string(2) "b4"
+string(2) "b5"
+string(2) "b6"
+string(2) "b7"
+string(2) "b8"
+string(2) "b9"
+string(2) "ba"
+string(2) "bb"
+string(2) "bc"
+string(2) "bd"
+string(2) "be"
+string(2) "bf"
+string(2) "c0"
+string(2) "c1"
+string(2) "c2"
+string(2) "c3"
+string(2) "c4"
+string(2) "c5"
+string(2) "c6"
+string(2) "c7"
+string(2) "c8"
+string(2) "c9"
+string(2) "ca"
+string(2) "cb"
+string(2) "cc"
+string(2) "cd"
+string(2) "ce"
+string(2) "cf"
+string(2) "d0"
+string(2) "d1"
+string(2) "d2"
+string(2) "d3"
+string(2) "d4"
+string(2) "d5"
+string(2) "d6"
+string(2) "d7"
+string(2) "d8"
+string(2) "d9"
+string(2) "da"
+string(2) "db"
+string(2) "dc"
+string(2) "dd"
+string(2) "de"
+string(2) "df"
+string(2) "fd"
+string(2) "fe"
+string(2) "ff"
+--
+string(0) ""
+string(0) ""
+string(4) "8140"
+string(4) "817e"
+string(0) ""
+string(4) "8180"
+string(4) "81fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8240"
+string(4) "827e"
+string(0) ""
+string(4) "8280"
+string(4) "82fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8340"
+string(4) "837e"
+string(0) ""
+string(4) "8380"
+string(4) "83fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8440"
+string(4) "847e"
+string(0) ""
+string(4) "8480"
+string(4) "84fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8540"
+string(4) "857e"
+string(0) ""
+string(4) "8580"
+string(4) "85fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8640"
+string(4) "867e"
+string(0) ""
+string(4) "8680"
+string(4) "86fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8740"
+string(4) "877e"
+string(0) ""
+string(4) "8780"
+string(4) "87fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8840"
+string(4) "887e"
+string(0) ""
+string(4) "8880"
+string(4) "88fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8940"
+string(4) "897e"
+string(0) ""
+string(4) "8980"
+string(4) "89fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8a40"
+string(4) "8a7e"
+string(0) ""
+string(4) "8a80"
+string(4) "8afc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8b40"
+string(4) "8b7e"
+string(0) ""
+string(4) "8b80"
+string(4) "8bfc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8c40"
+string(4) "8c7e"
+string(0) ""
+string(4) "8c80"
+string(4) "8cfc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8d40"
+string(4) "8d7e"
+string(0) ""
+string(4) "8d80"
+string(4) "8dfc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8e40"
+string(4) "8e7e"
+string(0) ""
+string(4) "8e80"
+string(4) "8efc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8f40"
+string(4) "8f7e"
+string(0) ""
+string(4) "8f80"
+string(4) "8ffc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9040"
+string(4) "907e"
+string(0) ""
+string(4) "9080"
+string(4) "90fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9140"
+string(4) "917e"
+string(0) ""
+string(4) "9180"
+string(4) "91fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9240"
+string(4) "927e"
+string(0) ""
+string(4) "9280"
+string(4) "92fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9340"
+string(4) "937e"
+string(0) ""
+string(4) "9380"
+string(4) "93fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9440"
+string(4) "947e"
+string(0) ""
+string(4) "9480"
+string(4) "94fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9540"
+string(4) "957e"
+string(0) ""
+string(4) "9580"
+string(4) "95fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9640"
+string(4) "967e"
+string(0) ""
+string(4) "9680"
+string(4) "96fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9740"
+string(4) "977e"
+string(0) ""
+string(4) "9780"
+string(4) "97fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9840"
+string(4) "987e"
+string(0) ""
+string(4) "9880"
+string(4) "98fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9940"
+string(4) "997e"
+string(0) ""
+string(4) "9980"
+string(4) "99fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9a40"
+string(4) "9a7e"
+string(0) ""
+string(4) "9a80"
+string(4) "9afc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9b40"
+string(4) "9b7e"
+string(0) ""
+string(4) "9b80"
+string(4) "9bfc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9c40"
+string(4) "9c7e"
+string(0) ""
+string(4) "9c80"
+string(4) "9cfc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9d40"
+string(4) "9d7e"
+string(0) ""
+string(4) "9d80"
+string(4) "9dfc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9e40"
+string(4) "9e7e"
+string(0) ""
+string(4) "9e80"
+string(4) "9efc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9f40"
+string(4) "9f7e"
+string(0) ""
+string(4) "9f80"
+string(4) "9ffc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e040"
+string(4) "e07e"
+string(0) ""
+string(4) "e080"
+string(4) "e0fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e140"
+string(4) "e17e"
+string(0) ""
+string(4) "e180"
+string(4) "e1fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e240"
+string(4) "e27e"
+string(0) ""
+string(4) "e280"
+string(4) "e2fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e340"
+string(4) "e37e"
+string(0) ""
+string(4) "e380"
+string(4) "e3fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e440"
+string(4) "e47e"
+string(0) ""
+string(4) "e480"
+string(4) "e4fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e540"
+string(4) "e57e"
+string(0) ""
+string(4) "e580"
+string(4) "e5fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e640"
+string(4) "e67e"
+string(0) ""
+string(4) "e680"
+string(4) "e6fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e740"
+string(4) "e77e"
+string(0) ""
+string(4) "e780"
+string(4) "e7fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e840"
+string(4) "e87e"
+string(0) ""
+string(4) "e880"
+string(4) "e8fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e940"
+string(4) "e97e"
+string(0) ""
+string(4) "e980"
+string(4) "e9fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ea40"
+string(4) "ea7e"
+string(0) ""
+string(4) "ea80"
+string(4) "eafc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "eb40"
+string(4) "eb7e"
+string(0) ""
+string(4) "eb80"
+string(4) "ebfc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ec40"
+string(4) "ec7e"
+string(0) ""
+string(4) "ec80"
+string(4) "ecfc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ed40"
+string(4) "ed7e"
+string(0) ""
+string(4) "ed80"
+string(4) "edfc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ee40"
+string(4) "ee7e"
+string(0) ""
+string(4) "ee80"
+string(4) "eefc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ef40"
+string(4) "ef7e"
+string(0) ""
+string(4) "ef80"
+string(4) "effc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f040"
+string(4) "f07e"
+string(0) ""
+string(4) "f080"
+string(4) "f0fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f140"
+string(4) "f17e"
+string(0) ""
+string(4) "f180"
+string(4) "f1fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f240"
+string(4) "f27e"
+string(0) ""
+string(4) "f280"
+string(4) "f2fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f340"
+string(4) "f37e"
+string(0) ""
+string(4) "f380"
+string(4) "f3fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f440"
+string(4) "f47e"
+string(0) ""
+string(4) "f480"
+string(4) "f4fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f540"
+string(4) "f57e"
+string(0) ""
+string(4) "f580"
+string(4) "f5fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f640"
+string(4) "f67e"
+string(0) ""
+string(4) "f680"
+string(4) "f6fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f740"
+string(4) "f77e"
+string(0) ""
+string(4) "f780"
+string(4) "f7fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f840"
+string(4) "f87e"
+string(0) ""
+string(4) "f880"
+string(4) "f8fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f940"
+string(4) "f97e"
+string(0) ""
+string(4) "f980"
+string(4) "f9fc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fa40"
+string(4) "fa7e"
+string(0) ""
+string(4) "fa80"
+string(4) "fafc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fb40"
+string(4) "fb7e"
+string(0) ""
+string(4) "fb80"
+string(4) "fbfc"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fc40"
+string(4) "fc7e"
+string(0) ""
+string(4) "fc80"
+string(4) "fcfc"
+string(0) ""
+string(0) ""
+string(0) ""
+--
+string(2) "80"
+string(2) "81"
+string(2) "82"
+string(2) "83"
+string(2) "84"
+string(2) "85"
+string(2) "86"
+string(2) "87"
+string(2) "88"
+string(2) "89"
+string(2) "8a"
+string(2) "8b"
+string(2) "8c"
+string(2) "8d"
+string(2) "90"
+string(2) "91"
+string(2) "92"
+string(2) "93"
+string(2) "94"
+string(2) "95"
+string(2) "96"
+string(2) "97"
+string(2) "98"
+string(2) "99"
+string(2) "9a"
+string(2) "9b"
+string(2) "9c"
+string(2) "9d"
+string(2) "9e"
+string(2) "9f"
+string(2) "ff"
+string(0) ""
+string(0) ""
+string(4) "8ea1"
+string(0) ""
+string(0) ""
+string(6) "8fa1a3"
+--
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a1a1"
+string(4) "a1fe"
+string(0) ""
+string(4) "8ea1"
+string(14) "8ea126616d703b"
+string(6) "8ea180"
+string(6) "8ea1a0"
+string(0) ""
+string(0) ""
+string(6) "8ea1ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fa1a1"
+string(6) "8fa1fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a2a1"
+string(4) "a2fe"
+string(0) ""
+string(4) "8ea2"
+string(14) "8ea226616d703b"
+string(6) "8ea280"
+string(6) "8ea2a0"
+string(0) ""
+string(0) ""
+string(6) "8ea2ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fa2a1"
+string(6) "8fa2fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a3a1"
+string(4) "a3fe"
+string(0) ""
+string(4) "8ea3"
+string(14) "8ea326616d703b"
+string(6) "8ea380"
+string(6) "8ea3a0"
+string(0) ""
+string(0) ""
+string(6) "8ea3ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fa3a1"
+string(6) "8fa3fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a4a1"
+string(4) "a4fe"
+string(0) ""
+string(4) "8ea4"
+string(14) "8ea426616d703b"
+string(6) "8ea480"
+string(6) "8ea4a0"
+string(0) ""
+string(0) ""
+string(6) "8ea4ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fa4a1"
+string(6) "8fa4fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a5a1"
+string(4) "a5fe"
+string(0) ""
+string(4) "8ea5"
+string(14) "8ea526616d703b"
+string(6) "8ea580"
+string(6) "8ea5a0"
+string(0) ""
+string(0) ""
+string(6) "8ea5ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fa5a1"
+string(6) "8fa5fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a6a1"
+string(4) "a6fe"
+string(0) ""
+string(4) "8ea6"
+string(14) "8ea626616d703b"
+string(6) "8ea680"
+string(6) "8ea6a0"
+string(0) ""
+string(0) ""
+string(6) "8ea6ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fa6a1"
+string(6) "8fa6fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a7a1"
+string(4) "a7fe"
+string(0) ""
+string(4) "8ea7"
+string(14) "8ea726616d703b"
+string(6) "8ea780"
+string(6) "8ea7a0"
+string(0) ""
+string(0) ""
+string(6) "8ea7ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fa7a1"
+string(6) "8fa7fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a8a1"
+string(4) "a8fe"
+string(0) ""
+string(4) "8ea8"
+string(14) "8ea826616d703b"
+string(6) "8ea880"
+string(6) "8ea8a0"
+string(0) ""
+string(0) ""
+string(6) "8ea8ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fa8a1"
+string(6) "8fa8fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a9a1"
+string(4) "a9fe"
+string(0) ""
+string(4) "8ea9"
+string(14) "8ea926616d703b"
+string(6) "8ea980"
+string(6) "8ea9a0"
+string(0) ""
+string(0) ""
+string(6) "8ea9ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fa9a1"
+string(6) "8fa9fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "aaa1"
+string(4) "aafe"
+string(0) ""
+string(4) "8eaa"
+string(14) "8eaa26616d703b"
+string(6) "8eaa80"
+string(6) "8eaaa0"
+string(0) ""
+string(0) ""
+string(6) "8eaaff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8faaa1"
+string(6) "8faafe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "aba1"
+string(4) "abfe"
+string(0) ""
+string(4) "8eab"
+string(14) "8eab26616d703b"
+string(6) "8eab80"
+string(6) "8eaba0"
+string(0) ""
+string(0) ""
+string(6) "8eabff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8faba1"
+string(6) "8fabfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "aca1"
+string(4) "acfe"
+string(0) ""
+string(4) "8eac"
+string(14) "8eac26616d703b"
+string(6) "8eac80"
+string(6) "8eaca0"
+string(0) ""
+string(0) ""
+string(6) "8eacff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8faca1"
+string(6) "8facfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ada1"
+string(4) "adfe"
+string(0) ""
+string(4) "8ead"
+string(14) "8ead26616d703b"
+string(6) "8ead80"
+string(6) "8eada0"
+string(0) ""
+string(0) ""
+string(6) "8eadff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fada1"
+string(6) "8fadfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "aea1"
+string(4) "aefe"
+string(0) ""
+string(4) "8eae"
+string(14) "8eae26616d703b"
+string(6) "8eae80"
+string(6) "8eaea0"
+string(0) ""
+string(0) ""
+string(6) "8eaeff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8faea1"
+string(6) "8faefe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "afa1"
+string(4) "affe"
+string(0) ""
+string(4) "8eaf"
+string(14) "8eaf26616d703b"
+string(6) "8eaf80"
+string(6) "8eafa0"
+string(0) ""
+string(0) ""
+string(6) "8eafff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fafa1"
+string(6) "8faffe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b0a1"
+string(4) "b0fe"
+string(0) ""
+string(4) "8eb0"
+string(14) "8eb026616d703b"
+string(6) "8eb080"
+string(6) "8eb0a0"
+string(0) ""
+string(0) ""
+string(6) "8eb0ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fb0a1"
+string(6) "8fb0fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b1a1"
+string(4) "b1fe"
+string(0) ""
+string(4) "8eb1"
+string(14) "8eb126616d703b"
+string(6) "8eb180"
+string(6) "8eb1a0"
+string(0) ""
+string(0) ""
+string(6) "8eb1ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fb1a1"
+string(6) "8fb1fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b2a1"
+string(4) "b2fe"
+string(0) ""
+string(4) "8eb2"
+string(14) "8eb226616d703b"
+string(6) "8eb280"
+string(6) "8eb2a0"
+string(0) ""
+string(0) ""
+string(6) "8eb2ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fb2a1"
+string(6) "8fb2fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b3a1"
+string(4) "b3fe"
+string(0) ""
+string(4) "8eb3"
+string(14) "8eb326616d703b"
+string(6) "8eb380"
+string(6) "8eb3a0"
+string(0) ""
+string(0) ""
+string(6) "8eb3ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fb3a1"
+string(6) "8fb3fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b4a1"
+string(4) "b4fe"
+string(0) ""
+string(4) "8eb4"
+string(14) "8eb426616d703b"
+string(6) "8eb480"
+string(6) "8eb4a0"
+string(0) ""
+string(0) ""
+string(6) "8eb4ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fb4a1"
+string(6) "8fb4fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b5a1"
+string(4) "b5fe"
+string(0) ""
+string(4) "8eb5"
+string(14) "8eb526616d703b"
+string(6) "8eb580"
+string(6) "8eb5a0"
+string(0) ""
+string(0) ""
+string(6) "8eb5ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fb5a1"
+string(6) "8fb5fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b6a1"
+string(4) "b6fe"
+string(0) ""
+string(4) "8eb6"
+string(14) "8eb626616d703b"
+string(6) "8eb680"
+string(6) "8eb6a0"
+string(0) ""
+string(0) ""
+string(6) "8eb6ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fb6a1"
+string(6) "8fb6fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b7a1"
+string(4) "b7fe"
+string(0) ""
+string(4) "8eb7"
+string(14) "8eb726616d703b"
+string(6) "8eb780"
+string(6) "8eb7a0"
+string(0) ""
+string(0) ""
+string(6) "8eb7ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fb7a1"
+string(6) "8fb7fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b8a1"
+string(4) "b8fe"
+string(0) ""
+string(4) "8eb8"
+string(14) "8eb826616d703b"
+string(6) "8eb880"
+string(6) "8eb8a0"
+string(0) ""
+string(0) ""
+string(6) "8eb8ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fb8a1"
+string(6) "8fb8fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b9a1"
+string(4) "b9fe"
+string(0) ""
+string(4) "8eb9"
+string(14) "8eb926616d703b"
+string(6) "8eb980"
+string(6) "8eb9a0"
+string(0) ""
+string(0) ""
+string(6) "8eb9ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fb9a1"
+string(6) "8fb9fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "baa1"
+string(4) "bafe"
+string(0) ""
+string(4) "8eba"
+string(14) "8eba26616d703b"
+string(6) "8eba80"
+string(6) "8ebaa0"
+string(0) ""
+string(0) ""
+string(6) "8ebaff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fbaa1"
+string(6) "8fbafe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "bba1"
+string(4) "bbfe"
+string(0) ""
+string(4) "8ebb"
+string(14) "8ebb26616d703b"
+string(6) "8ebb80"
+string(6) "8ebba0"
+string(0) ""
+string(0) ""
+string(6) "8ebbff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fbba1"
+string(6) "8fbbfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "bca1"
+string(4) "bcfe"
+string(0) ""
+string(4) "8ebc"
+string(14) "8ebc26616d703b"
+string(6) "8ebc80"
+string(6) "8ebca0"
+string(0) ""
+string(0) ""
+string(6) "8ebcff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fbca1"
+string(6) "8fbcfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "bda1"
+string(4) "bdfe"
+string(0) ""
+string(4) "8ebd"
+string(14) "8ebd26616d703b"
+string(6) "8ebd80"
+string(6) "8ebda0"
+string(0) ""
+string(0) ""
+string(6) "8ebdff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fbda1"
+string(6) "8fbdfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "bea1"
+string(4) "befe"
+string(0) ""
+string(4) "8ebe"
+string(14) "8ebe26616d703b"
+string(6) "8ebe80"
+string(6) "8ebea0"
+string(0) ""
+string(0) ""
+string(6) "8ebeff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fbea1"
+string(6) "8fbefe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "bfa1"
+string(4) "bffe"
+string(0) ""
+string(4) "8ebf"
+string(14) "8ebf26616d703b"
+string(6) "8ebf80"
+string(6) "8ebfa0"
+string(0) ""
+string(0) ""
+string(6) "8ebfff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fbfa1"
+string(6) "8fbffe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c0a1"
+string(4) "c0fe"
+string(0) ""
+string(4) "8ec0"
+string(14) "8ec026616d703b"
+string(6) "8ec080"
+string(6) "8ec0a0"
+string(0) ""
+string(0) ""
+string(6) "8ec0ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fc0a1"
+string(6) "8fc0fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c1a1"
+string(4) "c1fe"
+string(0) ""
+string(4) "8ec1"
+string(14) "8ec126616d703b"
+string(6) "8ec180"
+string(6) "8ec1a0"
+string(0) ""
+string(0) ""
+string(6) "8ec1ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fc1a1"
+string(6) "8fc1fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c2a1"
+string(4) "c2fe"
+string(0) ""
+string(4) "8ec2"
+string(14) "8ec226616d703b"
+string(6) "8ec280"
+string(6) "8ec2a0"
+string(0) ""
+string(0) ""
+string(6) "8ec2ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fc2a1"
+string(6) "8fc2fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c3a1"
+string(4) "c3fe"
+string(0) ""
+string(4) "8ec3"
+string(14) "8ec326616d703b"
+string(6) "8ec380"
+string(6) "8ec3a0"
+string(0) ""
+string(0) ""
+string(6) "8ec3ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fc3a1"
+string(6) "8fc3fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c4a1"
+string(4) "c4fe"
+string(0) ""
+string(4) "8ec4"
+string(14) "8ec426616d703b"
+string(6) "8ec480"
+string(6) "8ec4a0"
+string(0) ""
+string(0) ""
+string(6) "8ec4ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fc4a1"
+string(6) "8fc4fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c5a1"
+string(4) "c5fe"
+string(0) ""
+string(4) "8ec5"
+string(14) "8ec526616d703b"
+string(6) "8ec580"
+string(6) "8ec5a0"
+string(0) ""
+string(0) ""
+string(6) "8ec5ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fc5a1"
+string(6) "8fc5fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c6a1"
+string(4) "c6fe"
+string(0) ""
+string(4) "8ec6"
+string(14) "8ec626616d703b"
+string(6) "8ec680"
+string(6) "8ec6a0"
+string(0) ""
+string(0) ""
+string(6) "8ec6ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fc6a1"
+string(6) "8fc6fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c7a1"
+string(4) "c7fe"
+string(0) ""
+string(4) "8ec7"
+string(14) "8ec726616d703b"
+string(6) "8ec780"
+string(6) "8ec7a0"
+string(0) ""
+string(0) ""
+string(6) "8ec7ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fc7a1"
+string(6) "8fc7fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c8a1"
+string(4) "c8fe"
+string(0) ""
+string(4) "8ec8"
+string(14) "8ec826616d703b"
+string(6) "8ec880"
+string(6) "8ec8a0"
+string(0) ""
+string(0) ""
+string(6) "8ec8ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fc8a1"
+string(6) "8fc8fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c9a1"
+string(4) "c9fe"
+string(0) ""
+string(4) "8ec9"
+string(14) "8ec926616d703b"
+string(6) "8ec980"
+string(6) "8ec9a0"
+string(0) ""
+string(0) ""
+string(6) "8ec9ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fc9a1"
+string(6) "8fc9fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "caa1"
+string(4) "cafe"
+string(0) ""
+string(4) "8eca"
+string(14) "8eca26616d703b"
+string(6) "8eca80"
+string(6) "8ecaa0"
+string(0) ""
+string(0) ""
+string(6) "8ecaff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fcaa1"
+string(6) "8fcafe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "cba1"
+string(4) "cbfe"
+string(0) ""
+string(4) "8ecb"
+string(14) "8ecb26616d703b"
+string(6) "8ecb80"
+string(6) "8ecba0"
+string(0) ""
+string(0) ""
+string(6) "8ecbff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fcba1"
+string(6) "8fcbfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "cca1"
+string(4) "ccfe"
+string(0) ""
+string(4) "8ecc"
+string(14) "8ecc26616d703b"
+string(6) "8ecc80"
+string(6) "8ecca0"
+string(0) ""
+string(0) ""
+string(6) "8eccff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fcca1"
+string(6) "8fccfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "cda1"
+string(4) "cdfe"
+string(0) ""
+string(4) "8ecd"
+string(14) "8ecd26616d703b"
+string(6) "8ecd80"
+string(6) "8ecda0"
+string(0) ""
+string(0) ""
+string(6) "8ecdff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fcda1"
+string(6) "8fcdfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "cea1"
+string(4) "cefe"
+string(0) ""
+string(4) "8ece"
+string(14) "8ece26616d703b"
+string(6) "8ece80"
+string(6) "8ecea0"
+string(0) ""
+string(0) ""
+string(6) "8eceff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fcea1"
+string(6) "8fcefe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "cfa1"
+string(4) "cffe"
+string(0) ""
+string(4) "8ecf"
+string(14) "8ecf26616d703b"
+string(6) "8ecf80"
+string(6) "8ecfa0"
+string(0) ""
+string(0) ""
+string(6) "8ecfff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fcfa1"
+string(6) "8fcffe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d0a1"
+string(4) "d0fe"
+string(0) ""
+string(4) "8ed0"
+string(14) "8ed026616d703b"
+string(6) "8ed080"
+string(6) "8ed0a0"
+string(0) ""
+string(0) ""
+string(6) "8ed0ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fd0a1"
+string(6) "8fd0fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d1a1"
+string(4) "d1fe"
+string(0) ""
+string(4) "8ed1"
+string(14) "8ed126616d703b"
+string(6) "8ed180"
+string(6) "8ed1a0"
+string(0) ""
+string(0) ""
+string(6) "8ed1ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fd1a1"
+string(6) "8fd1fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d2a1"
+string(4) "d2fe"
+string(0) ""
+string(4) "8ed2"
+string(14) "8ed226616d703b"
+string(6) "8ed280"
+string(6) "8ed2a0"
+string(0) ""
+string(0) ""
+string(6) "8ed2ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fd2a1"
+string(6) "8fd2fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d3a1"
+string(4) "d3fe"
+string(0) ""
+string(4) "8ed3"
+string(14) "8ed326616d703b"
+string(6) "8ed380"
+string(6) "8ed3a0"
+string(0) ""
+string(0) ""
+string(6) "8ed3ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fd3a1"
+string(6) "8fd3fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d4a1"
+string(4) "d4fe"
+string(0) ""
+string(4) "8ed4"
+string(14) "8ed426616d703b"
+string(6) "8ed480"
+string(6) "8ed4a0"
+string(0) ""
+string(0) ""
+string(6) "8ed4ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fd4a1"
+string(6) "8fd4fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d5a1"
+string(4) "d5fe"
+string(0) ""
+string(4) "8ed5"
+string(14) "8ed526616d703b"
+string(6) "8ed580"
+string(6) "8ed5a0"
+string(0) ""
+string(0) ""
+string(6) "8ed5ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fd5a1"
+string(6) "8fd5fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d6a1"
+string(4) "d6fe"
+string(0) ""
+string(4) "8ed6"
+string(14) "8ed626616d703b"
+string(6) "8ed680"
+string(6) "8ed6a0"
+string(0) ""
+string(0) ""
+string(6) "8ed6ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fd6a1"
+string(6) "8fd6fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d7a1"
+string(4) "d7fe"
+string(0) ""
+string(4) "8ed7"
+string(14) "8ed726616d703b"
+string(6) "8ed780"
+string(6) "8ed7a0"
+string(0) ""
+string(0) ""
+string(6) "8ed7ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fd7a1"
+string(6) "8fd7fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d8a1"
+string(4) "d8fe"
+string(0) ""
+string(4) "8ed8"
+string(14) "8ed826616d703b"
+string(6) "8ed880"
+string(6) "8ed8a0"
+string(0) ""
+string(0) ""
+string(6) "8ed8ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fd8a1"
+string(6) "8fd8fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d9a1"
+string(4) "d9fe"
+string(0) ""
+string(4) "8ed9"
+string(14) "8ed926616d703b"
+string(6) "8ed980"
+string(6) "8ed9a0"
+string(0) ""
+string(0) ""
+string(6) "8ed9ff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fd9a1"
+string(6) "8fd9fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "daa1"
+string(4) "dafe"
+string(0) ""
+string(4) "8eda"
+string(14) "8eda26616d703b"
+string(6) "8eda80"
+string(6) "8edaa0"
+string(0) ""
+string(0) ""
+string(6) "8edaff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fdaa1"
+string(6) "8fdafe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "dba1"
+string(4) "dbfe"
+string(0) ""
+string(4) "8edb"
+string(14) "8edb26616d703b"
+string(6) "8edb80"
+string(6) "8edba0"
+string(0) ""
+string(0) ""
+string(6) "8edbff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fdba1"
+string(6) "8fdbfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "dca1"
+string(4) "dcfe"
+string(0) ""
+string(4) "8edc"
+string(14) "8edc26616d703b"
+string(6) "8edc80"
+string(6) "8edca0"
+string(0) ""
+string(0) ""
+string(6) "8edcff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fdca1"
+string(6) "8fdcfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "dda1"
+string(4) "ddfe"
+string(0) ""
+string(4) "8edd"
+string(14) "8edd26616d703b"
+string(6) "8edd80"
+string(6) "8edda0"
+string(0) ""
+string(0) ""
+string(6) "8eddff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fdda1"
+string(6) "8fddfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "dea1"
+string(4) "defe"
+string(0) ""
+string(4) "8ede"
+string(14) "8ede26616d703b"
+string(6) "8ede80"
+string(6) "8edea0"
+string(0) ""
+string(0) ""
+string(6) "8edeff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fdea1"
+string(6) "8fdefe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "dfa1"
+string(4) "dffe"
+string(0) ""
+string(4) "8edf"
+string(14) "8edf26616d703b"
+string(6) "8edf80"
+string(6) "8edfa0"
+string(0) ""
+string(0) ""
+string(6) "8edfff"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fdfa1"
+string(6) "8fdffe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e0a1"
+string(4) "e0fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fe0a1"
+string(6) "8fe0fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e1a1"
+string(4) "e1fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fe1a1"
+string(6) "8fe1fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e2a1"
+string(4) "e2fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fe2a1"
+string(6) "8fe2fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e3a1"
+string(4) "e3fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fe3a1"
+string(6) "8fe3fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e4a1"
+string(4) "e4fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fe4a1"
+string(6) "8fe4fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e5a1"
+string(4) "e5fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fe5a1"
+string(6) "8fe5fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e6a1"
+string(4) "e6fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fe6a1"
+string(6) "8fe6fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e7a1"
+string(4) "e7fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fe7a1"
+string(6) "8fe7fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e8a1"
+string(4) "e8fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fe8a1"
+string(6) "8fe8fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e9a1"
+string(4) "e9fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fe9a1"
+string(6) "8fe9fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "eaa1"
+string(4) "eafe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8feaa1"
+string(6) "8feafe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "eba1"
+string(4) "ebfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8feba1"
+string(6) "8febfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "eca1"
+string(4) "ecfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8feca1"
+string(6) "8fecfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "eda1"
+string(4) "edfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8feda1"
+string(6) "8fedfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "eea1"
+string(4) "eefe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8feea1"
+string(6) "8feefe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "efa1"
+string(4) "effe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8fefa1"
+string(6) "8feffe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f0a1"
+string(4) "f0fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ff0a1"
+string(6) "8ff0fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f1a1"
+string(4) "f1fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ff1a1"
+string(6) "8ff1fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f2a1"
+string(4) "f2fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ff2a1"
+string(6) "8ff2fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f3a1"
+string(4) "f3fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ff3a1"
+string(6) "8ff3fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f4a1"
+string(4) "f4fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ff4a1"
+string(6) "8ff4fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f5a1"
+string(4) "f5fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ff5a1"
+string(6) "8ff5fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f6a1"
+string(4) "f6fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ff6a1"
+string(6) "8ff6fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f7a1"
+string(4) "f7fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ff7a1"
+string(6) "8ff7fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f8a1"
+string(4) "f8fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ff8a1"
+string(6) "8ff8fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f9a1"
+string(4) "f9fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ff9a1"
+string(6) "8ff9fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "faa1"
+string(4) "fafe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ffaa1"
+string(6) "8ffafe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fba1"
+string(4) "fbfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ffba1"
+string(6) "8ffbfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fca1"
+string(4) "fcfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ffca1"
+string(6) "8ffcfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fda1"
+string(4) "fdfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ffda1"
+string(6) "8ffdfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fea1"
+string(4) "fefe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(0) ""
+string(6) "8ffea1"
+string(6) "8ffefe"
+string(0) ""
+--
+string(2) "80"
+string(2) "ff"
+--
+string(0) ""
+string(0) ""
+string(4) "8140"
+string(4) "817e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "81a1"
+string(4) "81fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8240"
+string(4) "827e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "82a1"
+string(4) "82fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8340"
+string(4) "837e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "83a1"
+string(4) "83fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8440"
+string(4) "847e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "84a1"
+string(4) "84fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8540"
+string(4) "857e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "85a1"
+string(4) "85fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8640"
+string(4) "867e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "86a1"
+string(4) "86fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8740"
+string(4) "877e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "87a1"
+string(4) "87fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8840"
+string(4) "887e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "88a1"
+string(4) "88fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8940"
+string(4) "897e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "89a1"
+string(4) "89fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8a40"
+string(4) "8a7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8aa1"
+string(4) "8afe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8b40"
+string(4) "8b7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8ba1"
+string(4) "8bfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8c40"
+string(4) "8c7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8ca1"
+string(4) "8cfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8d40"
+string(4) "8d7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8da1"
+string(4) "8dfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8e40"
+string(4) "8e7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8ea1"
+string(4) "8efe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8f40"
+string(4) "8f7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "8fa1"
+string(4) "8ffe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9040"
+string(4) "907e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "90a1"
+string(4) "90fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9140"
+string(4) "917e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "91a1"
+string(4) "91fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9240"
+string(4) "927e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "92a1"
+string(4) "92fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9340"
+string(4) "937e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "93a1"
+string(4) "93fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9440"
+string(4) "947e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "94a1"
+string(4) "94fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9540"
+string(4) "957e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "95a1"
+string(4) "95fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9640"
+string(4) "967e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "96a1"
+string(4) "96fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9740"
+string(4) "977e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "97a1"
+string(4) "97fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9840"
+string(4) "987e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "98a1"
+string(4) "98fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9940"
+string(4) "997e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "99a1"
+string(4) "99fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9a40"
+string(4) "9a7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9aa1"
+string(4) "9afe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9b40"
+string(4) "9b7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9ba1"
+string(4) "9bfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9c40"
+string(4) "9c7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9ca1"
+string(4) "9cfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9d40"
+string(4) "9d7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9da1"
+string(4) "9dfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9e40"
+string(4) "9e7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9ea1"
+string(4) "9efe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9f40"
+string(4) "9f7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "9fa1"
+string(4) "9ffe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a040"
+string(4) "a07e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a0a1"
+string(4) "a0fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a140"
+string(4) "a17e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a1a1"
+string(4) "a1fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a240"
+string(4) "a27e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a2a1"
+string(4) "a2fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a340"
+string(4) "a37e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a3a1"
+string(4) "a3fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a440"
+string(4) "a47e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a4a1"
+string(4) "a4fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a540"
+string(4) "a57e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a5a1"
+string(4) "a5fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a640"
+string(4) "a67e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a6a1"
+string(4) "a6fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a740"
+string(4) "a77e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a7a1"
+string(4) "a7fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a840"
+string(4) "a87e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a8a1"
+string(4) "a8fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a940"
+string(4) "a97e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "a9a1"
+string(4) "a9fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "aa40"
+string(4) "aa7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "aaa1"
+string(4) "aafe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ab40"
+string(4) "ab7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "aba1"
+string(4) "abfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ac40"
+string(4) "ac7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "aca1"
+string(4) "acfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ad40"
+string(4) "ad7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ada1"
+string(4) "adfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ae40"
+string(4) "ae7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "aea1"
+string(4) "aefe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "af40"
+string(4) "af7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "afa1"
+string(4) "affe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b040"
+string(4) "b07e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b0a1"
+string(4) "b0fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b140"
+string(4) "b17e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b1a1"
+string(4) "b1fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b240"
+string(4) "b27e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b2a1"
+string(4) "b2fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b340"
+string(4) "b37e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b3a1"
+string(4) "b3fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b440"
+string(4) "b47e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b4a1"
+string(4) "b4fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b540"
+string(4) "b57e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b5a1"
+string(4) "b5fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b640"
+string(4) "b67e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b6a1"
+string(4) "b6fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b740"
+string(4) "b77e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b7a1"
+string(4) "b7fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b840"
+string(4) "b87e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b8a1"
+string(4) "b8fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b940"
+string(4) "b97e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "b9a1"
+string(4) "b9fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ba40"
+string(4) "ba7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "baa1"
+string(4) "bafe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "bb40"
+string(4) "bb7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "bba1"
+string(4) "bbfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "bc40"
+string(4) "bc7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "bca1"
+string(4) "bcfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "bd40"
+string(4) "bd7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "bda1"
+string(4) "bdfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "be40"
+string(4) "be7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "bea1"
+string(4) "befe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "bf40"
+string(4) "bf7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "bfa1"
+string(4) "bffe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c040"
+string(4) "c07e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c0a1"
+string(4) "c0fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c140"
+string(4) "c17e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c1a1"
+string(4) "c1fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c240"
+string(4) "c27e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c2a1"
+string(4) "c2fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c340"
+string(4) "c37e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c3a1"
+string(4) "c3fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c440"
+string(4) "c47e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c4a1"
+string(4) "c4fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c540"
+string(4) "c57e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c5a1"
+string(4) "c5fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c640"
+string(4) "c67e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c6a1"
+string(4) "c6fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c740"
+string(4) "c77e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c7a1"
+string(4) "c7fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c840"
+string(4) "c87e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c8a1"
+string(4) "c8fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c940"
+string(4) "c97e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "c9a1"
+string(4) "c9fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ca40"
+string(4) "ca7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "caa1"
+string(4) "cafe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "cb40"
+string(4) "cb7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "cba1"
+string(4) "cbfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "cc40"
+string(4) "cc7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "cca1"
+string(4) "ccfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "cd40"
+string(4) "cd7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "cda1"
+string(4) "cdfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ce40"
+string(4) "ce7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "cea1"
+string(4) "cefe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "cf40"
+string(4) "cf7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "cfa1"
+string(4) "cffe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d040"
+string(4) "d07e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d0a1"
+string(4) "d0fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d140"
+string(4) "d17e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d1a1"
+string(4) "d1fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d240"
+string(4) "d27e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d2a1"
+string(4) "d2fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d340"
+string(4) "d37e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d3a1"
+string(4) "d3fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d440"
+string(4) "d47e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d4a1"
+string(4) "d4fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d540"
+string(4) "d57e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d5a1"
+string(4) "d5fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d640"
+string(4) "d67e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d6a1"
+string(4) "d6fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d740"
+string(4) "d77e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d7a1"
+string(4) "d7fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d840"
+string(4) "d87e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d8a1"
+string(4) "d8fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d940"
+string(4) "d97e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "d9a1"
+string(4) "d9fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "da40"
+string(4) "da7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "daa1"
+string(4) "dafe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "db40"
+string(4) "db7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "dba1"
+string(4) "dbfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "dc40"
+string(4) "dc7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "dca1"
+string(4) "dcfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "dd40"
+string(4) "dd7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "dda1"
+string(4) "ddfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "de40"
+string(4) "de7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "dea1"
+string(4) "defe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "df40"
+string(4) "df7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "dfa1"
+string(4) "dffe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e040"
+string(4) "e07e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e0a1"
+string(4) "e0fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e140"
+string(4) "e17e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e1a1"
+string(4) "e1fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e240"
+string(4) "e27e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e2a1"
+string(4) "e2fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e340"
+string(4) "e37e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e3a1"
+string(4) "e3fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e440"
+string(4) "e47e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e4a1"
+string(4) "e4fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e540"
+string(4) "e57e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e5a1"
+string(4) "e5fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e640"
+string(4) "e67e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e6a1"
+string(4) "e6fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e740"
+string(4) "e77e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e7a1"
+string(4) "e7fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e840"
+string(4) "e87e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e8a1"
+string(4) "e8fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e940"
+string(4) "e97e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "e9a1"
+string(4) "e9fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ea40"
+string(4) "ea7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "eaa1"
+string(4) "eafe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "eb40"
+string(4) "eb7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "eba1"
+string(4) "ebfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ec40"
+string(4) "ec7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "eca1"
+string(4) "ecfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ed40"
+string(4) "ed7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "eda1"
+string(4) "edfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ee40"
+string(4) "ee7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "eea1"
+string(4) "eefe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "ef40"
+string(4) "ef7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "efa1"
+string(4) "effe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f040"
+string(4) "f07e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f0a1"
+string(4) "f0fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f140"
+string(4) "f17e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f1a1"
+string(4) "f1fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f240"
+string(4) "f27e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f2a1"
+string(4) "f2fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f340"
+string(4) "f37e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f3a1"
+string(4) "f3fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f440"
+string(4) "f47e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f4a1"
+string(4) "f4fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f540"
+string(4) "f57e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f5a1"
+string(4) "f5fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f640"
+string(4) "f67e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f6a1"
+string(4) "f6fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f740"
+string(4) "f77e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f7a1"
+string(4) "f7fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f840"
+string(4) "f87e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f8a1"
+string(4) "f8fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f940"
+string(4) "f97e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "f9a1"
+string(4) "f9fe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fa40"
+string(4) "fa7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "faa1"
+string(4) "fafe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fb40"
+string(4) "fb7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fba1"
+string(4) "fbfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fc40"
+string(4) "fc7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fca1"
+string(4) "fcfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fd40"
+string(4) "fd7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fda1"
+string(4) "fdfe"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fe40"
+string(4) "fe7e"
+string(0) ""
+string(0) ""
+string(0) ""
+string(4) "fea1"
+string(4) "fefe"
+string(0) ""
diff --git a/ext/standard/tests/strings/htmlentities02.phpt b/ext/standard/tests/strings/htmlentities02.phpt
index b8b9e63..5d708c2 100644
--- a/ext/standard/tests/strings/htmlentities02.phpt
+++ b/ext/standard/tests/strings/htmlentities02.phpt
@@ -10,7 +10,7 @@ if (!$result) {
 --INI--
 output_handler=
 default_charset=
-mbstring.internal_encoding=none
+mbstring.internal_encoding=pass
 --FILE--
 <?php
 	setlocale(LC_CTYPE, "fr_FR.ISO-8859-15", "fr_FR.ISO8859-15", 'fr_FR at euro');
diff --git a/ext/standard/tests/strings/htmlentities03.phpt b/ext/standard/tests/strings/htmlentities03.phpt
index 7e93354..9f40ff3 100644
--- a/ext/standard/tests/strings/htmlentities03.phpt
+++ b/ext/standard/tests/strings/htmlentities03.phpt
@@ -10,7 +10,7 @@ if (!$result || preg_match('/ISO/i', setlocale(LC_CTYPE, 0)) == 0) {
 --INI--
 output_handler=
 default_charset=
-mbstring.internal_encoding=none
+mbstring.internal_encoding=pass
 --FILE--
 <?php
 	setlocale( LC_CTYPE, "de_DE.ISO-8859-1", "de_DE.ISO8859-1");
diff --git a/ext/standard/tests/strings/htmlentities04.phpt b/ext/standard/tests/strings/htmlentities04.phpt
index 8e362d0..565c11b 100644
--- a/ext/standard/tests/strings/htmlentities04.phpt
+++ b/ext/standard/tests/strings/htmlentities04.phpt
@@ -10,7 +10,7 @@ if (!$result || preg_match('/EUC[^a-zA-Z]*JP/i', setlocale(LC_CTYPE, 0)) == 0) {
 --INI--
 output_handler=
 default_charset=
-mbstring.internal_encoding=none
+mbstring.internal_encoding=pass
 --FILE--
 <?php
 	setlocale( LC_CTYPE, "ja_JP.EUC-JP", "ja_JP.eucJP" );
diff --git a/ext/standard/tests/strings/htmlentities15.phpt b/ext/standard/tests/strings/htmlentities15.phpt
index 2dc36e6..f45be11 100644
--- a/ext/standard/tests/strings/htmlentities15.phpt
+++ b/ext/standard/tests/strings/htmlentities15.phpt
@@ -3,7 +3,7 @@ htmlentities() test 15 (setlocale / KOI8-R)
 --INI--
 output_handler=
 default_charset=
-mbstring.internal_encoding=none
+mbstring.internal_encoding=pass
 --SKIPIF--
 <?php
 $result = (bool)setlocale(LC_CTYPE, "ru_RU.koi8r", "ru_RU.KOI8-R");
diff --git a/ext/standard/tests/strings/setlocale_variation2.phpt b/ext/standard/tests/strings/setlocale_variation2.phpt
index 98c405b..af8739a 100644
--- a/ext/standard/tests/strings/setlocale_variation2.phpt
+++ b/ext/standard/tests/strings/setlocale_variation2.phpt
@@ -18,6 +18,10 @@ if (substr(PHP_OS, 0, 3) == 'WIN') {
 /* setlocale() to set all available locales in the system and check the success count */
 echo "*** Testing setlocale() : usage variations ***\n";
 
+function good_locale($locale) {
+	return $locale !== 'tt_RU at iqtelif.UTF-8';
+}
+
 /* Prototype  : array list_system_locales( void )
  * Description: To get the currently installed locle in this platform 
  * Arguments  : Nil
@@ -38,8 +42,8 @@ function list_system_locales() {
 
   $system_locales = explode("\n", $all_locales);
 
-  // return all the locale found in the system
-  return $system_locales;
+  // return all the locale found in the system, except for broken one
+  return array_filter($system_locales, 'good_locale');
 }
 
 // gather all the locales installed in the system
diff --git a/ext/standard/url.c b/ext/standard/url.c
index c58ba73..677f123 100644
--- a/ext/standard/url.c
+++ b/ext/standard/url.c
@@ -15,7 +15,7 @@
    | Author: Jim Winstead <jimw at php.net>                                  |
    +----------------------------------------------------------------------+
  */
-/* $Id: url.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: url.c 290199 2009-11-04 13:44:10Z iliaa $ */
 
 #include <stdlib.h>
 #include <string.h>
@@ -201,10 +201,21 @@ PHPAPI php_url *php_url_parse_ex(char const *str, int length)
 	e = ue;
 	
 	if (!(p = memchr(s, '/', (ue - s)))) {
-		if ((p = memchr(s, '?', (ue - s)))) {
-			e = p;
-		} else if ((p = memchr(s, '#', (ue - s)))) {
-			e = p;
+		char *query, *fragment;
+
+		query = memchr(s, '?', (ue - s));
+		fragment = memchr(s, '#', (ue - s));
+
+		if (query && fragment) {
+			if (query > fragment) {
+				p = e = fragment;
+			} else {
+				p = e = query;
+			}
+		} else if (query) {
+			p = e = query;
+		} else if (fragment) {
+			p = e = fragment;
 		}
 	} else {
 		e = p;
@@ -285,10 +296,10 @@ PHPAPI php_url *php_url_parse_ex(char const *str, int length)
 	
 	if ((p = memchr(s, '?', (ue - s)))) {
 		pp = strchr(s, '#');
-		
+
 		if (pp && pp < p) {
 			p = pp;
-			pp = strchr(pp+2, '#');
+			goto label_parse;
 		}
 	
 		if (p - s) {
diff --git a/ext/standard/var.c b/ext/standard/var.c
index 67d4596..5f6c5de 100644
--- a/ext/standard/var.c
+++ b/ext/standard/var.c
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: var.c 287123 2009-08-11 22:46:07Z stas $ */
+/* $Id: var.c 291413 2009-11-29 04:38:46Z stas $ */
 
 
 
@@ -631,9 +631,9 @@ static void php_var_serialize_class(smart_str *buf, zval *struc, zval *retval_pt
 							break;
 						}
 						pefree(prot_name, ce->type & ZEND_INTERNAL_CLASS);
-						php_error_docref(NULL TSRMLS_CC, E_NOTICE, "\"%s\" returned as member variable from __sleep() but does not exist", Z_STRVAL_PP(name));
 						php_var_serialize_string(buf, Z_STRVAL_PP(name), Z_STRLEN_PP(name));
 						php_var_serialize_intern(buf, nvalp, var_hash TSRMLS_CC);
+						php_error_docref(NULL TSRMLS_CC, E_NOTICE, "\"%s\" returned as member variable from __sleep() but does not exist", Z_STRVAL_PP(name));
 					} while (0);
 				} else {
 					php_var_serialize_string(buf, Z_STRVAL_PP(name), Z_STRLEN_PP(name));
diff --git a/ext/xml/tests/bug32001b.phpt b/ext/xml/tests/bug32001b.phpt
index f4aea08..ddf26ce 100755
--- a/ext/xml/tests/bug32001b.phpt
+++ b/ext/xml/tests/bug32001b.phpt
@@ -95,9 +95,7 @@ $suite = array(
 );
 
 if (XML_SAX_IMPL == 'libxml') {
-  $php = getenv('TEST_PHP_EXECUTABLE');
-  preg_match("/^libxml2 Version.*\$/im", `$php -i`, $match);
-  echo $match[0], "\n";
+  echo "libxml2 Version => " . LIBXML_DOTTED_VERSION. "\n";
 } else {
   echo "libxml2 Version => NONE\n";  
 }
diff --git a/ext/xmlrpc/tests/bug50282.phpt b/ext/xmlrpc/tests/bug50282.phpt
new file mode 100644
index 0000000..eb35fe3
--- /dev/null
+++ b/ext/xmlrpc/tests/bug50282.phpt
@@ -0,0 +1,43 @@
+--TEST--
+Bug #50282 (xmlrpc_encode_request() changes object into array in calling function)
+--SKIPIF--
+<?php if (!extension_loaded("xmlrpc")) print "skip"; ?>
+--FILE--
+<?php
+
+class One { var $x = 10; }
+
+$o = new One();
+var_dump($o);
+var_dump(xmlrpc_encode_request('test', $o));
+var_dump($o);
+
+?>
+--EXPECTF--
+object(One)#%d (1) {
+  ["x"]=>
+  int(10)
+}
+string(279) "<?xml version="1.0" encoding="iso-8859-1"?>
+<methodCall>
+<methodName>test</methodName>
+<params>
+ <param>
+  <value>
+   <struct>
+    <member>
+     <name>x</name>
+     <value>
+      <int>10</int>
+     </value>
+    </member>
+   </struct>
+  </value>
+ </param>
+</params>
+</methodCall>
+"
+object(One)#%d (1) {
+  ["x"]=>
+  int(10)
+}
diff --git a/ext/xmlrpc/tests/bug50285.phpt b/ext/xmlrpc/tests/bug50285.phpt
new file mode 100644
index 0000000..cf766fc
--- /dev/null
+++ b/ext/xmlrpc/tests/bug50285.phpt
@@ -0,0 +1,115 @@
+--TEST--
+Bug #50285 (xmlrpc does not preserve keys in encoded indexed arrays)
+--FILE--
+<?php
+
+function test1($func, $params) {
+    return array(1=>'One', 3=>'Three', 5=>'Five');
+}
+
+function test2($func, $params) {
+    return array('One', 'Three', 'Five', 5);
+}
+
+function test3($func, $params) {
+    return array('One', 3 => 'Three', b'Five' => 5, 'Six');
+}
+
+function test4($func, $params) {
+    return array('One', 'Three', 'Five', b'Six' => 6);
+}
+
+$server = xmlrpc_server_create();
+$result = xmlrpc_server_register_method($server, 'test1', 'test1');
+$HTTP_RAW_POST_DATA = <<<EOD
+<?xml version="1.0" encoding="UTF-8"?>
+<methodCall>
+<methodName>test1</methodName>
+<params />
+</methodCall>
+EOD;
+$response = xmlrpc_server_call_method($server, $HTTP_RAW_POST_DATA, null);
+var_dump(xmlrpc_decode($response));
+
+// ------------ 
+
+$server = xmlrpc_server_create();
+$result = xmlrpc_server_register_method($server, 'test2', 'test2');
+$HTTP_RAW_POST_DATA = <<<EOD
+<?xml version="1.0" encoding="UTF-8"?>
+<methodCall>
+<methodName>test2</methodName>
+<params />
+</methodCall>
+EOD;
+$response = xmlrpc_server_call_method($server, $HTTP_RAW_POST_DATA, null);
+var_dump(xmlrpc_decode($response));
+
+// ------------ 
+
+$server = xmlrpc_server_create();
+$result = xmlrpc_server_register_method($server, 'test3', 'test3');
+$HTTP_RAW_POST_DATA = <<<EOD
+<?xml version="1.0" encoding="UTF-8"?>
+<methodCall>
+<methodName>test3</methodName>
+<params />
+</methodCall>
+EOD;
+$response = xmlrpc_server_call_method($server, $HTTP_RAW_POST_DATA, null);
+var_dump(xmlrpc_decode($response));
+
+// ------------ 
+
+$server = xmlrpc_server_create();
+$result = xmlrpc_server_register_method($server, 'test4', 'test4');
+$HTTP_RAW_POST_DATA = <<<EOD
+<?xml version="1.0" encoding="UTF-8"?>
+<methodCall>
+<methodName>test4</methodName>
+<params />
+</methodCall>
+EOD;
+$response = xmlrpc_server_call_method($server, $HTTP_RAW_POST_DATA, null);
+var_dump(xmlrpc_decode($response));
+
+?>
+--EXPECT--
+array(3) {
+  [1]=>
+  string(3) "One"
+  [3]=>
+  string(5) "Three"
+  [5]=>
+  string(4) "Five"
+}
+array(4) {
+  [0]=>
+  string(3) "One"
+  [1]=>
+  string(5) "Three"
+  [2]=>
+  string(4) "Five"
+  [3]=>
+  int(5)
+}
+array(4) {
+  [0]=>
+  string(3) "One"
+  [3]=>
+  string(5) "Three"
+  ["Five"]=>
+  int(5)
+  [4]=>
+  string(3) "Six"
+}
+array(4) {
+  [0]=>
+  string(3) "One"
+  [1]=>
+  string(5) "Three"
+  [2]=>
+  string(4) "Five"
+  ["Six"]=>
+  int(6)
+}
diff --git a/ext/xmlrpc/xmlrpc-epi-php.c b/ext/xmlrpc/xmlrpc-epi-php.c
index a55948c..d3ba1c2 100644
--- a/ext/xmlrpc/xmlrpc-epi-php.c
+++ b/ext/xmlrpc/xmlrpc-epi-php.c
@@ -51,7 +51,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: xmlrpc-epi-php.c 280954 2009-05-22 12:50:44Z felipe $ */
+/* $Id: xmlrpc-epi-php.c 291285 2009-11-25 02:03:02Z felipe $ */
 
 /**********************************************************************
 * BUGS:                                                               *
@@ -428,7 +428,7 @@ static void set_output_options(php_output_options* options, zval* output_opts)
 static XMLRPC_VECTOR_TYPE determine_vector_type (HashTable *ht)
 {
 	int bArray = 0, bStruct = 0, bMixed = 0;
-	unsigned long num_index;
+	unsigned long num_index, last_num = 0;
 	char* my_key;
 
 	zend_hash_internal_pointer_reset(ht);
@@ -438,8 +438,12 @@ static XMLRPC_VECTOR_TYPE determine_vector_type (HashTable *ht)
 			if(bStruct) {
 				bMixed = 1;
 				break;
+			} else if (last_num > 0 && last_num != num_index-1) {
+				bStruct = 1;
+				break;
 			}
 			bArray = 1;
+			last_num = num_index;
 		}
 		else if(res == HASH_KEY_NON_EXISTANT) {
 			break;
@@ -499,6 +503,8 @@ static XMLRPC_VALUE PHP_to_XMLRPC_worker (const char* key, zval* in_val, int dep
 					zval** pIter;
 					char* my_key;
 					HashTable *ht = NULL;
+					zval *val_arr;
+					XMLRPC_VECTOR_TYPE vtype;
 
 					ht = HASH_OF(val);
 					if (ht && ht->nApplyCount > 1) {
@@ -506,12 +512,18 @@ static XMLRPC_VALUE PHP_to_XMLRPC_worker (const char* key, zval* in_val, int dep
 						return NULL;
 					}
 
-					convert_to_array(val);
-					xReturn = XMLRPC_CreateVector(key, determine_vector_type(Z_ARRVAL_P(val)));
-
-					zend_hash_internal_pointer_reset(Z_ARRVAL_P(val));
-					while(zend_hash_get_current_data(Z_ARRVAL_P(val), (void**)&pIter) == SUCCESS) {
-						int res = my_zend_hash_get_current_key(Z_ARRVAL_P(val), &my_key, &num_index);
+					MAKE_STD_ZVAL(val_arr);
+					*val_arr = *val;
+					zval_copy_ctor(val_arr);
+					INIT_PZVAL(val_arr);
+					convert_to_array(val_arr);
+					
+					vtype = determine_vector_type(Z_ARRVAL_P(val_arr));
+					xReturn = XMLRPC_CreateVector(key, vtype);
+
+					zend_hash_internal_pointer_reset(Z_ARRVAL_P(val_arr));
+					while(zend_hash_get_current_data(Z_ARRVAL_P(val_arr), (void**)&pIter) == SUCCESS) {
+						int res = my_zend_hash_get_current_key(Z_ARRVAL_P(val_arr), &my_key, &num_index);
                     
 						switch (res) {
 							case HASH_KEY_NON_EXISTANT:
@@ -523,7 +535,15 @@ static XMLRPC_VALUE PHP_to_XMLRPC_worker (const char* key, zval* in_val, int dep
 									ht->nApplyCount++;
 								}
 								if (res == HASH_KEY_IS_LONG) {
-									XMLRPC_AddValueToVector(xReturn, PHP_to_XMLRPC_worker(0, *pIter, depth++ TSRMLS_CC));
+									char *num_str = NULL;
+									
+									if (vtype != xmlrpc_vector_array) {
+										spprintf(&num_str, 0, "%ld", num_index);
+									}
+									XMLRPC_AddValueToVector(xReturn, PHP_to_XMLRPC_worker(num_str, *pIter, depth++ TSRMLS_CC));
+									if (num_str) {
+										efree(num_str);
+									}
 								} else {
 									XMLRPC_AddValueToVector(xReturn, PHP_to_XMLRPC_worker(my_key, *pIter, depth++ TSRMLS_CC));
 								}
@@ -532,8 +552,9 @@ static XMLRPC_VALUE PHP_to_XMLRPC_worker (const char* key, zval* in_val, int dep
 								}
 								break;
 						}
-						zend_hash_move_forward(Z_ARRVAL_P(val));
+						zend_hash_move_forward(Z_ARRVAL_P(val_arr));
 					}
+					zval_ptr_dtor(&val_arr);
 				}
 				break;
 			default:
diff --git a/ext/xmlwriter/tests/bug48204.phpt b/ext/xmlwriter/tests/bug48204.phpt
index 86ab668..ca4a150 100644
--- a/ext/xmlwriter/tests/bug48204.phpt
+++ b/ext/xmlwriter/tests/bug48204.phpt
@@ -2,8 +2,16 @@
 xmlwriter_open_uri with PHP_MAXPATHLEN + 1
 --SKIPIF--
 <?php if (!extension_loaded("xmlwriter")) print "skip"; ?>
+<?php if (!defined('PHP_MAXPATHLEN') && !substr(PHP_OS, 0, 3) == "WIN" && !stristr(PHP_OS, 'linux')) print "skip unknown PHP_MAXPATHLEN"; ?>
 --FILE--
 <?php 
+if (!defined('PHP_MAXPATHLEN')) {
+	if (substr(PHP_OS, 0, 3) == "WIN") {
+		define('PHP_MAXPATHLEN', 260);
+	} else if (stristr(PHP_OS, 'linux')) {
+		define('PHP_MAXPATHLEN', 4096);
+	}
+}
 $path = str_repeat('a', PHP_MAXPATHLEN + 1);
 var_dump(xmlwriter_open_uri('file:///' . $path));
 ?>
diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c
index f7dd73f..6917bb0 100644
--- a/ext/zlib/zlib.c
+++ b/ext/zlib/zlib.c
@@ -19,7 +19,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: zlib.c 287423 2009-08-17 17:30:32Z jani $ */
+/* $Id: zlib.c 290765 2009-11-15 00:13:19Z jani $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -994,16 +994,23 @@ static void php_gzip_output_handler(char *output, uint output_len, char **handle
 		do_start = (mode & PHP_OUTPUT_HANDLER_START ? 1 : 0);
 		do_end = (mode & PHP_OUTPUT_HANDLER_END ? 1 : 0);
 
-		if (do_start && !SG(headers_sent) && !SG(request_info).no_headers) {
-			switch (ZLIBG(compression_coding)) {
-				case CODING_GZIP:
-					sapi_add_header_ex(ZEND_STRL("Content-Encoding: gzip"), 1, 1 TSRMLS_CC);
-					break;
-				case CODING_DEFLATE:
-					sapi_add_header_ex(ZEND_STRL("Content-Encoding: deflate"), 1, 1 TSRMLS_CC);
-					break;
+		if (do_start) {
+			if (!SG(headers_sent) && !SG(request_info).no_headers) {
+				switch (ZLIBG(compression_coding)) {
+					case CODING_GZIP:
+						sapi_add_header_ex(ZEND_STRL("Content-Encoding: gzip"), 1, 1 TSRMLS_CC);
+						break;
+					case CODING_DEFLATE:
+						sapi_add_header_ex(ZEND_STRL("Content-Encoding: deflate"), 1, 1 TSRMLS_CC);
+						break;
+				}
+				sapi_add_header_ex(ZEND_STRL("Vary: Accept-Encoding"), 1, 1 TSRMLS_CC);
+			} else {
+				/* Disable compression if headers can not be set (Fix for bug #49816) */
+				ZLIBG(output_compression) = 0;
+				*handled_output = NULL;
+				return;
 			}
-			sapi_add_header_ex(ZEND_STRL("Vary: Accept-Encoding"), 1, 1 TSRMLS_CC);
 		}
 
 		if (php_deflate_string(output, output_len, handled_output, handled_output_len, do_start, do_end TSRMLS_CC) != SUCCESS) {
diff --git a/ltmain.sh b/ltmain.sh
index 9e71d27..7e2240e 100644
--- a/ltmain.sh
+++ b/ltmain.sh
@@ -1,8 +1,8 @@
 # ltmain.sh - Provide generalized library-building support services.
 # NOTE: Changing this file will not affect anything until you rerun configure.
 #
-# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005
-# Free Software Foundation, Inc.
+# Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2003, 2004, 2005, 2006,
+# 2007, 2008  Free Software Foundation, Inc.
 # Originally by Gordon Matzigkeit <gord at gnu.ai.mit.edu>, 1996
 #
 # This program is free software; you can redistribute it and/or modify
@@ -43,14 +43,22 @@ EXIT_FAILURE=1
 
 PROGRAM=ltmain.sh
 PACKAGE=libtool
-VERSION=1.5.20
-TIMESTAMP=" (1.1220.2.287 2005/08/31 18:54:15)"
-
-# See if we are running on zsh, and set the options which allow our
-# commands through without removal of \ escapes.
-if test -n "${ZSH_VERSION+set}" ; then
+VERSION=1.5.26
+TIMESTAMP=" (1.1220.2.492 2008/01/30 06:40:56)"
+
+# Be Bourne compatible (taken from Autoconf:_AS_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
 
 # Check that we have a working $echo.
 if test "X$1" = X--no-reexec; then
@@ -105,11 +113,19 @@ esac
 # These must not be set unconditionally because not all systems understand
 # e.g. LANG=C (notably SCO).
 # We save the old values to restore during execute mode.
-if test "${LC_ALL+set}" = set; then
-  save_LC_ALL="$LC_ALL"; LC_ALL=C; export LC_ALL
-fi
-if test "${LANG+set}" = set; then
-  save_LANG="$LANG"; LANG=C; export LANG
+lt_env=
+for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
+do
+  eval "if test \"\${$lt_var+set}\" = set; then
+	  save_$lt_var=\$$lt_var
+	  lt_env=\"$lt_var=\$$lt_var \$lt_env\"
+	  $lt_var=C
+	  export $lt_var
+	fi"
+done
+
+if test -n "$lt_env"; then
+  lt_env="env $lt_env"
 fi
 
 # Make sure IFS has a sensible default
@@ -132,13 +148,54 @@ run=
 show="$echo"
 show_help=
 execute_dlfiles=
+duplicate_deps=no
+preserve_args=
 lo2o="s/\\.lo\$/.${objext}/"
 o2lo="s/\\.${objext}\$/.lo/"
+extracted_archives=
+extracted_serial=0
 
 #####################################
 # Shell function definitions:
 # This seems to be the best place for them
 
+# func_mktempdir [string]
+# Make a temporary directory that won't clash with other running
+# libtool processes, and avoids race conditions if possible.  If
+# given, STRING is the basename for that directory.
+func_mktempdir ()
+{
+    my_template="${TMPDIR-/tmp}/${1-$progname}"
+
+    if test "$run" = ":"; then
+      # Return a directory name, but don't create it in dry-run mode
+      my_tmpdir="${my_template}-$$"
+    else
+
+      # If mktemp works, use that first and foremost
+      my_tmpdir=`mktemp -d "${my_template}-XXXXXXXX" 2>/dev/null`
+
+      if test ! -d "$my_tmpdir"; then
+	# Failing that, at least try and use $RANDOM to avoid a race
+	my_tmpdir="${my_template}-${RANDOM-0}$$"
+
+	save_mktempdir_umask=`umask`
+	umask 0077
+	$mkdir "$my_tmpdir"
+	umask $save_mktempdir_umask
+      fi
+
+      # If we're not in dry-run mode, bomb out on failure
+      test -d "$my_tmpdir" || {
+        $echo "cannot create temporary directory \`$my_tmpdir'" 1>&2
+	exit $EXIT_FAILURE
+      }
+    fi
+
+    $echo "X$my_tmpdir" | $Xsed
+}
+
+
 # func_win32_libid arg
 # return the library type of file 'arg'
 #
@@ -157,12 +214,17 @@ func_win32_libid ()
     if eval $OBJDUMP -f $1 | $SED -e '10q' 2>/dev/null | \
       $EGREP -e 'file format pe-i386(.*architecture: i386)?' >/dev/null ; then
       win32_nmres=`eval $NM -f posix -A $1 | \
-	sed -n -e '1,100{/ I /{x;/import/!{s/^/import/;h;p;};x;};}'`
-      if test "X$win32_nmres" = "Ximport" ; then
-        win32_libid_type="x86 archive import"
-      else
-        win32_libid_type="x86 archive static"
-      fi
+	$SED -n -e '1,100{
+		/ I /{
+			s,.*,import,
+			p
+			q
+			}
+		}'`
+      case $win32_nmres in
+      import*)  win32_libid_type="x86 archive import";;
+      *)        win32_libid_type="x86 archive static";;
+      esac
     fi
     ;;
   *DLL*)
@@ -289,15 +351,25 @@ func_extract_archives ()
 	*) my_xabs=`pwd`"/$my_xlib" ;;
       esac
       my_xlib=`$echo "X$my_xlib" | $Xsed -e 's%^.*/%%'`
-      my_xdir="$my_gentop/$my_xlib"
+      my_xlib_u=$my_xlib
+      while :; do
+        case " $extracted_archives " in
+	*" $my_xlib_u "*)
+	  extracted_serial=`expr $extracted_serial + 1`
+	  my_xlib_u=lt$extracted_serial-$my_xlib ;;
+	*) break ;;
+	esac
+      done
+      extracted_archives="$extracted_archives $my_xlib_u"
+      my_xdir="$my_gentop/$my_xlib_u"
 
       $show "${rm}r $my_xdir"
       $run ${rm}r "$my_xdir"
       $show "$mkdir $my_xdir"
       $run $mkdir "$my_xdir"
-      status=$?
-      if test "$status" -ne 0 && test ! -d "$my_xdir"; then
-	exit $status
+      exit_status=$?
+      if test "$exit_status" -ne 0 && test ! -d "$my_xdir"; then
+	exit $exit_status
       fi
       case $host in
       *-darwin*)
@@ -352,6 +424,8 @@ func_extract_archives ()
 # Darwin sucks
 eval std_shrext=\"$shrext_cmds\"
 
+disable_libs=no
+
 # Parse our command line options once, thoroughly.
 while test "$#" -gt 0
 do
@@ -414,11 +488,12 @@ do
     ;;
 
   --version)
-    $echo "$PROGRAM (GNU $PACKAGE) $VERSION$TIMESTAMP"
-    $echo
-    $echo "Copyright (C) 2005  Free Software Foundation, Inc."
-    $echo "This is free software; see the source for copying conditions.  There is NO"
-    $echo "warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
+    echo "\
+$PROGRAM (GNU $PACKAGE) $VERSION$TIMESTAMP
+
+Copyright (C) 2008  Free Software Foundation, Inc.
+This is free software; see the source for copying conditions.  There is NO
+warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE."
     exit $?
     ;;
 
@@ -468,7 +543,11 @@ do
     preserve_args="$preserve_args $arg"
     ;;
 
-  --tag) prevopt="--tag" prev=tag ;;
+  --tag)
+    prevopt="--tag"
+    prev=tag
+    preserve_args="$preserve_args --tag"
+    ;;
   --tag=*)
     set tag "$optarg" ${1+"$@"}
     shift
@@ -500,6 +579,18 @@ if test -n "$prevopt"; then
   exit $EXIT_FAILURE
 fi
 
+case $disable_libs in
+no) 
+  ;;
+shared)
+  build_libtool_libs=no
+  build_old_libs=yes
+  ;;
+static)
+  build_old_libs=`case $build_libtool_libs in yes) echo no;; *) echo yes;; esac`
+  ;;
+esac
+
 # If this variable is set in any of the actions, the command in it
 # will be execed at the end.  This prevents here-documents from being
 # left over by shells.
@@ -699,9 +790,11 @@ if test -z "$show_help"; then
     *.class) xform=class ;;
     *.cpp) xform=cpp ;;
     *.cxx) xform=cxx ;;
-    *.f90) xform=f90 ;;
+    *.[fF][09]?) xform=[fF][09]. ;;
     *.for) xform=for ;;
     *.java) xform=java ;;
+    *.obj) xform=obj ;;
+    *.sx) xform=sx ;;
     esac
 
     libobj=`$echo "X$libobj" | $Xsed -e "s/\.$xform$/.lo/"`
@@ -856,21 +949,22 @@ EOF
       if test ! -d "${xdir}$objdir"; then
 	$show "$mkdir ${xdir}$objdir"
 	$run $mkdir ${xdir}$objdir
-	status=$?
-	if test "$status" -ne 0 && test ! -d "${xdir}$objdir"; then
-	  exit $status
+	exit_status=$?
+	if test "$exit_status" -ne 0 && test ! -d "${xdir}$objdir"; then
+	  exit $exit_status
 	fi
       fi
 
       if test -z "$output_obj"; then
+	$run $rm "$lobj"
 	# Place PIC objects in $objdir
 	command="$command -o $lobj"
+      else
+	$run $rm "$lobj" "$output_obj"
       fi
 
-      $run $rm "$lobj" "$output_obj"
-
       $show "$command"
-      if $run eval "$command"; then :
+      if $run eval $lt_env "$command"; then :
       else
 	test -n "$output_obj" && $run $rm $removelist
 	exit $EXIT_FAILURE
@@ -942,7 +1036,7 @@ EOF
       command="$command$suppress_output"
       $run $rm "$obj" "$output_obj"
       $show "$command"
-      if $run eval "$command"; then :
+      if $run eval $lt_env "$command"; then :
       else
 	$run $rm $removelist
 	exit $EXIT_FAILURE
@@ -1061,6 +1155,7 @@ EOF
     no_install=no
     objs=
     non_pic_objects=
+    notinst_path= # paths that contain not-installed libtool libraries
     precious_files_regex=
     prefer_static_libs=no
     preload=no
@@ -1074,6 +1169,7 @@ EOF
     thread_safe=no
     vinfo=
     vinfo_number=no
+    single_module="${wl}-single_module"
 
     func_infer_tag $base_compile
 
@@ -1081,22 +1177,32 @@ EOF
     for arg
     do
       case $arg in
-      -all-static | -static)
-	if test "X$arg" = "X-all-static"; then
+      -all-static | -static | -static-libtool-libs)
+	case $arg in
+	-all-static)
 	  if test "$build_libtool_libs" = yes && test -z "$link_static_flag"; then
 	    $echo "$modename: warning: complete static linking is impossible in this configuration" 1>&2
 	  fi
 	  if test -n "$link_static_flag"; then
 	    dlopen_self=$dlopen_self_static
 	  fi
-	else
+	  prefer_static_libs=yes
+	  ;;
+	-static)
 	  if test -z "$pic_flag" && test -n "$link_static_flag"; then
 	    dlopen_self=$dlopen_self_static
 	  fi
-	fi
+	  prefer_static_libs=built
+	  ;;
+	-static-libtool-libs)
+	  if test -z "$pic_flag" && test -n "$link_static_flag"; then
+	    dlopen_self=$dlopen_self_static
+	  fi
+	  prefer_static_libs=yes
+	  ;;
+	esac
 	build_libtool_libs=no
 	build_old_libs=yes
-	prefer_static_libs=yes
 	break
 	;;
       esac
@@ -1271,6 +1377,11 @@ EOF
 		  if test -z "$pic_object" || test "$pic_object" = none ; then
 		    arg="$non_pic_object"
 		  fi
+		else
+		  # If the PIC object exists, use it instead.
+		  # $xdir was prepended to $pic_object above.
+		  non_pic_object="$pic_object"
+		  non_pic_objects="$non_pic_objects $non_pic_object"
 		fi
 	      else
 		# Only an error if not doing a dry-run.
@@ -1354,8 +1465,8 @@ EOF
 	  prev=
 	  continue
 	  ;;
-        darwin_framework)
-	  compiler_flags="$compiler_flags $arg"
+	darwin_framework|darwin_framework_skip)
+	  test "$prev" = "darwin_framework" && compiler_flags="$compiler_flags $arg"
 	  compile_command="$compile_command $arg"
 	  finalize_command="$finalize_command $arg"
 	  prev=
@@ -1419,13 +1530,17 @@ EOF
 	continue
 	;;
 
-      -framework|-arch)
-        prev=darwin_framework
-        compiler_flags="$compiler_flags $arg"
+      -framework|-arch|-isysroot)
+	case " $CC " in
+	  *" ${arg} ${1} "* | *" ${arg}	${1} "*) 
+		prev=darwin_framework_skip ;;
+	  *) compiler_flags="$compiler_flags $arg"
+	     prev=darwin_framework ;;
+	esac
 	compile_command="$compile_command $arg"
 	finalize_command="$finalize_command $arg"
-        continue
-        ;;
+	continue
+	;;
 
       -inst-prefix-dir)
 	prev=inst_prefix
@@ -1453,7 +1568,8 @@ EOF
 	  absdir=`cd "$dir" && pwd`
 	  if test -z "$absdir"; then
 	    $echo "$modename: cannot determine absolute directory name of \`$dir'" 1>&2
-	    exit $EXIT_FAILURE
+	    absdir="$dir"
+	    notinst_path="$notinst_path $dir"
 	  fi
 	  dir="$absdir"
 	  ;;
@@ -1467,10 +1583,15 @@ EOF
 	esac
 	case $host in
 	*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*)
+	  testbindir=`$echo "X$dir" | $Xsed -e 's*/lib$*/bin*'`
 	  case :$dllsearchpath: in
 	  *":$dir:"*) ;;
 	  *) dllsearchpath="$dllsearchpath:$dir";;
 	  esac
+	  case :$dllsearchpath: in
+	  *":$testbindir:"*) ;;
+	  *) dllsearchpath="$dllsearchpath:$testbindir";;
+	  esac
 	  ;;
 	esac
 	continue
@@ -1479,11 +1600,11 @@ EOF
       -l*)
 	if test "X$arg" = "X-lc" || test "X$arg" = "X-lm"; then
 	  case $host in
-	  *-*-cygwin* | *-*-pw32* | *-*-beos*)
+	  *-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-beos*)
 	    # These systems don't actually have a C or math library (as such)
 	    continue
 	    ;;
-	  *-*-mingw* | *-*-os2*)
+	  *-*-os2*)
 	    # These systems don't actually have a C library (as such)
 	    test "X$arg" = "X-lc" && continue
 	    ;;
@@ -1495,6 +1616,15 @@ EOF
 	    # Rhapsody C and math libraries are in the System framework
 	    deplibs="$deplibs -framework System"
 	    continue
+	    ;;
+	  *-*-sco3.2v5* | *-*-sco5v6*)
+	    # Causes problems with __ctype
+	    test "X$arg" = "X-lc" && continue
+	    ;;
+	  *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*)
+	    # Compiler inserts libc in the correct place for threads to work
+	    test "X$arg" = "X-lc" && continue
+	    ;;
 	  esac
 	elif test "X$arg" = "X-lc_r"; then
 	 case $host in
@@ -1518,13 +1648,18 @@ EOF
 	continue
 	;;
 
-     -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe)
+     -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads)
 	compiler_flags="$compiler_flags $arg"
 	compile_command="$compile_command $arg"
 	finalize_command="$finalize_command $arg"
 	continue
 	;;
 
+      -multi_module)
+	single_module="${wl}-multi_module"
+	continue
+	;;
+
       -module)
 	module=yes
 	continue
@@ -1536,7 +1671,13 @@ EOF
       # +DA*, +DD* enable 64-bit mode on the HP compiler
       # -q* pass through compiler args for the IBM compiler
       # -m* pass through architecture-specific compiler args for GCC
-      -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*)
+      # -m*, -t[45]*, -txscale* pass through architecture-specific
+      # compiler args for GCC
+      # -p, -pg, --coverage, -fprofile-* pass through profiling flag for GCC
+      # -F/path gives path to uninstalled frameworks, gcc on darwin
+      # @file GCC response files
+      -64|-mips[0-9]|-r[0-9][0-9]*|-xarch=*|-xtarget=*|+DA*|+DD*|-q*|-m*| \
+      -t[45]*|-txscale*|-p|-pg|--coverage|-fprofile-*|-F*|@*)
 
 	# Unknown arguments in both finalize_command and compile_command need
 	# to be aesthetically quoted because they are evaled later.
@@ -1548,9 +1689,7 @@ EOF
 	esac
         compile_command="$compile_command $arg"
         finalize_command="$finalize_command $arg"
-        if test "$with_gcc" = "yes" ; then
-          compiler_flags="$compiler_flags $arg"
-        fi
+        compiler_flags="$compiler_flags $arg"
         continue
         ;;
 
@@ -1566,9 +1705,9 @@ EOF
 
       -no-install)
 	case $host in
-	*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*)
+	*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2* | *-*-darwin*)
 	  # The PATH hackery in wrapper scripts is required on Windows
-	  # in order for the loader to find any dlls it needs.
+	  # and Darwin in order for the loader to find any dlls it needs.
 	  $echo "$modename: warning: \`-no-install' is ignored for $host" 1>&2
 	  $echo "$modename: warning: assuming \`-no-fast-install' instead" 1>&2
 	  fast_install=no
@@ -1627,7 +1766,7 @@ EOF
 	continue
 	;;
 
-      -static)
+      -static | -static-libtool-libs)
 	# The effects of -static are defined in a previous loop.
 	# We used to do the same as -all-static on platforms that
 	# didn't have a PIC flag, but the assumption that the effects
@@ -1788,6 +1927,11 @@ EOF
 	    if test -z "$pic_object" || test "$pic_object" = none ; then
 	      arg="$non_pic_object"
 	    fi
+	  else
+	    # If the PIC object exists, use it instead.
+	    # $xdir was prepended to $pic_object above.
+	    non_pic_object="$pic_object"
+	    non_pic_objects="$non_pic_objects $non_pic_object"
 	  fi
 	else
 	  # Only an error if not doing a dry-run.
@@ -1893,9 +2037,9 @@ EOF
     if test ! -d "$output_objdir"; then
       $show "$mkdir $output_objdir"
       $run $mkdir $output_objdir
-      status=$?
-      if test "$status" -ne 0 && test ! -d "$output_objdir"; then
-	exit $status
+      exit_status=$?
+      if test "$exit_status" -ne 0 && test ! -d "$output_objdir"; then
+	exit $exit_status
       fi
     fi
 
@@ -1958,7 +2102,6 @@ EOF
     newlib_search_path=
     need_relink=no # whether we're linking any uninstalled libtool libraries
     notinst_deplibs= # not-installed libtool libraries
-    notinst_path= # paths that contain not-installed libtool libraries
     case $linkmode in
     lib)
 	passes="conv link"
@@ -2005,7 +2148,7 @@ EOF
 	lib=
 	found=no
 	case $deplib in
-	-mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe)
+	-mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads)
 	  if test "$linkmode,$pass" = "prog,link"; then
 	    compile_deplibs="$deplib $compile_deplibs"
 	    finalize_deplibs="$deplib $finalize_deplibs"
@@ -2020,7 +2163,12 @@ EOF
 	    continue
 	  fi
 	  name=`$echo "X$deplib" | $Xsed -e 's/^-l//'`
-	  for searchdir in $newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path; do
+	  if test "$linkmode" = lib; then
+	    searchdirs="$newlib_search_path $lib_search_path $compiler_lib_search_dirs $sys_lib_search_path $shlib_search_path"
+	  else
+	    searchdirs="$newlib_search_path $lib_search_path $sys_lib_search_path $shlib_search_path"
+	  fi
+	  for searchdir in $searchdirs; do
 	    for search_ext in .la $std_shrext .so .a; do
 	      # Search the libtool library
 	      lib="$searchdir/lib${name}${search_ext}"
@@ -2194,7 +2342,7 @@ EOF
 	esac # case $deplib
 	if test "$found" = yes || test -f "$lib"; then :
 	else
-	  $echo "$modename: cannot find the library \`$lib'" 1>&2
+	  $echo "$modename: cannot find the library \`$lib' or unhandled argument \`$deplib'" 1>&2
 	  exit $EXIT_FAILURE
 	fi
 
@@ -2401,7 +2549,9 @@ EOF
 
 	if test "$linkmode,$pass" = "prog,link"; then
 	  if test -n "$library_names" &&
-	     { test "$prefer_static_libs" = no || test -z "$old_library"; }; then
+	     { { test "$prefer_static_libs" = no ||
+		 test "$prefer_static_libs,$installed" = "built,yes"; } ||
+	       test -z "$old_library"; }; then
 	    # We need to hardcode the library path
 	    if test -n "$shlibpath_var" && test -z "$avoidtemprpath" ; then
 	      # Make sure the rpath contains only unique directories.
@@ -2445,8 +2595,12 @@ EOF
 	fi
 
 	link_static=no # Whether the deplib will be linked statically
+	use_static_libs=$prefer_static_libs
+	if test "$use_static_libs" = built && test "$installed" = yes ; then
+	  use_static_libs=no
+	fi
 	if test -n "$library_names" &&
-	   { test "$prefer_static_libs" = no || test -z "$old_library"; }; then
+	   { test "$use_static_libs" = no || test -z "$old_library"; }; then
 	  if test "$installed" = no; then
 	    notinst_deplibs="$notinst_deplibs $lib"
 	    need_relink=yes
@@ -2559,11 +2713,15 @@ EOF
 	      if test "$hardcode_direct" = no; then
 		add="$dir/$linklib"
 		case $host in
-		  *-*-sco3.2v5* ) add_dir="-L$dir" ;;
+		  *-*-sco3.2v5.0.[024]*) add_dir="-L$dir" ;;
+		  *-*-sysv4*uw2*) add_dir="-L$dir" ;;
+		  *-*-sysv5OpenUNIX* | *-*-sysv5UnixWare7.[01].[10]* | \
+		    *-*-unixware7*) add_dir="-L$dir" ;;
 		  *-*-darwin* )
 		    # if the lib is a module then we can not link against
 		    # it, someone is ignoring the new warnings I added
-		    if /usr/bin/file -L $add 2> /dev/null | $EGREP "bundle" >/dev/null ; then
+		    if /usr/bin/file -L $add 2> /dev/null |
+                      $EGREP ": [^:]* bundle" >/dev/null ; then
 		      $echo "** Warning, lib $linklib is a module, not a shared library"
 		      if test -z "$old_library" ; then
 		        $echo
@@ -2806,12 +2964,18 @@ EOF
 		  # we do not want to link against static libs,
 		  # but need to link against shared
 		  eval deplibrary_names=`${SED} -n -e 's/^library_names=\(.*\)$/\1/p' $deplib`
+		  eval deplibdir=`${SED} -n -e 's/^libdir=\(.*\)$/\1/p' $deplib`
 		  if test -n "$deplibrary_names" ; then
 		    for tmp in $deplibrary_names ; do
 		      depdepl=$tmp
 		    done
-		    if test -f "$path/$depdepl" ; then
+		    if test -f "$deplibdir/$depdepl" ; then
+		      depdepl="$deplibdir/$depdepl"
+	      	    elif test -f "$path/$depdepl" ; then
 		      depdepl="$path/$depdepl"
+		    else
+		      # Can't find it, oh well...
+		      depdepl=
 		    fi
 		    # do not add paths which are already there
 		    case " $newlib_search_path " in
@@ -2959,9 +3123,10 @@ EOF
 
     case $linkmode in
     oldlib)
-      if test -n "$deplibs"; then
-	$echo "$modename: warning: \`-l' and \`-L' are ignored for archives" 1>&2
-      fi
+      case " $deplibs" in
+      *\ -l* | *\ -L*)
+	$echo "$modename: warning: \`-l' and \`-L' are ignored for archives" 1>&2 ;;
+      esac
 
       if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then
 	$echo "$modename: warning: \`-dlopen' is ignored for archives" 1>&2
@@ -3089,7 +3254,7 @@ EOF
 	  # which has an extra 1 added just for fun
 	  #
 	  case $version_type in
-	  darwin|linux|osf|windows)
+	  darwin|linux|osf|windows|none)
 	    current=`expr $number_major + $number_minor`
 	    age="$number_minor"
 	    revision="$number_revision"
@@ -3100,9 +3265,10 @@ EOF
 	    age="0"
 	    ;;
 	  irix|nonstopux)
-	    current=`expr $number_major + $number_minor - 1`
+	    current=`expr $number_major + $number_minor`
 	    age="$number_minor"
 	    revision="$number_minor"
+	    lt_irix_increment=no
 	    ;;
 	  esac
 	  ;;
@@ -3161,7 +3327,8 @@ EOF
 	  versuffix="$major.$age.$revision"
 	  # Darwin ld doesn't like 0 for these options...
 	  minor_current=`expr $current + 1`
-	  verstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision"
+	  xlcverstring="${wl}-compatibility_version ${wl}$minor_current ${wl}-current_version ${wl}$minor_current.$revision"
+	  verstring="-compatibility_version $minor_current -current_version $minor_current.$revision"
 	  ;;
 
 	freebsd-aout)
@@ -3175,8 +3342,11 @@ EOF
 	  ;;
 
 	irix | nonstopux)
-	  major=`expr $current - $age + 1`
-
+	  if test "X$lt_irix_increment" = "Xno"; then
+	    major=`expr $current - $age`
+	  else
+	    major=`expr $current - $age + 1`
+	  fi
 	  case $version_type in
 	    nonstopux) verstring_prefix=nonstopux ;;
 	    *)         verstring_prefix=sgi ;;
@@ -3313,11 +3483,11 @@ EOF
       fi
 
       # Eliminate all temporary directories.
-      for path in $notinst_path; do
-	lib_search_path=`$echo "$lib_search_path " | ${SED} -e 's% $path % %g'`
-	deplibs=`$echo "$deplibs " | ${SED} -e 's% -L$path % %g'`
-	dependency_libs=`$echo "$dependency_libs " | ${SED} -e 's% -L$path % %g'`
-      done
+      #for path in $notinst_path; do
+      #	lib_search_path=`$echo "$lib_search_path " | ${SED} -e "s% $path % %g"`
+      #	deplibs=`$echo "$deplibs " | ${SED} -e "s% -L$path % %g"`
+      #	dependency_libs=`$echo "$dependency_libs " | ${SED} -e "s% -L$path % %g"`
+      #done
 
       if test -n "$xrpath"; then
 	# If the user specified any rpath flags, then add them.
@@ -3369,7 +3539,12 @@ EOF
 	    ;;
 	  *-*-openbsd* | *-*-freebsd* | *-*-dragonfly*)
 	    # Do not include libc due to us having libc/libc_r.
-	    test "X$arg" = "X-lc" && continue
+	    ;;
+	  *-*-sco3.2v5* | *-*-sco5v6*)
+	    # Causes problems with __ctype
+	    ;;
+	  *-*-sysv4.2uw2* | *-*-sysv5* | *-*-unixware* | *-*-OpenUNIX*)
+	    # Compiler inserts libc in the correct place for threads to work
 	    ;;
  	  *)
 	    # Add libc to deplibs on all other systems if necessary.
@@ -3413,13 +3588,12 @@ EOF
 	  int main() { return 0; }
 EOF
 	  $rm conftest
-	  $LTCC -o conftest conftest.c $deplibs
-	  if test "$?" -eq 0 ; then
+	  if $LTCC $LTCFLAGS -o conftest conftest.c $deplibs; then
 	    ldd_output=`ldd conftest`
 	    for i in $deplibs; do
 	      name=`expr $i : '-l\(.*\)'`
 	      # If $name is empty we are operating on a -L argument.
-              if test "$name" != "" && test "$name" -ne "0"; then
+              if test "$name" != "" && test "$name" != "0"; then
 		if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
 		  case " $predeps $postdeps " in
 		  *" $i "*)
@@ -3458,9 +3632,7 @@ EOF
 	      # If $name is empty we are operating on a -L argument.
               if test "$name" != "" && test "$name" != "0"; then
 		$rm conftest
-		$LTCC -o conftest conftest.c $i
-		# Did it work?
-		if test "$?" -eq 0 ; then
+		if $LTCC $LTCFLAGS -o conftest conftest.c $i; then
 		  ldd_output=`ldd conftest`
 		  if test "X$allow_libtool_libs_with_static_runtimes" = "Xyes" ; then
 		    case " $predeps $postdeps " in
@@ -3492,7 +3664,7 @@ EOF
 		  droppeddeps=yes
 		  $echo
 		  $echo "*** Warning!  Library $i is needed by this library but I was not able to"
-		  $echo "***  make it link in!  You will probably need to install it or some"
+		  $echo "*** make it link in!  You will probably need to install it or some"
 		  $echo "*** library that it depends on before this library will be fully"
 		  $echo "*** functional.  Installing it before continuing would be even better."
 		fi
@@ -3705,6 +3877,35 @@ EOF
 	deplibs=$newdeplibs
       fi
 
+
+      # move library search paths that coincide with paths to not yet
+      # installed libraries to the beginning of the library search list
+      new_libs=
+      for path in $notinst_path; do
+	case " $new_libs " in
+	*" -L$path/$objdir "*) ;;
+	*)
+	  case " $deplibs " in
+	  *" -L$path/$objdir "*)
+	    new_libs="$new_libs -L$path/$objdir" ;;
+	  esac
+	  ;;
+	esac
+      done
+      for deplib in $deplibs; do
+	case $deplib in
+	-L*)
+	  case " $new_libs " in
+	  *" $deplib "*) ;;
+	  *) new_libs="$new_libs $deplib" ;;
+	  esac
+	  ;;
+	*) new_libs="$new_libs $deplib" ;;
+	esac
+      done
+      deplibs="$new_libs"
+
+
       # All the library-specific variables (install_libdir is set above).
       library_names=
       old_library=
@@ -3749,7 +3950,10 @@ EOF
 	     test -n "$hardcode_libdirs"; then
 	    libdir="$hardcode_libdirs"
 	    if test -n "$hardcode_libdir_flag_spec_ld"; then
-	      eval dep_rpath=\"$hardcode_libdir_flag_spec_ld\"
+	      case $archive_cmds in
+	      *\$LD*) eval dep_rpath=\"$hardcode_libdir_flag_spec_ld\" ;;
+	      *)      eval dep_rpath=\"$hardcode_libdir_flag_spec\" ;;
+	      esac
 	    else
 	      eval dep_rpath=\"$hardcode_libdir_flag_spec\"
 	    fi
@@ -3788,6 +3992,7 @@ EOF
 	fi
 
 	lib="$output_objdir/$realname"
+	linknames=
 	for link
 	do
 	  linknames="$linknames $link"
@@ -4058,9 +4263,10 @@ EOF
       ;;
 
     obj)
-      if test -n "$deplibs"; then
-	$echo "$modename: warning: \`-l' and \`-L' are ignored for objects" 1>&2
-      fi
+      case " $deplibs" in
+      *\ -l* | *\ -L*)
+	$echo "$modename: warning: \`-l' and \`-L' are ignored for objects" 1>&2 ;;
+      esac
 
       if test -n "$dlfiles$dlprefiles" || test "$dlself" != no; then
 	$echo "$modename: warning: \`-dlopen' is ignored for objects" 1>&2
@@ -4107,12 +4313,14 @@ EOF
       reload_conv_objs=
       gentop=
       # reload_cmds runs $LD directly, so let us get rid of
-      # -Wl from whole_archive_flag_spec
+      # -Wl from whole_archive_flag_spec and hope we can get by with
+      # turning comma into space..
       wl=
 
       if test -n "$convenience"; then
 	if test -n "$whole_archive_flag_spec"; then
-	  eval reload_conv_objs=\"\$reload_objs $whole_archive_flag_spec\"
+	  eval tmp_whole_archive_flags=\"$whole_archive_flag_spec\"
+	  reload_conv_objs=$reload_objs\ `$echo "X$tmp_whole_archive_flags" | $Xsed -e 's|,| |g'`
 	else
 	  gentop="$output_objdir/${obj}x"
 	  generated="$generated $gentop"
@@ -4219,6 +4427,35 @@ EOF
         ;;
       esac
 
+
+      # move library search paths that coincide with paths to not yet
+      # installed libraries to the beginning of the library search list
+      new_libs=
+      for path in $notinst_path; do
+	case " $new_libs " in
+	*" -L$path/$objdir "*) ;;
+	*)
+	  case " $compile_deplibs " in
+	  *" -L$path/$objdir "*)
+	    new_libs="$new_libs -L$path/$objdir" ;;
+	  esac
+	  ;;
+	esac
+      done
+      for deplib in $compile_deplibs; do
+	case $deplib in
+	-L*)
+	  case " $new_libs " in
+	  *" $deplib "*) ;;
+	  *) new_libs="$new_libs $deplib" ;;
+	  esac
+	  ;;
+	*) new_libs="$new_libs $deplib" ;;
+	esac
+      done
+      compile_deplibs="$new_libs"
+
+
       compile_command="$compile_command $compile_deplibs"
       finalize_command="$finalize_command $finalize_deplibs"
 
@@ -4263,10 +4500,15 @@ EOF
 	fi
 	case $host in
 	*-*-cygwin* | *-*-mingw* | *-*-pw32* | *-*-os2*)
+	  testbindir=`$echo "X$libdir" | $Xsed -e 's*/lib$*/bin*'`
 	  case :$dllsearchpath: in
 	  *":$libdir:"*) ;;
 	  *) dllsearchpath="$dllsearchpath:$libdir";;
 	  esac
+	  case :$dllsearchpath: in
+	  *":$testbindir:"*) ;;
+	  *) dllsearchpath="$dllsearchpath:$testbindir";;
+	  esac
 	  ;;
 	esac
       done
@@ -4383,10 +4625,22 @@ extern \"C\" {
 	      export_symbols="$output_objdir/$outputname.exp"
 	      $run $rm $export_symbols
 	      $run eval "${SED} -n -e '/^: @PROGRAM@ $/d' -e 's/^.* \(.*\)$/\1/p' "'< "$nlist" > "$export_symbols"'
+              case $host in
+              *cygwin* | *mingw* )
+	        $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"'
+		$run eval 'cat "$export_symbols" >> "$output_objdir/$outputname.def"'
+                ;;
+              esac
 	    else
-	      $run eval "${SED} -e 's/\([ ][.*^$]\)/\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"'
+	      $run eval "${SED} -e 's/\([].[*^$]\)/\\\\\1/g' -e 's/^/ /' -e 's/$/$/'"' < "$export_symbols" > "$output_objdir/$outputname.exp"'
 	      $run eval 'grep -f "$output_objdir/$outputname.exp" < "$nlist" > "$nlist"T'
 	      $run eval 'mv "$nlist"T "$nlist"'
+              case $host in
+              *cygwin* | *mingw* )
+	        $run eval "echo EXPORTS "'> "$output_objdir/$outputname.def"'
+		$run eval 'cat "$nlist" >> "$output_objdir/$outputname.def"'
+                ;;
+              esac
 	    fi
 	  fi
 
@@ -4503,16 +4757,29 @@ static const void *lt_preloaded_setup() {
 	  esac
 
 	  # Now compile the dynamic symbol file.
-	  $show "(cd $output_objdir && $LTCC -c$no_builtin_flag$pic_flag_for_symtable \"$dlsyms\")"
-	  $run eval '(cd $output_objdir && $LTCC -c$no_builtin_flag$pic_flag_for_symtable "$dlsyms")' || exit $?
+	  $show "(cd $output_objdir && $LTCC  $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable \"$dlsyms\")"
+	  $run eval '(cd $output_objdir && $LTCC  $LTCFLAGS -c$no_builtin_flag$pic_flag_for_symtable "$dlsyms")' || exit $?
 
 	  # Clean up the generated files.
 	  $show "$rm $output_objdir/$dlsyms $nlist ${nlist}S ${nlist}T"
 	  $run $rm "$output_objdir/$dlsyms" "$nlist" "${nlist}S" "${nlist}T"
 
 	  # Transform the symbol file into the correct name.
-	  compile_command=`$echo "X$compile_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"`
-	  finalize_command=`$echo "X$finalize_command" | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%"`
+          case $host in
+          *cygwin* | *mingw* )
+            if test -f "$output_objdir/${outputname}.def" ; then
+              compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%" | $NL2SP`
+              finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}.def $output_objdir/${outputname}S.${objext}%" | $NL2SP`
+            else
+              compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP`
+              finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP`
+             fi
+            ;;
+          * )
+            compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP`
+            finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s%@SYMFILE@%$output_objdir/${outputname}S.${objext}%" | $NL2SP`
+            ;;
+          esac
 	  ;;
 	*)
 	  $echo "$modename: unknown suffix for \`$dlsyms'" 1>&2
@@ -4525,19 +4792,19 @@ static const void *lt_preloaded_setup() {
 	# really was required.
 
 	# Nullify the symbol file.
-	compile_command=`$echo "X$compile_command" | $Xsed -e "s% @SYMFILE@%%"`
-	finalize_command=`$echo "X$finalize_command" | $Xsed -e "s% @SYMFILE@%%"`
+	compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e "s% @SYMFILE@%%" | $NL2SP`
+	finalize_command=`$echo "X$finalize_command" | $SP2NL | $Xsed -e "s% @SYMFILE@%%" | $NL2SP`
       fi
 
       if test "$need_relink" = no || test "$build_libtool_libs" != yes; then
 	# Replace the output file specification.
-	compile_command=`$echo "X$compile_command" | $Xsed -e 's%@OUTPUT@%'"$output"'%g'`
+	compile_command=`$echo "X$compile_command" | $SP2NL | $Xsed -e 's%@OUTPUT@%'"$output"'%g' | $NL2SP`
 	link_command="$compile_command$compile_rpath"
 
 	# We have no uninstalled library dependencies, so finalize right now.
 	$show "$link_command"
 	$run eval "$link_command"
-	status=$?
+	exit_status=$?
 
 	# Delete the generated files.
 	if test -n "$dlsyms"; then
@@ -4545,7 +4812,7 @@ static const void *lt_preloaded_setup() {
 	  $run $rm "$output_objdir/${outputname}S.${objext}"
 	fi
 
-	exit $status
+	exit $exit_status
       fi
 
       if test -n "$shlibpath_var"; then
@@ -4618,7 +4885,7 @@ static const void *lt_preloaded_setup() {
 	if test "$fast_install" != no; then
 	  link_command="$finalize_var$compile_command$finalize_rpath"
 	  if test "$fast_install" = yes; then
-	    relink_command=`$echo "X$compile_var$compile_command$compile_rpath" | $Xsed -e 's%@OUTPUT@%\$progdir/\$file%g'`
+	    relink_command=`$echo "X$compile_var$compile_command$compile_rpath" | $SP2NL | $Xsed -e 's%@OUTPUT@%\$progdir/\$file%g' | $NL2SP`
 	  else
 	    # fast_install is set to needless
 	    relink_command=
@@ -4655,7 +4922,7 @@ static const void *lt_preloaded_setup() {
 	  fi
 	done
 	relink_command="(cd `pwd`; $relink_command)"
-	relink_command=`$echo "X$relink_command" | $Xsed -e "$sed_quote_subst"`
+	relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e "$sed_quote_subst" | $NL2SP`
       fi
 
       # Quote $echo for shipping.
@@ -4685,10 +4952,12 @@ static const void *lt_preloaded_setup() {
 	esac
 	case $host in
 	  *cygwin* | *mingw* )
-	    cwrappersource=`$echo ${objdir}/lt-${outputname}.c`
-	    cwrapper=`$echo ${output}.exe`
-	    $rm $cwrappersource $cwrapper
-	    trap "$rm $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15
+            output_name=`basename $output`
+            output_path=`dirname $output`
+            cwrappersource="$output_path/$objdir/lt-$output_name.c"
+            cwrapper="$output_path/$output_name.exe"
+            $rm $cwrappersource $cwrapper
+            trap "$rm $cwrappersource $cwrapper; exit $EXIT_FAILURE" 1 2 15
 
 	    cat > $cwrappersource <<EOF
 
@@ -4713,6 +4982,9 @@ EOF
 #include <malloc.h>
 #include <stdarg.h>
 #include <assert.h>
+#include <string.h>
+#include <ctype.h>
+#include <sys/stat.h>
 
 #if defined(PATH_MAX)
 # define LT_PATHMAX PATH_MAX
@@ -4723,15 +4995,19 @@ EOF
 #endif
 
 #ifndef DIR_SEPARATOR
-#define DIR_SEPARATOR '/'
+# define DIR_SEPARATOR '/'
+# define PATH_SEPARATOR ':'
 #endif
 
 #if defined (_WIN32) || defined (__MSDOS__) || defined (__DJGPP__) || \
   defined (__OS2__)
-#define HAVE_DOS_BASED_FILE_SYSTEM
-#ifndef DIR_SEPARATOR_2
-#define DIR_SEPARATOR_2 '\\'
-#endif
+# define HAVE_DOS_BASED_FILE_SYSTEM
+# ifndef DIR_SEPARATOR_2
+#  define DIR_SEPARATOR_2 '\\'
+# endif
+# ifndef PATH_SEPARATOR_2
+#  define PATH_SEPARATOR_2 ';'
+# endif
 #endif
 
 #ifndef DIR_SEPARATOR_2
@@ -4741,17 +5017,32 @@ EOF
         (((ch) == DIR_SEPARATOR) || ((ch) == DIR_SEPARATOR_2))
 #endif /* DIR_SEPARATOR_2 */
 
+#ifndef PATH_SEPARATOR_2
+# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR)
+#else /* PATH_SEPARATOR_2 */
+# define IS_PATH_SEPARATOR(ch) ((ch) == PATH_SEPARATOR_2)
+#endif /* PATH_SEPARATOR_2 */
+
 #define XMALLOC(type, num)      ((type *) xmalloc ((num) * sizeof(type)))
 #define XFREE(stale) do { \
   if (stale) { free ((void *) stale); stale = 0; } \
 } while (0)
 
+/* -DDEBUG is fairly common in CFLAGS.  */
+#undef DEBUG
+#if defined DEBUGWRAPPER
+# define DEBUG(format, ...) fprintf(stderr, format, __VA_ARGS__)
+#else
+# define DEBUG(format, ...)
+#endif
+
 const char *program_name = NULL;
 
 void * xmalloc (size_t num);
 char * xstrdup (const char *string);
-char * basename (const char *name);
-char * fnqualify(const char *path);
+const char * base_name (const char *name);
+char * find_executable(const char *wrapper);
+int    check_executable(const char *path);
 char * strendzap(char *str, const char *pat);
 void lt_fatal (const char *message, ...);
 
@@ -4761,29 +5052,50 @@ main (int argc, char *argv[])
   char **newargz;
   int i;
 
-  program_name = (char *) xstrdup ((char *) basename (argv[0]));
+  program_name = (char *) xstrdup (base_name (argv[0]));
+  DEBUG("(main) argv[0]      : %s\n",argv[0]);
+  DEBUG("(main) program_name : %s\n",program_name);
   newargz = XMALLOC(char *, argc+2);
 EOF
 
-	    cat >> $cwrappersource <<EOF
-  newargz[0] = "$SHELL";
+            cat >> $cwrappersource <<EOF
+  newargz[0] = (char *) xstrdup("$SHELL");
 EOF
 
-	    cat >> $cwrappersource <<"EOF"
-  newargz[1] = fnqualify(argv[0]);
+            cat >> $cwrappersource <<"EOF"
+  newargz[1] = find_executable(argv[0]);
+  if (newargz[1] == NULL)
+    lt_fatal("Couldn't find %s", argv[0]);
+  DEBUG("(main) found exe at : %s\n",newargz[1]);
   /* we know the script has the same name, without the .exe */
   /* so make sure newargz[1] doesn't end in .exe */
   strendzap(newargz[1],".exe");
   for (i = 1; i < argc; i++)
     newargz[i+1] = xstrdup(argv[i]);
   newargz[argc+1] = NULL;
+
+  for (i=0; i<argc+1; i++)
+  {
+    DEBUG("(main) newargz[%d]   : %s\n",i,newargz[i]);
+    ;
+  }
+
 EOF
 
-	    cat >> $cwrappersource <<EOF
+            case $host_os in
+              mingw*)
+                cat >> $cwrappersource <<EOF
+  execv("$SHELL",(char const **)newargz);
+EOF
+              ;;
+              *)
+                cat >> $cwrappersource <<EOF
   execv("$SHELL",newargz);
 EOF
+              ;;
+            esac
 
-	    cat >> $cwrappersource <<"EOF"
+            cat >> $cwrappersource <<"EOF"
   return 127;
 }
 
@@ -4804,48 +5116,148 @@ xstrdup (const char *string)
 ;
 }
 
-char *
-basename (const char *name)
+const char *
+base_name (const char *name)
 {
   const char *base;
 
 #if defined (HAVE_DOS_BASED_FILE_SYSTEM)
   /* Skip over the disk name in MSDOS pathnames. */
-  if (isalpha (name[0]) && name[1] == ':')
+  if (isalpha ((unsigned char)name[0]) && name[1] == ':')
     name += 2;
 #endif
 
   for (base = name; *name; name++)
     if (IS_DIR_SEPARATOR (*name))
       base = name + 1;
-  return (char *) base;
+  return base;
 }
 
+int
+check_executable(const char * path)
+{
+  struct stat st;
+
+  DEBUG("(check_executable)  : %s\n", path ? (*path ? path : "EMPTY!") : "NULL!");
+  if ((!path) || (!*path))
+    return 0;
+
+  if ((stat (path, &st) >= 0) &&
+      (
+        /* MinGW & native WIN32 do not support S_IXOTH or S_IXGRP */
+#if defined (S_IXOTH)
+       ((st.st_mode & S_IXOTH) == S_IXOTH) ||
+#endif
+#if defined (S_IXGRP)
+       ((st.st_mode & S_IXGRP) == S_IXGRP) ||
+#endif
+       ((st.st_mode & S_IXUSR) == S_IXUSR))
+      )
+    return 1;
+  else
+    return 0;
+}
+
+/* Searches for the full path of the wrapper.  Returns
+   newly allocated full path name if found, NULL otherwise */
 char *
-fnqualify(const char *path)
+find_executable (const char* wrapper)
 {
-  size_t size;
-  char *p;
+  int has_slash = 0;
+  const char* p;
+  const char* p_next;
+  /* static buffer for getcwd */
   char tmp[LT_PATHMAX + 1];
+  int tmp_len;
+  char* concat_name;
+
+  DEBUG("(find_executable)  : %s\n", wrapper ? (*wrapper ? wrapper : "EMPTY!") : "NULL!");
 
-  assert(path != NULL);
+  if ((wrapper == NULL) || (*wrapper == '\0'))
+    return NULL;
 
-  /* Is it qualified already? */
+  /* Absolute path? */
 #if defined (HAVE_DOS_BASED_FILE_SYSTEM)
-  if (isalpha (path[0]) && path[1] == ':')
-    return xstrdup (path);
+  if (isalpha ((unsigned char)wrapper[0]) && wrapper[1] == ':')
+  {
+    concat_name = xstrdup (wrapper);
+    if (check_executable(concat_name))
+      return concat_name;
+    XFREE(concat_name);
+  }
+  else
+  {
+#endif
+    if (IS_DIR_SEPARATOR (wrapper[0]))
+    {
+      concat_name = xstrdup (wrapper);
+      if (check_executable(concat_name))
+        return concat_name;
+      XFREE(concat_name);
+    }
+#if defined (HAVE_DOS_BASED_FILE_SYSTEM)
+  }
 #endif
-  if (IS_DIR_SEPARATOR (path[0]))
-    return xstrdup (path);
 
-  /* prepend the current directory */
-  /* doesn't handle '~' */
+  for (p = wrapper; *p; p++)
+    if (*p == '/')
+    {
+      has_slash = 1;
+      break;
+    }
+  if (!has_slash)
+  {
+    /* no slashes; search PATH */
+    const char* path = getenv ("PATH");
+    if (path != NULL)
+    {
+      for (p = path; *p; p = p_next)
+      {
+        const char* q;
+        size_t p_len;
+        for (q = p; *q; q++)
+          if (IS_PATH_SEPARATOR(*q))
+            break;
+        p_len = q - p;
+        p_next = (*q == '\0' ? q : q + 1);
+        if (p_len == 0)
+        {
+          /* empty path: current directory */
+          if (getcwd (tmp, LT_PATHMAX) == NULL)
+            lt_fatal ("getcwd failed");
+          tmp_len = strlen(tmp);
+          concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1);
+          memcpy (concat_name, tmp, tmp_len);
+          concat_name[tmp_len] = '/';
+          strcpy (concat_name + tmp_len + 1, wrapper);
+        }
+        else
+        {
+          concat_name = XMALLOC(char, p_len + 1 + strlen(wrapper) + 1);
+          memcpy (concat_name, p, p_len);
+          concat_name[p_len] = '/';
+          strcpy (concat_name + p_len + 1, wrapper);
+        }
+        if (check_executable(concat_name))
+          return concat_name;
+        XFREE(concat_name);
+      }
+    }
+    /* not found in PATH; assume curdir */
+  }
+  /* Relative path | not found in path: prepend cwd */
   if (getcwd (tmp, LT_PATHMAX) == NULL)
     lt_fatal ("getcwd failed");
-  size = strlen(tmp) + 1 + strlen(path) + 1; /* +2 for '/' and '\0' */
-  p = XMALLOC(char, size);
-  sprintf(p, "%s%c%s", tmp, DIR_SEPARATOR, path);
-  return p;
+  tmp_len = strlen(tmp);
+  concat_name = XMALLOC(char, tmp_len + 1 + strlen(wrapper) + 1);
+  memcpy (concat_name, tmp, tmp_len);
+  concat_name[tmp_len] = '/';
+  strcpy (concat_name + tmp_len + 1, wrapper);
+
+  if (check_executable(concat_name))
+    return concat_name;
+  XFREE(concat_name);
+  return NULL;
 }
 
 char *
@@ -4889,16 +5301,16 @@ lt_fatal (const char *message, ...)
   va_end (ap);
 }
 EOF
-	  # we should really use a build-platform specific compiler
-	  # here, but OTOH, the wrappers (shell script and this C one)
-	  # are only useful if you want to execute the "real" binary.
-	  # Since the "real" binary is built for $host, then this
-	  # wrapper might as well be built for $host, too.
-	  $run $LTCC -s -o $cwrapper $cwrappersource
-	  ;;
-	esac
-	$rm $output
-	trap "$rm $output; exit $EXIT_FAILURE" 1 2 15
+          # we should really use a build-platform specific compiler
+          # here, but OTOH, the wrappers (shell script and this C one)
+          # are only useful if you want to execute the "real" binary.
+          # Since the "real" binary is built for $host, then this
+          # wrapper might as well be built for $host, too.
+          $run $LTCC $LTCFLAGS -s -o $cwrapper $cwrappersource
+          ;;
+        esac
+        $rm $output
+        trap "$rm $output; exit $EXIT_FAILURE" 1 2 15
 
 	$echo > $output "\
 #! $SHELL
@@ -4917,6 +5329,20 @@ EOF
 Xsed='${SED} -e 1s/^X//'
 sed_quote_subst='$sed_quote_subst'
 
+# Be Bourne compatible (taken from Autoconf:_AS_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
+
 # The HP-UX ksh and POSIX shell print the target directory to stdout
 # if CDPATH is set.
 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
@@ -5059,7 +5485,7 @@ else
 	  ;;
 	esac
 	$echo >> $output "\
-      \$echo \"\$0: cannot exec \$program \${1+\"\$@\"}\"
+      \$echo \"\$0: cannot exec \$program \$*\"
       exit $EXIT_FAILURE
     fi
   else
@@ -5128,9 +5554,9 @@ fi\
 	    $run ${rm}r "$gentop"
 	    $show "$mkdir $gentop"
 	    $run $mkdir "$gentop"
-	    status=$?
-	    if test "$status" -ne 0 && test ! -d "$gentop"; then
-	      exit $status
+	    exit_status=$?
+	    if test "$exit_status" -ne 0 && test ! -d "$gentop"; then
+	      exit $exit_status
 	    fi
 	  fi
 
@@ -5245,7 +5671,7 @@ fi\
       done
       # Quote the link command for shipping.
       relink_command="(cd `pwd`; $SHELL $progpath $preserve_args --mode=relink $libtool_args @inst_prefix_dir@)"
-      relink_command=`$echo "X$relink_command" | $Xsed -e "$sed_quote_subst"`
+      relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e "$sed_quote_subst" | $NL2SP`
       if test "$hardcode_automatic" = yes ; then
 	relink_command=
       fi
@@ -5590,9 +6016,9 @@ relink_command=\"$relink_command\""
 
 	  if test -n "$inst_prefix_dir"; then
 	    # Stick the inst_prefix_dir data into the link command.
-	    relink_command=`$echo "$relink_command" | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%"`
+	    relink_command=`$echo "$relink_command" | $SP2NL | $SED "s%@inst_prefix_dir@%-inst-prefix-dir $inst_prefix_dir%" | $NL2SP`
 	  else
-	    relink_command=`$echo "$relink_command" | $SED "s%@inst_prefix_dir@%%"`
+	    relink_command=`$echo "$relink_command" | $SP2NL | $SED "s%@inst_prefix_dir@%%" | $NL2SP`
 	  fi
 
 	  $echo "$modename: warning: relinking \`$file'" 1>&2
@@ -5797,22 +6223,11 @@ relink_command=\"$relink_command\""
 	  outputname=
 	  if test "$fast_install" = no && test -n "$relink_command"; then
 	    if test "$finalize" = yes && test -z "$run"; then
-	      tmpdir="/tmp"
-	      test -n "$TMPDIR" && tmpdir="$TMPDIR"
-	      tmpdir="$tmpdir/libtool-$$"
-	      save_umask=`umask`
-	      umask 0077
-	      if $mkdir "$tmpdir"; then
-	        umask $save_umask
-	      else
-	        umask $save_umask
-		$echo "$modename: error: cannot create temporary directory \`$tmpdir'" 1>&2
-		continue
-	      fi
+	      tmpdir=`func_mktempdir`
 	      file=`$echo "X$file$stripped_ext" | $Xsed -e 's%^.*/%%'`
 	      outputname="$tmpdir/$file"
 	      # Replace the output file specification.
-	      relink_command=`$echo "X$relink_command" | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g'`
+	      relink_command=`$echo "X$relink_command" | $SP2NL | $Xsed -e 's%@OUTPUT@%'"$outputname"'%g' | $NL2SP`
 
 	      $show "$relink_command"
 	      if $run eval "$relink_command"; then :
@@ -5932,7 +6347,7 @@ relink_command=\"$relink_command\""
     # Exit here if they wanted silent mode.
     test "$show" = : && exit $EXIT_SUCCESS
 
-    $echo "----------------------------------------------------------------------"
+    $echo "X----------------------------------------------------------------------" | $Xsed
     $echo "Libraries have been installed in:"
     for libdir in $libdirs; do
       $echo "   $libdir"
@@ -5965,7 +6380,7 @@ relink_command=\"$relink_command\""
     $echo
     $echo "See any operating system documentation about shared libraries for"
     $echo "more information, such as the ld(1) and ld.so(8) manual pages."
-    $echo "----------------------------------------------------------------------"
+    $echo "X----------------------------------------------------------------------" | $Xsed
     exit $EXIT_SUCCESS
     ;;
 
@@ -6023,8 +6438,10 @@ relink_command=\"$relink_command\""
 	if test -f "$dir/$objdir/$dlname"; then
 	  dir="$dir/$objdir"
 	else
-	  $echo "$modename: cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" 1>&2
-	  exit $EXIT_FAILURE
+	  if test ! -f "$dir/$dlname"; then
+	    $echo "$modename: cannot find \`$dlname' in \`$dir' or \`$dir/$objdir'" 1>&2
+	    exit $EXIT_FAILURE
+	  fi
 	fi
 	;;
 
@@ -6088,12 +6505,12 @@ relink_command=\"$relink_command\""
       fi
 
       # Restore saved environment variables
-      if test "${save_LC_ALL+set}" = set; then
-	LC_ALL="$save_LC_ALL"; export LC_ALL
-      fi
-      if test "${save_LANG+set}" = set; then
-	LANG="$save_LANG"; export LANG
-      fi
+      for lt_var in LANG LANGUAGE LC_ALL LC_CTYPE LC_COLLATE LC_MESSAGES
+      do
+	eval "if test \"\${save_$lt_var+set}\" = set; then
+		$lt_var=\$save_$lt_var; export $lt_var
+	      fi"
+      done
 
       # Now prepare to actually exec the command.
       exec_cmd="\$cmd$args"
@@ -6182,9 +6599,17 @@ relink_command=\"$relink_command\""
 	    rmfiles="$rmfiles $objdir/$n"
 	  done
 	  test -n "$old_library" && rmfiles="$rmfiles $objdir/$old_library"
-	  test "$mode" = clean && rmfiles="$rmfiles $objdir/$name $objdir/${name}i"
 
-	  if test "$mode" = uninstall; then
+	  case "$mode" in
+	  clean)
+	    case "  $library_names " in
+	    # "  " in the beginning catches empty $dlname
+	    *" $dlname "*) ;;
+	    *) rmfiles="$rmfiles $objdir/$dlname" ;;
+	    esac
+	     test -n "$libdir" && rmfiles="$rmfiles $objdir/$name $objdir/${name}i"
+	    ;;
+	  uninstall)
 	    if test -n "$library_names"; then
 	      # Do each command in the postuninstall commands.
 	      cmds=$postuninstall_cmds
@@ -6217,7 +6642,8 @@ relink_command=\"$relink_command\""
 	      IFS="$save_ifs"
 	    fi
 	    # FIXME: should reinstall the best remaining shared library.
-	  fi
+	    ;;
+	  esac
 	fi
 	;;
 
@@ -6441,9 +6867,9 @@ The following components of LINK-COMMAND are treated specially:
   -dlpreopen FILE   link in FILE and add its symbols to lt_preloaded_symbols
   -export-dynamic   allow symbols from OUTPUT-FILE to be resolved with dlsym(3)
   -export-symbols SYMFILE
-		    try to export only the symbols listed in SYMFILE
+                    try to export only the symbols listed in SYMFILE
   -export-symbols-regex REGEX
-		    try to export only the symbols matching REGEX
+                    try to export only the symbols matching REGEX
   -LLIBDIR          search LIBDIR for required installed libraries
   -lNAME            OUTPUT-FILE requires the installed library libNAME
   -module           build a library that can dlopened
@@ -6457,9 +6883,11 @@ The following components of LINK-COMMAND are treated specially:
   -release RELEASE  specify package release information
   -rpath LIBDIR     the created library will eventually be installed in LIBDIR
   -R[ ]LIBDIR       add LIBDIR to the runtime path of programs and libraries
-  -static           do not do any dynamic linking of libtool libraries
+  -static           do not do any dynamic linking of uninstalled libtool libraries
+  -static-libtool-libs
+                    do not do any dynamic linking of libtool libraries
   -version-info CURRENT[:REVISION[:AGE]]
-		    specify library version info [each variable defaults to 0]
+                    specify library version info [each variable defaults to 0]
 
 All other options (arguments beginning with \`-') are ignored.
 
@@ -6516,12 +6944,11 @@ exit $?
 # configuration.  But we'll never go from static-only to shared-only.
 
 # ### BEGIN LIBTOOL TAG CONFIG: disable-shared
-build_libtool_libs=no
-build_old_libs=yes
+disable_libs=shared
 # ### END LIBTOOL TAG CONFIG: disable-shared
 
 # ### BEGIN LIBTOOL TAG CONFIG: disable-static
-build_old_libs=`case $build_libtool_libs in yes) $echo no;; *) $echo yes;; esac`
+disable_libs=static
 # ### END LIBTOOL TAG CONFIG: disable-static
 
 # Local Variables:
diff --git a/main/build-defs.h.in b/main/build-defs.h.in
index 912cc08..43f3614 100644
--- a/main/build-defs.h.in
+++ b/main/build-defs.h.in
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: build-defs.h.in 239769 2007-07-15 15:10:04Z jani $ */
+/* $Id: build-defs.h.in 292156 2009-12-15 11:17:47Z jani $ */
 
 #define CONFIGURE_COMMAND "@CONFIGURE_COMMAND@"
 #define PHP_ADA_INCLUDE		""
@@ -80,6 +80,7 @@
 #define PHP_EXTENSION_DIR       "@EXPANDED_EXTENSION_DIR@"
 #define PHP_PREFIX              "@prefix@"
 #define PHP_BINDIR              "@EXPANDED_BINDIR@"
+#define PHP_SBINDIR             "@EXPANDED_SBINDIR@"
 #define PHP_LIBDIR              "@EXPANDED_LIBDIR@"
 #define PHP_DATADIR             "@EXPANDED_DATADIR@"
 #define PHP_SYSCONFDIR          "@EXPANDED_SYSCONFDIR@"
diff --git a/main/internal_functions_nw.c b/main/internal_functions_nw.c
index f28461a..9a99715 100644
--- a/main/internal_functions_nw.c
+++ b/main/internal_functions_nw.c
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: internal_functions_nw.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: internal_functions_nw.c 290185 2009-11-03 19:03:49Z guenter $ */
 
 /* {{{ includes
  */
@@ -38,7 +38,7 @@
 #include "ext/standard/head.h"
 #include "ext/standard/pack.h"
 #include "ext/standard/php_browscap.h"
-/*#include "ext/standard/php_crypt.h"*/
+#include "ext/standard/php_crypt.h"
 #include "ext/standard/php_dir.h"
 #include "ext/standard/php_filestat.h"
 #include "ext/standard/php_mail.h"
@@ -48,16 +48,25 @@
 #include "ext/standard/php_array.h"
 #include "ext/standard/php_assert.h"
 #include "ext/calendar/php_calendar.h"
+#include "ext/date/php_date.h"
 /*#include "ext/com/php_COM.h"
 #include "ext/com/php_VARIANT.h"*/
 #include "ext/ftp/php_ftp.h"
 #include "ext/standard/reg.h"
+#include "ext/netware/php_netware.h"
 #include "ext/pcre/php_pcre.h"
+#include "ext/reflection/php_reflection.h"
 /*#include "ext/odbc/php_odbc.h"*/	/* Commented out for now */
 #include "ext/session/php_session.h"
 /*#include "ext/xml/php_xml.h"
 #include "ext/wddx/php_wddx.h"
 #include "ext/mysql/php_mysql.h"*/	/* Commented out for now */
+#if HAVE_OPENSSL_EXT
+#include "ext/openssl/php_openssl.h"
+#endif
+#if HAVE_ZLIB
+#include "ext/zlib/php_zlib.h"
+#endif
 /* }}} */
 
 /* {{{ php_builtin_extensions[]
@@ -68,17 +77,26 @@ static zend_module_entry *php_builtin_extensions[] = {
 	phpext_bcmath_ptr,
 #endif
 	phpext_calendar_ptr,
+	phpext_date_ptr,
 /*	COM_module_ptr,*/
 	phpext_ftp_ptr,
 #if defined(MBSTR_ENC_TRANS)
 	phpext_mbstring_ptr,
 #endif
 /*	phpext_mysql_ptr,*/	/* Commented out for now */
+#if HAVE_OPENSSL_EXT
+	phpext_openssl_ptr,
+#endif
 /*	phpext_odbc_ptr, */	/* Commented out for now */
 	phpext_pcre_ptr,
+	phpext_reflection_ptr,
 	phpext_session_ptr,
 /*	phpext_xml_ptr,
 	phpext_wddx_ptr */	/* Commented out for now */
+#if HAVE_ZLIB
+	phpext_zlib_ptr,
+#endif
+	phpext_netware_ptr
 };
 /* }}} */
 
diff --git a/main/main.c b/main/main.c
index 320dcb4..3785b55 100644
--- a/main/main.c
+++ b/main/main.c
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: main.c 283946 2009-07-12 16:42:16Z iliaa $ */
+/* $Id: main.c 291871 2009-12-08 10:16:38Z dmitry $ */
 
 /* {{{ includes
  */
@@ -204,12 +204,13 @@ static void php_disable_classes(TSRMLS_D)
  */
 static PHP_INI_MH(OnUpdateTimeout)
 {
-	EG(timeout_seconds) = atoi(new_value);
 	if (stage==PHP_INI_STAGE_STARTUP) {
 		/* Don't set a timeout on startup, only per-request */
+		EG(timeout_seconds) = atoi(new_value);
 		return SUCCESS;
 	}
 	zend_unset_timeout(TSRMLS_C);
+	EG(timeout_seconds) = atoi(new_value);
 	zend_set_timeout(EG(timeout_seconds));
 	return SUCCESS;
 }
@@ -452,6 +453,7 @@ PHP_INI_BEGIN()
 	PHP_INI_ENTRY("mail.force_extra_parameters",NULL,		PHP_INI_SYSTEM|PHP_INI_PERDIR,		OnChangeMailForceExtra)
 	PHP_INI_ENTRY("disable_functions",			"",			PHP_INI_SYSTEM,		NULL)
 	PHP_INI_ENTRY("disable_classes",			"",			PHP_INI_SYSTEM,		NULL)
+	PHP_INI_ENTRY("max_file_uploads",			"20",			PHP_INI_SYSTEM,		NULL)
 
 	STD_PHP_INI_BOOLEAN("allow_url_fopen",		"1",		PHP_INI_SYSTEM,		OnUpdateBool,		allow_url_fopen,		php_core_globals,	core_globals)
 	STD_PHP_INI_BOOLEAN("allow_url_include",	"0",		PHP_INI_SYSTEM,		OnUpdateBool,		allow_url_include,		php_core_globals,	core_globals)
@@ -489,11 +491,18 @@ PHPAPI void php_log_err(char *log_message TSRMLS_DC)
 	int fd = -1;
 	time_t error_time;
 
+	if (PG(in_error_log)) {
+		/* prevent recursive invocation */
+		return;
+	}
+	PG(in_error_log) = 1;
+
 	/* Try to use the specified logging location. */
 	if (PG(error_log) != NULL) {
 #ifdef HAVE_SYSLOG_H
 		if (!strcmp(PG(error_log), "syslog")) {
 			php_syslog(LOG_NOTICE, "%.500s", log_message);
+			PG(in_error_log) = 0;
 			return;
 		}
 #endif
@@ -504,7 +513,7 @@ PHPAPI void php_log_err(char *log_message TSRMLS_DC)
 			char *error_time_str;
 
 			time(&error_time);
-			error_time_str = php_format_date("d-M-Y H:i:s", 11, error_time, php_during_module_startup() TSRMLS_CC);
+			error_time_str = php_format_date("d-M-Y H:i:s", 11, error_time, 1 TSRMLS_CC);
 			len = spprintf(&tmp, 0, "[%s] %s%s", error_time_str, log_message, PHP_EOL);
 #ifdef PHP_WIN32
 			php_flock(fd, 2);
@@ -513,6 +522,7 @@ PHPAPI void php_log_err(char *log_message TSRMLS_DC)
 			efree(tmp);
 			efree(error_time_str);
 			close(fd);
+			PG(in_error_log) = 0;
 			return;
 		}
 	}
@@ -522,6 +532,7 @@ PHPAPI void php_log_err(char *log_message TSRMLS_DC)
 	if (sapi_module.log_message) {
 		sapi_module.log_message(log_message);
 	}
+	PG(in_error_log) = 0;
 }
 /* }}} */
 
@@ -823,6 +834,9 @@ static void php_error_cb(int type, const char *error_filename, const uint error_
 		if (PG(last_error_file)) {
 			free(PG(last_error_file));
 		}
+		if (!error_filename) {
+			error_filename = "Unknown";
+		}
 		PG(last_error_type) = type;
 		PG(last_error_message) = strdup(buffer);
 		PG(last_error_file) = strdup(error_filename);
@@ -1255,6 +1269,7 @@ int php_request_startup(TSRMLS_D)
 #endif
 
 	zend_try {
+		PG(in_error_log) = 0;
 		PG(during_request_startup) = 1;
 
 		php_output_activate(TSRMLS_C);
@@ -1979,6 +1994,7 @@ PHPAPI int php_execute_script(zend_file_handle *primary_file TSRMLS_DC)
 		 *   otherwise it will get opened and added to the included_files list in zend_execute_scripts
 		 */
  		if (primary_file->filename &&
+ 		    (primary_file->filename[0] != '-' || primary_file->filename[1] != 0) &&
  			primary_file->opened_path == NULL &&
  			primary_file->type != ZEND_HANDLE_FILENAME
 		) {
diff --git a/main/network.c b/main/network.c
index 4ac6333..5575205 100644
--- a/main/network.c
+++ b/main/network.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: network.c 288034 2009-09-04 07:59:48Z srinatar $ */
+/* $Id: network.c 289019 2009-09-30 20:48:41Z iliaa $ */
 
 /*#define DEBUG_MAIN_NETWORK 1*/
 
@@ -786,7 +786,7 @@ php_socket_t php_network_connect_socket_to_host(const char *host, unsigned short
 		switch (sa->sa_family) {
 #if HAVE_GETADDRINFO && HAVE_IPV6
 			case AF_INET6:
-				if (bindto && strchr(bindto, ':')) {
+				if (!bindto || strchr(bindto, ':')) {
 					((struct sockaddr_in6 *)sa)->sin6_family = sa->sa_family;
 					((struct sockaddr_in6 *)sa)->sin6_port = htons(port);
 					socklen = sizeof(struct sockaddr_in6);
diff --git a/main/output.c b/main/output.c
index 56ce6c1..052a105 100644
--- a/main/output.c
+++ b/main/output.c
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: output.c 277793 2009-03-26 00:00:18Z cseiler $ */
+/* $Id: output.c 288518 2009-09-21 11:22:13Z dmitry $ */
 
 #include "php.h"
 #include "ext/standard/head.h"
@@ -227,8 +227,6 @@ PHPAPI void php_end_ob_buffer(zend_bool send_buffer, zend_bool just_flush TSRMLS
 
 		ALLOC_INIT_ZVAL(orig_buffer);
 		ZVAL_STRINGL(orig_buffer, OG(active_ob_buffer).buffer, OG(active_ob_buffer).text_length, 1);
-		orig_buffer->refcount=2;	/* don't let call_user_function() destroy our buffer */
-		orig_buffer->is_ref=1;
 
 		ALLOC_INIT_ZVAL(z_status);
 		ZVAL_LONG(z_status, status);
@@ -248,11 +246,7 @@ PHPAPI void php_end_ob_buffer(zend_bool send_buffer, zend_bool just_flush TSRMLS
 		if (!just_flush) {
 			zval_ptr_dtor(&OG(active_ob_buffer).output_handler);
 		}
-		orig_buffer->refcount -=2;
-		if (orig_buffer->refcount <= 0) { /* free the zval */
-			zval_dtor(orig_buffer);
-			FREE_ZVAL(orig_buffer);
-		}
+		zval_ptr_dtor(&orig_buffer);
 		zval_ptr_dtor(&z_status);
 	}
 
diff --git a/main/php_config.h.in b/main/php_config.h.in
index e5bff3b..cfb2f40 100644
--- a/main/php_config.h.in
+++ b/main/php_config.h.in
@@ -335,6 +335,9 @@
 /* Define if you have the link function.  */
 #undef HAVE_LINK
 
+/* Define if you have the llabs function.  */
+#undef HAVE_LLABS
+
 /* Define if you have the localeconv function.  */
 #undef HAVE_LOCALECONV
 
@@ -596,6 +599,9 @@
 /* Define if you have the <arpa/nameser.h> header file.  */
 #undef HAVE_ARPA_NAMESER_H
 
+/* Define if you have the <arpa/nameser_compat.h> header file.  */
+#undef HAVE_ARPA_NAMESER_COMPAT_H
+
 /* Define if you have the <assert.h> header file.  */
 #undef HAVE_ASSERT_H
 
@@ -1139,6 +1145,12 @@
 /* Whether struct sockaddr has field sa_len */
 #undef HAVE_SOCKADDR_SA_LEN
 
+/*   */
+#undef HAVE_NANOSLEEP
+
+/*   */
+#undef HAVE_LIBRT
+
 /* Define if you have the getaddrinfo function */
 #undef HAVE_GETADDRINFO
 
diff --git a/main/php_globals.h b/main/php_globals.h
index 3ccaf86..46c7c93 100644
--- a/main/php_globals.h
+++ b/main/php_globals.h
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: php_globals.h 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: php_globals.h 289214 2009-10-05 13:56:49Z dmitry $ */
 
 #ifndef PHP_GLOBALS_H
 #define PHP_GLOBALS_H
@@ -161,6 +161,7 @@ struct _php_core_globals {
 #endif
 	long max_input_nesting_level;
 	zend_bool in_user_include;
+	zend_bool in_error_log;
 };
 
 
diff --git a/main/php_version.h b/main/php_version.h
index 1c11828..24b275a 100644
--- a/main/php_version.h
+++ b/main/php_version.h
@@ -2,7 +2,7 @@
 /* edit configure.in to change version number */
 #define PHP_MAJOR_VERSION 5
 #define PHP_MINOR_VERSION 2
-#define PHP_RELEASE_VERSION 11
+#define PHP_RELEASE_VERSION 12
 #define PHP_EXTRA_VERSION ""
-#define PHP_VERSION "5.2.11"
-#define PHP_VERSION_ID 50211
+#define PHP_VERSION "5.2.12"
+#define PHP_VERSION_ID 50212
diff --git a/main/rfc1867.c b/main/rfc1867.c
index bae45e7..42f396f 100644
--- a/main/rfc1867.c
+++ b/main/rfc1867.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: rfc1867.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: rfc1867.c 290885 2009-11-17 20:33:51Z rasmus $ */
 
 /*
  *  This product includes software developed by the Apache Group
@@ -32,6 +32,7 @@
 #include "php_globals.h"
 #include "php_variables.h"
 #include "rfc1867.h"
+#include "php_ini.h"
 
 #define DEBUG_FILE_UPLOAD ZEND_DEBUG
 
@@ -794,8 +795,9 @@ SAPI_API SAPI_POST_HANDLER_FUNC(rfc1867_post_handler)
 	zend_llist header;
 	void *event_extra_data = NULL;
 	int llen = 0;
+	int upload_cnt = INI_INT("max_file_uploads");
 
-	if (SG(request_info).content_length > SG(post_max_size)) {
+	if (SG(post_max_size) > 0 && SG(request_info).content_length > SG(post_max_size)) {
 		sapi_module.sapi_error(E_WARNING, "POST Content-Length of %ld bytes exceeds the limit of %ld bytes", SG(request_info).content_length, SG(post_max_size));
 		return;
 	}
@@ -972,6 +974,9 @@ SAPI_API SAPI_POST_HANDLER_FUNC(rfc1867_post_handler)
 			/* If file_uploads=off, skip the file part */
 			if (!PG(file_uploads)) {
 				skip_upload = 1;
+			} else if (upload_cnt <= 0) {
+				skip_upload = 1;
+				sapi_module.sapi_error(E_WARNING, "Maximum number of allowable file uploads has been exceeded");
 			}
 
 			/* Return with an error if the posted data is garbled */
@@ -1016,6 +1021,7 @@ SAPI_API SAPI_POST_HANDLER_FUNC(rfc1867_post_handler)
 			if (!skip_upload) {
 				/* Handle file */
 				fd = php_open_temporary_fd_ex(PG(upload_tmp_dir), "php", &temp_filename, 1 TSRMLS_CC);
+				upload_cnt--;
 				if (fd==-1) {
 					sapi_module.sapi_error(E_WARNING, "File upload error - unable to create a temporary file");
 					cancel_upload = UPLOAD_ERROR_E;
diff --git a/main/streams/memory.c b/main/streams/memory.c
index 95b054d..64c173a 100644
--- a/main/streams/memory.c
+++ b/main/streams/memory.c
@@ -16,7 +16,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: memory.c 280638 2009-05-16 20:28:02Z lbarnaud $ */
+/* $Id: memory.c 288393 2009-09-17 02:45:25Z srinatar $ */
 
 #define _GNU_SOURCE
 #include "php.h"
@@ -563,7 +563,7 @@ PHPAPI php_stream *_php_stream_temp_create(int mode, size_t max_memory_usage STR
 	stream = php_stream_alloc_rel(&php_stream_temp_ops, self, 0, mode & TEMP_STREAM_READONLY ? "rb" : "w+b");
 	stream->flags |= PHP_STREAM_FLAG_NO_BUFFER;
 	self->innerstream = php_stream_memory_create_rel(mode);
-	php_stream_auto_cleanup(self->innerstream); // do not warn if innerstream is GC'ed before stream
+	php_stream_auto_cleanup(self->innerstream); /* do not warn if innerstream is GC'ed before stream */
 	((php_stream_memory_data*)self->innerstream->abstract)->owner_ptr = &self->innerstream;
 
 	return stream;
diff --git a/main/streams/xp_socket.c b/main/streams/xp_socket.c
index edc028a..93dd4b6 100644
--- a/main/streams/xp_socket.c
+++ b/main/streams/xp_socket.c
@@ -16,7 +16,7 @@
   +----------------------------------------------------------------------+
 */
 
-/* $Id: xp_socket.c 288034 2009-09-04 07:59:48Z srinatar $ */
+/* $Id: xp_socket.c 288604 2009-09-23 10:25:54Z dmitry $ */
 
 #include "php.h"
 #include "ext/standard/file.h"
@@ -289,7 +289,7 @@ static int php_sockop_set_option(php_stream *stream, int option, int value, void
 				if (sock->socket == -1) {
 					alive = 0;
 				} else if (php_pollfd_for(sock->socket, PHP_POLLREADABLE|POLLPRI, &tv) > 0) {
-					if (recv(sock->socket, &buf, sizeof(buf), MSG_PEEK) != SOCK_CONN_ERR && php_socket_errno() != EWOULDBLOCK) {
+					if (0 >= recv(sock->socket, &buf, sizeof(buf), MSG_PEEK) && php_socket_errno() != EWOULDBLOCK) {
 						alive = 0;
 					}
 				}
diff --git a/pear/fetch.php b/pear/fetch.php
index 01d2233..62c436a 100644
--- a/pear/fetch.php
+++ b/pear/fetch.php
@@ -61,7 +61,12 @@ if (!isset($_ENV['http_proxy'])) {
     );
 }
 
-$ctx = stream_context_create($copt, array("notification" => "stream_notification_callback"));
+if ($copt) {
+	$ctx = stream_context_create($copt);
+} else {
+	$ctx = stream_context_create();
+}
+stream_context_set_params($ctx, array("notification" => "stream_notification_callback"));
 
 $fp = fopen($argv[1], "r", false, $ctx);
 if (is_resource($fp) && file_put_contents($argv[2], $fp)) {
diff --git a/pear/install-pear-nozlib.phar b/pear/install-pear-nozlib.phar
index 81f77eb..3342448 100644
--- a/pear/install-pear-nozlib.phar
+++ b/pear/install-pear-nozlib.phar
@@ -1234,27 +1234,54 @@ if (extension_loaded('phar')) {if (isset($_SERVER) && isset($_SERVER['REQUEST_UR
 
 
 require_once 'phar://install-pear-nozlib.phar/index.php';
-__HALT_COMPILER();Ú
  E          install-pear-nozlib.phar       Archive/Tar.phpýî  +ŸâIýî  rdIóm         Archive_Tar-1.3.3.tar v +ŸâI v `	•m         Console/Getopt.phpô(  +ŸâIô(  =¡¶m         Console_Getopt-1.2.3.tar F  +ŸâI F  ÆYxÕm      	   index.phpã$  +ŸâIã$   ±$m         OS/Guess.phpÄ)  +ŸâIÄ)  ë	yñm         PEAR-1.8.0.tar < +ŸâI < f;m         PEAR.phpì‹  +ŸâIì‹  Õ$8Mm         PEAR/ChannelFile.phpÆ  +ŸâIÆ  ;]Rêm         PEAR/ChannelFile/Parser.php>  +ŸâI>  r×·“m         PEAR/Command.php62  +ŸâI62  Ø{~m         PEAR/Command/Common.phpŒ   +ŸâIŒ   ½ñ˜m         PEAR/Command/Install.php¿Å  +ŸâI¿Å  ¶?Rbm         PEAR/Command/Install.xml~!  +ŸâI~!  áW_Em         PEAR/Common.php#i  +ŸâI#i  „fà4m         PEAR/Config.phpª	 +ŸâIª	 P
¦ m         PEAR/Dependency2.phpLÆ  +ŸâILÆ  7+‡m         PEAR/DependencyDB.phpª_  +ŸâIª_  ïŽm         PEAR/Downloader.php +ŸâI Jâ
 m         PEAR/Downloader/Package.php´+ +ŸâI´+ ¯NÔ"m         PEAR/ErrorStack.php­ˆ  +ŸâI­ˆ  b!ém         PEAR/Frontend.phpJ  +ŸâIJ  à`ƒm         PEAR/Frontend/CLI.phpÊa  +ŸâIÊa  “·”m         PEAR/Installer.php* +ŸâI* Çü³m         PEAR/Installer/Role.php¹   +ŸâI¹   bCiïm         PEAR/Installer/Role/Common.phpž  +ŸâIž  Òt]€m         PEAR/Installer/Role/Data.phpp  +ŸâIp  à[rm         PEAR/Installer/Role/Data.xml’  +ŸâI’  fszm         PEAR/Installer/Role/Doc.phpm  +ŸâIm  µîæm         PEAR/Installer/Role/Doc.xml‘  +ŸâI‘  h&P*m         PEAR/Installer/Role/Php.phpm  +ŸâIm  «Ÿ m         PEAR/Installer/Role/Php.xml­  +ŸâI­  zqm         PEAR/Installer/Role/Script.phpv  +ŸâIv  Òê|m         PEAR/Installer/Role/Script.xml°  +ŸâI°  @v§Ðm         PEAR/Installer/Role/Test.phpp  +ŸâIp  }aòˆm         PEAR/Installer/Role/Test.xml’  +ŸâI’  B] m         PEAR/PackageFile.php @  +ŸâI @  u´lAm      !   PEAR/PackageFile/Generator/v1.php›Å  +ŸâI›Å  7Ÿ|Öm      !   PEAR/PackageFile/Generator/v2.phpƒ  +ŸâIƒ  T)+lm         PEAR/PackageFile/Parser/v1.phpï@  +ŸâIï@  yU3m         PEAR/PackageFile/Parser/v2.phpÕ  +ŸâIÕ  ï´“m         PEAR/PackageFile/v1.php®Î  +ŸâI®Î  p·‘m         PEAR/PackageFile/v2.php¦ +ŸâI¦ ÒÍÝ®m      !   PEAR/PackageFile/v2/Validator.php%P +ŸâI%P hsÁRm         PEAR/Registry.phpc0 +ŸâIc0 gx³‚m      
   PEAR/REST.php´<  +ŸâI´<  Û
Í*m         PEAR/REST/10.php
  +ŸâI
  ž™%ãm         PEAR/Start.phpÝ6  +ŸâIÝ6  ¡=ðm         PEAR/Start/CLI.phpÅQ  +ŸâIÅQ  w
-Žm         PEAR/Task/Common.php  +ŸâI  ]7b€m         PEAR/Task/Postinstallscript.phpŸ8  +ŸâIŸ8  ýªYœm      "   PEAR/Task/Postinstallscript/rw.phpñ  +ŸâIñ  ¥ž$m         PEAR/Task/Replace.php  +ŸâI  ]> m         PEAR/Task/Replace/rw.php°  +ŸâI°  ±œ}m         PEAR/Task/Unixeol.php		  +ŸâI		  ¤ÂÎym         PEAR/Task/Unixeol/rw.php»  +ŸâI»  Útöm         PEAR/Task/Windowseol.php	  +ŸâI	  u(žÉm         PEAR/Task/Windowseol/rw.phpÐ  +ŸâIÐ  £BX‹m         PEAR/Validate.phpzV  +ŸâIzV  -åÄm         PEAR/Validator/PECL.php¥  +ŸâI¥  Hëm         PEAR/XMLParser.phpô  +ŸâIô  €heÜm         Structures/Graph.php½  +ŸâI½  rÀ*m      ,   Structures/Graph/Manipulator/AcyclicTest.phpß  +ŸâIß  1sÏm      2   Structures/Graph/Manipulator/TopologicalSorter.phpº  +ŸâIº  ¥Eûm         Structures/Graph/Node.phpé*  +ŸâIé*  úT¯æm         Structures_Graph-1.0.2.tar X +ŸâI X 'ß(Ám      
-   System.phpLN  +ŸâILN  OÊÞjm         XML/Util.phpÇv  +ŸâIÇv  ¥°m         XML_Util-1.2.1.tar â +ŸâI â 7l \m      <?php
-/* vim: set ts=4 sw=4: */
-// +----------------------------------------------------------------------+
-// | PHP Version 4                                                        |
-// +----------------------------------------------------------------------+
-// | Copyright (c) 1997-2003 The PHP Group                                |
-// +----------------------------------------------------------------------+
-// | This source file is subject to version 3.0 of the PHP license,       |
-// | that is bundled with this package in the file LICENSE, and is        |
-// | available through the world-wide-web at the following url:           |
-// | http://www.php.net/license/3_0.txt.                                  |
-// | If you did not receive a copy of the PHP license and are unable to   |
-// | obtain it through the world-wide-web, please send a note to          |
-// | license at php.net so we can mail you a copy immediately.               |
-// +----------------------------------------------------------------------+
-// | Author: Vincent Blavet <vincent at phpconcept.net>                      |
-// +----------------------------------------------------------------------+
-//
-// $Id: Tar.php,v 1.24 2007/01/06 04:03:32 cellog Exp $
+__HALT_COMPILER();ÿ
  F          install-pear-nozlib.phar       Archive/Tar.php	ö  8£J	ö  wÈöm         Archive_Tar-1.3.3.tar v 8£J v `	•m         Console/Getopt.php_2  8£J_2  ó<wÅm         Console_Getopt-1.2.3.tar F  8£J F  ÆYxÕm      	   index.php7&  8£J7&  T°„8m         OS/Guess.phpÁ)  8£JÁ)  äõä³m         PEAR-1.9.0.tar R 8£J R 솕
+m         PEAR.php®‡  8£J®‡  ój¶ºm         PEAR/ChannelFile.phpîÇ  8£JîÇ  ¤Pwåm         PEAR/ChannelFile/Parser.php<  8£J<  5†©øm         PEAR/Command.php
+2  8£J
+2  À4	£m         PEAR/Command/Common.php‰   8£J‰   ¾m¤ym         PEAR/Command/Install.phpÇ  8£JÇ  ú1ëm         PEAR/Command/Install.xml~!  8£J~!  2¡Vm         PEAR/Common.phpf  8£Jf  +qÙm         PEAR/Config.php-
+ 8£J-
+ xr©m         PEAR/Dependency2.phpÆ  8£JÆ  ãl³\m         PEAR/DependencyDB.phpø^  8£Jø^  œä€©m         PEAR/Downloader.php5 8£J5 Ní…ªm         PEAR/Downloader/Package.php|- 8£J|- º˜ª"m         PEAR/ErrorStack.php΄  8£J΄  †K1m         PEAR/Frontend.phpd  8£Jd  ¦Æcm         PEAR/Frontend/CLI.phpÇa  8£JÇa  Ì(_[m         PEAR/Installer.php? 8£J? û3 Ÿm         PEAR/Installer/Role.php£  8£J£  ´]øÉm         PEAR/Installer/Role/Common.php›  8£J›  ’ Hm         PEAR/Installer/Role/Data.phpS  8£JS  0Ðm         PEAR/Installer/Role/Data.xml’  8£J’  fszm         PEAR/Installer/Role/Doc.phpP  8£JP  ›¦­*m         PEAR/Installer/Role/Doc.xml‘  8£J‘  h&P*m         PEAR/Installer/Role/Php.phpP  8£JP  änâm         PEAR/Installer/Role/Php.xml­  8£J­  zqm         PEAR/Installer/Role/Script.phpY  8£JY  Ði…sm         PEAR/Installer/Role/Script.xml°  8£J°  @v§Ðm         PEAR/Installer/Role/Test.phpS  8£JS   cÕÃm         PEAR/Installer/Role/Test.xml’  8£J’  B] m         PEAR/PackageFile.phpï?  8£Jï?  QÂvm      !   PEAR/PackageFile/Generator/v1.phpvÅ  8£JvÅ  EåXxm      !   PEAR/PackageFile/Generator/v2.php_ƒ  8£J_ƒ  sþëm         PEAR/PackageFile/Parser/v1.phpì@  8£Jì@  ¿šû m         PEAR/PackageFile/Parser/v2.phpÒ  8£JÒ  %^jfm         PEAR/PackageFile/v1.php_È  8£J_È  ]´0m         PEAR/PackageFile/v2.php¢ 8£J¢ Þ m      !   PEAR/PackageFile/v2/Validator.php!P 8£J!P Åam         PEAR/Registry.php8+ 8£J8+ E¯¬¯m      
   PEAR/REST.php…<  8£J…<  SÕœm         PEAR/REST/10.phpô  8£Jô  ŠýÂØm         PEAR/Start.phpÝ6  8£JÝ6  ¡=ðm         PEAR/Start/CLI.phpÅQ  8£JÅQ  w
+Žm         PEAR/Task/Common.php  8£J  t8m         PEAR/Task/Postinstallscript.phpœ8  8£Jœ8   ”­•m      "   PEAR/Task/Postinstallscript/rw.phpî  8£Jî  ^˜<m         PEAR/Task/Replace.php¿  8£J¿   $m         PEAR/Task/Replace/rw.phpr  8£Jr  é-”üm         PEAR/Task/Unixeol.php	  8£J	  dj6\m         PEAR/Task/Unixeol/rw.php‚  8£J‚  ç¡‚!m         PEAR/Task/Windowseol.php	  8£J	  …Em         PEAR/Task/Windowseol/rw.php—  8£J—  D8Gm         PEAR/Validate.phpwV  8£JwV  AÕ³m         PEAR/Validator/PECL.php¢  8£J¢  KÅ›Øm         PEAR/XMLParser.phpK  8£JK  •uË–m      	   PEAR5.php?  8£J?  ßxÊm         Structures/Graph.php½  8£J½  rÀ*m      ,   Structures/Graph/Manipulator/AcyclicTest.phpß  8£Jß  1sÏm      2   Structures/Graph/Manipulator/TopologicalSorter.phpº  8£Jº  ¥Eûm         Structures/Graph/Node.phpé*  8£Jé*  úT¯æm         Structures_Graph-1.0.2.tar X 8£J X 'ß(Ám      
+   System.phpIN  8£JIN  ™&šÌm         XML/Util.phpÄv  8£JÄv  ²s3m         XML_Util-1.2.1.tar â 8£J â 7l \m      <?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
+
+/**
+ * File::CSV
+ *
+ * PHP versions 4 and 5
+ *
+ * Copyright (c) 1997-2008,
+ * Vincent Blavet <vincent at phpconcept.net>
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are met:
+ *
+ *     * Redistributions of source code must retain the above copyright notice,
+ *       this list of conditions and the following disclaimer.
+ *     * Redistributions in binary form must reproduce the above copyright
+ *       notice, this list of conditions and the following disclaimer in the
+ *       documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+ * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE
+ * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+ * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+ * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ *
+ * @category    File_Formats
+ * @package     Archive_Tar
+ * @author      Vincent Blavet <vincent at phpconcept.net>
+ * @copyright   1997-2008 The Authors
+ * @license     http://www.opensource.org/licenses/bsd-license.php New BSD License
+ * @version     CVS: $Id: Tar.php 287963 2009-09-02 08:18:55Z mrook $
+ * @link        http://pear.php.net/package/Archive_Tar
+ */
 
 require_once 'phar://install-pear-nozlib.phar/' . 'PEAR.php';
 
@@ -1266,8 +1293,9 @@ define ('ARCHIVE_TAR_END_BLOCK', pack("a512", ''));
 * Creates a (compressed) Tar archive
 *
 * @author   Vincent Blavet <vincent at phpconcept.net>
-* @version  $Revision: 1.24 $
-* @package  Archive
+* @version  $Revision: 287963 $
+* @license  http://www.opensource.org/licenses/bsd-license.php New BSD License
+* @package  Archive_Tar
 */
 class Archive_Tar extends PEAR
 {
@@ -1356,7 +1384,7 @@ class Archive_Tar extends PEAR
                 $this->_compress = true;
                 $this->_compress_type = 'bz2';
             } else {
-                die("Unsupported compression type '$p_compress'\n".
+                $this->_error("Unsupported compression type '$p_compress'\n".
                     "Supported types are 'gz' and 'bz2'.\n");
                 return false;
             }
@@ -1372,7 +1400,7 @@ class Archive_Tar extends PEAR
                 PEAR::loadExtension($extname);
             }
             if (!extension_loaded($extname)) {
-                die("The extension '$extname' couldn't be found.\n".
+                $this->_error("The extension '$extname' couldn't be found.\n".
                     "Please make sure your version of PHP was built ".
                     "with '$extname' support.\n");
                 return false;
@@ -1615,14 +1643,14 @@ class Archive_Tar extends PEAR
     function addString($p_filename, $p_string)
     {
         $v_result = true;
-        
+
         if (!$this->_isArchive()) {
             if (!$this->_openWrite()) {
                 return false;
             }
             $this->_close();
         }
-        
+
         if (!$this->_openAppend())
             return false;
 
@@ -1762,12 +1790,12 @@ class Archive_Tar extends PEAR
     function setAttribute()
     {
         $v_result = true;
-        
+
         // ----- Get the number of variable list of arguments
         if (($v_size = func_num_args()) == 0) {
             return true;
         }
-        
+
         // ----- Get the arguments
         $v_att_list = &func_get_args();
 
@@ -1827,7 +1855,7 @@ class Archive_Tar extends PEAR
             $p_filename = $this->_tarname;
         }
         clearstatcache();
-        return @is_file($p_filename);
+        return @is_file($p_filename) && !@is_link($p_filename);
     }
     // }}}
 
@@ -1837,7 +1865,7 @@ class Archive_Tar extends PEAR
         if ($this->_compress_type == 'gz')
             $this->_file = @gzopen($this->_tarname, "wb9");
         else if ($this->_compress_type == 'bz2')
-            $this->_file = @bzopen($this->_tarname, "wb");
+            $this->_file = @bzopen($this->_tarname, "w");
         else if ($this->_compress_type == 'none')
             $this->_file = @fopen($this->_tarname, "wb");
         else
@@ -1890,7 +1918,7 @@ class Archive_Tar extends PEAR
         if ($this->_compress_type == 'gz')
             $this->_file = @gzopen($v_filename, "rb");
         else if ($this->_compress_type == 'bz2')
-            $this->_file = @bzopen($v_filename, "rb");
+            $this->_file = @bzopen($v_filename, "r");
         else if ($this->_compress_type == 'none')
             $this->_file = @fopen($v_filename, "rb");
         else
@@ -1911,9 +1939,11 @@ class Archive_Tar extends PEAR
     {
         if ($this->_compress_type == 'gz')
             $this->_file = @gzopen($this->_tarname, "r+b");
-        else if ($this->_compress_type == 'bz2')
-            $this->_file = @bzopen($this->_tarname, "r+b");
-        else if ($this->_compress_type == 'none')
+        else if ($this->_compress_type == 'bz2') {
+            $this->_error('Unable to open bz2 in read/write mode \''
+			              .$this->_tarname.'\' (limitation of bz2 extension)');
+            return false;
+        } else if ($this->_compress_type == 'none')
             $this->_file = @fopen($this->_tarname, "r+b");
         else
             $this->_error('Unknown or missing compression type ('
@@ -2104,7 +2134,7 @@ class Archive_Tar extends PEAR
         if (!$this->_addFile($v_filename, $v_header, $p_add_dir, $p_remove_dir))
             return false;
 
-        if (@is_dir($v_filename)) {
+        if (@is_dir($v_filename) && !@is_link($v_filename)) {
             if (!($p_hdir = opendir($v_filename))) {
                 $this->_warning("Directory '$v_filename' can not be read");
                 continue;
@@ -2237,31 +2267,45 @@ class Archive_Tar extends PEAR
             return false;
         }
 
-        $v_info = stat($p_filename);
-        $v_uid = sprintf("%6s ", DecOct($v_info[4]));
-        $v_gid = sprintf("%6s ", DecOct($v_info[5]));
-        $v_perms = sprintf("%6s ", DecOct(fileperms($p_filename)));
+        $v_info = lstat($p_filename);
+        $v_uid = sprintf("%07s", DecOct($v_info[4]));
+        $v_gid = sprintf("%07s", DecOct($v_info[5]));
+        $v_perms = sprintf("%07s", DecOct($v_info['mode'] & 000777));
 
-        $v_mtime = sprintf("%11s", DecOct(filemtime($p_filename)));
+        $v_mtime = sprintf("%011s", DecOct($v_info['mtime']));
+
+        $v_linkname = '';
 
-        if (@is_dir($p_filename)) {
+        if (@is_link($p_filename)) {
+          $v_typeflag = '2';
+          $v_linkname = readlink($p_filename);
+          $v_size = sprintf("%011s", DecOct(0));
+        } elseif (@is_dir($p_filename)) {
           $v_typeflag = "5";
-          $v_size = sprintf("%11s ", DecOct(0));
+          $v_size = sprintf("%011s", DecOct(0));
         } else {
-          $v_typeflag = '';
+          $v_typeflag = '0';
           clearstatcache();
-          $v_size = sprintf("%11s ", DecOct(filesize($p_filename)));
+          $v_size = sprintf("%011s", DecOct($v_info['size']));
         }
 
-        $v_linkname = '';
-
-        $v_magic = '';
-
-        $v_version = '';
+        $v_magic = 'ustar ';
 
-        $v_uname = '';
-
-        $v_gname = '';
+        $v_version = ' ';
+        
+        if (function_exists('posix_getpwuid'))
+        {
+          $userinfo = posix_getpwuid($v_info[4]);
+          $groupinfo = posix_getgrgid($v_info[5]);
+          
+          $v_uname = $userinfo['name'];
+          $v_gname = $groupinfo['name'];
+        }
+        else
+        {
+          $v_uname = '';
+          $v_gname = '';
+        }
 
         $v_devmajor = '';
 
@@ -2269,7 +2313,7 @@ class Archive_Tar extends PEAR
 
         $v_prefix = '';
 
-        $v_binary_data_first = pack("a100a8a8a8a12A12",
+        $v_binary_data_first = pack("a100a8a8a8a12a12",
 		                            $v_reduce_filename, $v_perms, $v_uid,
 									$v_gid, $v_size, $v_mtime);
         $v_binary_data_last = pack("a1a100a6a2a32a32a8a8a155a12",
@@ -2293,7 +2337,7 @@ class Archive_Tar extends PEAR
         $this->_writeBlock($v_binary_data_first, 148);
 
         // ----- Write the calculated checksum
-        $v_checksum = sprintf("%6s ", DecOct($v_checksum));
+        $v_checksum = sprintf("%06s ", DecOct($v_checksum));
         $v_binary_data = pack("a8", $v_checksum);
         $this->_writeBlock($v_binary_data, 8);
 
@@ -2316,27 +2360,37 @@ class Archive_Tar extends PEAR
         }
 
         if ($p_type == "5") {
-          $v_size = sprintf("%11s ", DecOct(0));
+          $v_size = sprintf("%011s", DecOct(0));
         } else {
-          $v_size = sprintf("%11s ", DecOct($p_size));
+          $v_size = sprintf("%011s", DecOct($p_size));
         }
 
-        $v_uid = sprintf("%6s ", DecOct($p_uid));
-        $v_gid = sprintf("%6s ", DecOct($p_gid));
-        $v_perms = sprintf("%6s ", DecOct($p_perms));
+        $v_uid = sprintf("%07s", DecOct($p_uid));
+        $v_gid = sprintf("%07s", DecOct($p_gid));
+        $v_perms = sprintf("%07s", DecOct($p_perms & 000777));
 
         $v_mtime = sprintf("%11s", DecOct($p_mtime));
 
         $v_linkname = '';
 
-        $v_magic = '';
-
-        $v_version = '';
+        $v_magic = 'ustar ';
 
-        $v_uname = '';
-
-        $v_gname = '';
+        $v_version = ' ';
 
+        if (function_exists('posix_getpwuid'))
+        {
+          $userinfo = posix_getpwuid($p_uid);
+          $groupinfo = posix_getgrgid($p_gid);
+          
+          $v_uname = $userinfo['name'];
+          $v_gname = $groupinfo['name'];
+        }
+        else
+        {
+          $v_uname = '';
+          $v_gname = '';
+        }
+        
         $v_devmajor = '';
 
         $v_devminor = '';
@@ -2367,7 +2421,7 @@ class Archive_Tar extends PEAR
         $this->_writeBlock($v_binary_data_first, 148);
 
         // ----- Write the calculated checksum
-        $v_checksum = sprintf("%6s ", DecOct($v_checksum));
+        $v_checksum = sprintf("%06s ", DecOct($v_checksum));
         $v_binary_data = pack("a8", $v_checksum);
         $this->_writeBlock($v_binary_data, 8);
 
@@ -2401,7 +2455,7 @@ class Archive_Tar extends PEAR
 
         $v_prefix = '';
 
-        $v_binary_data_first = pack("a100a8a8a8a12A12",
+        $v_binary_data_first = pack("a100a8a8a8a12a12",
 		                            '././@LongLink', 0, 0, 0, $v_size, 0);
         $v_binary_data_last = pack("a1a100a6a2a32a32a8a8a155a12",
 		                           $v_typeflag, $v_linkname, $v_magic,
@@ -2424,7 +2478,7 @@ class Archive_Tar extends PEAR
         $this->_writeBlock($v_binary_data_first, 148);
 
         // ----- Write the calculated checksum
-        $v_checksum = sprintf("%6s ", DecOct($v_checksum));
+        $v_checksum = sprintf("%06s ", DecOct($v_checksum));
         $v_binary_data = pack("a8", $v_checksum);
         $this->_writeBlock($v_binary_data, 8);
 
@@ -2492,7 +2546,7 @@ class Archive_Tar extends PEAR
         }
 
         // ----- Extract the properties
-        $v_header['filename'] = trim($v_data['filename']);
+        $v_header['filename'] = $v_data['filename'];
         if ($this->_maliciousFilename($v_header['filename'])) {
             $this->_error('Malicious .tar detected, file "' . $v_header['filename'] .
                 '" will not install in desired directory tree');
@@ -2552,7 +2606,7 @@ class Archive_Tar extends PEAR
       }
       if (($v_header['size'] % 512) != 0) {
         $v_content = $this->_readBlock();
-        $v_filename .= $v_content;
+        $v_filename .= trim($v_content);
       }
 
       // ----- Read the next header
@@ -2561,6 +2615,7 @@ class Archive_Tar extends PEAR
       if (!$this->_readHeader($v_binary_data, $v_header))
         return false;
 
+      $v_filename = trim($v_filename);
       $v_header['filename'] = $v_filename;
         if ($this->_maliciousFilename($v_filename)) {
             $this->_error('Malicious .tar detected, file "' . $v_filename .
@@ -2768,6 +2823,9 @@ class Archive_Tar extends PEAR
                 }
             }
           } elseif ($v_header['typeflag'] == "2") {
+              if (@file_exists($v_header['filename'])) {
+                  @unlink($v_header['filename']);
+              }
               if (!@symlink($v_header['link'], $v_header['filename'])) {
                   $this->_error('Unable to extract symbolic link {'
                                 .$v_header['filename'].'}');
@@ -2849,7 +2907,7 @@ class Archive_Tar extends PEAR
     {
         if (filesize($this->_tarname) == 0)
           return $this->_openWrite();
-          
+
         if ($this->_compress) {
             $this->_close();
 
@@ -2863,8 +2921,8 @@ class Archive_Tar extends PEAR
             if ($this->_compress_type == 'gz')
                 $v_temp_tar = @gzopen($this->_tarname.".tmp", "rb");
             elseif ($this->_compress_type == 'bz2')
-                $v_temp_tar = @bzopen($this->_tarname.".tmp", "rb");
-                
+                $v_temp_tar = @bzopen($this->_tarname.".tmp", "r");
+
             if ($v_temp_tar == 0) {
                 $this->_error('Unable to open file \''.$this->_tarname
 				              .'.tmp\' in binary read mode');
@@ -2918,14 +2976,14 @@ class Archive_Tar extends PEAR
             $v_size = filesize($this->_tarname);
 
             // We might have zero, one or two end blocks.
-            // The standard is two, but we should try to handle 
+            // The standard is two, but we should try to handle
             // other cases.
             fseek($this->_file, $v_size - 1024);
             if (fread($this->_file, 512) == ARCHIVE_TAR_END_BLOCK) {
                 fseek($this->_file, $v_size - 1024);
             }
             elseif (fread($this->_file, 512) == ARCHIVE_TAR_END_BLOCK) {
-                fseek($this->_file, $v_size - 512);    
+                fseek($this->_file, $v_size - 512);
             }
         }
 
@@ -2938,7 +2996,7 @@ class Archive_Tar extends PEAR
     {
         if (!$this->_openAppend())
             return false;
-            
+
         if ($this->_addList($p_filelist, $p_add_dir, $p_remove_dir))
            $this->_writeFooter();
 
@@ -2984,7 +3042,7 @@ class Archive_Tar extends PEAR
     // {{{ _pathReduction()
 
     /**
-     * Compress path by changing for example "/dir/foo/../bar" to "/dir/bar", 
+     * Compress path by changing for example "/dir/foo/../bar" to "/dir/bar",
      * rand emove double slashes.
      *
      * @param string $p_dir path to reduce
@@ -5764,33 +5822,43 @@ Correct Bug #9352 Bug on _dirCheck function over nfs path
 </package>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               <?php
 /* vim: set expandtab tabstop=4 shiftwidth=4: */
-// +----------------------------------------------------------------------+
-// | PHP Version 5                                                        |
-// +----------------------------------------------------------------------+
-// | Copyright (c) 1997-2004 The PHP Group                                |
-// +----------------------------------------------------------------------+
-// | This source file is subject to version 3.0 of the PHP license,       |
-// | that is bundled with this package in the file LICENSE, and is        |
-// | available through the world-wide-web at the following url:           |
-// | http://www.php.net/license/3_0.txt.                                  |
-// | If you did not receive a copy of the PHP license and are unable to   |
-// | obtain it through the world-wide-web, please send a note to          |
-// | license at php.net so we can mail you a copy immediately.               |
-// +----------------------------------------------------------------------+
-// | Author: Andrei Zmievski <andrei at php.net>                             |
-// +----------------------------------------------------------------------+
-//
-// $Id: Getopt.php,v 1.32 2007/02/18 04:13:07 cellog Exp $
+/**
+ * Color.php
+ *
+ * PHP Version 5  
+ * 
+ * Copyright (c) 1997-2004 The PHP Group
+ *
+ * This source file is subject to version 3.0 of the PHP license,       
+ * that is bundled with this package in the file LICENSE, and is        
+ * available through the world-wide-web at the following url:           
+ * http://www.php.net/license/3_0.txt.                                  
+ * If you did not receive a copy of the PHP license and are unable to   
+ * obtain it through the world-wide-web, please send a note to          
+ * license at php.net so we can mail you a copy immediately.               
+ *
+ * @category Console
+ * @package  Console_Getopt
+ * @author   Andrei Zmievski <andrei at php.net>
+ * @license  http://www.php.net/license/3_0.txt PHP 3.0
+ * @version  CVS: $Id: Getopt.php 267328 2008-10-14 18:53:25Z andrei $
+ * @link     http://pear.php.net/package/Console_Getopt
+ */
 
 require_once 'phar://install-pear-nozlib.phar/' . 'PEAR.php';
 
 /**
  * Command-line options parsing class.
  *
- * @author Andrei Zmievski <andrei at php.net>
- *
+ * @category Console
+ * @package  Console_Getopt
+ * @author   Andrei Zmievski <andrei at php.net>
+ * @license  http://www.php.net/license/3_0.txt PHP 3.0
+ * @link     http://pear.php.net/package/Console_Getopt
  */
-class Console_Getopt {
+class Console_Getopt
+{
+
     /**
      * Parses the command-line options.
      *
@@ -5817,15 +5885,13 @@ class Console_Getopt {
      *
      * Most of the semantics of this function are based on GNU getopt_long().
      *
-     * @param array  $args           an array of command-line arguments
-     * @param string $short_options  specifies the list of allowed short options
-     * @param array  $long_options   specifies the list of allowed long options
+     * @param array  $args          an array of command-line arguments
+     * @param string $short_options specifies the list of allowed short options
+     * @param array  $long_options  specifies the list of allowed long options
      *
      * @return array two-element array containing the list of parsed options and
      * the non-option arguments
-     *
      * @access public
-     *
      */
     function getopt2($args, $short_options, $long_options = null)
     {
@@ -5835,7 +5901,14 @@ class Console_Getopt {
     /**
      * This function expects $args to start with the script name (POSIX-style).
      * Preserved for backwards compatibility.
+     *
+     * @param array  $args          an array of command-line arguments
+     * @param string $short_options specifies the list of allowed short options
+     * @param array  $long_options  specifies the list of allowed long options
+     *
      * @see getopt2()
+     * @return array two-element array containing the list of parsed options and
+     * the non-option arguments
      */    
     function getopt($args, $short_options, $long_options = null)
     {
@@ -5844,6 +5917,13 @@ class Console_Getopt {
 
     /**
      * The actual implementation of the argument parsing code.
+     *
+     * @param int    $version       Version to use
+     * @param array  $args          an array of command-line arguments
+     * @param string $short_options specifies the list of allowed short options
+     * @param array  $long_options  specifies the list of allowed long options
+     *
+     * @return array
      */
     function doGetopt($version, $args, $short_options, $long_options = null)
     {
@@ -5884,17 +5964,28 @@ class Console_Getopt {
                 break;
             }
 
-            if ($arg{0} != '-' || (strlen($arg) > 1 && $arg{1} == '-' && !$long_options)) {
+            if ($arg{0} != '-' || (strlen($arg) > 1 && $arg{1} == '-' 
+                                    && !$long_options)) {
                 $non_opts = array_merge($non_opts, array_slice($args, $i));
                 break;
             } elseif (strlen($arg) > 1 && $arg{1} == '-') {
-                $error = Console_Getopt::_parseLongOption(substr($arg, 2), $long_options, $opts, $args);
-                if (PEAR::isError($error))
+                $error = Console_Getopt::_parseLongOption(substr($arg, 2), 
+                                                          $long_options, $opts,
+                                                          $args);
+                if (PEAR::isError($error)) {
                     return $error;
+                }
+            } elseif ($arg == '-') {
+                // - is stdin
+                $non_opts = array_merge($non_opts, array_slice($args, $i));
+                break;
             } else {
-                $error = Console_Getopt::_parseShortOption(substr($arg, 1), $short_options, $opts, $args);
-                if (PEAR::isError($error))
+                $error = Console_Getopt::_parseShortOption(substr($arg, 1),
+                                                           $short_options, $opts,
+                                                           $args);
+                if (PEAR::isError($error)) {
                     return $error;
+                }
             }
         }
 
@@ -5902,19 +5993,27 @@ class Console_Getopt {
     }
 
     /**
-     * @access private
+     * Parse short option
+     *
+     * @param string     $arg           Argument
+     * @param string[]   $short_options Available short options
+     * @param string[][] &$opts
+     * @param string[]   &$args
      *
+     * @access private
+     * @return void
      */
     function _parseShortOption($arg, $short_options, &$opts, &$args)
     {
         for ($i = 0; $i < strlen($arg); $i++) {
-            $opt = $arg{$i};
+            $opt     = $arg{$i};
             $opt_arg = null;
 
             /* Try to find the short option in the specifier string. */
-            if (($spec = strstr($short_options, $opt)) === false || $arg{$i} == ':')
-            {
-                return PEAR::raiseError("Console_Getopt: unrecognized option -- $opt");
+            if (($spec = strstr($short_options, $opt)) === false 
+                || $arg{$i} == ':') {
+                $msg = "Console_Getopt: unrecognized option -- $opt";
+                return PEAR::raiseError($msg);
             }
 
             if (strlen($spec) > 1 && $spec{1} == ':') {
@@ -5933,11 +6032,14 @@ class Console_Getopt {
                         break;
                     } else if (list(, $opt_arg) = each($args)) {
                         /* Else use the next argument. */;
-                        if (Console_Getopt::_isShortOpt($opt_arg) || Console_Getopt::_isLongOpt($opt_arg)) {
-                            return PEAR::raiseError("Console_Getopt: option requires an argument -- $opt");
+                        if (Console_Getopt::_isShortOpt($opt_arg) 
+                            || Console_Getopt::_isLongOpt($opt_arg)) {
+                            $msg = "option requires an argument --$opt";
+                            return PEAR::raiseError("Console_Getopt:" . $msg);
                         }
                     } else {
-                        return PEAR::raiseError("Console_Getopt: option requires an argument -- $opt");
+                        $msg = "option requires an argument --$opt";
+                        return PEAR::raiseError("Console_Getopt:" . $msg);
                     }
                 }
             }
@@ -5947,36 +6049,54 @@ class Console_Getopt {
     }
 
     /**
-     * @access private
+     * Checks if an argument is a short option
+     *
+     * @param string $arg Argument to check
      *
+     * @access private
+     * @return bool
      */
     function _isShortOpt($arg)
     {
-        return strlen($arg) == 2 && $arg[0] == '-' && preg_match('/[a-zA-Z]/', $arg[1]);
+        return strlen($arg) == 2 && $arg[0] == '-' 
+               && preg_match('/[a-zA-Z]/', $arg[1]);
     }
 
     /**
-     * @access private
+     * Checks if an argument is a long option
+     *
+     * @param string $arg Argument to check
      *
+     * @access private
+     * @return bool
      */
     function _isLongOpt($arg)
     {
         return strlen($arg) > 2 && $arg[0] == '-' && $arg[1] == '-' &&
-            preg_match('/[a-zA-Z]+$/', substr($arg, 2));
+               preg_match('/[a-zA-Z]+$/', substr($arg, 2));
     }
 
     /**
-     * @access private
+     * Parse long option
+     *
+     * @param string     $arg          Argument
+     * @param string[]   $long_options Available long options
+     * @param string[][] &$opts
+     * @param string[]   &$args
      *
+     * @access private
+     * @return void|PEAR_Error
      */
     function _parseLongOption($arg, $long_options, &$opts, &$args)
     {
         @list($opt, $opt_arg) = explode('=', $arg, 2);
+
         $opt_len = strlen($opt);
 
         for ($i = 0; $i < count($long_options); $i++) {
             $long_opt  = $long_options[$i];
             $opt_start = substr($long_opt, 0, $opt_len);
+
             $long_opt_name = str_replace('=', '', $long_opt);
 
             /* Option doesn't match. Go on to the next one. */
@@ -5984,17 +6104,24 @@ class Console_Getopt {
                 continue;
             }
 
-            $opt_rest  = substr($long_opt, $opt_len);
+            $opt_rest = substr($long_opt, $opt_len);
 
             /* Check that the options uniquely matches one of the allowed
                options. */
-            $next_option_rest = substr($long_options[$i + 1], $opt_len);
+            if ($i + 1 < count($long_options)) {
+                $next_option_rest = substr($long_options[$i + 1], $opt_len);
+            } else {
+                $next_option_rest = '';
+            }
+
             if ($opt_rest != '' && $opt{0} != '=' &&
                 $i + 1 < count($long_options) &&
                 $opt == substr($long_options[$i+1], 0, $opt_len) &&
                 $next_option_rest != '' &&
                 $next_option_rest{0} != '=') {
-                return PEAR::raiseError("Console_Getopt: option --$opt is ambiguous");
+
+                $msg = "Console_Getopt: option --$opt is ambiguous";
+                return PEAR::raiseError($msg);
             }
 
             if (substr($long_opt, -1) == '=') {
@@ -6002,11 +6129,19 @@ class Console_Getopt {
                     /* Long option requires an argument.
                        Take the next argument if one wasn't specified. */;
                     if (!strlen($opt_arg) && !(list(, $opt_arg) = each($args))) {
-                        return PEAR::raiseError("Console_Getopt: option --$opt requires an argument");
+                        $msg = "Console_Getopt: option requires an argument --$opt";
+                        return PEAR::raiseError($msg);
+                    }
+
+                    if (Console_Getopt::_isShortOpt($opt_arg) 
+                        || Console_Getopt::_isLongOpt($opt_arg)) {
+                        $msg = "Console_Getopt: option requires an argument --$opt";
+                        return PEAR::raiseError($msg);
                     }
                 }
             } else if ($opt_arg) {
-                return PEAR::raiseError("Console_Getopt: option --$opt doesn't allow an argument");
+                $msg = "Console_Getopt: option --$opt doesn't allow an argument";
+                return PEAR::raiseError($msg);
             }
 
             $opts[] = array('--' . $opt, $opt_arg);
@@ -6017,19 +6152,20 @@ class Console_Getopt {
     }
 
     /**
-    * Safely read the $argv PHP array across different PHP configurations.
-    * Will take care on register_globals and register_argc_argv ini directives
-    *
-    * @access public
-    * @return mixed the $argv PHP array or PEAR error if not registered
-    */
+     * Safely read the $argv PHP array across different PHP configurations.
+     * Will take care on register_globals and register_argc_argv ini directives
+     *
+     * @access public
+     * @return mixed the $argv PHP array or PEAR error if not registered
+     */
     function readPHPArgv()
     {
         global $argv;
         if (!is_array($argv)) {
             if (!@is_array($_SERVER['argv'])) {
                 if (!@is_array($GLOBALS['HTTP_SERVER_VARS']['argv'])) {
-                    return PEAR::raiseError("Console_Getopt: Could not read cmd args (register_argc_argv=Off?)");
+                    $msg = "Could not read cmd args (register_argc_argv=Off?)";
+                    return PEAR::raiseError("Console_Getopt: " . $msg);
                 }
                 return $GLOBALS['HTTP_SERVER_VARS']['argv'];
             }
@@ -6486,278 +6622,307 @@ class Console_Getopt {
 }
 
 ?>
-                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      <?php
-
-/* $Id: install-pear.php,v 1.37 2009/02/16 00:46:55 dufuz Exp $ */
-
-error_reporting(1803);
-
-if (ini_get('date.timezone') === '' && function_exists('date_default_timezone_set')) {
-    date_default_timezone_set('UTC');
-}
-
-$pear_dir = dirname(__FILE__);
-ini_set('include_path', '');
-if (function_exists('mb_internal_encoding')) {
-    mb_internal_encoding('ASCII');
-}
-set_time_limit(0);
-include_once 'phar://install-pear-nozlib.phar/PEAR.php';
-include_once 'phar://install-pear-nozlib.phar/PEAR/Installer.php';
-include_once 'phar://install-pear-nozlib.phar/PEAR/Registry.php';
-include_once 'phar://install-pear-nozlib.phar/PEAR/PackageFile.php';
-include_once 'phar://install-pear-nozlib.phar/PEAR/Downloader/Package.php';
-include_once 'phar://install-pear-nozlib.phar/PEAR/Frontend.php';
-$a = true;
-if (!PEAR::loadExtension('xml')) {
-    $a = false;
-    echo "[PEAR] xml extension is required\n";
-}
-if (!PEAR::loadExtension('pcre')) {
-    $a = false;
-    echo "[PEAR] pcre extension is required\n";
-}
-if (!$a) {
-    return -1;
-}
-
-$force = false;
+                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      <?php
+
+/* $Id: install-pear.php 287906 2009-08-30 20:43:17Z dufuz $ */
+
+error_reporting(1803);
+
+if (ini_get('date.timezone') === '' && function_exists('date_default_timezone_set')) {
+    date_default_timezone_set('UTC');
+}
+
+$pear_dir = dirname(__FILE__);
+ini_set('include_path', '');
+if (function_exists('mb_internal_encoding')) {
+    mb_internal_encoding('ASCII');
+}
+set_time_limit(0);
+include_once 'phar://install-pear-nozlib.phar/PEAR.php';
+include_once 'phar://install-pear-nozlib.phar/PEAR/Installer.php';
+include_once 'phar://install-pear-nozlib.phar/PEAR/Registry.php';
+include_once 'phar://install-pear-nozlib.phar/PEAR/PackageFile.php';
+include_once 'phar://install-pear-nozlib.phar/PEAR/Downloader/Package.php';
+include_once 'phar://install-pear-nozlib.phar/PEAR/Frontend.php';
+$a = true;
+if (!PEAR::loadExtension('xml')) {
+    $a = false;
+    echo "[PEAR] xml extension is required\n";
+}
+if (!PEAR::loadExtension('pcre')) {
+    $a = false;
+    echo "[PEAR] pcre extension is required\n";
+}
+if (!$a) {
+    return -1;
+}
+
+$force = false;
 $install_files = array('Archive_Tar' => 'phar://install-pear-nozlib.phar/Archive_Tar-1.3.3.tar',
 'Console_Getopt' => 'phar://install-pear-nozlib.phar/Console_Getopt-1.2.3.tar',
 'Structures_Graph' => 'phar://install-pear-nozlib.phar/Structures_Graph-1.0.2.tar',
 'XML_Util' => 'phar://install-pear-nozlib.phar/XML_Util-1.2.1.tar',
-'PEAR' => 'phar://install-pear-nozlib.phar/PEAR-1.8.0.tar',
-);
-array_shift($argv);
-$debug = false;
-for ($i = 0; $i < sizeof($argv); $i++) {
-    $arg = $argv[$i];
-    $bn = basename($arg);
-    if (ereg('package-(.*)\.xml$', $bn, $matches) ||
-        ereg('([A-Za-z0-9_:]+)-.*\.(tar|tgz)$', $bn, $matches)) {
-        $install_files[$matches[1]] = $arg;
-    } elseif ($arg == '-a') {
-        $cache_dir = $argv[$i+1];
-        $i++;
-    } elseif ($arg == '--force') {
-        $force = true;
-    } elseif ($arg == '-d') {
-        $with_dir = $argv[$i+1];
-        $i++;
-    } elseif ($arg == '-b') {
-        $bin_dir = $argv[$i+1];
-        $i++;
-    } elseif ($arg == '-c') {
-        $cfg_dir = $argv[$i+1];
-        $i++;
-    } elseif ($arg == '-w') {
-        $www_dir = $argv[$i+1];
-        $i++;
-    } elseif ($arg == '-p') {
-        $php_bin = $argv[$i+1];
-        $i++;
-    } elseif ($arg == '-o') {
-        $download_dir = $argv[$i+1];
-        $i++;
-    } elseif ($arg == '-t') {
-        $temp_dir = $argv[$i+1];
-        $i++;
-    } elseif ($arg == '--debug') {
-        $debug = 1;
-    } elseif ($arg == '--extremedebug') {
-        $debug = 2;
-    }
-}
-
-$config = PEAR_Config::singleton();
-
-if (PEAR::isError($config)) {
-    $locs = PEAR_Config::getDefaultConfigFiles();
-    die("ERROR: One of $locs[user] or $locs[system] is corrupt, please remove them and try again");
-}
-
-// make sure we use only default values
-$config_layers = $config->getLayers();
-foreach ($config_layers as $layer) {
-    if ($layer == 'default') continue;
-    $config->removeLayer($layer);
-}
-$keys = $config->getKeys();
-if ($debug) {
-    $config->set('verbose', 5, 'default');
-} else {
-    $config->set('verbose', 0, 'default');
-}
-// PEAR executables
-if (!empty($bin_dir)) {
-    $config->set('bin_dir', $bin_dir, 'default');
-}
-
-// Cache files
-if (!empty($cache_dir)) {
-    $config->set('cache_dir', $cache_dir, 'default');
-}
-
-// Config files
-if (!empty($cfg_dir)) {
-    $config->set('cfg_dir', $cfg_dir, 'default');
-}
-
-// Web files
-if (!empty($www_dir)) {
-    $config->set('www_dir', $www_dir, 'default');
-}
-
-// Downloaded files
-if (!empty($download_dir)) {
-    $config->set('download_dir', $download_dir, 'default');
-}
-
-// Temporary files
-if (!empty($temp_dir)) {
-    $config->set('temp_dir', $temp_dir, 'default');
-}
-
-// User supplied a dir prefix
-if (!empty($with_dir)) {
-    $ds = DIRECTORY_SEPARATOR;
-    $config->set('php_dir', $with_dir, 'default');
-    $config->set('doc_dir', $with_dir . $ds . 'doc', 'default');
-    $config->set('data_dir', $with_dir . $ds . 'data', 'default');
-    $config->set('test_dir', $with_dir . $ds . 'test', 'default');
-    if (empty($www_dir)) {
-        $config->set('www_dir', $with_dir . $ds . 'htdocs', 'default');
-    }
-    if (empty($cfg_dir)) {
-        $config->set('cfg_dir', $with_dir . $ds . 'cfg', 'default');
-    }
-    if (!is_writable($config->get('cache_dir'))) {
-        include_once 'phar://install-pear-nozlib.phar/System.php';
-        $cdir = System::mktemp(array('-d', 'pear'));
-        if (PEAR::isError($cdir)) {
-            $ui->outputData("[PEAR] cannot make new temporary directory: " . $cdir);
-            die(1);
-        }
-        $oldcachedir = $config->get('cache_dir');
-        $config->set('cache_dir', $cdir);
-    }
-}
-if (!empty($php_bin)) {
-    $config->set('php_bin', $php_bin);
-}
-/* Print PEAR Conf (useful for debuging do NOT REMOVE) */
-if ($debug) {
-    sort($keys);
-    foreach ($keys as $key) {
-        echo $key . '    ' .
-            $config->getPrompt($key) . ": " . $config->get($key, null, 'default') . "\n";
-    }
-    if ($debug == 2) { // extreme debugging
-        exit;
-    }
-}
-// end print
-
-$php_dir = $config->get('php_dir');
-$options = array();
-$options['upgrade'] = true;
-$install_root = getenv('INSTALL_ROOT');
-if (!empty($install_root)) {
-    $options['packagingroot'] = $install_root;
-    $reg = &new PEAR_Registry($options['packagingroot']);
-} else {
-    $reg = $config->getRegistry('default');
-}
-
-$ui = PEAR_Frontend::singleton('PEAR_Frontend_CLI');
-if (PEAR::isError($ui)) {
-    die($ui->getMessage());
-}
-$installer = new PEAR_Installer($ui);
-$pkg = new PEAR_PackageFile($config, $debug);
-
-foreach ($install_files as $package => $instfile) {
-    $info = $pkg->fromAnyFile($instfile, PEAR_VALIDATE_INSTALLING);
-    if (PEAR::isError($info)) {
-        if (is_array($info->getUserInfo())) {
-            foreach ($info->getUserInfo() as $err) {
-                $ui->outputData(sprintf("[PEAR] %s: %s", $package, $err['message']));
-            }
-        }
-        $ui->outputData(sprintf("[PEAR] %s: %s", $package, $info->getMessage()));
-        continue;
-    }
-    $new_ver = $info->getVersion();
-    $downloaderpackage = new PEAR_Downloader_Package($installer);
-    $err = $downloaderpackage->initialize($instfile);
-    if (PEAR::isError($err)) {
-        $ui->outputData(sprintf("[PEAR] %s: %s", $package, $err->getMessage()));
-        continue;
-    }
-    if ($reg->packageExists($package)) {
-        $old_ver = $reg->packageInfo($package, 'version');
-        if (version_compare($new_ver, $old_ver, 'gt')) {
-            $installer->setOptions($options);
-            $dp = array($downloaderpackage);
-            $installer->setDownloadedPackages($dp);
-            $err = $installer->install($downloaderpackage, $options);
-            if (PEAR::isError($err)) {
-                $ui->outputData(sprintf("[PEAR] %s: %s", $package, $err->getMessage()));
-                continue;
-            }
-            $ui->outputData(sprintf("[PEAR] %-15s- upgraded:  %s", $package, $new_ver));
-        } else {
-            if ($force) {
-                $options['force'] = true;
-                $installer->setOptions($options);
-                $dp = array($downloaderpackage);
-                $installer->setDownloadedPackages($dp);
-                $err = $installer->install($downloaderpackage, $options);
-                if (PEAR::isError($err)) {
-                    $ui->outputData(sprintf("[PEAR] %s: %s", $package, $err->getMessage()));
-                    continue;
-                }
-                $ui->outputData(sprintf("[PEAR] %-15s- installed: %s", $package, $new_ver));
-            } else {
-                $ui->outputData(sprintf("[PEAR] %-15s- already installed: %s", $package, $old_ver));
-            }
-        }
-    } else {
-        $options['nodeps'] = true;
-        $installer->setOptions($options);
-        $dp = array($downloaderpackage);
-        $installer->setDownloadedPackages($dp);
-        $err = $installer->install($downloaderpackage, $options);
-        if (PEAR::isError($err)) {
-            $ui->outputData(sprintf("[PEAR] %s: %s", $package, $err->getMessage()));
-            continue;
-        }
-        $ui->outputData(sprintf("[PEAR] %-15s- installed: %s", $package, $new_ver));
-    }
-    if ($package == 'PEAR') {
-        if (is_file($ufile = $config->getConfFile('user'))) {
-            $ui->outputData('Warning! a PEAR user config file already exists from ' .
-                            'a previous PEAR installation at ' .
-                            "'$ufile'. You may probably want to remove it.");
-        }
-        $config->set('verbose', 1, 'default');
-        if (isset($oldcachedir)) {
-            $config->set('cache_dir', $oldcachedir);
-        }
-        $data = array();
-        foreach ($config->getKeys() as $key) {
-            $data[$key] = $config->get($key);
-        }
-        $cnf_file = $config->getConfFile('system');
-        if (!empty($install_root)) {
-            $cnf_file = $install_root . DIRECTORY_SEPARATOR . $cnf_file;
-        }
-        $config->writeConfigFile($cnf_file, 'system', $data);
-        $ui->outputData('Wrote PEAR system config file at: ' . $cnf_file);
-        $ui->outputData('You may want to add: ' . $config->get('php_dir') . ' to your php.ini include_path');
-    }
-}
-?>
+'PEAR' => 'phar://install-pear-nozlib.phar/PEAR-1.9.0.tar',
+);
+array_shift($argv);
+$debug = false;
+for ($i = 0; $i < sizeof($argv); $i++) {
+    $arg = $argv[$i];
+    $bn = basename($arg);
+    if (preg_match('/package-(.*)\.xml$/', $bn, $matches) ||
+        preg_match('/([A-Za-z0-9_:]+)-.*\.(tar|tgz)$/', $bn, $matches)) {
+        $install_files[$matches[1]] = $arg;
+    } elseif ($arg == '-a') {
+        $cache_dir = $argv[$i+1];
+        $i++;
+    } elseif ($arg == '--force') {
+        $force = true;
+    } elseif ($arg == '-dp') {
+        $prefix = $argv[$i+1];
+        $i++;
+    } elseif ($arg == '-ds') {
+        $suffix = $argv[$i+1];
+        $i++;
+    } elseif ($arg == '-d') {
+        $with_dir = $argv[$i+1];
+        $i++;
+    } elseif ($arg == '-b') {
+        $bin_dir = $argv[$i+1];
+        $i++;
+    } elseif ($arg == '-c') {
+        $cfg_dir = $argv[$i+1];
+        $i++;
+    } elseif ($arg == '-w') {
+        $www_dir = $argv[$i+1];
+        $i++;
+    } elseif ($arg == '-p') {
+        $php_bin = $argv[$i+1];
+        $i++;
+    } elseif ($arg == '-o') {
+        $download_dir = $argv[$i+1];
+        $i++;
+    } elseif ($arg == '-t') {
+        $temp_dir = $argv[$i+1];
+        $i++;
+    } elseif ($arg == '--debug') {
+        $debug = 1;
+    } elseif ($arg == '--extremedebug') {
+        $debug = 2;
+    }
+}
+
+$config = PEAR_Config::singleton();
+
+if (PEAR::isError($config)) {
+    $locs = PEAR_Config::getDefaultConfigFiles();
+    die("ERROR: One of $locs[user] or $locs[system] is corrupt, please remove them and try again");
+}
+
+// make sure we use only default values
+$config_layers = $config->getLayers();
+foreach ($config_layers as $layer) {
+    if ($layer == 'default') continue;
+    $config->removeLayer($layer);
+}
+$keys = $config->getKeys();
+if ($debug) {
+    $config->set('verbose', 5, 'default');
+} else {
+    $config->set('verbose', 0, 'default');
+}
+// PEAR executables
+if (!empty($bin_dir)) {
+    $config->set('bin_dir', $bin_dir, 'default');
+}
+
+// Cache files
+if (!empty($cache_dir)) {
+    $config->set('cache_dir', $cache_dir, 'default');
+}
+
+// Config files
+if (!empty($cfg_dir)) {
+    $config->set('cfg_dir', $cfg_dir, 'default');
+}
+
+// Web files
+if (!empty($www_dir)) {
+    $config->set('www_dir', $www_dir, 'default');
+}
+
+// Downloaded files
+if (!empty($download_dir)) {
+    $config->set('download_dir', $download_dir, 'default');
+}
+
+// Temporary files
+if (!empty($temp_dir)) {
+    $config->set('temp_dir', $temp_dir, 'default');
+}
+
+// User supplied a dir prefix
+if (!empty($with_dir)) {
+    $ds = DIRECTORY_SEPARATOR;
+    $config->set('php_dir', $with_dir, 'default');
+    $config->set('doc_dir', $with_dir . $ds . 'doc', 'default');
+    $config->set('data_dir', $with_dir . $ds . 'data', 'default');
+    $config->set('test_dir', $with_dir . $ds . 'test', 'default');
+    if (empty($www_dir)) {
+        $config->set('www_dir', $with_dir . $ds . 'htdocs', 'default');
+    }
+    if (empty($cfg_dir)) {
+        $config->set('cfg_dir', $with_dir . $ds . 'cfg', 'default');
+    }
+    if (!is_writable($config->get('cache_dir'))) {
+        include_once 'phar://install-pear-nozlib.phar/System.php';
+        $cdir = System::mktemp(array('-d', 'pear'));
+        if (PEAR::isError($cdir)) {
+            $ui->outputData("[PEAR] cannot make new temporary directory: " . $cdir);
+            die(1);
+        }
+        $oldcachedir = $config->get('cache_dir');
+        $config->set('cache_dir', $cdir);
+    }
+}
+
+// PHP executable
+if (!empty($php_bin)) {
+    $config->set('php_bin', $php_bin);
+}
+
+// PHP prefix
+if (isset($prefix)) {
+    if ($prefix != 'a') {
+        if ($prefix[0] == 'a') {
+            $prefix = substr($prefix, 1);
+        }
+        $config->set('php_prefix', $prefix, 'system');
+    }
+}
+
+// PHP suffix
+if (isset($suffix)) {
+    if ($suffix != 'a') {
+        if ($suffix[0] == 'a') {
+            $suffix = substr($suffix, 1);
+        }
+        $config->set('php_suffix', $suffix, 'system');
+    }
+}
+
+/* Print PEAR Conf (useful for debuging do NOT REMOVE) */
+if ($debug) {
+    sort($keys);
+    foreach ($keys as $key) {
+        echo $key . '    ' .
+            $config->getPrompt($key) . ": " . $config->get($key, null, 'default') . "\n";
+    }
+    if ($debug == 2) { // extreme debugging
+        exit;
+    }
+}
+// end print
+
+$php_dir = $config->get('php_dir');
+$options = array();
+$options['upgrade'] = true;
+$install_root = getenv('INSTALL_ROOT');
+if (!empty($install_root)) {
+    $options['packagingroot'] = $install_root;
+    $reg = &new PEAR_Registry($options['packagingroot']);
+} else {
+    $reg = $config->getRegistry('default');
+}
+
+$ui = PEAR_Frontend::singleton('PEAR_Frontend_CLI');
+if (PEAR::isError($ui)) {
+    die($ui->getMessage());
+}
+$installer = new PEAR_Installer($ui);
+$pkg = new PEAR_PackageFile($config, $debug);
+
+foreach ($install_files as $package => $instfile) {
+    $info = $pkg->fromAnyFile($instfile, PEAR_VALIDATE_INSTALLING);
+    if (PEAR::isError($info)) {
+        if (is_array($info->getUserInfo())) {
+            foreach ($info->getUserInfo() as $err) {
+                $ui->outputData(sprintf("[PEAR] %s: %s", $package, $err['message']));
+            }
+        }
+        $ui->outputData(sprintf("[PEAR] %s: %s", $package, $info->getMessage()));
+        continue;
+    }
+    $new_ver = $info->getVersion();
+    $downloaderpackage = new PEAR_Downloader_Package($installer);
+    $err = $downloaderpackage->initialize($instfile);
+    if (PEAR::isError($err)) {
+        $ui->outputData(sprintf("[PEAR] %s: %s", $package, $err->getMessage()));
+        continue;
+    }
+    if ($reg->packageExists($package)) {
+        $old_ver = $reg->packageInfo($package, 'version');
+        if (version_compare($new_ver, $old_ver, 'gt')) {
+            $installer->setOptions($options);
+            $dp = array($downloaderpackage);
+            $installer->setDownloadedPackages($dp);
+            $err = $installer->install($downloaderpackage, $options);
+            if (PEAR::isError($err)) {
+                $ui->outputData(sprintf("[PEAR] %s: %s", $package, $err->getMessage()));
+                continue;
+            }
+            $ui->outputData(sprintf("[PEAR] %-15s- upgraded:  %s", $package, $new_ver));
+        } else {
+            if ($force) {
+                $options['force'] = true;
+                $installer->setOptions($options);
+                $dp = array($downloaderpackage);
+                $installer->setDownloadedPackages($dp);
+                $err = $installer->install($downloaderpackage, $options);
+                if (PEAR::isError($err)) {
+                    $ui->outputData(sprintf("[PEAR] %s: %s", $package, $err->getMessage()));
+                    continue;
+                }
+                $ui->outputData(sprintf("[PEAR] %-15s- installed: %s", $package, $new_ver));
+            } else {
+                $ui->outputData(sprintf("[PEAR] %-15s- already installed: %s", $package, $old_ver));
+            }
+        }
+    } else {
+        $options['nodeps'] = true;
+        $installer->setOptions($options);
+        $dp = array($downloaderpackage);
+        $installer->setDownloadedPackages($dp);
+        $err = $installer->install($downloaderpackage, $options);
+        if (PEAR::isError($err)) {
+            $ui->outputData(sprintf("[PEAR] %s: %s", $package, $err->getMessage()));
+            continue;
+        }
+        $ui->outputData(sprintf("[PEAR] %-15s- installed: %s", $package, $new_ver));
+    }
+    if ($package == 'PEAR') {
+        if (is_file($ufile = $config->getConfFile('user'))) {
+            $ui->outputData('Warning! a PEAR user config file already exists from ' .
+                            'a previous PEAR installation at ' .
+                            "'$ufile'. You may probably want to remove it.");
+        }
+        $config->set('verbose', 1, 'default');
+        if (isset($oldcachedir)) {
+            $config->set('cache_dir', $oldcachedir);
+        }
+        $data = array();
+        foreach ($config->getKeys() as $key) {
+            $data[$key] = $config->get($key);
+        }
+        $cnf_file = $config->getConfFile('system');
+        if (!empty($install_root)) {
+            $cnf_file = $install_root . DIRECTORY_SEPARATOR . $cnf_file;
+        }
+        $config->writeConfigFile($cnf_file, 'system', $data);
+        $ui->outputData('Wrote PEAR system config file at: ' . $cnf_file);
+        $ui->outputData('You may want to add: ' . $config->get('php_dir') . ' to your php.ini include_path');
+    }
+}
+?>
 <?php
 /**
  * The OS_Guess class
@@ -6770,7 +6935,7 @@ foreach ($install_files as $package => $instfile) {
  * @author     Gregory Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Guess.php,v 1.29 2009/04/09 22:24:12 dufuz Exp $
+ * @version    CVS: $Id: Guess.php 278521 2009-04-09 22:24:12Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since PEAR 0.1
  */
@@ -6847,7 +7012,7 @@ foreach ($install_files as $package => $instfile) {
  * @author     Gregory Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -7095,8 +7260,8 @@ class OS_Guess
  * indent-tabs-mode: nil
  * c-basic-offset: 4
  * End:
- */package2.xml                                                                                        100664     764     764       123245      100664   6362                                                                                                                                                                                                                                                                                                                                                                      <?xml version="1.0" encoding="UTF-8"?>
-<package packagerversion="1.8.0" version="2.0" xmlns="http://pear.php.net/dtd/package-2.0" xmlns:tasks="http://pear.php.net/dtd/tasks-1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://pear.php.net/dtd/tasks-1.0 http://pear.php.net/dtd/tasks-1.0.xsd http://pear.php.net/dtd/package-2.0 http://pear.php.net/dtd/package-2.0.xsd">
+ */package2.xml                                                                                        100664     764     764       117255      100664   6366                                                                                                                                                                                                                                                                                                                                                                      <?xml version="1.0" encoding="UTF-8"?>
+<package packagerversion="1.9.0RC4" version="2.0" xmlns="http://pear.php.net/dtd/package-2.0" xmlns:tasks="http://pear.php.net/dtd/tasks-1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://pear.php.net/dtd/tasks-1.0 http://pear.php.net/dtd/tasks-1.0.xsd http://pear.php.net/dtd/package-2.0 http://pear.php.net/dtd/package-2.0.xsd">
  <name>PEAR</name>
  <channel>pear.php.net</channel>
  <summary>PEAR Base System</summary>
@@ -7178,325 +7343,246 @@ class OS_Guess
   <email>mj at php.net</email>
   <active>no</active>
  </helper>
- <date>2009-04-10</date>
- <time>21:01:25</time>
+ <date>2009-09-03</date>
+ <time>13:13:10</time>
  <version>
-  <release>1.8.0</release>
-  <api>1.8.0</api>
+  <release>1.9.0</release>
+  <api>1.9.0</api>
  </version>
  <stability>
   <release>stable</release>
   <api>stable</api>
  </stability>
- <license uri="http://opensource.org/licenses/bsd-license.php New BSD License">New BSD License</license>
+ <license uri="http://opensource.org/licenses/bsd-license.php">New BSD License</license>
  <notes>
-Changes since RC1:
-  * Fix Bug #14792: Bad md5sum for files with replaced content [dufuz]
-  * Fix Bug #16057:-r is limited to 4 directories in depth [dufuz]
-  * Fix Bug #16077: PEAR5::getStaticProperty does not return a reference to the property [dufuz]
-
-  Remove custom XML_Util class in favor of using upstream XML_Util package as dependency
-
-RC1 Release Notes:
-  * Fix Bug #14331: pear cvstag only works from inside the package directory [dufuz]
-  * Fix Bug #16045: E_Notice: Undefined index: channel in PEAR/DependencyDB.php [dufuz]
-
-  * Implemented Request #11230: better error message when mirror not in channel.xml file [dufuz]
-  * Implemented Request #13150: Add support for following HTTP 302 redirects [dufuz]
-
-Alpha1 Release Notes:
-  * Implement Request #10373: if pref_state=stable and installed package=beta, allow up to latest beta version [dufuz]
-  * Implement Request #10581: login / logout should map to channel-login / channel-logout [dufuz]
-  * Implement Request #10825: Only display the &quot;invalid or missing package file&quot;-error if it makes sense [dufuz]
-  * Implement Request #11170: script to generate Command/[command].xml [dufuz]
-  * Implement Request #11176: improve channel ... has updated its protocols message [dufuz]
-  * Implement Request #12706: pear list -a hard to read [dufuz]
-  * Implement Request #11353: upgrade-all and upgrade commands to upgrade within the same stability level [dufuz]
-  * Implement Request #13015: Add https discovery for channel.xml [dufuz / initial patch by Martin Roos]
-  * Implement Request #13927: install-pear.php should have option to set www_dir [timj]
-  * Implement Request #14324: Make the pear install command behave similar to apt-get [dufuz]
-  * Implement Request #14325: make pear upgrade with no params behave like pear upgrade-all [dufuz]
-    - upgrade-all can be considered deprecated in favor of calling upgrade with no parameters to replicate
-      better what other package managers are doing. upgrade-all will still work as intended.
-  * Implement Request #14504: add a channel parameter support to the upgrade function [dufuz]
-    - Options -c ezc and --channel=ezc got added to upgrade and upgrade-all to allow for
-      channel specific upgrades
-  * Implement Request #14556: install-pear-nozlib.phar should get download_dir config and other options [cweiske]
-  * Implement Request #15566: Add doc.php.net as a default channel [dufuz / saltybeagle]
-
-  * Fix PHP Bug #43857: --program-suffix not always reflected everywhere [cellog]
-  * Fix PHP Bug #47323: strotime warnings in make install [dufuz]
-
-  * Fix Bug #13908: pear info command and maintainers inactive not mentioned [dufuz]
-  * Fix Bug #13926: install-pear.php does not set cfg_dir if -d option set with no -c option [timj]
-  * Fix Bug #13943: tests fail when php.exe path contains spaces [dufuz / jorrit]
-  * Fix Bug #13953: config-set/config-show with channel alias fail [cellog]
-  * Fix Bug #13958: When a phpt tests exit() or die() xdebug coverage is not generated, patch by izi (David Jean Louis) [izi / dufuz]
-  * Fix Bug #14041: Unpredictable unit test processing sequence [dufuz]
-  * Fix Bug #14140: Strict warning not suppressed in the shutdown function [dufuz]
-  * Fix Bug #14210: pear list -ia brings warnings [dufuz]
-  * Fix Bug #14274: PEAR packager mangles package.xml encoding, then complains about it [dufuz]
-  * Fix Bug #14287: cannot upgrade from stable to beta via -beta when config is set to stable [dufuz]
-  * Fix Bug #14300: Package files themselves can not be served over https [dufuz / initial patch by Martin Roos]
-  * Fix Bug #14437: openbasedir warning when loading config [dufuz]
-  * Fix Bug #14558: PackageFile.php creates tmp directory outside configured temp_dir [cweiske]
-  * Fix Bug #14947: downloadHttp() is missing Host part of the HTTP Request when using Proxy [ifeghali]
-  * Fix Bug #14977: PEAR/Frontend.php doesn&apos;t require_once PEAR.php [dufuz]
-  * Fix Bug #15750: Unreachable code in PEAR_Downloader [dufuz]
-  * Fix Bug #15979: Package files incorrectly removed when splitting a package into multiple pkgs [dufuz]
-  * Fix Bug #15914: pear upgrade installs different version if desired version not found [dufuz]
-
-  NOTE!
-  Functions that have been deprecated for 3+ years in PEAR_Common, please take a moment
-  to migrate over to one of the alternatives that have ben provided:
-  * PEAR_Common-&gt;downloadHttp (use PEAR_Downloader-&gt;downloadHttp instead)
-  * PEAR_Common-&gt;infoFromTgzFile (use PEAR_PackageFile-&gt;fromTgzFile instead)
-  * PEAR_Common-&gt;infoFromDescriptionFile (use PEAR_PackageFile-&gt;fromPackageFile instead)
-  * PEAR_Common-&gt;infoFromString (use PEAR_PackageFile-&gt;fromXmlstring instead)
-  * PEAR_Common-&gt;infoFromArray (use PEAR_PackageFile-&gt;fromAnyFile instead)
-  * PEAR_Common-&gt;xmlFromInfo (use a PEAR_PackageFile_v* object&apos;s generator instead)
-  * PEAR_Common-&gt;validatePackageInfo (use the validation of PEAR_PackageFile objects)
-  * PEAR_Common-&gt;analyzeSourceCode (use a PEAR_PackageFile_v* object instead)
-  * PEAR_Common-&gt;detectDependencies (use PEAR_Downloader_Package-&gt;detectDependencies instead)
-  * PEAR_Common-&gt;buildProvidesArray (use PEAR_PackageFile_v1-&gt;_buildProvidesArray or
-    PEAR_PackageFile_v2_Validator-&gt;_buildProvidesArray)
-
-  PHP 4.4 and 5.1.6 are now the minimum PHP requirements, for brave souls
-  pear upgrade -f PEAR will allow people with lower versions
-  to upgrade to this release but no guarantees will be made that it will work properly.
-
-  Support for XML RPC channels has been dropped - The only ones that used it
-  (pear.php.net and pecl.php.net) have used the REST interface for years now.
-  SOAP support also removed as it was only proof of concept.
-
-  Move codebase from the PHP License to New BSD 2 clause license
+* Fix  Bug #16547: The phar for PEAR installer uses ereg() which is deprecated [dufuz]
  </notes>
  <contents>
   <dir name="/">
-   <file md5sum="c5b7cabb1fd56e54d51de624b10e7e0a" name="OS/Guess.php" role="php">
+   <file md5sum="f063d5b84d03538b85f05cde9aae8037" name="OS/Guess.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="58e6a076eaedbcfa157080c122bb0f6b" name="PEAR/ChannelFile/Parser.php" role="php">
+   <file md5sum="e839d4a327219441507bd5de7409ee5b" name="PEAR/ChannelFile/Parser.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="8fd87e64002e11fd86eb2f3fbfee6599" name="PEAR/Command/Auth.xml" role="php" />
-   <file md5sum="cf9d055aabc38596be6729d63919f0a1" name="PEAR/Command/Auth.php" role="php">
+   <file md5sum="7d3f1696902faf5442059393e541ad2d" name="PEAR/Command/Auth.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="483dd90056453bc93314472a66388057" name="PEAR/Command/Build.xml" role="php" />
-   <file md5sum="e01afa618052f88b2ffe0c037c7892d2" name="PEAR/Command/Build.php" role="php">
+   <file md5sum="73602fd7f051eaf8d37452d0e3063bdb" name="PEAR/Command/Build.xml" role="php" />
+   <file md5sum="99e6dae6555a272f16f1cf2265d221c0" name="PEAR/Command/Build.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="dec008667dd7c3cb3740b5aa7d3ac619" name="PEAR/Command/Channels.xml" role="php" />
-   <file md5sum="d32278c6471cc9276890f72645d3993c" name="PEAR/Command/Channels.php" role="php">
+   <file md5sum="6d5aab4d4308c3005b5f584c7783a031" name="PEAR/Command/Channels.xml" role="php" />
+   <file md5sum="63a395cf6c752e8121e1fa2ae1f9ac28" name="PEAR/Command/Channels.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="86b458158392cdba2f2c62131a238a6b" name="PEAR/Command/Common.php" role="php">
+   <file md5sum="dc4961036d632859bb1bda5e32a8c346" name="PEAR/Command/Common.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="91f189cb9423b5e87ee0abc5ea1a2be3" name="PEAR/Command/Config.xml" role="php" />
-   <file md5sum="c1ff72162e26064888987e77ff2fb851" name="PEAR/Command/Config.php" role="php">
+   <file md5sum="f0c106b4ba5e12236c59b161b75f4182" name="PEAR/Command/Config.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="54c542190627909c2ccabdc844dbd5e9" name="PEAR/Command/Install.xml" role="php" />
-   <file md5sum="8b564d859a10dc4c881d8275793305d5" name="PEAR/Command/Install.php" role="php">
+   <file md5sum="2db0386b865d3f9a29f9126728722ece" name="PEAR/Command/Install.xml" role="php" />
+   <file md5sum="034593b2194bf8feb689722833e1c9b0" name="PEAR/Command/Install.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="5cb62a04c0a268f4edd64a49a3895c92" name="PEAR/Command/Mirror.xml" role="php" />
-   <file md5sum="6a05eff162094574269851bf8d2eb86e" name="PEAR/Command/Mirror.php" role="php">
+   <file md5sum="8bc9265e1046ec67a85571557515bb1b" name="PEAR/Command/Mirror.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="fedae0702f3bdc32c37a9912dc8fe171" name="PEAR/Command/Package.xml" role="php" />
-   <file md5sum="db75e44ce6d61a2d84271cefc847ee67" name="PEAR/Command/Package.php" role="php">
+   <file md5sum="6c3061a594644e49b0648798dce6de32" name="PEAR/Command/Package.xml" role="php" />
+   <file md5sum="2d4e5f5200fdbdbb5f1c2bf0a27ab754" name="PEAR/Command/Package.php" role="php">
     <tasks:replace from="@DATA-DIR@" to="data_dir" type="pear-config" />
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="28dc842ea725d8787b9f9c3dbca5aa22" name="PEAR/Command/Pickle.xml" role="php" />
-   <file md5sum="a56f511146a5aceded33637631c17b74" name="PEAR/Command/Pickle.php" role="php">
+   <file md5sum="6a794c2a0545fff7300217dd6e133c17" name="PEAR/Command/Pickle.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="49b046cfc14747f0365e02e9c3f0e6dc" name="PEAR/Command/Registry.xml" role="php" />
-   <file md5sum="c28030095775bcf060571ffceefe17da" name="PEAR/Command/Registry.php" role="php">
+   <file md5sum="567687617b7f406bd1ba55e37060edf8" name="PEAR/Command/Registry.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="29c02e823879b4e3e291f6b36fb339f1" name="PEAR/Command/Remote.xml" role="php" />
-   <file md5sum="170e88fb6930a13c348ece2c2c915ee8" name="PEAR/Command/Remote.php" role="php">
+   <file md5sum="374366b6f361c401ae22edc5b76b7a90" name="PEAR/Command/Remote.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="ff80fba20e3637a1d53a68b9fa017197" name="PEAR/Command/Test.xml" role="php" />
-   <file md5sum="a2684aabe6246adb0e4483f860d5e11a" name="PEAR/Command/Test.php" role="php">
+   <file md5sum="a50c32015005e0761cc3b04679b29ed0" name="PEAR/Command/Test.xml" role="php" />
+   <file md5sum="01252c8d6c005f53f250344bb4453a59" name="PEAR/Command/Test.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="d2ff9bb14e39abf0ed122b806a086a6d" name="PEAR/Downloader/Package.php" role="php">
+   <file md5sum="73a70ef0ac6d521fcbc972de10341bbe" name="PEAR/Downloader/Package.php" role="php">
     <tasks:replace from="@PEAR-VER@" to="version" type="package-info" />
    </file>
-   <file md5sum="ad5d4d946dfd6b990007450e30b3dfb1" name="PEAR/Frontend/CLI.php" role="php">
+   <file md5sum="e613fdf2c8090bf8f7289dbeaa06a97c" name="PEAR/Frontend/CLI.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="3c882c3ef0b2c42516ffecefcff26f9e" name="PEAR/Installer/Role/Common.php" role="php">
+   <file md5sum="d3c3a546ced9a12889eda5e368583944" name="PEAR/Installer/Role/Common.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="d8c62e6275e3aaa7784290912406092c" name="PEAR/Installer/Role/Cfg.xml" role="php" />
-   <file md5sum="97524d269a5289ca703b906f30906942" name="PEAR/Installer/Role/Cfg.php" role="php">
+   <file md5sum="a3bb43296f00bd5459a0fbf8314f8917" name="PEAR/Installer/Role/Cfg.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="89a4a2a286e842d45a98974f40a0565c" name="PEAR/Installer/Role/Data.xml" role="php" />
-   <file md5sum="de4de130aa45ebbca82432bdc0b5e929" name="PEAR/Installer/Role/Data.php" role="php">
+   <file md5sum="2cb74a7dd5fdfce5b78717e1847d463c" name="PEAR/Installer/Role/Data.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="b1ce0fe105251c3b75209d6518ee69ac" name="PEAR/Installer/Role/Doc.xml" role="php" />
-   <file md5sum="747444f4c829d356d812eaf7c9c0b099" name="PEAR/Installer/Role/Doc.php" role="php">
+   <file md5sum="5c0b53e95ae25306da82cf6dd87da4dc" name="PEAR/Installer/Role/Doc.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="af71c0ad42d16a323afe24a4f884ef15" name="PEAR/Installer/Role/Ext.xml" role="php" />
-   <file md5sum="14cedff64246d06ac73597cc7008e9fe" name="PEAR/Installer/Role/Ext.php" role="php">
+   <file md5sum="b3c70e10e63273ef1f2e5cd0a2bd33e8" name="PEAR/Installer/Role/Ext.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="ef88f0321d3e481c2130c95122cf76d8" name="PEAR/Installer/Role/Php.xml" role="php" />
-   <file md5sum="3ffee54fd27e11c57805de49ccb9599d" name="PEAR/Installer/Role/Php.php" role="php">
+   <file md5sum="9e4a34e2a332b704417590cb734ffc93" name="PEAR/Installer/Role/Php.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="746461dc3b48af6d24094cb0211608f2" name="PEAR/Installer/Role/Script.xml" role="php" />
-   <file md5sum="f4c2288d22e16db5222e9423ac27ba3f" name="PEAR/Installer/Role/Script.php" role="php">
+   <file md5sum="eb20ad9051db4db53a1c30e9f1b0dab5" name="PEAR/Installer/Role/Script.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="999bc34ddef1d3cfc1d03ac64a45d680" name="PEAR/Installer/Role/Src.xml" role="php" />
-   <file md5sum="0d1ddded65dbd723ac268c76b5b52a18" name="PEAR/Installer/Role/Src.php" role="php">
+   <file md5sum="e147d63f168ea156fc2be38caaa63804" name="PEAR/Installer/Role/Src.xml" role="php" />
+   <file md5sum="656ad25a2fa1a13f53aad6121edfba91" name="PEAR/Installer/Role/Src.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="a24b596ec987aa5688fc19e8ed4e97ea" name="PEAR/Installer/Role/Test.xml" role="php" />
-   <file md5sum="9a955fcc40e6ff3187604dc71af21d2a" name="PEAR/Installer/Role/Test.php" role="php">
+   <file md5sum="5601a755c633dafb639a8fbd1abe0261" name="PEAR/Installer/Role/Test.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="26f696fe4e32a1a4d95441ba8a9ec66e" name="PEAR/Installer/Role/Www.xml" role="php" />
-   <file md5sum="1776b898ec03d9212a0b9b85a5841dcf" name="PEAR/Installer/Role/Www.php" role="php">
+   <file md5sum="7641e71c5785bb33a4261ebe25ed0fd7" name="PEAR/Installer/Role/Www.xml" role="php" />
+   <file md5sum="8ab36d60bc9eb361885d7d901b107c0c" name="PEAR/Installer/Role/Www.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="935f9dc1ad736be6f92889414b477a23" name="PEAR/Installer/Role.php" role="php">
+   <file md5sum="0dab463a3402a0401616c7a1630bebcb" name="PEAR/Installer/Role.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="59655b9d4816cc1e94a661764b49e229" name="PEAR/PackageFile/Generator/v1.php" role="php">
+   <file md5sum="cd8b1ef4c311e0e4f5a00e5e36d48d43" name="PEAR/PackageFile/Generator/v1.php" role="php">
     <tasks:replace from="@PEAR-VER@" to="version" type="package-info" />
    </file>
-   <file md5sum="2a25244b486984ef074a5023865969b9" name="PEAR/PackageFile/Generator/v2.php" role="php">
+   <file md5sum="f7ed15b3d6d1aab0b6f8ee2fe0d9d3db" name="PEAR/PackageFile/Generator/v2.php" role="php">
     <tasks:replace from="@PEAR-VER@" to="version" type="package-info" />
    </file>
-   <file md5sum="50058789604936483b9e82c5990f5751" name="PEAR/PackageFile/Parser/v1.php" role="php">
+   <file md5sum="7d3828c0f41aadc34d948f5215c4cd66" name="PEAR/PackageFile/Parser/v1.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="eb78e5f34b4e0ae993fe2f43830ca367" name="PEAR/PackageFile/Parser/v2.php" role="php">
+   <file md5sum="a5f847fdba24116593efc223425a9609" name="PEAR/PackageFile/Parser/v2.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="3863e2343baa5cfab1c4c1f386deb9ba" name="PEAR/PackageFile/v2/rw.php" role="php">
+   <file md5sum="9a159d7f8e70bf9f57f9ade64dd5e377" name="PEAR/PackageFile/v2/rw.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="105d1ef053e38954ef32b056fe057101" name="PEAR/PackageFile/v2/Validator.php" role="php">
+   <file md5sum="cf2b5655d9accc025e5cf5f0476302a8" name="PEAR/PackageFile/v2/Validator.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="d1001b5d6336ab4e218c72624cf591d0" name="PEAR/PackageFile/v1.php" role="php">
+   <file md5sum="7736b857a1153b02453d42dd476d6f8a" name="PEAR/PackageFile/v1.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="9170859737fc3c16a0a380acb036c871" name="PEAR/PackageFile/v2.php" role="php">
+   <file md5sum="7026083ae0b038045dc117d68dc32a0a" name="PEAR/PackageFile/v2.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="71161e2ad26859b65ade1121df4e581c" name="PEAR/REST/10.php" role="php">
+   <file md5sum="b0b343c594552895492692d52561bc52" name="PEAR/REST/10.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="226d07e4adaf0cffa766a61a60674614" name="PEAR/REST/11.php" role="php">
+   <file md5sum="41f230e5d3282221e6b55466cb0510d3" name="PEAR/REST/11.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="3cd456e38ecc49a3d2494ed3d2aa10af" name="PEAR/REST/13.php" role="php">
+   <file md5sum="897908bf87ac9ae617a0a42e13f8e0cd" name="PEAR/REST/13.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="4205d96470d330b79785470092da51b7" name="PEAR/Task/Postinstallscript/rw.php" role="php">
+   <file md5sum="bff16b5498aa831d106061ebbaba484c" name="PEAR/Task/Postinstallscript/rw.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="5c493ff8705bcd75745679cf946ccce3" name="PEAR/Task/Replace/rw.php" role="php">
+   <file md5sum="d4f525ae7d94c48662d45769643abada" name="PEAR/Task/Replace/rw.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="47f9acf9063cf8709d34adc9fd506e22" name="PEAR/Task/Unixeol/rw.php" role="php">
+   <file md5sum="0787e483b91cb6842b9cfedbb486aabf" name="PEAR/Task/Unixeol/rw.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="36d60522e57f34da581af0595dc02df3" name="PEAR/Task/Windowseol/rw.php" role="php">
+   <file md5sum="a5545cfac22a53d0aad99f4acdbee50c" name="PEAR/Task/Windowseol/rw.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="3e8d8a967da5a7571331819a2b340150" name="PEAR/Task/Common.php" role="php">
+   <file md5sum="e61537de629cb2f7f7e1bc497038902e" name="PEAR/Task/Common.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="542744e38c5f49462047c6b0f21b27be" name="PEAR/Task/Postinstallscript.php" role="php">
+   <file md5sum="34d4c4f16734388faca7e418ab206f68" name="PEAR/Task/Postinstallscript.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="fe0e5e543a72531908f9feedeb904384" name="PEAR/Task/Replace.php" role="php">
+   <file md5sum="0fecedc2f99e5f010b327650c353e4db" name="PEAR/Task/Replace.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="1e4ab461f8c59644fba160eff3729f42" name="PEAR/Task/Unixeol.php" role="php">
+   <file md5sum="85ee9fd0fa58d4aef2161d5ac5d9b539" name="PEAR/Task/Unixeol.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="20ae133e8f43ff99c2ab25f12dbd52a6" name="PEAR/Task/Windowseol.php" role="php">
+   <file md5sum="33bc10b55f7c90425054024b42d0e944" name="PEAR/Task/Windowseol.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="70389318e500120b2fdd6df9cf9eb9e2" name="PEAR/Validator/PECL.php" role="php">
+   <file md5sum="a18f1a10bb85cc988f7c2de9914c1e9f" name="PEAR/Validator/PECL.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="8dff2754449b92d30700617b0d95c5b3" name="PEAR/Autoloader.php" role="php">
+   <file md5sum="b6d6b167ca1514d0765533d4abafca1d" name="PEAR/Autoloader.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="6fedb21642af9a4a5dac405b8f335874" name="PEAR/Builder.php" role="php">
+   <file md5sum="d9d3b94e0d1bf2f2c377a5cd8201481c" name="PEAR/Builder.php" role="php">
     <tasks:replace from="@PEAR-VER@" to="version" type="package-info" />
    </file>
-   <file md5sum="c0ca2d8695b28855002f8d2675a88519" name="PEAR/ChannelFile.php" role="php">
+   <file md5sum="f9d18b3c198a2a0f0771036c6b0404f7" name="PEAR/ChannelFile.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="7b0a88899e6ff37694546a9ff32ed6f8" name="PEAR/Command.php" role="php">
+   <file md5sum="150c15a2fb2fd57166ca8276e29cb74b" name="PEAR/Command.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="e76884b29acc9273c3cb13c55734ba9b" name="PEAR/Common.php" role="php">
+   <file md5sum="7c0ff45e0ee9df0ddbaa9b8c4c31b2fd" name="PEAR/Common.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="09ede5947b2145f79074c6df4ecdbe5a" name="PEAR/Config.php" role="php">
+   <file md5sum="5080a36f685fcef9b160617e8cb02870" name="PEAR/Config.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="3b0923bb6eb52049b57b1a1553a93cff" name="PEAR/DependencyDB.php" role="php">
+   <file md5sum="c161acaf73f7938ea48b3165d891998b" name="PEAR/DependencyDB.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="20ba6fb65adce82c8ad000f2d622f69c" name="PEAR/Dependency2.php" role="php">
+   <file md5sum="b0d1ee5d0acd02ca9351e076f73cc9da" name="PEAR/Dependency2.php" role="php">
     <tasks:replace from="@PEAR-VER@" to="version" type="package-info" />
    </file>
-   <file md5sum="1029b9ad5560624b9d4f17838d02983f" name="PEAR/Downloader.php" role="php">
+   <file md5sum="2185eb7a493f863ea3d3510195e7c901" name="PEAR/Downloader.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="278eefd89ba1d74a62c4436dda6dfca8" name="PEAR/ErrorStack.php" role="php">
+   <file md5sum="33ce30b4478cdb76e29bd75058c842e3" name="PEAR/ErrorStack.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="abf45593961edd5bb1f92d70e4623997" name="PEAR/Exception.php" role="php">
+   <file md5sum="f364e75223744d460a6bb08420ac94f9" name="PEAR/Exception.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="e0e4cbcec4a972fbad779d0f9d323120" name="PEAR/FixPHP5PEARWarnings.php" role="php" />
-   <file md5sum="68f488516741f6f8a3af57c16678e0fd" name="PEAR/Frontend.php" role="php">
+   <file md5sum="52c3acdba716110657f7bf86ca2012e1" name="PEAR/Frontend.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="4e03c62b818773511b1cc25ef4061bb9" name="PEAR/Installer.php" role="php">
+   <file md5sum="45f4c064607a7d3d4f68b0f06f98db5c" name="PEAR/Installer.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="8078d5d41ed18a6fe6eefe9abe68e5b0" name="PEAR/PackageFile.php" role="php">
+   <file md5sum="df9c5cc34b6fbbf661d534cecb315c9f" name="PEAR/PackageFile.php" role="php">
     <tasks:replace from="@PEAR-VER@" to="version" type="package-info" />
    </file>
-   <file md5sum="7448e3df885514343512094b946f475b" name="PEAR/Packager.php" role="php">
+   <file md5sum="821b72d18cbdc2e8b9c5087bc9b99854" name="PEAR/Packager.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="45503b28720431d9ad8d64c36bb87bc1" name="PEAR/Registry.php" role="php">
+   <file md5sum="a58437db39d3d71bb93f44a660334720" name="PEAR/Registry.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="63a2caea137e35fadd6d9085b6894d94" name="PEAR/REST.php" role="php">
+   <file md5sum="28e5f3b905280051309e65d3e85d0b15" name="PEAR/REST.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="5c2b6d2791b94bf8d98cff37dc6f1bfc" name="PEAR/RunTest.php" role="php">
+   <file md5sum="34a0d9008da01b3987a610d94837a80c" name="PEAR/RunTest.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="4235e4ed6a3be97da6eff9c069e93516" name="PEAR/Validate.php" role="php">
+   <file md5sum="c5ea781c8abb14ff62b04b6db5e10e0f" name="PEAR/Validate.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="f3e6145dd13e447ea0d8e9a0e3f7812b" name="PEAR/XMLParser.php" role="php">
+   <file md5sum="c6de49d413a1cf97a1f8a4668766e3ab" name="PEAR/XMLParser.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file baseinstalldir="/" md5sum="bd65b087b7707463525e9f0092337793" name="scripts/pear.bat" role="script">
@@ -7505,7 +7591,7 @@ Alpha1 Release Notes:
     <tasks:replace from="@include_path@" to="php_dir" type="pear-config" />
     <tasks:windowseol />
    </file>
-   <file baseinstalldir="/" md5sum="f92ee8acc4f00a7ca9ffedc1fe959b69" name="scripts/peardev.bat" role="script">
+   <file baseinstalldir="/" md5sum="92cafd038c7d6a212111c84ca4907a13" name="scripts/peardev.bat" role="script">
     <tasks:replace from="@bin_dir@" to="bin_dir" type="pear-config" />
     <tasks:replace from="@php_bin@" to="php_bin" type="pear-config" />
     <tasks:replace from="@include_path@" to="php_dir" type="pear-config" />
@@ -7538,26 +7624,27 @@ Alpha1 Release Notes:
     <tasks:replace from="@include_path@" to="php_dir" type="pear-config" />
     <tasks:unixeol />
    </file>
-   <file baseinstalldir="/" md5sum="d52e189171fbd1b50aeb7fd9ae79f3f5" name="scripts/pearcmd.php" role="php">
+   <file baseinstalldir="/" md5sum="55426bdbfd8e1bc050a79e3c6095d8e5" name="scripts/pearcmd.php" role="php">
     <tasks:replace from="@php_bin@" to="php_bin" type="pear-config" />
     <tasks:replace from="@php_dir@" to="php_dir" type="pear-config" />
     <tasks:replace from="@pear_version@" to="version" type="package-info" />
     <tasks:replace from="@include_path@" to="php_dir" type="pear-config" />
    </file>
-   <file baseinstalldir="/" md5sum="c7bd82e5f20e548980aa1f0bae4427a4" name="scripts/peclcmd.php" role="php">
+   <file baseinstalldir="/" md5sum="320849b646e4cdaeca543af666524e73" name="scripts/peclcmd.php" role="php">
     <tasks:replace from="@php_bin@" to="php_bin" type="pear-config" />
     <tasks:replace from="@php_dir@" to="php_dir" type="pear-config" />
     <tasks:replace from="@pear_version@" to="version" type="package-info" />
     <tasks:replace from="@include_path@" to="php_dir" type="pear-config" />
    </file>
    <file md5sum="45b44486d8090de17b2a8b4211fab247" name="LICENSE" role="doc" />
-   <file md5sum="671e6690634062ee521d2027a9971f22" name="INSTALL" role="doc" />
-   <file md5sum="ca444da9174e05f8a0dc71d8ee47900f" name="package.dtd" role="data" />
-   <file md5sum="0965c4c961762dc0c99ef4e62f69cd25" name="PEAR.php" role="php">
+   <file md5sum="45b1a9dcc368539cb8f2a65c30b2f453" name="INSTALL" role="doc" />
+   <file md5sum="4a49bc83a392934e57af45c70a589fda" name="package.dtd" role="data" />
+   <file md5sum="1a8f67d58009372a6cbcddd638b128cf" name="PEAR5.php" role="php" />
+   <file md5sum="4e4941a59ed97ca61c93deb6a7ff918c" name="PEAR.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
-   <file md5sum="ae70dd96347165e048bd37521d6437f2" name="README" role="doc" />
-   <file md5sum="9aeb41ebb0a0072a9b537d0b3d9767a8" name="System.php" role="php">
+   <file md5sum="d3b517006b304817731eb77cc2154258" name="README" role="doc" />
+   <file md5sum="8bf4cfb58d10d72b5082c3022c887710" name="System.php" role="php">
     <tasks:replace from="@package_version@" to="version" type="package-info" />
    </file>
    <file md5sum="acd010e3bc43c0f72df584acde7b9158" name="template.spec" role="data" />
@@ -7684,7 +7771,7 @@ Alpha1 Release Notes:
     <api>stable</api>
    </stability>
    <date>2009-03-09</date>
-   <license uri="http://opensource.org/licenses/bsd-license.php New BSD License">New BSD License</license>
+   <license uri="http://opensource.org/licenses/bsd-license.php">New BSD License</license>
    <notes>
 * Implement Request #10373: if pref_state=stable and installed package=beta, allow up to latest beta version [dufuz]
 * Implement Request #10581: login / logout should map to channel-login / channel-logout [dufuz]
@@ -7763,7 +7850,7 @@ Move codebase from the PHP License to New BSD 2 clause license
     <release>beta</release>
     <api>stable</api>
    </stability>
-   <license uri="http://opensource.org/licenses/bsd-license.php New BSD License">New BSD License</license>
+   <license uri="http://opensource.org/licenses/bsd-license.php">New BSD License</license>
    <notes>
 * Fix Bug #14331: pear cvstag only works from inside the package directory [dufuz]
 * Fix Bug #16045: E_Notice: Undefined index: channel in PEAR/DependencyDB.php [dufuz]
@@ -7782,7 +7869,7 @@ Move codebase from the PHP License to New BSD 2 clause license
     <release>stable</release>
     <api>stable</api>
    </stability>
-   <license uri="http://opensource.org/licenses/bsd-license.php New BSD License">New BSD License</license>
+   <license uri="http://opensource.org/licenses/bsd-license.php">New BSD License</license>
    <notes>
 Changes since RC1:
   * Fix Bug #14792: Bad md5sum for files with replaced content [dufuz]
@@ -7866,9 +7953,116 @@ Alpha1 Release Notes:
   Move codebase from the PHP License to New BSD 2 clause license
    </notes>
   </release>
+  <release>
+   <date>2009-04-15</date>
+   <version>
+    <release>1.8.1</release>
+    <api>1.8.1</api>
+   </version>
+   <stability>
+    <release>stable</release>
+    <api>stable</api>
+   </stability>
+   <license uri="http://opensource.org/licenses/bsd-license.php">New BSD License</license>
+   <notes>
+* Fix Bug #16099 	PEAR crash on PHP4 (parse error) [dufuz]
+   </notes>
+  </release>
+  <release>
+   <date>2009-08-18</date>
+   <version>
+    <release>1.9.0RC1</release>
+    <api>1.9.0RC1</api>
+   </version>
+   <stability>
+    <release>beta</release>
+    <api>stable</api>
+   </stability>
+   <license uri="http://opensource.org/licenses/bsd-license.php">New BSD License</license>
+   <notes>
+* Implement Request #16213: add alias to list-channels output [dufuz]
+* Implement Request #16378: pear svntag [dufuz]
+* Implement Request #16386: PEAR_Config::remove() does not support specifying a channel [timj]
+* Implement Request #16396: package-dependencies should allow package names [dufuz]
+
+* Fix Bug #11181: pear requests channel.xml from main server instead from mirror [dufuz]
+* Fix Bug #14493: pear install --offline doesn&apos;t print out errors [dufuz]
+* Fix Bug #11348: pear package-dependencies isn&apos;t well explained [dufuz]
+* Fix Bug #16108: PEAR_PackageFile_Generator_v2 PHP4 parse error when running upgrade-all [dufuz]
+* Fix Bug #16113: Installing certain packages fails due incorrect encoding handling [dufuz]
+* Fix Bug #16122: PEAR RunTest failed to run as expected [dufuz]
+* Fix Bug #16366: compiling 5.2.10 leads to non-functioning pear [dufuz]
+* Fix Bug #16387: channel-logout does not support logging out from a non-default channel [timj]
+* Fix Bug #16444: Setting preferred mirror fails [dufuz]
+* Fix the shutdown functions where a index might not exist and thus raise a notice [derick]
+   </notes>
+  </release>
+  <release>
+   <date>2009-08-20</date>
+   <version>
+    <release>1.9.0RC2</release>
+    <api>1.9.0RC2</api>
+   </version>
+   <stability>
+    <release>beta</release>
+    <api>stable</api>
+   </stability>
+   <license uri="http://opensource.org/licenses/bsd-license.php">New BSD License</license>
+   <notes>
+* REST 1.4 file was occasionally being included but REST 1.4 is not intended for this release cycle [dufuz]
+   </notes>
+  </release>
+  <release>
+   <date>2009-08-21</date>
+   <version>
+    <release>1.9.0RC3</release>
+    <api>1.9.0RC3</api>
+   </version>
+   <stability>
+    <release>beta</release>
+    <api>stable</api>
+   </stability>
+   <license uri="http://opensource.org/licenses/bsd-license.php">New BSD License</license>
+   <notes>
+* Improved svntag support to handle packages like PEAR it self [dufuz]
+   </notes>
+  </release>
+  <release>
+   <date>2009-08-23</date>
+   <version>
+    <release>1.9.0RC4</release>
+    <api>1.9.0RC4</api>
+   </version>
+   <stability>
+    <release>beta</release>
+    <api>stable</api>
+   </stability>
+   <license uri="http://opensource.org/licenses/bsd-license.php">New BSD License</license>
+   <notes>
+* Fixed a problem where the original channel could not be set as a preferred_mirror again [dufuz]
+* Make sure channel aliases can&apos;t be made to start with - [dufuz]
+* Output issues with pear search [dufuz]
+* Fixed couple of stray notices [dufuz]
+   </notes>
+  </release>
+  <release>
+   <date>2009-09-03</date>
+   <version>
+    <release>1.9.0</release>
+    <api>1.9.0</api>
+   </version>
+   <stability>
+    <release>stable</release>
+    <api>stable</api>
+   </stability>
+   <license uri="http://opensource.org/licenses/bsd-license.php">New BSD License</license>
+   <notes>
+* Fix  Bug #16547: The phar for PEAR installer uses ereg() which is deprecated [dufuz]
+   </notes>
+  </release>
  </changelog>
 </package>
-                                                                                                                                                                                                                                                                                                                                                           PEAR-1.8.0/OS/Guess.php                                                                             100664     764     764        24637      100664   7461                                                                                                                                                                                                                                                                                                                                                                      <?php
+                                                                                                                                                                                                                                                                                                                                                   PEAR-1.9.0/OS/Guess.php                                                                             100664     764     764        24634      100664   7457                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * The OS_Guess class
  *
@@ -7880,7 +8074,7 @@ Alpha1 Release Notes:
  * @author     Gregory Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Guess.php,v 1.29 2009/04/09 22:24:12 dufuz Exp $
+ * @version    CVS: $Id: Guess.php 278521 2009-04-09 22:24:12Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since PEAR 0.1
  */
@@ -7957,7 +8151,7 @@ Alpha1 Release Notes:
  * @author     Gregory Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -8205,7 +8399,7 @@ class OS_Guess
  * indent-tabs-mode: nil
  * c-basic-offset: 4
  * End:
- */                                                                                                 PEAR-1.8.0/PEAR/ChannelFile/Parser.php                                                              100664     764     764         3364      100664  12157                                                                                                                                                                                                                                                                                                                                                                      <?php
+ */                                                                                                    PEAR-1.9.0/PEAR/ChannelFile/Parser.php                                                              100664     764     764         3362      100664  12156                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_ChannelFile_Parser for parsing channel.xml
  *
@@ -8216,7 +8410,7 @@ class OS_Guess
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Parser.php,v 1.7 2009/02/24 23:39:07 dufuz Exp $
+ * @version    CVS: $Id: Parser.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -8233,7 +8427,7 @@ require_once 'PEAR/ChannelFile.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -8272,7 +8466,7 @@ class PEAR_ChannelFile_Parser extends PEAR_XMLParser
         $ret->setPackagefile($file, $archive);
         return $ret;
     }
-}                                                                                                                                                                                                                                                                            PEAR-1.8.0/PEAR/Command/Auth.xml                                                                    100777     764     764         2314      100777  11047                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
+}                                                                                                                                                                                                                                                                              PEAR-1.9.0/PEAR/Command/Auth.xml                                                                    100664     764     764         2314      100664  11036                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
  <login>
   <summary>Connects and authenticates to remote server [Deprecated in favor of channel-login]</summary>
   <function>doLogin</function>
@@ -8301,7 +8495,7 @@ Logs out from the remote server.  This command does not actually
 connect to the remote server, it only deletes the stored username and
 password from your user configuration.</doc>
  </logout>
-</commands>                                                                                                                                                                                                                                                                                                                    PEAR-1.8.0/PEAR/Command/Auth.php                                                                    100664     764     764         5141      100664  11025                                                                                                                                                                                                                                                                                                                                                                      <?php
+</commands>                                                                                                                                                                                                                                                                                                                    PEAR-1.9.0/PEAR/Command/Auth.php                                                                    100664     764     764         5136      100664  11032                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Command_Auth (login, logout commands)
  *
@@ -8313,7 +8507,7 @@ password from your user configuration.</doc>
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Auth.php,v 1.36 2009/02/24 23:39:29 dufuz Exp $
+ * @version    CVS: $Id: Auth.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  * @deprecated since 1.8.0alpha1
@@ -8333,7 +8527,7 @@ require_once 'PEAR/Command/Channels.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  * @deprecated since 1.8.0alpha1
@@ -8381,100 +8575,100 @@ password from your user configuration.',
     {
         parent::PEAR_Command_Channels($ui, $config);
     }
-}                                                                                                                                                                                                                                                                                                                                                                                                                               PEAR-1.8.0/PEAR/Command/Build.xml                                                                   100777     764     764          405      100777  11164                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
+}                                                                                                                                                                                                                                                                                                                                                                                                                                  PEAR-1.9.0/PEAR/Command/Build.xml                                                                   100664     764     764          404      100664  11152                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
  <build>
   <summary>Build an Extension From C Source</summary>
   <function>doBuild</function>
   <shortcut>b</shortcut>
   <options />
-  <doc>[package.xml]
+  <doc>[package.xml]
 Builds one or more extensions contained in a package.</doc>
  </build>
-</commands>                                                                                                                                                                                                                                                           PEAR-1.8.0/PEAR/Command/Build.php                                                                   100664     764     764         4602      100664  11164                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_Command_Auth (build command)
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Stig Bakken <ssb at php.net>
- * @author     Tomas V.V.Cox <cox at idecnet.com>
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Build.php,v 1.16 2009/02/24 23:39:29 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 0.1
- */
-
-/**
- * base class
- */
-require_once 'PEAR/Command/Common.php';
-
-/**
- * PEAR commands for building extensions.
- *
- * @category   pear
- * @package    PEAR
- * @author     Stig Bakken <ssb at php.net>
- * @author     Tomas V.V.Cox <cox at idecnet.com>
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 0.1
- */
-class PEAR_Command_Build extends PEAR_Command_Common
-{
-    var $commands = array(
-        'build' => array(
-            'summary' => 'Build an Extension From C Source',
-            'function' => 'doBuild',
-            'shortcut' => 'b',
-            'options' => array(),
-            'doc' => '[package.xml]
-Builds one or more extensions contained in a package.'
-            ),
-        );
-
-    /**
-     * PEAR_Command_Build constructor.
-     *
-     * @access public
-     */
-    function PEAR_Command_Build(&$ui, &$config)
-    {
-        parent::PEAR_Command_Common($ui, $config);
-    }
-
-    function doBuild($command, $options, $params)
-    {
-        require_once 'PEAR/Builder.php';
-        if (sizeof($params) < 1) {
-            $params[0] = 'package.xml';
-        }
-
-        $builder = &new PEAR_Builder($this->ui);
-        $this->debug = $this->config->get('verbose');
-        $err = $builder->build($params[0], array(&$this, 'buildCallback'));
-        if (PEAR::isError($err)) {
-            return $err;
-        }
-
-        return true;
-    }
-
-    function buildCallback($what, $data)
-    {
-        if (($what == 'cmdoutput' && $this->debug > 1) ||
-            ($what == 'output' && $this->debug > 0)) {
-            $this->ui->outputData(rtrim($data), 'build');
-        }
-    }
-}                                                                                                                              PEAR-1.8.0/PEAR/Command/Channels.xml                                                                100777     764     764        10032      100777  11715                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
+</commands>                                                                                                                                                                                                                                                            PEAR-1.9.0/PEAR/Command/Build.php                                                                   100664     764     764         4453      100664  11171                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_Command_Auth (build command)
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Stig Bakken <ssb at php.net>
+ * @author     Tomas V.V.Cox <cox at idecnet.com>
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Build.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 0.1
+ */
+
+/**
+ * base class
+ */
+require_once 'PEAR/Command/Common.php';
+
+/**
+ * PEAR commands for building extensions.
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Stig Bakken <ssb at php.net>
+ * @author     Tomas V.V.Cox <cox at idecnet.com>
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 0.1
+ */
+class PEAR_Command_Build extends PEAR_Command_Common
+{
+    var $commands = array(
+        'build' => array(
+            'summary' => 'Build an Extension From C Source',
+            'function' => 'doBuild',
+            'shortcut' => 'b',
+            'options' => array(),
+            'doc' => '[package.xml]
+Builds one or more extensions contained in a package.'
+            ),
+        );
+
+    /**
+     * PEAR_Command_Build constructor.
+     *
+     * @access public
+     */
+    function PEAR_Command_Build(&$ui, &$config)
+    {
+        parent::PEAR_Command_Common($ui, $config);
+    }
+
+    function doBuild($command, $options, $params)
+    {
+        require_once 'PEAR/Builder.php';
+        if (sizeof($params) < 1) {
+            $params[0] = 'package.xml';
+        }
+
+        $builder = &new PEAR_Builder($this->ui);
+        $this->debug = $this->config->get('verbose');
+        $err = $builder->build($params[0], array(&$this, 'buildCallback'));
+        if (PEAR::isError($err)) {
+            return $err;
+        }
+
+        return true;
+    }
+
+    function buildCallback($what, $data)
+    {
+        if (($what == 'cmdoutput' && $this->debug > 1) ||
+            ($what == 'output' && $this->debug > 0)) {
+            $this->ui->outputData(rtrim($data), 'build');
+        }
+    }
+}                                                                                                                                                                                                                     PEAR-1.9.0/PEAR/Command/Channels.xml                                                                100664     764     764        10172      100664  11711                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
  <list-channels>
   <summary>List Available Channels</summary>
   <function>doList</function>
@@ -8590,12 +8784,13 @@ operations on the remote server.</doc>
   <function>doLogout</function>
   <shortcut>clo</shortcut>
   <options />
-  <doc>
-Logs out from the remote server.  This command does not actually
-connect to the remote server, it only deletes the stored username and
-password from your user configuration.</doc>
+  <doc>&lt;channel name&gt;
+Logs out from a remote channel server.  If &lt;channel name&gt; is not supplied,
+the default channel is used. This command does not actually connect to the
+remote server, it only deletes the stored username and password from your user
+configuration.</doc>
  </channel-logout>
-</commands>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      PEAR-1.8.0/PEAR/Command/Channels.php                                                                100664     764     764       100632      100664  11720                                                                                                                                                                                                                                                                                                                                                                      <?php
+</commands>                                                                                                                                                                                                                                                                                                                                                                                                      PEAR-1.9.0/PEAR/Command/Channels.php                                                                100664     764     764       101377      100664  11730                                                                                                                                                                                                                                                                                                                                                                      <?php
 // /* vim: set expandtab tabstop=4 shiftwidth=4: */
 /**
  * PEAR_Command_Channels (list-channels, update-channels, channel-delete, channel-add,
@@ -8609,7 +8804,7 @@ password from your user configuration.</doc>
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Channels.php,v 1.64 2009/02/24 23:39:29 dufuz Exp $
+ * @version    CVS: $Id: Channels.php 287561 2009-08-21 22:42:58Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -8629,7 +8824,7 @@ define('PEAR_COMMAND_CHANNELS_CHANNEL_EXISTS', -500);
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -8751,10 +8946,11 @@ operations on the remote server.',
             'shortcut' => 'clo',
             'function' => 'doLogout',
             'options' => array(),
-            'doc' => '
-Logs out from the remote server.  This command does not actually
-connect to the remote server, it only deletes the stored username and
-password from your user configuration.',
+            'doc' => '<channel name>
+Logs out from a remote channel server.  If <channel name> is not supplied,
+the default channel is used. This command does not actually connect to the
+remote server, it only deletes the stored username and password from your user
+configuration.',
             ),
         );
 
@@ -8782,11 +8978,12 @@ password from your user configuration.',
         $data = array(
             'caption' => 'Registered Channels:',
             'border' => true,
-            'headline' => array('Channel', 'Summary')
+            'headline' => array('Channel', 'Alias', 'Summary')
             );
         foreach ($registered as $channel) {
             $data['data'][] = array($channel->getName(),
-                                      $channel->getSummary());
+                                    $channel->getAlias(),
+                                    $channel->getSummary());
         }
 
         if (count($registered) === 0) {
@@ -9269,7 +9466,7 @@ password from your user configuration.',
             return $this->raiseError('No channel alias specified');
         }
 
-        if (count($params) !== 2) {
+        if (count($params) !== 2 || (!empty($params[1]) && $params[1]{0} == '-')) {
             return $this->raiseError(
                 'Invalid format, correct is: channel-alias channel alias');
         }
@@ -9459,20 +9656,23 @@ password from your user configuration.',
     function doLogout($command, $options, $params)
     {
         $reg     = &$this->config->getRegistry();
-        $channel = $this->config->get('default_channel');
+
+        // If a parameter is supplied, use that as the channel to log in to
+        $channel = isset($params[0]) ? $params[0] : $this->config->get('default_channel');
+
         $chan    = $reg->getChannel($channel);
         if (PEAR::isError($chan)) {
             return $this->raiseError($chan);
         }
 
-        $server = $this->config->get('preferred_mirror');
+        $server = $this->config->get('preferred_mirror', null, $channel);
         $this->ui->outputData("Logging out from $server.", $command);
-        $this->config->remove('username');
-        $this->config->remove('password');
+        $this->config->remove('username', 'user', $channel);
+        $this->config->remove('password', 'user', $channel);
         $this->config->store();
         return true;
     }
-}                                                                                                      PEAR-1.8.0/PEAR/Command/Common.php                                                                  100664     764     764        20147      100664  11377                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                                                                                                 PEAR-1.9.0/PEAR/Command/Common.php                                                                  100664     764     764        20144      100664  11375                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Command_Common base class
  *
@@ -9484,7 +9684,7 @@ password from your user configuration.',
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Common.php,v 1.39 2009/02/24 23:39:29 dufuz Exp $
+ * @version    CVS: $Id: Common.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -9503,7 +9703,7 @@ require_once 'PEAR.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -9744,7 +9944,7 @@ class PEAR_Command_Common extends PEAR
 
         return $this->$func($command, $options, $params);
     }
-}                                                                                                                                                                                                                                                                                                                                                                                                                         PEAR-1.8.0/PEAR/Command/Config.xml                                                                  100777     764     764         6466      100777  11367                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
+}                                                                                                                                                                                                                                                                                                                                                                                                                            PEAR-1.9.0/PEAR/Command/Config.xml                                                                  100664     764     764         6466      100664  11356                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
  <config-show>
   <summary>Show All Settings</summary>
   <function>doConfigShow</function>
@@ -9835,7 +10035,7 @@ PEAR installation (using the --remoteconfig option of install, upgrade,
 and uninstall).
 </doc>
  </config-create>
-</commands>                                                                                                                                                                                                          PEAR-1.8.0/PEAR/Command/Config.php                                                                  100664     764     764        35663      100664  11365                                                                                                                                                                                                                                                                                                                                                                      <?php
+</commands>                                                                                                                                                                                                          PEAR-1.9.0/PEAR/Command/Config.php                                                                  100664     764     764        36076      100664  11365                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Command_Config (config-show, config-get, config-set, config-help, config-create commands)
  *
@@ -9847,7 +10047,7 @@ and uninstall).
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Config.php,v 1.61 2009/03/26 21:36:32 dufuz Exp $
+ * @version    CVS: $Id: Config.php 287554 2009-08-21 21:16:25Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -9866,7 +10066,7 @@ require_once 'PEAR/Command/Common.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -10079,7 +10279,12 @@ and uninstall).
             return $this->raiseError('Channel "' . $params[1] . '" does not exist');
         }
 
-        if ($params[0] == 'preferred_mirror' && !$reg->channelExists($params[1])) {
+        if ($params[0] == 'preferred_mirror'
+            && (
+                !$reg->mirrorExists($channel, $params[1]) &&
+                (!$reg->channelExists($params[1]) || $channel != $params[1])
+            )
+        ) {
             $msg  = 'Channel Mirror "' . $params[1] . '" does not exist';
             $msg .= ' in your registry for channel "' . $channel . '".';
             $msg .= "\n" . 'Attempt to run "pear channel-update ' . $channel .'"';
@@ -10242,7 +10447,7 @@ and uninstall).
 
         return false;
     }
-}                                                                             PEAR-1.8.0/PEAR/Command/Install.xml                                                                 100775     764     764        20576      100775  11602                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
+}                                                                                                                                                                                                                                                                                                                                                                                                                                                                  PEAR-1.9.0/PEAR/Command/Install.xml                                                                 100664     764     764        20576      100664  11575                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
  <install>
   <summary>Install Package</summary>
   <function>doInstall</function>
@@ -10474,7 +10679,7 @@ more stable.
     <arg>DIR</arg>
    </installroot>
    <ignore-errors>
-    <shortopt>f</shortopt>
+    <shortopt></shortopt>
     <doc>force install even if there were errors</doc>
    </ignore-errors>
    <offline>
@@ -10499,7 +10704,7 @@ channel not in your default channel ({config default_channel})
     <arg>DIR</arg>
    </destination>
    <force>
-    <shortopt></shortopt>
+    <shortopt>f</shortopt>
     <doc>Force the unpacking even if there were errors in the package</doc>
    </force>
   </options>
@@ -10517,7 +10722,7 @@ package if needed.
 Run post-installation scripts in package &lt;package&gt;, if any exist.
 </doc>
  </run-scripts>
-</commands>                                                                                                                                  PEAR-1.8.0/PEAR/Command/Install.php                                                                 100664     764     764       142453      100664  11602                                                                                                                                                                                                                                                                                                                                                                      <?php
+</commands>                                                                                                                                  PEAR-1.9.0/PEAR/Command/Install.php                                                                 100664     764     764       143164      100664  11603                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Command_Install (install, upgrade, upgrade-all, uninstall, bundle, run-scripts commands)
  *
@@ -10529,7 +10734,7 @@ Run post-installation scripts in package &lt;package&gt;, if any exist.
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Install.php,v 1.153 2009/03/08 04:01:11 dufuz Exp $
+ * @version    CVS: $Id: Install.php 287477 2009-08-19 14:19:43Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -10549,7 +10754,7 @@ require_once 'PEAR/Command/Common.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -11082,8 +11287,7 @@ Run post-installation scripts in package <package>, if any exist.
             }
         }
 
-        $abstractpackages = array();
-        $otherpackages    = array();
+        $abstractpackages = $otherpackages = array();
         // parse params
         PEAR::staticPushErrorHandling(PEAR_ERROR_RETURN);
 
@@ -11177,7 +11381,7 @@ Run post-installation scripts in package <package>, if any exist.
         }
 
         $this->downloader = &$this->getDownloader($this->ui, $options, $this->config);
-        $errors = $downloaded = $binaries   = array();
+        $errors = $downloaded = $binaries = array();
         $downloaded = &$this->downloader->download($packages);
         if (PEAR::isError($downloaded)) {
             return $this->raiseError($downloaded);
@@ -11222,8 +11426,7 @@ Run post-installation scripts in package <package>, if any exist.
             return true;
         }
 
-        $extrainfo = array();
-        $binaries  = array();
+        $binaries = $extrainfo = array();
         foreach ($downloaded as $param) {
             PEAR::staticPushErrorHandling(PEAR_ERROR_RETURN);
             $info = $this->installer->install($param, $options);
@@ -11722,10 +11925,14 @@ Run post-installation scripts in package <package>, if any exist.
                     return $this->raiseError($chan);
                 }
 
+                $base2 = false;
                 $preferred_mirror = $this->config->get('preferred_mirror', null, $channel);
                 if ($chan->supportsREST($preferred_mirror) &&
-                      $base = $chan->getBaseURL('REST1.0', $preferred_mirror))
-                {
+                    (
+                       //($base2 = $chan->getBaseURL('REST1.4', $preferred_mirror)) ||
+                       ($base  = $chan->getBaseURL('REST1.0', $preferred_mirror))
+                    )
+                ) {
                     $dorest = true;
                 }
 
@@ -11737,10 +11944,15 @@ Run post-installation scripts in package <package>, if any exist.
                 }
 
                 if ($dorest) {
-                    $rest = &$this->config->getREST('1.0', array());
-                    $installed = array_flip($reg->listPackages($channel));
+                    if ($base2) {
+                        $rest = &$this->config->getREST('1.4', array());
+                        $base = $base2;
+                    } else {
+                        $rest = &$this->config->getREST('1.0', array());
+                    }
 
-                    $latest = $rest->listLatestUpgrades($base, $state, $installed, $channel, $reg);
+                    $installed = array_flip($reg->listPackages($channel));
+                    $latest    = $rest->listLatestUpgrades($base, $state, $installed, $channel, $reg);
                 }
 
                 PEAR::staticPopErrorHandling();
@@ -11775,7 +11987,7 @@ Run post-installation scripts in package <package>, if any exist.
 
         return $ret;
     }
-}                                                                                                                                                                                                                     PEAR-1.8.0/PEAR/Command/Mirror.xml                                                                  100777     764     764         1151      100777  11416                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
+}                                                                                                                                                                                                                                                                                                                                                                                                            PEAR-1.9.0/PEAR/Command/Mirror.xml                                                                  100664     764     764         1151      100664  11405                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
  <download-all>
   <summary>Downloads each available package from the default channel</summary>
   <function>doDownloadAll</function>
@@ -11792,7 +12004,7 @@ Requests a list of available packages from the default channel ({config default_
 and downloads them to current working directory.  Note: only
 packages within preferred_state ({config preferred_state}) will be downloaded</doc>
  </download-all>
-</commands>                                                                                                                                                                                                                                                                                                                                                                                                                       PEAR-1.8.0/PEAR/Command/Mirror.php                                                                  100664     764     764        10765      100664  11426                                                                                                                                                                                                                                                                                                                                                                      <?php
+</commands>                                                                                                                                                                                                                                                                                                                                                                                                                       PEAR-1.9.0/PEAR/Command/Mirror.php                                                                  100664     764     764        10762      100664  11424                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Command_Mirror (download-all command)
  *
@@ -11803,7 +12015,7 @@ packages within preferred_state ({config preferred_state}) will be downloaded</d
  * @author     Alexander Merz <alexmerz at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Mirror.php,v 1.23 2009/02/24 23:39:29 dufuz Exp $
+ * @version    CVS: $Id: Mirror.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.2.0
  */
@@ -11821,7 +12033,7 @@ require_once 'PEAR/Command/Common.php';
  * @author     Alexander Merz <alexmerz at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.2.0
  */
@@ -11930,7 +12142,7 @@ packages within preferred_state ({config preferred_state}) will be downloaded'
 
         return true;
     }
-}           PEAR-1.8.0/PEAR/Command/Package.xml                                                                 100777     764     764        13665      100777  11534                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
+}              PEAR-1.9.0/PEAR/Command/Package.xml                                                                 100664     764     764        16066      100664  11521                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
  <package>
   <summary>Build Package</summary>
   <function>doPackage</function>
@@ -11945,13 +12157,13 @@ packages within preferred_state ({config preferred_state}) will be downloaded'
     <doc>Print the name of the packaged file.</doc>
    </showname>
   </options>
-  <doc>[descfile] [descfile2]
-Creates a PEAR package from its description file (usually called
-package.xml).  If a second packagefile is passed in, then
-the packager will check to make sure that one is a package.xml
-version 1.0, and the other is a package.xml version 2.0.  The
-package.xml version 1.0 will be saved as &quot;package.xml&quot; in the archive,
-and the other as &quot;package2.xml&quot; in the archive&quot;
+  <doc>[descfile] [descfile2]
+Creates a PEAR package from its description file (usually called
+package.xml).  If a second packagefile is passed in, then
+the packager will check to make sure that one is a package.xml
+version 1.0, and the other is a package.xml version 2.0.  The
+package.xml version 1.0 will be saved as &quot;package.xml&quot; in the archive,
+and the other as &quot;package2.xml&quot; in the archive&quot;
 </doc>
  </package>
  <package-validate>
@@ -11959,7 +12171,7 @@ and the other as &quot;package2.xml&quot; in the archive&quot;
   <function>doPackageValidate</function>
   <shortcut>pv</shortcut>
   <options />
-  <doc>
+  <doc>
 </doc>
  </package-validate>
  <cvsdiff>
@@ -12019,13 +12231,46 @@ and the other as &quot;package2.xml&quot; in the archive&quot;
     <doc>Don&#039;t do anything, just pretend</doc>
    </dry-run>
   </options>
-  <doc>&lt;package.xml&gt;
-Compares all the files in a package.  Without any options, this
-command will compare the current code with the last checked-in code.
-Using the -r or -R option you may compare the current code with that
-of a specific release.
+  <doc>&lt;package.xml&gt;
+Compares all the files in a package.  Without any options, this
+command will compare the current code with the last checked-in code.
+Using the -r or -R option you may compare the current code with that
+of a specific release.
 </doc>
  </cvsdiff>
+ <svntag>
+  <summary>Set SVN Release Tag</summary>
+  <function>doSvnTag</function>
+  <shortcut>sv</shortcut>
+  <options>
+   <quiet>
+    <shortopt>q</shortopt>
+    <doc>Be quiet</doc>
+   </quiet>
+   <slide>
+    <shortopt>F</shortopt>
+    <doc>Move (slide) tag if it exists</doc>
+   </slide>
+   <delete>
+    <shortopt>d</shortopt>
+    <doc>Remove tag</doc>
+   </delete>
+   <dry-run>
+    <shortopt>n</shortopt>
+    <doc>Don&#039;t do anything, just pretend</doc>
+   </dry-run>
+  </options>
+  <doc>&lt;package.xml&gt; [files...]
+ Sets a SVN tag on all files in a package.  Use this command after you have
+ packaged a distribution tarball with the &quot;package&quot; command to tag what
+ revisions of what files were in that release.  If need to fix something
+ after running cvstag once, but before the tarball is released to the public,
+ use the &quot;slide&quot; option to move the release tag.
+
+ to include files (such as a second package.xml, or tests not included in the
+ release), pass them as additional parameters.
+ </doc>
+ </svntag>
  <cvstag>
   <summary>Set CVS Release Tag</summary>
   <function>doCvsTag</function>
@@ -12052,15 +12297,15 @@ of a specific release.
     <doc>Don&#039;t do anything, just pretend</doc>
    </dry-run>
   </options>
-  <doc>&lt;package.xml&gt; [files...]
-Sets a CVS tag on all files in a package.  Use this command after you have
-packaged a distribution tarball with the &quot;package&quot; command to tag what
-revisions of what files were in that release.  If need to fix something
-after running cvstag once, but before the tarball is released to the public,
-use the &quot;slide&quot; option to move the release tag.
-
-to include files (such as a second package.xml, or tests not included in the
-release), pass them as additional parameters.
+  <doc>&lt;package.xml&gt; [files...]
+Sets a CVS tag on all files in a package.  Use this command after you have
+packaged a distribution tarball with the &quot;package&quot; command to tag what
+revisions of what files were in that release.  If need to fix something
+after running cvstag once, but before the tarball is released to the public,
+use the &quot;slide&quot; option to move the release tag.
+
+to include files (such as a second package.xml, or tests not included in the
+release), pass them as additional parameters.
 </doc>
  </cvstag>
  <package-dependencies>
@@ -12068,8 +12313,9 @@ release), pass them as additional parameters.
   <function>doPackageDependencies</function>
   <shortcut>pd</shortcut>
   <options />
-  <doc>
-List all dependencies the package has.</doc>
+  <doc>&lt;package-file&gt; or &lt;package.xml&gt; or &lt;install-package-name&gt;
+List all dependencies the package has.
+Can take a tgz / tar file, package.xml or a package name of an installed package.</doc>
  </package-dependencies>
  <sign>
   <summary>Sign a package distribution file</summary>
@@ -12081,7 +12327,7 @@ List all dependencies the package has.</doc>
     <doc>Display GnuPG output</doc>
    </verbose>
   </options>
-  <doc>&lt;package-file&gt;
+  <doc>&lt;package-file&gt;
 Signs a package distribution (.tar or .tgz) file with GnuPG.</doc>
  </sign>
  <makerpm>
@@ -12096,22 +12342,22 @@ Signs a package distribution (.tar or .tgz) file with GnuPG.</doc>
    </spec-template>
    <rpm-pkgname>
     <shortopt>p</shortopt>
-    <doc>Use FORMAT as format string for RPM package name, %s is replaced
+    <doc>Use FORMAT as format string for RPM package name, %s is replaced
 by the PEAR package name, defaults to &quot;PEAR::%s&quot;.</doc>
     <arg>FORMAT</arg>
    </rpm-pkgname>
   </options>
-  <doc>&lt;package-file&gt;
-
-Creates an RPM .spec file for wrapping a PEAR package inside an RPM
-package.  Intended to be used from the SPECS directory, with the PEAR
-package tarball in the SOURCES directory:
-
-$ pear makerpm ../SOURCES/Net_Socket-1.0.tgz
-Wrote RPM spec file PEAR::Net_Geo-1.0.spec
-$ rpm -bb PEAR::Net_Socket-1.0.spec
-...
-Wrote: /usr/src/redhat/RPMS/i386/PEAR::Net_Socket-1.0-1.i386.rpm
+  <doc>&lt;package-file&gt;
+
+Creates an RPM .spec file for wrapping a PEAR package inside an RPM
+package.  Intended to be used from the SPECS directory, with the PEAR
+package tarball in the SOURCES directory:
+
+$ pear makerpm ../SOURCES/Net_Socket-1.0.tgz
+Wrote RPM spec file PEAR::Net_Geo-1.0.spec
+$ rpm -bb PEAR::Net_Socket-1.0.spec
+...
+Wrote: /usr/src/redhat/RPMS/i386/PEAR::Net_Socket-1.0-1.i386.rpm
 </doc>
  </makerpm>
  <convert>
@@ -12124,881 +12370,1122 @@ Wrote: /usr/src/redhat/RPMS/i386/PEAR::Net_Socket-1.0-1.i386.rpm
     <doc>do not beautify the filelist.</doc>
    </flat>
   </options>
-  <doc>[descfile] [descfile2]
-Converts a package.xml in 1.0 format into a package.xml
-in 2.0 format.  The new file will be named package2.xml by default,
-and package.xml will be used as the old file by default.
-This is not the most intelligent conversion, and should only be
-used for automated conversion or learning the format.
+  <doc>[descfile] [descfile2]
+Converts a package.xml in 1.0 format into a package.xml
+in 2.0 format.  The new file will be named package2.xml by default,
+and package.xml will be used as the old file by default.
+This is not the most intelligent conversion, and should only be
+used for automated conversion or learning the format.
 </doc>
  </convert>
-</commands>                                                                           PEAR-1.8.0/PEAR/Command/Package.php                                                                 100664     764     764        76030      100664  11504                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_Command_Package (package, package-validate, cvsdiff, cvstag, package-dependencies,
- * sign, makerpm, convert commands)
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Stig Bakken <ssb at php.net>
- * @author     Martin Jansen <mj at php.net>
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Package.php,v 1.133 2009/03/25 02:15:57 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 0.1
- */
-
-/**
- * base class
- */
-require_once 'PEAR/Command/Common.php';
-
-/**
- * PEAR commands for login/logout
- *
- * @category   pear
- * @package    PEAR
- * @author     Stig Bakken <ssb at php.net>
- * @author     Martin Jansen <mj at php.net>
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: @package_version@
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 0.1
- */
-
-class PEAR_Command_Package extends PEAR_Command_Common
-{
-    var $commands = array(
-        'package' => array(
-            'summary' => 'Build Package',
-            'function' => 'doPackage',
-            'shortcut' => 'p',
-            'options' => array(
-                'nocompress' => array(
-                    'shortopt' => 'Z',
-                    'doc' => 'Do not gzip the package file'
-                    ),
-                'showname' => array(
-                    'shortopt' => 'n',
-                    'doc' => 'Print the name of the packaged file.',
-                    ),
-                ),
-            'doc' => '[descfile] [descfile2]
-Creates a PEAR package from its description file (usually called
-package.xml).  If a second packagefile is passed in, then
-the packager will check to make sure that one is a package.xml
-version 1.0, and the other is a package.xml version 2.0.  The
-package.xml version 1.0 will be saved as "package.xml" in the archive,
-and the other as "package2.xml" in the archive"
-'
-            ),
-        'package-validate' => array(
-            'summary' => 'Validate Package Consistency',
-            'function' => 'doPackageValidate',
-            'shortcut' => 'pv',
-            'options' => array(),
-            'doc' => '
-',
-            ),
-        'cvsdiff' => array(
-            'summary' => 'Run a "cvs diff" for all files in a package',
-            'function' => 'doCvsDiff',
-            'shortcut' => 'cd',
-            'options' => array(
-                'quiet' => array(
-                    'shortopt' => 'q',
-                    'doc' => 'Be quiet',
-                    ),
-                'reallyquiet' => array(
-                    'shortopt' => 'Q',
-                    'doc' => 'Be really quiet',
-                    ),
-                'date' => array(
-                    'shortopt' => 'D',
-                    'doc' => 'Diff against revision of DATE',
-                    'arg' => 'DATE',
-                    ),
-                'release' => array(
-                    'shortopt' => 'R',
-                    'doc' => 'Diff against tag for package release REL',
-                    'arg' => 'REL',
-                    ),
-                'revision' => array(
-                    'shortopt' => 'r',
-                    'doc' => 'Diff against revision REV',
-                    'arg' => 'REV',
-                    ),
-                'context' => array(
-                    'shortopt' => 'c',
-                    'doc' => 'Generate context diff',
-                    ),
-                'unified' => array(
-                    'shortopt' => 'u',
-                    'doc' => 'Generate unified diff',
-                    ),
-                'ignore-case' => array(
-                    'shortopt' => 'i',
-                    'doc' => 'Ignore case, consider upper- and lower-case letters equivalent',
-                    ),
-                'ignore-whitespace' => array(
-                    'shortopt' => 'b',
-                    'doc' => 'Ignore changes in amount of white space',
-                    ),
-                'ignore-blank-lines' => array(
-                    'shortopt' => 'B',
-                    'doc' => 'Ignore changes that insert or delete blank lines',
-                    ),
-                'brief' => array(
-                    'doc' => 'Report only whether the files differ, no details',
-                    ),
-                'dry-run' => array(
-                    'shortopt' => 'n',
-                    'doc' => 'Don\'t do anything, just pretend',
-                    ),
-                ),
-            'doc' => '<package.xml>
-Compares all the files in a package.  Without any options, this
-command will compare the current code with the last checked-in code.
-Using the -r or -R option you may compare the current code with that
-of a specific release.
-',
-            ),
-        'cvstag' => array(
-            'summary' => 'Set CVS Release Tag',
-            'function' => 'doCvsTag',
-            'shortcut' => 'ct',
-            'options' => array(
-                'quiet' => array(
-                    'shortopt' => 'q',
-                    'doc' => 'Be quiet',
-                    ),
-                'reallyquiet' => array(
-                    'shortopt' => 'Q',
-                    'doc' => 'Be really quiet',
-                    ),
-                'slide' => array(
-                    'shortopt' => 'F',
-                    'doc' => 'Move (slide) tag if it exists',
-                    ),
-                'delete' => array(
-                    'shortopt' => 'd',
-                    'doc' => 'Remove tag',
-                    ),
-                'dry-run' => array(
-                    'shortopt' => 'n',
-                    'doc' => 'Don\'t do anything, just pretend',
-                    ),
-                ),
-            'doc' => '<package.xml> [files...]
-Sets a CVS tag on all files in a package.  Use this command after you have
-packaged a distribution tarball with the "package" command to tag what
-revisions of what files were in that release.  If need to fix something
-after running cvstag once, but before the tarball is released to the public,
-use the "slide" option to move the release tag.
-
-to include files (such as a second package.xml, or tests not included in the
-release), pass them as additional parameters.
-',
-            ),
-        'package-dependencies' => array(
-            'summary' => 'Show package dependencies',
-            'function' => 'doPackageDependencies',
-            'shortcut' => 'pd',
-            'options' => array(),
-            'doc' => '
-List all dependencies the package has.'
-            ),
-        'sign' => array(
-            'summary' => 'Sign a package distribution file',
-            'function' => 'doSign',
-            'shortcut' => 'si',
-            'options' => array(
-                'verbose' => array(
-                    'shortopt' => 'v',
-                    'doc' => 'Display GnuPG output',
-                    ),
-            ),
-            'doc' => '<package-file>
-Signs a package distribution (.tar or .tgz) file with GnuPG.',
-            ),
-        'makerpm' => array(
-            'summary' => 'Builds an RPM spec file from a PEAR package',
-            'function' => 'doMakeRPM',
-            'shortcut' => 'rpm',
-            'options' => array(
-                'spec-template' => array(
-                    'shortopt' => 't',
-                    'arg' => 'FILE',
-                    'doc' => 'Use FILE as RPM spec file template'
-                    ),
-                'rpm-pkgname' => array(
-                    'shortopt' => 'p',
-                    'arg' => 'FORMAT',
-                    'doc' => 'Use FORMAT as format string for RPM package name, %s is replaced
-by the PEAR package name, defaults to "PEAR::%s".',
-                    ),
-                ),
-            'doc' => '<package-file>
-
-Creates an RPM .spec file for wrapping a PEAR package inside an RPM
-package.  Intended to be used from the SPECS directory, with the PEAR
-package tarball in the SOURCES directory:
-
-$ pear makerpm ../SOURCES/Net_Socket-1.0.tgz
-Wrote RPM spec file PEAR::Net_Geo-1.0.spec
-$ rpm -bb PEAR::Net_Socket-1.0.spec
-...
-Wrote: /usr/src/redhat/RPMS/i386/PEAR::Net_Socket-1.0-1.i386.rpm
-',
-            ),
-        'convert' => array(
-            'summary' => 'Convert a package.xml 1.0 to package.xml 2.0 format',
-            'function' => 'doConvert',
-            'shortcut' => 'c2',
-            'options' => array(
-                'flat' => array(
-                    'shortopt' => 'f',
-                    'doc' => 'do not beautify the filelist.',
-                    ),
-                ),
-            'doc' => '[descfile] [descfile2]
-Converts a package.xml in 1.0 format into a package.xml
-in 2.0 format.  The new file will be named package2.xml by default,
-and package.xml will be used as the old file by default.
-This is not the most intelligent conversion, and should only be
-used for automated conversion or learning the format.
-'
-            ),
-        );
-
-    var $output;
-
-    /**
-     * PEAR_Command_Package constructor.
-     *
-     * @access public
-     */
-    function PEAR_Command_Package(&$ui, &$config)
-    {
-        parent::PEAR_Command_Common($ui, $config);
-    }
-
-    function _displayValidationResults($err, $warn, $strict = false)
-    {
-        foreach ($err as $e) {
-            $this->output .= "Error: $e\n";
-        }
-        foreach ($warn as $w) {
-            $this->output .= "Warning: $w\n";
-        }
-        $this->output .= sprintf('Validation: %d error(s), %d warning(s)'."\n",
-                                       sizeof($err), sizeof($warn));
-        if ($strict && count($err) > 0) {
-            $this->output .= "Fix these errors and try again.";
-            return false;
-        }
-        return true;
-    }
-
-    function &getPackager()
-    {
-        if (!class_exists('PEAR_Packager')) {
-            require_once 'PEAR/Packager.php';
-        }
-        $a = &new PEAR_Packager;
-        return $a;
-    }
-
-    function &getPackageFile($config, $debug = false, $tmpdir = null)
-    {
-        if (!class_exists('PEAR_Common')) {
-            require_once 'PEAR/Common.php';
-        }
-        if (!class_exists('PEAR_PackageFile')) {
-            require_once 'PEAR/PackageFile.php';
-        }
-        $a = &new PEAR_PackageFile($config, $debug, $tmpdir);
-        $common = new PEAR_Common;
-        $common->ui = $this->ui;
-        $a->setLogger($common);
-        return $a;
-    }
-
-    function doPackage($command, $options, $params)
-    {
-        $this->output = '';
-        $pkginfofile = isset($params[0]) ? $params[0] : 'package.xml';
-        $pkg2 = isset($params[1]) ? $params[1] : null;
-        if (!$pkg2 && !isset($params[0]) && file_exists('package2.xml')) {
-            $pkg2 = 'package2.xml';
-        }
-
-        $packager = &$this->getPackager();
-        $compress = empty($options['nocompress']) ? true : false;
-        $result   = $packager->package($pkginfofile, $compress, $pkg2);
-        if (PEAR::isError($result)) {
-            return $this->raiseError($result);
-        }
-
-        // Don't want output, only the package file name just created
-        if (isset($options['showname'])) {
-            $this->output = $result;
-        }
-
-        if ($this->output) {
-            $this->ui->outputData($this->output, $command);
-        }
-
-        return true;
-    }
-
-    function doPackageValidate($command, $options, $params)
-    {
-        $this->output = '';
-        if (count($params) < 1) {
-            $params[0] = 'package.xml';
-        }
-
-        $obj = &$this->getPackageFile($this->config, $this->_debug);
-        $obj->rawReturn();
-        PEAR::staticPushErrorHandling(PEAR_ERROR_RETURN);
-        $info = $obj->fromTgzFile($params[0], PEAR_VALIDATE_NORMAL);
-        if (PEAR::isError($info)) {
-            $info = $obj->fromPackageFile($params[0], PEAR_VALIDATE_NORMAL);
-        } else {
-            $archive = $info->getArchiveFile();
-            $tar = &new Archive_Tar($archive);
-            $tar->extract(dirname($info->getPackageFile()));
-            $info->setPackageFile(dirname($info->getPackageFile()) . DIRECTORY_SEPARATOR .
-                $info->getPackage() . '-' . $info->getVersion() . DIRECTORY_SEPARATOR .
-                basename($info->getPackageFile()));
-        }
-
-        PEAR::staticPopErrorHandling();
-        if (PEAR::isError($info)) {
-            return $this->raiseError($info);
-        }
-
-        $valid = false;
-        if ($info->getPackagexmlVersion() == '2.0') {
-            if ($valid = $info->validate(PEAR_VALIDATE_NORMAL)) {
-                $info->flattenFileList();
-                $valid = $info->validate(PEAR_VALIDATE_PACKAGING);
-            }
-        } else {
-            $valid = $info->validate(PEAR_VALIDATE_PACKAGING);
-        }
-
-        $err = $warn = array();
-        if ($errors = $info->getValidationWarnings()) {
-            foreach ($errors as $error) {
-                if ($error['level'] == 'warning') {
-                    $warn[] = $error['message'];
-                } else {
-                    $err[] = $error['message'];
-                }
-            }
-        }
-
-        $this->_displayValidationResults($err, $warn);
-        $this->ui->outputData($this->output, $command);
-        return true;
-    }
-
-    function doCvsTag($command, $options, $params)
-    {
-        $this->output = '';
-        $_cmd = $command;
-        if (count($params) < 1) {
-            $help = $this->getHelp($command);
-            return $this->raiseError("$command: missing parameter: $help[0]");
-        }
-
-        $packageFile = realpath($params[0]);
-        $obj  = &$this->getPackageFile($this->config, $this->_debug);
-        $info = $obj->fromAnyFile($packageFile, PEAR_VALIDATE_NORMAL);
-        if (PEAR::isError($info)) {
-            return $this->raiseError($info);
-        }
-
-        $err = $warn = array();
-        if (!$info->validate()) {
-            foreach ($info->getValidationWarnings() as $error) {
-                if ($error['level'] == 'warning') {
-                    $warn[] = $error['message'];
-                } else {
-                    $err[] = $error['message'];
-                }
-            }
-        }
-
-        if (!$this->_displayValidationResults($err, $warn, true)) {
-            $this->ui->outputData($this->output, $command);
-            return $this->raiseError('CVS tag failed');
-        }
-
-        $version    = $info->getVersion();
-        $cvsversion = preg_replace('/[^a-z0-9]/i', '_', $version);
-        $cvstag     = "RELEASE_$cvsversion";
-        $files      = array_keys($info->getFilelist());
-        $command = 'cvs';
-        if (isset($options['quiet'])) {
-            $command .= ' -q';
-        }
-
-        if (isset($options['reallyquiet'])) {
-            $command .= ' -Q';
-        }
-
-        $command .= ' tag';
-        if (isset($options['slide'])) {
-            $command .= ' -F';
-        }
-
-        if (isset($options['delete'])) {
-            $command .= ' -d';
-        }
-
-        $command .= ' ' . $cvstag . ' ' . escapeshellarg($params[0]);
-        array_shift($params);
-        if (count($params)) {
-            // add in additional files to be tagged
-            $files = array_merge($files, $params);
-        }
-
-        $dir = dirname($packageFile);
-        $dir = substr($dir, strrpos($dir, '/') + 1);
-        foreach ($files as $file) {
-            if (!file_exists($file)) {
-                $file = $dir . DIRECTORY_SEPARATOR . $file;
-            }
-            $command .= ' ' . escapeshellarg($file);
-        }
-
-        if ($this->config->get('verbose') > 1) {
-            $this->output .= "+ $command\n";
-        }
-
-        $this->output .= "+ $command\n";
-        if (empty($options['dry-run'])) {
-            $fp = popen($command, "r");
-            while ($line = fgets($fp, 1024)) {
-                $this->output .= rtrim($line)."\n";
-            }
-            pclose($fp);
-        }
-
-        $this->ui->outputData($this->output, $_cmd);
-        return true;
-    }
-
-    function doCvsDiff($command, $options, $params)
-    {
-        $this->output = '';
-        if (sizeof($params) < 1) {
-            $help = $this->getHelp($command);
-            return $this->raiseError("$command: missing parameter: $help[0]");
-        }
-
-        $file = realpath($params[0]);
-        $obj  = &$this->getPackageFile($this->config, $this->_debug);
-        $info = $obj->fromAnyFile($file, PEAR_VALIDATE_NORMAL);
-        if (PEAR::isError($info)) {
-            return $this->raiseError($info);
-        }
-
-        $err = $warn = array();
-        if (!$info->validate()) {
-            foreach ($info->getValidationWarnings() as $error) {
-                if ($error['level'] == 'warning') {
-                    $warn[] = $error['message'];
-                } else {
-                    $err[] = $error['message'];
-                }
-            }
-        }
-
-        if (!$this->_displayValidationResults($err, $warn, true)) {
-            $this->ui->outputData($this->output, $command);
-            return $this->raiseError('CVS diff failed');
-        }
-
-        $info1 = $info->getFilelist();
-        $files = $info1;
-        $cmd = "cvs";
-        if (isset($options['quiet'])) {
-            $cmd .= ' -q';
-            unset($options['quiet']);
-        }
-
-        if (isset($options['reallyquiet'])) {
-            $cmd .= ' -Q';
-            unset($options['reallyquiet']);
-        }
-
-        if (isset($options['release'])) {
-            $cvsversion = preg_replace('/[^a-z0-9]/i', '_', $options['release']);
-            $cvstag = "RELEASE_$cvsversion";
-            $options['revision'] = $cvstag;
-            unset($options['release']);
-        }
-
-        $execute = true;
-        if (isset($options['dry-run'])) {
-            $execute = false;
-            unset($options['dry-run']);
-        }
-
-        $cmd .= ' diff';
-        // the rest of the options are passed right on to "cvs diff"
-        foreach ($options as $option => $optarg) {
-            $arg = $short = false;
-            if (isset($this->commands[$command]['options'][$option])) {
-                $arg = $this->commands[$command]['options'][$option]['arg'];
-                $short = $this->commands[$command]['options'][$option]['shortopt'];
-            }
-            $cmd .= $short ? " -$short" : " --$option";
-            if ($arg && $optarg) {
-                $cmd .= ($short ? '' : '=') . escapeshellarg($optarg);
-            }
-        }
-
-        foreach ($files as $file) {
-            $cmd .= ' ' . escapeshellarg($file['name']);
-        }
-
-        if ($this->config->get('verbose') > 1) {
-            $this->output .= "+ $cmd\n";
-        }
-
-        if ($execute) {
-            $fp = popen($cmd, "r");
-            while ($line = fgets($fp, 1024)) {
-                $this->output .= rtrim($line)."\n";
-            }
-            pclose($fp);
-        }
-
-        $this->ui->outputData($this->output, $command);
-        return true;
-    }
-
-    function doPackageDependencies($command, $options, $params)
-    {
-        // $params[0] -> the PEAR package to list its information
-        if (count($params) !== 1) {
-            return $this->raiseError("bad parameter(s), try \"help $command\"");
-        }
-
-        $obj  = &$this->getPackageFile($this->config, $this->_debug);
-        $info = $obj->fromAnyFile($params[0], PEAR_VALIDATE_NORMAL);
-        if (PEAR::isError($info)) {
-            return $this->raiseError($info);
-        }
-
-        $deps = $info->getDeps();
-        if (is_array($deps)) {
-            if ($info->getPackagexmlVersion() == '1.0') {
-                $data = array(
-                    'caption' => 'Dependencies for pear/' . $info->getPackage(),
-                    'border' => true,
-                    'headline' => array("Required?", "Type", "Name", "Relation", "Version"),
-                    );
-
-                foreach ($deps as $d) {
-                    if (isset($d['optional'])) {
-                        if ($d['optional'] == 'yes') {
-                            $req = 'No';
-                        } else {
-                            $req = 'Yes';
-                        }
-                    } else {
-                        $req = 'Yes';
-                    }
-
-                    if (isset($this->_deps_rel_trans[$d['rel']])) {
-                        $rel = $this->_deps_rel_trans[$d['rel']];
-                    } else {
-                        $rel = $d['rel'];
-                    }
-
-                    if (isset($this->_deps_type_trans[$d['type']])) {
-                        $type = ucfirst($this->_deps_type_trans[$d['type']]);
-                    } else {
-                        $type = $d['type'];
-                    }
-
-                    if (isset($d['name'])) {
-                        $name = $d['name'];
-                    } else {
-                        $name = '';
-                    }
-
-                    if (isset($d['version'])) {
-                        $version = $d['version'];
-                    } else {
-                        $version = '';
-                    }
-
-                    $data['data'][] = array($req, $type, $name, $rel, $version);
-                }
-            } else { // package.xml 2.0 dependencies display
-                require_once 'PEAR/Dependency2.php';
-                $deps = $info->getDependencies();
-                $reg = &$this->config->getRegistry();
-                if (is_array($deps)) {
-                    $d = new PEAR_Dependency2($this->config, array(), '');
-                    $data = array(
-                        'caption' => 'Dependencies for ' . $info->getPackage(),
-                        'border' => true,
-                        'headline' => array("Required?", "Type", "Name", 'Versioning', 'Group'),
-                        );
-                    foreach ($deps as $type => $subd) {
-                        $req = ($type == 'required') ? 'Yes' : 'No';
-                        if ($type == 'group') {
-                            $group = $subd['attribs']['name'];
-                        } else {
-                            $group = '';
-                        }
-
-                        if (!isset($subd[0])) {
-                            $subd = array($subd);
-                        }
-
-                        foreach ($subd as $groupa) {
-                            foreach ($groupa as $deptype => $depinfo) {
-                                if ($deptype == 'attribs') {
-                                    continue;
-                                }
-
-                                if ($deptype == 'pearinstaller') {
-                                    $deptype = 'pear Installer';
-                                }
-
-                                if (!isset($depinfo[0])) {
-                                    $depinfo = array($depinfo);
-                                }
-
-                                foreach ($depinfo as $inf) {
-                                    $name = '';
-                                    if (isset($inf['channel'])) {
-                                        $alias = $reg->channelAlias($inf['channel']);
-                                        if (!$alias) {
-                                            $alias = '(channel?) ' .$inf['channel'];
-                                        }
-                                        $name = $alias . '/';
-
-                                    }
-                                    if (isset($inf['name'])) {
-                                        $name .= $inf['name'];
-                                    } elseif (isset($inf['pattern'])) {
-                                        $name .= $inf['pattern'];
-                                    } else {
-                                        $name .= '';
-                                    }
-
-                                    if (isset($inf['uri'])) {
-                                        $name .= ' [' . $inf['uri'] .  ']';
-                                    }
-
-                                    if (isset($inf['conflicts'])) {
-                                        $ver = 'conflicts';
-                                    } else {
-                                        $ver = $d->_getExtraString($inf);
-                                    }
-
-                                    $data['data'][] = array($req, ucfirst($deptype), $name,
-                                        $ver, $group);
-                                }
-                            }
-                        }
-                    }
-                }
-            }
-
-            $this->ui->outputData($data, $command);
-            return true;
-        }
-
-        // Fallback
-        $this->ui->outputData("This package does not have any dependencies.", $command);
-    }
-
-    function doSign($command, $options, $params)
-    {
-        // should move most of this code into PEAR_Packager
-        // so it'll be easy to implement "pear package --sign"
-        if (count($params) !== 1) {
-            return $this->raiseError("bad parameter(s), try \"help $command\"");
-        }
-
-        require_once 'System.php';
-        require_once 'Archive/Tar.php';
-
-        if (!file_exists($params[0])) {
-            return $this->raiseError("file does not exist: $params[0]");
-        }
-
-        $obj = $this->getPackageFile($this->config, $this->_debug);
-        $info = $obj->fromTgzFile($params[0], PEAR_VALIDATE_NORMAL);
-        if (PEAR::isError($info)) {
-            return $this->raiseError($info);
-        }
-
-        $tar = new Archive_Tar($params[0]);
-        $tmpdir = System::mktemp('-d pearsign');
-        if (!$tar->extractList('package2.xml package.xml package.sig', $tmpdir)) {
-            return $this->raiseError("failed to extract tar file");
-        }
-
-        if (file_exists("$tmpdir/package.sig")) {
-            return $this->raiseError("package already signed");
-        }
-
-        $packagexml = 'package.xml';
-        if (file_exists("$tmpdir/package2.xml")) {
-            $packagexml = 'package2.xml';
-        }
-
-        if (file_exists("$tmpdir/package.sig")) {
-            unlink("$tmpdir/package.sig");
-        }
-
-        if (!file_exists("$tmpdir/$packagexml")) {
-            return $this->raiseError("Extracted file $tmpdir/$packagexml not found.");
-        }
-
-        $input = $this->ui->userDialog($command,
-                                       array('GnuPG Passphrase'),
-                                       array('password'));
-        if (!isset($input[0])) {
-            //use empty passphrase
-            $input[0] = '';
-        }
-
-        $devnull = (isset($options['verbose'])) ? '' : ' 2>/dev/null';
-        $gpg = popen("gpg --batch --passphrase-fd 0 --armor --detach-sign --output $tmpdir/package.sig $tmpdir/$packagexml" . $devnull, "w");
-        if (!$gpg) {
-            return $this->raiseError("gpg command failed");
-        }
-
-        fwrite($gpg, "$input[0]\n");
-        if (pclose($gpg) || !file_exists("$tmpdir/package.sig")) {
-            return $this->raiseError("gpg sign failed");
-        }
-
-        if (!$tar->addModify("$tmpdir/package.sig", '', $tmpdir)) {
-            return $this->raiseError('failed adding signature to file');
-        }
-
-        $this->ui->outputData("Package signed.", $command);
-        return true;
-    }
-
-    /**
-     * For unit testing purposes
-     */
-    function &getInstaller(&$ui)
-    {
-        if (!class_exists('PEAR_Installer')) {
-            require_once 'PEAR/Installer.php';
-        }
-        $a = &new PEAR_Installer($ui);
-        return $a;
-    }
-
-    /**
-     * For unit testing purposes
-     */
-    function &getCommandPackaging(&$ui, &$config)
-    {
-        if (!class_exists('PEAR_Command_Packaging')) {
-            if ($fp = @fopen('PEAR/Command/Packaging.php', 'r', true)) {
-                fclose($fp);
-                include_once 'PEAR/Command/Packaging.php';
-            }
-        }
-
-        if (class_exists('PEAR_Command_Packaging')) {
-            $a = &new PEAR_Command_Packaging($ui, $config);
-        } else {
-            $a = null;
-        }
-
-        return $a;
-    }
-
-    function doMakeRPM($command, $options, $params)
-    {
-
-        // Check to see if PEAR_Command_Packaging is installed, and
-        // transparently switch to use the "make-rpm-spec" command from it
-        // instead, if it does. Otherwise, continue to use the old version
-        // of "makerpm" supplied with this package (PEAR).
-        $packaging_cmd = $this->getCommandPackaging($this->ui, $this->config);
-        if ($packaging_cmd !== null) {
-            $this->ui->outputData('PEAR_Command_Packaging is installed; using '.
-                'newer "make-rpm-spec" command instead');
-            return $packaging_cmd->run('make-rpm-spec', $options, $params);
-        }
-
-        $this->ui->outputData('WARNING: "pear makerpm" is no longer available; an '.
-          'improved version is available via "pear make-rpm-spec", which '.
-          'is available by installing PEAR_Command_Packaging');
-        return true;
-    }
-
-    function doConvert($command, $options, $params)
-    {
-        $packagexml    = isset($params[0]) ? $params[0] : 'package.xml';
-        $newpackagexml = isset($params[1]) ? $params[1] : dirname($packagexml) .
-            DIRECTORY_SEPARATOR . 'package2.xml';
-        $pkg = &$this->getPackageFile($this->config, $this->_debug);
-        PEAR::staticPushErrorHandling(PEAR_ERROR_RETURN);
-        $pf = $pkg->fromPackageFile($packagexml, PEAR_VALIDATE_NORMAL);
-        PEAR::staticPopErrorHandling();
-        if (PEAR::isError($pf)) {
-            if (is_array($pf->getUserInfo())) {
-                foreach ($pf->getUserInfo() as $warning) {
-                    $this->ui->outputData($warning['message']);
-                }
-            }
-            return $this->raiseError($pf);
-        }
-
-        if (is_a($pf, 'PEAR_PackageFile_v2')) {
-            $this->ui->outputData($packagexml . ' is already a package.xml version 2.0');
-            return true;
-        }
-
-        $gen   = &$pf->getDefaultGenerator();
-        $newpf = &$gen->toV2();
-        $newpf->setPackagefile($newpackagexml);
-        $gen = &$newpf->getDefaultGenerator();
-        PEAR::staticPushErrorHandling(PEAR_ERROR_RETURN);
-        $state = (isset($options['flat']) ? PEAR_VALIDATE_PACKAGING : PEAR_VALIDATE_NORMAL);
-        $saved = $gen->toPackageFile(dirname($newpackagexml), $state, basename($newpackagexml));
-        PEAR::staticPopErrorHandling();
-        if (PEAR::isError($saved)) {
-            if (is_array($saved->getUserInfo())) {
-                foreach ($saved->getUserInfo() as $warning) {
-                    $this->ui->outputData($warning['message']);
-                }
-            }
-
-            $this->ui->outputData($saved->getMessage());
-            return true;
-        }
-
-        $this->ui->outputData('Wrote new version 2.0 package.xml to "' . $saved . '"');
-        return true;
-    }
-}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        PEAR-1.8.0/PEAR/Command/Pickle.xml                                                                  100777     764     764         2233      100777  11355                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
+</commands>                                                                                                                                                                                                                                                                                                                                                                                                                                                                          PEAR-1.9.0/PEAR/Command/Package.php                                                                 100664     764     764       114657      100664  11535                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_Command_Package (package, package-validate, cvsdiff, cvstag, package-dependencies,
+ * sign, makerpm, convert commands)
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Stig Bakken <ssb at php.net>
+ * @author     Martin Jansen <mj at php.net>
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Package.php 287559 2009-08-21 22:33:10Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 0.1
+ */
+
+/**
+ * base class
+ */
+require_once 'PEAR/Command/Common.php';
+
+/**
+ * PEAR commands for login/logout
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Stig Bakken <ssb at php.net>
+ * @author     Martin Jansen <mj at php.net>
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: @package_version@
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 0.1
+ */
+
+class PEAR_Command_Package extends PEAR_Command_Common
+{
+    var $commands = array(
+        'package' => array(
+            'summary' => 'Build Package',
+            'function' => 'doPackage',
+            'shortcut' => 'p',
+            'options' => array(
+                'nocompress' => array(
+                    'shortopt' => 'Z',
+                    'doc' => 'Do not gzip the package file'
+                    ),
+                'showname' => array(
+                    'shortopt' => 'n',
+                    'doc' => 'Print the name of the packaged file.',
+                    ),
+                ),
+            'doc' => '[descfile] [descfile2]
+Creates a PEAR package from its description file (usually called
+package.xml).  If a second packagefile is passed in, then
+the packager will check to make sure that one is a package.xml
+version 1.0, and the other is a package.xml version 2.0.  The
+package.xml version 1.0 will be saved as "package.xml" in the archive,
+and the other as "package2.xml" in the archive"
+'
+            ),
+        'package-validate' => array(
+            'summary' => 'Validate Package Consistency',
+            'function' => 'doPackageValidate',
+            'shortcut' => 'pv',
+            'options' => array(),
+            'doc' => '
+',
+            ),
+        'cvsdiff' => array(
+            'summary' => 'Run a "cvs diff" for all files in a package',
+            'function' => 'doCvsDiff',
+            'shortcut' => 'cd',
+            'options' => array(
+                'quiet' => array(
+                    'shortopt' => 'q',
+                    'doc' => 'Be quiet',
+                    ),
+                'reallyquiet' => array(
+                    'shortopt' => 'Q',
+                    'doc' => 'Be really quiet',
+                    ),
+                'date' => array(
+                    'shortopt' => 'D',
+                    'doc' => 'Diff against revision of DATE',
+                    'arg' => 'DATE',
+                    ),
+                'release' => array(
+                    'shortopt' => 'R',
+                    'doc' => 'Diff against tag for package release REL',
+                    'arg' => 'REL',
+                    ),
+                'revision' => array(
+                    'shortopt' => 'r',
+                    'doc' => 'Diff against revision REV',
+                    'arg' => 'REV',
+                    ),
+                'context' => array(
+                    'shortopt' => 'c',
+                    'doc' => 'Generate context diff',
+                    ),
+                'unified' => array(
+                    'shortopt' => 'u',
+                    'doc' => 'Generate unified diff',
+                    ),
+                'ignore-case' => array(
+                    'shortopt' => 'i',
+                    'doc' => 'Ignore case, consider upper- and lower-case letters equivalent',
+                    ),
+                'ignore-whitespace' => array(
+                    'shortopt' => 'b',
+                    'doc' => 'Ignore changes in amount of white space',
+                    ),
+                'ignore-blank-lines' => array(
+                    'shortopt' => 'B',
+                    'doc' => 'Ignore changes that insert or delete blank lines',
+                    ),
+                'brief' => array(
+                    'doc' => 'Report only whether the files differ, no details',
+                    ),
+                'dry-run' => array(
+                    'shortopt' => 'n',
+                    'doc' => 'Don\'t do anything, just pretend',
+                    ),
+                ),
+            'doc' => '<package.xml>
+Compares all the files in a package.  Without any options, this
+command will compare the current code with the last checked-in code.
+Using the -r or -R option you may compare the current code with that
+of a specific release.
+',
+            ),
+         'svntag' => array(
+             'summary' => 'Set SVN Release Tag',
+             'function' => 'doSvnTag',
+             'shortcut' => 'sv',
+             'options' => array(
+                 'quiet' => array(
+                     'shortopt' => 'q',
+                     'doc' => 'Be quiet',
+                     ),
+                 'slide' => array(
+                     'shortopt' => 'F',
+                     'doc' => 'Move (slide) tag if it exists',
+                     ),
+                 'delete' => array(
+                     'shortopt' => 'd',
+                     'doc' => 'Remove tag',
+                     ),
+                 'dry-run' => array(
+                     'shortopt' => 'n',
+                     'doc' => 'Don\'t do anything, just pretend',
+                     ),
+                 ),
+             'doc' => '<package.xml> [files...]
+ Sets a SVN tag on all files in a package.  Use this command after you have
+ packaged a distribution tarball with the "package" command to tag what
+ revisions of what files were in that release.  If need to fix something
+ after running cvstag once, but before the tarball is released to the public,
+ use the "slide" option to move the release tag.
+
+ to include files (such as a second package.xml, or tests not included in the
+ release), pass them as additional parameters.
+ ',
+             ),
+        'cvstag' => array(
+            'summary' => 'Set CVS Release Tag',
+            'function' => 'doCvsTag',
+            'shortcut' => 'ct',
+            'options' => array(
+                'quiet' => array(
+                    'shortopt' => 'q',
+                    'doc' => 'Be quiet',
+                    ),
+                'reallyquiet' => array(
+                    'shortopt' => 'Q',
+                    'doc' => 'Be really quiet',
+                    ),
+                'slide' => array(
+                    'shortopt' => 'F',
+                    'doc' => 'Move (slide) tag if it exists',
+                    ),
+                'delete' => array(
+                    'shortopt' => 'd',
+                    'doc' => 'Remove tag',
+                    ),
+                'dry-run' => array(
+                    'shortopt' => 'n',
+                    'doc' => 'Don\'t do anything, just pretend',
+                    ),
+                ),
+            'doc' => '<package.xml> [files...]
+Sets a CVS tag on all files in a package.  Use this command after you have
+packaged a distribution tarball with the "package" command to tag what
+revisions of what files were in that release.  If need to fix something
+after running cvstag once, but before the tarball is released to the public,
+use the "slide" option to move the release tag.
+
+to include files (such as a second package.xml, or tests not included in the
+release), pass them as additional parameters.
+',
+            ),
+        'package-dependencies' => array(
+            'summary' => 'Show package dependencies',
+            'function' => 'doPackageDependencies',
+            'shortcut' => 'pd',
+            'options' => array(),
+            'doc' => '<package-file> or <package.xml> or <install-package-name>
+List all dependencies the package has.
+Can take a tgz / tar file, package.xml or a package name of an installed package.'
+            ),
+        'sign' => array(
+            'summary' => 'Sign a package distribution file',
+            'function' => 'doSign',
+            'shortcut' => 'si',
+            'options' => array(
+                'verbose' => array(
+                    'shortopt' => 'v',
+                    'doc' => 'Display GnuPG output',
+                    ),
+            ),
+            'doc' => '<package-file>
+Signs a package distribution (.tar or .tgz) file with GnuPG.',
+            ),
+        'makerpm' => array(
+            'summary' => 'Builds an RPM spec file from a PEAR package',
+            'function' => 'doMakeRPM',
+            'shortcut' => 'rpm',
+            'options' => array(
+                'spec-template' => array(
+                    'shortopt' => 't',
+                    'arg' => 'FILE',
+                    'doc' => 'Use FILE as RPM spec file template'
+                    ),
+                'rpm-pkgname' => array(
+                    'shortopt' => 'p',
+                    'arg' => 'FORMAT',
+                    'doc' => 'Use FORMAT as format string for RPM package name, %s is replaced
+by the PEAR package name, defaults to "PEAR::%s".',
+                    ),
+                ),
+            'doc' => '<package-file>
+
+Creates an RPM .spec file for wrapping a PEAR package inside an RPM
+package.  Intended to be used from the SPECS directory, with the PEAR
+package tarball in the SOURCES directory:
+
+$ pear makerpm ../SOURCES/Net_Socket-1.0.tgz
+Wrote RPM spec file PEAR::Net_Geo-1.0.spec
+$ rpm -bb PEAR::Net_Socket-1.0.spec
+...
+Wrote: /usr/src/redhat/RPMS/i386/PEAR::Net_Socket-1.0-1.i386.rpm
+',
+            ),
+        'convert' => array(
+            'summary' => 'Convert a package.xml 1.0 to package.xml 2.0 format',
+            'function' => 'doConvert',
+            'shortcut' => 'c2',
+            'options' => array(
+                'flat' => array(
+                    'shortopt' => 'f',
+                    'doc' => 'do not beautify the filelist.',
+                    ),
+                ),
+            'doc' => '[descfile] [descfile2]
+Converts a package.xml in 1.0 format into a package.xml
+in 2.0 format.  The new file will be named package2.xml by default,
+and package.xml will be used as the old file by default.
+This is not the most intelligent conversion, and should only be
+used for automated conversion or learning the format.
+'
+            ),
+        );
+
+    var $output;
+
+    /**
+     * PEAR_Command_Package constructor.
+     *
+     * @access public
+     */
+    function PEAR_Command_Package(&$ui, &$config)
+    {
+        parent::PEAR_Command_Common($ui, $config);
+    }
+
+    function _displayValidationResults($err, $warn, $strict = false)
+    {
+        foreach ($err as $e) {
+            $this->output .= "Error: $e\n";
+        }
+        foreach ($warn as $w) {
+            $this->output .= "Warning: $w\n";
+        }
+        $this->output .= sprintf('Validation: %d error(s), %d warning(s)'."\n",
+                                       sizeof($err), sizeof($warn));
+        if ($strict && count($err) > 0) {
+            $this->output .= "Fix these errors and try again.";
+            return false;
+        }
+        return true;
+    }
+
+    function &getPackager()
+    {
+        if (!class_exists('PEAR_Packager')) {
+            require_once 'PEAR/Packager.php';
+        }
+        $a = &new PEAR_Packager;
+        return $a;
+    }
+
+    function &getPackageFile($config, $debug = false, $tmpdir = null)
+    {
+        if (!class_exists('PEAR_Common')) {
+            require_once 'PEAR/Common.php';
+        }
+        if (!class_exists('PEAR_PackageFile')) {
+            require_once 'PEAR/PackageFile.php';
+        }
+        $a = &new PEAR_PackageFile($config, $debug, $tmpdir);
+        $common = new PEAR_Common;
+        $common->ui = $this->ui;
+        $a->setLogger($common);
+        return $a;
+    }
+
+    function doPackage($command, $options, $params)
+    {
+        $this->output = '';
+        $pkginfofile = isset($params[0]) ? $params[0] : 'package.xml';
+        $pkg2 = isset($params[1]) ? $params[1] : null;
+        if (!$pkg2 && !isset($params[0]) && file_exists('package2.xml')) {
+            $pkg2 = 'package2.xml';
+        }
+
+        $packager = &$this->getPackager();
+        $compress = empty($options['nocompress']) ? true : false;
+        $result   = $packager->package($pkginfofile, $compress, $pkg2);
+        if (PEAR::isError($result)) {
+            return $this->raiseError($result);
+        }
+
+        // Don't want output, only the package file name just created
+        if (isset($options['showname'])) {
+            $this->output = $result;
+        }
+
+        if ($this->output) {
+            $this->ui->outputData($this->output, $command);
+        }
+
+        return true;
+    }
+
+    function doPackageValidate($command, $options, $params)
+    {
+        $this->output = '';
+        if (count($params) < 1) {
+            $params[0] = 'package.xml';
+        }
+
+        $obj = &$this->getPackageFile($this->config, $this->_debug);
+        $obj->rawReturn();
+        PEAR::staticPushErrorHandling(PEAR_ERROR_RETURN);
+        $info = $obj->fromTgzFile($params[0], PEAR_VALIDATE_NORMAL);
+        if (PEAR::isError($info)) {
+            $info = $obj->fromPackageFile($params[0], PEAR_VALIDATE_NORMAL);
+        } else {
+            $archive = $info->getArchiveFile();
+            $tar = &new Archive_Tar($archive);
+            $tar->extract(dirname($info->getPackageFile()));
+            $info->setPackageFile(dirname($info->getPackageFile()) . DIRECTORY_SEPARATOR .
+                $info->getPackage() . '-' . $info->getVersion() . DIRECTORY_SEPARATOR .
+                basename($info->getPackageFile()));
+        }
+
+        PEAR::staticPopErrorHandling();
+        if (PEAR::isError($info)) {
+            return $this->raiseError($info);
+        }
+
+        $valid = false;
+        if ($info->getPackagexmlVersion() == '2.0') {
+            if ($valid = $info->validate(PEAR_VALIDATE_NORMAL)) {
+                $info->flattenFileList();
+                $valid = $info->validate(PEAR_VALIDATE_PACKAGING);
+            }
+        } else {
+            $valid = $info->validate(PEAR_VALIDATE_PACKAGING);
+        }
+
+        $err = $warn = array();
+        if ($errors = $info->getValidationWarnings()) {
+            foreach ($errors as $error) {
+                if ($error['level'] == 'warning') {
+                    $warn[] = $error['message'];
+                } else {
+                    $err[] = $error['message'];
+                }
+            }
+        }
+
+        $this->_displayValidationResults($err, $warn);
+        $this->ui->outputData($this->output, $command);
+        return true;
+    }
+
+    function doSvnTag($command, $options, $params)
+    {
+        $this->output = '';
+        $_cmd = $command;
+        if (count($params) < 1) {
+            $help = $this->getHelp($command);
+            return $this->raiseError("$command: missing parameter: $help[0]");
+        }
+
+        $packageFile = realpath($params[0]);
+        $dir = dirname($packageFile);
+        $dir = substr($dir, strrpos($dir, '/') + 1);
+        $obj  = &$this->getPackageFile($this->config, $this->_debug);
+        $info = $obj->fromAnyFile($packageFile, PEAR_VALIDATE_NORMAL);
+        if (PEAR::isError($info)) {
+            return $this->raiseError($info);
+        }
+
+        $err = $warn = array();
+        if (!$info->validate()) {
+            foreach ($info->getValidationWarnings() as $error) {
+                if ($error['level'] == 'warning') {
+                    $warn[] = $error['message'];
+                } else {
+                    $err[] = $error['message'];
+                }
+            }
+        }
+
+        if (!$this->_displayValidationResults($err, $warn, true)) {
+            $this->ui->outputData($this->output, $command);
+            return $this->raiseError('SVN tag failed');
+        }
+
+        $version    = $info->getVersion();
+        $package    = $info->getName();
+        $svntag     = "$package-$version";
+
+        if (isset($options['delete'])) {
+            return $this->_svnRemoveTag($version, $package, $svntag, $packageFile, $options);
+        }
+
+        $path = $this->_svnFindPath($packageFile);
+
+        // Check if there are any modified files
+        $fp = popen('svn st --xml ' . dirname($packageFile), "r");
+        $out = '';
+        while ($line = fgets($fp, 1024)) {
+            $out .= rtrim($line)."\n";
+        }
+        pclose($fp);
+
+        if (!isset($options['quiet']) && strpos($out, 'item="modified"')) {
+            $params = array(array(
+                'name' => 'modified',
+                'type' => 'yesno',
+                'default' => 'no',
+                'prompt' => 'You have files in your SVN checkout (' . $path['from']  . ') that have been modified but not commited, do you still want to tag ' . $version . '?',
+            ));
+            $answers = $this->ui->confirmDialog($params);
+
+            if (!in_array($answers['modified'], array('y', 'yes', 'on', '1'))) {
+                return true;
+            }
+        }
+
+        if (isset($options['slide'])) {
+            $this->_svnRemoveTag($version, $package, $svntag, $packageFile, $options);
+        }
+
+        // Check if tag already exists
+        $releaseTag = $path['local']['base'] . 'tags/' . $svntag;
+        $existsCommand = 'svn ls ' . $path['base'] . 'tags/';
+
+        $fp = popen($existsCommand, "r");
+        $out = '';
+        while ($line = fgets($fp, 1024)) {
+            $out .= rtrim($line)."\n";
+        }
+        pclose($fp);
+
+        if (in_array($svntag . '/', explode("\n", $out))) {
+            $this->ui->outputData($this->output, $command);
+            return $this->raiseError('SVN tag ' . $svntag . ' for ' . $package . ' already exists.');
+        } else {
+            $makeCommand = 'svn mkdir ' . $releaseTag;
+            $this->output .= "+ $makeCommand\n";
+            if (empty($options['dry-run'])) {
+                // We need to create the tag dir.
+                $fp = popen($makeCommand, "r");
+                $out = '';
+                while ($line = fgets($fp, 1024)) {
+                    $out .= rtrim($line)."\n";
+                }
+                pclose($fp);
+                $this->output .= "$out\n";
+            }
+        }
+
+        $command = 'svn';
+        if (isset($options['quiet'])) {
+            $command .= ' -q';
+        }
+
+        $command .= ' copy --parents ';
+
+        $dir   = dirname($packageFile);
+        $dir   = substr($dir, strrpos($dir, '/') + 1);
+        $files = array_keys($info->getFilelist());
+        $commands = array();
+        foreach ($files as $file) {
+            if (!file_exists($file)) {
+                $file = $dir . DIRECTORY_SEPARATOR . $file;
+            }
+            $commands[] = $command . ' ' . escapeshellarg($file) . ' ' .
+                          escapeshellarg($releaseTag . DIRECTORY_SEPARATOR . $file);
+        }
+
+        $this->output .= implode("\n", $commands) . "\n";
+        if (empty($options['dry-run'])) {
+            foreach ($commands as $command) {
+                $fp = popen($command, "r");
+                while ($line = fgets($fp, 1024)) {
+                    $this->output .= rtrim($line)."\n";
+                }
+                pclose($fp);
+            }
+        }
+
+        $command = 'svn ci -m "Tagging the ' . $version  . ' release" ' . $releaseTag . "\n";
+        $this->output .= "+ $command\n";
+        if (empty($options['dry-run'])) {
+            $fp = popen($command, "r");
+            while ($line = fgets($fp, 1024)) {
+                $this->output .= rtrim($line)."\n";
+            }
+            pclose($fp);
+        }
+
+        $this->ui->outputData($this->output, $_cmd);
+        return true;
+    }
+
+    function _svnFindPath($file)
+    {
+        $xml = '';
+        $command = "svn info --xml $file";
+        $fp = popen($command, "r");
+        while ($line = fgets($fp, 1024)) {
+            $xml .= rtrim($line)."\n";
+        }
+        pclose($fp);
+        $url_tag = strpos($xml, '<url>');
+        $url = substr($xml, $url_tag + 5, strpos($xml, '</url>', $url_tag + 5) - ($url_tag + 5));
+
+        $path = array();
+        $path['from'] = substr($url, 0, strrpos($url, '/'));
+        $path['base'] = substr($path['from'], 0, strrpos($path['from'], '/') + 1);
+
+        // Figure out the local paths
+        $pos = strpos($file, '/trunk/');
+        if ($pos === false) {
+            $pos = strpos($file, '/branches/');
+        }
+        $path['local']['base'] = substr($file, 0, $pos + 1);
+
+        return $path;
+    }
+
+    function _svnRemoveTag($version, $package, $tag, $packageFile, $options)
+    {
+        $command = 'svn';
+
+        if (isset($options['quiet'])) {
+            $command .= ' -q';
+        }
+
+        $command .= ' remove';
+        $command .= ' -m "Removing tag for the ' . $version  . ' release."';
+
+        $path = $this->_svnFindPath($packageFile);
+        $command .= ' ' . $path['base'] . 'tags/' . $tag;
+
+
+        if ($this->config->get('verbose') > 1) {
+            $this->output .= "+ $command\n";
+        }
+
+        $this->output .= "+ $command\n";
+        if (empty($options['dry-run'])) {
+            $fp = popen($command, "r");
+            while ($line = fgets($fp, 1024)) {
+                $this->output .= rtrim($line)."\n";
+            }
+            pclose($fp);
+        }
+
+        $this->ui->outputData($this->output, $command);
+        return true;
+    }
+
+    function doCvsTag($command, $options, $params)
+    {
+        $this->output = '';
+        $_cmd = $command;
+        if (count($params) < 1) {
+            $help = $this->getHelp($command);
+            return $this->raiseError("$command: missing parameter: $help[0]");
+        }
+
+        $packageFile = realpath($params[0]);
+        $obj  = &$this->getPackageFile($this->config, $this->_debug);
+        $info = $obj->fromAnyFile($packageFile, PEAR_VALIDATE_NORMAL);
+        if (PEAR::isError($info)) {
+            return $this->raiseError($info);
+        }
+
+        $err = $warn = array();
+        if (!$info->validate()) {
+            foreach ($info->getValidationWarnings() as $error) {
+                if ($error['level'] == 'warning') {
+                    $warn[] = $error['message'];
+                } else {
+                    $err[] = $error['message'];
+                }
+            }
+        }
+
+        if (!$this->_displayValidationResults($err, $warn, true)) {
+            $this->ui->outputData($this->output, $command);
+            return $this->raiseError('CVS tag failed');
+        }
+
+        $version    = $info->getVersion();
+        $cvsversion = preg_replace('/[^a-z0-9]/i', '_', $version);
+        $cvstag     = "RELEASE_$cvsversion";
+        $files      = array_keys($info->getFilelist());
+        $command = 'cvs';
+        if (isset($options['quiet'])) {
+            $command .= ' -q';
+        }
+
+        if (isset($options['reallyquiet'])) {
+            $command .= ' -Q';
+        }
+
+        $command .= ' tag';
+        if (isset($options['slide'])) {
+            $command .= ' -F';
+        }
+
+        if (isset($options['delete'])) {
+            $command .= ' -d';
+        }
+
+        $command .= ' ' . $cvstag . ' ' . escapeshellarg($params[0]);
+        array_shift($params);
+        if (count($params)) {
+            // add in additional files to be tagged
+            $files = array_merge($files, $params);
+        }
+
+        $dir = dirname($packageFile);
+        $dir = substr($dir, strrpos($dir, '/') + 1);
+        foreach ($files as $file) {
+            if (!file_exists($file)) {
+                $file = $dir . DIRECTORY_SEPARATOR . $file;
+            }
+            $command .= ' ' . escapeshellarg($file);
+        }
+
+        if ($this->config->get('verbose') > 1) {
+            $this->output .= "+ $command\n";
+        }
+
+        $this->output .= "+ $command\n";
+        if (empty($options['dry-run'])) {
+            $fp = popen($command, "r");
+            while ($line = fgets($fp, 1024)) {
+                $this->output .= rtrim($line)."\n";
+            }
+            pclose($fp);
+        }
+
+        $this->ui->outputData($this->output, $_cmd);
+        return true;
+    }
+
+    function doCvsDiff($command, $options, $params)
+    {
+        $this->output = '';
+        if (sizeof($params) < 1) {
+            $help = $this->getHelp($command);
+            return $this->raiseError("$command: missing parameter: $help[0]");
+        }
+
+        $file = realpath($params[0]);
+        $obj  = &$this->getPackageFile($this->config, $this->_debug);
+        $info = $obj->fromAnyFile($file, PEAR_VALIDATE_NORMAL);
+        if (PEAR::isError($info)) {
+            return $this->raiseError($info);
+        }
+
+        $err = $warn = array();
+        if (!$info->validate()) {
+            foreach ($info->getValidationWarnings() as $error) {
+                if ($error['level'] == 'warning') {
+                    $warn[] = $error['message'];
+                } else {
+                    $err[] = $error['message'];
+                }
+            }
+        }
+
+        if (!$this->_displayValidationResults($err, $warn, true)) {
+            $this->ui->outputData($this->output, $command);
+            return $this->raiseError('CVS diff failed');
+        }
+
+        $info1 = $info->getFilelist();
+        $files = $info1;
+        $cmd = "cvs";
+        if (isset($options['quiet'])) {
+            $cmd .= ' -q';
+            unset($options['quiet']);
+        }
+
+        if (isset($options['reallyquiet'])) {
+            $cmd .= ' -Q';
+            unset($options['reallyquiet']);
+        }
+
+        if (isset($options['release'])) {
+            $cvsversion = preg_replace('/[^a-z0-9]/i', '_', $options['release']);
+            $cvstag = "RELEASE_$cvsversion";
+            $options['revision'] = $cvstag;
+            unset($options['release']);
+        }
+
+        $execute = true;
+        if (isset($options['dry-run'])) {
+            $execute = false;
+            unset($options['dry-run']);
+        }
+
+        $cmd .= ' diff';
+        // the rest of the options are passed right on to "cvs diff"
+        foreach ($options as $option => $optarg) {
+            $arg = $short = false;
+            if (isset($this->commands[$command]['options'][$option])) {
+                $arg = $this->commands[$command]['options'][$option]['arg'];
+                $short = $this->commands[$command]['options'][$option]['shortopt'];
+            }
+            $cmd .= $short ? " -$short" : " --$option";
+            if ($arg && $optarg) {
+                $cmd .= ($short ? '' : '=') . escapeshellarg($optarg);
+            }
+        }
+
+        foreach ($files as $file) {
+            $cmd .= ' ' . escapeshellarg($file['name']);
+        }
+
+        if ($this->config->get('verbose') > 1) {
+            $this->output .= "+ $cmd\n";
+        }
+
+        if ($execute) {
+            $fp = popen($cmd, "r");
+            while ($line = fgets($fp, 1024)) {
+                $this->output .= rtrim($line)."\n";
+            }
+            pclose($fp);
+        }
+
+        $this->ui->outputData($this->output, $command);
+        return true;
+    }
+
+    function doPackageDependencies($command, $options, $params)
+    {
+        // $params[0] -> the PEAR package to list its information
+        if (count($params) !== 1) {
+            return $this->raiseError("bad parameter(s), try \"help $command\"");
+        }
+
+        $obj = &$this->getPackageFile($this->config, $this->_debug);
+        if (is_file($params[0]) || strpos($params[0], '.xml') > 0) {
+           $info = $obj->fromAnyFile($params[0], PEAR_VALIDATE_NORMAL);
+        } else {
+            $reg  = $this->config->getRegistry();
+            $info = $obj->fromArray($reg->packageInfo($params[0]));
+        }
+
+        if (PEAR::isError($info)) {
+            return $this->raiseError($info);
+        }
+
+        $deps = $info->getDeps();
+        if (is_array($deps)) {
+            if ($info->getPackagexmlVersion() == '1.0') {
+                $data = array(
+                    'caption' => 'Dependencies for pear/' . $info->getPackage(),
+                    'border' => true,
+                    'headline' => array("Required?", "Type", "Name", "Relation", "Version"),
+                    );
+
+                foreach ($deps as $d) {
+                    if (isset($d['optional'])) {
+                        if ($d['optional'] == 'yes') {
+                            $req = 'No';
+                        } else {
+                            $req = 'Yes';
+                        }
+                    } else {
+                        $req = 'Yes';
+                    }
+
+                    if (isset($this->_deps_rel_trans[$d['rel']])) {
+                        $rel = $this->_deps_rel_trans[$d['rel']];
+                    } else {
+                        $rel = $d['rel'];
+                    }
+
+                    if (isset($this->_deps_type_trans[$d['type']])) {
+                        $type = ucfirst($this->_deps_type_trans[$d['type']]);
+                    } else {
+                        $type = $d['type'];
+                    }
+
+                    if (isset($d['name'])) {
+                        $name = $d['name'];
+                    } else {
+                        $name = '';
+                    }
+
+                    if (isset($d['version'])) {
+                        $version = $d['version'];
+                    } else {
+                        $version = '';
+                    }
+
+                    $data['data'][] = array($req, $type, $name, $rel, $version);
+                }
+            } else { // package.xml 2.0 dependencies display
+                require_once 'PEAR/Dependency2.php';
+                $deps = $info->getDependencies();
+                $reg = &$this->config->getRegistry();
+                if (is_array($deps)) {
+                    $d = new PEAR_Dependency2($this->config, array(), '');
+                    $data = array(
+                        'caption' => 'Dependencies for ' . $info->getPackage(),
+                        'border' => true,
+                        'headline' => array("Required?", "Type", "Name", 'Versioning', 'Group'),
+                        );
+                    foreach ($deps as $type => $subd) {
+                        $req = ($type == 'required') ? 'Yes' : 'No';
+                        if ($type == 'group') {
+                            $group = $subd['attribs']['name'];
+                        } else {
+                            $group = '';
+                        }
+
+                        if (!isset($subd[0])) {
+                            $subd = array($subd);
+                        }
+
+                        foreach ($subd as $groupa) {
+                            foreach ($groupa as $deptype => $depinfo) {
+                                if ($deptype == 'attribs') {
+                                    continue;
+                                }
+
+                                if ($deptype == 'pearinstaller') {
+                                    $deptype = 'pear Installer';
+                                }
+
+                                if (!isset($depinfo[0])) {
+                                    $depinfo = array($depinfo);
+                                }
+
+                                foreach ($depinfo as $inf) {
+                                    $name = '';
+                                    if (isset($inf['channel'])) {
+                                        $alias = $reg->channelAlias($inf['channel']);
+                                        if (!$alias) {
+                                            $alias = '(channel?) ' .$inf['channel'];
+                                        }
+                                        $name = $alias . '/';
+
+                                    }
+                                    if (isset($inf['name'])) {
+                                        $name .= $inf['name'];
+                                    } elseif (isset($inf['pattern'])) {
+                                        $name .= $inf['pattern'];
+                                    } else {
+                                        $name .= '';
+                                    }
+
+                                    if (isset($inf['uri'])) {
+                                        $name .= ' [' . $inf['uri'] .  ']';
+                                    }
+
+                                    if (isset($inf['conflicts'])) {
+                                        $ver = 'conflicts';
+                                    } else {
+                                        $ver = $d->_getExtraString($inf);
+                                    }
+
+                                    $data['data'][] = array($req, ucfirst($deptype), $name,
+                                        $ver, $group);
+                                }
+                            }
+                        }
+                    }
+                }
+            }
+
+            $this->ui->outputData($data, $command);
+            return true;
+        }
+
+        // Fallback
+        $this->ui->outputData("This package does not have any dependencies.", $command);
+    }
+
+    function doSign($command, $options, $params)
+    {
+        // should move most of this code into PEAR_Packager
+        // so it'll be easy to implement "pear package --sign"
+        if (count($params) !== 1) {
+            return $this->raiseError("bad parameter(s), try \"help $command\"");
+        }
+
+        require_once 'System.php';
+        require_once 'Archive/Tar.php';
+
+        if (!file_exists($params[0])) {
+            return $this->raiseError("file does not exist: $params[0]");
+        }
+
+        $obj = $this->getPackageFile($this->config, $this->_debug);
+        $info = $obj->fromTgzFile($params[0], PEAR_VALIDATE_NORMAL);
+        if (PEAR::isError($info)) {
+            return $this->raiseError($info);
+        }
+
+        $tar = new Archive_Tar($params[0]);
+        $tmpdir = System::mktemp('-d pearsign');
+        if (!$tar->extractList('package2.xml package.xml package.sig', $tmpdir)) {
+            return $this->raiseError("failed to extract tar file");
+        }
+
+        if (file_exists("$tmpdir/package.sig")) {
+            return $this->raiseError("package already signed");
+        }
+
+        $packagexml = 'package.xml';
+        if (file_exists("$tmpdir/package2.xml")) {
+            $packagexml = 'package2.xml';
+        }
+
+        if (file_exists("$tmpdir/package.sig")) {
+            unlink("$tmpdir/package.sig");
+        }
+
+        if (!file_exists("$tmpdir/$packagexml")) {
+            return $this->raiseError("Extracted file $tmpdir/$packagexml not found.");
+        }
+
+        $input = $this->ui->userDialog($command,
+                                       array('GnuPG Passphrase'),
+                                       array('password'));
+        if (!isset($input[0])) {
+            //use empty passphrase
+            $input[0] = '';
+        }
+
+        $devnull = (isset($options['verbose'])) ? '' : ' 2>/dev/null';
+        $gpg = popen("gpg --batch --passphrase-fd 0 --armor --detach-sign --output $tmpdir/package.sig $tmpdir/$packagexml" . $devnull, "w");
+        if (!$gpg) {
+            return $this->raiseError("gpg command failed");
+        }
+
+        fwrite($gpg, "$input[0]\n");
+        if (pclose($gpg) || !file_exists("$tmpdir/package.sig")) {
+            return $this->raiseError("gpg sign failed");
+        }
+
+        if (!$tar->addModify("$tmpdir/package.sig", '', $tmpdir)) {
+            return $this->raiseError('failed adding signature to file');
+        }
+
+        $this->ui->outputData("Package signed.", $command);
+        return true;
+    }
+
+    /**
+     * For unit testing purposes
+     */
+    function &getInstaller(&$ui)
+    {
+        if (!class_exists('PEAR_Installer')) {
+            require_once 'PEAR/Installer.php';
+        }
+        $a = &new PEAR_Installer($ui);
+        return $a;
+    }
+
+    /**
+     * For unit testing purposes
+     */
+    function &getCommandPackaging(&$ui, &$config)
+    {
+        if (!class_exists('PEAR_Command_Packaging')) {
+            if ($fp = @fopen('PEAR/Command/Packaging.php', 'r', true)) {
+                fclose($fp);
+                include_once 'PEAR/Command/Packaging.php';
+            }
+        }
+
+        if (class_exists('PEAR_Command_Packaging')) {
+            $a = &new PEAR_Command_Packaging($ui, $config);
+        } else {
+            $a = null;
+        }
+
+        return $a;
+    }
+
+    function doMakeRPM($command, $options, $params)
+    {
+
+        // Check to see if PEAR_Command_Packaging is installed, and
+        // transparently switch to use the "make-rpm-spec" command from it
+        // instead, if it does. Otherwise, continue to use the old version
+        // of "makerpm" supplied with this package (PEAR).
+        $packaging_cmd = $this->getCommandPackaging($this->ui, $this->config);
+        if ($packaging_cmd !== null) {
+            $this->ui->outputData('PEAR_Command_Packaging is installed; using '.
+                'newer "make-rpm-spec" command instead');
+            return $packaging_cmd->run('make-rpm-spec', $options, $params);
+        }
+
+        $this->ui->outputData('WARNING: "pear makerpm" is no longer available; an '.
+          'improved version is available via "pear make-rpm-spec", which '.
+          'is available by installing PEAR_Command_Packaging');
+        return true;
+    }
+
+    function doConvert($command, $options, $params)
+    {
+        $packagexml    = isset($params[0]) ? $params[0] : 'package.xml';
+        $newpackagexml = isset($params[1]) ? $params[1] : dirname($packagexml) .
+            DIRECTORY_SEPARATOR . 'package2.xml';
+        $pkg = &$this->getPackageFile($this->config, $this->_debug);
+        PEAR::staticPushErrorHandling(PEAR_ERROR_RETURN);
+        $pf = $pkg->fromPackageFile($packagexml, PEAR_VALIDATE_NORMAL);
+        PEAR::staticPopErrorHandling();
+        if (PEAR::isError($pf)) {
+            if (is_array($pf->getUserInfo())) {
+                foreach ($pf->getUserInfo() as $warning) {
+                    $this->ui->outputData($warning['message']);
+                }
+            }
+            return $this->raiseError($pf);
+        }
+
+        if (is_a($pf, 'PEAR_PackageFile_v2')) {
+            $this->ui->outputData($packagexml . ' is already a package.xml version 2.0');
+            return true;
+        }
+
+        $gen   = &$pf->getDefaultGenerator();
+        $newpf = &$gen->toV2();
+        $newpf->setPackagefile($newpackagexml);
+        $gen = &$newpf->getDefaultGenerator();
+        PEAR::staticPushErrorHandling(PEAR_ERROR_RETURN);
+        $state = (isset($options['flat']) ? PEAR_VALIDATE_PACKAGING : PEAR_VALIDATE_NORMAL);
+        $saved = $gen->toPackageFile(dirname($newpackagexml), $state, basename($newpackagexml));
+        PEAR::staticPopErrorHandling();
+        if (PEAR::isError($saved)) {
+            if (is_array($saved->getUserInfo())) {
+                foreach ($saved->getUserInfo() as $warning) {
+                    $this->ui->outputData($warning['message']);
+                }
+            }
+
+            $this->ui->outputData($saved->getMessage());
+            return true;
+        }
+
+        $this->ui->outputData('Wrote new version 2.0 package.xml to "' . $saved . '"');
+        return true;
+    }
+}                                                                                 PEAR-1.9.0/PEAR/Command/Pickle.xml                                                                  100664     764     764         2233      100664  11344                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
  <pickle>
   <summary>Build PECL Package</summary>
   <function>doPackage</function>
@@ -13033,7 +13520,7 @@ uses any of these features, you are best off using PEAR_PackageFileManager to
 generate both package.xml.
 </doc>
  </pickle>
-</commands>                                                                                                                                                                                                                                                                                                                                                                     PEAR-1.8.0/PEAR/Command/Pickle.php                                                                  100664     764     764        37212      100664  11357                                                                                                                                                                                                                                                                                                                                                                      <?php
+</commands>                                                                                                                                                                                                                                                                                                                                                                     PEAR-1.9.0/PEAR/Command/Pickle.php                                                                  100664     764     764        37207      100664  11364                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Command_Pickle (pickle command)
  *
@@ -13044,7 +13531,7 @@ generate both package.xml.
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  2005-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Pickle.php,v 1.13 2009/02/24 23:39:29 dufuz Exp $
+ * @version    CVS: $Id: Pickle.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.1
  */
@@ -13062,7 +13549,7 @@ require_once 'PEAR/Command/Common.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  2005-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.1
  */
@@ -13453,7 +13940,7 @@ generate both package.xml.
         $gen = &$pf->getDefaultGenerator();
         $gen->toPackageFile('.');
     }
-}                                                                                                                                                                                                                                                                                                                                                                                      PEAR-1.8.0/PEAR/Command/Registry.xml                                                                100777     764     764         3376      100777  11767                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
+}                                                                                                                                                                                                                                                                                                                                                                                         PEAR-1.9.0/PEAR/Command/Registry.xml                                                                100664     764     764         3376      100664  11756                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
  <list>
   <summary>List Installed Packages In The Default Channel</summary>
   <function>doList</function>
@@ -13510,7 +13997,7 @@ Displays information about a package. The package argument may be a
 local package file, an URL to a package file, or the name of an
 installed package.</doc>
  </info>
-</commands>                                                                                                                                                                                                                                                                  PEAR-1.8.0/PEAR/Command/Registry.php                                                                100664     764     764       132374      100664  12005                                                                                                                                                                                                                                                                                                                                                                      <?php
+</commands>                                                                                                                                                                                                                                                                  PEAR-1.9.0/PEAR/Command/Registry.php                                                                100664     764     764       132371      100664  12003                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Command_Registry (list, list-files, shell-test, info commands)
  *
@@ -13522,7 +14009,7 @@ installed package.</doc>
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Registry.php,v 1.88 2009/02/24 23:39:29 dufuz Exp $
+ * @version    CVS: $Id: Registry.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -13541,7 +14028,7 @@ require_once 'PEAR/Command/Common.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -14652,7 +15139,7 @@ installed package.'
         $data['raw'] = $obj->getArray(); // no validation needed
         $this->ui->outputData($data, 'package-info');
     }
-}                                                                                                                                                                                                                                                                    PEAR-1.8.0/PEAR/Command/Remote.xml                                                                  100777     764     764         6357      100777  11414                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
+}                                                                                                                                                                                                                                                                       PEAR-1.9.0/PEAR/Command/Remote.xml                                                                  100664     764     764         6357      100664  11403                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
  <remote-info>
   <summary>Information About Remote Packages</summary>
   <function>doRemoteInfo</function>
@@ -14760,7 +15247,7 @@ Clear the XML-RPC/REST cache.  See also the cache_ttl configuration
 parameter.
 </doc>
  </clear-cache>
-</commands>                                                                                                                                                                                                                                                                                 PEAR-1.8.0/PEAR/Command/Remote.php                                                                  100664     764     764        72007      100664  11404                                                                                                                                                                                                                                                                                                                                                                      <?php
+</commands>                                                                                                                                                                                                                                                                                 PEAR-1.9.0/PEAR/Command/Remote.php                                                                  100664     764     764        72576      100664  11420                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Command_Remote (remote-info, list-upgrades, remote-list, search, list-all, download,
  * clear-cache commands)
@@ -14773,7 +15260,7 @@ parameter.
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Remote.php,v 1.120 2009/03/09 01:33:20 dufuz Exp $
+ * @version    CVS: $Id: Remote.php 287477 2009-08-19 14:19:43Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -14793,7 +15280,7 @@ require_once 'PEAR/REST.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -15426,9 +15913,22 @@ parameter.
             }
 
             $latest = array();
-            if ($chan->supportsREST($this->config->get('preferred_mirror')) &&
-                  $base = $chan->getBaseURL('REST1.0', $this->config->get('preferred_mirror'))) {
-                $rest = &$this->config->getREST('1.0', array());
+            $base2  = false;
+            $preferred_mirror = $this->config->get('preferred_mirror');
+            if ($chan->supportsREST($preferred_mirror) &&
+                (
+                   //($base2 = $chan->getBaseURL('REST1.4', $preferred_mirror)) ||
+                   ($base  = $chan->getBaseURL('REST1.0', $preferred_mirror))
+                )
+
+            ) {
+                if ($base2) {
+                    $rest = &$this->config->getREST('1.4', array());
+                    $base = $base2;
+                } else {
+                    $rest = &$this->config->getREST('1.0', array());
+                }
+
                 if (empty($state) || $state == 'any') {
                     $state = false;
                 } else {
@@ -15555,7 +16055,7 @@ parameter.
         $this->ui->outputData(rtrim($output), $command);
         return $num;
     }
-}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         PEAR-1.8.0/PEAR/Command/Test.xml                                                                    100777     764     764         3153      100777  11067                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
+}                                                                                                                                  PEAR-1.9.0/PEAR/Command/Test.xml                                                                    100664     764     764         3151      100664  11054                                                                                                                                                                                                                                                                                                                                                                      <commands version="1.0">
  <run-tests>
   <summary>Run Regression Tests</summary>
   <function>doRunTests</function>
@@ -15588,7 +16088,7 @@ parameter.
    </package>
    <phpunit>
     <shortopt>u</shortopt>
-    <doc>Search parameters for AllTests.php, and use that to run phpunit-based tests
+    <doc>Search parameters for AllTests.php, and use that to run phpunit-based tests
 If none is found, all .phpt tests will be tried instead.</doc>
    </phpunit>
    <tapoutput>
@@ -15605,346 +16105,346 @@ If none is found, all .phpt tests will be tried instead.</doc>
     <doc>Generate a code coverage report (requires Xdebug 2.0.0+)</doc>
    </coverage>
   </options>
-  <doc>[testfile|dir ...]
+  <doc>[testfile|dir ...]
 Run regression tests with PHP&#039;s regression testing script (run-tests.php).</doc>
  </run-tests>
-</commands>                                                                                                                                                                                                                                                                                                                                                                                                                     PEAR-1.8.0/PEAR/Command/Test.php                                                                    100664     764     764        30011      100664  11055                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_Command_Test (run-tests)
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Stig Bakken <ssb at php.net>
- * @author     Martin Jansen <mj at php.net>
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Test.php,v 1.32 2009/04/04 00:06:17 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 0.1
- */
-
-/**
- * base class
- */
-require_once 'PEAR/Command/Common.php';
-
-/**
- * PEAR commands for login/logout
- *
- * @category   pear
- * @package    PEAR
- * @author     Stig Bakken <ssb at php.net>
- * @author     Martin Jansen <mj at php.net>
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 0.1
- */
-
-class PEAR_Command_Test extends PEAR_Command_Common
-{
-    var $commands = array(
-        'run-tests' => array(
-            'summary' => 'Run Regression Tests',
-            'function' => 'doRunTests',
-            'shortcut' => 'rt',
-            'options' => array(
-                'recur' => array(
-                    'shortopt' => 'r',
-                    'doc' => 'Run tests in child directories, recursively.  4 dirs deep maximum',
-                ),
-                'ini' => array(
-                    'shortopt' => 'i',
-                    'doc' => 'actual string of settings to pass to php in format " -d setting=blah"',
-                    'arg' => 'SETTINGS'
-                ),
-                'realtimelog' => array(
-                    'shortopt' => 'l',
-                    'doc' => 'Log test runs/results as they are run',
-                ),
-                'quiet' => array(
-                    'shortopt' => 'q',
-                    'doc' => 'Only display detail for failed tests',
-                ),
-                'simple' => array(
-                    'shortopt' => 's',
-                    'doc' => 'Display simple output for all tests',
-                ),
-                'package' => array(
-                    'shortopt' => 'p',
-                    'doc' => 'Treat parameters as installed packages from which to run tests',
-                ),
-                'phpunit' => array(
-                    'shortopt' => 'u',
-                    'doc' => 'Search parameters for AllTests.php, and use that to run phpunit-based tests
-If none is found, all .phpt tests will be tried instead.',
-                ),
-                'tapoutput' => array(
-                    'shortopt' => 't',
-                    'doc' => 'Output run-tests.log in TAP-compliant format',
-                ),
-                'cgi' => array(
-                    'shortopt' => 'c',
-                    'doc' => 'CGI php executable (needed for tests with POST/GET section)',
-                    'arg' => 'PHPCGI',
-                ),
-                'coverage' => array(
-                    'shortopt' => 'x',
-                    'doc'      => 'Generate a code coverage report (requires Xdebug 2.0.0+)',
-                ),
-            ),
-            'doc' => '[testfile|dir ...]
-Run regression tests with PHP\'s regression testing script (run-tests.php).',
-            ),
-        );
-
-    var $output;
-
-    /**
-     * PEAR_Command_Test constructor.
-     *
-     * @access public
-     */
-    function PEAR_Command_Test(&$ui, &$config)
-    {
-        parent::PEAR_Command_Common($ui, $config);
-    }
-
-    function doRunTests($command, $options, $params)
-    {
-        if (isset($options['phpunit']) && isset($options['tapoutput'])) {
-            return $this->raiseError('ERROR: cannot use both --phpunit and --tapoutput at the same time');
-        }
-
-        require_once 'PEAR/Common.php';
-        require_once 'System.php';
-        $log = new PEAR_Common;
-        $log->ui = &$this->ui; // slightly hacky, but it will work
-        $tests = array();
-        $depth = isset($options['recur']) ? 14 : 1;
-
-        if (!count($params)) {
-            $params[] = '.';
-        }
-
-        if (isset($options['package'])) {
-            $oldparams = $params;
-            $params = array();
-            $reg = &$this->config->getRegistry();
-            foreach ($oldparams as $param) {
-                $pname = $reg->parsePackageName($param, $this->config->get('default_channel'));
-                if (PEAR::isError($pname)) {
-                    return $this->raiseError($pname);
-                }
-
-                $package = &$reg->getPackage($pname['package'], $pname['channel']);
-                if (!$package) {
-                    return PEAR::raiseError('Unknown package "' .
-                        $reg->parsedPackageNameToString($pname) . '"');
-                }
-
-                $filelist = $package->getFilelist();
-                foreach ($filelist as $name => $atts) {
-                    if (isset($atts['role']) && $atts['role'] != 'test') {
-                        continue;
-                    }
-
-                    if (isset($options['phpunit']) && preg_match('/AllTests\.php\\z/i', $name)) {
-                        $params[] = $atts['installed_as'];
-                        continue;
-                    } elseif (!preg_match('/\.phpt\\z/', $name)) {
-                        continue;
-                    }
-                    $params[] = $atts['installed_as'];
-                }
-            }
-        }
-
-        foreach ($params as $p) {
-            if (is_dir($p)) {
-                if (isset($options['phpunit'])) {
-                    $dir = System::find(array($p, '-type', 'f',
-                                                '-maxdepth', $depth,
-                                                '-name', 'AllTests.php'));
-                    if (count($dir)) {
-                        foreach ($dir as $p) {
-                            $p = realpath($p);
-                            if (!count($tests) ||
-                                  (count($tests) && strlen($p) < strlen($tests[0]))) {
-                                // this is in a higher-level directory, use this one instead.
-                                $tests = array($p);
-                            }
-                        }
-                    }
-                    continue;
-                }
-
-                $args  = array($p, '-type', 'f', '-name', '*.phpt');
-            } else {
-                if (isset($options['phpunit'])) {
-                    if (preg_match('/AllTests\.php\\z/i', $p)) {
-                        $p = realpath($p);
-                        if (!count($tests) ||
-                              (count($tests) && strlen($p) < strlen($tests[0]))) {
-                            // this is in a higher-level directory, use this one instead.
-                            $tests = array($p);
-                        }
-                    }
-                    continue;
-                }
-
-                if (file_exists($p) && preg_match('/\.phpt$/', $p)) {
-                    $tests[] = $p;
-                    continue;
-                }
-
-                if (!preg_match('/\.phpt\\z/', $p)) {
-                    $p .= '.phpt';
-                }
-
-                $args  = array(dirname($p), '-type', 'f', '-name', $p);
-            }
-
-            if (!isset($options['recur'])) {
-                $args[] = '-maxdepth';
-                $args[] = 1;
-            }
-
-            $dir   = System::find($args);
-            $tests = array_merge($tests, $dir);
-        }
-
-        $ini_settings = '';
-        if (isset($options['ini'])) {
-            $ini_settings .= $options['ini'];
-        }
-
-        if (isset($_ENV['TEST_PHP_INCLUDE_PATH'])) {
-            $ini_settings .= " -d include_path={$_ENV['TEST_PHP_INCLUDE_PATH']}";
-        }
-
-        if ($ini_settings) {
-            $this->ui->outputData('Using INI settings: "' . $ini_settings . '"');
-        }
-
-        $skipped = $passed = $failed = array();
-        $tests_count = count($tests);
-        $this->ui->outputData('Running ' . $tests_count . ' tests', $command);
-        $start = time();
-        if (isset($options['realtimelog']) && file_exists('run-tests.log')) {
-            unlink('run-tests.log');
-        }
-
-        if (isset($options['tapoutput'])) {
-            $tap = '1..' . $tests_count . "\n";
-        }
-
-        require_once 'PEAR/RunTest.php';
-        $run = new PEAR_RunTest($log, $options);
-        $run->tests_count = $tests_count;
-
-        if (isset($options['coverage']) && extension_loaded('xdebug')){
-            $run->xdebug_loaded = true;
-        } else {
-            $run->xdebug_loaded = false;
-        }
-
-        $j = $i = 1;
-        foreach ($tests as $t) {
-            if (isset($options['realtimelog'])) {
-                $fp = @fopen('run-tests.log', 'a');
-                if ($fp) {
-                    fwrite($fp, "Running test [$i / $tests_count] $t...");
-                    fclose($fp);
-                }
-            }
-            PEAR::staticPushErrorHandling(PEAR_ERROR_RETURN);
-            if (isset($options['phpunit'])) {
-                $result = $run->runPHPUnit($t, $ini_settings);
-            } else {
-                $result = $run->run($t, $ini_settings, $j);
-            }
-            PEAR::staticPopErrorHandling();
-            if (PEAR::isError($result)) {
-                $this->ui->log($result->getMessage());
-                continue;
-            }
-
-            if (isset($options['tapoutput'])) {
-                $tap .= $result[0] . ' ' . $i . $result[1] . "\n";
-                continue;
-            }
-
-            if (isset($options['realtimelog'])) {
-                $fp = @fopen('run-tests.log', 'a');
-                if ($fp) {
-                    fwrite($fp, "$result\n");
-                    fclose($fp);
-                }
-            }
-
-            if ($result == 'FAILED') {
-                $failed[] = $t;
-            }
-            if ($result == 'PASSED') {
-                $passed[] = $t;
-            }
-            if ($result == 'SKIPPED') {
-                $skipped[] = $t;
-            }
-
-            $j++;
-        }
-
-        $total = date('i:s', time() - $start);
-        if (isset($options['tapoutput'])) {
-            $fp = @fopen('run-tests.log', 'w');
-            if ($fp) {
-                fwrite($fp, $tap, strlen($tap));
-                fclose($fp);
-                $this->ui->outputData('wrote TAP-format log to "' .realpath('run-tests.log') .
-                    '"', $command);
-            }
-        } else {
-            if (count($failed)) {
-                $output = "TOTAL TIME: $total\n";
-                $output .= count($passed) . " PASSED TESTS\n";
-                $output .= count($skipped) . " SKIPPED TESTS\n";
-                $output .= count($failed) . " FAILED TESTS:\n";
-                foreach ($failed as $failure) {
-                    $output .= $failure . "\n";
-                }
-
-                $mode = isset($options['realtimelog']) ? 'a' : 'w';
-                $fp   = @fopen('run-tests.log', $mode);
-
-                if ($fp) {
-                    fwrite($fp, $output, strlen($output));
-                    fclose($fp);
-                    $this->ui->outputData('wrote log to "' . realpath('run-tests.log') . '"', $command);
-                }
-            } elseif (file_exists('run-tests.log') && !is_dir('run-tests.log')) {
-                @unlink('run-tests.log');
-            }
-        }
-        $this->ui->outputData('TOTAL TIME: ' . $total);
-        $this->ui->outputData(count($passed) . ' PASSED TESTS', $command);
-        $this->ui->outputData(count($skipped) . ' SKIPPED TESTS', $command);
-        if (count($failed)) {
-            $this->ui->outputData(count($failed) . ' FAILED TESTS:', $command);
-            foreach ($failed as $failure) {
-                $this->ui->outputData($failure, $command);
-            }
-        }
-
-        return true;
-    }
-}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       PEAR-1.8.0/PEAR/Downloader/Package.php                                                              100664     764     764       225261      100664  12246                                                                                                                                                                                                                                                                                                                                                                      <?php
+</commands>                                                                                                                                                                                                                                                                                                                                                                                                                       PEAR-1.9.0/PEAR/Command/Test.php                                                                    100664     764     764        27267      100664  11101                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_Command_Test (run-tests)
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Stig Bakken <ssb at php.net>
+ * @author     Martin Jansen <mj at php.net>
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Test.php 279072 2009-04-20 19:57:41Z cellog $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 0.1
+ */
+
+/**
+ * base class
+ */
+require_once 'PEAR/Command/Common.php';
+
+/**
+ * PEAR commands for login/logout
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Stig Bakken <ssb at php.net>
+ * @author     Martin Jansen <mj at php.net>
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 0.1
+ */
+
+class PEAR_Command_Test extends PEAR_Command_Common
+{
+    var $commands = array(
+        'run-tests' => array(
+            'summary' => 'Run Regression Tests',
+            'function' => 'doRunTests',
+            'shortcut' => 'rt',
+            'options' => array(
+                'recur' => array(
+                    'shortopt' => 'r',
+                    'doc' => 'Run tests in child directories, recursively.  4 dirs deep maximum',
+                ),
+                'ini' => array(
+                    'shortopt' => 'i',
+                    'doc' => 'actual string of settings to pass to php in format " -d setting=blah"',
+                    'arg' => 'SETTINGS'
+                ),
+                'realtimelog' => array(
+                    'shortopt' => 'l',
+                    'doc' => 'Log test runs/results as they are run',
+                ),
+                'quiet' => array(
+                    'shortopt' => 'q',
+                    'doc' => 'Only display detail for failed tests',
+                ),
+                'simple' => array(
+                    'shortopt' => 's',
+                    'doc' => 'Display simple output for all tests',
+                ),
+                'package' => array(
+                    'shortopt' => 'p',
+                    'doc' => 'Treat parameters as installed packages from which to run tests',
+                ),
+                'phpunit' => array(
+                    'shortopt' => 'u',
+                    'doc' => 'Search parameters for AllTests.php, and use that to run phpunit-based tests
+If none is found, all .phpt tests will be tried instead.',
+                ),
+                'tapoutput' => array(
+                    'shortopt' => 't',
+                    'doc' => 'Output run-tests.log in TAP-compliant format',
+                ),
+                'cgi' => array(
+                    'shortopt' => 'c',
+                    'doc' => 'CGI php executable (needed for tests with POST/GET section)',
+                    'arg' => 'PHPCGI',
+                ),
+                'coverage' => array(
+                    'shortopt' => 'x',
+                    'doc'      => 'Generate a code coverage report (requires Xdebug 2.0.0+)',
+                ),
+            ),
+            'doc' => '[testfile|dir ...]
+Run regression tests with PHP\'s regression testing script (run-tests.php).',
+            ),
+        );
+
+    var $output;
+
+    /**
+     * PEAR_Command_Test constructor.
+     *
+     * @access public
+     */
+    function PEAR_Command_Test(&$ui, &$config)
+    {
+        parent::PEAR_Command_Common($ui, $config);
+    }
+
+    function doRunTests($command, $options, $params)
+    {
+        if (isset($options['phpunit']) && isset($options['tapoutput'])) {
+            return $this->raiseError('ERROR: cannot use both --phpunit and --tapoutput at the same time');
+        }
+
+        require_once 'PEAR/Common.php';
+        require_once 'System.php';
+        $log = new PEAR_Common;
+        $log->ui = &$this->ui; // slightly hacky, but it will work
+        $tests = array();
+        $depth = isset($options['recur']) ? 14 : 1;
+
+        if (!count($params)) {
+            $params[] = '.';
+        }
+
+        if (isset($options['package'])) {
+            $oldparams = $params;
+            $params = array();
+            $reg = &$this->config->getRegistry();
+            foreach ($oldparams as $param) {
+                $pname = $reg->parsePackageName($param, $this->config->get('default_channel'));
+                if (PEAR::isError($pname)) {
+                    return $this->raiseError($pname);
+                }
+
+                $package = &$reg->getPackage($pname['package'], $pname['channel']);
+                if (!$package) {
+                    return PEAR::raiseError('Unknown package "' .
+                        $reg->parsedPackageNameToString($pname) . '"');
+                }
+
+                $filelist = $package->getFilelist();
+                foreach ($filelist as $name => $atts) {
+                    if (isset($atts['role']) && $atts['role'] != 'test') {
+                        continue;
+                    }
+
+                    if (isset($options['phpunit']) && preg_match('/AllTests\.php\\z/i', $name)) {
+                        $params[] = $atts['installed_as'];
+                        continue;
+                    } elseif (!preg_match('/\.phpt\\z/', $name)) {
+                        continue;
+                    }
+                    $params[] = $atts['installed_as'];
+                }
+            }
+        }
+
+        foreach ($params as $p) {
+            if (is_dir($p)) {
+                if (isset($options['phpunit'])) {
+                    $dir = System::find(array($p, '-type', 'f',
+                                                '-maxdepth', $depth,
+                                                '-name', 'AllTests.php'));
+                    if (count($dir)) {
+                        foreach ($dir as $p) {
+                            $p = realpath($p);
+                            if (!count($tests) ||
+                                  (count($tests) && strlen($p) < strlen($tests[0]))) {
+                                // this is in a higher-level directory, use this one instead.
+                                $tests = array($p);
+                            }
+                        }
+                    }
+                    continue;
+                }
+
+                $args  = array($p, '-type', 'f', '-name', '*.phpt');
+            } else {
+                if (isset($options['phpunit'])) {
+                    if (preg_match('/AllTests\.php\\z/i', $p)) {
+                        $p = realpath($p);
+                        if (!count($tests) ||
+                              (count($tests) && strlen($p) < strlen($tests[0]))) {
+                            // this is in a higher-level directory, use this one instead.
+                            $tests = array($p);
+                        }
+                    }
+                    continue;
+                }
+
+                if (file_exists($p) && preg_match('/\.phpt$/', $p)) {
+                    $tests[] = $p;
+                    continue;
+                }
+
+                if (!preg_match('/\.phpt\\z/', $p)) {
+                    $p .= '.phpt';
+                }
+
+                $args  = array(dirname($p), '-type', 'f', '-name', $p);
+            }
+
+            if (!isset($options['recur'])) {
+                $args[] = '-maxdepth';
+                $args[] = 1;
+            }
+
+            $dir   = System::find($args);
+            $tests = array_merge($tests, $dir);
+        }
+
+        $ini_settings = '';
+        if (isset($options['ini'])) {
+            $ini_settings .= $options['ini'];
+        }
+
+        if (isset($_ENV['TEST_PHP_INCLUDE_PATH'])) {
+            $ini_settings .= " -d include_path={$_ENV['TEST_PHP_INCLUDE_PATH']}";
+        }
+
+        if ($ini_settings) {
+            $this->ui->outputData('Using INI settings: "' . $ini_settings . '"');
+        }
+
+        $skipped = $passed = $failed = array();
+        $tests_count = count($tests);
+        $this->ui->outputData('Running ' . $tests_count . ' tests', $command);
+        $start = time();
+        if (isset($options['realtimelog']) && file_exists('run-tests.log')) {
+            unlink('run-tests.log');
+        }
+
+        if (isset($options['tapoutput'])) {
+            $tap = '1..' . $tests_count . "\n";
+        }
+
+        require_once 'PEAR/RunTest.php';
+        $run = new PEAR_RunTest($log, $options);
+        $run->tests_count = $tests_count;
+
+        if (isset($options['coverage']) && extension_loaded('xdebug')){
+            $run->xdebug_loaded = true;
+        } else {
+            $run->xdebug_loaded = false;
+        }
+
+        $j = $i = 1;
+        foreach ($tests as $t) {
+            if (isset($options['realtimelog'])) {
+                $fp = @fopen('run-tests.log', 'a');
+                if ($fp) {
+                    fwrite($fp, "Running test [$i / $tests_count] $t...");
+                    fclose($fp);
+                }
+            }
+            PEAR::staticPushErrorHandling(PEAR_ERROR_RETURN);
+            if (isset($options['phpunit'])) {
+                $result = $run->runPHPUnit($t, $ini_settings);
+            } else {
+                $result = $run->run($t, $ini_settings, $j);
+            }
+            PEAR::staticPopErrorHandling();
+            if (PEAR::isError($result)) {
+                $this->ui->log($result->getMessage());
+                continue;
+            }
+
+            if (isset($options['tapoutput'])) {
+                $tap .= $result[0] . ' ' . $i . $result[1] . "\n";
+                continue;
+            }
+
+            if (isset($options['realtimelog'])) {
+                $fp = @fopen('run-tests.log', 'a');
+                if ($fp) {
+                    fwrite($fp, "$result\n");
+                    fclose($fp);
+                }
+            }
+
+            if ($result == 'FAILED') {
+                $failed[] = $t;
+            }
+            if ($result == 'PASSED') {
+                $passed[] = $t;
+            }
+            if ($result == 'SKIPPED') {
+                $skipped[] = $t;
+            }
+
+            $j++;
+        }
+
+        $total = date('i:s', time() - $start);
+        if (isset($options['tapoutput'])) {
+            $fp = @fopen('run-tests.log', 'w');
+            if ($fp) {
+                fwrite($fp, $tap, strlen($tap));
+                fclose($fp);
+                $this->ui->outputData('wrote TAP-format log to "' .realpath('run-tests.log') .
+                    '"', $command);
+            }
+        } else {
+            if (count($failed)) {
+                $output = "TOTAL TIME: $total\n";
+                $output .= count($passed) . " PASSED TESTS\n";
+                $output .= count($skipped) . " SKIPPED TESTS\n";
+                $output .= count($failed) . " FAILED TESTS:\n";
+                foreach ($failed as $failure) {
+                    $output .= $failure . "\n";
+                }
+
+                $mode = isset($options['realtimelog']) ? 'a' : 'w';
+                $fp   = @fopen('run-tests.log', $mode);
+
+                if ($fp) {
+                    fwrite($fp, $output, strlen($output));
+                    fclose($fp);
+                    $this->ui->outputData('wrote log to "' . realpath('run-tests.log') . '"', $command);
+                }
+            } elseif (file_exists('run-tests.log') && !is_dir('run-tests.log')) {
+                @unlink('run-tests.log');
+            }
+        }
+        $this->ui->outputData('TOTAL TIME: ' . $total);
+        $this->ui->outputData(count($passed) . ' PASSED TESTS', $command);
+        $this->ui->outputData(count($skipped) . ' SKIPPED TESTS', $command);
+        if (count($failed)) {
+            $this->ui->outputData(count($failed) . ' FAILED TESTS:', $command);
+            foreach ($failed as $failure) {
+                $this->ui->outputData($failure, $command);
+            }
+        }
+
+        return true;
+    }
+}                                                                                                                                                                                                                                                                                                                                         PEAR-1.9.0/PEAR/Downloader/Package.php                                                              100664     764     764       226171      100664  12250                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Downloader_Package
  *
@@ -15955,7 +16455,7 @@ Run regression tests with PHP\'s regression testing script (run-tests.php).',
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Package.php,v 1.126 2009/03/07 21:51:52 dufuz Exp $
+ * @version    CVS: $Id: Package.php 287560 2009-08-21 22:36:18Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -15996,7 +16496,7 @@ define('PEAR_DOWNLOADER_PACKAGE_PHPVERSION', -1004);
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -16111,6 +16611,12 @@ class PEAR_Downloader_Package
         $options = $this->_downloader->getOptions();
         if (isset($options['offline'])) {
             if (PEAR::isError($origErr) && !isset($options['soft'])) {
+                foreach ($origErr->getUserInfo() as $userInfo) {
+                    if (isset($userInfo['message'])) {
+                        $this->_downloader->log(0, $userInfo['message']);
+                    }
+                }
+
                 $this->_downloader->log(0, $origErr->getMessage());
             }
 
@@ -16208,8 +16714,15 @@ class PEAR_Downloader_Package
 
             if ($info != $newinfo) {
                 do {
-                    if ($info['package'] == 'pecl.php.net' && $newinfo['package'] == 'pear.php.net') {
-                        $info['package'] = 'pear.php.net';
+                    if ($info['channel'] == 'pecl.php.net' && $newinfo['channel'] == 'pear.php.net') {
+                        $info['channel'] = 'pear.php.net';
+                        if ($info == $newinfo) {
+                            // skip the channel check if a pecl package says it's a PEAR package
+                            break;
+                        }
+                    }
+                    if ($info['channel'] == 'pear.php.net' && $newinfo['channel'] == 'pecl.php.net') {
+                        $info['channel'] = 'pecl.php.net';
                         if ($info == $newinfo) {
                             // skip the channel check if a pecl package says it's a PEAR package
                             break;
@@ -16598,8 +17111,7 @@ class PEAR_Downloader_Package
         // we can't determine whether upgrade is necessary until we know what
         // version would be downloaded
         if (!isset($options['force']) && $this->isInstalled($ret, $oper)) {
-            $version = $this->_installRegistry->packageInfo($dep['name'], 'version',
-                $dep['channel']);
+            $version = $this->_installRegistry->packageInfo($dep['name'], 'version', $dep['channel']);
             $dep['package'] = $dep['name'];
             if (!isset($options['soft'])) {
                 $this->_downloader->log(3, $this->getShortName() . ': Skipping ' . $group .
@@ -16676,8 +17188,7 @@ class PEAR_Downloader_Package
                     $newdep = $newdep[0];
                     $newdep['channel'] = 'pecl.php.net';
                     $chan = 'pecl.php.net';
-                    $url =
-                        $this->_downloader->_getDepPackageDownloadUrl($newdep, $pname);
+                    $url = $this->_downloader->_getDepPackageDownloadUrl($newdep, $pname);
                     $obj = &$this->_installRegistry->getPackage($dep['name']);
                     if (PEAR::isError($url)) {
                         PEAR::popErrorHandling();
@@ -16761,8 +17272,7 @@ class PEAR_Downloader_Package
                         'optional';
                     $dep['package'] = $dep['name'];
                     if (isset($newdep)) {
-                        $version = $this->_installRegistry->packageInfo($newdep['name'], 'version',
-                            $newdep['channel']);
+                        $version = $this->_installRegistry->packageInfo($newdep['name'], 'version', $newdep['channel']);
                     } else {
                         $version = $this->_installRegistry->packageInfo($dep['name'], 'version');
                     }
@@ -17081,6 +17591,7 @@ class PEAR_Downloader_Package
                     $channel = 'pear.php.net';
                 }
             }
+
             return (strtolower($package) == strtolower($this->getPackage()) &&
                 $channel == $this->getChannel() &&
                 version_compare($newdep['min'], $this->getVersion(), '<=') &&
@@ -17225,13 +17736,9 @@ class PEAR_Downloader_Package
             if (!$param) {
                 continue;
             }
-            if ($param->getPackage()) {
-                if ($ignoreGroups) {
-                    $group = '';
-                } else {
-                    $group = $param->getGroup();
-                }
 
+            if ($param->getPackage()) {
+                $group = $ignoreGroups ? '' : $param->getGroup();
                 $pnames[$i] = $param->getChannel() . '/' .
                     $param->getPackage() . '-' . $param->getVersion() . '#' . $group;
             }
@@ -17761,7 +18268,7 @@ class PEAR_Downloader_Package
             if ($info['version'] === $package_version) {
                 if (!isset($options['soft'])) {
                     $this->_downloader->log(1, 'WARNING: failed to download ' . $pname['channel'] .
-                        '/' . $pname['package'] . '-' . $pname['version'] . ', additionally the suggested version' .
+                        '/' . $pname['package'] . '-' . $package_version. ', additionally the suggested version' .
                         ' (' . $package_version . ') is the same as the locally installed one.');
                 }
 
@@ -17771,7 +18278,7 @@ class PEAR_Downloader_Package
             if (version_compare($info['version'], $package_version, '<=')) {
                 if (!isset($options['soft'])) {
                     $this->_downloader->log(1, 'WARNING: failed to download ' . $pname['channel'] .
-                        '/' . $pname['package'] . '-' . $pname['version'] . ', additionally the suggested version' .
+                        '/' . $pname['package'] . '-' . $package_version . ', additionally the suggested version' .
                         ' (' . $info['version'] . ') is a lower version than the locally installed one (' . $package_version . ').');
                 }
 
@@ -17940,7 +18447,7 @@ class PEAR_Downloader_Package
 
         return $info;
     }
-}                                                                                                                                                                                                                                                                                                                                               PEAR-1.8.0/PEAR/Frontend/CLI.php                                                                    100664     764     764        60645      100664  10766                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                                                                                                                                                                                                                                       PEAR-1.9.0/PEAR/Frontend/CLI.php                                                                    100664     764     764        60642      100664  10764                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Frontend_CLI
  *
@@ -17952,7 +18459,7 @@ class PEAR_Downloader_Package
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: CLI.php,v 1.76 2009/04/04 00:09:14 dufuz Exp $
+ * @version    CVS: $Id: CLI.php 278236 2009-04-04 00:09:14Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -17969,7 +18476,7 @@ require_once 'PEAR/Frontend.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -18671,7 +19178,7 @@ class PEAR_Frontend_CLI extends PEAR_Frontend
     {
         print $text;
     }
-}                                                                                           PEAR-1.8.0/PEAR/Installer/Role/Common.php                                                           100664     764     764        14236      100664  12661                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                              PEAR-1.9.0/PEAR/Installer/Role/Common.php                                                           100664     764     764        14233      100664  12657                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * Base class for all installation roles.
  *
@@ -18682,7 +19189,7 @@ class PEAR_Frontend_CLI extends PEAR_Frontend
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2006 The PHP Group
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Common.php,v 1.13 2009/02/24 23:39:37 dufuz Exp $
+ * @version    CVS: $Id: Common.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -18697,7 +19204,7 @@ class PEAR_Frontend_CLI extends PEAR_Frontend
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2006 The PHP Group
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -18844,7 +19351,7 @@ class PEAR_Installer_Role_Common
         return $roleInfo['phpextension'];
     }
 }
-?>                                                                                                                                                                                                                                                                                                                                                                  PEAR-1.8.0/PEAR/Installer/Role/Cfg.xml                                                              100777     764     764          645      100777  12112                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
+?>                                                                                                                                                                                                                                                                                                                                                                     PEAR-1.9.0/PEAR/Installer/Role/Cfg.xml                                                              100664     764     764          645      100664  12101                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
  <releasetypes>php</releasetypes>
  <releasetypes>extsrc</releasetypes>
  <releasetypes>extbin</releasetypes>
@@ -18858,7 +19365,7 @@ class PEAR_Installer_Role_Common
  <executable />
  <phpextension />
  <config_vars />
-</role>                                                                                           PEAR-1.8.0/PEAR/Installer/Role/Cfg.php                                                              100664     764     764         7704      100664  12112                                                                                                                                                                                                                                                                                                                                                                      <?php
+</role>                                                                                           PEAR-1.9.0/PEAR/Installer/Role/Cfg.php                                                              100664     764     764         7702      100664  12111                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Installer_Role_Cfg
  *
@@ -18869,7 +19376,7 @@ class PEAR_Installer_Role_Common
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  2007-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Cfg.php,v 1.9 2009/02/24 23:39:37 dufuz Exp $
+ * @version    CVS: $Id: Cfg.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.7.0
  */
@@ -18880,7 +19387,7 @@ class PEAR_Installer_Role_Common
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  2007-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.7.0
  */
@@ -18963,7 +19470,7 @@ class PEAR_Installer_Role_Cfg extends PEAR_Installer_Role_Common
 
         return $test;
     }
-}                                                            PEAR-1.8.0/PEAR/Installer/Role/Data.xml                                                             100777     764     764          622      100777  12257                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
+}                                                              PEAR-1.9.0/PEAR/Installer/Role/Data.xml                                                             100664     764     764          622      100664  12246                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
  <releasetypes>php</releasetypes>
  <releasetypes>extsrc</releasetypes>
  <releasetypes>extbin</releasetypes>
@@ -18977,34 +19484,34 @@ class PEAR_Installer_Role_Cfg extends PEAR_Installer_Role_Common
  <executable />
  <phpextension />
  <config_vars />
-</role>                                                                                                              PEAR-1.8.0/PEAR/Installer/Role/Data.php                                                             100664     764     764         1560      100664  12256                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_Installer_Role_Data
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Data.php,v 1.8 2009/02/24 23:39:37 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Installer_Role_Data extends PEAR_Installer_Role_Common {}
-?>                                                                                                                                                PEAR-1.8.0/PEAR/Installer/Role/Doc.xml                                                              100777     764     764          621      100777  12112                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
+</role>                                                                                                              PEAR-1.9.0/PEAR/Installer/Role/Data.php                                                             100664     764     764         1523      100664  12256                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_Installer_Role_Data
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Data.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Installer_Role_Data extends PEAR_Installer_Role_Common {}
+?>                                                                                                                                                                             PEAR-1.9.0/PEAR/Installer/Role/Doc.xml                                                              100664     764     764          621      100664  12101                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
  <releasetypes>php</releasetypes>
  <releasetypes>extsrc</releasetypes>
  <releasetypes>extbin</releasetypes>
@@ -19018,34 +19525,34 @@ class PEAR_Installer_Role_Data extends PEAR_Installer_Role_Common {}
  <executable />
  <phpextension />
  <config_vars />
-</role>                                                                                                               PEAR-1.8.0/PEAR/Installer/Role/Doc.php                                                              100664     764     764         1555      100664  12116                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_Installer_Role_Doc
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Doc.php,v 1.8 2009/02/24 23:39:37 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Installer_Role_Doc extends PEAR_Installer_Role_Common {}
-?>                                                                                                                                                   PEAR-1.8.0/PEAR/Installer/Role/Ext.xml                                                              100777     764     764          502      100777  12143                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
+</role>                                                                                                               PEAR-1.9.0/PEAR/Installer/Role/Doc.php                                                              100664     764     764         1520      100664  12107                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_Installer_Role_Doc
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Doc.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Installer_Role_Doc extends PEAR_Installer_Role_Common {}
+?>                                                                                                                                                                                PEAR-1.9.0/PEAR/Installer/Role/Ext.xml                                                              100664     764     764          502      100664  12132                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
  <releasetypes>extbin</releasetypes>
  <releasetypes>zendextbin</releasetypes>
  <installable>1</installable>
@@ -19056,34 +19563,34 @@ class PEAR_Installer_Role_Doc extends PEAR_Installer_Role_Common {}
  <executable />
  <phpextension>1</phpextension>
  <config_vars />
-</role>                                                                                                                                                                                              PEAR-1.8.0/PEAR/Installer/Role/Ext.php                                                              100664     764     764         1555      100664  12151                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_Installer_Role_Ext
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Ext.php,v 1.8 2009/02/24 23:39:37 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Installer_Role_Ext extends PEAR_Installer_Role_Common {}
-?>                                                                                                                                                   PEAR-1.8.0/PEAR/Installer/Role/Php.xml                                                              100777     764     764          655      100777  12143                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
+</role>                                                                                                                                                                                              PEAR-1.9.0/PEAR/Installer/Role/Ext.php                                                              100664     764     764         1520      100664  12142                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_Installer_Role_Ext
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Ext.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Installer_Role_Ext extends PEAR_Installer_Role_Common {}
+?>                                                                                                                                                                                PEAR-1.9.0/PEAR/Installer/Role/Php.xml                                                              100664     764     764          655      100664  12132                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
  <releasetypes>php</releasetypes>
  <releasetypes>extsrc</releasetypes>
  <releasetypes>extbin</releasetypes>
@@ -19097,34 +19604,34 @@ class PEAR_Installer_Role_Ext extends PEAR_Installer_Role_Common {}
  <executable />
  <phpextension />
  <config_vars />
-</role>                                                                                   PEAR-1.8.0/PEAR/Installer/Role/Php.php                                                              100664     764     764         1555      100664  12140                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_Installer_Role_Php
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Php.php,v 1.9 2009/02/24 23:39:37 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Installer_Role_Php extends PEAR_Installer_Role_Common {}
-?>                                                                                                                                                   PEAR-1.8.0/PEAR/Installer/Role/Script.xml                                                           100777     764     764          660      100777  12654                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
+</role>                                                                                   PEAR-1.9.0/PEAR/Installer/Role/Php.php                                                              100664     764     764         1520      100664  12131                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_Installer_Role_Php
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Php.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Installer_Role_Php extends PEAR_Installer_Role_Common {}
+?>                                                                                                                                                                                PEAR-1.9.0/PEAR/Installer/Role/Script.xml                                                           100664     764     764          660      100664  12643                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
  <releasetypes>php</releasetypes>
  <releasetypes>extsrc</releasetypes>
  <releasetypes>extbin</releasetypes>
@@ -19138,78 +19645,78 @@ class PEAR_Installer_Role_Php extends PEAR_Installer_Role_Common {}
  <executable>1</executable>
  <phpextension />
  <config_vars />
-</role>                                                                                PEAR-1.8.0/PEAR/Installer/Role/Script.php                                                           100664     764     764         1566      100664  12657                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_Installer_Role_Script
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Script.php,v 1.8 2009/02/24 23:39:37 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Installer_Role_Script extends PEAR_Installer_Role_Common {}
-?>                                                                                                                                          PEAR-1.8.0/PEAR/Installer/Role/Src.xml                                                              100777     764     764          455      100777  12141                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
- <releasetypes>extsrc</releasetypes>
- <releasetypes>zendextsrc</releasetypes>
- <installable>1</installable>
- <locationconfig>temp_dir</locationconfig>
- <honorsbaseinstall />
- <unusualbaseinstall />
- <phpfile />
- <executable />
- <phpextension />
- <config_vars />
-</role>                                                                                                                                                                                                                   PEAR-1.8.0/PEAR/Installer/Role/Src.php                                                              100664     764     764         1730      100664  12133                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_Installer_Role_Src
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Src.php,v 1.8 2009/02/24 23:39:37 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Installer_Role_Src extends PEAR_Installer_Role_Common
-{
-    function setup(&$installer, $pkg, $atts, $file)
-    {
-        $installer->source_files++;
-    }
-}
-?>                                        PEAR-1.8.0/PEAR/Installer/Role/Test.xml                                                             100777     764     764          622      100777  12325                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
+</role>                                                                                PEAR-1.9.0/PEAR/Installer/Role/Script.php                                                           100664     764     764         1531      100664  12650                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_Installer_Role_Script
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Script.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Installer_Role_Script extends PEAR_Installer_Role_Common {}
+?>                                                                                                                                                                       PEAR-1.9.0/PEAR/Installer/Role/Src.xml                                                              100664     764     764          442      100664  12124                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
+ <releasetypes>extsrc</releasetypes>
+ <releasetypes>zendextsrc</releasetypes>
+ <installable>1</installable>
+ <locationconfig>temp_dir</locationconfig>
+ <honorsbaseinstall />
+ <unusualbaseinstall />
+ <phpfile />
+ <executable />
+ <phpextension />
+ <config_vars />
+</role>                                                                                                                                                                                                                              PEAR-1.9.0/PEAR/Installer/Role/Src.php                                                              100664     764     764         1665      100664  12143                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_Installer_Role_Src
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Src.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Installer_Role_Src extends PEAR_Installer_Role_Common
+{
+    function setup(&$installer, $pkg, $atts, $file)
+    {
+        $installer->source_files++;
+    }
+}
+?>                                                                           PEAR-1.9.0/PEAR/Installer/Role/Test.xml                                                             100664     764     764          622      100664  12314                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
  <releasetypes>php</releasetypes>
  <releasetypes>extsrc</releasetypes>
  <releasetypes>extbin</releasetypes>
@@ -19223,350 +19730,350 @@ class PEAR_Installer_Role_Src extends PEAR_Installer_Role_Common
  <executable />
  <phpextension />
  <config_vars />
-</role>                                                                                                              PEAR-1.8.0/PEAR/Installer/Role/Test.php                                                             100664     764     764         1560      100664  12324                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_Installer_Role_Test
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Test.php,v 1.8 2009/02/24 23:39:37 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Installer_Role_Test extends PEAR_Installer_Role_Common {}
-?>                                                                                                                                                PEAR-1.8.0/PEAR/Installer/Role/Www.xml                                                              100777     764     764          662      100777  12176                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
- <releasetypes>php</releasetypes>
- <releasetypes>extsrc</releasetypes>
- <releasetypes>extbin</releasetypes>
- <releasetypes>zendextsrc</releasetypes>
- <releasetypes>zendextbin</releasetypes>
- <installable>1</installable>
- <locationconfig>www_dir</locationconfig>
- <honorsbaseinstall>1</honorsbaseinstall>
- <unusualbaseinstall />
- <phpfile />
- <executable />
- <phpextension />
- <config_vars />
-</role>                                                                              PEAR-1.8.0/PEAR/Installer/Role/Www.php                                                              100664     764     764         1551      100664  12171                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_Installer_Role_Www
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  2007-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Www.php,v 1.3 2009/02/24 23:39:37 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.7.0
- */
-
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  2007-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.7.0
- */
-class PEAR_Installer_Role_Www extends PEAR_Installer_Role_Common {}
-?>                                                                                                                                                       PEAR-1.8.0/PEAR/Installer/Role.php                                                                  100664     764     764        20112      100664  11417                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_Installer_Role
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Role.php,v 1.22 2009/04/10 19:42:49 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * base class for installer roles
- */
-require_once 'PEAR/Installer/Role/Common.php';
-require_once 'PEAR/XMLParser.php';
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Installer_Role
-{
-    /**
-     * Set up any additional configuration variables that file roles require
-     *
-     * Never call this directly, it is called by the PEAR_Config constructor
-     * @param PEAR_Config
-     * @access private
-     * @static
-     */
-    function initializeConfig(&$config)
-    {
-        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
-            PEAR_Installer_Role::registerRoles();
-        }
-
-        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $class => $info) {
-            if (!$info['config_vars']) {
-                continue;
-            }
-
-            $config->_addConfigVars($class, $info['config_vars']);
-        }
-    }
-
-    /**
-     * @param PEAR_PackageFile_v2
-     * @param string role name
-     * @param PEAR_Config
-     * @return PEAR_Installer_Role_Common
-     * @static
-     */
-    function &factory($pkg, $role, &$config)
-    {
-        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
-            PEAR_Installer_Role::registerRoles();
-        }
-
-        if (!in_array($role, PEAR_Installer_Role::getValidRoles($pkg->getPackageType()))) {
-            $a = false;
-            return $a;
-        }
-
-        $a = 'PEAR_Installer_Role_' . ucfirst($role);
-        if (!class_exists($a)) {
-            require_once str_replace('_', '/', $a) . '.php';
-        }
-
-        $b = new $a($config);
-        return $b;
-    }
-
-    /**
-     * Get a list of file roles that are valid for the particular release type.
-     *
-     * For instance, src files serve no purpose in regular php releases.
-     * @param string
-     * @param bool clear cache
-     * @return array
-     * @static
-     */
-    function getValidRoles($release, $clear = false)
-    {
-        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
-            PEAR_Installer_Role::registerRoles();
-        }
-
-        static $ret = array();
-        if ($clear) {
-            $ret = array();
-        }
-
-        if (isset($ret[$release])) {
-            return $ret[$release];
-        }
-
-        $ret[$release] = array();
-        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
-            if (in_array($release, $okreleases['releasetypes'])) {
-                $ret[$release][] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
-            }
-        }
-
-        return $ret[$release];
-    }
-
-    /**
-     * Get a list of roles that require their files to be installed
-     *
-     * Most roles must be installed, but src and package roles, for instance
-     * are pseudo-roles.  src files are compiled into a new extension.  Package
-     * roles are actually fully bundled releases of a package
-     * @param bool clear cache
-     * @return array
-     * @static
-     */
-    function getInstallableRoles($clear = false)
-    {
-        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
-            PEAR_Installer_Role::registerRoles();
-        }
-
-        static $ret;
-        if ($clear) {
-            unset($ret);
-        }
-
-        if (isset($ret)) {
-            return $ret;
-        }
-
-        $ret = array();
-        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
-            if ($okreleases['installable']) {
-                $ret[] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
-            }
-        }
-
-        return $ret;
-    }
-
-    /**
-     * Return an array of roles that are affected by the baseinstalldir attribute
-     *
-     * Most roles ignore this attribute, and instead install directly into:
-     * PackageName/filepath
-     * so a tests file tests/file.phpt is installed into PackageName/tests/filepath.php
-     * @param bool clear cache
-     * @return array
-     * @static
-     */
-    function getBaseinstallRoles($clear = false)
-    {
-        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
-            PEAR_Installer_Role::registerRoles();
-        }
-
-        static $ret;
-        if ($clear) {
-            unset($ret);
-        }
-
-        if (isset($ret)) {
-            return $ret;
-        }
-
-        $ret = array();
-        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
-            if ($okreleases['honorsbaseinstall']) {
-                $ret[] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
-            }
-        }
-
-        return $ret;
-    }
-
-    /**
-     * Return an array of file roles that should be analyzed for PHP content at package time,
-     * like the "php" role.
-     * @param bool clear cache
-     * @return array
-     * @static
-     */
-    function getPhpRoles($clear = false)
-    {
-        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
-            PEAR_Installer_Role::registerRoles();
-        }
-
-        static $ret;
-        if ($clear) {
-            unset($ret);
-        }
-
-        if (isset($ret)) {
-            return $ret;
-        }
-
-        $ret = array();
-        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
-            if ($okreleases['phpfile']) {
-                $ret[] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
-            }
-        }
-
-        return $ret;
-    }
-
-    /**
-     * Scan through the Command directory looking for classes
-     * and see what commands they implement.
-     * @param string which directory to look for classes, defaults to
-     *               the Installer/Roles subdirectory of
-     *               the directory from where this file (__FILE__) is
-     *               included.
-     *
-     * @return bool TRUE on success, a PEAR error on failure
-     * @access public
-     * @static
-     */
-    function registerRoles($dir = null)
-    {
-        $GLOBALS['_PEAR_INSTALLER_ROLES'] = array();
-        $parser = new PEAR_XMLParser;
-        if ($dir === null) {
-            $dir = dirname(__FILE__) . '/Role';
-        }
-
-        if (!file_exists($dir) || !is_dir($dir)) {
-            return PEAR::raiseError("registerRoles: opendir($dir) failed: does not exist/is not directory");
-        }
-
-        $dp = @opendir($dir);
-        if (empty($dp)) {
-            return PEAR::raiseError("registerRoles: opendir($dir) failed: $php_errmsg");
-        }
-
-        while ($entry = readdir($dp)) {
-            if ($entry{0} == '.' || substr($entry, -4) != '.xml') {
-                continue;
-            }
-
-            $class = "PEAR_Installer_Role_".substr($entry, 0, -4);
-            // List of roles
-            if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'][$class])) {
-                $file = "$dir/$entry";
-                $parser->parse(file_get_contents($file));
-                $data = $parser->getData();
-                if (!is_array($data['releasetypes'])) {
-                    $data['releasetypes'] = array($data['releasetypes']);
-                }
-
-                $GLOBALS['_PEAR_INSTALLER_ROLES'][$class] = $data;
-            }
-        }
-
-        closedir($dp);
-        ksort($GLOBALS['_PEAR_INSTALLER_ROLES']);
-        PEAR_Installer_Role::getBaseinstallRoles(true);
-        PEAR_Installer_Role::getInstallableRoles(true);
-        PEAR_Installer_Role::getPhpRoles(true);
-        PEAR_Installer_Role::getValidRoles('****', true);
-        return true;
-    }
-}                                                                                                                                                                                                                                                                                                                                                                                                                                                      PEAR-1.8.0/PEAR/PackageFile/Generator/v1.php                                                        100664     764     764       142407      100664  13224                                                                                                                                                                                                                                                                                                                                                                      <?php
+</role>                                                                                                              PEAR-1.9.0/PEAR/Installer/Role/Test.php                                                             100664     764     764         1523      100664  12324                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_Installer_Role_Test
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Test.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Installer_Role_Test extends PEAR_Installer_Role_Common {}
+?>                                                                                                                                                                             PEAR-1.9.0/PEAR/Installer/Role/Www.xml                                                              100664     764     764          644      100664  12165                                                                                                                                                                                                                                                                                                                                                                      <role version="1.0">
+ <releasetypes>php</releasetypes>
+ <releasetypes>extsrc</releasetypes>
+ <releasetypes>extbin</releasetypes>
+ <releasetypes>zendextsrc</releasetypes>
+ <releasetypes>zendextbin</releasetypes>
+ <installable>1</installable>
+ <locationconfig>www_dir</locationconfig>
+ <honorsbaseinstall>1</honorsbaseinstall>
+ <unusualbaseinstall />
+ <phpfile />
+ <executable />
+ <phpextension />
+ <config_vars />
+</role>                                                                                            PEAR-1.9.0/PEAR/Installer/Role/Www.php                                                              100664     764     764         1514      100664  12171                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_Installer_Role_Www
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  2007-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Www.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.7.0
+ */
+
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  2007-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.7.0
+ */
+class PEAR_Installer_Role_Www extends PEAR_Installer_Role_Common {}
+?>                                                                                                                                                                                    PEAR-1.9.0/PEAR/Installer/Role.php                                                                  100664     764     764        17464      100664  11440                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_Installer_Role
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Role.php 278552 2009-04-10 19:42:49Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * base class for installer roles
+ */
+require_once 'PEAR/Installer/Role/Common.php';
+require_once 'PEAR/XMLParser.php';
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Installer_Role
+{
+    /**
+     * Set up any additional configuration variables that file roles require
+     *
+     * Never call this directly, it is called by the PEAR_Config constructor
+     * @param PEAR_Config
+     * @access private
+     * @static
+     */
+    function initializeConfig(&$config)
+    {
+        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
+            PEAR_Installer_Role::registerRoles();
+        }
+
+        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $class => $info) {
+            if (!$info['config_vars']) {
+                continue;
+            }
+
+            $config->_addConfigVars($class, $info['config_vars']);
+        }
+    }
+
+    /**
+     * @param PEAR_PackageFile_v2
+     * @param string role name
+     * @param PEAR_Config
+     * @return PEAR_Installer_Role_Common
+     * @static
+     */
+    function &factory($pkg, $role, &$config)
+    {
+        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
+            PEAR_Installer_Role::registerRoles();
+        }
+
+        if (!in_array($role, PEAR_Installer_Role::getValidRoles($pkg->getPackageType()))) {
+            $a = false;
+            return $a;
+        }
+
+        $a = 'PEAR_Installer_Role_' . ucfirst($role);
+        if (!class_exists($a)) {
+            require_once str_replace('_', '/', $a) . '.php';
+        }
+
+        $b = new $a($config);
+        return $b;
+    }
+
+    /**
+     * Get a list of file roles that are valid for the particular release type.
+     *
+     * For instance, src files serve no purpose in regular php releases.
+     * @param string
+     * @param bool clear cache
+     * @return array
+     * @static
+     */
+    function getValidRoles($release, $clear = false)
+    {
+        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
+            PEAR_Installer_Role::registerRoles();
+        }
+
+        static $ret = array();
+        if ($clear) {
+            $ret = array();
+        }
+
+        if (isset($ret[$release])) {
+            return $ret[$release];
+        }
+
+        $ret[$release] = array();
+        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
+            if (in_array($release, $okreleases['releasetypes'])) {
+                $ret[$release][] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
+            }
+        }
+
+        return $ret[$release];
+    }
+
+    /**
+     * Get a list of roles that require their files to be installed
+     *
+     * Most roles must be installed, but src and package roles, for instance
+     * are pseudo-roles.  src files are compiled into a new extension.  Package
+     * roles are actually fully bundled releases of a package
+     * @param bool clear cache
+     * @return array
+     * @static
+     */
+    function getInstallableRoles($clear = false)
+    {
+        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
+            PEAR_Installer_Role::registerRoles();
+        }
+
+        static $ret;
+        if ($clear) {
+            unset($ret);
+        }
+
+        if (isset($ret)) {
+            return $ret;
+        }
+
+        $ret = array();
+        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
+            if ($okreleases['installable']) {
+                $ret[] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
+            }
+        }
+
+        return $ret;
+    }
+
+    /**
+     * Return an array of roles that are affected by the baseinstalldir attribute
+     *
+     * Most roles ignore this attribute, and instead install directly into:
+     * PackageName/filepath
+     * so a tests file tests/file.phpt is installed into PackageName/tests/filepath.php
+     * @param bool clear cache
+     * @return array
+     * @static
+     */
+    function getBaseinstallRoles($clear = false)
+    {
+        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
+            PEAR_Installer_Role::registerRoles();
+        }
+
+        static $ret;
+        if ($clear) {
+            unset($ret);
+        }
+
+        if (isset($ret)) {
+            return $ret;
+        }
+
+        $ret = array();
+        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
+            if ($okreleases['honorsbaseinstall']) {
+                $ret[] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
+            }
+        }
+
+        return $ret;
+    }
+
+    /**
+     * Return an array of file roles that should be analyzed for PHP content at package time,
+     * like the "php" role.
+     * @param bool clear cache
+     * @return array
+     * @static
+     */
+    function getPhpRoles($clear = false)
+    {
+        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
+            PEAR_Installer_Role::registerRoles();
+        }
+
+        static $ret;
+        if ($clear) {
+            unset($ret);
+        }
+
+        if (isset($ret)) {
+            return $ret;
+        }
+
+        $ret = array();
+        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
+            if ($okreleases['phpfile']) {
+                $ret[] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
+            }
+        }
+
+        return $ret;
+    }
+
+    /**
+     * Scan through the Command directory looking for classes
+     * and see what commands they implement.
+     * @param string which directory to look for classes, defaults to
+     *               the Installer/Roles subdirectory of
+     *               the directory from where this file (__FILE__) is
+     *               included.
+     *
+     * @return bool TRUE on success, a PEAR error on failure
+     * @access public
+     * @static
+     */
+    function registerRoles($dir = null)
+    {
+        $GLOBALS['_PEAR_INSTALLER_ROLES'] = array();
+        $parser = new PEAR_XMLParser;
+        if ($dir === null) {
+            $dir = dirname(__FILE__) . '/Role';
+        }
+
+        if (!file_exists($dir) || !is_dir($dir)) {
+            return PEAR::raiseError("registerRoles: opendir($dir) failed: does not exist/is not directory");
+        }
+
+        $dp = @opendir($dir);
+        if (empty($dp)) {
+            return PEAR::raiseError("registerRoles: opendir($dir) failed: $php_errmsg");
+        }
+
+        while ($entry = readdir($dp)) {
+            if ($entry{0} == '.' || substr($entry, -4) != '.xml') {
+                continue;
+            }
+
+            $class = "PEAR_Installer_Role_".substr($entry, 0, -4);
+            // List of roles
+            if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'][$class])) {
+                $file = "$dir/$entry";
+                $parser->parse(file_get_contents($file));
+                $data = $parser->getData();
+                if (!is_array($data['releasetypes'])) {
+                    $data['releasetypes'] = array($data['releasetypes']);
+                }
+
+                $GLOBALS['_PEAR_INSTALLER_ROLES'][$class] = $data;
+            }
+        }
+
+        closedir($dp);
+        ksort($GLOBALS['_PEAR_INSTALLER_ROLES']);
+        PEAR_Installer_Role::getBaseinstallRoles(true);
+        PEAR_Installer_Role::getInstallableRoles(true);
+        PEAR_Installer_Role::getPhpRoles(true);
+        PEAR_Installer_Role::getValidRoles('****', true);
+        return true;
+    }
+}                                                                                                                                                                                                            PEAR-1.9.0/PEAR/PackageFile/Generator/v1.php                                                        100664     764     764       142342      100664  13223                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * package.xml generation class, package.xml version 1.0
  *
@@ -19577,7 +20084,7 @@ class PEAR_Installer_Role
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: v1.php,v 1.76 2009/02/24 23:45:26 dufuz Exp $
+ * @version    CVS: $Id: v1.php 286494 2009-07-29 06:57:11Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -19597,7 +20104,7 @@ require_once 'PEAR/PackageFile/v2.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -19614,7 +20121,7 @@ class PEAR_PackageFile_Generator_v1
 
     function getPackagerVersion()
     {
-        return '1.8.0';
+        return '1.9.0';
     }
 
     /**
@@ -19768,7 +20275,7 @@ class PEAR_PackageFile_Generator_v1
             );
         $ret = "<?xml version=\"1.0\" encoding=\"UTF-8\" ?>\n";
         $ret .= "<!DOCTYPE package SYSTEM \"http://pear.php.net/dtd/package-1.0\">\n";
-        $ret .= "<package version=\"1.0\" packagerversion=\"1.8.0\">\n" .
+        $ret .= "<package version=\"1.0\" packagerversion=\"1.9.0\">\n" .
 " <name>$pkginfo[package]</name>";
         if (isset($pkginfo['extends'])) {
             $ret .= "\n<extends>$pkginfo[extends]</extends>";
@@ -20783,16 +21290,15 @@ class PEAR_PackageFile_Generator_v1
      */
     function _processMultipleDepsName($deps)
     {
-        $tests = array();
+        $ret = $tests = array();
         foreach ($deps as $name => $dep) {
             foreach ($dep as $d) {
                 $tests[$name][] = $this->_processDep($d);
             }
         }
+
         foreach ($tests as $name => $test) {
-            $php = array();
-            $min = array();
-            $max = array();
+            $max = $min = $php = array();
             $php['name'] = $name;
             foreach ($test as $dep) {
                 if (!$dep) {
@@ -20850,7 +21356,7 @@ class PEAR_PackageFile_Generator_v1
         return $ret;
     }
 }
-?>                                                                                                                                                                                                                                                         PEAR-1.8.0/PEAR/PackageFile/Generator/v2.php                                                        100664     764     764       101226      100664  13217                                                                                                                                                                                                                                                                                                                                                                      <?php
+?>                                                                                                                                                                                                                                                                                              PEAR-1.9.0/PEAR/PackageFile/Generator/v2.php                                                        100664     764     764       101360      100664  13217                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * package.xml generation class, package.xml version 2.0
  *
@@ -20862,7 +21368,7 @@ class PEAR_PackageFile_Generator_v1
  * @author     Stephan Schmidt (original XML_Serializer code)
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: v2.php,v 1.51 2009/03/27 17:11:18 dufuz Exp $
+ * @version    CVS: $Id: v2.php 278907 2009-04-17 21:10:04Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -20883,7 +21389,7 @@ require_once 'XML/Util.php';
  * @author     Stephan Schmidt (original XML_Serializer code)
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -20965,7 +21471,7 @@ http://pear.php.net/dtd/package-2.0.xsd',
      */
     function getPackagerVersion()
     {
-        return '1.8.0';
+        return '1.9.0';
     }
 
     /**
@@ -21229,7 +21735,8 @@ http://pear.php.net/dtd/package-2.0.xsd',
                 $arr['changelog']['release'][0] = $release;
             }
 
-            foreach ($arr['changelog']['release'] as &$c) {
+            foreach (array_keys($arr['changelog']['release']) as $key) {
+                $c =& $arr['changelog']['release'][$key];
                 if (isset($c['notes'])) {
                     // This trims out the indenting, needs fixing
                     $c['notes'] = "\n" . trim($c['notes']) . "\n";
@@ -21249,7 +21756,7 @@ http://pear.php.net/dtd/package-2.0.xsd',
             $this->options['beautifyFilelist'] = true;
         }
 
-        $arr['attribs']['packagerversion'] = '1.8.0';
+        $arr['attribs']['packagerversion'] = '1.9.0';
         if ($this->serialize($arr, $options)) {
             return $this->_serializedData . "\n";
         }
@@ -21723,7 +22230,7 @@ http://pear.php.net/dtd/package-2.0.xsd',
             if ($this->options['encoding'] == 'UTF-8' &&
                   version_compare(phpversion(), '5.0.0', 'lt')
             ) {
-                $tag = utf8_encode($tag);
+                $tag['content'] = utf8_encode($tag['content']);
             }
 
             if ($replaceEntities === true) {
@@ -21741,7 +22248,7 @@ http://pear.php.net/dtd/package-2.0.xsd',
         }
         return  $tag;
     }
-}                                                                                                                                                                                                                                                                                                                                                                          PEAR-1.8.0/PEAR/PackageFile/Parser/v1.php                                                           100664     764     764        40317      100664  12507                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                                                                                                                PEAR-1.9.0/PEAR/PackageFile/Parser/v1.php                                                           100664     764     764        40314      100664  12505                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * package.xml parsing class, package.xml version 1.0
  *
@@ -21752,7 +22259,7 @@ http://pear.php.net/dtd/package-2.0.xsd',
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: v1.php,v 1.30 2009/02/24 23:45:22 dufuz Exp $
+ * @version    CVS: $Id: v1.php 276385 2009-02-24 23:46:03Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -22199,7 +22706,7 @@ class PEAR_PackageFile_Parser_v1
 
     // }}}
 }
-?>                                                                                                                                                                                                                                                                                                                 PEAR-1.8.0/PEAR/PackageFile/Parser/v2.php                                                           100664     764     764         6220      100664  12463                                                                                                                                                                                                                                                                                                                                                                      <?php
+?>                                                                                                                                                                                                                                                                                                                    PEAR-1.9.0/PEAR/PackageFile/Parser/v2.php                                                           100664     764     764         6215      100664  12470                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * package.xml parsing class, package.xml version 2.0
  *
@@ -22210,7 +22717,7 @@ class PEAR_PackageFile_Parser_v1
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: v2.php,v 1.24 2009/02/24 23:45:22 dufuz Exp $
+ * @version    CVS: $Id: v2.php 276385 2009-02-24 23:46:03Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -22311,7 +22818,7 @@ class PEAR_PackageFile_Parser_v2 extends PEAR_XMLParser
         $ret->setPackagefile($file, $archive);
         return $ret;
     }
-}                                                                                                                                                                                                                                                                                                                                                                                PEAR-1.8.0/PEAR/PackageFile/v2/rw.php                                                               100664     764     764       173213      100664  11726                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                                                                                                                                                                                                                   PEAR-1.9.0/PEAR/PackageFile/v2/rw.php                                                               100664     764     764       173210      100664  11724                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_PackageFile_v2, package.xml version 2.0, read/write version
  *
@@ -22322,7 +22829,7 @@ class PEAR_PackageFile_Parser_v2 extends PEAR_XMLParser
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: rw.php,v 1.25 2009/02/24 23:46:03 dufuz Exp $
+ * @version    CVS: $Id: rw.php 276385 2009-02-24 23:46:03Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a8
  */
@@ -22336,7 +22843,7 @@ require_once 'PEAR/PackageFile/v2.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a8
  */
@@ -23914,7 +24421,7 @@ class PEAR_PackageFile_v2_rw extends PEAR_PackageFile_v2
     {
         unset($this->_packageInfo['changelog']);
     }
-}                                                                                                                                                                                                                                                                                                                                                                                     PEAR-1.8.0/PEAR/PackageFile/v2/Validator.php                                                        100664     764     764       250045      100664  13222                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                                                                                                                                                                                                                        PEAR-1.9.0/PEAR/PackageFile/v2/Validator.php                                                        100664     764     764       250041      100664  13217                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_PackageFile_v2, package.xml version 2.0, read/write version
  *
@@ -23925,7 +24432,7 @@ class PEAR_PackageFile_v2_rw extends PEAR_PackageFile_v2
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Validator.php,v 1.110 2009/03/27 19:29:31 dufuz Exp $
+ * @version    CVS: $Id: Validator.php 277885 2009-03-27 19:29:31Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a8
  */
@@ -23937,7 +24444,7 @@ class PEAR_PackageFile_v2_rw extends PEAR_PackageFile_v2
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a8
  * @access private
@@ -24028,7 +24535,7 @@ class PEAR_PackageFile_v2_Validator
               isset($test['dependencies']['required']) &&
               isset($test['dependencies']['required']['pearinstaller']) &&
               isset($test['dependencies']['required']['pearinstaller']['min']) &&
-              version_compare('1.8.0',
+              version_compare('1.9.0',
                 $test['dependencies']['required']['pearinstaller']['min'], '<')
         ) {
             $this->_pearVersionTooLow($test['dependencies']['required']['pearinstaller']['min']);
@@ -25267,7 +25774,7 @@ class PEAR_PackageFile_v2_Validator
         $this->_stack->push(__FUNCTION__, 'error',
             array('version' => $version),
             'This package.xml requires PEAR version %version% to parse properly, we are ' .
-            'version 1.8.0');
+            'version 1.9.0');
     }
 
     function _invalidTagOrder($oktags, $actual, $root)
@@ -26067,1619 +26574,1619 @@ class PEAR_PackageFile_v2_Validator
 
         return $providesret;
     }
-}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           PEAR-1.8.0/PEAR/PackageFile/v1.php                                                                  100664     764     764       147077      100664  11306                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_PackageFile_v1, package.xml version 1.0
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: v1.php,v 1.75 2009/02/24 23:39:16 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-/**
- * For error handling
- */
-require_once 'PEAR/ErrorStack.php';
-
-/**
- * Error code if parsing is attempted with no xml extension
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_XML_EXT', 3);
-
-/**
- * Error code if creating the xml parser resource fails
- */
-define('PEAR_PACKAGEFILE_ERROR_CANT_MAKE_PARSER', 4);
-
-/**
- * Error code used for all sax xml parsing errors
- */
-define('PEAR_PACKAGEFILE_ERROR_PARSER_ERROR', 5);
-
-/**
- * Error code used when there is no name
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_NAME', 6);
-
-/**
- * Error code when a package name is not valid
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_NAME', 7);
-
-/**
- * Error code used when no summary is parsed
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_SUMMARY', 8);
-
-/**
- * Error code for summaries that are more than 1 line
- */
-define('PEAR_PACKAGEFILE_ERROR_MULTILINE_SUMMARY', 9);
-
-/**
- * Error code used when no description is present
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_DESCRIPTION', 10);
-
-/**
- * Error code used when no license is present
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_LICENSE', 11);
-
-/**
- * Error code used when a <version> version number is not present
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_VERSION', 12);
-
-/**
- * Error code used when a <version> version number is invalid
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_VERSION', 13);
-
-/**
- * Error code when release state is missing
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_STATE', 14);
-
-/**
- * Error code when release state is invalid
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_STATE', 15);
-
-/**
- * Error code when release state is missing
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_DATE', 16);
-
-/**
- * Error code when release state is invalid
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_DATE', 17);
-
-/**
- * Error code when no release notes are found
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_NOTES', 18);
-
-/**
- * Error code when no maintainers are found
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_MAINTAINERS', 19);
-
-/**
- * Error code when a maintainer has no handle
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_MAINTHANDLE', 20);
-
-/**
- * Error code when a maintainer has no handle
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_MAINTROLE', 21);
-
-/**
- * Error code when a maintainer has no name
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_MAINTNAME', 22);
-
-/**
- * Error code when a maintainer has no email
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_MAINTEMAIL', 23);
-
-/**
- * Error code when a maintainer has no handle
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_MAINTROLE', 24);
-
-/**
- * Error code when a dependency is not a PHP dependency, but has no name
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_DEPNAME', 25);
-
-/**
- * Error code when a dependency has no type (pkg, php, etc.)
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_DEPTYPE', 26);
-
-/**
- * Error code when a dependency has no relation (lt, ge, has, etc.)
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_DEPREL', 27);
-
-/**
- * Error code when a dependency is not a 'has' relation, but has no version
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_DEPVERSION', 28);
-
-/**
- * Error code when a dependency has an invalid relation
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPREL', 29);
-
-/**
- * Error code when a dependency has an invalid type
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPTYPE', 30);
-
-/**
- * Error code when a dependency has an invalid optional option
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPOPTIONAL', 31);
-
-/**
- * Error code when a dependency is a pkg dependency, and has an invalid package name
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPNAME', 32);
-
-/**
- * Error code when a dependency has a channel="foo" attribute, and foo is not a registered channel
- */
-define('PEAR_PACKAGEFILE_ERROR_UNKNOWN_DEPCHANNEL', 33);
-
-/**
- * Error code when rel="has" and version attribute is present.
- */
-define('PEAR_PACKAGEFILE_ERROR_DEPVERSION_IGNORED', 34);
-
-/**
- * Error code when type="php" and dependency name is present
- */
-define('PEAR_PACKAGEFILE_ERROR_DEPNAME_IGNORED', 35);
-
-/**
- * Error code when a configure option has no name
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_CONFNAME', 36);
-
-/**
- * Error code when a configure option has no name
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_CONFPROMPT', 37);
-
-/**
- * Error code when a file in the filelist has an invalid role
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_FILEROLE', 38);
-
-/**
- * Error code when a file in the filelist has no role
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_FILEROLE', 39);
-
-/**
- * Error code when analyzing a php source file that has parse errors
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE', 40);
-
-/**
- * Error code when analyzing a php source file reveals a source element
- * without a package name prefix
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX', 41);
-
-/**
- * Error code when an unknown channel is specified
- */
-define('PEAR_PACKAGEFILE_ERROR_UNKNOWN_CHANNEL', 42);
-
-/**
- * Error code when no files are found in the filelist
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_FILES', 43);
-
-/**
- * Error code when a file is not valid php according to _analyzeSourceCode()
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_FILE', 44);
-
-/**
- * Error code when the channel validator returns an error or warning
- */
-define('PEAR_PACKAGEFILE_ERROR_CHANNELVAL', 45);
-
-/**
- * Error code when a php5 package is packaged in php4 (analysis doesn't work)
- */
-define('PEAR_PACKAGEFILE_ERROR_PHP5', 46);
-
-/**
- * Error code when a file is listed in package.xml but does not exist
- */
-define('PEAR_PACKAGEFILE_ERROR_FILE_NOTFOUND', 47);
-
-/**
- * Error code when a <dep type="php" rel="not"... is encountered (use rel="ne")
- */
-define('PEAR_PACKAGEFILE_PHP_NO_NOT', 48);
-
-/**
- * Error code when a package.xml contains non-ISO-8859-1 characters
- */
-define('PEAR_PACKAGEFILE_ERROR_NON_ISO_CHARS', 49);
-
-/**
- * Error code when a dependency is not a 'has' relation, but has no version
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_DEPPHPVERSION', 50);
-
-/**
- * Error code when a package has no lead developer
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_LEAD', 51);
-
-/**
- * Error code when a filename begins with "."
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME', 52);
-/**
- * package.xml encapsulator
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_PackageFile_v1
-{
-    /**
-     * @access private
-     * @var PEAR_ErrorStack
-     * @access private
-     */
-    var $_stack;
-
-    /**
-     * A registry object, used to access the package name validation regex for non-standard channels
-     * @var PEAR_Registry
-     * @access private
-     */
-    var $_registry;
-
-    /**
-     * An object that contains a log method that matches PEAR_Common::log's signature
-     * @var object
-     * @access private
-     */
-    var $_logger;
-
-    /**
-     * Parsed package information
-     * @var array
-     * @access private
-     */
-    var $_packageInfo;
-
-    /**
-     * path to package.xml
-     * @var string
-     * @access private
-     */
-    var $_packageFile;
-
-    /**
-     * path to package .tgz or false if this is a local/extracted package.xml
-     * @var string
-     * @access private
-     */
-    var $_archiveFile;
-
-    /**
-     * @var int
-     * @access private
-     */
-    var $_isValid = 0;
-
-    /**
-     * Determines whether this packagefile was initialized only with partial package info
-     *
-     * If this package file was constructed via parsing REST, it will only contain
-     *
-     * - package name
-     * - channel name
-     * - dependencies 
-     * @var boolean
-     * @access private
-     */
-    var $_incomplete = true;
-
-    /**
-     * @param bool determines whether to return a PEAR_Error object, or use the PEAR_ErrorStack
-     * @param string Name of Error Stack class to use.
-     */
-    function PEAR_PackageFile_v1()
-    {
-        $this->_stack = &new PEAR_ErrorStack('PEAR_PackageFile_v1');
-        $this->_stack->setErrorMessageTemplate($this->_getErrorMessage());
-        $this->_isValid = 0;
-    }
-
-    function installBinary($installer)
-    {
-        return false;
-    }
-
-    function isExtension($name)
-    {
-        return false;
-    }
-
-    function setConfig(&$config)
-    {
-        $this->_config = &$config;
-        $this->_registry = &$config->getRegistry();
-    }
-
-    function setRequestedGroup()
-    {
-        // placeholder
-    }
-
-    /**
-     * For saving in the registry.
-     *
-     * Set the last version that was installed
-     * @param string
-     */
-    function setLastInstalledVersion($version)
-    {
-        $this->_packageInfo['_lastversion'] = $version;
-    }
-
-    /**
-     * @return string|false
-     */
-    function getLastInstalledVersion()
-    {
-        if (isset($this->_packageInfo['_lastversion'])) {
-            return $this->_packageInfo['_lastversion'];
-        }
-        return false;
-    }
-
-    function getInstalledBinary()
-    {
-        return false;
-    }
-
-    function listPostinstallScripts()
-    {
-        return false;
-    }
-
-    function initPostinstallScripts()
-    {
-        return false;
-    }
-
-    function setLogger(&$logger)
-    {
-        if ($logger && (!is_object($logger) || !method_exists($logger, 'log'))) {
-            return PEAR::raiseError('Logger must be compatible with PEAR_Common::log');
-        }
-        $this->_logger = &$logger;
-    }
-
-    function setPackagefile($file, $archive = false)
-    {
-        $this->_packageFile = $file;
-        $this->_archiveFile = $archive ? $archive : $file;
-    }
-
-    function getPackageFile()
-    {
-        return isset($this->_packageFile) ? $this->_packageFile : false;
-    }
-
-    function getPackageType()
-    {
-        return 'php';
-    }
-
-    function getArchiveFile()
-    {
-        return $this->_archiveFile;
-    }
-
-    function packageInfo($field)
-    {
-        if (!is_string($field) || empty($field) ||
-            !isset($this->_packageInfo[$field])) {
-            return false;
-        }
-        return $this->_packageInfo[$field];
-    }
-
-    function setDirtree($path)
-    {
-        if (!isset($this->_packageInfo['dirtree'])) {
-            $this->_packageInfo['dirtree'] = array();
-        }
-        $this->_packageInfo['dirtree'][$path] = true;
-    }
-
-    function getDirtree()
-    {
-        if (isset($this->_packageInfo['dirtree']) && count($this->_packageInfo['dirtree'])) {
-            return $this->_packageInfo['dirtree'];
-        }
-        return false;
-    }
-
-    function resetDirtree()
-    {
-        unset($this->_packageInfo['dirtree']);
-    }
-
-    function fromArray($pinfo)
-    {
-        $this->_incomplete = false;
-        $this->_packageInfo = $pinfo;
-    }
-
-    function isIncomplete()
-    {
-        return $this->_incomplete;
-    }
-
-    function getChannel()
-    {
-        return 'pear.php.net';
-    }
-
-    function getUri()
-    {
-        return false;
-    }
-
-    function getTime()
-    {
-        return false;
-    }
-
-    function getExtends()
-    {
-        if (isset($this->_packageInfo['extends'])) {
-            return $this->_packageInfo['extends'];
-        }
-        return false;
-    }
-
-    /**
-     * @return array
-     */
-    function toArray()
-    {
-        if (!$this->validate(PEAR_VALIDATE_NORMAL)) {
-            return false;
-        }
-        return $this->getArray();
-    }
-
-    function getArray()
-    {
-        return $this->_packageInfo;
-    }
-
-    function getName()
-    {
-        return $this->getPackage();
-    }
-
-    function getPackage()
-    {
-        if (isset($this->_packageInfo['package'])) {
-            return $this->_packageInfo['package'];
-        }
-        return false;
-    }
-
-    /**
-     * WARNING - don't use this unless you know what you are doing
-     */
-    function setRawPackage($package)
-    {
-        $this->_packageInfo['package'] = $package;
-    }
-
-    function setPackage($package)
-    {
-        $this->_packageInfo['package'] = $package;
-        $this->_isValid = false;
-    }
-
-    function getVersion()
-    {
-        if (isset($this->_packageInfo['version'])) {
-            return $this->_packageInfo['version'];
-        }
-        return false;
-    }
-
-    function setVersion($version)
-    {
-        $this->_packageInfo['version'] = $version;
-        $this->_isValid = false;
-    }
-
-    function clearMaintainers()
-    {
-        unset($this->_packageInfo['maintainers']);
-    }
-
-    function getMaintainers()
-    {
-        if (isset($this->_packageInfo['maintainers'])) {
-            return $this->_packageInfo['maintainers'];
-        }
-        return false;
-    }
-
-    /**
-     * Adds a new maintainer - no checking of duplicates is performed, use
-     * updatemaintainer for that purpose.
-     */
-    function addMaintainer($role, $handle, $name, $email)
-    {
-        $this->_packageInfo['maintainers'][] =
-            array('handle' => $handle, 'role' => $role, 'email' => $email, 'name' => $name);
-        $this->_isValid = false;
-    }
-
-    function updateMaintainer($role, $handle, $name, $email)
-    {
-        $found = false;
-        if (!isset($this->_packageInfo['maintainers']) ||
-              !is_array($this->_packageInfo['maintainers'])) {
-            return $this->addMaintainer($role, $handle, $name, $email);
-        }
-        foreach ($this->_packageInfo['maintainers'] as $i => $maintainer) {
-            if ($maintainer['handle'] == $handle) {
-                $found = $i;
-                break;
-            }
-        }
-        if ($found !== false) {
-            unset($this->_packageInfo['maintainers'][$found]);
-            $this->_packageInfo['maintainers'] =
-                array_values($this->_packageInfo['maintainers']);
-        }
-        $this->addMaintainer($role, $handle, $name, $email);
-    }
-
-    function deleteMaintainer($handle)
-    {
-        $found = false;
-        foreach ($this->_packageInfo['maintainers'] as $i => $maintainer) {
-            if ($maintainer['handle'] == $handle) {
-                $found = $i;
-                break;
-            }
-        }
-        if ($found !== false) {
-            unset($this->_packageInfo['maintainers'][$found]);
-            $this->_packageInfo['maintainers'] =
-                array_values($this->_packageInfo['maintainers']);
-            return true;
-        }
-        return false;
-    }
-
-    function getState()
-    {
-        if (isset($this->_packageInfo['release_state'])) {
-            return $this->_packageInfo['release_state'];
-        }
-        return false;
-    }
-
-    function setRawState($state)
-    {
-        $this->_packageInfo['release_state'] = $state;
-    }
-
-    function setState($state)
-    {
-        $this->_packageInfo['release_state'] = $state;
-        $this->_isValid = false;
-    }
-
-    function getDate()
-    {
-        if (isset($this->_packageInfo['release_date'])) {
-            return $this->_packageInfo['release_date'];
-        }
-        return false;
-    }
-
-    function setDate($date)
-    {
-        $this->_packageInfo['release_date'] = $date;
-        $this->_isValid = false;
-    }
-
-    function getLicense()
-    {
-        if (isset($this->_packageInfo['release_license'])) {
-            return $this->_packageInfo['release_license'];
-        }
-        return false;
-    }
-
-    function setLicense($date)
-    {
-        $this->_packageInfo['release_license'] = $date;
-        $this->_isValid = false;
-    }
-
-    function getSummary()
-    {
-        if (isset($this->_packageInfo['summary'])) {
-            return $this->_packageInfo['summary'];
-        }
-        return false;
-    }
-
-    function setSummary($summary)
-    {
-        $this->_packageInfo['summary'] = $summary;
-        $this->_isValid = false;
-    }
-
-    function getDescription()
-    {
-        if (isset($this->_packageInfo['description'])) {
-            return $this->_packageInfo['description'];
-        }
-        return false;
-    }
-
-    function setDescription($desc)
-    {
-        $this->_packageInfo['description'] = $desc;
-        $this->_isValid = false;
-    }
-
-    function getNotes()
-    {
-        if (isset($this->_packageInfo['release_notes'])) {
-            return $this->_packageInfo['release_notes'];
-        }
-        return false;
-    }
-
-    function setNotes($notes)
-    {
-        $this->_packageInfo['release_notes'] = $notes;
-        $this->_isValid = false;
-    }
-
-    function getDeps()
-    {
-        if (isset($this->_packageInfo['release_deps'])) {
-            return $this->_packageInfo['release_deps'];
-        }
-        return false;
-    }
-
-    /**
-     * Reset dependencies prior to adding new ones
-     */
-    function clearDeps()
-    {
-        unset($this->_packageInfo['release_deps']);
-    }
-
-    function addPhpDep($version, $rel)
-    {
-        $this->_isValid = false;
-        $this->_packageInfo['release_deps'][] =
-            array('type' => 'php',
-                  'rel' => $rel,
-                  'version' => $version);
-    }
-
-    function addPackageDep($name, $version, $rel, $optional = 'no')
-    {
-        $this->_isValid = false;
-        $dep =
-            array('type' => 'pkg',
-                  'name' => $name,
-                  'rel' => $rel,
-                  'optional' => $optional);
-        if ($rel != 'has' && $rel != 'not') {
-            $dep['version'] = $version;
-        }
-        $this->_packageInfo['release_deps'][] = $dep;
-    }
-
-    function addExtensionDep($name, $version, $rel, $optional = 'no')
-    {
-        $this->_isValid = false;
-        $this->_packageInfo['release_deps'][] =
-            array('type' => 'ext',
-                  'name' => $name,
-                  'rel' => $rel,
-                  'version' => $version,
-                  'optional' => $optional);
-    }
-
-    /**
-     * WARNING - do not use this function directly unless you know what you're doing
-     */
-    function setDeps($deps)
-    {
-        $this->_packageInfo['release_deps'] = $deps;
-    }
-
-    function hasDeps()
-    {
-        return isset($this->_packageInfo['release_deps']) &&
-            count($this->_packageInfo['release_deps']);
-    }
-
-    function getDependencyGroup($group)
-    {
-        return false;
-    }
-
-    function isCompatible($pf)
-    {
-        return false;
-    }
-
-    function isSubpackageOf($p)
-    {
-        return $p->isSubpackage($this);
-    }
-
-    function isSubpackage($p)
-    {
-        return false;
-    }
-
-    function dependsOn($package, $channel)
-    {
-        if (strtolower($channel) != 'pear.php.net') {
-            return false;
-        }
-        if (!($deps = $this->getDeps())) {
-            return false;
-        }
-        foreach ($deps as $dep) {
-            if ($dep['type'] != 'pkg') {
-                continue;
-            }
-            if (strtolower($dep['name']) == strtolower($package)) {
-                return true;
-            }
-        }
-        return false;
-    }
-
-    function getConfigureOptions()
-    {
-        if (isset($this->_packageInfo['configure_options'])) {
-            return $this->_packageInfo['configure_options'];
-        }
-        return false;
-    }
-
-    function hasConfigureOptions()
-    {
-        return isset($this->_packageInfo['configure_options']) &&
-            count($this->_packageInfo['configure_options']);
-    }
-
-    function addConfigureOption($name, $prompt, $default = false)
-    {
-        $o = array('name' => $name, 'prompt' => $prompt);
-        if ($default !== false) {
-            $o['default'] = $default;
-        }
-        if (!isset($this->_packageInfo['configure_options'])) {
-            $this->_packageInfo['configure_options'] = array();
-        }
-        $this->_packageInfo['configure_options'][] = $o;
-    }
-
-    function clearConfigureOptions()
-    {
-        unset($this->_packageInfo['configure_options']);
-    }
-
-    function getProvides()
-    {
-        if (isset($this->_packageInfo['provides'])) {
-            return $this->_packageInfo['provides'];
-        }
-        return false;
-    }
-
-    function getProvidesExtension()
-    {
-        return false;
-    }
-
-    function addFile($dir, $file, $attrs)
-    {
-        $dir = preg_replace(array('!\\\\+!', '!/+!'), array('/', '/'), $dir);
-        if ($dir == '/' || $dir == '') {
-            $dir = '';
-        } else {
-            $dir .= '/';
-        }
-        $file = $dir . $file;
-        $file = preg_replace('![\\/]+!', '/', $file);
-        $this->_packageInfo['filelist'][$file] = $attrs;
-    }
-
-    function getInstallationFilelist()
-    {
-        return $this->getFilelist();
-    }
-
-    function getFilelist()
-    {
-        if (isset($this->_packageInfo['filelist'])) {
-            return $this->_packageInfo['filelist'];
-        }
-        return false;
-    }
-
-    function setFileAttribute($file, $attr, $value)
-    {
-        $this->_packageInfo['filelist'][$file][$attr] = $value;
-    }
-
-    function resetFilelist()
-    {
-        $this->_packageInfo['filelist'] = array();
-    }
-
-    function setInstalledAs($file, $path)
-    {
-        if ($path) {
-            return $this->_packageInfo['filelist'][$file]['installed_as'] = $path;
-        }
-        unset($this->_packageInfo['filelist'][$file]['installed_as']);
-    }
-
-    function installedFile($file, $atts)
-    {
-        if (isset($this->_packageInfo['filelist'][$file])) {
-            $this->_packageInfo['filelist'][$file] =
-                array_merge($this->_packageInfo['filelist'][$file], $atts);
-        } else {
-            $this->_packageInfo['filelist'][$file] = $atts;
-        }
-    }
-
-    function getChangelog()
-    {
-        if (isset($this->_packageInfo['changelog'])) {
-            return $this->_packageInfo['changelog'];
-        }
-        return false;
-    }
-
-    function getPackagexmlVersion()
-    {
-        return '1.0';
-    }
-
-    /**
-     * Wrapper to {@link PEAR_ErrorStack::getErrors()}
-     * @param boolean determines whether to purge the error stack after retrieving
-     * @return array
-     */
-    function getValidationWarnings($purge = true)
-    {
-        return $this->_stack->getErrors($purge);
-    }
-
-    // }}}
-    /**
-     * Validation error.  Also marks the object contents as invalid
-     * @param error code
-     * @param array error information
-     * @access private
-     */
-    function _validateError($code, $params = array())
-    {
-        $this->_stack->push($code, 'error', $params, false, false, debug_backtrace());
-        $this->_isValid = false;
-    }
-
-    /**
-     * Validation warning.  Does not mark the object contents invalid.
-     * @param error code
-     * @param array error information
-     * @access private
-     */
-    function _validateWarning($code, $params = array())
-    {
-        $this->_stack->push($code, 'warning', $params, false, false, debug_backtrace());
-    }
-
-    /**
-     * @param integer error code
-     * @access protected
-     */
-    function _getErrorMessage()
-    {
-        return array(
-                PEAR_PACKAGEFILE_ERROR_NO_NAME =>
-                    'Missing Package Name',
-                PEAR_PACKAGEFILE_ERROR_NO_SUMMARY =>
-                    'No summary found',
-                PEAR_PACKAGEFILE_ERROR_MULTILINE_SUMMARY =>
-                    'Summary should be on one line',
-                PEAR_PACKAGEFILE_ERROR_NO_DESCRIPTION =>
-                    'Missing description',
-                PEAR_PACKAGEFILE_ERROR_NO_LICENSE =>
-                    'Missing license',
-                PEAR_PACKAGEFILE_ERROR_NO_VERSION =>
-                    'No release version found',
-                PEAR_PACKAGEFILE_ERROR_NO_STATE =>
-                    'No release state found',
-                PEAR_PACKAGEFILE_ERROR_NO_DATE =>
-                    'No release date found',
-                PEAR_PACKAGEFILE_ERROR_NO_NOTES =>
-                    'No release notes found',
-                PEAR_PACKAGEFILE_ERROR_NO_LEAD =>
-                    'Package must have at least one lead maintainer',
-                PEAR_PACKAGEFILE_ERROR_NO_MAINTAINERS =>
-                    'No maintainers found, at least one must be defined',
-                PEAR_PACKAGEFILE_ERROR_NO_MAINTHANDLE =>
-                    'Maintainer %index% has no handle (user ID at channel server)',
-                PEAR_PACKAGEFILE_ERROR_NO_MAINTROLE =>
-                    'Maintainer %index% has no role',
-                PEAR_PACKAGEFILE_ERROR_NO_MAINTNAME =>
-                    'Maintainer %index% has no name',
-                PEAR_PACKAGEFILE_ERROR_NO_MAINTEMAIL =>
-                    'Maintainer %index% has no email',
-                PEAR_PACKAGEFILE_ERROR_NO_DEPNAME =>
-                    'Dependency %index% is not a php dependency, and has no name',
-                PEAR_PACKAGEFILE_ERROR_NO_DEPREL =>
-                    'Dependency %index% has no relation (rel)',
-                PEAR_PACKAGEFILE_ERROR_NO_DEPTYPE =>
-                    'Dependency %index% has no type',
-                PEAR_PACKAGEFILE_ERROR_DEPNAME_IGNORED =>
-                    'PHP Dependency %index% has a name attribute of "%name%" which will be' .
-                        ' ignored!',
-                PEAR_PACKAGEFILE_ERROR_NO_DEPVERSION =>
-                    'Dependency %index% is not a rel="has" or rel="not" dependency, ' .
-                        'and has no version',
-                PEAR_PACKAGEFILE_ERROR_NO_DEPPHPVERSION =>
-                    'Dependency %index% is a type="php" dependency, ' .
-                        'and has no version',
-                PEAR_PACKAGEFILE_ERROR_DEPVERSION_IGNORED =>
-                    'Dependency %index% is a rel="%rel%" dependency, versioning is ignored',
-                PEAR_PACKAGEFILE_ERROR_INVALID_DEPOPTIONAL =>
-                    'Dependency %index% has invalid optional value "%opt%", should be yes or no',
-                PEAR_PACKAGEFILE_PHP_NO_NOT =>
-                    'Dependency %index%: php dependencies cannot use "not" rel, use "ne"' .
-                        ' to exclude specific versions',
-                PEAR_PACKAGEFILE_ERROR_NO_CONFNAME =>
-                    'Configure Option %index% has no name',
-                PEAR_PACKAGEFILE_ERROR_NO_CONFPROMPT =>
-                    'Configure Option %index% has no prompt',
-                PEAR_PACKAGEFILE_ERROR_NO_FILES =>
-                    'No files in <filelist> section of package.xml',
-                PEAR_PACKAGEFILE_ERROR_NO_FILEROLE =>
-                    'File "%file%" has no role, expecting one of "%roles%"',
-                PEAR_PACKAGEFILE_ERROR_INVALID_FILEROLE =>
-                    'File "%file%" has invalid role "%role%", expecting one of "%roles%"',
-                PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME =>
-                    'File "%file%" cannot start with ".", cannot package or install',
-                PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE =>
-                    'Parser error: invalid PHP found in file "%file%"',
-                PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX =>
-                    'in %file%: %type% "%name%" not prefixed with package name "%package%"',
-                PEAR_PACKAGEFILE_ERROR_INVALID_FILE =>
-                    'Parser error: invalid PHP file "%file%"',
-                PEAR_PACKAGEFILE_ERROR_CHANNELVAL =>
-                    'Channel validator error: field "%field%" - %reason%',
-                PEAR_PACKAGEFILE_ERROR_PHP5 =>
-                    'Error, PHP5 token encountered in %file%, analysis should be in PHP5',
-                PEAR_PACKAGEFILE_ERROR_FILE_NOTFOUND =>
-                    'File "%file%" in package.xml does not exist',
-                PEAR_PACKAGEFILE_ERROR_NON_ISO_CHARS =>
-                    'Package.xml contains non-ISO-8859-1 characters, and may not validate',
-            );
-    }
-
-    /**
-     * Validate XML package definition file.
-     *
-     * @access public
-     * @return boolean
-     */
-    function validate($state = PEAR_VALIDATE_NORMAL, $nofilechecking = false)
-    {
-        if (($this->_isValid & $state) == $state) {
-            return true;
-        }
-        $this->_isValid = true;
-        $info = $this->_packageInfo;
-        if (empty($info['package'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_NAME);
-            $this->_packageName = $pn = 'unknown';
-        } else {
-            $this->_packageName = $pn = $info['package'];
-        }
-
-        if (empty($info['summary'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_SUMMARY);
-        } elseif (strpos(trim($info['summary']), "\n") !== false) {
-            $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_MULTILINE_SUMMARY,
-                array('summary' => $info['summary']));
-        }
-        if (empty($info['description'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DESCRIPTION);
-        }
-        if (empty($info['release_license'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_LICENSE);
-        }
-        if (empty($info['version'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_VERSION);
-        }
-        if (empty($info['release_state'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_STATE);
-        }
-        if (empty($info['release_date'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DATE);
-        }
-        if (empty($info['release_notes'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_NOTES);
-        }
-        if (empty($info['maintainers'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTAINERS);
-        } else {
-            $haslead = false;
-            $i = 1;
-            foreach ($info['maintainers'] as $m) {
-                if (empty($m['handle'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTHANDLE,
-                        array('index' => $i));
-                }
-                if (empty($m['role'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTROLE,
-                        array('index' => $i, 'roles' => PEAR_Common::getUserRoles()));
-                } elseif ($m['role'] == 'lead') {
-                    $haslead = true;
-                }
-                if (empty($m['name'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTNAME,
-                        array('index' => $i));
-                }
-                if (empty($m['email'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTEMAIL,
-                        array('index' => $i));
-                }
-                $i++;
-            }
-            if (!$haslead) {
-                $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_LEAD);
-            }
-        }
-        if (!empty($info['release_deps'])) {
-            $i = 1;
-            foreach ($info['release_deps'] as $d) {
-                if (!isset($d['type']) || empty($d['type'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPTYPE,
-                        array('index' => $i, 'types' => PEAR_Common::getDependencyTypes()));
-                    continue;
-                }
-                if (!isset($d['rel']) || empty($d['rel'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPREL,
-                        array('index' => $i, 'rels' => PEAR_Common::getDependencyRelations()));
-                    continue;
-                }
-                if (!empty($d['optional'])) {
-                    if (!in_array($d['optional'], array('yes', 'no'))) {
-                        $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_DEPOPTIONAL,
-                            array('index' => $i, 'opt' => $d['optional']));
-                    }
-                }
-                if ($d['rel'] != 'has' && $d['rel'] != 'not' && empty($d['version'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPVERSION,
-                        array('index' => $i));
-                } elseif (($d['rel'] == 'has' || $d['rel'] == 'not') && !empty($d['version'])) {
-                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_DEPVERSION_IGNORED,
-                        array('index' => $i, 'rel' => $d['rel']));
-                }
-                if ($d['type'] == 'php' && !empty($d['name'])) {
-                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_DEPNAME_IGNORED,
-                        array('index' => $i, 'name' => $d['name']));
-                } elseif ($d['type'] != 'php' && empty($d['name'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPNAME,
-                        array('index' => $i));
-                }
-                if ($d['type'] == 'php' && empty($d['version'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPPHPVERSION,
-                        array('index' => $i));
-                }
-                if (($d['rel'] == 'not') && ($d['type'] == 'php')) {
-                    $this->_validateError(PEAR_PACKAGEFILE_PHP_NO_NOT,
-                        array('index' => $i));
-                }
-                $i++;
-            }
-        }
-        if (!empty($info['configure_options'])) {
-            $i = 1;
-            foreach ($info['configure_options'] as $c) {
-                if (empty($c['name'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_CONFNAME,
-                        array('index' => $i));
-                }
-                if (empty($c['prompt'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_CONFPROMPT,
-                        array('index' => $i));
-                }
-                $i++;
-            }
-        }
-        if (empty($info['filelist'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_FILES);
-            $errors[] = 'no files';
-        } else {
-            foreach ($info['filelist'] as $file => $fa) {
-                if (empty($fa['role'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_FILEROLE,
-                        array('file' => $file, 'roles' => PEAR_Common::getFileRoles()));
-                    continue;
-                } elseif (!in_array($fa['role'], PEAR_Common::getFileRoles())) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILEROLE,
-                        array('file' => $file, 'role' => $fa['role'], 'roles' => PEAR_Common::getFileRoles()));
-                }
-                if (preg_match('~/\.\.?(/|\\z)|^\.\.?/~', str_replace('\\', '/', $file))) {
-                    // file contains .. parent directory or . cur directory references
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME,
-                        array('file' => $file));
-                }
-                if (isset($fa['install-as']) &&
-                      preg_match('~/\.\.?(/|\\z)|^\.\.?/~', 
-                                 str_replace('\\', '/', $fa['install-as']))) {
-                    // install-as contains .. parent directory or . cur directory references
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME,
-                        array('file' => $file . ' [installed as ' . $fa['install-as'] . ']'));
-                }
-                if (isset($fa['baseinstalldir']) &&
-                      preg_match('~/\.\.?(/|\\z)|^\.\.?/~', 
-                                 str_replace('\\', '/', $fa['baseinstalldir']))) {
-                    // install-as contains .. parent directory or . cur directory references
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME,
-                        array('file' => $file . ' [baseinstalldir ' . $fa['baseinstalldir'] . ']'));
-                }
-            }
-        }
-        if (isset($this->_registry) && $this->_isValid) {
-            $chan = $this->_registry->getChannel('pear.php.net');
-            if (PEAR::isError($chan)) {
-                $this->_validateError(PEAR_PACKAGEFILE_ERROR_CHANNELVAL, $chan->getMessage());
-                return $this->_isValid = 0;
-            }
-            $validator = $chan->getValidationObject();
-            $validator->setPackageFile($this);
-            $validator->validate($state);
-            $failures = $validator->getFailures();
-            foreach ($failures['errors'] as $error) {
-                $this->_validateError(PEAR_PACKAGEFILE_ERROR_CHANNELVAL, $error);
-            }
-            foreach ($failures['warnings'] as $warning) {
-                $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_CHANNELVAL, $warning);
-            }
-        }
-        if ($this->_isValid && $state == PEAR_VALIDATE_PACKAGING && !$nofilechecking) {
-            if ($this->_analyzePhpFiles()) {
-                $this->_isValid = true;
-            }
-        }
-        if ($this->_isValid) {
-            return $this->_isValid = $state;
-        }
-        return $this->_isValid = 0;
-    }
-
-    function _analyzePhpFiles()
-    {
-        if (!$this->_isValid) {
-            return false;
-        }
-        if (!isset($this->_packageFile)) {
-            return false;
-        }
-        $dir_prefix = dirname($this->_packageFile);
-        $common = new PEAR_Common;
-        $log = isset($this->_logger) ? array(&$this->_logger, 'log') :
-            array($common, 'log');
-        $info = $this->getFilelist();
-        foreach ($info as $file => $fa) {
-            if (!file_exists($dir_prefix . DIRECTORY_SEPARATOR . $file)) {
-                $this->_validateError(PEAR_PACKAGEFILE_ERROR_FILE_NOTFOUND,
-                    array('file' => realpath($dir_prefix) . DIRECTORY_SEPARATOR . $file));
-                continue;
-            }
-            if ($fa['role'] == 'php' && $dir_prefix) {
-                call_user_func_array($log, array(1, "Analyzing $file"));
-                $srcinfo = $this->_analyzeSourceCode($dir_prefix . DIRECTORY_SEPARATOR . $file);
-                if ($srcinfo) {
-                    $this->_buildProvidesArray($srcinfo);
-                }
-            }
-        }
-        $this->_packageName = $pn = $this->getPackage();
-        $pnl = strlen($pn);
-        if (isset($this->_packageInfo['provides'])) {
-            foreach ((array) $this->_packageInfo['provides'] as $key => $what) {
-                if (isset($what['explicit'])) {
-                    // skip conformance checks if the provides entry is
-                    // specified in the package.xml file
-                    continue;
-                }
-                extract($what);
-                if ($type == 'class') {
-                    if (!strncasecmp($name, $pn, $pnl)) {
-                        continue;
-                    }
-                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX,
-                        array('file' => $file, 'type' => $type, 'name' => $name, 'package' => $pn));
-                } elseif ($type == 'function') {
-                    if (strstr($name, '::') || !strncasecmp($name, $pn, $pnl)) {
-                        continue;
-                    }
-                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX,
-                        array('file' => $file, 'type' => $type, 'name' => $name, 'package' => $pn));
-                }
-            }
-        }
-        return $this->_isValid;
-    }
-
-    /**
-     * Get the default xml generator object
-     *
-     * @return PEAR_PackageFile_Generator_v1
-     */
-    function &getDefaultGenerator()
-    {
-        if (!class_exists('PEAR_PackageFile_Generator_v1')) {
-            require_once 'PEAR/PackageFile/Generator/v1.php';
-        }
-        $a = &new PEAR_PackageFile_Generator_v1($this);
-        return $a;
-    }
-
-    /**
-     * Get the contents of a file listed within the package.xml
-     * @param string
-     * @return string
-     */
-    function getFileContents($file)
-    {
-        if ($this->_archiveFile == $this->_packageFile) { // unpacked
-            $dir = dirname($this->_packageFile);
-            $file = $dir . DIRECTORY_SEPARATOR . $file;
-            $file = str_replace(array('/', '\\'),
-                array(DIRECTORY_SEPARATOR, DIRECTORY_SEPARATOR), $file);
-            if (file_exists($file) && is_readable($file)) {
-                return implode('', file($file));
-            }
-        } else { // tgz
-            if (!class_exists('Archive_Tar')) {
-                require_once 'Archive/Tar.php';
-            }
-            $tar = &new Archive_Tar($this->_archiveFile);
-            $tar->pushErrorHandling(PEAR_ERROR_RETURN);
-            if ($file != 'package.xml' && $file != 'package2.xml') {
-                $file = $this->getPackage() . '-' . $this->getVersion() . '/' . $file;
-            }
-            $file = $tar->extractInString($file);
-            $tar->popErrorHandling();
-            if (PEAR::isError($file)) {
-                return PEAR::raiseError("Cannot locate file '$file' in archive");
-            }
-            return $file;
-        }
-    }
-
-    // {{{ analyzeSourceCode()
-    /**
-     * Analyze the source code of the given PHP file
-     *
-     * @param  string Filename of the PHP file
-     * @return mixed
-     * @access private
-     */
-    function _analyzeSourceCode($file)
-    {
-        if (!function_exists("token_get_all")) {
-            return false;
-        }
-        if (!defined('T_DOC_COMMENT')) {
-            define('T_DOC_COMMENT', T_COMMENT);
-        }
-        if (!defined('T_INTERFACE')) {
-            define('T_INTERFACE', -1);
-        }
-        if (!defined('T_IMPLEMENTS')) {
-            define('T_IMPLEMENTS', -1);
-        }
-        if (!$fp = @fopen($file, "r")) {
-            return false;
-        }
-        fclose($fp);
-        $contents = file_get_contents($file);
-        $tokens = token_get_all($contents);
-/*
-        for ($i = 0; $i < sizeof($tokens); $i++) {
-            @list($token, $data) = $tokens[$i];
-            if (is_string($token)) {
-                var_dump($token);
-            } else {
-                print token_name($token) . ' ';
-                var_dump(rtrim($data));
-            }
-        }
-*/
-        $look_for = 0;
-        $paren_level = 0;
-        $bracket_level = 0;
-        $brace_level = 0;
-        $lastphpdoc = '';
-        $current_class = '';
-        $current_interface = '';
-        $current_class_level = -1;
-        $current_function = '';
-        $current_function_level = -1;
-        $declared_classes = array();
-        $declared_interfaces = array();
-        $declared_functions = array();
-        $declared_methods = array();
-        $used_classes = array();
-        $used_functions = array();
-        $extends = array();
-        $implements = array();
-        $nodeps = array();
-        $inquote = false;
-        $interface = false;
-        for ($i = 0; $i < sizeof($tokens); $i++) {
-            if (is_array($tokens[$i])) {
-                list($token, $data) = $tokens[$i];
-            } else {
-                $token = $tokens[$i];
-                $data = '';
-            }
-            if ($inquote) {
-                if ($token != '"' && $token != T_END_HEREDOC) {
-                    continue;
-                } else {
-                    $inquote = false;
-                    continue;
-                }
-            }
-            switch ($token) {
-                case T_WHITESPACE :
-                    continue;
-                case ';':
-                    if ($interface) {
-                        $current_function = '';
-                        $current_function_level = -1;
-                    }
-                    break;
-                case '"':
-                case T_START_HEREDOC:
-                    $inquote = true;
-                    break;
-                case T_CURLY_OPEN:
-                case T_DOLLAR_OPEN_CURLY_BRACES:
-                case '{': $brace_level++; continue 2;
-                case '}':
-                    $brace_level--;
-                    if ($current_class_level == $brace_level) {
-                        $current_class = '';
-                        $current_class_level = -1;
-                    }
-                    if ($current_function_level == $brace_level) {
-                        $current_function = '';
-                        $current_function_level = -1;
-                    }
-                    continue 2;
-                case '[': $bracket_level++; continue 2;
-                case ']': $bracket_level--; continue 2;
-                case '(': $paren_level++;   continue 2;
-                case ')': $paren_level--;   continue 2;
-                case T_INTERFACE:
-                    $interface = true;
-                case T_CLASS:
-                    if (($current_class_level != -1) || ($current_function_level != -1)) {
-                        $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE,
-                            array('file' => $file));
-                        return false;
-                    }
-                case T_FUNCTION:
-                case T_NEW:
-                case T_EXTENDS:
-                case T_IMPLEMENTS:
-                    $look_for = $token;
-                    continue 2;
-                case T_STRING:
-                    if (version_compare(zend_version(), '2.0', '<')) {
-                        if (in_array(strtolower($data),
-                            array('public', 'private', 'protected', 'abstract',
-                                  'interface', 'implements', 'throw') 
-                                 )) {
-                            $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_PHP5,
-                                array($file));
-                        }
-                    }
-                    if ($look_for == T_CLASS) {
-                        $current_class = $data;
-                        $current_class_level = $brace_level;
-                        $declared_classes[] = $current_class;
-                    } elseif ($look_for == T_INTERFACE) {
-                        $current_interface = $data;
-                        $current_class_level = $brace_level;
-                        $declared_interfaces[] = $current_interface;
-                    } elseif ($look_for == T_IMPLEMENTS) {
-                        $implements[$current_class] = $data;
-                    } elseif ($look_for == T_EXTENDS) {
-                        $extends[$current_class] = $data;
-                    } elseif ($look_for == T_FUNCTION) {
-                        if ($current_class) {
-                            $current_function = "$current_class::$data";
-                            $declared_methods[$current_class][] = $data;
-                        } elseif ($current_interface) {
-                            $current_function = "$current_interface::$data";
-                            $declared_methods[$current_interface][] = $data;
-                        } else {
-                            $current_function = $data;
-                            $declared_functions[] = $current_function;
-                        }
-                        $current_function_level = $brace_level;
-                        $m = array();
-                    } elseif ($look_for == T_NEW) {
-                        $used_classes[$data] = true;
-                    }
-                    $look_for = 0;
-                    continue 2;
-                case T_VARIABLE:
-                    $look_for = 0;
-                    continue 2;
-                case T_DOC_COMMENT:
-                case T_COMMENT:
-                    if (preg_match('!^/\*\*\s!', $data)) {
-                        $lastphpdoc = $data;
-                        if (preg_match_all('/@nodep\s+(\S+)/', $lastphpdoc, $m)) {
-                            $nodeps = array_merge($nodeps, $m[1]);
-                        }
-                    }
-                    continue 2;
-                case T_DOUBLE_COLON:
-                    if (!($tokens[$i - 1][0] == T_WHITESPACE || $tokens[$i - 1][0] == T_STRING)) {
-                        $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE,
-                            array('file' => $file));
-                        return false;
-                    }
-                    $class = $tokens[$i - 1][1];
-                    if (strtolower($class) != 'parent') {
-                        $used_classes[$class] = true;
-                    }
-                    continue 2;
-            }
-        }
-        return array(
-            "source_file" => $file,
-            "declared_classes" => $declared_classes,
-            "declared_interfaces" => $declared_interfaces,
-            "declared_methods" => $declared_methods,
-            "declared_functions" => $declared_functions,
-            "used_classes" => array_diff(array_keys($used_classes), $nodeps),
-            "inheritance" => $extends,
-            "implements" => $implements,
-            );
-    }
-
-    /**
-     * Build a "provides" array from data returned by
-     * analyzeSourceCode().  The format of the built array is like
-     * this:
-     *
-     *  array(
-     *    'class;MyClass' => 'array('type' => 'class', 'name' => 'MyClass'),
-     *    ...
-     *  )
-     *
-     *
-     * @param array $srcinfo array with information about a source file
-     * as returned by the analyzeSourceCode() method.
-     *
-     * @return void
-     *
-     * @access private
-     *
-     */
-    function _buildProvidesArray($srcinfo)
-    {
-        if (!$this->_isValid) {
-            return false;
-        }
-        $file = basename($srcinfo['source_file']);
-        $pn = $this->getPackage();
-        $pnl = strlen($pn);
-        foreach ($srcinfo['declared_classes'] as $class) {
-            $key = "class;$class";
-            if (isset($this->_packageInfo['provides'][$key])) {
-                continue;
-            }
-            $this->_packageInfo['provides'][$key] =
-                array('file'=> $file, 'type' => 'class', 'name' => $class);
-            if (isset($srcinfo['inheritance'][$class])) {
-                $this->_packageInfo['provides'][$key]['extends'] =
-                    $srcinfo['inheritance'][$class];
-            }
-        }
-        foreach ($srcinfo['declared_methods'] as $class => $methods) {
-            foreach ($methods as $method) {
-                $function = "$class::$method";
-                $key = "function;$function";
-                if ($method{0} == '_' || !strcasecmp($method, $class) ||
-                    isset($this->_packageInfo['provides'][$key])) {
-                    continue;
-                }
-                $this->_packageInfo['provides'][$key] =
-                    array('file'=> $file, 'type' => 'function', 'name' => $function);
-            }
-        }
-
-        foreach ($srcinfo['declared_functions'] as $function) {
-            $key = "function;$function";
-            if ($function{0} == '_' || isset($this->_packageInfo['provides'][$key])) {
-                continue;
-            }
-            if (!strstr($function, '::') && strncasecmp($function, $pn, $pnl)) {
-                $warnings[] = "in1 " . $file . ": function \"$function\" not prefixed with package name \"$pn\"";
-            }
-            $this->_packageInfo['provides'][$key] =
-                array('file'=> $file, 'type' => 'function', 'name' => $function);
-        }
-    }
-
-    // }}}
-}
-?>
-                                                                                                                                                                                                                                                                                                                                                                                                                                                                 PEAR-1.8.0/PEAR/PackageFile/v2.php                                                                  100664     764     764       207602      100664  11276                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               PEAR-1.9.0/PEAR/PackageFile/v1.php                                                                  100664     764     764       143760      100664  11302                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_PackageFile_v1, package.xml version 1.0
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: v1.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+/**
+ * For error handling
+ */
+require_once 'PEAR/ErrorStack.php';
+
+/**
+ * Error code if parsing is attempted with no xml extension
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_XML_EXT', 3);
+
+/**
+ * Error code if creating the xml parser resource fails
+ */
+define('PEAR_PACKAGEFILE_ERROR_CANT_MAKE_PARSER', 4);
+
+/**
+ * Error code used for all sax xml parsing errors
+ */
+define('PEAR_PACKAGEFILE_ERROR_PARSER_ERROR', 5);
+
+/**
+ * Error code used when there is no name
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_NAME', 6);
+
+/**
+ * Error code when a package name is not valid
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_NAME', 7);
+
+/**
+ * Error code used when no summary is parsed
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_SUMMARY', 8);
+
+/**
+ * Error code for summaries that are more than 1 line
+ */
+define('PEAR_PACKAGEFILE_ERROR_MULTILINE_SUMMARY', 9);
+
+/**
+ * Error code used when no description is present
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_DESCRIPTION', 10);
+
+/**
+ * Error code used when no license is present
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_LICENSE', 11);
+
+/**
+ * Error code used when a <version> version number is not present
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_VERSION', 12);
+
+/**
+ * Error code used when a <version> version number is invalid
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_VERSION', 13);
+
+/**
+ * Error code when release state is missing
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_STATE', 14);
+
+/**
+ * Error code when release state is invalid
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_STATE', 15);
+
+/**
+ * Error code when release state is missing
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_DATE', 16);
+
+/**
+ * Error code when release state is invalid
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_DATE', 17);
+
+/**
+ * Error code when no release notes are found
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_NOTES', 18);
+
+/**
+ * Error code when no maintainers are found
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_MAINTAINERS', 19);
+
+/**
+ * Error code when a maintainer has no handle
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_MAINTHANDLE', 20);
+
+/**
+ * Error code when a maintainer has no handle
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_MAINTROLE', 21);
+
+/**
+ * Error code when a maintainer has no name
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_MAINTNAME', 22);
+
+/**
+ * Error code when a maintainer has no email
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_MAINTEMAIL', 23);
+
+/**
+ * Error code when a maintainer has no handle
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_MAINTROLE', 24);
+
+/**
+ * Error code when a dependency is not a PHP dependency, but has no name
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_DEPNAME', 25);
+
+/**
+ * Error code when a dependency has no type (pkg, php, etc.)
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_DEPTYPE', 26);
+
+/**
+ * Error code when a dependency has no relation (lt, ge, has, etc.)
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_DEPREL', 27);
+
+/**
+ * Error code when a dependency is not a 'has' relation, but has no version
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_DEPVERSION', 28);
+
+/**
+ * Error code when a dependency has an invalid relation
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPREL', 29);
+
+/**
+ * Error code when a dependency has an invalid type
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPTYPE', 30);
+
+/**
+ * Error code when a dependency has an invalid optional option
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPOPTIONAL', 31);
+
+/**
+ * Error code when a dependency is a pkg dependency, and has an invalid package name
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPNAME', 32);
+
+/**
+ * Error code when a dependency has a channel="foo" attribute, and foo is not a registered channel
+ */
+define('PEAR_PACKAGEFILE_ERROR_UNKNOWN_DEPCHANNEL', 33);
+
+/**
+ * Error code when rel="has" and version attribute is present.
+ */
+define('PEAR_PACKAGEFILE_ERROR_DEPVERSION_IGNORED', 34);
+
+/**
+ * Error code when type="php" and dependency name is present
+ */
+define('PEAR_PACKAGEFILE_ERROR_DEPNAME_IGNORED', 35);
+
+/**
+ * Error code when a configure option has no name
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_CONFNAME', 36);
+
+/**
+ * Error code when a configure option has no name
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_CONFPROMPT', 37);
+
+/**
+ * Error code when a file in the filelist has an invalid role
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_FILEROLE', 38);
+
+/**
+ * Error code when a file in the filelist has no role
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_FILEROLE', 39);
+
+/**
+ * Error code when analyzing a php source file that has parse errors
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE', 40);
+
+/**
+ * Error code when analyzing a php source file reveals a source element
+ * without a package name prefix
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX', 41);
+
+/**
+ * Error code when an unknown channel is specified
+ */
+define('PEAR_PACKAGEFILE_ERROR_UNKNOWN_CHANNEL', 42);
+
+/**
+ * Error code when no files are found in the filelist
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_FILES', 43);
+
+/**
+ * Error code when a file is not valid php according to _analyzeSourceCode()
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_FILE', 44);
+
+/**
+ * Error code when the channel validator returns an error or warning
+ */
+define('PEAR_PACKAGEFILE_ERROR_CHANNELVAL', 45);
+
+/**
+ * Error code when a php5 package is packaged in php4 (analysis doesn't work)
+ */
+define('PEAR_PACKAGEFILE_ERROR_PHP5', 46);
+
+/**
+ * Error code when a file is listed in package.xml but does not exist
+ */
+define('PEAR_PACKAGEFILE_ERROR_FILE_NOTFOUND', 47);
+
+/**
+ * Error code when a <dep type="php" rel="not"... is encountered (use rel="ne")
+ */
+define('PEAR_PACKAGEFILE_PHP_NO_NOT', 48);
+
+/**
+ * Error code when a package.xml contains non-ISO-8859-1 characters
+ */
+define('PEAR_PACKAGEFILE_ERROR_NON_ISO_CHARS', 49);
+
+/**
+ * Error code when a dependency is not a 'has' relation, but has no version
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_DEPPHPVERSION', 50);
+
+/**
+ * Error code when a package has no lead developer
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_LEAD', 51);
+
+/**
+ * Error code when a filename begins with "."
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME', 52);
+/**
+ * package.xml encapsulator
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_PackageFile_v1
+{
+    /**
+     * @access private
+     * @var PEAR_ErrorStack
+     * @access private
+     */
+    var $_stack;
+
+    /**
+     * A registry object, used to access the package name validation regex for non-standard channels
+     * @var PEAR_Registry
+     * @access private
+     */
+    var $_registry;
+
+    /**
+     * An object that contains a log method that matches PEAR_Common::log's signature
+     * @var object
+     * @access private
+     */
+    var $_logger;
+
+    /**
+     * Parsed package information
+     * @var array
+     * @access private
+     */
+    var $_packageInfo;
+
+    /**
+     * path to package.xml
+     * @var string
+     * @access private
+     */
+    var $_packageFile;
+
+    /**
+     * path to package .tgz or false if this is a local/extracted package.xml
+     * @var string
+     * @access private
+     */
+    var $_archiveFile;
+
+    /**
+     * @var int
+     * @access private
+     */
+    var $_isValid = 0;
+
+    /**
+     * Determines whether this packagefile was initialized only with partial package info
+     *
+     * If this package file was constructed via parsing REST, it will only contain
+     *
+     * - package name
+     * - channel name
+     * - dependencies 
+     * @var boolean
+     * @access private
+     */
+    var $_incomplete = true;
+
+    /**
+     * @param bool determines whether to return a PEAR_Error object, or use the PEAR_ErrorStack
+     * @param string Name of Error Stack class to use.
+     */
+    function PEAR_PackageFile_v1()
+    {
+        $this->_stack = &new PEAR_ErrorStack('PEAR_PackageFile_v1');
+        $this->_stack->setErrorMessageTemplate($this->_getErrorMessage());
+        $this->_isValid = 0;
+    }
+
+    function installBinary($installer)
+    {
+        return false;
+    }
+
+    function isExtension($name)
+    {
+        return false;
+    }
+
+    function setConfig(&$config)
+    {
+        $this->_config = &$config;
+        $this->_registry = &$config->getRegistry();
+    }
+
+    function setRequestedGroup()
+    {
+        // placeholder
+    }
+
+    /**
+     * For saving in the registry.
+     *
+     * Set the last version that was installed
+     * @param string
+     */
+    function setLastInstalledVersion($version)
+    {
+        $this->_packageInfo['_lastversion'] = $version;
+    }
+
+    /**
+     * @return string|false
+     */
+    function getLastInstalledVersion()
+    {
+        if (isset($this->_packageInfo['_lastversion'])) {
+            return $this->_packageInfo['_lastversion'];
+        }
+        return false;
+    }
+
+    function getInstalledBinary()
+    {
+        return false;
+    }
+
+    function listPostinstallScripts()
+    {
+        return false;
+    }
+
+    function initPostinstallScripts()
+    {
+        return false;
+    }
+
+    function setLogger(&$logger)
+    {
+        if ($logger && (!is_object($logger) || !method_exists($logger, 'log'))) {
+            return PEAR::raiseError('Logger must be compatible with PEAR_Common::log');
+        }
+        $this->_logger = &$logger;
+    }
+
+    function setPackagefile($file, $archive = false)
+    {
+        $this->_packageFile = $file;
+        $this->_archiveFile = $archive ? $archive : $file;
+    }
+
+    function getPackageFile()
+    {
+        return isset($this->_packageFile) ? $this->_packageFile : false;
+    }
+
+    function getPackageType()
+    {
+        return 'php';
+    }
+
+    function getArchiveFile()
+    {
+        return $this->_archiveFile;
+    }
+
+    function packageInfo($field)
+    {
+        if (!is_string($field) || empty($field) ||
+            !isset($this->_packageInfo[$field])) {
+            return false;
+        }
+        return $this->_packageInfo[$field];
+    }
+
+    function setDirtree($path)
+    {
+        if (!isset($this->_packageInfo['dirtree'])) {
+            $this->_packageInfo['dirtree'] = array();
+        }
+        $this->_packageInfo['dirtree'][$path] = true;
+    }
+
+    function getDirtree()
+    {
+        if (isset($this->_packageInfo['dirtree']) && count($this->_packageInfo['dirtree'])) {
+            return $this->_packageInfo['dirtree'];
+        }
+        return false;
+    }
+
+    function resetDirtree()
+    {
+        unset($this->_packageInfo['dirtree']);
+    }
+
+    function fromArray($pinfo)
+    {
+        $this->_incomplete = false;
+        $this->_packageInfo = $pinfo;
+    }
+
+    function isIncomplete()
+    {
+        return $this->_incomplete;
+    }
+
+    function getChannel()
+    {
+        return 'pear.php.net';
+    }
+
+    function getUri()
+    {
+        return false;
+    }
+
+    function getTime()
+    {
+        return false;
+    }
+
+    function getExtends()
+    {
+        if (isset($this->_packageInfo['extends'])) {
+            return $this->_packageInfo['extends'];
+        }
+        return false;
+    }
+
+    /**
+     * @return array
+     */
+    function toArray()
+    {
+        if (!$this->validate(PEAR_VALIDATE_NORMAL)) {
+            return false;
+        }
+        return $this->getArray();
+    }
+
+    function getArray()
+    {
+        return $this->_packageInfo;
+    }
+
+    function getName()
+    {
+        return $this->getPackage();
+    }
+
+    function getPackage()
+    {
+        if (isset($this->_packageInfo['package'])) {
+            return $this->_packageInfo['package'];
+        }
+        return false;
+    }
+
+    /**
+     * WARNING - don't use this unless you know what you are doing
+     */
+    function setRawPackage($package)
+    {
+        $this->_packageInfo['package'] = $package;
+    }
+
+    function setPackage($package)
+    {
+        $this->_packageInfo['package'] = $package;
+        $this->_isValid = false;
+    }
+
+    function getVersion()
+    {
+        if (isset($this->_packageInfo['version'])) {
+            return $this->_packageInfo['version'];
+        }
+        return false;
+    }
+
+    function setVersion($version)
+    {
+        $this->_packageInfo['version'] = $version;
+        $this->_isValid = false;
+    }
+
+    function clearMaintainers()
+    {
+        unset($this->_packageInfo['maintainers']);
+    }
+
+    function getMaintainers()
+    {
+        if (isset($this->_packageInfo['maintainers'])) {
+            return $this->_packageInfo['maintainers'];
+        }
+        return false;
+    }
+
+    /**
+     * Adds a new maintainer - no checking of duplicates is performed, use
+     * updatemaintainer for that purpose.
+     */
+    function addMaintainer($role, $handle, $name, $email)
+    {
+        $this->_packageInfo['maintainers'][] =
+            array('handle' => $handle, 'role' => $role, 'email' => $email, 'name' => $name);
+        $this->_isValid = false;
+    }
+
+    function updateMaintainer($role, $handle, $name, $email)
+    {
+        $found = false;
+        if (!isset($this->_packageInfo['maintainers']) ||
+              !is_array($this->_packageInfo['maintainers'])) {
+            return $this->addMaintainer($role, $handle, $name, $email);
+        }
+        foreach ($this->_packageInfo['maintainers'] as $i => $maintainer) {
+            if ($maintainer['handle'] == $handle) {
+                $found = $i;
+                break;
+            }
+        }
+        if ($found !== false) {
+            unset($this->_packageInfo['maintainers'][$found]);
+            $this->_packageInfo['maintainers'] =
+                array_values($this->_packageInfo['maintainers']);
+        }
+        $this->addMaintainer($role, $handle, $name, $email);
+    }
+
+    function deleteMaintainer($handle)
+    {
+        $found = false;
+        foreach ($this->_packageInfo['maintainers'] as $i => $maintainer) {
+            if ($maintainer['handle'] == $handle) {
+                $found = $i;
+                break;
+            }
+        }
+        if ($found !== false) {
+            unset($this->_packageInfo['maintainers'][$found]);
+            $this->_packageInfo['maintainers'] =
+                array_values($this->_packageInfo['maintainers']);
+            return true;
+        }
+        return false;
+    }
+
+    function getState()
+    {
+        if (isset($this->_packageInfo['release_state'])) {
+            return $this->_packageInfo['release_state'];
+        }
+        return false;
+    }
+
+    function setRawState($state)
+    {
+        $this->_packageInfo['release_state'] = $state;
+    }
+
+    function setState($state)
+    {
+        $this->_packageInfo['release_state'] = $state;
+        $this->_isValid = false;
+    }
+
+    function getDate()
+    {
+        if (isset($this->_packageInfo['release_date'])) {
+            return $this->_packageInfo['release_date'];
+        }
+        return false;
+    }
+
+    function setDate($date)
+    {
+        $this->_packageInfo['release_date'] = $date;
+        $this->_isValid = false;
+    }
+
+    function getLicense()
+    {
+        if (isset($this->_packageInfo['release_license'])) {
+            return $this->_packageInfo['release_license'];
+        }
+        return false;
+    }
+
+    function setLicense($date)
+    {
+        $this->_packageInfo['release_license'] = $date;
+        $this->_isValid = false;
+    }
+
+    function getSummary()
+    {
+        if (isset($this->_packageInfo['summary'])) {
+            return $this->_packageInfo['summary'];
+        }
+        return false;
+    }
+
+    function setSummary($summary)
+    {
+        $this->_packageInfo['summary'] = $summary;
+        $this->_isValid = false;
+    }
+
+    function getDescription()
+    {
+        if (isset($this->_packageInfo['description'])) {
+            return $this->_packageInfo['description'];
+        }
+        return false;
+    }
+
+    function setDescription($desc)
+    {
+        $this->_packageInfo['description'] = $desc;
+        $this->_isValid = false;
+    }
+
+    function getNotes()
+    {
+        if (isset($this->_packageInfo['release_notes'])) {
+            return $this->_packageInfo['release_notes'];
+        }
+        return false;
+    }
+
+    function setNotes($notes)
+    {
+        $this->_packageInfo['release_notes'] = $notes;
+        $this->_isValid = false;
+    }
+
+    function getDeps()
+    {
+        if (isset($this->_packageInfo['release_deps'])) {
+            return $this->_packageInfo['release_deps'];
+        }
+        return false;
+    }
+
+    /**
+     * Reset dependencies prior to adding new ones
+     */
+    function clearDeps()
+    {
+        unset($this->_packageInfo['release_deps']);
+    }
+
+    function addPhpDep($version, $rel)
+    {
+        $this->_isValid = false;
+        $this->_packageInfo['release_deps'][] =
+            array('type' => 'php',
+                  'rel' => $rel,
+                  'version' => $version);
+    }
+
+    function addPackageDep($name, $version, $rel, $optional = 'no')
+    {
+        $this->_isValid = false;
+        $dep =
+            array('type' => 'pkg',
+                  'name' => $name,
+                  'rel' => $rel,
+                  'optional' => $optional);
+        if ($rel != 'has' && $rel != 'not') {
+            $dep['version'] = $version;
+        }
+        $this->_packageInfo['release_deps'][] = $dep;
+    }
+
+    function addExtensionDep($name, $version, $rel, $optional = 'no')
+    {
+        $this->_isValid = false;
+        $this->_packageInfo['release_deps'][] =
+            array('type' => 'ext',
+                  'name' => $name,
+                  'rel' => $rel,
+                  'version' => $version,
+                  'optional' => $optional);
+    }
+
+    /**
+     * WARNING - do not use this function directly unless you know what you're doing
+     */
+    function setDeps($deps)
+    {
+        $this->_packageInfo['release_deps'] = $deps;
+    }
+
+    function hasDeps()
+    {
+        return isset($this->_packageInfo['release_deps']) &&
+            count($this->_packageInfo['release_deps']);
+    }
+
+    function getDependencyGroup($group)
+    {
+        return false;
+    }
+
+    function isCompatible($pf)
+    {
+        return false;
+    }
+
+    function isSubpackageOf($p)
+    {
+        return $p->isSubpackage($this);
+    }
+
+    function isSubpackage($p)
+    {
+        return false;
+    }
+
+    function dependsOn($package, $channel)
+    {
+        if (strtolower($channel) != 'pear.php.net') {
+            return false;
+        }
+        if (!($deps = $this->getDeps())) {
+            return false;
+        }
+        foreach ($deps as $dep) {
+            if ($dep['type'] != 'pkg') {
+                continue;
+            }
+            if (strtolower($dep['name']) == strtolower($package)) {
+                return true;
+            }
+        }
+        return false;
+    }
+
+    function getConfigureOptions()
+    {
+        if (isset($this->_packageInfo['configure_options'])) {
+            return $this->_packageInfo['configure_options'];
+        }
+        return false;
+    }
+
+    function hasConfigureOptions()
+    {
+        return isset($this->_packageInfo['configure_options']) &&
+            count($this->_packageInfo['configure_options']);
+    }
+
+    function addConfigureOption($name, $prompt, $default = false)
+    {
+        $o = array('name' => $name, 'prompt' => $prompt);
+        if ($default !== false) {
+            $o['default'] = $default;
+        }
+        if (!isset($this->_packageInfo['configure_options'])) {
+            $this->_packageInfo['configure_options'] = array();
+        }
+        $this->_packageInfo['configure_options'][] = $o;
+    }
+
+    function clearConfigureOptions()
+    {
+        unset($this->_packageInfo['configure_options']);
+    }
+
+    function getProvides()
+    {
+        if (isset($this->_packageInfo['provides'])) {
+            return $this->_packageInfo['provides'];
+        }
+        return false;
+    }
+
+    function getProvidesExtension()
+    {
+        return false;
+    }
+
+    function addFile($dir, $file, $attrs)
+    {
+        $dir = preg_replace(array('!\\\\+!', '!/+!'), array('/', '/'), $dir);
+        if ($dir == '/' || $dir == '') {
+            $dir = '';
+        } else {
+            $dir .= '/';
+        }
+        $file = $dir . $file;
+        $file = preg_replace('![\\/]+!', '/', $file);
+        $this->_packageInfo['filelist'][$file] = $attrs;
+    }
+
+    function getInstallationFilelist()
+    {
+        return $this->getFilelist();
+    }
+
+    function getFilelist()
+    {
+        if (isset($this->_packageInfo['filelist'])) {
+            return $this->_packageInfo['filelist'];
+        }
+        return false;
+    }
+
+    function setFileAttribute($file, $attr, $value)
+    {
+        $this->_packageInfo['filelist'][$file][$attr] = $value;
+    }
+
+    function resetFilelist()
+    {
+        $this->_packageInfo['filelist'] = array();
+    }
+
+    function setInstalledAs($file, $path)
+    {
+        if ($path) {
+            return $this->_packageInfo['filelist'][$file]['installed_as'] = $path;
+        }
+        unset($this->_packageInfo['filelist'][$file]['installed_as']);
+    }
+
+    function installedFile($file, $atts)
+    {
+        if (isset($this->_packageInfo['filelist'][$file])) {
+            $this->_packageInfo['filelist'][$file] =
+                array_merge($this->_packageInfo['filelist'][$file], $atts);
+        } else {
+            $this->_packageInfo['filelist'][$file] = $atts;
+        }
+    }
+
+    function getChangelog()
+    {
+        if (isset($this->_packageInfo['changelog'])) {
+            return $this->_packageInfo['changelog'];
+        }
+        return false;
+    }
+
+    function getPackagexmlVersion()
+    {
+        return '1.0';
+    }
+
+    /**
+     * Wrapper to {@link PEAR_ErrorStack::getErrors()}
+     * @param boolean determines whether to purge the error stack after retrieving
+     * @return array
+     */
+    function getValidationWarnings($purge = true)
+    {
+        return $this->_stack->getErrors($purge);
+    }
+
+    // }}}
+    /**
+     * Validation error.  Also marks the object contents as invalid
+     * @param error code
+     * @param array error information
+     * @access private
+     */
+    function _validateError($code, $params = array())
+    {
+        $this->_stack->push($code, 'error', $params, false, false, debug_backtrace());
+        $this->_isValid = false;
+    }
+
+    /**
+     * Validation warning.  Does not mark the object contents invalid.
+     * @param error code
+     * @param array error information
+     * @access private
+     */
+    function _validateWarning($code, $params = array())
+    {
+        $this->_stack->push($code, 'warning', $params, false, false, debug_backtrace());
+    }
+
+    /**
+     * @param integer error code
+     * @access protected
+     */
+    function _getErrorMessage()
+    {
+        return array(
+                PEAR_PACKAGEFILE_ERROR_NO_NAME =>
+                    'Missing Package Name',
+                PEAR_PACKAGEFILE_ERROR_NO_SUMMARY =>
+                    'No summary found',
+                PEAR_PACKAGEFILE_ERROR_MULTILINE_SUMMARY =>
+                    'Summary should be on one line',
+                PEAR_PACKAGEFILE_ERROR_NO_DESCRIPTION =>
+                    'Missing description',
+                PEAR_PACKAGEFILE_ERROR_NO_LICENSE =>
+                    'Missing license',
+                PEAR_PACKAGEFILE_ERROR_NO_VERSION =>
+                    'No release version found',
+                PEAR_PACKAGEFILE_ERROR_NO_STATE =>
+                    'No release state found',
+                PEAR_PACKAGEFILE_ERROR_NO_DATE =>
+                    'No release date found',
+                PEAR_PACKAGEFILE_ERROR_NO_NOTES =>
+                    'No release notes found',
+                PEAR_PACKAGEFILE_ERROR_NO_LEAD =>
+                    'Package must have at least one lead maintainer',
+                PEAR_PACKAGEFILE_ERROR_NO_MAINTAINERS =>
+                    'No maintainers found, at least one must be defined',
+                PEAR_PACKAGEFILE_ERROR_NO_MAINTHANDLE =>
+                    'Maintainer %index% has no handle (user ID at channel server)',
+                PEAR_PACKAGEFILE_ERROR_NO_MAINTROLE =>
+                    'Maintainer %index% has no role',
+                PEAR_PACKAGEFILE_ERROR_NO_MAINTNAME =>
+                    'Maintainer %index% has no name',
+                PEAR_PACKAGEFILE_ERROR_NO_MAINTEMAIL =>
+                    'Maintainer %index% has no email',
+                PEAR_PACKAGEFILE_ERROR_NO_DEPNAME =>
+                    'Dependency %index% is not a php dependency, and has no name',
+                PEAR_PACKAGEFILE_ERROR_NO_DEPREL =>
+                    'Dependency %index% has no relation (rel)',
+                PEAR_PACKAGEFILE_ERROR_NO_DEPTYPE =>
+                    'Dependency %index% has no type',
+                PEAR_PACKAGEFILE_ERROR_DEPNAME_IGNORED =>
+                    'PHP Dependency %index% has a name attribute of "%name%" which will be' .
+                        ' ignored!',
+                PEAR_PACKAGEFILE_ERROR_NO_DEPVERSION =>
+                    'Dependency %index% is not a rel="has" or rel="not" dependency, ' .
+                        'and has no version',
+                PEAR_PACKAGEFILE_ERROR_NO_DEPPHPVERSION =>
+                    'Dependency %index% is a type="php" dependency, ' .
+                        'and has no version',
+                PEAR_PACKAGEFILE_ERROR_DEPVERSION_IGNORED =>
+                    'Dependency %index% is a rel="%rel%" dependency, versioning is ignored',
+                PEAR_PACKAGEFILE_ERROR_INVALID_DEPOPTIONAL =>
+                    'Dependency %index% has invalid optional value "%opt%", should be yes or no',
+                PEAR_PACKAGEFILE_PHP_NO_NOT =>
+                    'Dependency %index%: php dependencies cannot use "not" rel, use "ne"' .
+                        ' to exclude specific versions',
+                PEAR_PACKAGEFILE_ERROR_NO_CONFNAME =>
+                    'Configure Option %index% has no name',
+                PEAR_PACKAGEFILE_ERROR_NO_CONFPROMPT =>
+                    'Configure Option %index% has no prompt',
+                PEAR_PACKAGEFILE_ERROR_NO_FILES =>
+                    'No files in <filelist> section of package.xml',
+                PEAR_PACKAGEFILE_ERROR_NO_FILEROLE =>
+                    'File "%file%" has no role, expecting one of "%roles%"',
+                PEAR_PACKAGEFILE_ERROR_INVALID_FILEROLE =>
+                    'File "%file%" has invalid role "%role%", expecting one of "%roles%"',
+                PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME =>
+                    'File "%file%" cannot start with ".", cannot package or install',
+                PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE =>
+                    'Parser error: invalid PHP found in file "%file%"',
+                PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX =>
+                    'in %file%: %type% "%name%" not prefixed with package name "%package%"',
+                PEAR_PACKAGEFILE_ERROR_INVALID_FILE =>
+                    'Parser error: invalid PHP file "%file%"',
+                PEAR_PACKAGEFILE_ERROR_CHANNELVAL =>
+                    'Channel validator error: field "%field%" - %reason%',
+                PEAR_PACKAGEFILE_ERROR_PHP5 =>
+                    'Error, PHP5 token encountered in %file%, analysis should be in PHP5',
+                PEAR_PACKAGEFILE_ERROR_FILE_NOTFOUND =>
+                    'File "%file%" in package.xml does not exist',
+                PEAR_PACKAGEFILE_ERROR_NON_ISO_CHARS =>
+                    'Package.xml contains non-ISO-8859-1 characters, and may not validate',
+            );
+    }
+
+    /**
+     * Validate XML package definition file.
+     *
+     * @access public
+     * @return boolean
+     */
+    function validate($state = PEAR_VALIDATE_NORMAL, $nofilechecking = false)
+    {
+        if (($this->_isValid & $state) == $state) {
+            return true;
+        }
+        $this->_isValid = true;
+        $info = $this->_packageInfo;
+        if (empty($info['package'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_NAME);
+            $this->_packageName = $pn = 'unknown';
+        } else {
+            $this->_packageName = $pn = $info['package'];
+        }
+
+        if (empty($info['summary'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_SUMMARY);
+        } elseif (strpos(trim($info['summary']), "\n") !== false) {
+            $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_MULTILINE_SUMMARY,
+                array('summary' => $info['summary']));
+        }
+        if (empty($info['description'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DESCRIPTION);
+        }
+        if (empty($info['release_license'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_LICENSE);
+        }
+        if (empty($info['version'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_VERSION);
+        }
+        if (empty($info['release_state'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_STATE);
+        }
+        if (empty($info['release_date'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DATE);
+        }
+        if (empty($info['release_notes'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_NOTES);
+        }
+        if (empty($info['maintainers'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTAINERS);
+        } else {
+            $haslead = false;
+            $i = 1;
+            foreach ($info['maintainers'] as $m) {
+                if (empty($m['handle'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTHANDLE,
+                        array('index' => $i));
+                }
+                if (empty($m['role'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTROLE,
+                        array('index' => $i, 'roles' => PEAR_Common::getUserRoles()));
+                } elseif ($m['role'] == 'lead') {
+                    $haslead = true;
+                }
+                if (empty($m['name'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTNAME,
+                        array('index' => $i));
+                }
+                if (empty($m['email'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTEMAIL,
+                        array('index' => $i));
+                }
+                $i++;
+            }
+            if (!$haslead) {
+                $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_LEAD);
+            }
+        }
+        if (!empty($info['release_deps'])) {
+            $i = 1;
+            foreach ($info['release_deps'] as $d) {
+                if (!isset($d['type']) || empty($d['type'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPTYPE,
+                        array('index' => $i, 'types' => PEAR_Common::getDependencyTypes()));
+                    continue;
+                }
+                if (!isset($d['rel']) || empty($d['rel'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPREL,
+                        array('index' => $i, 'rels' => PEAR_Common::getDependencyRelations()));
+                    continue;
+                }
+                if (!empty($d['optional'])) {
+                    if (!in_array($d['optional'], array('yes', 'no'))) {
+                        $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_DEPOPTIONAL,
+                            array('index' => $i, 'opt' => $d['optional']));
+                    }
+                }
+                if ($d['rel'] != 'has' && $d['rel'] != 'not' && empty($d['version'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPVERSION,
+                        array('index' => $i));
+                } elseif (($d['rel'] == 'has' || $d['rel'] == 'not') && !empty($d['version'])) {
+                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_DEPVERSION_IGNORED,
+                        array('index' => $i, 'rel' => $d['rel']));
+                }
+                if ($d['type'] == 'php' && !empty($d['name'])) {
+                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_DEPNAME_IGNORED,
+                        array('index' => $i, 'name' => $d['name']));
+                } elseif ($d['type'] != 'php' && empty($d['name'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPNAME,
+                        array('index' => $i));
+                }
+                if ($d['type'] == 'php' && empty($d['version'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPPHPVERSION,
+                        array('index' => $i));
+                }
+                if (($d['rel'] == 'not') && ($d['type'] == 'php')) {
+                    $this->_validateError(PEAR_PACKAGEFILE_PHP_NO_NOT,
+                        array('index' => $i));
+                }
+                $i++;
+            }
+        }
+        if (!empty($info['configure_options'])) {
+            $i = 1;
+            foreach ($info['configure_options'] as $c) {
+                if (empty($c['name'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_CONFNAME,
+                        array('index' => $i));
+                }
+                if (empty($c['prompt'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_CONFPROMPT,
+                        array('index' => $i));
+                }
+                $i++;
+            }
+        }
+        if (empty($info['filelist'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_FILES);
+            $errors[] = 'no files';
+        } else {
+            foreach ($info['filelist'] as $file => $fa) {
+                if (empty($fa['role'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_FILEROLE,
+                        array('file' => $file, 'roles' => PEAR_Common::getFileRoles()));
+                    continue;
+                } elseif (!in_array($fa['role'], PEAR_Common::getFileRoles())) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILEROLE,
+                        array('file' => $file, 'role' => $fa['role'], 'roles' => PEAR_Common::getFileRoles()));
+                }
+                if (preg_match('~/\.\.?(/|\\z)|^\.\.?/~', str_replace('\\', '/', $file))) {
+                    // file contains .. parent directory or . cur directory references
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME,
+                        array('file' => $file));
+                }
+                if (isset($fa['install-as']) &&
+                      preg_match('~/\.\.?(/|\\z)|^\.\.?/~', 
+                                 str_replace('\\', '/', $fa['install-as']))) {
+                    // install-as contains .. parent directory or . cur directory references
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME,
+                        array('file' => $file . ' [installed as ' . $fa['install-as'] . ']'));
+                }
+                if (isset($fa['baseinstalldir']) &&
+                      preg_match('~/\.\.?(/|\\z)|^\.\.?/~', 
+                                 str_replace('\\', '/', $fa['baseinstalldir']))) {
+                    // install-as contains .. parent directory or . cur directory references
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME,
+                        array('file' => $file . ' [baseinstalldir ' . $fa['baseinstalldir'] . ']'));
+                }
+            }
+        }
+        if (isset($this->_registry) && $this->_isValid) {
+            $chan = $this->_registry->getChannel('pear.php.net');
+            if (PEAR::isError($chan)) {
+                $this->_validateError(PEAR_PACKAGEFILE_ERROR_CHANNELVAL, $chan->getMessage());
+                return $this->_isValid = 0;
+            }
+            $validator = $chan->getValidationObject();
+            $validator->setPackageFile($this);
+            $validator->validate($state);
+            $failures = $validator->getFailures();
+            foreach ($failures['errors'] as $error) {
+                $this->_validateError(PEAR_PACKAGEFILE_ERROR_CHANNELVAL, $error);
+            }
+            foreach ($failures['warnings'] as $warning) {
+                $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_CHANNELVAL, $warning);
+            }
+        }
+        if ($this->_isValid && $state == PEAR_VALIDATE_PACKAGING && !$nofilechecking) {
+            if ($this->_analyzePhpFiles()) {
+                $this->_isValid = true;
+            }
+        }
+        if ($this->_isValid) {
+            return $this->_isValid = $state;
+        }
+        return $this->_isValid = 0;
+    }
+
+    function _analyzePhpFiles()
+    {
+        if (!$this->_isValid) {
+            return false;
+        }
+        if (!isset($this->_packageFile)) {
+            return false;
+        }
+        $dir_prefix = dirname($this->_packageFile);
+        $common = new PEAR_Common;
+        $log = isset($this->_logger) ? array(&$this->_logger, 'log') :
+            array($common, 'log');
+        $info = $this->getFilelist();
+        foreach ($info as $file => $fa) {
+            if (!file_exists($dir_prefix . DIRECTORY_SEPARATOR . $file)) {
+                $this->_validateError(PEAR_PACKAGEFILE_ERROR_FILE_NOTFOUND,
+                    array('file' => realpath($dir_prefix) . DIRECTORY_SEPARATOR . $file));
+                continue;
+            }
+            if ($fa['role'] == 'php' && $dir_prefix) {
+                call_user_func_array($log, array(1, "Analyzing $file"));
+                $srcinfo = $this->_analyzeSourceCode($dir_prefix . DIRECTORY_SEPARATOR . $file);
+                if ($srcinfo) {
+                    $this->_buildProvidesArray($srcinfo);
+                }
+            }
+        }
+        $this->_packageName = $pn = $this->getPackage();
+        $pnl = strlen($pn);
+        if (isset($this->_packageInfo['provides'])) {
+            foreach ((array) $this->_packageInfo['provides'] as $key => $what) {
+                if (isset($what['explicit'])) {
+                    // skip conformance checks if the provides entry is
+                    // specified in the package.xml file
+                    continue;
+                }
+                extract($what);
+                if ($type == 'class') {
+                    if (!strncasecmp($name, $pn, $pnl)) {
+                        continue;
+                    }
+                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX,
+                        array('file' => $file, 'type' => $type, 'name' => $name, 'package' => $pn));
+                } elseif ($type == 'function') {
+                    if (strstr($name, '::') || !strncasecmp($name, $pn, $pnl)) {
+                        continue;
+                    }
+                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX,
+                        array('file' => $file, 'type' => $type, 'name' => $name, 'package' => $pn));
+                }
+            }
+        }
+        return $this->_isValid;
+    }
+
+    /**
+     * Get the default xml generator object
+     *
+     * @return PEAR_PackageFile_Generator_v1
+     */
+    function &getDefaultGenerator()
+    {
+        if (!class_exists('PEAR_PackageFile_Generator_v1')) {
+            require_once 'PEAR/PackageFile/Generator/v1.php';
+        }
+        $a = &new PEAR_PackageFile_Generator_v1($this);
+        return $a;
+    }
+
+    /**
+     * Get the contents of a file listed within the package.xml
+     * @param string
+     * @return string
+     */
+    function getFileContents($file)
+    {
+        if ($this->_archiveFile == $this->_packageFile) { // unpacked
+            $dir = dirname($this->_packageFile);
+            $file = $dir . DIRECTORY_SEPARATOR . $file;
+            $file = str_replace(array('/', '\\'),
+                array(DIRECTORY_SEPARATOR, DIRECTORY_SEPARATOR), $file);
+            if (file_exists($file) && is_readable($file)) {
+                return implode('', file($file));
+            }
+        } else { // tgz
+            if (!class_exists('Archive_Tar')) {
+                require_once 'Archive/Tar.php';
+            }
+            $tar = &new Archive_Tar($this->_archiveFile);
+            $tar->pushErrorHandling(PEAR_ERROR_RETURN);
+            if ($file != 'package.xml' && $file != 'package2.xml') {
+                $file = $this->getPackage() . '-' . $this->getVersion() . '/' . $file;
+            }
+            $file = $tar->extractInString($file);
+            $tar->popErrorHandling();
+            if (PEAR::isError($file)) {
+                return PEAR::raiseError("Cannot locate file '$file' in archive");
+            }
+            return $file;
+        }
+    }
+
+    // {{{ analyzeSourceCode()
+    /**
+     * Analyze the source code of the given PHP file
+     *
+     * @param  string Filename of the PHP file
+     * @return mixed
+     * @access private
+     */
+    function _analyzeSourceCode($file)
+    {
+        if (!function_exists("token_get_all")) {
+            return false;
+        }
+        if (!defined('T_DOC_COMMENT')) {
+            define('T_DOC_COMMENT', T_COMMENT);
+        }
+        if (!defined('T_INTERFACE')) {
+            define('T_INTERFACE', -1);
+        }
+        if (!defined('T_IMPLEMENTS')) {
+            define('T_IMPLEMENTS', -1);
+        }
+        if (!$fp = @fopen($file, "r")) {
+            return false;
+        }
+        fclose($fp);
+        $contents = file_get_contents($file);
+        $tokens = token_get_all($contents);
+/*
+        for ($i = 0; $i < sizeof($tokens); $i++) {
+            @list($token, $data) = $tokens[$i];
+            if (is_string($token)) {
+                var_dump($token);
+            } else {
+                print token_name($token) . ' ';
+                var_dump(rtrim($data));
+            }
+        }
+*/
+        $look_for = 0;
+        $paren_level = 0;
+        $bracket_level = 0;
+        $brace_level = 0;
+        $lastphpdoc = '';
+        $current_class = '';
+        $current_interface = '';
+        $current_class_level = -1;
+        $current_function = '';
+        $current_function_level = -1;
+        $declared_classes = array();
+        $declared_interfaces = array();
+        $declared_functions = array();
+        $declared_methods = array();
+        $used_classes = array();
+        $used_functions = array();
+        $extends = array();
+        $implements = array();
+        $nodeps = array();
+        $inquote = false;
+        $interface = false;
+        for ($i = 0; $i < sizeof($tokens); $i++) {
+            if (is_array($tokens[$i])) {
+                list($token, $data) = $tokens[$i];
+            } else {
+                $token = $tokens[$i];
+                $data = '';
+            }
+            if ($inquote) {
+                if ($token != '"' && $token != T_END_HEREDOC) {
+                    continue;
+                } else {
+                    $inquote = false;
+                    continue;
+                }
+            }
+            switch ($token) {
+                case T_WHITESPACE :
+                    continue;
+                case ';':
+                    if ($interface) {
+                        $current_function = '';
+                        $current_function_level = -1;
+                    }
+                    break;
+                case '"':
+                case T_START_HEREDOC:
+                    $inquote = true;
+                    break;
+                case T_CURLY_OPEN:
+                case T_DOLLAR_OPEN_CURLY_BRACES:
+                case '{': $brace_level++; continue 2;
+                case '}':
+                    $brace_level--;
+                    if ($current_class_level == $brace_level) {
+                        $current_class = '';
+                        $current_class_level = -1;
+                    }
+                    if ($current_function_level == $brace_level) {
+                        $current_function = '';
+                        $current_function_level = -1;
+                    }
+                    continue 2;
+                case '[': $bracket_level++; continue 2;
+                case ']': $bracket_level--; continue 2;
+                case '(': $paren_level++;   continue 2;
+                case ')': $paren_level--;   continue 2;
+                case T_INTERFACE:
+                    $interface = true;
+                case T_CLASS:
+                    if (($current_class_level != -1) || ($current_function_level != -1)) {
+                        $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE,
+                            array('file' => $file));
+                        return false;
+                    }
+                case T_FUNCTION:
+                case T_NEW:
+                case T_EXTENDS:
+                case T_IMPLEMENTS:
+                    $look_for = $token;
+                    continue 2;
+                case T_STRING:
+                    if (version_compare(zend_version(), '2.0', '<')) {
+                        if (in_array(strtolower($data),
+                            array('public', 'private', 'protected', 'abstract',
+                                  'interface', 'implements', 'throw') 
+                                 )) {
+                            $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_PHP5,
+                                array($file));
+                        }
+                    }
+                    if ($look_for == T_CLASS) {
+                        $current_class = $data;
+                        $current_class_level = $brace_level;
+                        $declared_classes[] = $current_class;
+                    } elseif ($look_for == T_INTERFACE) {
+                        $current_interface = $data;
+                        $current_class_level = $brace_level;
+                        $declared_interfaces[] = $current_interface;
+                    } elseif ($look_for == T_IMPLEMENTS) {
+                        $implements[$current_class] = $data;
+                    } elseif ($look_for == T_EXTENDS) {
+                        $extends[$current_class] = $data;
+                    } elseif ($look_for == T_FUNCTION) {
+                        if ($current_class) {
+                            $current_function = "$current_class::$data";
+                            $declared_methods[$current_class][] = $data;
+                        } elseif ($current_interface) {
+                            $current_function = "$current_interface::$data";
+                            $declared_methods[$current_interface][] = $data;
+                        } else {
+                            $current_function = $data;
+                            $declared_functions[] = $current_function;
+                        }
+                        $current_function_level = $brace_level;
+                        $m = array();
+                    } elseif ($look_for == T_NEW) {
+                        $used_classes[$data] = true;
+                    }
+                    $look_for = 0;
+                    continue 2;
+                case T_VARIABLE:
+                    $look_for = 0;
+                    continue 2;
+                case T_DOC_COMMENT:
+                case T_COMMENT:
+                    if (preg_match('!^/\*\*\s!', $data)) {
+                        $lastphpdoc = $data;
+                        if (preg_match_all('/@nodep\s+(\S+)/', $lastphpdoc, $m)) {
+                            $nodeps = array_merge($nodeps, $m[1]);
+                        }
+                    }
+                    continue 2;
+                case T_DOUBLE_COLON:
+                    if (!($tokens[$i - 1][0] == T_WHITESPACE || $tokens[$i - 1][0] == T_STRING)) {
+                        $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE,
+                            array('file' => $file));
+                        return false;
+                    }
+                    $class = $tokens[$i - 1][1];
+                    if (strtolower($class) != 'parent') {
+                        $used_classes[$class] = true;
+                    }
+                    continue 2;
+            }
+        }
+        return array(
+            "source_file" => $file,
+            "declared_classes" => $declared_classes,
+            "declared_interfaces" => $declared_interfaces,
+            "declared_methods" => $declared_methods,
+            "declared_functions" => $declared_functions,
+            "used_classes" => array_diff(array_keys($used_classes), $nodeps),
+            "inheritance" => $extends,
+            "implements" => $implements,
+            );
+    }
+
+    /**
+     * Build a "provides" array from data returned by
+     * analyzeSourceCode().  The format of the built array is like
+     * this:
+     *
+     *  array(
+     *    'class;MyClass' => 'array('type' => 'class', 'name' => 'MyClass'),
+     *    ...
+     *  )
+     *
+     *
+     * @param array $srcinfo array with information about a source file
+     * as returned by the analyzeSourceCode() method.
+     *
+     * @return void
+     *
+     * @access private
+     *
+     */
+    function _buildProvidesArray($srcinfo)
+    {
+        if (!$this->_isValid) {
+            return false;
+        }
+        $file = basename($srcinfo['source_file']);
+        $pn = $this->getPackage();
+        $pnl = strlen($pn);
+        foreach ($srcinfo['declared_classes'] as $class) {
+            $key = "class;$class";
+            if (isset($this->_packageInfo['provides'][$key])) {
+                continue;
+            }
+            $this->_packageInfo['provides'][$key] =
+                array('file'=> $file, 'type' => 'class', 'name' => $class);
+            if (isset($srcinfo['inheritance'][$class])) {
+                $this->_packageInfo['provides'][$key]['extends'] =
+                    $srcinfo['inheritance'][$class];
+            }
+        }
+        foreach ($srcinfo['declared_methods'] as $class => $methods) {
+            foreach ($methods as $method) {
+                $function = "$class::$method";
+                $key = "function;$function";
+                if ($method{0} == '_' || !strcasecmp($method, $class) ||
+                    isset($this->_packageInfo['provides'][$key])) {
+                    continue;
+                }
+                $this->_packageInfo['provides'][$key] =
+                    array('file'=> $file, 'type' => 'function', 'name' => $function);
+            }
+        }
+
+        foreach ($srcinfo['declared_functions'] as $function) {
+            $key = "function;$function";
+            if ($function{0} == '_' || isset($this->_packageInfo['provides'][$key])) {
+                continue;
+            }
+            if (!strstr($function, '::') && strncasecmp($function, $pn, $pnl)) {
+                $warnings[] = "in1 " . $file . ": function \"$function\" not prefixed with package name \"$pn\"";
+            }
+            $this->_packageInfo['provides'][$key] =
+                array('file'=> $file, 'type' => 'function', 'name' => $function);
+        }
+    }
+
+    // }}}
+}
+?>
+                PEAR-1.9.0/PEAR/PackageFile/v2.php                                                                  100664     764     764       207576      100664  11311                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_PackageFile_v2, package.xml version 2.0
  *
@@ -27690,7 +28197,7 @@ class PEAR_PackageFile_v1
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: v2.php,v 1.145 2009/02/24 23:39:16 dufuz Exp $
+ * @version    CVS: $Id: v2.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -27704,7 +28211,7 @@ require_once 'PEAR/ErrorStack.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -29724,7 +30231,7 @@ class PEAR_PackageFile_v2
     }
 }
 ?>
-                                                                                                                              PEAR-1.8.0/PEAR/REST/10.php                                                                         100664     764     764       100236      100664   7604                                                                                                                                                                                                                                                                                                                                                                      <?php
+                                                                                                                                  PEAR-1.9.0/PEAR/REST/10.php                                                                         100664     764     764        77605      100664   7602                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_REST_10
  *
@@ -29735,7 +30242,7 @@ class PEAR_PackageFile_v2
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: 10.php,v 1.60 2009/03/07 23:09:56 dufuz Exp $
+ * @version    CVS: $Id: 10.php 287558 2009-08-21 22:21:28Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a12
  */
@@ -29753,7 +30260,7 @@ require_once 'PEAR/REST.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a12
  */
@@ -29787,16 +30294,18 @@ class PEAR_REST_10
      */
     function getDownloadURL($base, $packageinfo, $prefstate, $installed, $channel = false)
     {
-        $channel = $packageinfo['channel'];
-        $package = $packageinfo['package'];
         $states = $this->betterStates($prefstate, true);
         if (!$states) {
             return PEAR::raiseError('"' . $prefstate . '" is not a valid state');
         }
 
-        $state   = isset($packageinfo['state'])   ? $packageinfo['state']   : null;
-        $version = isset($packageinfo['version']) ? $packageinfo['version'] : null;
-        $info = $this->_rest->retrieveData($base . 'r/' . strtolower($package) . '/allreleases.xml', false, false, $channel);
+        $channel  = $packageinfo['channel'];
+        $package  = $packageinfo['package'];
+        $state    = isset($packageinfo['state'])   ? $packageinfo['state']   : null;
+        $version  = isset($packageinfo['version']) ? $packageinfo['version'] : null;
+        $restFile = $base . 'r/' . strtolower($package) . '/allreleases.xml';
+
+        $info = $this->_rest->retrieveData($restFile, false, false, $channel);
         if (PEAR::isError($info)) {
             return PEAR::raiseError('No releases available for package "' .
                 $channel . '/' . $package . '"');
@@ -29848,22 +30357,27 @@ class PEAR_REST_10
     function getDepDownloadURL($base, $xsdversion, $dependency, $deppackage,
                                $prefstate = 'stable', $installed = false, $channel = false)
     {
-        $channel = $dependency['channel'];
-        $package = $dependency['name'];
         $states = $this->betterStates($prefstate, true);
         if (!$states) {
             return PEAR::raiseError('"' . $prefstate . '" is not a valid state');
         }
-        $state   = isset($dependency['state'])   ? $dependency['state']   : null;
-        $version = isset($dependency['version']) ? $dependency['version'] : null;
-        $info = $this->_rest->retrieveData($base . 'r/' . strtolower($package) . '/allreleases.xml', false, false, $channel);
+
+        $channel  = $dependency['channel'];
+        $package  = $dependency['name'];
+        $state    = isset($dependency['state'])   ? $dependency['state']   : null;
+        $version  = isset($dependency['version']) ? $dependency['version'] : null;
+        $restFile = $base . 'r/' . strtolower($package) . '/allreleases.xml';
+
+        $info = $this->_rest->retrieveData($restFile, false, false, $channel);
         if (PEAR::isError($info)) {
             return PEAR::raiseError('Package "' . $deppackage['channel'] . '/' . $deppackage['package']
                 . '" dependency "' . $channel . '/' . $package . '" has no releases');
         }
+
         if (!is_array($info) || !isset($info['r'])) {
             return false;
         }
+
         $exclude = array();
         $min = $max = $recommended = false;
         if ($xsdversion == '1.0') {
@@ -29981,19 +30495,23 @@ class PEAR_REST_10
         if (!$found) {
             $release = $info['r'][0];
         }
-        $pinfo = $this->_rest->retrieveCacheFirst($base . 'p/' . strtolower($package) . '/' .
+
+        $packageLower = strtolower($package);
+        $pinfo = $this->_rest->retrieveCacheFirst($base . 'p/' . $packageLower . '/' .
             'info.xml', false, false, $channel);
         if (PEAR::isError($pinfo)) {
             return PEAR::raiseError('Package "' . $package .
                 '" does not have REST info xml available');
         }
-        $releaseinfo = $this->_rest->retrieveCacheFirst($base . 'r/' . strtolower($package) . '/' .
+
+        $releaseinfo = $this->_rest->retrieveCacheFirst($base . 'r/' . $packageLower . '/' .
             $release['v'] . '.xml', false, false, $channel);
         if (PEAR::isError($releaseinfo)) {
             return PEAR::raiseError('Package "' . $package . '" Version "' . $release['v'] .
                 '" does not have REST xml available');
         }
-        $packagexml = $this->_rest->retrieveCacheFirst($base . 'r/' . strtolower($package) . '/' .
+
+        $packagexml = $this->_rest->retrieveCacheFirst($base . 'r/' . $packageLower . '/' .
             'deps.' . $release['v'] . '.txt', false, true, $channel);
         if (PEAR::isError($packagexml)) {
             return PEAR::raiseError('Package "' . $package . '" Version "' . $release['v'] .
@@ -30004,39 +30522,49 @@ class PEAR_REST_10
         if (!$packagexml) {
             $packagexml = array();
         }
-        $allinfo = $this->_rest->retrieveData($base . 'r/' . strtolower($package) .
+
+        $allinfo = $this->_rest->retrieveData($base . 'r/' . $packageLower .
             '/allreleases.xml', false, false, $channel);
         if (!is_array($allinfo['r']) || !isset($allinfo['r'][0])) {
             $allinfo['r'] = array($allinfo['r']);
         }
+
         $compatible = false;
         foreach ($allinfo['r'] as $release) {
             if ($release['v'] != $releaseinfo['v']) {
                 continue;
             }
+
             if (!isset($release['co'])) {
                 break;
             }
+
             $compatible = array();
             if (!is_array($release['co']) || !isset($release['co'][0])) {
                 $release['co'] = array($release['co']);
             }
+
             foreach ($release['co'] as $entry) {
                 $comp = array();
-                $comp['name'] = $entry['p'];
+                $comp['name']    = $entry['p'];
                 $comp['channel'] = $entry['c'];
-                $comp['min'] = $entry['min'];
-                $comp['max'] = $entry['max'];
+                $comp['min']     = $entry['min'];
+                $comp['max']     = $entry['max'];
                 if (isset($entry['x']) && !is_array($entry['x'])) {
                     $comp['exclude'] = $entry['x'];
                 }
+
                 $compatible[] = $comp;
             }
+
             if (count($compatible) == 1) {
                 $compatible = $compatible[0];
             }
+
             break;
         }
+
+        $deprecated = false;
         if (isset($pinfo['dc']) && isset($pinfo['dp'])) {
             if (is_array($pinfo['dp'])) {
                 $deprecated = array('channel' => (string) $pinfo['dc'],
@@ -30045,30 +30573,24 @@ class PEAR_REST_10
                 $deprecated = array('channel' => (string) $pinfo['dc'],
                                     'package' => trim($pinfo['dp']));
             }
-        } else {
-            $deprecated = false;
         }
+
+        $return = array(
+            'version'    => $releaseinfo['v'],
+            'info'       => $packagexml,
+            'package'    => $releaseinfo['p']['_content'],
+            'stability'  => $releaseinfo['st'],
+            'compatible' => $compatible,
+            'deprecated' => $deprecated,
+        );
+
         if ($found) {
-            return
-                array('version' => $releaseinfo['v'],
-                      'info' => $packagexml,
-                      'package' => $releaseinfo['p']['_content'],
-                      'stability' => $releaseinfo['st'],
-                      'url' => $releaseinfo['g'],
-                      'compatible' => $compatible,
-                      'deprecated' => $deprecated,
-                );
-        } else {
-            return
-                array('version' => $releaseinfo['v'],
-                      'package' => $releaseinfo['p']['_content'],
-                      'stability' => $releaseinfo['st'],
-                      'info' => $packagexml,
-                      'compatible' => $compatible,
-                      'deprecated' => $deprecated,
-                      'php' => $phpversion
-                );
+            $return['url'] = $releaseinfo['g'];
+            return $return;
         }
+
+        $return['php'] = $phpversion;
+        return $return;
     }
 
     function listPackages($base, $channel = false)
@@ -30077,12 +30599,15 @@ class PEAR_REST_10
         if (PEAR::isError($packagelist)) {
             return $packagelist;
         }
+
         if (!is_array($packagelist) || !isset($packagelist['p'])) {
             return array();
         }
+
         if (!is_array($packagelist['p'])) {
             $packagelist['p'] = array($packagelist['p']);
         }
+
         return $packagelist['p'];
     }
 
@@ -30103,10 +30628,12 @@ class PEAR_REST_10
         if (PEAR::isError($packagelist)) {
             return $packagelist;
         }
+
         if (!is_array($packagelist) || !isset($packagelist['p'])) {
             $ret = array();
             return $ret;
         }
+
         if (!is_array($packagelist['p'])) {
             $packagelist['p'] = array($packagelist['p']);
         }
@@ -30123,6 +30650,7 @@ class PEAR_REST_10
                     $categories[$cat] = $inf['ca'];
                 }
         }
+
         return array_values($categories);
     }
 
@@ -30141,9 +30669,11 @@ class PEAR_REST_10
         if (PEAR::isError($packagelist)) {
             return $packagelist;
         }
+
         if (!is_array($packagelist) || !isset($packagelist['p'])) {
             return array();
         }
+
         if (!is_array($packagelist['p']) ||
             !isset($packagelist['p'][0])) { // only 1 pkg
             $packagelist = array($packagelist['p']);
@@ -30187,7 +30717,7 @@ class PEAR_REST_10
         }
         if ($this->_rest->config->get('verbose') > 0) {
             $ui = &PEAR_Frontend::singleton();
-            $ui->log('Retrieving data...0%', false);
+            $ui->log('Retrieving data...0%', true);
         }
         $ret = array();
         if (!is_array($packagelist) || !isset($packagelist['p'])) {
@@ -30567,621 +31097,645 @@ class PEAR_REST_10
             return 1;
         }
     }
-}                                                                                                                                                                                                                                                                                                                                                                  PEAR-1.8.0/PEAR/REST/11.php                                                                         100664     764     764        26471      100664   7575                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_REST_11 - implement faster list-all/remote-list command
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: 11.php,v 1.16 2009/02/24 23:39:22 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.3
- */
-
-/**
- * For downloading REST xml/txt files
- */
-require_once 'PEAR/REST.php';
-
-/**
- * Implement REST 1.1
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.3
- */
-class PEAR_REST_11
-{
-    /**
-     * @var PEAR_REST
-     */
-    var $_rest;
-
-    function PEAR_REST_11($config, $options = array())
-    {
-        $this->_rest = &new PEAR_REST($config, $options);
-    }
-
-    function listAll($base, $dostable, $basic = true, $searchpackage = false, $searchsummary = false, $channel = false)
-    {
-        $categorylist = $this->_rest->retrieveData($base . 'c/categories.xml', false, false, $channel);
-        if (PEAR::isError($categorylist)) {
-            return $categorylist;
-        }
-
-        $ret = array();
-        if (!is_array($categorylist['c']) || !isset($categorylist['c'][0])) {
-            $categorylist['c'] = array($categorylist['c']);
-        }
-
-        PEAR::pushErrorHandling(PEAR_ERROR_RETURN);
-
-        foreach ($categorylist['c'] as $progress => $category) {
-            $category = $category['_content'];
-            $packagesinfo = $this->_rest->retrieveData($base .
-                'c/' . urlencode($category) . '/packagesinfo.xml', false, false, $channel);
-
-            if (PEAR::isError($packagesinfo)) {
-                continue;
-            }
-
-            if (!is_array($packagesinfo) || !isset($packagesinfo['pi'])) {
-                continue;
-            }
-
-            if (!is_array($packagesinfo['pi']) || !isset($packagesinfo['pi'][0])) {
-                $packagesinfo['pi'] = array($packagesinfo['pi']);
-            }
-
-            foreach ($packagesinfo['pi'] as $packageinfo) {
-                if (empty($packageinfo)) {
-                    continue;
-                }
-
-                $info = $packageinfo['p'];
-                $package = $info['n'];
-                $releases = isset($packageinfo['a']) ? $packageinfo['a'] : false;
-                unset($latest);
-                unset($unstable);
-                unset($stable);
-                unset($state);
-
-                if ($releases) {
-                    if (!isset($releases['r'][0])) {
-                        $releases['r'] = array($releases['r']);
-                    }
-                    foreach ($releases['r'] as $release) {
-                        if (!isset($latest)) {
-                            if ($dostable && $release['s'] == 'stable') {
-                                $latest = $release['v'];
-                                $state = 'stable';
-                            }
-                            if (!$dostable) {
-                                $latest = $release['v'];
-                                $state = $release['s'];
-                            }
-                        }
-                        if (!isset($stable) && $release['s'] == 'stable') {
-                            $stable = $release['v'];
-                            if (!isset($unstable)) {
-                                $unstable = $stable;
-                            }
-                        }
-                        if (!isset($unstable) && $release['s'] != 'stable') {
-                            $unstable = $release['v'];
-                            $state = $release['s'];
-                        }
-                        if (isset($latest) && !isset($state)) {
-                            $state = $release['s'];
-                        }
-                        if (isset($latest) && isset($stable) && isset($unstable)) {
-                            break;
-                        }
-                    }
-                }
-
-                if ($basic) { // remote-list command
-                    if (!isset($latest)) {
-                        $latest = false;
-                    }
-                    if ($dostable) {
-                        // $state is not set if there are no releases
-                        if (isset($state) && $state == 'stable') {
-                            $ret[$package] = array('stable' => $latest);
-                        } else {
-                            $ret[$package] = array('stable' => '-n/a-');
-                        }
-                    } else {
-                        $ret[$package] = array('stable' => $latest);
-                    }
-                    continue;
-                }
-
-                // list-all command
-                $deps = array();
-                if (!isset($unstable)) {
-                    $unstable = false;
-                    $state = 'stable';
-                    if (isset($stable)) {
-                        $latest = $unstable = $stable;
-                    }
-                } else {
-                    $latest = $unstable;
-                }
-
-                if (!isset($latest)) {
-                    $latest = false;
-                }
-
-                if ($latest && isset($packageinfo['deps'])) {
-                    if (!is_array($packageinfo['deps']) ||
-                          !isset($packageinfo['deps'][0])) {
-                        $packageinfo['deps'] = array($packageinfo['deps']);
-                    }
-                    $d = false;
-                    foreach ($packageinfo['deps'] as $dep) {
-                        if ($dep['v'] == $latest) {
-                            $d = unserialize($dep['d']);
-                        }
-                    }
-                    if ($d) {
-                        if (isset($d['required'])) {
-                            if (!class_exists('PEAR_PackageFile_v2')) {
-                                require_once 'PEAR/PackageFile/v2.php';
-                            }
-                            if (!isset($pf)) {
-                                $pf = new PEAR_PackageFile_v2;
-                            }
-                            $pf->setDeps($d);
-                            $tdeps = $pf->getDeps();
-                        } else {
-                            $tdeps = $d;
-                        }
-                        foreach ($tdeps as $dep) {
-                            if ($dep['type'] !== 'pkg') {
-                                continue;
-                            }
-                            $deps[] = $dep;
-                        }
-                    }
-                }
-
-                $info = array('stable' => $latest, 'summary' => $info['s'],
-                    'description' =>
-                    $info['d'], 'deps' => $deps, 'category' => $info['ca']['_content'],
-                    'unstable' => $unstable, 'state' => $state);
-                $ret[$package] = $info;
-            }
-        }
-        PEAR::popErrorHandling();
-        return $ret;
-    }
-
-    /**
-     * List all categories of a REST server
-     *
-     * @param string $base base URL of the server
-     * @return array of categorynames
-     */
-    function listCategories($base, $channel = false)
-    {
-        $categorylist = $this->_rest->retrieveData($base . 'c/categories.xml', false, false, $channel);
-        if (PEAR::isError($categorylist)) {
-            return $categorylist;
-        }
-        if (!is_array($categorylist) || !isset($categorylist['c'])) {
-            return array();
-        }
-        if (isset($categorylist['c']['_content'])) {
-            // only 1 category
-            $categorylist['c'] = array($categorylist['c']);
-        }
-        return $categorylist['c'];
-    }
-
-    /**
-     * List packages in a category of a REST server
-     *
-     * @param string $base base URL of the server
-     * @param string $category name of the category
-     * @param boolean $info also download full package info
-     * @return array of packagenames
-     */
-    function listCategory($base, $category, $info = false, $channel = false)
-    {
-        if ($info == false) {
-            $url = '%s'.'c/%s/packages.xml';
-        } else {
-            $url = '%s'.'c/%s/packagesinfo.xml';
-        }
-        $url = sprintf($url,
-                    $base,
-                    urlencode($category));
-
-        // gives '404 Not Found' error when category doesn't exist
-        $packagelist = $this->_rest->retrieveData($url, false, false, $channel);
-        if (PEAR::isError($packagelist)) {
-            return $packagelist;
-        }
-        if (!is_array($packagelist)) {
-            return array();
-        }
-
-        if ($info == false) {
-            if (!isset($packagelist['p'])) {
-                return array();
-            }
-            if (!is_array($packagelist['p']) ||
-                !isset($packagelist['p'][0])) { // only 1 pkg
-                $packagelist = array($packagelist['p']);
-            } else {
-                $packagelist = $packagelist['p'];
-            }
-            return $packagelist;
-        } else {
-            // info == true
-            if (!isset($packagelist['pi'])) {
-                return array();
-            }
-            if (!is_array($packagelist['pi']) ||
-                !isset($packagelist['pi'][0])) { // only 1 pkg
-                $packagelist_pre = array($packagelist['pi']);
-            } else {
-                $packagelist_pre = $packagelist['pi'];
-            }
-
-            $packagelist = array();
-            foreach ($packagelist_pre as $i => $item) {
-                // compatibility with r/<latest.txt>.xml
-                if (isset($item['a']['r'][0])) {
-                    // multiple releases
-                    $item['p']['v'] = $item['a']['r'][0]['v'];
-                    $item['p']['st'] = $item['a']['r'][0]['s'];
-                } elseif (isset($item['a'])) {
-                    // first and only release
-                    $item['p']['v'] = $item['a']['r']['v'];
-                    $item['p']['st'] = $item['a']['r']['s'];
-                }
-
-                $packagelist[$i] = array('attribs' => $item['p']['r'],
-                                         '_content' => $item['p']['n'],
-                                         'info' => $item['p']);
-            }
-        }
-
-        return $packagelist;
-    }
-
-    /**
-     * Return an array containing all of the states that are more stable than
-     * or equal to the passed in state
-     *
-     * @param string Release state
-     * @param boolean Determines whether to include $state in the list
-     * @return false|array False if $state is not a valid release state
-     */
-    function betterStates($state, $include = false)
-    {
-        static $states = array('snapshot', 'devel', 'alpha', 'beta', 'stable');
-        $i = array_search($state, $states);
-        if ($i === false) {
-            return false;
-        }
-        if ($include) {
-            $i--;
-        }
-        return array_slice($states, $i + 1);
-    }
-}
-?>                                                                                                                                                                                                       PEAR-1.8.0/PEAR/REST/13.php                                                                         100664     764     764        27117      100664   7575                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_REST_13
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: 13.php,v 1.8 2009/02/24 23:39:22 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a12
- */
-
-/**
- * For downloading REST xml/txt files
- */
-require_once 'PEAR/REST.php';
-require_once 'PEAR/REST/10.php';
-
-/**
- * Implement REST 1.3
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a12
- */
-class PEAR_REST_13 extends PEAR_REST_10
-{
-    /**
-     * Retrieve information about a remote package to be downloaded from a REST server
-     *
-     * This is smart enough to resolve the minimum PHP version dependency prior to download
-     * @param string $base The uri to prepend to all REST calls
-     * @param array $packageinfo an array of format:
-     * <pre>
-     *  array(
-     *   'package' => 'packagename',
-     *   'channel' => 'channelname',
-     *  ['state' => 'alpha' (or valid state),]
-     *  -or-
-     *  ['version' => '1.whatever']
-     * </pre>
-     * @param string $prefstate Current preferred_state config variable value
-     * @param bool $installed the installed version of this package to compare against
-     * @return array|false|PEAR_Error see {@link _returnDownloadURL()}
-     */
-    function getDownloadURL($base, $packageinfo, $prefstate, $installed, $channel = false)
-    {
-        $channel = $packageinfo['channel'];
-        $package = $packageinfo['package'];
-        $states = $this->betterStates($prefstate, true);
-        if (!$states) {
-            return PEAR::raiseError('"' . $prefstate . '" is not a valid state');
-        }
-
-        $state   = isset($packageinfo['state'])   ? $packageinfo['state']   : null;
-        $version = isset($packageinfo['version']) ? $packageinfo['version'] : null;
-        $info = $this->_rest->retrieveData($base . 'r/' . strtolower($package) .
-            '/allreleases2.xml');
-        if (PEAR::isError($info)) {
-            return PEAR::raiseError('No releases available for package "' .
-                $channel . '/' . $package . '"');
-        }
-
-        if (!isset($info['r'])) {
-            return false;
-        }
-
-        $release = $found = false;
-        if (!is_array($info['r']) || !isset($info['r'][0])) {
-            $info['r'] = array($info['r']);
-        }
-
-        $skippedphp = false;
-        foreach ($info['r'] as $release) {
-            if (!isset($this->_rest->_options['force']) && ($installed &&
-                  version_compare($release['v'], $installed, '<'))) {
-                continue;
-            }
-
-            if (isset($state)) {
-                // try our preferred state first
-                if ($release['s'] == $state) {
-                    if (!isset($version) && version_compare($release['m'], phpversion(), '>')) {
-                        // skip releases that require a PHP version newer than our PHP version
-                        $skippedphp = $release;
-                        continue;
-                    }
-                    $found = true;
-                    break;
-                }
-
-                // see if there is something newer and more stable
-                // bug #7221
-                if (in_array($release['s'], $this->betterStates($state), true)) {
-                    if (!isset($version) && version_compare($release['m'], phpversion(), '>')) {
-                        // skip releases that require a PHP version newer than our PHP version
-                        $skippedphp = $release;
-                        continue;
-                    }
-                    $found = true;
-                    break;
-                }
-            } elseif (isset($version)) {
-                if ($release['v'] == $version) {
-                    if (!isset($this->_rest->_options['force']) &&
-                          !isset($version) &&
-                          version_compare($release['m'], phpversion(), '>')) {
-                        // skip releases that require a PHP version newer than our PHP version
-                        $skippedphp = $release;
-                        continue;
-                    }
-                    $found = true;
-                    break;
-                }
-            } else {
-                if (in_array($release['s'], $states)) {
-                    if (version_compare($release['m'], phpversion(), '>')) {
-                        // skip releases that require a PHP version newer than our PHP version
-                        $skippedphp = $release;
-                        continue;
-                    }
-                    $found = true;
-                    break;
-                }
-            }
-        }
-
-        if (!$found && $skippedphp) {
-            $found = null;
-        }
-
-        return $this->_returnDownloadURL($base, $package, $release, $info, $found, $skippedphp, $channel);
-    }
-
-    function getDepDownloadURL($base, $xsdversion, $dependency, $deppackage,
-                               $prefstate = 'stable', $installed = false, $channel = false)
-    {
-        $channel = $dependency['channel'];
-        $package = $dependency['name'];
-        $states = $this->betterStates($prefstate, true);
-        if (!$states) {
-            return PEAR::raiseError('"' . $prefstate . '" is not a valid state');
-        }
-
-        $state   = isset($dependency['state'])   ? $dependency['state']   : null;
-        $version = isset($dependency['version']) ? $dependency['version'] : null;
-        $info = $this->_rest->retrieveData($base . 'r/' . strtolower($package) .
-            '/allreleases2.xml');
-        if (PEAR::isError($info)) {
-            return PEAR::raiseError('Package "' . $deppackage['channel'] . '/' . $deppackage['package']
-                . '" dependency "' . $channel . '/' . $package . '" has no releases');
-        }
-
-        if (!is_array($info) || !isset($info['r'])) {
-            return false;
-        }
-
-        $exclude = array();
-        $min = $max = $recommended = false;
-        if ($xsdversion == '1.0') {
-            $pinfo['package'] = $dependency['name'];
-            $pinfo['channel'] = 'pear.php.net'; // this is always true - don't change this
-            switch ($dependency['rel']) {
-                case 'ge' :
-                    $min = $dependency['version'];
-                break;
-                case 'gt' :
-                    $min = $dependency['version'];
-                    $exclude = array($dependency['version']);
-                break;
-                case 'eq' :
-                    $recommended = $dependency['version'];
-                break;
-                case 'lt' :
-                    $max = $dependency['version'];
-                    $exclude = array($dependency['version']);
-                break;
-                case 'le' :
-                    $max = $dependency['version'];
-                break;
-                case 'ne' :
-                    $exclude = array($dependency['version']);
-                break;
-            }
-        } else {
-            $pinfo['package'] = $dependency['name'];
-            $min = isset($dependency['min']) ? $dependency['min'] : false;
-            $max = isset($dependency['max']) ? $dependency['max'] : false;
-            $recommended = isset($dependency['recommended']) ?
-                $dependency['recommended'] : false;
-            if (isset($dependency['exclude'])) {
-                if (!isset($dependency['exclude'][0])) {
-                    $exclude = array($dependency['exclude']);
-                }
-            }
-        }
-
-        $found = false;
-        $release = false;
-        $skippedphp = false;
-        if (!is_array($info['r']) || !isset($info['r'][0])) {
-            $info['r'] = array($info['r']);
-        }
-
-        foreach ($info['r'] as $release) {
-            if (!isset($this->_rest->_options['force']) && ($installed &&
-                  version_compare($release['v'], $installed, '<'))) {
-                continue;
-            }
-
-            if (in_array($release['v'], $exclude)) { // skip excluded versions
-                continue;
-            }
-
-            // allow newer releases to say "I'm OK with the dependent package"
-            if ($xsdversion == '2.0' && isset($release['co'])) {
-                if (!is_array($release['co']) || !isset($release['co'][0])) {
-                    $release['co'] = array($release['co']);
-                }
-
-                foreach ($release['co'] as $entry) {
-                    if (isset($entry['x']) && !is_array($entry['x'])) {
-                        $entry['x'] = array($entry['x']);
-                    } elseif (!isset($entry['x'])) {
-                        $entry['x'] = array();
-                    }
-
-                    if ($entry['c'] == $deppackage['channel'] &&
-                          strtolower($entry['p']) == strtolower($deppackage['package']) &&
-                          version_compare($deppackage['version'], $entry['min'], '>=') &&
-                          version_compare($deppackage['version'], $entry['max'], '<=') &&
-                          !in_array($release['v'], $entry['x'])) {
-                        if (version_compare($release['m'], phpversion(), '>')) {
-                            // skip dependency releases that require a PHP version
-                            // newer than our PHP version
-                            $skippedphp = $release;
-                            continue;
-                        }
-
-                        $recommended = $release['v'];
-                        break;
-                    }
-                }
-            }
-
-            if ($recommended) {
-                if ($release['v'] != $recommended) { // if we want a specific
-                    // version, then skip all others
-                    continue;
-                }
-
-                if (!in_array($release['s'], $states)) {
-                    // the stability is too low, but we must return the
-                    // recommended version if possible
-                    return $this->_returnDownloadURL($base, $package, $release, $info, true, false, $channel);
-                }
-            }
-
-            if ($min && version_compare($release['v'], $min, 'lt')) { // skip too old versions
-                continue;
-            }
-
-            if ($max && version_compare($release['v'], $max, 'gt')) { // skip too new versions
-                continue;
-            }
-
-            if ($installed && version_compare($release['v'], $installed, '<')) {
-                continue;
-            }
-
-            if (in_array($release['s'], $states)) { // if in the preferred state...
-                if (version_compare($release['m'], phpversion(), '>')) {
-                    // skip dependency releases that require a PHP version
-                    // newer than our PHP version
-                    $skippedphp = $release;
-                    continue;
-                }
-
-                $found = true; // ... then use it
-                break;
-            }
-        }
-
-        if (!$found && $skippedphp) {
-            $found = null;
-        }
-
-        return $this->_returnDownloadURL($base, $package, $release, $info, $found, $skippedphp, $channel);
-    }
-}                                                                                                                                                                                                                                                                                                                                                                                                                                                 PEAR-1.8.0/PEAR/Task/Postinstallscript/rw.php                                                       100664     764     764        13314      100664  13662                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                           PEAR-1.9.0/PEAR/REST/11.php                                                                         100664     764     764        26054      100664   7573                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_REST_11 - implement faster list-all/remote-list command
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: 11.php 286670 2009-08-02 14:16:06Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.3
+ */
+
+/**
+ * For downloading REST xml/txt files
+ */
+require_once 'PEAR/REST.php';
+
+/**
+ * Implement REST 1.1
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.3
+ */
+class PEAR_REST_11
+{
+    /**
+     * @var PEAR_REST
+     */
+    var $_rest;
+
+    function PEAR_REST_11($config, $options = array())
+    {
+        $this->_rest = &new PEAR_REST($config, $options);
+    }
+
+    function listAll($base, $dostable, $basic = true, $searchpackage = false, $searchsummary = false, $channel = false)
+    {
+        $categorylist = $this->_rest->retrieveData($base . 'c/categories.xml', false, false, $channel);
+        if (PEAR::isError($categorylist)) {
+            return $categorylist;
+        }
+
+        $ret = array();
+        if (!is_array($categorylist['c']) || !isset($categorylist['c'][0])) {
+            $categorylist['c'] = array($categorylist['c']);
+        }
+
+        PEAR::pushErrorHandling(PEAR_ERROR_RETURN);
+
+        foreach ($categorylist['c'] as $progress => $category) {
+            $category = $category['_content'];
+            $packagesinfo = $this->_rest->retrieveData($base .
+                'c/' . urlencode($category) . '/packagesinfo.xml', false, false, $channel);
+
+            if (PEAR::isError($packagesinfo)) {
+                continue;
+            }
+
+            if (!is_array($packagesinfo) || !isset($packagesinfo['pi'])) {
+                continue;
+            }
+
+            if (!is_array($packagesinfo['pi']) || !isset($packagesinfo['pi'][0])) {
+                $packagesinfo['pi'] = array($packagesinfo['pi']);
+            }
+
+            foreach ($packagesinfo['pi'] as $packageinfo) {
+                if (empty($packageinfo)) {
+                    continue;
+                }
+
+                $info     = $packageinfo['p'];
+                $package  = $info['n'];
+                $releases = isset($packageinfo['a']) ? $packageinfo['a'] : false;
+                unset($latest);
+                unset($unstable);
+                unset($stable);
+                unset($state);
+
+                if ($releases) {
+                    if (!isset($releases['r'][0])) {
+                        $releases['r'] = array($releases['r']);
+                    }
+
+                    foreach ($releases['r'] as $release) {
+                        if (!isset($latest)) {
+                            if ($dostable && $release['s'] == 'stable') {
+                                $latest = $release['v'];
+                                $state = 'stable';
+                            }
+                            if (!$dostable) {
+                                $latest = $release['v'];
+                                $state = $release['s'];
+                            }
+                        }
+
+                        if (!isset($stable) && $release['s'] == 'stable') {
+                            $stable = $release['v'];
+                            if (!isset($unstable)) {
+                                $unstable = $stable;
+                            }
+                        }
+
+                        if (!isset($unstable) && $release['s'] != 'stable') {
+                            $unstable = $release['v'];
+                            $state = $release['s'];
+                        }
+
+                        if (isset($latest) && !isset($state)) {
+                            $state = $release['s'];
+                        }
+
+                        if (isset($latest) && isset($stable) && isset($unstable)) {
+                            break;
+                        }
+                    }
+                }
+
+                if ($basic) { // remote-list command
+                    if (!isset($latest)) {
+                        $latest = false;
+                    }
+
+                    if ($dostable) {
+                        // $state is not set if there are no releases
+                        if (isset($state) && $state == 'stable') {
+                            $ret[$package] = array('stable' => $latest);
+                        } else {
+                            $ret[$package] = array('stable' => '-n/a-');
+                        }
+                    } else {
+                        $ret[$package] = array('stable' => $latest);
+                    }
+
+                    continue;
+                }
+
+                // list-all command
+                if (!isset($unstable)) {
+                    $unstable = false;
+                    $state = 'stable';
+                    if (isset($stable)) {
+                        $latest = $unstable = $stable;
+                    }
+                } else {
+                    $latest = $unstable;
+                }
+
+                if (!isset($latest)) {
+                    $latest = false;
+                }
+
+                $deps = array();
+                if ($latest && isset($packageinfo['deps'])) {
+                    if (!is_array($packageinfo['deps']) ||
+                          !isset($packageinfo['deps'][0])
+                    ) {
+                        $packageinfo['deps'] = array($packageinfo['deps']);
+                    }
+
+                    $d = false;
+                    foreach ($packageinfo['deps'] as $dep) {
+                        if ($dep['v'] == $latest) {
+                            $d = unserialize($dep['d']);
+                        }
+                    }
+
+                    if ($d) {
+                        if (isset($d['required'])) {
+                            if (!class_exists('PEAR_PackageFile_v2')) {
+                                require_once 'PEAR/PackageFile/v2.php';
+                            }
+
+                            if (!isset($pf)) {
+                                $pf = new PEAR_PackageFile_v2;
+                            }
+
+                            $pf->setDeps($d);
+                            $tdeps = $pf->getDeps();
+                        } else {
+                            $tdeps = $d;
+                        }
+
+                        foreach ($tdeps as $dep) {
+                            if ($dep['type'] !== 'pkg') {
+                                continue;
+                            }
+
+                            $deps[] = $dep;
+                        }
+                    }
+                }
+
+                $info = array(
+                    'stable'      => $latest,
+                    'summary'     => $info['s'],
+                    'description' => $info['d'],
+                    'deps'        => $deps,
+                    'category'    => $info['ca']['_content'],
+                    'unstable'    => $unstable,
+                    'state'       => $state
+                );
+                $ret[$package] = $info;
+            }
+        }
+
+        PEAR::popErrorHandling();
+        return $ret;
+    }
+
+    /**
+     * List all categories of a REST server
+     *
+     * @param string $base base URL of the server
+     * @return array of categorynames
+     */
+    function listCategories($base, $channel = false)
+    {
+        $categorylist = $this->_rest->retrieveData($base . 'c/categories.xml', false, false, $channel);
+        if (PEAR::isError($categorylist)) {
+            return $categorylist;
+        }
+
+        if (!is_array($categorylist) || !isset($categorylist['c'])) {
+            return array();
+        }
+
+        if (isset($categorylist['c']['_content'])) {
+            // only 1 category
+            $categorylist['c'] = array($categorylist['c']);
+        }
+
+        return $categorylist['c'];
+    }
+
+    /**
+     * List packages in a category of a REST server
+     *
+     * @param string $base base URL of the server
+     * @param string $category name of the category
+     * @param boolean $info also download full package info
+     * @return array of packagenames
+     */
+    function listCategory($base, $category, $info = false, $channel = false)
+    {
+        if ($info == false) {
+            $url = '%s'.'c/%s/packages.xml';
+        } else {
+            $url = '%s'.'c/%s/packagesinfo.xml';
+        }
+        $url = sprintf($url,
+                    $base,
+                    urlencode($category));
+
+        // gives '404 Not Found' error when category doesn't exist
+        $packagelist = $this->_rest->retrieveData($url, false, false, $channel);
+        if (PEAR::isError($packagelist)) {
+            return $packagelist;
+        }
+        if (!is_array($packagelist)) {
+            return array();
+        }
+
+        if ($info == false) {
+            if (!isset($packagelist['p'])) {
+                return array();
+            }
+            if (!is_array($packagelist['p']) ||
+                !isset($packagelist['p'][0])) { // only 1 pkg
+                $packagelist = array($packagelist['p']);
+            } else {
+                $packagelist = $packagelist['p'];
+            }
+            return $packagelist;
+        }
+
+        // info == true
+        if (!isset($packagelist['pi'])) {
+            return array();
+        }
+
+        if (!is_array($packagelist['pi']) ||
+            !isset($packagelist['pi'][0])) { // only 1 pkg
+            $packagelist_pre = array($packagelist['pi']);
+        } else {
+            $packagelist_pre = $packagelist['pi'];
+        }
+
+        $packagelist = array();
+        foreach ($packagelist_pre as $i => $item) {
+            // compatibility with r/<latest.txt>.xml
+            if (isset($item['a']['r'][0])) {
+                // multiple releases
+                $item['p']['v'] = $item['a']['r'][0]['v'];
+                $item['p']['st'] = $item['a']['r'][0]['s'];
+            } elseif (isset($item['a'])) {
+                // first and only release
+                $item['p']['v'] = $item['a']['r']['v'];
+                $item['p']['st'] = $item['a']['r']['s'];
+            }
+
+            $packagelist[$i] = array('attribs' => $item['p']['r'],
+                                     '_content' => $item['p']['n'],
+                                     'info' => $item['p']);
+        }
+
+        return $packagelist;
+    }
+
+    /**
+     * Return an array containing all of the states that are more stable than
+     * or equal to the passed in state
+     *
+     * @param string Release state
+     * @param boolean Determines whether to include $state in the list
+     * @return false|array False if $state is not a valid release state
+     */
+    function betterStates($state, $include = false)
+    {
+        static $states = array('snapshot', 'devel', 'alpha', 'beta', 'stable');
+        $i = array_search($state, $states);
+        if ($i === false) {
+            return false;
+        }
+        if ($include) {
+            $i--;
+        }
+        return array_slice($states, $i + 1);
+    }
+}
+?>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    PEAR-1.9.0/PEAR/REST/13.php                                                                         100664     764     764        26544      100664   7601                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_REST_13
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: 13.php 287110 2009-08-11 18:51:15Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a12
+ */
+
+/**
+ * For downloading REST xml/txt files
+ */
+require_once 'PEAR/REST.php';
+require_once 'PEAR/REST/10.php';
+
+/**
+ * Implement REST 1.3
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a12
+ */
+class PEAR_REST_13 extends PEAR_REST_10
+{
+    /**
+     * Retrieve information about a remote package to be downloaded from a REST server
+     *
+     * This is smart enough to resolve the minimum PHP version dependency prior to download
+     * @param string $base The uri to prepend to all REST calls
+     * @param array $packageinfo an array of format:
+     * <pre>
+     *  array(
+     *   'package' => 'packagename',
+     *   'channel' => 'channelname',
+     *  ['state' => 'alpha' (or valid state),]
+     *  -or-
+     *  ['version' => '1.whatever']
+     * </pre>
+     * @param string $prefstate Current preferred_state config variable value
+     * @param bool $installed the installed version of this package to compare against
+     * @return array|false|PEAR_Error see {@link _returnDownloadURL()}
+     */
+    function getDownloadURL($base, $packageinfo, $prefstate, $installed, $channel = false)
+    {
+        $states = $this->betterStates($prefstate, true);
+        if (!$states) {
+            return PEAR::raiseError('"' . $prefstate . '" is not a valid state');
+        }
+
+        $channel  = $packageinfo['channel'];
+        $package  = $packageinfo['package'];
+        $state    = isset($packageinfo['state'])   ? $packageinfo['state']   : null;
+        $version  = isset($packageinfo['version']) ? $packageinfo['version'] : null;
+        $restFile = $base . 'r/' . strtolower($package) . '/allreleases2.xml';
+
+        $info = $this->_rest->retrieveData($restFile, false, false, $channel);
+        if (PEAR::isError($info)) {
+            return PEAR::raiseError('No releases available for package "' .
+                $channel . '/' . $package . '"');
+        }
+
+        if (!isset($info['r'])) {
+            return false;
+        }
+
+        $release = $found = false;
+        if (!is_array($info['r']) || !isset($info['r'][0])) {
+            $info['r'] = array($info['r']);
+        }
+
+        $skippedphp = false;
+        foreach ($info['r'] as $release) {
+            if (!isset($this->_rest->_options['force']) && ($installed &&
+                  version_compare($release['v'], $installed, '<'))) {
+                continue;
+            }
+
+            if (isset($state)) {
+                // try our preferred state first
+                if ($release['s'] == $state) {
+                    if (!isset($version) && version_compare($release['m'], phpversion(), '>')) {
+                        // skip releases that require a PHP version newer than our PHP version
+                        $skippedphp = $release;
+                        continue;
+                    }
+                    $found = true;
+                    break;
+                }
+
+                // see if there is something newer and more stable
+                // bug #7221
+                if (in_array($release['s'], $this->betterStates($state), true)) {
+                    if (!isset($version) && version_compare($release['m'], phpversion(), '>')) {
+                        // skip releases that require a PHP version newer than our PHP version
+                        $skippedphp = $release;
+                        continue;
+                    }
+                    $found = true;
+                    break;
+                }
+            } elseif (isset($version)) {
+                if ($release['v'] == $version) {
+                    if (!isset($this->_rest->_options['force']) &&
+                          !isset($version) &&
+                          version_compare($release['m'], phpversion(), '>')) {
+                        // skip releases that require a PHP version newer than our PHP version
+                        $skippedphp = $release;
+                        continue;
+                    }
+                    $found = true;
+                    break;
+                }
+            } else {
+                if (in_array($release['s'], $states)) {
+                    if (version_compare($release['m'], phpversion(), '>')) {
+                        // skip releases that require a PHP version newer than our PHP version
+                        $skippedphp = $release;
+                        continue;
+                    }
+                    $found = true;
+                    break;
+                }
+            }
+        }
+
+        if (!$found && $skippedphp) {
+            $found = null;
+        }
+
+        return $this->_returnDownloadURL($base, $package, $release, $info, $found, $skippedphp, $channel);
+    }
+
+    function getDepDownloadURL($base, $xsdversion, $dependency, $deppackage,
+                               $prefstate = 'stable', $installed = false, $channel = false)
+    {
+        $states = $this->betterStates($prefstate, true);
+        if (!$states) {
+            return PEAR::raiseError('"' . $prefstate . '" is not a valid state');
+        }
+
+        $channel  = $dependency['channel'];
+        $package  = $dependency['name'];
+        $state    = isset($dependency['state'])   ? $dependency['state']   : null;
+        $version  = isset($dependency['version']) ? $dependency['version'] : null;
+        $restFile = $base . 'r/' . strtolower($package) .'/allreleases2.xml';
+
+        $info = $this->_rest->retrieveData($restFile, false, false, $channel);
+        if (PEAR::isError($info)) {
+            return PEAR::raiseError('Package "' . $deppackage['channel'] . '/' . $deppackage['package']
+                . '" dependency "' . $channel . '/' . $package . '" has no releases');
+        }
+
+        if (!is_array($info) || !isset($info['r'])) {
+            return false;
+        }
+
+        $exclude = array();
+        $min = $max = $recommended = false;
+        if ($xsdversion == '1.0') {
+            $pinfo['package'] = $dependency['name'];
+            $pinfo['channel'] = 'pear.php.net'; // this is always true - don't change this
+            switch ($dependency['rel']) {
+                case 'ge' :
+                    $min = $dependency['version'];
+                break;
+                case 'gt' :
+                    $min = $dependency['version'];
+                    $exclude = array($dependency['version']);
+                break;
+                case 'eq' :
+                    $recommended = $dependency['version'];
+                break;
+                case 'lt' :
+                    $max = $dependency['version'];
+                    $exclude = array($dependency['version']);
+                break;
+                case 'le' :
+                    $max = $dependency['version'];
+                break;
+                case 'ne' :
+                    $exclude = array($dependency['version']);
+                break;
+            }
+        } else {
+            $pinfo['package'] = $dependency['name'];
+            $min = isset($dependency['min']) ? $dependency['min'] : false;
+            $max = isset($dependency['max']) ? $dependency['max'] : false;
+            $recommended = isset($dependency['recommended']) ?
+                $dependency['recommended'] : false;
+            if (isset($dependency['exclude'])) {
+                if (!isset($dependency['exclude'][0])) {
+                    $exclude = array($dependency['exclude']);
+                }
+            }
+        }
+
+        $skippedphp = $found = $release = false;
+        if (!is_array($info['r']) || !isset($info['r'][0])) {
+            $info['r'] = array($info['r']);
+        }
+
+        foreach ($info['r'] as $release) {
+            if (!isset($this->_rest->_options['force']) && ($installed &&
+                  version_compare($release['v'], $installed, '<'))) {
+                continue;
+            }
+
+            if (in_array($release['v'], $exclude)) { // skip excluded versions
+                continue;
+            }
+
+            // allow newer releases to say "I'm OK with the dependent package"
+            if ($xsdversion == '2.0' && isset($release['co'])) {
+                if (!is_array($release['co']) || !isset($release['co'][0])) {
+                    $release['co'] = array($release['co']);
+                }
+
+                foreach ($release['co'] as $entry) {
+                    if (isset($entry['x']) && !is_array($entry['x'])) {
+                        $entry['x'] = array($entry['x']);
+                    } elseif (!isset($entry['x'])) {
+                        $entry['x'] = array();
+                    }
+
+                    if ($entry['c'] == $deppackage['channel'] &&
+                          strtolower($entry['p']) == strtolower($deppackage['package']) &&
+                          version_compare($deppackage['version'], $entry['min'], '>=') &&
+                          version_compare($deppackage['version'], $entry['max'], '<=') &&
+                          !in_array($release['v'], $entry['x'])) {
+                        if (version_compare($release['m'], phpversion(), '>')) {
+                            // skip dependency releases that require a PHP version
+                            // newer than our PHP version
+                            $skippedphp = $release;
+                            continue;
+                        }
+
+                        $recommended = $release['v'];
+                        break;
+                    }
+                }
+            }
+
+            if ($recommended) {
+                if ($release['v'] != $recommended) { // if we want a specific
+                    // version, then skip all others
+                    continue;
+                }
+
+                if (!in_array($release['s'], $states)) {
+                    // the stability is too low, but we must return the
+                    // recommended version if possible
+                    return $this->_returnDownloadURL($base, $package, $release, $info, true, false, $channel);
+                }
+            }
+
+            if ($min && version_compare($release['v'], $min, 'lt')) { // skip too old versions
+                continue;
+            }
+
+            if ($max && version_compare($release['v'], $max, 'gt')) { // skip too new versions
+                continue;
+            }
+
+            if ($installed && version_compare($release['v'], $installed, '<')) {
+                continue;
+            }
+
+            if (in_array($release['s'], $states)) { // if in the preferred state...
+                if (version_compare($release['m'], phpversion(), '>')) {
+                    // skip dependency releases that require a PHP version
+                    // newer than our PHP version
+                    $skippedphp = $release;
+                    continue;
+                }
+
+                $found = true; // ... then use it
+                break;
+            }
+        }
+
+        if (!$found && $skippedphp) {
+            $found = null;
+        }
+
+        return $this->_returnDownloadURL($base, $package, $release, $info, $found, $skippedphp, $channel);
+    }
+}                                                                                                                                                            PEAR-1.9.0/PEAR/Task/Postinstallscript/rw.php                                                       100664     764     764        13311      100664  13660                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * <tasks:postinstallscript> - read/write version
  *
@@ -31192,7 +31746,7 @@ class PEAR_REST_13 extends PEAR_REST_10
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: rw.php,v 1.14 2009/02/24 23:45:32 dufuz Exp $
+ * @version    CVS: $Id: rw.php 276385 2009-02-24 23:46:03Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a10
  */
@@ -31207,7 +31761,7 @@ require_once 'PEAR/Task/Postinstallscript.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a10
  */
@@ -31349,177 +31903,177 @@ class PEAR_Task_Postinstallscript_rw extends PEAR_Task_Postinstallscript
             );
     }
 }
-?>                                                                                                                                                                                                                                                                                                                    PEAR-1.8.0/PEAR/Task/Replace/rw.php                                                                 100664     764     764         3213      100664  11451                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * <tasks:replace> - read/write version
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: rw.php,v 1.5 2009/02/24 23:45:44 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a10
- */
-/**
- * Base class
- */
-require_once 'PEAR/Task/Replace.php';
-/**
- * Abstracts the replace task xml.
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a10
- */
-class PEAR_Task_Replace_rw extends PEAR_Task_Replace
-{
-    function PEAR_Task_Replace_rw(&$pkg, &$config, &$logger, $fileXml)
-    {
-        parent::PEAR_Task_Common($config, $logger, PEAR_TASK_PACKAGE);
-        $this->_contents = $fileXml;
-        $this->_pkg = &$pkg;
-        $this->_params = array();
-    }
-
-    function validate()
-    {
-        return $this->validateXml($this->_pkg, $this->_params, $this->config, $this->_contents);
-    }
-
-    function setInfo($from, $to, $type)
-    {
-        $this->_params = array('attribs' => array('from' => $from, 'to' => $to, 'type' => $type));
-    }
-
-    function getName()
-    {
-        return 'replace';
-    }
-
-    function getXml()
-    {
-        return $this->_params;
-    }
-}
-?>                                                                                                                                                                                                                                                                                                                                                                                     PEAR-1.8.0/PEAR/Task/Unixeol/rw.php                                                                 100664     764     764         2626      100664  11530                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * <tasks:unixeol> - read/write version
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: rw.php,v 1.6 2009/02/24 23:45:30 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a10
- */
-/**
- * Base class
- */
-require_once 'PEAR/Task/Unixeol.php';
-/**
- * Abstracts the unixeol task xml.
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a10
- */
-class PEAR_Task_Unixeol_rw extends PEAR_Task_Unixeol
-{
-    function PEAR_Task_Unixeol_rw(&$pkg, &$config, &$logger, $fileXml)
-    {
-        parent::PEAR_Task_Common($config, $logger, PEAR_TASK_PACKAGE);
-        $this->_contents = $fileXml;
-        $this->_pkg = &$pkg;
-        $this->_params = array();
-    }
-
-    function validate()
-    {
-        return true;
-    }
-
-    function getName()
-    {
-        return 'unixeol';
-    }
-
-    function getXml()
-    {
-        return '';
-    }
-}
-?>                                                                                                          PEAR-1.8.0/PEAR/Task/Windowseol/rw.php                                                              100664     764     764         2653      100664  12237                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * <tasks:windowseol> - read/write version
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: rw.php,v 1.6 2009/02/24 23:45:20 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a10
- */
-/**
- * Base class
- */
-require_once 'PEAR/Task/Windowseol.php';
-/**
- * Abstracts the windowseol task xml.
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a10
- */
-class PEAR_Task_Windowseol_rw extends PEAR_Task_Windowseol
-{
-    function PEAR_Task_Windowseol_rw(&$pkg, &$config, &$logger, $fileXml)
-    {
-        parent::PEAR_Task_Common($config, $logger, PEAR_TASK_PACKAGE);
-        $this->_contents = $fileXml;
-        $this->_pkg = &$pkg;
-        $this->_params = array();
-    }
-
-    function validate()
-    {
-        return true;
-    }
-
-    function getName()
-    {
-        return 'windowseol';
-    }
-
-    function getXml()
-    {
-        return '';
-    }
-}
-?>                                                                                     PEAR-1.8.0/PEAR/Task/Common.php                                                                     100664     764     764        13741      100664  10725                                                                                                                                                                                                                                                                                                                                                                      <?php
+?>                                                                                                                                                                                                                                                                                                                       PEAR-1.9.0/PEAR/Task/Replace/rw.php                                                                 100664     764     764         3115      100664  11453                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * <tasks:replace> - read/write version
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: rw.php 276385 2009-02-24 23:46:03Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a10
+ */
+/**
+ * Base class
+ */
+require_once 'PEAR/Task/Replace.php';
+/**
+ * Abstracts the replace task xml.
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a10
+ */
+class PEAR_Task_Replace_rw extends PEAR_Task_Replace
+{
+    function PEAR_Task_Replace_rw(&$pkg, &$config, &$logger, $fileXml)
+    {
+        parent::PEAR_Task_Common($config, $logger, PEAR_TASK_PACKAGE);
+        $this->_contents = $fileXml;
+        $this->_pkg = &$pkg;
+        $this->_params = array();
+    }
+
+    function validate()
+    {
+        return $this->validateXml($this->_pkg, $this->_params, $this->config, $this->_contents);
+    }
+
+    function setInfo($from, $to, $type)
+    {
+        $this->_params = array('attribs' => array('from' => $from, 'to' => $to, 'type' => $type));
+    }
+
+    function getName()
+    {
+        return 'replace';
+    }
+
+    function getXml()
+    {
+        return $this->_params;
+    }
+}
+?>                                                                                                                                                                                                                                                                                                                                                                                                                                                   PEAR-1.9.0/PEAR/Task/Unixeol/rw.php                                                                 100664     764     764         2535      100664  11530                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * <tasks:unixeol> - read/write version
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: rw.php 276385 2009-02-24 23:46:03Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a10
+ */
+/**
+ * Base class
+ */
+require_once 'PEAR/Task/Unixeol.php';
+/**
+ * Abstracts the unixeol task xml.
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a10
+ */
+class PEAR_Task_Unixeol_rw extends PEAR_Task_Unixeol
+{
+    function PEAR_Task_Unixeol_rw(&$pkg, &$config, &$logger, $fileXml)
+    {
+        parent::PEAR_Task_Common($config, $logger, PEAR_TASK_PACKAGE);
+        $this->_contents = $fileXml;
+        $this->_pkg = &$pkg;
+        $this->_params = array();
+    }
+
+    function validate()
+    {
+        return true;
+    }
+
+    function getName()
+    {
+        return 'unixeol';
+    }
+
+    function getXml()
+    {
+        return '';
+    }
+}
+?>                                                                                                                                                                   PEAR-1.9.0/PEAR/Task/Windowseol/rw.php                                                              100664     764     764         2562      100664  12237                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * <tasks:windowseol> - read/write version
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: rw.php 276385 2009-02-24 23:46:03Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a10
+ */
+/**
+ * Base class
+ */
+require_once 'PEAR/Task/Windowseol.php';
+/**
+ * Abstracts the windowseol task xml.
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a10
+ */
+class PEAR_Task_Windowseol_rw extends PEAR_Task_Windowseol
+{
+    function PEAR_Task_Windowseol_rw(&$pkg, &$config, &$logger, $fileXml)
+    {
+        parent::PEAR_Task_Common($config, $logger, PEAR_TASK_PACKAGE);
+        $this->_contents = $fileXml;
+        $this->_pkg = &$pkg;
+        $this->_params = array();
+    }
+
+    function validate()
+    {
+        return true;
+    }
+
+    function getName()
+    {
+        return 'windowseol';
+    }
+
+    function getXml()
+    {
+        return '';
+    }
+}
+?>                                                                                                                                              PEAR-1.9.0/PEAR/Task/Common.php                                                                     100664     764     764        13736      100664  10732                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Task_Common, base class for installer tasks
  *
@@ -31530,7 +32084,7 @@ class PEAR_Task_Windowseol_rw extends PEAR_Task_Windowseol
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Common.php,v 1.20 2009/02/25 00:15:49 dufuz Exp $
+ * @version    CVS: $Id: Common.php 276394 2009-02-25 00:15:49Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -31568,7 +32122,7 @@ define('PEAR_TASK_PACKAGEANDINSTALL', 3);
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  * @abstract
@@ -31720,7 +32274,7 @@ class PEAR_Task_Common
         return PEAR::raiseError($msg, $code);
     }
 }
-?>                               PEAR-1.8.0/PEAR/Task/Postinstallscript.php                                                          100664     764     764        34125      100664  13235                                                                                                                                                                                                                                                                                                                                                                      <?php
+?>                                  PEAR-1.9.0/PEAR/Task/Postinstallscript.php                                                          100664     764     764        34122      100664  13233                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * <tasks:postinstallscript>
  *
@@ -31731,7 +32285,7 @@ class PEAR_Task_Common
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Postinstallscript.php,v 1.22 2009/02/24 23:45:56 dufuz Exp $
+ * @version    CVS: $Id: Postinstallscript.php 276385 2009-02-24 23:46:03Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -31749,7 +32303,7 @@ require_once 'PEAR/Task/Common.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -32042,7 +32596,7 @@ class PEAR_Task_Postinstallscript extends PEAR_Task_Common
     {
     }
 }
-?>                                                                                                                                                                                                                                                                                                                                                                                                                                           PEAR-1.8.0/PEAR/Task/Replace.php                                                                    100664     764     764        15235      100664  11050                                                                                                                                                                                                                                                                                                                                                                      <?php
+?>                                                                                                                                                                                                                                                                                                                                                                                                                                              PEAR-1.9.0/PEAR/Task/Replace.php                                                                    100664     764     764        15232      100664  11046                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * <tasks:replace>
  *
@@ -32053,7 +32607,7 @@ class PEAR_Task_Postinstallscript extends PEAR_Task_Common
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Replace.php,v 1.19 2009/02/25 00:15:49 dufuz Exp $
+ * @version    CVS: $Id: Replace.php 276394 2009-02-25 00:15:49Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -32068,7 +32622,7 @@ require_once 'PEAR/Task/Common.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -32217,7 +32771,7 @@ class PEAR_Task_Replace extends PEAR_Task_Common
         return $contents;
     }
 }
-?>                                                                                                                                                                                                                                                                                                                                                                   PEAR-1.8.0/PEAR/Task/Unixeol.php                                                                    100664     764     764         4344      100664  11077                                                                                                                                                                                                                                                                                                                                                                      <?php
+?>                                                                                                                                                                                                                                                                                                                                                                      PEAR-1.9.0/PEAR/Task/Unixeol.php                                                                    100664     764     764         4341      100664  11075                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * <tasks:unixeol>
  *
@@ -32228,7 +32782,7 @@ class PEAR_Task_Replace extends PEAR_Task_Common
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Unixeol.php,v 1.12 2009/02/25 00:15:49 dufuz Exp $
+ * @version    CVS: $Id: Unixeol.php 276394 2009-02-25 00:15:49Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -32243,7 +32797,7 @@ require_once 'PEAR/Task/Common.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -32293,7 +32847,7 @@ class PEAR_Task_Unixeol extends PEAR_Task_Common
         return preg_replace("/\r\n|\n\r|\r|\n/", "\n", $contents);
     }
 }
-?>                                                                                                                                                                                                                                                                                            PEAR-1.8.0/PEAR/Task/Windowseol.php                                                                 100664     764     764         4340      100664  11602                                                                                                                                                                                                                                                                                                                                                                      <?php
+?>                                                                                                                                                                                                                                                                                               PEAR-1.9.0/PEAR/Task/Windowseol.php                                                                 100664     764     764         4335      100664  11607                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * <tasks:windowseol>
  *
@@ -32304,7 +32858,7 @@ class PEAR_Task_Unixeol extends PEAR_Task_Common
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Windowseol.php,v 1.11 2009/02/25 00:15:49 dufuz Exp $
+ * @version    CVS: $Id: Windowseol.php 276394 2009-02-25 00:15:49Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -32319,7 +32873,7 @@ require_once 'PEAR/Task/Common.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -32369,7 +32923,7 @@ class PEAR_Task_Windowseol extends PEAR_Task_Common
         return preg_replace("/\r\n|\n\r|\r|\n/", "\r\n", $contents);
     }
 }
-?>                                                                                                                                                                                                                                                                                                PEAR-1.8.0/PEAR/Validator/PECL.php                                                                  100664     764     764         4200      100664  11211                                                                                                                                                                                                                                                                                                                                                                      <?php
+?>                                                                                                                                                                                                                                                                                                   PEAR-1.9.0/PEAR/Validator/PECL.php                                                                  100664     764     764         4175      100664  11225                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * Channel Validator for the pecl.php.net channel
  *
@@ -32380,7 +32934,7 @@ class PEAR_Task_Windowseol extends PEAR_Task_Common
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2006 The PHP Group
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: PECL.php,v 1.10 2009/02/24 23:39:19 dufuz Exp $
+ * @version    CVS: $Id: PECL.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a5
  */
@@ -32395,7 +32949,7 @@ require_once 'PEAR/Validate.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a5
  */
@@ -32431,225 +32985,225 @@ class PEAR_Validator_PECL extends PEAR_Validate
         return $ret;
     }
 }
-?>                                                                                                                                                                                                                                                                                                                                                                                                PEAR-1.8.0/PEAR/Autoloader.php                                                                      100664     764     764        15202      100664  10664                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * Class auto-loader
- *
- * PHP versions 4
-
- *
- * @category   pear
- * @package    PEAR
- * @author     Stig Bakken <ssb at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Autoloader.php,v 1.15 2009/02/24 23:38:22 dufuz Exp $
- * @link       http://pear.php.net/manual/en/core.ppm.php#core.ppm.pear-autoloader
- * @since      File available since Release 0.1
- * @deprecated File deprecated in Release 1.4.0a1
- */
-
-// /* vim: set expandtab tabstop=4 shiftwidth=4: */
-
-if (!extension_loaded("overload")) {
-    // die hard without ext/overload
-    die("Rebuild PHP with the `overload' extension to use PEAR_Autoloader");
-}
-
-/**
- * Include for PEAR_Error and PEAR classes
- */
-require_once "PEAR.php";
-
-/**
- * This class is for objects where you want to separate the code for
- * some methods into separate classes.  This is useful if you have a
- * class with not-frequently-used methods that contain lots of code
- * that you would like to avoid always parsing.
- *
- * The PEAR_Autoloader class provides autoloading and aggregation.
- * The autoloading lets you set up in which classes the separated
- * methods are found.  Aggregation is the technique used to import new
- * methods, an instance of each class providing separated methods is
- * stored and called every time the aggregated method is called.
- *
- * @category   pear
- * @package    PEAR
- * @author Stig Bakken <ssb at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/manual/en/core.ppm.php#core.ppm.pear-autoloader
- * @since      File available since Release 0.1
- * @deprecated File deprecated in Release 1.4.0a1
- */
-class PEAR_Autoloader extends PEAR
-{
-    // {{{ properties
-
-    /**
-     * Map of methods and classes where they are defined
-     *
-     * @var array
-     *
-     * @access private
-     */
-    var $_autoload_map = array();
-
-    /**
-     * Map of methods and aggregate objects
-     *
-     * @var array
-     *
-     * @access private
-     */
-    var $_method_map = array();
-
-    // }}}
-    // {{{ addAutoload()
-
-    /**
-     * Add one or more autoload entries.
-     *
-     * @param string $method     which method to autoload
-     *
-     * @param string $classname  (optional) which class to find the method in.
-     *                           If the $method parameter is an array, this
-     *                           parameter may be omitted (and will be ignored
-     *                           if not), and the $method parameter will be
-     *                           treated as an associative array with method
-     *                           names as keys and class names as values.
-     *
-     * @return void
-     *
-     * @access public
-     */
-    function addAutoload($method, $classname = null)
-    {
-        if (is_array($method)) {
-            array_walk($method, create_function('$a,&$b', '$b = strtolower($b);'));
-            $this->_autoload_map = array_merge($this->_autoload_map, $method);
-        } else {
-            $this->_autoload_map[strtolower($method)] = $classname;
-        }
-    }
-
-    // }}}
-    // {{{ removeAutoload()
-
-    /**
-     * Remove an autoload entry.
-     *
-     * @param string $method  which method to remove the autoload entry for
-     *
-     * @return bool TRUE if an entry was removed, FALSE if not
-     *
-     * @access public
-     */
-    function removeAutoload($method)
-    {
-        $method = strtolower($method);
-        $ok = isset($this->_autoload_map[$method]);
-        unset($this->_autoload_map[$method]);
-        return $ok;
-    }
-
-    // }}}
-    // {{{ addAggregateObject()
-
-    /**
-     * Add an aggregate object to this object.  If the specified class
-     * is not defined, loading it will be attempted following PEAR's
-     * file naming scheme.  All the methods in the class will be
-     * aggregated, except private ones (name starting with an
-     * underscore) and constructors.
-     *
-     * @param string $classname  what class to instantiate for the object.
-     *
-     * @return void
-     *
-     * @access public
-     */
-    function addAggregateObject($classname)
-    {
-        $classname = strtolower($classname);
-        if (!class_exists($classname)) {
-            $include_file = preg_replace('/[^a-z0-9]/i', '_', $classname);
-            include_once $include_file;
-        }
-        $obj =& new $classname;
-        $methods = get_class_methods($classname);
-        foreach ($methods as $method) {
-            // don't import priviate methods and constructors
-            if ($method{0} != '_' && $method != $classname) {
-                $this->_method_map[$method] = $obj;
-            }
-        }
-    }
-
-    // }}}
-    // {{{ removeAggregateObject()
-
-    /**
-     * Remove an aggregate object.
-     *
-     * @param string $classname  the class of the object to remove
-     *
-     * @return bool  TRUE if an object was removed, FALSE if not
-     *
-     * @access public
-     */
-    function removeAggregateObject($classname)
-    {
-        $ok = false;
-        $classname = strtolower($classname);
-        reset($this->_method_map);
-        while (list($method, $obj) = each($this->_method_map)) {
-            if (is_a($obj, $classname)) {
-                unset($this->_method_map[$method]);
-                $ok = true;
-            }
-        }
-        return $ok;
-    }
-
-    // }}}
-    // {{{ __call()
-
-    /**
-     * Overloaded object call handler, called each time an
-     * undefined/aggregated method is invoked.  This method repeats
-     * the call in the right aggregate object and passes on the return
-     * value.
-     *
-     * @param string $method  which method that was called
-     *
-     * @param string $args    An array of the parameters passed in the
-     *                        original call
-     *
-     * @return mixed  The return value from the aggregated method, or a PEAR
-     *                error if the called method was unknown.
-     */
-    function __call($method, $args, &$retval)
-    {
-        $method = strtolower($method);
-        if (empty($this->_method_map[$method]) && isset($this->_autoload_map[$method])) {
-            $this->addAggregateObject($this->_autoload_map[$method]);
-        }
-        if (isset($this->_method_map[$method])) {
-            $retval = call_user_func_array(array($this->_method_map[$method], $method), $args);
-            return true;
-        }
-        return false;
-    }
-
-    // }}}
-}
-
-overload("PEAR_Autoloader");
-
-?>
-                                                                                                                                                                                                                                                                                                                                                                                              PEAR-1.8.0/PEAR/Builder.php                                                                         100664     764     764        40123      100664  10153                                                                                                                                                                                                                                                                                                                                                                      <?php
+?>                                                                                                                                                                                                                                                                                                                                                                                                   PEAR-1.9.0/PEAR/Autoloader.php                                                                      100664     764     764        14645      100664  10677                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * Class auto-loader
+ *
+ * PHP versions 4
+
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Stig Bakken <ssb at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Autoloader.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/manual/en/core.ppm.php#core.ppm.pear-autoloader
+ * @since      File available since Release 0.1
+ * @deprecated File deprecated in Release 1.4.0a1
+ */
+
+// /* vim: set expandtab tabstop=4 shiftwidth=4: */
+
+if (!extension_loaded("overload")) {
+    // die hard without ext/overload
+    die("Rebuild PHP with the `overload' extension to use PEAR_Autoloader");
+}
+
+/**
+ * Include for PEAR_Error and PEAR classes
+ */
+require_once "PEAR.php";
+
+/**
+ * This class is for objects where you want to separate the code for
+ * some methods into separate classes.  This is useful if you have a
+ * class with not-frequently-used methods that contain lots of code
+ * that you would like to avoid always parsing.
+ *
+ * The PEAR_Autoloader class provides autoloading and aggregation.
+ * The autoloading lets you set up in which classes the separated
+ * methods are found.  Aggregation is the technique used to import new
+ * methods, an instance of each class providing separated methods is
+ * stored and called every time the aggregated method is called.
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author Stig Bakken <ssb at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/manual/en/core.ppm.php#core.ppm.pear-autoloader
+ * @since      File available since Release 0.1
+ * @deprecated File deprecated in Release 1.4.0a1
+ */
+class PEAR_Autoloader extends PEAR
+{
+    // {{{ properties
+
+    /**
+     * Map of methods and classes where they are defined
+     *
+     * @var array
+     *
+     * @access private
+     */
+    var $_autoload_map = array();
+
+    /**
+     * Map of methods and aggregate objects
+     *
+     * @var array
+     *
+     * @access private
+     */
+    var $_method_map = array();
+
+    // }}}
+    // {{{ addAutoload()
+
+    /**
+     * Add one or more autoload entries.
+     *
+     * @param string $method     which method to autoload
+     *
+     * @param string $classname  (optional) which class to find the method in.
+     *                           If the $method parameter is an array, this
+     *                           parameter may be omitted (and will be ignored
+     *                           if not), and the $method parameter will be
+     *                           treated as an associative array with method
+     *                           names as keys and class names as values.
+     *
+     * @return void
+     *
+     * @access public
+     */
+    function addAutoload($method, $classname = null)
+    {
+        if (is_array($method)) {
+            array_walk($method, create_function('$a,&$b', '$b = strtolower($b);'));
+            $this->_autoload_map = array_merge($this->_autoload_map, $method);
+        } else {
+            $this->_autoload_map[strtolower($method)] = $classname;
+        }
+    }
+
+    // }}}
+    // {{{ removeAutoload()
+
+    /**
+     * Remove an autoload entry.
+     *
+     * @param string $method  which method to remove the autoload entry for
+     *
+     * @return bool TRUE if an entry was removed, FALSE if not
+     *
+     * @access public
+     */
+    function removeAutoload($method)
+    {
+        $method = strtolower($method);
+        $ok = isset($this->_autoload_map[$method]);
+        unset($this->_autoload_map[$method]);
+        return $ok;
+    }
+
+    // }}}
+    // {{{ addAggregateObject()
+
+    /**
+     * Add an aggregate object to this object.  If the specified class
+     * is not defined, loading it will be attempted following PEAR's
+     * file naming scheme.  All the methods in the class will be
+     * aggregated, except private ones (name starting with an
+     * underscore) and constructors.
+     *
+     * @param string $classname  what class to instantiate for the object.
+     *
+     * @return void
+     *
+     * @access public
+     */
+    function addAggregateObject($classname)
+    {
+        $classname = strtolower($classname);
+        if (!class_exists($classname)) {
+            $include_file = preg_replace('/[^a-z0-9]/i', '_', $classname);
+            include_once $include_file;
+        }
+        $obj =& new $classname;
+        $methods = get_class_methods($classname);
+        foreach ($methods as $method) {
+            // don't import priviate methods and constructors
+            if ($method{0} != '_' && $method != $classname) {
+                $this->_method_map[$method] = $obj;
+            }
+        }
+    }
+
+    // }}}
+    // {{{ removeAggregateObject()
+
+    /**
+     * Remove an aggregate object.
+     *
+     * @param string $classname  the class of the object to remove
+     *
+     * @return bool  TRUE if an object was removed, FALSE if not
+     *
+     * @access public
+     */
+    function removeAggregateObject($classname)
+    {
+        $ok = false;
+        $classname = strtolower($classname);
+        reset($this->_method_map);
+        while (list($method, $obj) = each($this->_method_map)) {
+            if (is_a($obj, $classname)) {
+                unset($this->_method_map[$method]);
+                $ok = true;
+            }
+        }
+        return $ok;
+    }
+
+    // }}}
+    // {{{ __call()
+
+    /**
+     * Overloaded object call handler, called each time an
+     * undefined/aggregated method is invoked.  This method repeats
+     * the call in the right aggregate object and passes on the return
+     * value.
+     *
+     * @param string $method  which method that was called
+     *
+     * @param string $args    An array of the parameters passed in the
+     *                        original call
+     *
+     * @return mixed  The return value from the aggregated method, or a PEAR
+     *                error if the called method was unknown.
+     */
+    function __call($method, $args, &$retval)
+    {
+        $method = strtolower($method);
+        if (empty($this->_method_map[$method]) && isset($this->_autoload_map[$method])) {
+            $this->addAggregateObject($this->_autoload_map[$method]);
+        }
+        if (isset($this->_method_map[$method])) {
+            $retval = call_user_func_array(array($this->_method_map[$method], $method), $args);
+            return true;
+        }
+        return false;
+    }
+
+    // }}}
+}
+
+overload("PEAR_Autoloader");
+
+?>
+                                                                                           PEAR-1.9.0/PEAR/Builder.php                                                                         100664     764     764        40120      100664  10151                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Builder for building PHP extensions (PECL packages)
  *
@@ -32661,7 +33215,7 @@ overload("PEAR_Autoloader");
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Builder.php,v 1.38 2009/02/24 23:38:22 dufuz Exp $
+ * @version    CVS: $Id: Builder.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  *
@@ -32684,7 +33238,7 @@ require_once 'PEAR/PackageFile.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since PHP 4.0.2
  * @see        http://pear.php.net/manual/en/core.ppm.pear-builder.php
@@ -33011,7 +33565,7 @@ class PEAR_Builder extends PEAR_Common
         if (!file_exists($build_dir) || !is_dir($build_dir) || !chdir($build_dir)) {
             return $this->raiseError("could not chdir to $build_dir");
         }
-        putenv('PHP_PEAR_VERSION=1.8.0');
+        putenv('PHP_PEAR_VERSION=1.9.0');
         foreach ($to_run as $cmd) {
             $err = $this->_runCommand($cmd, $callback);
             if (PEAR::isError($err)) {
@@ -33122,7 +33676,7 @@ class PEAR_Builder extends PEAR_Common
         }
         return PEAR_Common::log($level, $msg);
     }
-}                                                                                                                                                                                                                                                                                                                                                                                                                                             PEAR-1.8.0/PEAR/ChannelFile.php                                                                     100664     764     764       142432      100664  10763                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                                                                                                                                                                                                                                                                                PEAR-1.9.0/PEAR/ChannelFile.php                                                                     100664     764     764       143353      100664  10767                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_ChannelFile, the channel handling class
  *
@@ -33133,7 +33687,7 @@ class PEAR_Builder extends PEAR_Common
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: ChannelFile.php,v 1.84 2009/03/09 01:03:51 dufuz Exp $
+ * @version    CVS: $Id: ChannelFile.php 286951 2009-08-09 14:41:22Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -33270,7 +33824,7 @@ $GLOBALS['_PEAR_CHANNELS_MIRROR_TYPES'] =  array('server');
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -33622,12 +34176,15 @@ class PEAR_ChannelFile
     function _makeRestXml($info, $indent)
     {
         $ret = $indent . "<rest>\n";
-        if (!isset($info['baseurl'][0])) {
+        if (isset($info['baseurl']) && !isset($info['baseurl'][0])) {
             $info['baseurl'] = array($info['baseurl']);
         }
-        foreach ($info['baseurl'] as $url) {
-            $ret .= "$indent <baseurl type=\"" . $url['attribs']['type'] . "\"";
-            $ret .= ">" . $url['_content'] . "</baseurl>\n";
+
+        if (isset($info['baseurl'])) {
+            foreach ($info['baseurl'] as $url) {
+                $ret .= "$indent <baseurl type=\"" . $url['attribs']['type'] . "\"";
+                $ret .= ">" . $url['_content'] . "</baseurl>\n";
+            }
         }
         $ret .= $indent . "</rest>\n";
         return $ret;
@@ -33811,15 +34368,17 @@ class PEAR_ChannelFile
         if (!isset($functions[0])) {
             $functions = array($functions);
         }
+
         foreach ($functions as $function) {
             if (!isset($function['_content']) || empty($function['_content'])) {
                 $this->_validateError(PEAR_CHANNELFILE_ERROR_NO_FUNCTIONNAME,
                     array('parent' => $parent, 'protocol' => $protocol));
             }
+
             if ($protocol == 'rest') {
                 if (!isset($function['attribs']['type']) ||
                       empty($function['attribs']['type'])) {
-                    $this->_validateError(PEAR_CHANNELFILE_ERROR_NO_BASEURLTYPE,
+                    $this->_validateError(PEAR_CHANNELFILE_ERROR_NOBASEURLTYPE,
                         array('parent' => $parent, 'protocol' => $protocol));
                 }
             } else {
@@ -34143,6 +34702,14 @@ class PEAR_ChannelFile
         switch ($version) {
             case '1.0' :
                 $this->resetREST($mirror);
+
+                if (!isset($this->_channelInfo['servers'])) {
+                    $this->_channelInfo['servers'] = array('primary' =>
+                        array('rest' => array()));
+                } elseif (!isset($this->_channelInfo['servers']['primary'])) {
+                    $this->_channelInfo['servers']['primary'] = array('rest' => array());
+                }
+
                 return true;
             break;
             default :
@@ -34667,7 +35234,7 @@ class PEAR_ChannelFile
 
         return time();
     }
-}                                                                                                                                                                                                                                      PEAR-1.8.0/PEAR/Command.php                                                                         100664     764     764        30707      100664  10152                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                                                                                                                     PEAR-1.9.0/PEAR/Command.php                                                                         100664     764     764        30633      100664  10151                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Command, command pattern class
  *
@@ -34679,7 +35246,7 @@ class PEAR_ChannelFile
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Command.php,v 1.41 2009/02/24 23:38:22 dufuz Exp $
+ * @version    CVS: $Id: Command.php 286494 2009-07-29 06:57:11Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -34763,7 +35330,7 @@ $GLOBALS['_PEAR_Command_objects'] = array();
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -34910,27 +35477,31 @@ class PEAR_Command
         if (!$merge) {
             $GLOBALS['_PEAR_Command_commandlist'] = array();
         }
-        while ($entry = readdir($dp)) {
-            if ($entry{0} == '.' || substr($entry, -4) != '.xml') {
+
+        while ($file = readdir($dp)) {
+            if ($file{0} == '.' || substr($file, -4) != '.xml') {
                 continue;
             }
-            $class = "PEAR_Command_".substr($entry, 0, -4);
-            $file = "$dir/$entry";
-            $parser->parse(file_get_contents($file));
-            $implements = $parser->getData();
+
+            $f = substr($file, 0, -4);
+            $class = "PEAR_Command_" . $f;
             // List of commands
             if (empty($GLOBALS['_PEAR_Command_objects'][$class])) {
-                $GLOBALS['_PEAR_Command_objects'][$class] = "$dir/" . substr($entry, 0, -4) .
-                    '.php';
+                $GLOBALS['_PEAR_Command_objects'][$class] = "$dir/" . $f . '.php';
             }
+
+            $parser->parse(file_get_contents("$dir/$file"));
+            $implements = $parser->getData();
             foreach ($implements as $command => $desc) {
                 if ($command == 'attribs') {
                     continue;
                 }
+
                 if (isset($GLOBALS['_PEAR_Command_commandlist'][$command])) {
                     return PEAR::raiseError('Command "' . $command . '" already registered in ' .
                         'class "' . $GLOBALS['_PEAR_Command_commandlist'][$command] . '"');
                 }
+
                 $GLOBALS['_PEAR_Command_commandlist'][$command] = $class;
                 $GLOBALS['_PEAR_Command_commanddesc'][$command] = $desc['summary'];
                 if (isset($desc['shortcut'])) {
@@ -34942,6 +35513,7 @@ class PEAR_Command
                     }
                     $GLOBALS['_PEAR_Command_shortcuts'][$shortcut] = $command;
                 }
+
                 if (isset($desc['options']) && $desc['options']) {
                     foreach ($desc['options'] as $oname => $option) {
                         if (isset($option['shortopt']) && strlen($option['shortopt']) > 1) {
@@ -34954,6 +35526,7 @@ class PEAR_Command
                 }
             }
         }
+
         ksort($GLOBALS['_PEAR_Command_shortcuts']);
         ksort($GLOBALS['_PEAR_Command_commandlist']);
         @closedir($dp);
@@ -35074,7 +35647,7 @@ class PEAR_Command
         return false;
     }
     // }}}
-}                                                         PEAR-1.8.0/PEAR/Common.php                                                                          100664     764     764        63661      100664  10031                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                     PEAR-1.9.0/PEAR/Common.php                                                                          100664     764     764        62255      100664  10030                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Common, the base class for the PEAR Installer
  *
@@ -35087,7 +35660,7 @@ class PEAR_Command
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Common.php,v 1.168 2009/03/27 19:35:47 dufuz Exp $
+ * @version    CVS: $Id: Common.php 282969 2009-06-28 23:09:27Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1.0
  * @deprecated File deprecated since Release 1.4.0a1
@@ -35194,7 +35767,7 @@ $GLOBALS['_PEAR_Common_script_phases'] = array('pre-install', 'post-install', 'p
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  * @deprecated This class will disappear, and its components will be spread
@@ -35535,6 +36108,22 @@ class PEAR_Common extends PEAR
         return false;
     }
 
+    function _postProcessChecks($pf)
+    {
+        if (!PEAR::isError($pf)) {
+            return $this->_postProcessValidPackagexml($pf);
+        }
+
+        $errs = $pf->getUserinfo();
+        if (is_array($errs)) {
+            foreach ($errs as $error) {
+                $e = $this->raiseError($error['message'], $error['code'], null, null, $error);
+            }
+        }
+
+        return $pf;
+    }
+
     /**
      * Returns information about a package file.  Expects the name of
      * a gzipped tar file as input.
@@ -35551,18 +36140,7 @@ class PEAR_Common extends PEAR
     {
         $packagefile = &new PEAR_PackageFile($this->config);
         $pf = &$packagefile->fromTgzFile($file, PEAR_VALIDATE_NORMAL);
-        if (PEAR::isError($pf)) {
-            $errs = $pf->getUserinfo();
-            if (is_array($errs)) {
-                foreach ($errs as $error) {
-                    $e = $this->raiseError($error['message'], $error['code'], null, null, $error);
-                }
-            }
-
-            return $pf;
-        }
-
-        return $this->_postProcessValidPackagexml($pf);
+        return $this->_postProcessChecks($pf);
     }
 
     /**
@@ -35581,18 +36159,7 @@ class PEAR_Common extends PEAR
     {
         $packagefile = &new PEAR_PackageFile($this->config);
         $pf = &$packagefile->fromPackageFile($descfile, PEAR_VALIDATE_NORMAL);
-        if (PEAR::isError($pf)) {
-            $errs = $pf->getUserinfo();
-            if (is_array($errs)) {
-                foreach ($errs as $error) {
-                    $e = $this->raiseError($error['message'], $error['code'], null, null, $error);
-                }
-            }
-
-            return $pf;
-        }
-
-        return $this->_postProcessValidPackagexml($pf);
+        return $this->_postProcessChecks($pf);
     }
 
     /**
@@ -35611,18 +36178,7 @@ class PEAR_Common extends PEAR
     {
         $packagefile = &new PEAR_PackageFile($this->config);
         $pf = &$packagefile->fromXmlString($data, PEAR_VALIDATE_NORMAL, false);
-        if (PEAR::isError($pf)) {
-            $errs = $pf->getUserinfo();
-            if (is_array($errs)) {
-                foreach ($errs as $error) {
-                    $e = $this->raiseError($error['message'], $error['code'], null, null, $error);
-                }
-            }
-
-            return $pf;
-        }
-
-        return $this->_postProcessValidPackagexml($pf);
+        return $this->_postProcessChecks($pf);
     }
 
     /**
@@ -35640,23 +36196,11 @@ class PEAR_Common extends PEAR
         // changelog is not converted to old format.
         $arr = $pf->toArray(true);
         $arr = array_merge($arr, $arr['old']);
-        unset($arr['old']);
-        unset($arr['xsdversion']);
-        unset($arr['contents']);
-        unset($arr['compatible']);
-        unset($arr['channel']);
-        unset($arr['uri']);
-        unset($arr['dependencies']);
-        unset($arr['phprelease']);
-        unset($arr['extsrcrelease']);
-        unset($arr['zendextsrcrelease']);
-        unset($arr['extbinrelease']);
-        unset($arr['zendextbinrelease']);
-        unset($arr['bundle']);
-        unset($arr['lead']);
-        unset($arr['developer']);
-        unset($arr['helper']);
-        unset($arr['contributor']);
+        unset($arr['old'], $arr['xsdversion'], $arr['contents'], $arr['compatible'],
+              $arr['channel'], $arr['uri'], $arr['dependencies'], $arr['phprelease'],
+              $arr['extsrcrelease'], $arr['zendextsrcrelease'], $arr['extbinrelease'],
+              $arr['zendextbinrelease'], $arr['bundle'], $arr['lead'], $arr['developer'],
+              $arr['helper'], $arr['contributor']);
         $arr['filelist'] = $pf->getFilelist();
         $this->pkginfo = $arr;
         return $arr;
@@ -35939,7 +36483,7 @@ class PEAR_Common extends PEAR
 }
 
 require_once 'PEAR/Config.php';
-require_once 'PEAR/PackageFile.php';                                                                               PEAR-1.8.0/PEAR/Config.php                                                                          100664     764     764       204247      100664  10023                                                                                                                                                                                                                                                                                                                                                                      <?php
+require_once 'PEAR/PackageFile.php';                                                                                                                                                                                                                                                                                                                                                   PEAR-1.9.0/PEAR/Config.php                                                                          100664     764     764       204452      100664  10022                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Config, customized configuration handling for the PEAR Installer
  *
@@ -35951,7 +36495,7 @@ require_once 'PEAR/PackageFile.php';                                            
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Config.php,v 1.157 2009/02/25 00:23:26 dufuz Exp $
+ * @version    CVS: $Id: Config.php 286480 2009-07-29 02:50:02Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -36187,7 +36731,7 @@ if (getenv('PHP_PEAR_SIG_KEYDIR')) {
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -37772,13 +38316,17 @@ class PEAR_Config extends PEAR
      *
      * @param string config key
      * @param string (optional) config layer
+     * @param string (optional) channel (defaults to default channel)
      * @return bool TRUE on success, FALSE on failure
      *
      * @access public
      */
-    function remove($key, $layer = 'user')
+    function remove($key, $layer = 'user', $channel = null)
     {
-        $channel = $this->getDefaultChannel();
+        if ($channel === null) {
+            $channel = $this->getDefaultChannel();
+        }
+
         if ($channel !== 'pear.php.net') {
             if (isset($this->configuration[$layer]['__channels'][$channel][$key])) {
                 unset($this->configuration[$layer]['__channels'][$channel][$key]);
@@ -38032,7 +38580,7 @@ class PEAR_Config extends PEAR
         }
     }
 }
-                                                                                                                                                                                                                                                                                                                                                         PEAR-1.8.0/PEAR/DependencyDB.php                                                                    100664     764     764        57540      100664  11064                                                                                                                                                                                                                                                                                                                                                                      <?php
+                                                                                                                                                                                                                      PEAR-1.9.0/PEAR/DependencyDB.php                                                                    100664     764     764        57256      100664  11071                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_DependencyDB, advanced installed packages dependency database
  *
@@ -38044,7 +38592,7 @@ class PEAR_Config extends PEAR
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: DependencyDB.php,v 1.44 2009/03/21 15:15:26 dufuz Exp $
+ * @version    CVS: $Id: DependencyDB.php 286686 2009-08-02 17:38:57Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -38064,7 +38612,7 @@ $GLOBALS['_PEAR_DEPENDENCYDB_INSTANCE'] = array();
  * @author     Tomas V.V.Cox <cox at idec.net.com>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -38198,18 +38746,19 @@ class PEAR_DependencyDB
     {
         if (!is_file($this->_depdb)) {
             $this->rebuildDB();
-        } else {
-            $depdb = $this->_getDepDB();
-            // Datatype format has been changed, rebuild the Deps DB
-            if ($depdb['_version'] < $this->_version) {
-                $this->rebuildDB();
-            }
+            return;
+        }
 
-            if ($depdb['_version']{0} > $this->_version{0}) {
-                return PEAR::raiseError('Dependency database is version ' .
-                    $depdb['_version'] . ', and we are version ' .
-                    $this->_version . ', cannot continue');
-            }
+        $depdb = $this->_getDepDB();
+        // Datatype format has been changed, rebuild the Deps DB
+        if ($depdb['_version'] < $this->_version) {
+            $this->rebuildDB();
+        }
+
+        if ($depdb['_version']{0} > $this->_version{0}) {
+            return PEAR::raiseError('Dependency database is version ' .
+                $depdb['_version'] . ', and we are version ' .
+                $this->_version . ', cannot continue');
         }
     }
 
@@ -38262,9 +38811,10 @@ class PEAR_DependencyDB
         foreach ($depend as $info) {
             $temp = $this->getDependencies($info);
             foreach ($temp as $dep) {
-                if (isset($dep['dep'], $dep['dep']['channel'], $dep['dep']['name']) &&
-                      strtolower($dep['dep']['channel']) == $channel &&
-                      strtolower($dep['dep']['name']) == $package
+                if (
+                    isset($dep['dep'], $dep['dep']['channel'], $dep['dep']['name']) &&
+                    strtolower($dep['dep']['channel']) == $channel &&
+                    strtolower($dep['dep']['name']) == $package
                 ) {
                     if (!isset($dependencies[$info['channel']])) {
                         $dependencies[$info['channel']] = array();
@@ -38775,13 +39325,6 @@ class PEAR_DependencyDB
                     break;
                 }
             }
-
-            if (!$found) {
-                $data['packages'][$depchannel][$dep['name']][] = array(
-                    'channel' => $channel,
-                    'package' => $package
-                );
-            }
         } else {
             if (!isset($data['packages'])) {
                 $data['packages'] = array();
@@ -38795,13 +39338,17 @@ class PEAR_DependencyDB
                 $data['packages'][$depchannel][$dep['name']] = array();
             }
 
+            $found = false;
+        }
+
+        if (!$found) {
             $data['packages'][$depchannel][$dep['name']][] = array(
                 'channel' => $channel,
                 'package' => $package
             );
         }
     }
-}                                                                                                                                                                PEAR-1.8.0/PEAR/Dependency2.php                                                                     100664     764     764       142623      100664  10755                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                                                                                                                                                                                  PEAR-1.9.0/PEAR/Dependency2.php                                                                     100664     764     764       142517      100664  10760                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Dependency2, advanced dependency validation
  *
@@ -38812,7 +39359,7 @@ class PEAR_DependencyDB
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Dependency2.php,v 1.59 2009/02/24 23:38:22 dufuz Exp $
+ * @version    CVS: $Id: Dependency2.php 286494 2009-07-29 06:57:11Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -38834,7 +39381,7 @@ require_once 'PEAR/Validate.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -39149,7 +39696,8 @@ class PEAR_Dependency2
         }
 
         if (!isset($dep['min']) && !isset($dep['max']) &&
-              !isset($dep['recommended']) && !isset($dep['exclude'])) {
+            !isset($dep['recommended']) && !isset($dep['exclude'])
+        ) {
             if ($loaded) {
                 if (isset($dep['conflicts'])) {
                     if (!isset($this->_options['nodeps']) && !isset($this->_options['force'])) {
@@ -39162,24 +39710,24 @@ class PEAR_Dependency2
                 }
 
                 return true;
-            } else {
-                if (isset($dep['conflicts'])) {
-                    return true;
-                }
+            }
 
-                if ($required) {
-                    if (!isset($this->_options['nodeps']) && !isset($this->_options['force'])) {
-                        return $this->raiseError('%s requires PHP extension "' .
-                            $dep['name'] . '"' . $extra);
-                    }
+            if (isset($dep['conflicts'])) {
+                return true;
+            }
 
-                    return $this->warning('warning: %s requires PHP extension "' .
+            if ($required) {
+                if (!isset($this->_options['nodeps']) && !isset($this->_options['force'])) {
+                    return $this->raiseError('%s requires PHP extension "' .
                         $dep['name'] . '"' . $extra);
                 }
 
-                return $this->warning('%s can optionally use PHP extension "' .
+                return $this->warning('warning: %s requires PHP extension "' .
                     $dep['name'] . '"' . $extra);
             }
+
+            return $this->warning('%s can optionally use PHP extension "' .
+                $dep['name'] . '"' . $extra);
         }
 
         if (!$loaded) {
@@ -39343,7 +39891,7 @@ class PEAR_Dependency2
      */
     function getPEARVersion()
     {
-        return '1.8.0';
+        return '1.9.0';
     }
 
     function validatePearinstallerDependency($dep)
@@ -40157,7 +40705,7 @@ class PEAR_Dependency2
         return array(sprintf($msg, $this->_registry->parsedPackageNameToString(
             $this->_currentPackage, true)));
     }
-}                                                                                                             PEAR-1.8.0/PEAR/Downloader.php                                                                      100664     764     764       202344      100664  10710                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                 PEAR-1.9.0/PEAR/Downloader.php                                                                      100664     764     764       201412      100664  10704                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Downloader, the PEAR Installer's download utility class
  *
@@ -40171,7 +40719,7 @@ class PEAR_Dependency2
  * @author     Martin Jansen <mj at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Downloader.php,v 1.159 2009/03/08 04:01:08 dufuz Exp $
+ * @version    CVS: $Id: Downloader.php 287109 2009-08-11 18:50:30Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.3.0
  */
@@ -40198,7 +40746,7 @@ define('PEAR_INSTALLER_ERROR_NO_PREF_STATE', 2);
  * @author     Martin Jansen <mj at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.3.0
  */
@@ -40298,7 +40846,6 @@ class PEAR_Downloader extends PEAR_Common
      * @var string
      */
     var $_downloadDir;
-    // {{{ PEAR_Downloader()
 
     /**
      * @param PEAR_Frontend_*
@@ -40466,7 +41013,8 @@ class PEAR_Downloader extends PEAR_Common
                     }
 
                     if ($params[$i] && !isset($channelschecked[$params[$i]->getChannel()]) &&
-                          !isset($this->_options['offline'])) {
+                          !isset($this->_options['offline'])
+                    ) {
                         $channelschecked[$params[$i]->getChannel()] = true;
                         PEAR::staticPushErrorHandling(PEAR_ERROR_RETURN);
                         if (!class_exists('System')) {
@@ -40484,10 +41032,9 @@ class PEAR_Downloader extends PEAR_Common
                             break;
                         }
 
-                        $mirror = $this->config->get('preferred_mirror', null,
-                                                     $params[$i]->getChannel());
-                        $a = $this->downloadHttp('http://' . $mirror .
-                            '/channel.xml', $this->ui, $dir, null, $curchannel->lastModified());
+                        $mirror = $this->config->get('preferred_mirror', null, $params[$i]->getChannel());
+                        $url    = 'http://' . $mirror . '/channel.xml';
+                        $a = $this->downloadHttp($url, $this->ui, $dir, null, $curchannel->lastModified());
 
                         PEAR::staticPopErrorHandling();
                         if (PEAR::isError($a) || !$a) {
@@ -40916,8 +41463,6 @@ class PEAR_Downloader extends PEAR_Common
         $this->_downloadDir = $dir;
     }
 
-    // }}}
-    // {{{ configSet()
     function configSet($key, $value, $layer = 'user', $channel = false)
     {
         $this->config->set($key, $value, $layer, $channel);
@@ -40928,8 +41473,6 @@ class PEAR_Downloader extends PEAR_Common
         }
     }
 
-    // }}}
-    // {{{ setOptions()
     function setOptions($options)
     {
         $this->_options = $options;
@@ -40942,8 +41485,6 @@ class PEAR_Downloader extends PEAR_Common
         return $this->_options;
     }
 
-    // }}}
-
     /**
      * For simpler unit-testing
      * @param PEAR_Config
@@ -40959,8 +41500,6 @@ class PEAR_Downloader extends PEAR_Common
         return $a;
     }
 
-    // {{{ _getPackageDownloadUrl()
-
     /**
      * @param array output of {@link parsePackageName()}
      * @access private
@@ -41007,7 +41546,7 @@ class PEAR_Downloader extends PEAR_Common
                !($base = $chan->getBaseURL('REST1.0', $preferred_mirror))
               )
         ) {
-            return $this->raiseError($parr['channel'] . ' is using a unsupported protocal - This should never happen.');
+            return $this->raiseError($parr['channel'] . ' is using a unsupported protocol - This should never happen.');
         }
 
         if ($base2) {
@@ -41017,14 +41556,15 @@ class PEAR_Downloader extends PEAR_Common
             $rest = &$this->config->getREST('1.0', $this->_options);
         }
 
+        $downloadVersion = false;
         if (!isset($parr['version']) && !isset($parr['state']) && $version
               && !PEAR::isError($version)
-              && !isset($this->_options['downloadonly'])) {
-            $url = $rest->getDownloadURL($base, $parr, $state, $version, $chan->getName());
-        } else {
-            $url = $rest->getDownloadURL($base, $parr, $state, false, $chan->getName());
+              && !isset($this->_options['downloadonly'])
+        ) {
+            $downloadVersion = $version;
         }
 
+        $url = $rest->getDownloadURL($base, $parr, $state, $downloadVersion, $chan->getName());
         if (PEAR::isError($url)) {
             $this->configSet('default_channel', $curchannel);
             return $url;
@@ -41095,8 +41635,6 @@ class PEAR_Downloader extends PEAR_Common
 
         return $url;
     }
-    // }}}
-    // {{{ getDepPackageDownloadUrl()
 
     /**
      * @param array dependency array
@@ -41226,10 +41764,8 @@ class PEAR_Downloader extends PEAR_Common
             return $url;
         }
 
-        return $this->raiseError($parr['channel'] . ' is using a unsupported protocal - This should never happen.');
+        return $this->raiseError($parr['channel'] . ' is using a unsupported protocol - This should never happen.');
     }
-    // }}}
-    // {{{ getPackageDownloadUrl()
 
     /**
      * @deprecated in favor of _getPackageDownloadUrl
@@ -41254,9 +41790,6 @@ class PEAR_Downloader extends PEAR_Common
         return $package;
     }
 
-    // }}}
-    // {{{ getDownloadedPackages()
-
     /**
      * Retrieve a list of downloaded packages after a call to {@link download()}.
      *
@@ -41271,9 +41804,6 @@ class PEAR_Downloader extends PEAR_Common
         return $ret;
     }
 
-    // }}}
-    // {{{ _downloadCallback()
-
     function _downloadCallback($msg, $params = null)
     {
         switch ($msg) {
@@ -41306,9 +41836,6 @@ class PEAR_Downloader extends PEAR_Common
             $this->ui->_downloadCallback($msg, $params);
     }
 
-    // }}}
-    // {{{ _prependPath($path, $prepend)
-
     function _prependPath($path, $prepend)
     {
         if (strlen($prepend) > 0) {
@@ -41325,8 +41852,6 @@ class PEAR_Downloader extends PEAR_Common
         }
         return $path;
     }
-    // }}}
-    // {{{ pushError($errmsg, $code)
 
     /**
      * @param string
@@ -41337,9 +41862,6 @@ class PEAR_Downloader extends PEAR_Common
         array_push($this->_errorStack, array($errmsg, $code));
     }
 
-    // }}}
-    // {{{ getErrorMsgs()
-
     function getErrorMsgs()
     {
         $msgs = array();
@@ -41351,10 +41873,10 @@ class PEAR_Downloader extends PEAR_Common
         return $msgs;
     }
 
-    // }}}
-
     /**
      * for BC
+     *
+     * @deprecated
      */
     function sortPkgDeps(&$packages, $uninstall = false)
     {
@@ -41513,7 +42035,7 @@ class PEAR_Downloader extends PEAR_Common
 
         $installOrder = Structures_Graph_Manipulator_TopologicalSorter::sort($depgraph);
         $ret = array();
-        for ($i = 0; $i < count($installOrder); $i++) {
+        for ($i = 0, $count = count($installOrder); $i < $count; $i++) {
             foreach ($installOrder[$i] as $index => $sortedpackage) {
                 $data = &$installOrder[$i][$index]->getData();
                 $ret[] = &$nodes[$reg->parsedPackageNameToString(
@@ -41548,6 +42070,7 @@ class PEAR_Downloader extends PEAR_Common
                         if (count($deplinks[$dep]) == 0) {
                             unset($deplinks[$dep]);
                         }
+
                         continue 3;
                     }
                 }
@@ -41562,25 +42085,30 @@ class PEAR_Downloader extends PEAR_Common
             $visited = array();
             return;
         }
+
         // this happens when a parent has a dep cycle on another dependency
         // but the child is not part of the cycle
         if (isset($visited[$dep])) {
             return false;
         }
+
         $visited[$dep] = 1;
         if ($test == $dep) {
             return true;
         }
+
         if (isset($deplinks[$dep])) {
             if (in_array($test, array_keys($deplinks[$dep]), true)) {
                 return true;
             }
+
             foreach ($deplinks[$dep] as $parent => $unused) {
                 if ($this->_testCycle($test, $deplinks, $parent)) {
                     return true;
                 }
             }
         }
+
         return false;
     }
 
@@ -41817,7 +42345,7 @@ class PEAR_Downloader extends PEAR_Common
         }
 
         $request .= $ifmodifiedsince .
-            "User-Agent: PEAR/1.8.0/PHP/" . PHP_VERSION . "\r\n";
+            "User-Agent: PEAR/1.9.0/PHP/" . PHP_VERSION . "\r\n";
 
         if (isset($this)) { // only pass in authentication for non-static calls
             $username = $config->get('username', null, $channel);
@@ -41914,6 +42442,7 @@ class PEAR_Downloader extends PEAR_Common
                 return PEAR::raiseError("$dest_file: write failed ($php_errormsg)");
             }
         }
+
         fclose($fp);
         fclose($wp);
         if ($callback) {
@@ -41924,6 +42453,7 @@ class PEAR_Downloader extends PEAR_Common
             if (isset($headers['etag'])) {
                 $lastmodified = array('ETag' => $headers['etag']);
             }
+
             if (isset($headers['last-modified'])) {
                 if (is_array($lastmodified)) {
                     $lastmodified['Last-Modified'] = $headers['last-modified'];
@@ -41936,1615 +42466,1615 @@ class PEAR_Downloader extends PEAR_Common
         return $dest_file;
     }
 }
-// }}}                                                                                                                                                                                                                                                                                            PEAR-1.8.0/PEAR/ErrorStack.php                                                                      100664     764     764       104210      100664  10662                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * Error Stack Implementation
- * 
- * This is an incredibly simple implementation of a very complex error handling
- * facility.  It contains the ability
- * to track multiple errors from multiple packages simultaneously.  In addition,
- * it can track errors of many levels, save data along with the error, context
- * information such as the exact file, line number, class and function that
- * generated the error, and if necessary, it can raise a traditional PEAR_Error.
- * It has built-in support for PEAR::Log, to log errors as they occur
- * 
- * Since version 0.2alpha, it is also possible to selectively ignore errors,
- * through the use of an error callback, see {@link pushCallback()}
- * 
- * Since version 0.3alpha, it is possible to specify the exception class
- * returned from {@link push()}
- *
- * Since version PEAR1.3.2, ErrorStack no longer instantiates an exception class.  This can
- * still be done quite handily in an error callback or by manipulating the returned array
- * @category   Debugging
- * @package    PEAR_ErrorStack
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  2004-2008 Greg Beaver
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: ErrorStack.php,v 1.29 2009/02/24 23:38:22 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR_ErrorStack
- */
-
-/**
- * Singleton storage
- * 
- * Format:
- * <pre>
- * array(
- *  'package1' => PEAR_ErrorStack object,
- *  'package2' => PEAR_ErrorStack object,
- *  ...
- * )
- * </pre>
- * @access private
- * @global array $GLOBALS['_PEAR_ERRORSTACK_SINGLETON']
- */
-$GLOBALS['_PEAR_ERRORSTACK_SINGLETON'] = array();
-
-/**
- * Global error callback (default)
- * 
- * This is only used if set to non-false.  * is the default callback for
- * all packages, whereas specific packages may set a default callback
- * for all instances, regardless of whether they are a singleton or not.
- *
- * To exclude non-singletons, only set the local callback for the singleton
- * @see PEAR_ErrorStack::setDefaultCallback()
- * @access private
- * @global array $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK']
- */
-$GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'] = array(
-    '*' => false,
-);
-
-/**
- * Global Log object (default)
- * 
- * This is only used if set to non-false.  Use to set a default log object for
- * all stacks, regardless of instantiation order or location
- * @see PEAR_ErrorStack::setDefaultLogger()
- * @access private
- * @global array $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER']
- */
-$GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'] = false;
-
-/**
- * Global Overriding Callback
- * 
- * This callback will override any error callbacks that specific loggers have set.
- * Use with EXTREME caution
- * @see PEAR_ErrorStack::staticPushCallback()
- * @access private
- * @global array $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER']
- */
-$GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'] = array();
-
-/**#@+
- * One of four possible return values from the error Callback
- * @see PEAR_ErrorStack::_errorCallback()
- */
-/**
- * If this is returned, then the error will be both pushed onto the stack
- * and logged.
- */
-define('PEAR_ERRORSTACK_PUSHANDLOG', 1);
-/**
- * If this is returned, then the error will only be pushed onto the stack,
- * and not logged.
- */
-define('PEAR_ERRORSTACK_PUSH', 2);
-/**
- * If this is returned, then the error will only be logged, but not pushed
- * onto the error stack.
- */
-define('PEAR_ERRORSTACK_LOG', 3);
-/**
- * If this is returned, then the error is completely ignored.
- */
-define('PEAR_ERRORSTACK_IGNORE', 4);
-/**
- * If this is returned, then the error is logged and die() is called.
- */
-define('PEAR_ERRORSTACK_DIE', 5);
-/**#@-*/
-
-/**
- * Error code for an attempt to instantiate a non-class as a PEAR_ErrorStack in
- * the singleton method.
- */
-define('PEAR_ERRORSTACK_ERR_NONCLASS', 1);
-
-/**
- * Error code for an attempt to pass an object into {@link PEAR_ErrorStack::getMessage()}
- * that has no __toString() method
- */
-define('PEAR_ERRORSTACK_ERR_OBJTOSTRING', 2);
-/**
- * Error Stack Implementation
- *
- * Usage:
- * <code>
- * // global error stack
- * $global_stack = &PEAR_ErrorStack::singleton('MyPackage');
- * // local error stack
- * $local_stack = new PEAR_ErrorStack('MyPackage');
- * </code>
- * @author     Greg Beaver <cellog at php.net>
- * @version    1.8.0
- * @package    PEAR_ErrorStack
- * @category   Debugging
- * @copyright  2004-2008 Greg Beaver
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: ErrorStack.php,v 1.29 2009/02/24 23:38:22 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR_ErrorStack
- */
-class PEAR_ErrorStack {
-    /**
-     * Errors are stored in the order that they are pushed on the stack.
-     * @since 0.4alpha Errors are no longer organized by error level.
-     * This renders pop() nearly unusable, and levels could be more easily
-     * handled in a callback anyway
-     * @var array
-     * @access private
-     */
-    var $_errors = array();
-
-    /**
-     * Storage of errors by level.
-     *
-     * Allows easy retrieval and deletion of only errors from a particular level
-     * @since PEAR 1.4.0dev
-     * @var array
-     * @access private
-     */
-    var $_errorsByLevel = array();
-
-    /**
-     * Package name this error stack represents
-     * @var string
-     * @access protected
-     */
-    var $_package;
-    
-    /**
-     * Determines whether a PEAR_Error is thrown upon every error addition
-     * @var boolean
-     * @access private
-     */
-    var $_compat = false;
-    
-    /**
-     * If set to a valid callback, this will be used to generate the error
-     * message from the error code, otherwise the message passed in will be
-     * used
-     * @var false|string|array
-     * @access private
-     */
-    var $_msgCallback = false;
-    
-    /**
-     * If set to a valid callback, this will be used to generate the error
-     * context for an error.  For PHP-related errors, this will be a file
-     * and line number as retrieved from debug_backtrace(), but can be
-     * customized for other purposes.  The error might actually be in a separate
-     * configuration file, or in a database query.
-     * @var false|string|array
-     * @access protected
-     */
-    var $_contextCallback = false;
-    
-    /**
-     * If set to a valid callback, this will be called every time an error
-     * is pushed onto the stack.  The return value will be used to determine
-     * whether to allow an error to be pushed or logged.
-     * 
-     * The return value must be one an PEAR_ERRORSTACK_* constant
-     * @see PEAR_ERRORSTACK_PUSHANDLOG, PEAR_ERRORSTACK_PUSH, PEAR_ERRORSTACK_LOG
-     * @var false|string|array
-     * @access protected
-     */
-    var $_errorCallback = array();
-    
-    /**
-     * PEAR::Log object for logging errors
-     * @var false|Log
-     * @access protected
-     */
-    var $_logger = false;
-    
-    /**
-     * Error messages - designed to be overridden
-     * @var array
-     * @abstract
-     */
-    var $_errorMsgs = array();
-    
-    /**
-     * Set up a new error stack
-     * 
-     * @param string   $package name of the package this error stack represents
-     * @param callback $msgCallback callback used for error message generation
-     * @param callback $contextCallback callback used for context generation,
-     *                 defaults to {@link getFileLine()}
-     * @param boolean  $throwPEAR_Error
-     */
-    function PEAR_ErrorStack($package, $msgCallback = false, $contextCallback = false,
-                         $throwPEAR_Error = false)
-    {
-        $this->_package = $package;
-        $this->setMessageCallback($msgCallback);
-        $this->setContextCallback($contextCallback);
-        $this->_compat = $throwPEAR_Error;
-    }
-    
-    /**
-     * Return a single error stack for this package.
-     * 
-     * Note that all parameters are ignored if the stack for package $package
-     * has already been instantiated
-     * @param string   $package name of the package this error stack represents
-     * @param callback $msgCallback callback used for error message generation
-     * @param callback $contextCallback callback used for context generation,
-     *                 defaults to {@link getFileLine()}
-     * @param boolean  $throwPEAR_Error
-     * @param string   $stackClass class to instantiate
-     * @static
-     * @return PEAR_ErrorStack
-     */
-    function &singleton($package, $msgCallback = false, $contextCallback = false,
-                         $throwPEAR_Error = false, $stackClass = 'PEAR_ErrorStack')
-    {
-        if (isset($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package])) {
-            return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package];
-        }
-        if (!class_exists($stackClass)) {
-            if (function_exists('debug_backtrace')) {
-                $trace = debug_backtrace();
-            }
-            PEAR_ErrorStack::staticPush('PEAR_ErrorStack', PEAR_ERRORSTACK_ERR_NONCLASS,
-                'exception', array('stackclass' => $stackClass),
-                'stack class "%stackclass%" is not a valid class name (should be like PEAR_ErrorStack)',
-                false, $trace);
-        }
-        $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package] =
-            new $stackClass($package, $msgCallback, $contextCallback, $throwPEAR_Error);
-
-        return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package];
-    }
-
-    /**
-     * Internal error handler for PEAR_ErrorStack class
-     * 
-     * Dies if the error is an exception (and would have died anyway)
-     * @access private
-     */
-    function _handleError($err)
-    {
-        if ($err['level'] == 'exception') {
-            $message = $err['message'];
-            if (isset($_SERVER['REQUEST_URI'])) {
-                echo '<br />';
-            } else {
-                echo "\n";
-            }
-            var_dump($err['context']);
-            die($message);
-        }
-    }
-    
-    /**
-     * Set up a PEAR::Log object for all error stacks that don't have one
-     * @param Log $log 
-     * @static
-     */
-    function setDefaultLogger(&$log)
-    {
-        if (is_object($log) && method_exists($log, 'log') ) {
-            $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'] = &$log;
-        } elseif (is_callable($log)) {
-            $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'] = &$log;
-	}
-    }
-    
-    /**
-     * Set up a PEAR::Log object for this error stack
-     * @param Log $log 
-     */
-    function setLogger(&$log)
-    {
-        if (is_object($log) && method_exists($log, 'log') ) {
-            $this->_logger = &$log;
-        } elseif (is_callable($log)) {
-            $this->_logger = &$log;
-        }
-    }
-    
-    /**
-     * Set an error code => error message mapping callback
-     * 
-     * This method sets the callback that can be used to generate error
-     * messages for any instance
-     * @param array|string Callback function/method
-     */
-    function setMessageCallback($msgCallback)
-    {
-        if (!$msgCallback) {
-            $this->_msgCallback = array(&$this, 'getErrorMessage');
-        } else {
-            if (is_callable($msgCallback)) {
-                $this->_msgCallback = $msgCallback;
-            }
-        }
-    }
-    
-    /**
-     * Get an error code => error message mapping callback
-     * 
-     * This method returns the current callback that can be used to generate error
-     * messages
-     * @return array|string|false Callback function/method or false if none
-     */
-    function getMessageCallback()
-    {
-        return $this->_msgCallback;
-    }
-    
-    /**
-     * Sets a default callback to be used by all error stacks
-     * 
-     * This method sets the callback that can be used to generate error
-     * messages for a singleton
-     * @param array|string Callback function/method
-     * @param string Package name, or false for all packages
-     * @static
-     */
-    function setDefaultCallback($callback = false, $package = false)
-    {
-        if (!is_callable($callback)) {
-            $callback = false;
-        }
-        $package = $package ? $package : '*';
-        $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'][$package] = $callback;
-    }
-    
-    /**
-     * Set a callback that generates context information (location of error) for an error stack
-     * 
-     * This method sets the callback that can be used to generate context
-     * information for an error.  Passing in NULL will disable context generation
-     * and remove the expensive call to debug_backtrace()
-     * @param array|string|null Callback function/method
-     */
-    function setContextCallback($contextCallback)
-    {
-        if ($contextCallback === null) {
-            return $this->_contextCallback = false;
-        }
-        if (!$contextCallback) {
-            $this->_contextCallback = array(&$this, 'getFileLine');
-        } else {
-            if (is_callable($contextCallback)) {
-                $this->_contextCallback = $contextCallback;
-            }
-        }
-    }
-    
-    /**
-     * Set an error Callback
-     * If set to a valid callback, this will be called every time an error
-     * is pushed onto the stack.  The return value will be used to determine
-     * whether to allow an error to be pushed or logged.
-     * 
-     * The return value must be one of the ERRORSTACK_* constants.
-     * 
-     * This functionality can be used to emulate PEAR's pushErrorHandling, and
-     * the PEAR_ERROR_CALLBACK mode, without affecting the integrity of
-     * the error stack or logging
-     * @see PEAR_ERRORSTACK_PUSHANDLOG, PEAR_ERRORSTACK_PUSH, PEAR_ERRORSTACK_LOG
-     * @see popCallback()
-     * @param string|array $cb
-     */
-    function pushCallback($cb)
-    {
-        array_push($this->_errorCallback, $cb);
-    }
-    
-    /**
-     * Remove a callback from the error callback stack
-     * @see pushCallback()
-     * @return array|string|false
-     */
-    function popCallback()
-    {
-        if (!count($this->_errorCallback)) {
-            return false;
-        }
-        return array_pop($this->_errorCallback);
-    }
-    
-    /**
-     * Set a temporary overriding error callback for every package error stack
-     *
-     * Use this to temporarily disable all existing callbacks (can be used
-     * to emulate the @ operator, for instance)
-     * @see PEAR_ERRORSTACK_PUSHANDLOG, PEAR_ERRORSTACK_PUSH, PEAR_ERRORSTACK_LOG
-     * @see staticPopCallback(), pushCallback()
-     * @param string|array $cb
-     * @static
-     */
-    function staticPushCallback($cb)
-    {
-        array_push($GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'], $cb);
-    }
-    
-    /**
-     * Remove a temporary overriding error callback
-     * @see staticPushCallback()
-     * @return array|string|false
-     * @static
-     */
-    function staticPopCallback()
-    {
-        $ret = array_pop($GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK']);
-        if (!is_array($GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'])) {
-            $GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'] = array();
-        }
-        return $ret;
-    }
-    
-    /**
-     * Add an error to the stack
-     * 
-     * If the message generator exists, it is called with 2 parameters.
-     *  - the current Error Stack object
-     *  - an array that is in the same format as an error.  Available indices
-     *    are 'code', 'package', 'time', 'params', 'level', and 'context'
-     * 
-     * Next, if the error should contain context information, this is
-     * handled by the context grabbing method.
-     * Finally, the error is pushed onto the proper error stack
-     * @param int    $code      Package-specific error code
-     * @param string $level     Error level.  This is NOT spell-checked
-     * @param array  $params    associative array of error parameters
-     * @param string $msg       Error message, or a portion of it if the message
-     *                          is to be generated
-     * @param array  $repackage If this error re-packages an error pushed by
-     *                          another package, place the array returned from
-     *                          {@link pop()} in this parameter
-     * @param array  $backtrace Protected parameter: use this to pass in the
-     *                          {@link debug_backtrace()} that should be used
-     *                          to find error context
-     * @return PEAR_Error|array if compatibility mode is on, a PEAR_Error is also
-     * thrown.  If a PEAR_Error is returned, the userinfo
-     * property is set to the following array:
-     * 
-     * <code>
-     * array(
-     *    'code' => $code,
-     *    'params' => $params,
-     *    'package' => $this->_package,
-     *    'level' => $level,
-     *    'time' => time(),
-     *    'context' => $context,
-     *    'message' => $msg,
-     * //['repackage' => $err] repackaged error array/Exception class
-     * );
-     * </code>
-     * 
-     * Normally, the previous array is returned.
-     */
-    function push($code, $level = 'error', $params = array(), $msg = false,
-                  $repackage = false, $backtrace = false)
-    {
-        $context = false;
-        // grab error context
-        if ($this->_contextCallback) {
-            if (!$backtrace) {
-                $backtrace = debug_backtrace();
-            }
-            $context = call_user_func($this->_contextCallback, $code, $params, $backtrace);
-        }
-        
-        // save error
-        $time = explode(' ', microtime());
-        $time = $time[1] + $time[0];
-        $err = array(
-                'code' => $code,
-                'params' => $params,
-                'package' => $this->_package,
-                'level' => $level,
-                'time' => $time,
-                'context' => $context,
-                'message' => $msg,
-               );
-
-        if ($repackage) {
-            $err['repackage'] = $repackage;
-        }
-
-        // set up the error message, if necessary
-        if ($this->_msgCallback) {
-            $msg = call_user_func_array($this->_msgCallback,
-                                        array(&$this, $err));
-            $err['message'] = $msg;
-        }        
-        $push = $log = true;
-        $die = false;
-        // try the overriding callback first
-        $callback = $this->staticPopCallback();
-        if ($callback) {
-            $this->staticPushCallback($callback);
-        }
-        if (!is_callable($callback)) {
-            // try the local callback next
-            $callback = $this->popCallback();
-            if (is_callable($callback)) {
-                $this->pushCallback($callback);
-            } else {
-                // try the default callback
-                $callback = isset($GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'][$this->_package]) ?
-                    $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'][$this->_package] :
-                    $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK']['*'];
-            }
-        }
-        if (is_callable($callback)) {
-            switch(call_user_func($callback, $err)){
-            	case PEAR_ERRORSTACK_IGNORE: 
-            		return $err;
-        		break;
-            	case PEAR_ERRORSTACK_PUSH: 
-            		$log = false;
-        		break;
-            	case PEAR_ERRORSTACK_LOG: 
-            		$push = false;
-        		break;
-            	case PEAR_ERRORSTACK_DIE: 
-            		$die = true;
-        		break;
-                // anything else returned has the same effect as pushandlog
-            }
-        }
-        if ($push) {
-            array_unshift($this->_errors, $err);
-            if (!isset($this->_errorsByLevel[$err['level']])) {
-                $this->_errorsByLevel[$err['level']] = array();
-            }
-            $this->_errorsByLevel[$err['level']][] = &$this->_errors[0];
-        }
-        if ($log) {
-            if ($this->_logger || $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER']) {
-                $this->_log($err);
-            }
-        }
-        if ($die) {
-            die();
-        }
-        if ($this->_compat && $push) {
-            return $this->raiseError($msg, $code, null, null, $err);
-        }
-        return $err;
-    }
-    
-    /**
-     * Static version of {@link push()}
-     * 
-     * @param string $package   Package name this error belongs to
-     * @param int    $code      Package-specific error code
-     * @param string $level     Error level.  This is NOT spell-checked
-     * @param array  $params    associative array of error parameters
-     * @param string $msg       Error message, or a portion of it if the message
-     *                          is to be generated
-     * @param array  $repackage If this error re-packages an error pushed by
-     *                          another package, place the array returned from
-     *                          {@link pop()} in this parameter
-     * @param array  $backtrace Protected parameter: use this to pass in the
-     *                          {@link debug_backtrace()} that should be used
-     *                          to find error context
-     * @return PEAR_Error|array if compatibility mode is on, a PEAR_Error is also
-     *                          thrown.  see docs for {@link push()}
-     * @static
-     */
-    function staticPush($package, $code, $level = 'error', $params = array(),
-                        $msg = false, $repackage = false, $backtrace = false)
-    {
-        $s = &PEAR_ErrorStack::singleton($package);
-        if ($s->_contextCallback) {
-            if (!$backtrace) {
-                if (function_exists('debug_backtrace')) {
-                    $backtrace = debug_backtrace();
-                }
-            }
-        }
-        return $s->push($code, $level, $params, $msg, $repackage, $backtrace);
-    }
-    
-    /**
-     * Log an error using PEAR::Log
-     * @param array $err Error array
-     * @param array $levels Error level => Log constant map
-     * @access protected
-     */
-    function _log($err)
-    {
-        if ($this->_logger) {
-            $logger = &$this->_logger;
-        } else {
-            $logger = &$GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'];
-        }
-        if (is_a($logger, 'Log')) {
-            $levels = array(
-                'exception' => PEAR_LOG_CRIT,
-                'alert' => PEAR_LOG_ALERT,
-                'critical' => PEAR_LOG_CRIT,
-                'error' => PEAR_LOG_ERR,
-                'warning' => PEAR_LOG_WARNING,
-                'notice' => PEAR_LOG_NOTICE,
-                'info' => PEAR_LOG_INFO,
-                'debug' => PEAR_LOG_DEBUG);
-            if (isset($levels[$err['level']])) {
-                $level = $levels[$err['level']];
-            } else {
-                $level = PEAR_LOG_INFO;
-            }
-            $logger->log($err['message'], $level, $err);
-        } else { // support non-standard logs
-            call_user_func($logger, $err);
-        }
-    }
-
-    
-    /**
-     * Pop an error off of the error stack
-     * 
-     * @return false|array
-     * @since 0.4alpha it is no longer possible to specify a specific error
-     * level to return - the last error pushed will be returned, instead
-     */
-    function pop()
-    {
-        $err = @array_shift($this->_errors);
-        if (!is_null($err)) {
-            @array_pop($this->_errorsByLevel[$err['level']]);
-            if (!count($this->_errorsByLevel[$err['level']])) {
-                unset($this->_errorsByLevel[$err['level']]);
-            }
-        }
-        return $err;
-    }
-
-    /**
-     * Pop an error off of the error stack, static method
-     *
-     * @param string package name
-     * @return boolean
-     * @since PEAR1.5.0a1
-     */
-    function staticPop($package)
-    {
-        if ($package) {
-            if (!isset($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package])) {
-                return false;
-            }
-            return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package]->pop();
-        }
-    }
-
-    /**
-     * Determine whether there are any errors on the stack
-     * @param string|array Level name.  Use to determine if any errors
-     * of level (string), or levels (array) have been pushed
-     * @return boolean
-     */
-    function hasErrors($level = false)
-    {
-        if ($level) {
-            return isset($this->_errorsByLevel[$level]);
-        }
-        return count($this->_errors);
-    }
-    
-    /**
-     * Retrieve all errors since last purge
-     * 
-     * @param boolean set in order to empty the error stack
-     * @param string level name, to return only errors of a particular severity
-     * @return array
-     */
-    function getErrors($purge = false, $level = false)
-    {
-        if (!$purge) {
-            if ($level) {
-                if (!isset($this->_errorsByLevel[$level])) {
-                    return array();
-                } else {
-                    return $this->_errorsByLevel[$level];
-                }
-            } else {
-                return $this->_errors;
-            }
-        }
-        if ($level) {
-            $ret = $this->_errorsByLevel[$level];
-            foreach ($this->_errorsByLevel[$level] as $i => $unused) {
-                // entries are references to the $_errors array
-                $this->_errorsByLevel[$level][$i] = false;
-            }
-            // array_filter removes all entries === false
-            $this->_errors = array_filter($this->_errors);
-            unset($this->_errorsByLevel[$level]);
-            return $ret;
-        }
-        $ret = $this->_errors;
-        $this->_errors = array();
-        $this->_errorsByLevel = array();
-        return $ret;
-    }
-    
-    /**
-     * Determine whether there are any errors on a single error stack, or on any error stack
-     *
-     * The optional parameter can be used to test the existence of any errors without the need of
-     * singleton instantiation
-     * @param string|false Package name to check for errors
-     * @param string Level name to check for a particular severity
-     * @return boolean
-     * @static
-     */
-    function staticHasErrors($package = false, $level = false)
-    {
-        if ($package) {
-            if (!isset($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package])) {
-                return false;
-            }
-            return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package]->hasErrors($level);
-        }
-        foreach ($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'] as $package => $obj) {
-            if ($obj->hasErrors($level)) {
-                return true;
-            }
-        }
-        return false;
-    }
-    
-    /**
-     * Get a list of all errors since last purge, organized by package
-     * @since PEAR 1.4.0dev BC break! $level is now in the place $merge used to be
-     * @param boolean $purge Set to purge the error stack of existing errors
-     * @param string  $level Set to a level name in order to retrieve only errors of a particular level
-     * @param boolean $merge Set to return a flat array, not organized by package
-     * @param array   $sortfunc Function used to sort a merged array - default
-     *        sorts by time, and should be good for most cases
-     * @static
-     * @return array 
-     */
-    function staticGetErrors($purge = false, $level = false, $merge = false,
-                             $sortfunc = array('PEAR_ErrorStack', '_sortErrors'))
-    {
-        $ret = array();
-        if (!is_callable($sortfunc)) {
-            $sortfunc = array('PEAR_ErrorStack', '_sortErrors');
-        }
-        foreach ($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'] as $package => $obj) {
-            $test = $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package]->getErrors($purge, $level);
-            if ($test) {
-                if ($merge) {
-                    $ret = array_merge($ret, $test);
-                } else {
-                    $ret[$package] = $test;
-                }
-            }
-        }
-        if ($merge) {
-            usort($ret, $sortfunc);
-        }
-        return $ret;
-    }
-    
-    /**
-     * Error sorting function, sorts by time
-     * @access private
-     */
-    function _sortErrors($a, $b)
-    {
-        if ($a['time'] == $b['time']) {
-            return 0;
-        }
-        if ($a['time'] < $b['time']) {
-            return 1;
-        }
-        return -1;
-    }
-
-    /**
-     * Standard file/line number/function/class context callback
-     *
-     * This function uses a backtrace generated from {@link debug_backtrace()}
-     * and so will not work at all in PHP < 4.3.0.  The frame should
-     * reference the frame that contains the source of the error.
-     * @return array|false either array('file' => file, 'line' => line,
-     *         'function' => function name, 'class' => class name) or
-     *         if this doesn't work, then false
-     * @param unused
-     * @param integer backtrace frame.
-     * @param array Results of debug_backtrace()
-     * @static
-     */
-    function getFileLine($code, $params, $backtrace = null)
-    {
-        if ($backtrace === null) {
-            return false;
-        }
-        $frame = 0;
-        $functionframe = 1;
-        if (!isset($backtrace[1])) {
-            $functionframe = 0;
-        } else {
-            while (isset($backtrace[$functionframe]['function']) &&
-                  $backtrace[$functionframe]['function'] == 'eval' &&
-                  isset($backtrace[$functionframe + 1])) {
-                $functionframe++;
-            }
-        }
-        if (isset($backtrace[$frame])) {
-            if (!isset($backtrace[$frame]['file'])) {
-                $frame++;
-            }
-            $funcbacktrace = $backtrace[$functionframe];
-            $filebacktrace = $backtrace[$frame];
-            $ret = array('file' => $filebacktrace['file'],
-                         'line' => $filebacktrace['line']);
-            // rearrange for eval'd code or create function errors
-            if (strpos($filebacktrace['file'], '(') && 
-            	  preg_match(';^(.*?)\((\d+)\) : (.*?)\\z;', $filebacktrace['file'],
-                  $matches)) {
-                $ret['file'] = $matches[1];
-                $ret['line'] = $matches[2] + 0;
-            }
-            if (isset($funcbacktrace['function']) && isset($backtrace[1])) {
-                if ($funcbacktrace['function'] != 'eval') {
-                    if ($funcbacktrace['function'] == '__lambda_func') {
-                        $ret['function'] = 'create_function() code';
-                    } else {
-                        $ret['function'] = $funcbacktrace['function'];
-                    }
-                }
-            }
-            if (isset($funcbacktrace['class']) && isset($backtrace[1])) {
-                $ret['class'] = $funcbacktrace['class'];
-            }
-            return $ret;
-        }
-        return false;
-    }
-    
-    /**
-     * Standard error message generation callback
-     * 
-     * This method may also be called by a custom error message generator
-     * to fill in template values from the params array, simply
-     * set the third parameter to the error message template string to use
-     * 
-     * The special variable %__msg% is reserved: use it only to specify
-     * where a message passed in by the user should be placed in the template,
-     * like so:
-     * 
-     * Error message: %msg% - internal error
-     * 
-     * If the message passed like so:
-     * 
-     * <code>
-     * $stack->push(ERROR_CODE, 'error', array(), 'server error 500');
-     * </code>
-     * 
-     * The returned error message will be "Error message: server error 500 -
-     * internal error"
-     * @param PEAR_ErrorStack
-     * @param array
-     * @param string|false Pre-generated error message template
-     * @static
-     * @return string
-     */
-    function getErrorMessage(&$stack, $err, $template = false)
-    {
-        if ($template) {
-            $mainmsg = $template;
-        } else {
-            $mainmsg = $stack->getErrorMessageTemplate($err['code']);
-        }
-        $mainmsg = str_replace('%__msg%', $err['message'], $mainmsg);
-        if (is_array($err['params']) && count($err['params'])) {
-            foreach ($err['params'] as $name => $val) {
-                if (is_array($val)) {
-                    // @ is needed in case $val is a multi-dimensional array
-                    $val = @implode(', ', $val);
-                }
-                if (is_object($val)) {
-                    if (method_exists($val, '__toString')) {
-                        $val = $val->__toString();
-                    } else {
-                        PEAR_ErrorStack::staticPush('PEAR_ErrorStack', PEAR_ERRORSTACK_ERR_OBJTOSTRING,
-                            'warning', array('obj' => get_class($val)),
-                            'object %obj% passed into getErrorMessage, but has no __toString() method');
-                        $val = 'Object';
-                    }
-                }
-                $mainmsg = str_replace('%' . $name . '%', $val, $mainmsg);
-            }
-        }
-        return $mainmsg;
-    }
-    
-    /**
-     * Standard Error Message Template generator from code
-     * @return string
-     */
-    function getErrorMessageTemplate($code)
-    {
-        if (!isset($this->_errorMsgs[$code])) {
-            return '%__msg%';
-        }
-        return $this->_errorMsgs[$code];
-    }
-    
-    /**
-     * Set the Error Message Template array
-     * 
-     * The array format must be:
-     * <pre>
-     * array(error code => 'message template',...)
-     * </pre>
-     * 
-     * Error message parameters passed into {@link push()} will be used as input
-     * for the error message.  If the template is 'message %foo% was %bar%', and the
-     * parameters are array('foo' => 'one', 'bar' => 'six'), the error message returned will
-     * be 'message one was six'
-     * @return string
-     */
-    function setErrorMessageTemplate($template)
-    {
-        $this->_errorMsgs = $template;
-    }
-    
-    
-    /**
-     * emulate PEAR::raiseError()
-     * 
-     * @return PEAR_Error
-     */
-    function raiseError()
-    {
-        require_once 'PEAR.php';
-        $args = func_get_args();
-        return call_user_func_array(array('PEAR', 'raiseError'), $args);
-    }
-}
-$stack = &PEAR_ErrorStack::singleton('PEAR_ErrorStack');
-$stack->pushCallback(array('PEAR_ErrorStack', '_handleError'));
-?>
-                                                                                                                                                                                                                                                                                                                                                                                        PEAR-1.8.0/PEAR/Exception.php                                                                       100664     764     764        33642      100664  10533                                                                                                                                                                                                                                                                                                                                                                      <?php
-/* vim: set expandtab tabstop=4 shiftwidth=4 foldmethod=marker: */
-/**
- * PEAR_Exception
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Tomas V. V. Cox <cox at idecnet.com>
- * @author     Hans Lellelid <hans at velum.net>
- * @author     Bertrand Mansion <bmansion at mamasam.com>
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Exception.php,v 1.30 2009/02/24 23:38:22 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.3.3
- */
-
-
-/**
- * Base PEAR_Exception Class
- *
- * 1) Features:
- *
- * - Nestable exceptions (throw new PEAR_Exception($msg, $prev_exception))
- * - Definable triggers, shot when exceptions occur
- * - Pretty and informative error messages
- * - Added more context info available (like class, method or cause)
- * - cause can be a PEAR_Exception or an array of mixed
- *   PEAR_Exceptions/PEAR_ErrorStack warnings
- * - callbacks for specific exception classes and their children
- *
- * 2) Ideas:
- *
- * - Maybe a way to define a 'template' for the output
- *
- * 3) Inherited properties from PHP Exception Class:
- *
- * protected $message
- * protected $code
- * protected $line
- * protected $file
- * private   $trace
- *
- * 4) Inherited methods from PHP Exception Class:
- *
- * __clone
- * __construct
- * getMessage
- * getCode
- * getFile
- * getLine
- * getTraceSafe
- * getTraceSafeAsString
- * __toString
- *
- * 5) Usage example
- *
- * <code>
- *  require_once 'PEAR/Exception.php';
- *
- *  class Test {
- *     function foo() {
- *         throw new PEAR_Exception('Error Message', ERROR_CODE);
- *     }
- *  }
- *
- *  function myLogger($pear_exception) {
- *     echo $pear_exception->getMessage();
- *  }
- *  // each time a exception is thrown the 'myLogger' will be called
- *  // (its use is completely optional)
- *  PEAR_Exception::addObserver('myLogger');
- *  $test = new Test;
- *  try {
- *     $test->foo();
- *  } catch (PEAR_Exception $e) {
- *     print $e;
- *  }
- * </code>
- *
- * @category   pear
- * @package    PEAR
- * @author     Tomas V.V.Cox <cox at idecnet.com>
- * @author     Hans Lellelid <hans at velum.net>
- * @author     Bertrand Mansion <bmansion at mamasam.com>
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.3.3
- *
- */
-class PEAR_Exception extends Exception
-{
-    const OBSERVER_PRINT = -2;
-    const OBSERVER_TRIGGER = -4;
-    const OBSERVER_DIE = -8;
-    protected $cause;
-    private static $_observers = array();
-    private static $_uniqueid = 0;
-    private $_trace;
-
-    /**
-     * Supported signatures:
-     *  - PEAR_Exception(string $message);
-     *  - PEAR_Exception(string $message, int $code);
-     *  - PEAR_Exception(string $message, Exception $cause);
-     *  - PEAR_Exception(string $message, Exception $cause, int $code);
-     *  - PEAR_Exception(string $message, PEAR_Error $cause);
-     *  - PEAR_Exception(string $message, PEAR_Error $cause, int $code);
-     *  - PEAR_Exception(string $message, array $causes);
-     *  - PEAR_Exception(string $message, array $causes, int $code);
-     * @param string exception message
-     * @param int|Exception|PEAR_Error|array|null exception cause
-     * @param int|null exception code or null
-     */
-    public function __construct($message, $p2 = null, $p3 = null)
-    {
-        if (is_int($p2)) {
-            $code = $p2;
-            $this->cause = null;
-        } elseif (is_object($p2) || is_array($p2)) {
-            // using is_object allows both Exception and PEAR_Error
-            if (is_object($p2) && !($p2 instanceof Exception)) {
-                if (!class_exists('PEAR_Error') || !($p2 instanceof PEAR_Error)) {
-                    throw new PEAR_Exception('exception cause must be Exception, ' .
-                        'array, or PEAR_Error');
-                }
-            }
-            $code = $p3;
-            if (is_array($p2) && isset($p2['message'])) {
-                // fix potential problem of passing in a single warning
-                $p2 = array($p2);
-            }
-            $this->cause = $p2;
-        } else {
-            $code = null;
-            $this->cause = null;
-        }
-        parent::__construct($message, $code);
-        $this->signal();
-    }
-
-    /**
-     * @param mixed $callback  - A valid php callback, see php func is_callable()
-     *                         - A PEAR_Exception::OBSERVER_* constant
-     *                         - An array(const PEAR_Exception::OBSERVER_*,
-     *                           mixed $options)
-     * @param string $label    The name of the observer. Use this if you want
-     *                         to remove it later with removeObserver()
-     */
-    public static function addObserver($callback, $label = 'default')
-    {
-        self::$_observers[$label] = $callback;
-    }
-
-    public static function removeObserver($label = 'default')
-    {
-        unset(self::$_observers[$label]);
-    }
-
-    /**
-     * @return int unique identifier for an observer
-     */
-    public static function getUniqueId()
-    {
-        return self::$_uniqueid++;
-    }
-
-    private function signal()
-    {
-        foreach (self::$_observers as $func) {
-            if (is_callable($func)) {
-                call_user_func($func, $this);
-                continue;
-            }
-            settype($func, 'array');
-            switch ($func[0]) {
-                case self::OBSERVER_PRINT :
-                    $f = (isset($func[1])) ? $func[1] : '%s';
-                    printf($f, $this->getMessage());
-                    break;
-                case self::OBSERVER_TRIGGER :
-                    $f = (isset($func[1])) ? $func[1] : E_USER_NOTICE;
-                    trigger_error($this->getMessage(), $f);
-                    break;
-                case self::OBSERVER_DIE :
-                    $f = (isset($func[1])) ? $func[1] : '%s';
-                    die(printf($f, $this->getMessage()));
-                    break;
-                default:
-                    trigger_error('invalid observer type', E_USER_WARNING);
-            }
-        }
-    }
-
-    /**
-     * Return specific error information that can be used for more detailed
-     * error messages or translation.
-     *
-     * This method may be overridden in child exception classes in order
-     * to add functionality not present in PEAR_Exception and is a placeholder
-     * to define API
-     *
-     * The returned array must be an associative array of parameter => value like so:
-     * <pre>
-     * array('name' => $name, 'context' => array(...))
-     * </pre>
-     * @return array
-     */
-    public function getErrorData()
-    {
-        return array();
-    }
-
-    /**
-     * Returns the exception that caused this exception to be thrown
-     * @access public
-     * @return Exception|array The context of the exception
-     */
-    public function getCause()
-    {
-        return $this->cause;
-    }
-
-    /**
-     * Function must be public to call on caused exceptions
-     * @param array
-     */
-    public function getCauseMessage(&$causes)
-    {
-        $trace = $this->getTraceSafe();
-        $cause = array('class'   => get_class($this),
-                       'message' => $this->message,
-                       'file' => 'unknown',
-                       'line' => 'unknown');
-        if (isset($trace[0])) {
-            if (isset($trace[0]['file'])) {
-                $cause['file'] = $trace[0]['file'];
-                $cause['line'] = $trace[0]['line'];
-            }
-        }
-        $causes[] = $cause;
-        if ($this->cause instanceof PEAR_Exception) {
-            $this->cause->getCauseMessage($causes);
-        } elseif ($this->cause instanceof Exception) {
-            $causes[] = array('class'   => get_class($this->cause),
-                              'message' => $this->cause->getMessage(),
-                              'file' => $this->cause->getFile(),
-                              'line' => $this->cause->getLine());
-        } elseif (class_exists('PEAR_Error') && $this->cause instanceof PEAR_Error) {
-            $causes[] = array('class' => get_class($this->cause),
-                              'message' => $this->cause->getMessage(),
-                              'file' => 'unknown',
-                              'line' => 'unknown');
-        } elseif (is_array($this->cause)) {
-            foreach ($this->cause as $cause) {
-                if ($cause instanceof PEAR_Exception) {
-                    $cause->getCauseMessage($causes);
-                } elseif ($cause instanceof Exception) {
-                    $causes[] = array('class'   => get_class($cause),
-                                   'message' => $cause->getMessage(),
-                                   'file' => $cause->getFile(),
-                                   'line' => $cause->getLine());
-                } elseif (class_exists('PEAR_Error') && $cause instanceof PEAR_Error) {
-                    $causes[] = array('class' => get_class($cause),
-                                      'message' => $cause->getMessage(),
-                                      'file' => 'unknown',
-                                      'line' => 'unknown');
-                } elseif (is_array($cause) && isset($cause['message'])) {
-                    // PEAR_ErrorStack warning
-                    $causes[] = array(
-                        'class' => $cause['package'],
-                        'message' => $cause['message'],
-                        'file' => isset($cause['context']['file']) ?
-                                            $cause['context']['file'] :
-                                            'unknown',
-                        'line' => isset($cause['context']['line']) ?
-                                            $cause['context']['line'] :
-                                            'unknown',
-                    );
-                }
-            }
-        }
-    }
-
-    public function getTraceSafe()
-    {   
-        if (!isset($this->_trace)) {
-            $this->_trace = $this->getTrace();
-            if (empty($this->_trace)) {
-                $backtrace = debug_backtrace();
-                $this->_trace = array($backtrace[count($backtrace)-1]);
-            }
-        }
-        return $this->_trace;
-    }
-
-    public function getErrorClass()
-    {
-        $trace = $this->getTraceSafe();
-        return $trace[0]['class'];
-    }
-
-    public function getErrorMethod()
-    {
-        $trace = $this->getTraceSafe();
-        return $trace[0]['function'];
-    }
-
-    public function __toString()
-    {
-        if (isset($_SERVER['REQUEST_URI'])) {
-            return $this->toHtml();
-        }
-        return $this->toText();
-    }
-
-    public function toHtml()
-    {
-        $trace = $this->getTraceSafe();
-        $causes = array();
-        $this->getCauseMessage($causes);
-        $html =  '<table border="1" cellspacing="0">' . "\n";
-        foreach ($causes as $i => $cause) {
-            $html .= '<tr><td colspan="3" bgcolor="#ff9999">'
-               . str_repeat('-', $i) . ' <b>' . $cause['class'] . '</b>: '
-               . htmlspecialchars($cause['message']) . ' in <b>' . $cause['file'] . '</b> '
-               . 'on line <b>' . $cause['line'] . '</b>'
-               . "</td></tr>\n";
-        }
-        $html .= '<tr><td colspan="3" bgcolor="#aaaaaa" align="center"><b>Exception trace</b></td></tr>' . "\n"
-               . '<tr><td align="center" bgcolor="#cccccc" width="20"><b>#</b></td>'
-               . '<td align="center" bgcolor="#cccccc"><b>Function</b></td>'
-               . '<td align="center" bgcolor="#cccccc"><b>Location</b></td></tr>' . "\n";
-
-        foreach ($trace as $k => $v) {
-            $html .= '<tr><td align="center">' . $k . '</td>'
-                   . '<td>';
-            if (!empty($v['class'])) {
-                $html .= $v['class'] . $v['type'];
-            }
-            $html .= $v['function'];
-            $args = array();
-            if (!empty($v['args'])) {
-                foreach ($v['args'] as $arg) {
-                    if (is_null($arg)) $args[] = 'null';
-                    elseif (is_array($arg)) $args[] = 'Array';
-                    elseif (is_object($arg)) $args[] = 'Object('.get_class($arg).')';
-                    elseif (is_bool($arg)) $args[] = $arg ? 'true' : 'false';
-                    elseif (is_int($arg) || is_double($arg)) $args[] = $arg;
-                    else {
-                        $arg = (string)$arg;
-                        $str = htmlspecialchars(substr($arg, 0, 16));
-                        if (strlen($arg) > 16) $str .= '&hellip;';
-                        $args[] = "'" . $str . "'";
-                    }
-                }
-            }
-            $html .= '(' . implode(', ',$args) . ')'
-                   . '</td>'
-                   . '<td>' . (isset($v['file']) ? $v['file'] : 'unknown')
-                   . ':' . (isset($v['line']) ? $v['line'] : 'unknown')
-                   . '</td></tr>' . "\n";
-        }
-        $html .= '<tr><td align="center">' . ($k+1) . '</td>'
-               . '<td>{main}</td>'
-               . '<td>&nbsp;</td></tr>' . "\n"
-               . '</table>';
-        return $html;
-    }
-
-    public function toText()
-    {
-        $causes = array();
-        $this->getCauseMessage($causes);
-        $causeMsg = '';
-        foreach ($causes as $i => $cause) {
-            $causeMsg .= str_repeat(' ', $i) . $cause['class'] . ': '
-                   . $cause['message'] . ' in ' . $cause['file']
-                   . ' on line ' . $cause['line'] . "\n";
-        }
-        return $causeMsg . $this->getTraceAsString();
-    }
-}
-
-?>                                                                                              PEAR-1.8.0/PEAR/FixPHP5PEARWarnings.php                                                             100777     764     764          231      100777  12077                                                                                                                                                                                                                                                                                                                                                                      <?php
+// }}}                                                                                                                                                                                                                                                      PEAR-1.9.0/PEAR/ErrorStack.php                                                                      100664     764     764       102251      100664  10666                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * Error Stack Implementation
+ * 
+ * This is an incredibly simple implementation of a very complex error handling
+ * facility.  It contains the ability
+ * to track multiple errors from multiple packages simultaneously.  In addition,
+ * it can track errors of many levels, save data along with the error, context
+ * information such as the exact file, line number, class and function that
+ * generated the error, and if necessary, it can raise a traditional PEAR_Error.
+ * It has built-in support for PEAR::Log, to log errors as they occur
+ * 
+ * Since version 0.2alpha, it is also possible to selectively ignore errors,
+ * through the use of an error callback, see {@link pushCallback()}
+ * 
+ * Since version 0.3alpha, it is possible to specify the exception class
+ * returned from {@link push()}
+ *
+ * Since version PEAR1.3.2, ErrorStack no longer instantiates an exception class.  This can
+ * still be done quite handily in an error callback or by manipulating the returned array
+ * @category   Debugging
+ * @package    PEAR_ErrorStack
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  2004-2008 Greg Beaver
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: ErrorStack.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR_ErrorStack
+ */
+
+/**
+ * Singleton storage
+ * 
+ * Format:
+ * <pre>
+ * array(
+ *  'package1' => PEAR_ErrorStack object,
+ *  'package2' => PEAR_ErrorStack object,
+ *  ...
+ * )
+ * </pre>
+ * @access private
+ * @global array $GLOBALS['_PEAR_ERRORSTACK_SINGLETON']
+ */
+$GLOBALS['_PEAR_ERRORSTACK_SINGLETON'] = array();
+
+/**
+ * Global error callback (default)
+ * 
+ * This is only used if set to non-false.  * is the default callback for
+ * all packages, whereas specific packages may set a default callback
+ * for all instances, regardless of whether they are a singleton or not.
+ *
+ * To exclude non-singletons, only set the local callback for the singleton
+ * @see PEAR_ErrorStack::setDefaultCallback()
+ * @access private
+ * @global array $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK']
+ */
+$GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'] = array(
+    '*' => false,
+);
+
+/**
+ * Global Log object (default)
+ * 
+ * This is only used if set to non-false.  Use to set a default log object for
+ * all stacks, regardless of instantiation order or location
+ * @see PEAR_ErrorStack::setDefaultLogger()
+ * @access private
+ * @global array $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER']
+ */
+$GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'] = false;
+
+/**
+ * Global Overriding Callback
+ * 
+ * This callback will override any error callbacks that specific loggers have set.
+ * Use with EXTREME caution
+ * @see PEAR_ErrorStack::staticPushCallback()
+ * @access private
+ * @global array $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER']
+ */
+$GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'] = array();
+
+/**#@+
+ * One of four possible return values from the error Callback
+ * @see PEAR_ErrorStack::_errorCallback()
+ */
+/**
+ * If this is returned, then the error will be both pushed onto the stack
+ * and logged.
+ */
+define('PEAR_ERRORSTACK_PUSHANDLOG', 1);
+/**
+ * If this is returned, then the error will only be pushed onto the stack,
+ * and not logged.
+ */
+define('PEAR_ERRORSTACK_PUSH', 2);
+/**
+ * If this is returned, then the error will only be logged, but not pushed
+ * onto the error stack.
+ */
+define('PEAR_ERRORSTACK_LOG', 3);
+/**
+ * If this is returned, then the error is completely ignored.
+ */
+define('PEAR_ERRORSTACK_IGNORE', 4);
+/**
+ * If this is returned, then the error is logged and die() is called.
+ */
+define('PEAR_ERRORSTACK_DIE', 5);
+/**#@-*/
+
+/**
+ * Error code for an attempt to instantiate a non-class as a PEAR_ErrorStack in
+ * the singleton method.
+ */
+define('PEAR_ERRORSTACK_ERR_NONCLASS', 1);
+
+/**
+ * Error code for an attempt to pass an object into {@link PEAR_ErrorStack::getMessage()}
+ * that has no __toString() method
+ */
+define('PEAR_ERRORSTACK_ERR_OBJTOSTRING', 2);
+/**
+ * Error Stack Implementation
+ *
+ * Usage:
+ * <code>
+ * // global error stack
+ * $global_stack = &PEAR_ErrorStack::singleton('MyPackage');
+ * // local error stack
+ * $local_stack = new PEAR_ErrorStack('MyPackage');
+ * </code>
+ * @author     Greg Beaver <cellog at php.net>
+ * @version    1.9.0
+ * @package    PEAR_ErrorStack
+ * @category   Debugging
+ * @copyright  2004-2008 Greg Beaver
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: ErrorStack.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR_ErrorStack
+ */
+class PEAR_ErrorStack {
+    /**
+     * Errors are stored in the order that they are pushed on the stack.
+     * @since 0.4alpha Errors are no longer organized by error level.
+     * This renders pop() nearly unusable, and levels could be more easily
+     * handled in a callback anyway
+     * @var array
+     * @access private
+     */
+    var $_errors = array();
+
+    /**
+     * Storage of errors by level.
+     *
+     * Allows easy retrieval and deletion of only errors from a particular level
+     * @since PEAR 1.4.0dev
+     * @var array
+     * @access private
+     */
+    var $_errorsByLevel = array();
+
+    /**
+     * Package name this error stack represents
+     * @var string
+     * @access protected
+     */
+    var $_package;
+    
+    /**
+     * Determines whether a PEAR_Error is thrown upon every error addition
+     * @var boolean
+     * @access private
+     */
+    var $_compat = false;
+    
+    /**
+     * If set to a valid callback, this will be used to generate the error
+     * message from the error code, otherwise the message passed in will be
+     * used
+     * @var false|string|array
+     * @access private
+     */
+    var $_msgCallback = false;
+    
+    /**
+     * If set to a valid callback, this will be used to generate the error
+     * context for an error.  For PHP-related errors, this will be a file
+     * and line number as retrieved from debug_backtrace(), but can be
+     * customized for other purposes.  The error might actually be in a separate
+     * configuration file, or in a database query.
+     * @var false|string|array
+     * @access protected
+     */
+    var $_contextCallback = false;
+    
+    /**
+     * If set to a valid callback, this will be called every time an error
+     * is pushed onto the stack.  The return value will be used to determine
+     * whether to allow an error to be pushed or logged.
+     * 
+     * The return value must be one an PEAR_ERRORSTACK_* constant
+     * @see PEAR_ERRORSTACK_PUSHANDLOG, PEAR_ERRORSTACK_PUSH, PEAR_ERRORSTACK_LOG
+     * @var false|string|array
+     * @access protected
+     */
+    var $_errorCallback = array();
+    
+    /**
+     * PEAR::Log object for logging errors
+     * @var false|Log
+     * @access protected
+     */
+    var $_logger = false;
+    
+    /**
+     * Error messages - designed to be overridden
+     * @var array
+     * @abstract
+     */
+    var $_errorMsgs = array();
+    
+    /**
+     * Set up a new error stack
+     * 
+     * @param string   $package name of the package this error stack represents
+     * @param callback $msgCallback callback used for error message generation
+     * @param callback $contextCallback callback used for context generation,
+     *                 defaults to {@link getFileLine()}
+     * @param boolean  $throwPEAR_Error
+     */
+    function PEAR_ErrorStack($package, $msgCallback = false, $contextCallback = false,
+                         $throwPEAR_Error = false)
+    {
+        $this->_package = $package;
+        $this->setMessageCallback($msgCallback);
+        $this->setContextCallback($contextCallback);
+        $this->_compat = $throwPEAR_Error;
+    }
+    
+    /**
+     * Return a single error stack for this package.
+     * 
+     * Note that all parameters are ignored if the stack for package $package
+     * has already been instantiated
+     * @param string   $package name of the package this error stack represents
+     * @param callback $msgCallback callback used for error message generation
+     * @param callback $contextCallback callback used for context generation,
+     *                 defaults to {@link getFileLine()}
+     * @param boolean  $throwPEAR_Error
+     * @param string   $stackClass class to instantiate
+     * @static
+     * @return PEAR_ErrorStack
+     */
+    function &singleton($package, $msgCallback = false, $contextCallback = false,
+                         $throwPEAR_Error = false, $stackClass = 'PEAR_ErrorStack')
+    {
+        if (isset($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package])) {
+            return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package];
+        }
+        if (!class_exists($stackClass)) {
+            if (function_exists('debug_backtrace')) {
+                $trace = debug_backtrace();
+            }
+            PEAR_ErrorStack::staticPush('PEAR_ErrorStack', PEAR_ERRORSTACK_ERR_NONCLASS,
+                'exception', array('stackclass' => $stackClass),
+                'stack class "%stackclass%" is not a valid class name (should be like PEAR_ErrorStack)',
+                false, $trace);
+        }
+        $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package] =
+            new $stackClass($package, $msgCallback, $contextCallback, $throwPEAR_Error);
+
+        return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package];
+    }
+
+    /**
+     * Internal error handler for PEAR_ErrorStack class
+     * 
+     * Dies if the error is an exception (and would have died anyway)
+     * @access private
+     */
+    function _handleError($err)
+    {
+        if ($err['level'] == 'exception') {
+            $message = $err['message'];
+            if (isset($_SERVER['REQUEST_URI'])) {
+                echo '<br />';
+            } else {
+                echo "\n";
+            }
+            var_dump($err['context']);
+            die($message);
+        }
+    }
+    
+    /**
+     * Set up a PEAR::Log object for all error stacks that don't have one
+     * @param Log $log 
+     * @static
+     */
+    function setDefaultLogger(&$log)
+    {
+        if (is_object($log) && method_exists($log, 'log') ) {
+            $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'] = &$log;
+        } elseif (is_callable($log)) {
+            $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'] = &$log;
+	}
+    }
+    
+    /**
+     * Set up a PEAR::Log object for this error stack
+     * @param Log $log 
+     */
+    function setLogger(&$log)
+    {
+        if (is_object($log) && method_exists($log, 'log') ) {
+            $this->_logger = &$log;
+        } elseif (is_callable($log)) {
+            $this->_logger = &$log;
+        }
+    }
+    
+    /**
+     * Set an error code => error message mapping callback
+     * 
+     * This method sets the callback that can be used to generate error
+     * messages for any instance
+     * @param array|string Callback function/method
+     */
+    function setMessageCallback($msgCallback)
+    {
+        if (!$msgCallback) {
+            $this->_msgCallback = array(&$this, 'getErrorMessage');
+        } else {
+            if (is_callable($msgCallback)) {
+                $this->_msgCallback = $msgCallback;
+            }
+        }
+    }
+    
+    /**
+     * Get an error code => error message mapping callback
+     * 
+     * This method returns the current callback that can be used to generate error
+     * messages
+     * @return array|string|false Callback function/method or false if none
+     */
+    function getMessageCallback()
+    {
+        return $this->_msgCallback;
+    }
+    
+    /**
+     * Sets a default callback to be used by all error stacks
+     * 
+     * This method sets the callback that can be used to generate error
+     * messages for a singleton
+     * @param array|string Callback function/method
+     * @param string Package name, or false for all packages
+     * @static
+     */
+    function setDefaultCallback($callback = false, $package = false)
+    {
+        if (!is_callable($callback)) {
+            $callback = false;
+        }
+        $package = $package ? $package : '*';
+        $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'][$package] = $callback;
+    }
+    
+    /**
+     * Set a callback that generates context information (location of error) for an error stack
+     * 
+     * This method sets the callback that can be used to generate context
+     * information for an error.  Passing in NULL will disable context generation
+     * and remove the expensive call to debug_backtrace()
+     * @param array|string|null Callback function/method
+     */
+    function setContextCallback($contextCallback)
+    {
+        if ($contextCallback === null) {
+            return $this->_contextCallback = false;
+        }
+        if (!$contextCallback) {
+            $this->_contextCallback = array(&$this, 'getFileLine');
+        } else {
+            if (is_callable($contextCallback)) {
+                $this->_contextCallback = $contextCallback;
+            }
+        }
+    }
+    
+    /**
+     * Set an error Callback
+     * If set to a valid callback, this will be called every time an error
+     * is pushed onto the stack.  The return value will be used to determine
+     * whether to allow an error to be pushed or logged.
+     * 
+     * The return value must be one of the ERRORSTACK_* constants.
+     * 
+     * This functionality can be used to emulate PEAR's pushErrorHandling, and
+     * the PEAR_ERROR_CALLBACK mode, without affecting the integrity of
+     * the error stack or logging
+     * @see PEAR_ERRORSTACK_PUSHANDLOG, PEAR_ERRORSTACK_PUSH, PEAR_ERRORSTACK_LOG
+     * @see popCallback()
+     * @param string|array $cb
+     */
+    function pushCallback($cb)
+    {
+        array_push($this->_errorCallback, $cb);
+    }
+    
+    /**
+     * Remove a callback from the error callback stack
+     * @see pushCallback()
+     * @return array|string|false
+     */
+    function popCallback()
+    {
+        if (!count($this->_errorCallback)) {
+            return false;
+        }
+        return array_pop($this->_errorCallback);
+    }
+    
+    /**
+     * Set a temporary overriding error callback for every package error stack
+     *
+     * Use this to temporarily disable all existing callbacks (can be used
+     * to emulate the @ operator, for instance)
+     * @see PEAR_ERRORSTACK_PUSHANDLOG, PEAR_ERRORSTACK_PUSH, PEAR_ERRORSTACK_LOG
+     * @see staticPopCallback(), pushCallback()
+     * @param string|array $cb
+     * @static
+     */
+    function staticPushCallback($cb)
+    {
+        array_push($GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'], $cb);
+    }
+    
+    /**
+     * Remove a temporary overriding error callback
+     * @see staticPushCallback()
+     * @return array|string|false
+     * @static
+     */
+    function staticPopCallback()
+    {
+        $ret = array_pop($GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK']);
+        if (!is_array($GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'])) {
+            $GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'] = array();
+        }
+        return $ret;
+    }
+    
+    /**
+     * Add an error to the stack
+     * 
+     * If the message generator exists, it is called with 2 parameters.
+     *  - the current Error Stack object
+     *  - an array that is in the same format as an error.  Available indices
+     *    are 'code', 'package', 'time', 'params', 'level', and 'context'
+     * 
+     * Next, if the error should contain context information, this is
+     * handled by the context grabbing method.
+     * Finally, the error is pushed onto the proper error stack
+     * @param int    $code      Package-specific error code
+     * @param string $level     Error level.  This is NOT spell-checked
+     * @param array  $params    associative array of error parameters
+     * @param string $msg       Error message, or a portion of it if the message
+     *                          is to be generated
+     * @param array  $repackage If this error re-packages an error pushed by
+     *                          another package, place the array returned from
+     *                          {@link pop()} in this parameter
+     * @param array  $backtrace Protected parameter: use this to pass in the
+     *                          {@link debug_backtrace()} that should be used
+     *                          to find error context
+     * @return PEAR_Error|array if compatibility mode is on, a PEAR_Error is also
+     * thrown.  If a PEAR_Error is returned, the userinfo
+     * property is set to the following array:
+     * 
+     * <code>
+     * array(
+     *    'code' => $code,
+     *    'params' => $params,
+     *    'package' => $this->_package,
+     *    'level' => $level,
+     *    'time' => time(),
+     *    'context' => $context,
+     *    'message' => $msg,
+     * //['repackage' => $err] repackaged error array/Exception class
+     * );
+     * </code>
+     * 
+     * Normally, the previous array is returned.
+     */
+    function push($code, $level = 'error', $params = array(), $msg = false,
+                  $repackage = false, $backtrace = false)
+    {
+        $context = false;
+        // grab error context
+        if ($this->_contextCallback) {
+            if (!$backtrace) {
+                $backtrace = debug_backtrace();
+            }
+            $context = call_user_func($this->_contextCallback, $code, $params, $backtrace);
+        }
+        
+        // save error
+        $time = explode(' ', microtime());
+        $time = $time[1] + $time[0];
+        $err = array(
+                'code' => $code,
+                'params' => $params,
+                'package' => $this->_package,
+                'level' => $level,
+                'time' => $time,
+                'context' => $context,
+                'message' => $msg,
+               );
+
+        if ($repackage) {
+            $err['repackage'] = $repackage;
+        }
+
+        // set up the error message, if necessary
+        if ($this->_msgCallback) {
+            $msg = call_user_func_array($this->_msgCallback,
+                                        array(&$this, $err));
+            $err['message'] = $msg;
+        }        
+        $push = $log = true;
+        $die = false;
+        // try the overriding callback first
+        $callback = $this->staticPopCallback();
+        if ($callback) {
+            $this->staticPushCallback($callback);
+        }
+        if (!is_callable($callback)) {
+            // try the local callback next
+            $callback = $this->popCallback();
+            if (is_callable($callback)) {
+                $this->pushCallback($callback);
+            } else {
+                // try the default callback
+                $callback = isset($GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'][$this->_package]) ?
+                    $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'][$this->_package] :
+                    $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK']['*'];
+            }
+        }
+        if (is_callable($callback)) {
+            switch(call_user_func($callback, $err)){
+            	case PEAR_ERRORSTACK_IGNORE: 
+            		return $err;
+        		break;
+            	case PEAR_ERRORSTACK_PUSH: 
+            		$log = false;
+        		break;
+            	case PEAR_ERRORSTACK_LOG: 
+            		$push = false;
+        		break;
+            	case PEAR_ERRORSTACK_DIE: 
+            		$die = true;
+        		break;
+                // anything else returned has the same effect as pushandlog
+            }
+        }
+        if ($push) {
+            array_unshift($this->_errors, $err);
+            if (!isset($this->_errorsByLevel[$err['level']])) {
+                $this->_errorsByLevel[$err['level']] = array();
+            }
+            $this->_errorsByLevel[$err['level']][] = &$this->_errors[0];
+        }
+        if ($log) {
+            if ($this->_logger || $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER']) {
+                $this->_log($err);
+            }
+        }
+        if ($die) {
+            die();
+        }
+        if ($this->_compat && $push) {
+            return $this->raiseError($msg, $code, null, null, $err);
+        }
+        return $err;
+    }
+    
+    /**
+     * Static version of {@link push()}
+     * 
+     * @param string $package   Package name this error belongs to
+     * @param int    $code      Package-specific error code
+     * @param string $level     Error level.  This is NOT spell-checked
+     * @param array  $params    associative array of error parameters
+     * @param string $msg       Error message, or a portion of it if the message
+     *                          is to be generated
+     * @param array  $repackage If this error re-packages an error pushed by
+     *                          another package, place the array returned from
+     *                          {@link pop()} in this parameter
+     * @param array  $backtrace Protected parameter: use this to pass in the
+     *                          {@link debug_backtrace()} that should be used
+     *                          to find error context
+     * @return PEAR_Error|array if compatibility mode is on, a PEAR_Error is also
+     *                          thrown.  see docs for {@link push()}
+     * @static
+     */
+    function staticPush($package, $code, $level = 'error', $params = array(),
+                        $msg = false, $repackage = false, $backtrace = false)
+    {
+        $s = &PEAR_ErrorStack::singleton($package);
+        if ($s->_contextCallback) {
+            if (!$backtrace) {
+                if (function_exists('debug_backtrace')) {
+                    $backtrace = debug_backtrace();
+                }
+            }
+        }
+        return $s->push($code, $level, $params, $msg, $repackage, $backtrace);
+    }
+    
+    /**
+     * Log an error using PEAR::Log
+     * @param array $err Error array
+     * @param array $levels Error level => Log constant map
+     * @access protected
+     */
+    function _log($err)
+    {
+        if ($this->_logger) {
+            $logger = &$this->_logger;
+        } else {
+            $logger = &$GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'];
+        }
+        if (is_a($logger, 'Log')) {
+            $levels = array(
+                'exception' => PEAR_LOG_CRIT,
+                'alert' => PEAR_LOG_ALERT,
+                'critical' => PEAR_LOG_CRIT,
+                'error' => PEAR_LOG_ERR,
+                'warning' => PEAR_LOG_WARNING,
+                'notice' => PEAR_LOG_NOTICE,
+                'info' => PEAR_LOG_INFO,
+                'debug' => PEAR_LOG_DEBUG);
+            if (isset($levels[$err['level']])) {
+                $level = $levels[$err['level']];
+            } else {
+                $level = PEAR_LOG_INFO;
+            }
+            $logger->log($err['message'], $level, $err);
+        } else { // support non-standard logs
+            call_user_func($logger, $err);
+        }
+    }
+
+    
+    /**
+     * Pop an error off of the error stack
+     * 
+     * @return false|array
+     * @since 0.4alpha it is no longer possible to specify a specific error
+     * level to return - the last error pushed will be returned, instead
+     */
+    function pop()
+    {
+        $err = @array_shift($this->_errors);
+        if (!is_null($err)) {
+            @array_pop($this->_errorsByLevel[$err['level']]);
+            if (!count($this->_errorsByLevel[$err['level']])) {
+                unset($this->_errorsByLevel[$err['level']]);
+            }
+        }
+        return $err;
+    }
+
+    /**
+     * Pop an error off of the error stack, static method
+     *
+     * @param string package name
+     * @return boolean
+     * @since PEAR1.5.0a1
+     */
+    function staticPop($package)
+    {
+        if ($package) {
+            if (!isset($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package])) {
+                return false;
+            }
+            return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package]->pop();
+        }
+    }
+
+    /**
+     * Determine whether there are any errors on the stack
+     * @param string|array Level name.  Use to determine if any errors
+     * of level (string), or levels (array) have been pushed
+     * @return boolean
+     */
+    function hasErrors($level = false)
+    {
+        if ($level) {
+            return isset($this->_errorsByLevel[$level]);
+        }
+        return count($this->_errors);
+    }
+    
+    /**
+     * Retrieve all errors since last purge
+     * 
+     * @param boolean set in order to empty the error stack
+     * @param string level name, to return only errors of a particular severity
+     * @return array
+     */
+    function getErrors($purge = false, $level = false)
+    {
+        if (!$purge) {
+            if ($level) {
+                if (!isset($this->_errorsByLevel[$level])) {
+                    return array();
+                } else {
+                    return $this->_errorsByLevel[$level];
+                }
+            } else {
+                return $this->_errors;
+            }
+        }
+        if ($level) {
+            $ret = $this->_errorsByLevel[$level];
+            foreach ($this->_errorsByLevel[$level] as $i => $unused) {
+                // entries are references to the $_errors array
+                $this->_errorsByLevel[$level][$i] = false;
+            }
+            // array_filter removes all entries === false
+            $this->_errors = array_filter($this->_errors);
+            unset($this->_errorsByLevel[$level]);
+            return $ret;
+        }
+        $ret = $this->_errors;
+        $this->_errors = array();
+        $this->_errorsByLevel = array();
+        return $ret;
+    }
+    
+    /**
+     * Determine whether there are any errors on a single error stack, or on any error stack
+     *
+     * The optional parameter can be used to test the existence of any errors without the need of
+     * singleton instantiation
+     * @param string|false Package name to check for errors
+     * @param string Level name to check for a particular severity
+     * @return boolean
+     * @static
+     */
+    function staticHasErrors($package = false, $level = false)
+    {
+        if ($package) {
+            if (!isset($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package])) {
+                return false;
+            }
+            return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package]->hasErrors($level);
+        }
+        foreach ($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'] as $package => $obj) {
+            if ($obj->hasErrors($level)) {
+                return true;
+            }
+        }
+        return false;
+    }
+    
+    /**
+     * Get a list of all errors since last purge, organized by package
+     * @since PEAR 1.4.0dev BC break! $level is now in the place $merge used to be
+     * @param boolean $purge Set to purge the error stack of existing errors
+     * @param string  $level Set to a level name in order to retrieve only errors of a particular level
+     * @param boolean $merge Set to return a flat array, not organized by package
+     * @param array   $sortfunc Function used to sort a merged array - default
+     *        sorts by time, and should be good for most cases
+     * @static
+     * @return array 
+     */
+    function staticGetErrors($purge = false, $level = false, $merge = false,
+                             $sortfunc = array('PEAR_ErrorStack', '_sortErrors'))
+    {
+        $ret = array();
+        if (!is_callable($sortfunc)) {
+            $sortfunc = array('PEAR_ErrorStack', '_sortErrors');
+        }
+        foreach ($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'] as $package => $obj) {
+            $test = $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package]->getErrors($purge, $level);
+            if ($test) {
+                if ($merge) {
+                    $ret = array_merge($ret, $test);
+                } else {
+                    $ret[$package] = $test;
+                }
+            }
+        }
+        if ($merge) {
+            usort($ret, $sortfunc);
+        }
+        return $ret;
+    }
+    
+    /**
+     * Error sorting function, sorts by time
+     * @access private
+     */
+    function _sortErrors($a, $b)
+    {
+        if ($a['time'] == $b['time']) {
+            return 0;
+        }
+        if ($a['time'] < $b['time']) {
+            return 1;
+        }
+        return -1;
+    }
+
+    /**
+     * Standard file/line number/function/class context callback
+     *
+     * This function uses a backtrace generated from {@link debug_backtrace()}
+     * and so will not work at all in PHP < 4.3.0.  The frame should
+     * reference the frame that contains the source of the error.
+     * @return array|false either array('file' => file, 'line' => line,
+     *         'function' => function name, 'class' => class name) or
+     *         if this doesn't work, then false
+     * @param unused
+     * @param integer backtrace frame.
+     * @param array Results of debug_backtrace()
+     * @static
+     */
+    function getFileLine($code, $params, $backtrace = null)
+    {
+        if ($backtrace === null) {
+            return false;
+        }
+        $frame = 0;
+        $functionframe = 1;
+        if (!isset($backtrace[1])) {
+            $functionframe = 0;
+        } else {
+            while (isset($backtrace[$functionframe]['function']) &&
+                  $backtrace[$functionframe]['function'] == 'eval' &&
+                  isset($backtrace[$functionframe + 1])) {
+                $functionframe++;
+            }
+        }
+        if (isset($backtrace[$frame])) {
+            if (!isset($backtrace[$frame]['file'])) {
+                $frame++;
+            }
+            $funcbacktrace = $backtrace[$functionframe];
+            $filebacktrace = $backtrace[$frame];
+            $ret = array('file' => $filebacktrace['file'],
+                         'line' => $filebacktrace['line']);
+            // rearrange for eval'd code or create function errors
+            if (strpos($filebacktrace['file'], '(') && 
+            	  preg_match(';^(.*?)\((\d+)\) : (.*?)\\z;', $filebacktrace['file'],
+                  $matches)) {
+                $ret['file'] = $matches[1];
+                $ret['line'] = $matches[2] + 0;
+            }
+            if (isset($funcbacktrace['function']) && isset($backtrace[1])) {
+                if ($funcbacktrace['function'] != 'eval') {
+                    if ($funcbacktrace['function'] == '__lambda_func') {
+                        $ret['function'] = 'create_function() code';
+                    } else {
+                        $ret['function'] = $funcbacktrace['function'];
+                    }
+                }
+            }
+            if (isset($funcbacktrace['class']) && isset($backtrace[1])) {
+                $ret['class'] = $funcbacktrace['class'];
+            }
+            return $ret;
+        }
+        return false;
+    }
+    
+    /**
+     * Standard error message generation callback
+     * 
+     * This method may also be called by a custom error message generator
+     * to fill in template values from the params array, simply
+     * set the third parameter to the error message template string to use
+     * 
+     * The special variable %__msg% is reserved: use it only to specify
+     * where a message passed in by the user should be placed in the template,
+     * like so:
+     * 
+     * Error message: %msg% - internal error
+     * 
+     * If the message passed like so:
+     * 
+     * <code>
+     * $stack->push(ERROR_CODE, 'error', array(), 'server error 500');
+     * </code>
+     * 
+     * The returned error message will be "Error message: server error 500 -
+     * internal error"
+     * @param PEAR_ErrorStack
+     * @param array
+     * @param string|false Pre-generated error message template
+     * @static
+     * @return string
+     */
+    function getErrorMessage(&$stack, $err, $template = false)
+    {
+        if ($template) {
+            $mainmsg = $template;
+        } else {
+            $mainmsg = $stack->getErrorMessageTemplate($err['code']);
+        }
+        $mainmsg = str_replace('%__msg%', $err['message'], $mainmsg);
+        if (is_array($err['params']) && count($err['params'])) {
+            foreach ($err['params'] as $name => $val) {
+                if (is_array($val)) {
+                    // @ is needed in case $val is a multi-dimensional array
+                    $val = @implode(', ', $val);
+                }
+                if (is_object($val)) {
+                    if (method_exists($val, '__toString')) {
+                        $val = $val->__toString();
+                    } else {
+                        PEAR_ErrorStack::staticPush('PEAR_ErrorStack', PEAR_ERRORSTACK_ERR_OBJTOSTRING,
+                            'warning', array('obj' => get_class($val)),
+                            'object %obj% passed into getErrorMessage, but has no __toString() method');
+                        $val = 'Object';
+                    }
+                }
+                $mainmsg = str_replace('%' . $name . '%', $val, $mainmsg);
+            }
+        }
+        return $mainmsg;
+    }
+    
+    /**
+     * Standard Error Message Template generator from code
+     * @return string
+     */
+    function getErrorMessageTemplate($code)
+    {
+        if (!isset($this->_errorMsgs[$code])) {
+            return '%__msg%';
+        }
+        return $this->_errorMsgs[$code];
+    }
+    
+    /**
+     * Set the Error Message Template array
+     * 
+     * The array format must be:
+     * <pre>
+     * array(error code => 'message template',...)
+     * </pre>
+     * 
+     * Error message parameters passed into {@link push()} will be used as input
+     * for the error message.  If the template is 'message %foo% was %bar%', and the
+     * parameters are array('foo' => 'one', 'bar' => 'six'), the error message returned will
+     * be 'message one was six'
+     * @return string
+     */
+    function setErrorMessageTemplate($template)
+    {
+        $this->_errorMsgs = $template;
+    }
+    
+    
+    /**
+     * emulate PEAR::raiseError()
+     * 
+     * @return PEAR_Error
+     */
+    function raiseError()
+    {
+        require_once 'PEAR.php';
+        $args = func_get_args();
+        return call_user_func_array(array('PEAR', 'raiseError'), $args);
+    }
+}
+$stack = &PEAR_ErrorStack::singleton('PEAR_ErrorStack');
+$stack->pushCallback(array('PEAR_ErrorStack', '_handleError'));
+?>
+                                                                                                                                                                                                                                                                                                                                                       PEAR-1.9.0/PEAR/Exception.php                                                                       100664     764     764        33031      100664  10524                                                                                                                                                                                                                                                                                                                                                                      <?php
+/* vim: set expandtab tabstop=4 shiftwidth=4 foldmethod=marker: */
+/**
+ * PEAR_Exception
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Tomas V. V. Cox <cox at idecnet.com>
+ * @author     Hans Lellelid <hans at velum.net>
+ * @author     Bertrand Mansion <bmansion at mamasam.com>
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Exception.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.3.3
+ */
+
+
+/**
+ * Base PEAR_Exception Class
+ *
+ * 1) Features:
+ *
+ * - Nestable exceptions (throw new PEAR_Exception($msg, $prev_exception))
+ * - Definable triggers, shot when exceptions occur
+ * - Pretty and informative error messages
+ * - Added more context info available (like class, method or cause)
+ * - cause can be a PEAR_Exception or an array of mixed
+ *   PEAR_Exceptions/PEAR_ErrorStack warnings
+ * - callbacks for specific exception classes and their children
+ *
+ * 2) Ideas:
+ *
+ * - Maybe a way to define a 'template' for the output
+ *
+ * 3) Inherited properties from PHP Exception Class:
+ *
+ * protected $message
+ * protected $code
+ * protected $line
+ * protected $file
+ * private   $trace
+ *
+ * 4) Inherited methods from PHP Exception Class:
+ *
+ * __clone
+ * __construct
+ * getMessage
+ * getCode
+ * getFile
+ * getLine
+ * getTraceSafe
+ * getTraceSafeAsString
+ * __toString
+ *
+ * 5) Usage example
+ *
+ * <code>
+ *  require_once 'PEAR/Exception.php';
+ *
+ *  class Test {
+ *     function foo() {
+ *         throw new PEAR_Exception('Error Message', ERROR_CODE);
+ *     }
+ *  }
+ *
+ *  function myLogger($pear_exception) {
+ *     echo $pear_exception->getMessage();
+ *  }
+ *  // each time a exception is thrown the 'myLogger' will be called
+ *  // (its use is completely optional)
+ *  PEAR_Exception::addObserver('myLogger');
+ *  $test = new Test;
+ *  try {
+ *     $test->foo();
+ *  } catch (PEAR_Exception $e) {
+ *     print $e;
+ *  }
+ * </code>
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Tomas V.V.Cox <cox at idecnet.com>
+ * @author     Hans Lellelid <hans at velum.net>
+ * @author     Bertrand Mansion <bmansion at mamasam.com>
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.3.3
+ *
+ */
+class PEAR_Exception extends Exception
+{
+    const OBSERVER_PRINT = -2;
+    const OBSERVER_TRIGGER = -4;
+    const OBSERVER_DIE = -8;
+    protected $cause;
+    private static $_observers = array();
+    private static $_uniqueid = 0;
+    private $_trace;
+
+    /**
+     * Supported signatures:
+     *  - PEAR_Exception(string $message);
+     *  - PEAR_Exception(string $message, int $code);
+     *  - PEAR_Exception(string $message, Exception $cause);
+     *  - PEAR_Exception(string $message, Exception $cause, int $code);
+     *  - PEAR_Exception(string $message, PEAR_Error $cause);
+     *  - PEAR_Exception(string $message, PEAR_Error $cause, int $code);
+     *  - PEAR_Exception(string $message, array $causes);
+     *  - PEAR_Exception(string $message, array $causes, int $code);
+     * @param string exception message
+     * @param int|Exception|PEAR_Error|array|null exception cause
+     * @param int|null exception code or null
+     */
+    public function __construct($message, $p2 = null, $p3 = null)
+    {
+        if (is_int($p2)) {
+            $code = $p2;
+            $this->cause = null;
+        } elseif (is_object($p2) || is_array($p2)) {
+            // using is_object allows both Exception and PEAR_Error
+            if (is_object($p2) && !($p2 instanceof Exception)) {
+                if (!class_exists('PEAR_Error') || !($p2 instanceof PEAR_Error)) {
+                    throw new PEAR_Exception('exception cause must be Exception, ' .
+                        'array, or PEAR_Error');
+                }
+            }
+            $code = $p3;
+            if (is_array($p2) && isset($p2['message'])) {
+                // fix potential problem of passing in a single warning
+                $p2 = array($p2);
+            }
+            $this->cause = $p2;
+        } else {
+            $code = null;
+            $this->cause = null;
+        }
+        parent::__construct($message, $code);
+        $this->signal();
+    }
+
+    /**
+     * @param mixed $callback  - A valid php callback, see php func is_callable()
+     *                         - A PEAR_Exception::OBSERVER_* constant
+     *                         - An array(const PEAR_Exception::OBSERVER_*,
+     *                           mixed $options)
+     * @param string $label    The name of the observer. Use this if you want
+     *                         to remove it later with removeObserver()
+     */
+    public static function addObserver($callback, $label = 'default')
+    {
+        self::$_observers[$label] = $callback;
+    }
+
+    public static function removeObserver($label = 'default')
+    {
+        unset(self::$_observers[$label]);
+    }
+
+    /**
+     * @return int unique identifier for an observer
+     */
+    public static function getUniqueId()
+    {
+        return self::$_uniqueid++;
+    }
+
+    private function signal()
+    {
+        foreach (self::$_observers as $func) {
+            if (is_callable($func)) {
+                call_user_func($func, $this);
+                continue;
+            }
+            settype($func, 'array');
+            switch ($func[0]) {
+                case self::OBSERVER_PRINT :
+                    $f = (isset($func[1])) ? $func[1] : '%s';
+                    printf($f, $this->getMessage());
+                    break;
+                case self::OBSERVER_TRIGGER :
+                    $f = (isset($func[1])) ? $func[1] : E_USER_NOTICE;
+                    trigger_error($this->getMessage(), $f);
+                    break;
+                case self::OBSERVER_DIE :
+                    $f = (isset($func[1])) ? $func[1] : '%s';
+                    die(printf($f, $this->getMessage()));
+                    break;
+                default:
+                    trigger_error('invalid observer type', E_USER_WARNING);
+            }
+        }
+    }
+
+    /**
+     * Return specific error information that can be used for more detailed
+     * error messages or translation.
+     *
+     * This method may be overridden in child exception classes in order
+     * to add functionality not present in PEAR_Exception and is a placeholder
+     * to define API
+     *
+     * The returned array must be an associative array of parameter => value like so:
+     * <pre>
+     * array('name' => $name, 'context' => array(...))
+     * </pre>
+     * @return array
+     */
+    public function getErrorData()
+    {
+        return array();
+    }
+
+    /**
+     * Returns the exception that caused this exception to be thrown
+     * @access public
+     * @return Exception|array The context of the exception
+     */
+    public function getCause()
+    {
+        return $this->cause;
+    }
+
+    /**
+     * Function must be public to call on caused exceptions
+     * @param array
+     */
+    public function getCauseMessage(&$causes)
+    {
+        $trace = $this->getTraceSafe();
+        $cause = array('class'   => get_class($this),
+                       'message' => $this->message,
+                       'file' => 'unknown',
+                       'line' => 'unknown');
+        if (isset($trace[0])) {
+            if (isset($trace[0]['file'])) {
+                $cause['file'] = $trace[0]['file'];
+                $cause['line'] = $trace[0]['line'];
+            }
+        }
+        $causes[] = $cause;
+        if ($this->cause instanceof PEAR_Exception) {
+            $this->cause->getCauseMessage($causes);
+        } elseif ($this->cause instanceof Exception) {
+            $causes[] = array('class'   => get_class($this->cause),
+                              'message' => $this->cause->getMessage(),
+                              'file' => $this->cause->getFile(),
+                              'line' => $this->cause->getLine());
+        } elseif (class_exists('PEAR_Error') && $this->cause instanceof PEAR_Error) {
+            $causes[] = array('class' => get_class($this->cause),
+                              'message' => $this->cause->getMessage(),
+                              'file' => 'unknown',
+                              'line' => 'unknown');
+        } elseif (is_array($this->cause)) {
+            foreach ($this->cause as $cause) {
+                if ($cause instanceof PEAR_Exception) {
+                    $cause->getCauseMessage($causes);
+                } elseif ($cause instanceof Exception) {
+                    $causes[] = array('class'   => get_class($cause),
+                                   'message' => $cause->getMessage(),
+                                   'file' => $cause->getFile(),
+                                   'line' => $cause->getLine());
+                } elseif (class_exists('PEAR_Error') && $cause instanceof PEAR_Error) {
+                    $causes[] = array('class' => get_class($cause),
+                                      'message' => $cause->getMessage(),
+                                      'file' => 'unknown',
+                                      'line' => 'unknown');
+                } elseif (is_array($cause) && isset($cause['message'])) {
+                    // PEAR_ErrorStack warning
+                    $causes[] = array(
+                        'class' => $cause['package'],
+                        'message' => $cause['message'],
+                        'file' => isset($cause['context']['file']) ?
+                                            $cause['context']['file'] :
+                                            'unknown',
+                        'line' => isset($cause['context']['line']) ?
+                                            $cause['context']['line'] :
+                                            'unknown',
+                    );
+                }
+            }
+        }
+    }
+
+    public function getTraceSafe()
+    {   
+        if (!isset($this->_trace)) {
+            $this->_trace = $this->getTrace();
+            if (empty($this->_trace)) {
+                $backtrace = debug_backtrace();
+                $this->_trace = array($backtrace[count($backtrace)-1]);
+            }
+        }
+        return $this->_trace;
+    }
+
+    public function getErrorClass()
+    {
+        $trace = $this->getTraceSafe();
+        return $trace[0]['class'];
+    }
+
+    public function getErrorMethod()
+    {
+        $trace = $this->getTraceSafe();
+        return $trace[0]['function'];
+    }
+
+    public function __toString()
+    {
+        if (isset($_SERVER['REQUEST_URI'])) {
+            return $this->toHtml();
+        }
+        return $this->toText();
+    }
+
+    public function toHtml()
+    {
+        $trace = $this->getTraceSafe();
+        $causes = array();
+        $this->getCauseMessage($causes);
+        $html =  '<table border="1" cellspacing="0">' . "\n";
+        foreach ($causes as $i => $cause) {
+            $html .= '<tr><td colspan="3" bgcolor="#ff9999">'
+               . str_repeat('-', $i) . ' <b>' . $cause['class'] . '</b>: '
+               . htmlspecialchars($cause['message']) . ' in <b>' . $cause['file'] . '</b> '
+               . 'on line <b>' . $cause['line'] . '</b>'
+               . "</td></tr>\n";
+        }
+        $html .= '<tr><td colspan="3" bgcolor="#aaaaaa" align="center"><b>Exception trace</b></td></tr>' . "\n"
+               . '<tr><td align="center" bgcolor="#cccccc" width="20"><b>#</b></td>'
+               . '<td align="center" bgcolor="#cccccc"><b>Function</b></td>'
+               . '<td align="center" bgcolor="#cccccc"><b>Location</b></td></tr>' . "\n";
+
+        foreach ($trace as $k => $v) {
+            $html .= '<tr><td align="center">' . $k . '</td>'
+                   . '<td>';
+            if (!empty($v['class'])) {
+                $html .= $v['class'] . $v['type'];
+            }
+            $html .= $v['function'];
+            $args = array();
+            if (!empty($v['args'])) {
+                foreach ($v['args'] as $arg) {
+                    if (is_null($arg)) $args[] = 'null';
+                    elseif (is_array($arg)) $args[] = 'Array';
+                    elseif (is_object($arg)) $args[] = 'Object('.get_class($arg).')';
+                    elseif (is_bool($arg)) $args[] = $arg ? 'true' : 'false';
+                    elseif (is_int($arg) || is_double($arg)) $args[] = $arg;
+                    else {
+                        $arg = (string)$arg;
+                        $str = htmlspecialchars(substr($arg, 0, 16));
+                        if (strlen($arg) > 16) $str .= '&hellip;';
+                        $args[] = "'" . $str . "'";
+                    }
+                }
+            }
+            $html .= '(' . implode(', ',$args) . ')'
+                   . '</td>'
+                   . '<td>' . (isset($v['file']) ? $v['file'] : 'unknown')
+                   . ':' . (isset($v['line']) ? $v['line'] : 'unknown')
+                   . '</td></tr>' . "\n";
+        }
+        $html .= '<tr><td align="center">' . ($k+1) . '</td>'
+               . '<td>{main}</td>'
+               . '<td>&nbsp;</td></tr>' . "\n"
+               . '</table>';
+        return $html;
+    }
+
+    public function toText()
+    {
+        $causes = array();
+        $this->getCauseMessage($causes);
+        $causeMsg = '';
+        foreach ($causes as $i => $cause) {
+            $causeMsg .= str_repeat(' ', $i) . $cause['class'] . ': '
+                   . $cause['message'] . ' in ' . $cause['file']
+                   . ' on line ' . $cause['line'] . "\n";
+        }
+        return $causeMsg . $this->getTraceAsString();
+    }
+}
+
+?>                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       PEAR-1.9.0/PEAR/FixPHP5PEARWarnings.php                                                             100664     764     764          231      100664  12066                                                                                                                                                                                                                                                                                                                                                                      <?php
 if ($skipmsg) {
     $a = &new $ec($code, $mode, $options, $userinfo);
 } else {
     $a = &new $ec($message, $code, $mode, $options, $userinfo);
 }
-?>                                                                                                                                                                                                                                                                                                                                                                       PEAR-1.8.0/PEAR/Frontend.php                                                                        100664     764     764        15445      100664  10355                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_Frontend, the singleton-based frontend for user input/output
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Frontend.php,v 1.18 2009/02/24 23:38:22 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * Include error handling
- */
-//require_once 'PEAR.php';
-
-/**
- * Which user interface class is being used.
- * @var string class name
- */
-$GLOBALS['_PEAR_FRONTEND_CLASS'] = 'PEAR_Frontend_CLI';
-
-/**
- * Instance of $_PEAR_Command_uiclass.
- * @var object
- */
-$GLOBALS['_PEAR_FRONTEND_SINGLETON'] = null;
-
-/**
- * Singleton-based frontend for PEAR user input/output
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Frontend extends PEAR
-{
-    /**
-     * Retrieve the frontend object
-     * @return PEAR_Frontend_CLI|PEAR_Frontend_Web|PEAR_Frontend_Gtk
-     * @static
-     */
-    function &singleton($type = null)
-    {
-        if ($type === null) {
-            if (!isset($GLOBALS['_PEAR_FRONTEND_SINGLETON'])) {
-                $a = false;
-                return $a;
-            }
-            return $GLOBALS['_PEAR_FRONTEND_SINGLETON'];
-        }
-
-        $a = PEAR_Frontend::setFrontendClass($type);
-        return $a;
-    }
-
-    /**
-     * Set the frontend class that will be used by calls to {@link singleton()}
-     *
-     * Frontends are expected to conform to the PEAR naming standard of
-     * _ => DIRECTORY_SEPARATOR (PEAR_Frontend_CLI is in PEAR/Frontend/CLI.php)
-     * @param string $uiclass full class name
-     * @return PEAR_Frontend
-     * @static
-     */
-    function &setFrontendClass($uiclass)
-    {
-        if (is_object($GLOBALS['_PEAR_FRONTEND_SINGLETON']) &&
-              is_a($GLOBALS['_PEAR_FRONTEND_SINGLETON'], $uiclass)) {
-            return $GLOBALS['_PEAR_FRONTEND_SINGLETON'];
-        }
-
-        if (!class_exists($uiclass)) {
-            $file = str_replace('_', '/', $uiclass) . '.php';
-            if (PEAR_Frontend::isIncludeable($file)) {
-                include_once $file;
-            }
-        }
-
-        if (class_exists($uiclass)) {
-            $obj = &new $uiclass;
-            // quick test to see if this class implements a few of the most
-            // important frontend methods
-            if (is_a($obj, 'PEAR_Frontend')) {
-                $GLOBALS['_PEAR_FRONTEND_SINGLETON'] = &$obj;
-                $GLOBALS['_PEAR_FRONTEND_CLASS'] = $uiclass;
-                return $obj;
-            }
-
-            $err = PEAR::raiseError("not a frontend class: $uiclass");
-            return $err;
-        }
-
-        $err = PEAR::raiseError("no such class: $uiclass");
-        return $err;
-    }
-
-    /**
-     * Set the frontend class that will be used by calls to {@link singleton()}
-     *
-     * Frontends are expected to be a descendant of PEAR_Frontend
-     * @param PEAR_Frontend
-     * @return PEAR_Frontend
-     * @static
-     */
-    function &setFrontendObject($uiobject)
-    {
-        if (is_object($GLOBALS['_PEAR_FRONTEND_SINGLETON']) &&
-              is_a($GLOBALS['_PEAR_FRONTEND_SINGLETON'], get_class($uiobject))) {
-            return $GLOBALS['_PEAR_FRONTEND_SINGLETON'];
-        }
-
-        if (!is_a($uiobject, 'PEAR_Frontend')) {
-            $err = PEAR::raiseError('not a valid frontend class: (' .
-                get_class($uiobject) . ')');
-            return $err;
-        }
-
-        $GLOBALS['_PEAR_FRONTEND_SINGLETON'] = &$uiobject;
-        $GLOBALS['_PEAR_FRONTEND_CLASS'] = get_class($uiobject);
-        return $uiobject;
-    }
-
-    /**
-     * @param string $path relative or absolute include path
-     * @return boolean
-     * @static
-     */
-    function isIncludeable($path)
-    {
-        if (file_exists($path) && is_readable($path)) {
-            return true;
-        }
-
-        $fp = @fopen($path, 'r', true);
-        if ($fp) {
-            fclose($fp);
-            return true;
-        }
-
-        return false;
-    }
-
-    /**
-     * @param PEAR_Config
-     */
-    function setConfig(&$config)
-    {
-    }
-
-    /**
-     * This can be overridden to allow session-based temporary file management
-     *
-     * By default, all files are deleted at the end of a session.  The web installer
-     * needs to be able to sustain a list over many sessions in order to support
-     * user interaction with install scripts
-     */
-    function addTempFile($file)
-    {
-        $GLOBALS['_PEAR_Common_tempfiles'][] = $file;
-    }
-
-    /**
-     * Log an action
-     *
-     * @param string $msg the message to log
-     * @param boolean $append_crlf
-     * @return boolean true
-     * @abstract
-     */
-    function log($msg, $append_crlf = true)
-    {
-    }
-
-    /**
-     * Run a post-installation script
-     *
-     * @param array $scripts array of post-install scripts
-     * @abstract
-     */
-    function runPostinstallScripts(&$scripts)
-    {
-    }
-
-    /**
-     * Display human-friendly output formatted depending on the
-     * $command parameter.
-     *
-     * This should be able to handle basic output data with no command
-     * @param mixed  $data    data structure containing the information to display
-     * @param string $command command from which this method was called
-     * @abstract
-     */
-    function outputData($data, $command = '_default')
-    {
-    }
-
-    /**
-     * Display a modal form dialog and return the given input
-     *
-     * A frontend that requires multiple requests to retrieve and process
-     * data must take these needs into account, and implement the request
-     * handling code.
-     * @param string $command  command from which this method was called
-     * @param array  $prompts  associative array. keys are the input field names
-     *                         and values are the description
-     * @param array  $types    array of input field types (text, password,
-     *                         etc.) keys have to be the same like in $prompts
-     * @param array  $defaults array of default values. again keys have
-     *                         to be the same like in $prompts.  Do not depend
-     *                         on a default value being set.
-     * @return array input sent by the user
-     * @abstract
-     */
-    function userDialog($command, $prompts, $types = array(), $defaults = array())
-    {
-    }
-}                                                                                                                                                                                                                           PEAR-1.8.0/PEAR/Installer.php                                                                       100664     764     764       211556      100664  10554                                                                                                                                                                                                                                                                                                                                                                      <?php
+?>                                                                                                                                                                                                                                                                                                                                                                       PEAR-1.9.0/PEAR/Frontend.php                                                                        100664     764     764        15077      100664  10357                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_Frontend, the singleton-based frontend for user input/output
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Frontend.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * Include error handling
+ */
+//require_once 'PEAR.php';
+
+/**
+ * Which user interface class is being used.
+ * @var string class name
+ */
+$GLOBALS['_PEAR_FRONTEND_CLASS'] = 'PEAR_Frontend_CLI';
+
+/**
+ * Instance of $_PEAR_Command_uiclass.
+ * @var object
+ */
+$GLOBALS['_PEAR_FRONTEND_SINGLETON'] = null;
+
+/**
+ * Singleton-based frontend for PEAR user input/output
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Frontend extends PEAR
+{
+    /**
+     * Retrieve the frontend object
+     * @return PEAR_Frontend_CLI|PEAR_Frontend_Web|PEAR_Frontend_Gtk
+     * @static
+     */
+    function &singleton($type = null)
+    {
+        if ($type === null) {
+            if (!isset($GLOBALS['_PEAR_FRONTEND_SINGLETON'])) {
+                $a = false;
+                return $a;
+            }
+            return $GLOBALS['_PEAR_FRONTEND_SINGLETON'];
+        }
+
+        $a = PEAR_Frontend::setFrontendClass($type);
+        return $a;
+    }
+
+    /**
+     * Set the frontend class that will be used by calls to {@link singleton()}
+     *
+     * Frontends are expected to conform to the PEAR naming standard of
+     * _ => DIRECTORY_SEPARATOR (PEAR_Frontend_CLI is in PEAR/Frontend/CLI.php)
+     * @param string $uiclass full class name
+     * @return PEAR_Frontend
+     * @static
+     */
+    function &setFrontendClass($uiclass)
+    {
+        if (is_object($GLOBALS['_PEAR_FRONTEND_SINGLETON']) &&
+              is_a($GLOBALS['_PEAR_FRONTEND_SINGLETON'], $uiclass)) {
+            return $GLOBALS['_PEAR_FRONTEND_SINGLETON'];
+        }
+
+        if (!class_exists($uiclass)) {
+            $file = str_replace('_', '/', $uiclass) . '.php';
+            if (PEAR_Frontend::isIncludeable($file)) {
+                include_once $file;
+            }
+        }
+
+        if (class_exists($uiclass)) {
+            $obj = &new $uiclass;
+            // quick test to see if this class implements a few of the most
+            // important frontend methods
+            if (is_a($obj, 'PEAR_Frontend')) {
+                $GLOBALS['_PEAR_FRONTEND_SINGLETON'] = &$obj;
+                $GLOBALS['_PEAR_FRONTEND_CLASS'] = $uiclass;
+                return $obj;
+            }
+
+            $err = PEAR::raiseError("not a frontend class: $uiclass");
+            return $err;
+        }
+
+        $err = PEAR::raiseError("no such class: $uiclass");
+        return $err;
+    }
+
+    /**
+     * Set the frontend class that will be used by calls to {@link singleton()}
+     *
+     * Frontends are expected to be a descendant of PEAR_Frontend
+     * @param PEAR_Frontend
+     * @return PEAR_Frontend
+     * @static
+     */
+    function &setFrontendObject($uiobject)
+    {
+        if (is_object($GLOBALS['_PEAR_FRONTEND_SINGLETON']) &&
+              is_a($GLOBALS['_PEAR_FRONTEND_SINGLETON'], get_class($uiobject))) {
+            return $GLOBALS['_PEAR_FRONTEND_SINGLETON'];
+        }
+
+        if (!is_a($uiobject, 'PEAR_Frontend')) {
+            $err = PEAR::raiseError('not a valid frontend class: (' .
+                get_class($uiobject) . ')');
+            return $err;
+        }
+
+        $GLOBALS['_PEAR_FRONTEND_SINGLETON'] = &$uiobject;
+        $GLOBALS['_PEAR_FRONTEND_CLASS'] = get_class($uiobject);
+        return $uiobject;
+    }
+
+    /**
+     * @param string $path relative or absolute include path
+     * @return boolean
+     * @static
+     */
+    function isIncludeable($path)
+    {
+        if (file_exists($path) && is_readable($path)) {
+            return true;
+        }
+
+        $fp = @fopen($path, 'r', true);
+        if ($fp) {
+            fclose($fp);
+            return true;
+        }
+
+        return false;
+    }
+
+    /**
+     * @param PEAR_Config
+     */
+    function setConfig(&$config)
+    {
+    }
+
+    /**
+     * This can be overridden to allow session-based temporary file management
+     *
+     * By default, all files are deleted at the end of a session.  The web installer
+     * needs to be able to sustain a list over many sessions in order to support
+     * user interaction with install scripts
+     */
+    function addTempFile($file)
+    {
+        $GLOBALS['_PEAR_Common_tempfiles'][] = $file;
+    }
+
+    /**
+     * Log an action
+     *
+     * @param string $msg the message to log
+     * @param boolean $append_crlf
+     * @return boolean true
+     * @abstract
+     */
+    function log($msg, $append_crlf = true)
+    {
+    }
+
+    /**
+     * Run a post-installation script
+     *
+     * @param array $scripts array of post-install scripts
+     * @abstract
+     */
+    function runPostinstallScripts(&$scripts)
+    {
+    }
+
+    /**
+     * Display human-friendly output formatted depending on the
+     * $command parameter.
+     *
+     * This should be able to handle basic output data with no command
+     * @param mixed  $data    data structure containing the information to display
+     * @param string $command command from which this method was called
+     * @abstract
+     */
+    function outputData($data, $command = '_default')
+    {
+    }
+
+    /**
+     * Display a modal form dialog and return the given input
+     *
+     * A frontend that requires multiple requests to retrieve and process
+     * data must take these needs into account, and implement the request
+     * handling code.
+     * @param string $command  command from which this method was called
+     * @param array  $prompts  associative array. keys are the input field names
+     *                         and values are the description
+     * @param array  $types    array of input field types (text, password,
+     *                         etc.) keys have to be the same like in $prompts
+     * @param array  $defaults array of default values. again keys have
+     *                         to be the same like in $prompts.  Do not depend
+     *                         on a default value being set.
+     * @return array input sent by the user
+     * @abstract
+     */
+    function userDialog($command, $prompts, $types = array(), $defaults = array())
+    {
+    }
+}                                                                                                                                                                                                                                                                                                                                                                                                                                                                 PEAR-1.9.0/PEAR/Installer.php                                                                       100664     764     764       210603      100664  10545                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Installer
  *
@@ -43558,7 +44088,7 @@ class PEAR_Frontend extends PEAR
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Installer.php,v 1.259 2009/04/09 00:55:07 dufuz Exp $
+ * @version    CVS: $Id: Installer.php 287446 2009-08-18 11:45:05Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -43582,7 +44112,7 @@ define('PEAR_INSTALLER_NOBINARY', -240);
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -44672,7 +45202,6 @@ class PEAR_Installer extends PEAR_Downloader
      *
      * @return array|PEAR_Error package info if successful
      */
-
     function install($pkgfile, $options = array())
     {
         $this->_options = $options;
@@ -44686,7 +45215,7 @@ class PEAR_Installer extends PEAR_Downloader
         } else {
             $descfile = $pkgfile;
             $tmpdir   = '';
-            $pkg      = &$this->_parsePackageXml($descfile, $tmpdir);
+            $pkg      = $this->_parsePackageXml($descfile, $tmpdir);
             if (PEAR::isError($pkg)) {
                 return $pkg;
             }
@@ -44940,11 +45469,7 @@ class PEAR_Installer extends PEAR_Downloader
         }
 
         $p = &$installregistry->getPackage($pkgname, $channel);
-        if (empty($options['register-only']) && $p) {
-            $dirtree = $p->getDirTree();
-        } else {
-            $dirtree = false;
-        }
+        $dirtree = (empty($options['register-only']) && $p) ? $p->getDirTree() : false;
 
         $pkg->resetFilelist();
         $pkg->setLastInstalledVersion($installregistry->packageInfo($pkg->getPackage(),
@@ -45117,11 +45642,8 @@ class PEAR_Installer extends PEAR_Downloader
             }
 
             $copyto = $this->_prependPath($dest, $packagingroot);
-            if ($copyto != $dest) {
-                $this->log(1, "Installing '$dest' as '$copyto'");
-            } else {
-                $this->log(1, "Installing '$dest'");
-            }
+            $extra  = $copyto != $dest ? " as '$copyto'" : '';
+            $this->log(1, "Installing '$dest'$extra");
 
             $copydir = dirname($copyto);
             // pretty much nothing happens if we are only registering the install
@@ -45150,24 +45672,20 @@ class PEAR_Installer extends PEAR_Downloader
                 }
             }
 
+
+            $data = array(
+                'role'         => $role,
+                'name'         => $bn,
+                'installed_as' => $dest,
+                'php_api'      => $ext['php_api'],
+                'zend_mod_api' => $ext['zend_mod_api'],
+                'zend_ext_api' => $ext['zend_ext_api'],
+            );
+
             if ($filelist->getPackageXmlVersion() == '1.0') {
-                $filelist->installedFile($bn, array(
-                    'role' => $role,
-                    'name' => $bn,
-                    'installed_as' => $dest,
-                    'php_api' => $ext['php_api'],
-                    'zend_mod_api' => $ext['zend_mod_api'],
-                    'zend_ext_api' => $ext['zend_ext_api'],
-                    ));
+                $filelist->installedFile($bn, $data);
             } else {
-                $filelist->installedFile($bn, array('attribs' => array(
-                    'role' => $role,
-                    'name' => $bn,
-                    'installed_as' => $dest,
-                    'php_api' => $ext['php_api'],
-                    'zend_mod_api' => $ext['zend_mod_api'],
-                    'zend_ext_api' => $ext['zend_ext_api'],
-                    )));
+                $filelist->installedFile($bn, array('attribs' => $data));
             }
         }
     }
@@ -45194,11 +45712,8 @@ class PEAR_Installer extends PEAR_Downloader
      */
     function uninstall($package, $options = array())
     {
-        if (isset($options['installroot'])) {
-            $this->config->setInstallRoot($options['installroot']);
-        } else {
-            $this->config->setInstallRoot('');
-        }
+        $installRoot = isset($options['installroot']) ? $options['installroot'] : '';
+        $this->config->setInstallRoot($installRoot);
 
         $this->installroot = '';
         $this->_registry = &$this->config->getRegistry();
@@ -45291,17 +45806,18 @@ class PEAR_Installer extends PEAR_Downloader
                 }
             } else {
                 $this->startFileTransaction();
-                if ($dirtree = $pkg->getDirTree()) {
-                    // attempt to delete empty directories
-                    uksort($dirtree, array($this, '_sortDirs'));
-                    foreach($dirtree as $dir => $notused) {
-                        $this->addFileOperation('rmdir', array($dir));
-                    }
-                } else {
+                $dirtree = $pkg->getDirTree();
+                if ($dirtree === false) {
                     $this->configSet('default_channel', $savechannel);
                     return $this->_registry->deletePackage($package, $channel);
                 }
 
+                // attempt to delete empty directories
+                uksort($dirtree, array($this, '_sortDirs'));
+                foreach($dirtree as $dir => $notused) {
+                    $this->addFileOperation('rmdir', array($dir));
+                }
+
                 if (!$this->commitFileTransaction()) {
                     $this->rollbackFileTransaction();
                     if (!isset($options['ignore-errors'])) {
@@ -45380,7 +45896,7 @@ class PEAR_Installer extends PEAR_Downloader
     }
 
     // }}}
-}                                                                                                                                                  PEAR-1.8.0/PEAR/PackageFile.php                                                                     100664     764     764        37507      100664  10734                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                             PEAR-1.9.0/PEAR/PackageFile.php                                                                     100664     764     764        37466      100664  10741                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_PackageFile, package.xml parsing utility class
  *
@@ -45391,7 +45907,7 @@ class PEAR_Installer extends PEAR_Downloader
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: PackageFile.php,v 1.48 2009/04/09 22:16:26 dufuz Exp $
+ * @version    CVS: $Id: PackageFile.php 286670 2009-08-02 14:16:06Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -45417,7 +45933,7 @@ define('PEAR_PACKAGEFILE_ERROR_INVALID_PACKAGEVERSION', 2);
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -45587,9 +46103,10 @@ class PEAR_PackageFile
                 return $pf;
             }
 
-            if (!$pf->validate($state)) {
+            if (!$pf->validate($state)) {;
                 if ($this->_config->get('verbose') > 0
-                    && $this->_logger && $pf->getValidationWarnings(false)) {
+                    && $this->_logger && $pf->getValidationWarnings(false)
+                ) {
                     foreach ($pf->getValidationWarnings(false) as $warning) {
                         $this->_logger->log(0, 'ERROR: ' . $warning['message']);
                     }
@@ -45705,11 +46222,11 @@ class PEAR_PackageFile
             $ret = PEAR::raiseError("Could not get contents of package \"$file\"".
                                      '. Invalid tgz file.');
             return $ret;
-        } else {
-            if (!count($content) && !@is_file($file)) {
-                $ret = PEAR::raiseError("could not open file \"$file\"");
-                return $ret;
-            }
+        }
+
+        if (!count($content) && !@is_file($file)) {
+            $ret = PEAR::raiseError("could not open file \"$file\"");
+            return $ret;
         }
 
         $xml      = null;
@@ -45879,7 +46396,7 @@ class PEAR_PackageFile
         $info = PEAR::raiseError("Cannot open '$info' for parsing");
         return $info;
     }
-}                                                                                                                                                                                         PEAR-1.8.0/PEAR/Packager.php                                                                        100664     764     764        15603      100664  10307                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                                          PEAR-1.9.0/PEAR/Packager.php                                                                        100664     764     764        17151      100664  10310                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Packager for generating releases
  *
@@ -45892,7 +46409,7 @@ class PEAR_PackageFile
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Packager.php,v 1.75 2009/02/24 23:38:22 dufuz Exp $
+ * @version    CVS: $Id: Packager.php 286809 2009-08-04 15:10:26Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -45912,7 +46429,7 @@ require_once 'System.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -46044,6 +46561,12 @@ class PEAR_Packager extends PEAR_Common
                 $this->log(1, 'Tag the released code with "pear cvstag ' .
                     $main->getPackageFile() . '"');
                 $this->log(1, "(or set the CVS tag $cvstag by hand)");
+            } elseif (file_exists("$pkgdir/.svn")) {
+                $svnversion = preg_replace('/[^a-z0-9]/i', '.', $pf->getVersion());
+                $svntag = $pf->getName() . "-$svnversion";
+                $this->log(1, 'Tag the released code with "pear svntag ' .
+                    $main->getPackageFile() . '"');
+                $this->log(1, "(or set the SVN tag $svntag by hand)");
             }
         } else { // this branch is executed for single packagefile packaging
             $gen = &$pf->getDefaultGenerator();
@@ -46063,2363 +46586,2411 @@ class PEAR_Packager extends PEAR_Common
                 $cvstag = "RELEASE_$cvsversion";
                 $this->log(1, "Tag the released code with `pear cvstag $pkgfile'");
                 $this->log(1, "(or set the CVS tag $cvstag by hand)");
+            } elseif (file_exists("$pkgdir/.svn")) {
+                $svnversion = preg_replace('/[^a-z0-9]/i', '.', $pf->getVersion());
+                $svntag = $pf->getName() . "-$svnversion";
+                $this->log(1, "Tag the released code with `pear svntag $pkgfile'");
+                $this->log(1, "(or set the SVN tag $svntag by hand)");
             }
         }
 
         return $dest_package;
     }
-}                                                                                                                             PEAR-1.8.0/PEAR/Registry.php                                                                        100664     764     764       226577      100664  10440                                                                                                                                                                                                                                                                                                                                                                      <?php
-/**
- * PEAR_Registry
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Stig Bakken <ssb at php.net>
- * @author     Tomas V. V. Cox <cox at idecnet.com>
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Registry.php,v 1.179 2009/04/10 19:42:18 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 0.1
- */
-
-/**
- * for PEAR_Error
- */
-require_once 'PEAR.php';
-require_once 'PEAR/DependencyDB.php';
-
-define('PEAR_REGISTRY_ERROR_LOCK',         -2);
-define('PEAR_REGISTRY_ERROR_FORMAT',       -3);
-define('PEAR_REGISTRY_ERROR_FILE',         -4);
-define('PEAR_REGISTRY_ERROR_CONFLICT',     -5);
-define('PEAR_REGISTRY_ERROR_CHANNEL_FILE', -6);
-
-/**
- * Administration class used to maintain the installed package database.
- * @category   pear
- * @package    PEAR
- * @author     Stig Bakken <ssb at php.net>
- * @author     Tomas V. V. Cox <cox at idecnet.com>
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Registry extends PEAR
-{
-    /**
-     * File containing all channel information.
-     * @var string
-     */
-    var $channels = '';
-
-    /** Directory where registry files are stored.
-     * @var string
-     */
-    var $statedir = '';
-
-    /** File where the file map is stored
-     * @var string
-     */
-    var $filemap = '';
-
-    /** Directory where registry files for channels are stored.
-     * @var string
-     */
-    var $channelsdir = '';
-
-    /** Name of file used for locking the registry
-     * @var string
-     */
-    var $lockfile = '';
-
-    /** File descriptor used during locking
-     * @var resource
-     */
-    var $lock_fp = null;
-
-    /** Mode used during locking
-     * @var int
-     */
-    var $lock_mode = 0; // XXX UNUSED
-
-    /** Cache of package information.  Structure:
-     * array(
-     *   'package' => array('id' => ... ),
-     *   ... )
-     * @var array
-     */
-    var $pkginfo_cache = array();
-
-    /** Cache of file map.  Structure:
-     * array( '/path/to/file' => 'package', ... )
-     * @var array
-     */
-    var $filemap_cache = array();
-
-    /**
-     * @var false|PEAR_ChannelFile
-     */
-    var $_pearChannel;
-
-    /**
-     * @var false|PEAR_ChannelFile
-     */
-    var $_peclChannel;
-
-    /**
-     * @var false|PEAR_ChannelFile
-     */
-    var $_docChannel;
-
-    /**
-     * @var PEAR_DependencyDB
-     */
-    var $_dependencyDB;
-
-    /**
-     * @var PEAR_Config
-     */
-    var $_config;
-
-    /**
-     * PEAR_Registry constructor.
-     *
-     * @param string (optional) PEAR install directory (for .php files)
-     * @param PEAR_ChannelFile PEAR_ChannelFile object representing the PEAR channel, if
-     *        default values are not desired.  Only used the very first time a PEAR
-     *        repository is initialized
-     * @param PEAR_ChannelFile PEAR_ChannelFile object representing the PECL channel, if
-     *        default values are not desired.  Only used the very first time a PEAR
-     *        repository is initialized
-     *
-     * @access public
-     */
-    function PEAR_Registry($pear_install_dir = PEAR_INSTALL_DIR, $pear_channel = false,
-                           $pecl_channel = false)
-    {
-        parent::PEAR();
-        $this->setInstallDir($pear_install_dir);
-        $this->_pearChannel = $pear_channel;
-        $this->_peclChannel = $pecl_channel;
-        $this->_config      = false;
-    }
-
-    function setInstallDir($pear_install_dir = PEAR_INSTALL_DIR)
-    {
-        $ds = DIRECTORY_SEPARATOR;
-        $this->install_dir = $pear_install_dir;
-        $this->channelsdir = $pear_install_dir.$ds.'.channels';
-        $this->statedir    = $pear_install_dir.$ds.'.registry';
-        $this->filemap     = $pear_install_dir.$ds.'.filemap';
-        $this->lockfile    = $pear_install_dir.$ds.'.lock';
-    }
-
-    function hasWriteAccess()
-    {
-        if (!file_exists($this->install_dir)) {
-            $dir = $this->install_dir;
-            while ($dir && $dir != '.') {
-                $olddir = $dir;
-                $dir    = dirname($dir);
-                if ($dir != '.' && file_exists($dir)) {
-                    if (is_writeable($dir)) {
-                        return true;
-                    }
-
-                    return false;
-                }
-
-                if ($dir == $olddir) { // this can happen in safe mode
-                    return @is_writable($dir);
-                }
-            }
-
-            return false;
-        }
-
-        return is_writeable($this->install_dir);
-    }
-
-    function setConfig(&$config, $resetInstallDir = true)
-    {
-        $this->_config = &$config;
-        if ($resetInstallDir) {
-            $this->setInstallDir($config->get('php_dir'));
-        }
-    }
-
-    function _initializeChannelDirs()
-    {
-        static $running = false;
-        if (!$running) {
-            $running = true;
-            $ds = DIRECTORY_SEPARATOR;
-            if (!is_dir($this->channelsdir) ||
-                  !file_exists($this->channelsdir . $ds . 'pear.php.net.reg') ||
-                  !file_exists($this->channelsdir . $ds . 'pecl.php.net.reg') ||
-                  !file_exists($this->channelsdir . $ds . 'doc.php.net.reg') ||
-                  !file_exists($this->channelsdir . $ds . '__uri.reg')) {
-                if (!file_exists($this->channelsdir . $ds . 'pear.php.net.reg')) {
-                    $pear_channel = $this->_pearChannel;
-                    if (!is_a($pear_channel, 'PEAR_ChannelFile') || !$pear_channel->validate()) {
-                        if (!class_exists('PEAR_ChannelFile')) {
-                            require_once 'PEAR/ChannelFile.php';
-                        }
-
-                        $pear_channel = new PEAR_ChannelFile;
-                        $pear_channel->setName('pear.php.net');
-                        $pear_channel->setAlias('pear');
-                        $pear_channel->setServer('pear.php.net');
-                        $pear_channel->setSummary('PHP Extension and Application Repository');
-                        $pear_channel->setDefaultPEARProtocols();
-                        $pear_channel->setBaseURL('REST1.0', 'http://pear.php.net/rest/');
-                        $pear_channel->setBaseURL('REST1.1', 'http://pear.php.net/rest/');
-                    } else {
-                        $pear_channel->setName('pear.php.net');
-                        $pear_channel->setAlias('pear');
-                    }
-
-                    $pear_channel->validate();
-                    $this->_addChannel($pear_channel);
-                }
-
-                if (!file_exists($this->channelsdir . $ds . 'pecl.php.net.reg')) {
-                    $pecl_channel = $this->_peclChannel;
-                    if (!is_a($pecl_channel, 'PEAR_ChannelFile') || !$pecl_channel->validate()) {
-                        if (!class_exists('PEAR_ChannelFile')) {
-                            require_once 'PEAR/ChannelFile.php';
-                        }
-
-                        $pecl_channel = new PEAR_ChannelFile;
-                        $pecl_channel->setName('pecl.php.net');
-                        $pecl_channel->setAlias('pecl');
-                        $pecl_channel->setServer('pecl.php.net');
-                        $pecl_channel->setSummary('PHP Extension Community Library');
-                        $pecl_channel->setDefaultPEARProtocols();
-                        $pecl_channel->setBaseURL('REST1.0', 'http://pecl.php.net/rest/');
-                        $pecl_channel->setBaseURL('REST1.1', 'http://pecl.php.net/rest/');
-                        $pecl_channel->setValidationPackage('PEAR_Validator_PECL', '1.0');
-                    } else {
-                        $pecl_channel->setName('pecl.php.net');
-                        $pecl_channel->setAlias('pecl');
-                    }
-
-                    $pecl_channel->validate();
-                    $this->_addChannel($pecl_channel);
-                }
-
-                if (!file_exists($this->channelsdir . $ds . 'doc.php.net.reg')) {
-                    $doc_channel = $this->_docChannel;
-                    if (!is_a($doc_channel, 'PEAR_ChannelFile') || !$doc_channel->validate()) {
-                        if (!class_exists('PEAR_ChannelFile')) {
-                            require_once 'PEAR/ChannelFile.php';
-                        }
-
-                        $doc_channel = new PEAR_ChannelFile;
-                        $doc_channel->setName('doc.php.net');
-                        $doc_channel->setAlias('phpdocs');
-                        $doc_channel->setServer('doc.php.net');
-                        $doc_channel->setSummary('PHP Documentation Team');
-                        $doc_channel->setDefaultPEARProtocols();
-                        $doc_channel->setBaseURL('REST1.0', 'http://doc.php.net/Chiara_PEAR_Server_REST/');
-                        $doc_channel->setBaseURL('REST1.1', 'http://doc.php.net/Chiara_PEAR_Server_REST/');
-                    } else {
-                        $doc_channel->setName('doc.php.net');
-                        $doc_channel->setAlias('doc');
-                    }
-
-                    $doc_channel->validate();
-                    $this->_addChannel($doc_channel);
-                }
-
-                if (!file_exists($this->channelsdir . $ds . '__uri.reg')) {
-                    if (!class_exists('PEAR_ChannelFile')) {
-                        require_once 'PEAR/ChannelFile.php';
-                    }
-
-                    $private = new PEAR_ChannelFile;
-                    $private->setName('__uri');
-                    $private->setDefaultPEARProtocols();
-                    $private->setBaseURL('REST1.0', '****');
-                    $private->setSummary('Pseudo-channel for static packages');
-                    $this->_addChannel($private);
-                }
-                $this->_rebuildFileMap();
-            }
-
-            $running = false;
-        }
-    }
-
-    function _initializeDirs()
-    {
-        $ds = DIRECTORY_SEPARATOR;
-        // XXX Compatibility code should be removed in the future
-        // rename all registry files if any to lowercase
-        if (!OS_WINDOWS && file_exists($this->statedir) && is_dir($this->statedir) &&
-              $handle = opendir($this->statedir)) {
-            $dest = $this->statedir . $ds;
-            while (false !== ($file = readdir($handle))) {
-                if (preg_match('/^.*[A-Z].*\.reg\\z/', $file)) {
-                    rename($dest . $file, $dest . strtolower($file));
-                }
-            }
-            closedir($handle);
-        }
-
-        $this->_initializeChannelDirs();
-        if (!file_exists($this->filemap)) {
-            $this->_rebuildFileMap();
-        }
-        $this->_initializeDepDB();
-    }
-
-    function _initializeDepDB()
-    {
-        if (!isset($this->_dependencyDB)) {
-            static $initializing = false;
-            if (!$initializing) {
-                $initializing = true;
-                if (!$this->_config) { // never used?
-                    $file = OS_WINDOWS ? 'pear.ini' : '.pearrc';
-                    $this->_config = &new PEAR_Config($this->statedir . DIRECTORY_SEPARATOR .
-                        $file);
-                    $this->_config->setRegistry($this);
-                    $this->_config->set('php_dir', $this->install_dir);
-                }
-
-                $this->_dependencyDB = &PEAR_DependencyDB::singleton($this->_config);
-                if (PEAR::isError($this->_dependencyDB)) {
-                    // attempt to recover by removing the dep db
-                    if (file_exists($this->_config->get('php_dir', null, 'pear.php.net') .
-                        DIRECTORY_SEPARATOR . '.depdb')) {
-                        @unlink($this->_config->get('php_dir', null, 'pear.php.net') .
-                            DIRECTORY_SEPARATOR . '.depdb');
-                    }
-
-                    $this->_dependencyDB = &PEAR_DependencyDB::singleton($this->_config);
-                    if (PEAR::isError($this->_dependencyDB)) {
-                        echo $this->_dependencyDB->getMessage();
-                        echo 'Unrecoverable error';
-                        exit(1);
-                    }
-                }
-
-                $initializing = false;
-            }
-        }
-    }
-
-    /**
-     * PEAR_Registry destructor.  Makes sure no locks are forgotten.
-     *
-     * @access private
-     */
-    function _PEAR_Registry()
-    {
-        parent::_PEAR();
-        if (is_resource($this->lock_fp)) {
-            $this->_unlock();
-        }
-    }
-
-    /**
-     * Make sure the directory where we keep registry files exists.
-     *
-     * @return bool TRUE if directory exists, FALSE if it could not be
-     * created
-     *
-     * @access private
-     */
-    function _assertStateDir($channel = false)
-    {
-        if ($channel && $this->_getChannelFromAlias($channel) != 'pear.php.net') {
-            return $this->_assertChannelStateDir($channel);
-        }
-
-        static $init = false;
-        if (!file_exists($this->statedir)) {
-            if (!$this->hasWriteAccess()) {
-                return false;
-            }
-
-            require_once 'System.php';
-            if (!System::mkdir(array('-p', $this->statedir))) {
-                return $this->raiseError("could not create directory '{$this->statedir}'");
-            }
-            $init = true;
-        } elseif (!is_dir($this->statedir)) {
-            return $this->raiseError('Cannot create directory ' . $this->statedir . ', ' .
-                'it already exists and is not a directory');
-        }
-
-        $ds = DIRECTORY_SEPARATOR;
-        if (!file_exists($this->channelsdir)) {
-            if (!file_exists($this->channelsdir . $ds . 'pear.php.net.reg') ||
-                  !file_exists($this->channelsdir . $ds . 'pecl.php.net.reg') ||
-                  !file_exists($this->channelsdir . $ds . 'doc.php.net.reg') ||
-                  !file_exists($this->channelsdir . $ds . '__uri.reg')) {
-                $init = true;
-            }
-        } elseif (!is_dir($this->channelsdir)) {
-            return $this->raiseError('Cannot create directory ' . $this->channelsdir . ', ' .
-                'it already exists and is not a directory');
-        }
-
-        if ($init) {
-            static $running = false;
-            if (!$running) {
-                $running = true;
-                $this->_initializeDirs();
-                $running = false;
-                $init = false;
-            }
-        } else {
-            $this->_initializeDepDB();
-        }
-
-        return true;
-    }
-
-    /**
-     * Make sure the directory where we keep registry files exists for a non-standard channel.
-     *
-     * @param string channel name
-     * @return bool TRUE if directory exists, FALSE if it could not be
-     * created
-     *
-     * @access private
-     */
-    function _assertChannelStateDir($channel)
-    {
-        $ds = DIRECTORY_SEPARATOR;
-        if (!$channel || $this->_getChannelFromAlias($channel) == 'pear.php.net') {
-            if (!file_exists($this->channelsdir . $ds . 'pear.php.net.reg')) {
-                $this->_initializeChannelDirs();
-            }
-            return $this->_assertStateDir($channel);
-        }
-
-        $channelDir = $this->_channelDirectoryName($channel);
-        if (!is_dir($this->channelsdir) ||
-              !file_exists($this->channelsdir . $ds . 'pear.php.net.reg')) {
-            $this->_initializeChannelDirs();
-        }
-
-        if (!file_exists($channelDir)) {
-            if (!$this->hasWriteAccess()) {
-                return false;
-            }
-
-            require_once 'System.php';
-            if (!System::mkdir(array('-p', $channelDir))) {
-                return $this->raiseError("could not create directory '" . $channelDir .
-                    "'");
-            }
-        } elseif (!is_dir($channelDir)) {
-            return $this->raiseError("could not create directory '" . $channelDir .
-                "', already exists and is not a directory");
-        }
-
-        return true;
-    }
-
-    /**
-     * Make sure the directory where we keep registry files for channels exists
-     *
-     * @return bool TRUE if directory exists, FALSE if it could not be
-     * created
-     *
-     * @access private
-     */
-    function _assertChannelDir()
-    {
-        if (!file_exists($this->channelsdir)) {
-            if (!$this->hasWriteAccess()) {
-                return false;
-            }
-
-            require_once 'System.php';
-            if (!System::mkdir(array('-p', $this->channelsdir))) {
-                return $this->raiseError("could not create directory '{$this->channelsdir}'");
-            }
-        } elseif (!is_dir($this->channelsdir)) {
-            return $this->raiseError("could not create directory '{$this->channelsdir}" .
-                "', it already exists and is not a directory");
-        }
-
-        if (!file_exists($this->channelsdir . DIRECTORY_SEPARATOR . '.alias')) {
-            if (!$this->hasWriteAccess()) {
-                return false;
-            }
-
-            require_once 'System.php';
-            if (!System::mkdir(array('-p', $this->channelsdir . DIRECTORY_SEPARATOR . '.alias'))) {
-                return $this->raiseError("could not create directory '{$this->channelsdir}/.alias'");
-            }
-        } elseif (!is_dir($this->channelsdir . DIRECTORY_SEPARATOR . '.alias')) {
-            return $this->raiseError("could not create directory '{$this->channelsdir}" .
-                "/.alias', it already exists and is not a directory");
-        }
-
-        return true;
-    }
-
-    /**
-     * Get the name of the file where data for a given package is stored.
-     *
-     * @param string channel name, or false if this is a PEAR package
-     * @param string package name
-     *
-     * @return string registry file name
-     *
-     * @access public
-     */
-    function _packageFileName($package, $channel = false)
-    {
-        if ($channel && $this->_getChannelFromAlias($channel) != 'pear.php.net') {
-            return $this->_channelDirectoryName($channel) . DIRECTORY_SEPARATOR .
-                strtolower($package) . '.reg';
-        }
-
-        return $this->statedir . DIRECTORY_SEPARATOR . strtolower($package) . '.reg';
-    }
-
-    /**
-     * Get the name of the file where data for a given channel is stored.
-     * @param string channel name
-     * @return string registry file name
-     */
-    function _channelFileName($channel, $noaliases = false)
-    {
-        if (!$noaliases) {
-            if (file_exists($this->_getChannelAliasFileName($channel))) {
-                $channel = implode('', file($this->_getChannelAliasFileName($channel)));
-            }
-        }
-        return $this->channelsdir . DIRECTORY_SEPARATOR . str_replace('/', '_',
-            strtolower($channel)) . '.reg';
-    }
-
-    /**
-     * @param string
-     * @return string
-     */
-    function _getChannelAliasFileName($alias)
-    {
-        return $this->channelsdir . DIRECTORY_SEPARATOR . '.alias' .
-              DIRECTORY_SEPARATOR . str_replace('/', '_', strtolower($alias)) . '.txt';
-    }
-
-    /**
-     * Get the name of a channel from its alias
-     */
-    function _getChannelFromAlias($channel)
-    {
-        if (!$this->_channelExists($channel)) {
-            if ($channel == 'pear.php.net') {
-                return 'pear.php.net';
-            }
-
-            if ($channel == 'pecl.php.net') {
-                return 'pecl.php.net';
-            }
-
-            if ($channel == 'doc.php.net') {
-                return 'doc.php.net';
-            }
-
-            if ($channel == '__uri') {
-                return '__uri';
-            }
-
-            return false;
-        }
-
-        $channel = strtolower($channel);
-        if (file_exists($this->_getChannelAliasFileName($channel))) {
-            // translate an alias to an actual channel
-            return implode('', file($this->_getChannelAliasFileName($channel)));
-        }
-
-        return $channel;
-    }
-
-    /**
-     * Get the alias of a channel from its alias or its name
-     */
-    function _getAlias($channel)
-    {
-        if (!$this->_channelExists($channel)) {
-            if ($channel == 'pear.php.net') {
-                return 'pear';
-            }
-
-            if ($channel == 'pecl.php.net') {
-                return 'pecl';
-            }
-
-            if ($channel == 'doc.php.net') {
-                return 'phpdocs';
-            }
-
-            return false;
-        }
-
-        $channel = $this->_getChannel($channel);
-        if (PEAR::isError($channel)) {
-            return $channel;
-        }
-
-        return $channel->getAlias();
-    }
-
-    /**
-     * Get the name of the file where data for a given package is stored.
-     *
-     * @param string channel name, or false if this is a PEAR package
-     * @param string package name
-     *
-     * @return string registry file name
-     *
-     * @access public
-     */
-    function _channelDirectoryName($channel)
-    {
-        if (!$channel || $this->_getChannelFromAlias($channel) == 'pear.php.net') {
-            return $this->statedir;
-        }
-
-        $ch = $this->_getChannelFromAlias($channel);
-        if (!$ch) {
-            $ch = $channel;
-        }
-
-        return $this->statedir . DIRECTORY_SEPARATOR . strtolower('.channel.' .
-            str_replace('/', '_', $ch));
-    }
-
-    function _openPackageFile($package, $mode, $channel = false)
-    {
-        if (!$this->_assertStateDir($channel)) {
-            return null;
-        }
-
-        if (!in_array($mode, array('r', 'rb')) && !$this->hasWriteAccess()) {
-            return null;
-        }
-
-        $file = $this->_packageFileName($package, $channel);
-        if (!file_exists($file) && $mode == 'r' || $mode == 'rb') {
-            return null;
-        }
-
-        $fp = @fopen($file, $mode);
-        if (!$fp) {
-            return null;
-        }
-
-        return $fp;
-    }
-
-    function _closePackageFile($fp)
-    {
-        fclose($fp);
-    }
-
-    function _openChannelFile($channel, $mode)
-    {
-        if (!$this->_assertChannelDir()) {
-            return null;
-        }
-
-        if (!in_array($mode, array('r', 'rb')) && !$this->hasWriteAccess()) {
-            return null;
-        }
-
-        $file = $this->_channelFileName($channel);
-        if (!file_exists($file) && $mode == 'r' || $mode == 'rb') {
-            return null;
-        }
-
-        $fp = @fopen($file, $mode);
-        if (!$fp) {
-            return null;
-        }
-
-        return $fp;
-    }
-
-    function _closeChannelFile($fp)
-    {
-        fclose($fp);
-    }
-
-    function _rebuildFileMap()
-    {
-        if (!class_exists('PEAR_Installer_Role')) {
-            require_once 'PEAR/Installer/Role.php';
-        }
-
-        $channels = $this->_listAllPackages();
-        $files = array();
-        foreach ($channels as $channel => $packages) {
-            foreach ($packages as $package) {
-                $version = $this->_packageInfo($package, 'version', $channel);
-                $filelist = $this->_packageInfo($package, 'filelist', $channel);
-                if (!is_array($filelist)) {
-                    continue;
-                }
-
-                foreach ($filelist as $name => $attrs) {
-                    if (isset($attrs['attribs'])) {
-                        $attrs = $attrs['attribs'];
-                    }
-
-                    // it is possible for conflicting packages in different channels to
-                    // conflict with data files/doc files
-                    if ($name == 'dirtree') {
-                        continue;
-                    }
-
-                    if (isset($attrs['role']) && !in_array($attrs['role'],
-                          PEAR_Installer_Role::getInstallableRoles())) {
-                        // these are not installed
-                        continue;
-                    }
-
-                    if (isset($attrs['role']) && !in_array($attrs['role'],
-                          PEAR_Installer_Role::getBaseinstallRoles())) {
-                        $attrs['baseinstalldir'] = $package;
-                    }
-
-                    if (isset($attrs['baseinstalldir'])) {
-                        $file = $attrs['baseinstalldir'].DIRECTORY_SEPARATOR.$name;
-                    } else {
-                        $file = $name;
-                    }
-
-                    $file = preg_replace(',^/+,', '', $file);
-                    if ($channel != 'pear.php.net') {
-                        if (!isset($files[$attrs['role']])) {
-                            $files[$attrs['role']] = array();
-                        }
-                        $files[$attrs['role']][$file] = array(strtolower($channel),
-                            strtolower($package));
-                    } else {
-                        if (!isset($files[$attrs['role']])) {
-                            $files[$attrs['role']] = array();
-                        }
-                        $files[$attrs['role']][$file] = strtolower($package);
-                    }
-                }
-            }
-        }
-
-
-        $this->_assertStateDir();
-        if (!$this->hasWriteAccess()) {
-            return false;
-        }
-
-        $fp = @fopen($this->filemap, 'wb');
-        if (!$fp) {
-            return false;
-        }
-
-        $this->filemap_cache = $files;
-        fwrite($fp, serialize($files));
-        fclose($fp);
-        return true;
-    }
-
-    function _readFileMap()
-    {
-        if (!file_exists($this->filemap)) {
-            return array();
-        }
-
-        $fp = @fopen($this->filemap, 'r');
-        if (!$fp) {
-            return $this->raiseError('PEAR_Registry: could not open filemap "' . $this->filemap . '"', PEAR_REGISTRY_ERROR_FILE, null, null, $php_errormsg);
-        }
-
-        clearstatcache();
-        $rt = get_magic_quotes_runtime();
-        set_magic_quotes_runtime(0);
-        $fsize = filesize($this->filemap);
-        fclose($fp);
-        $data = file_get_contents($this->filemap);
-        set_magic_quotes_runtime($rt);
-        $tmp = unserialize($data);
-        if (!$tmp && $fsize > 7) {
-            return $this->raiseError('PEAR_Registry: invalid filemap data', PEAR_REGISTRY_ERROR_FORMAT, null, null, $data);
-        }
-
-        $this->filemap_cache = $tmp;
-        return true;
-    }
-
-    /**
-     * Lock the registry.
-     *
-     * @param integer lock mode, one of LOCK_EX, LOCK_SH or LOCK_UN.
-     *                See flock manual for more information.
-     *
-     * @return bool TRUE on success, FALSE if locking failed, or a
-     *              PEAR error if some other error occurs (such as the
-     *              lock file not being writable).
-     *
-     * @access private
-     */
-    function _lock($mode = LOCK_EX)
-    {
-        if (stristr(php_uname(), 'Windows 9')) {
-            return true;
-        }
-
-        if ($mode != LOCK_UN && is_resource($this->lock_fp)) {
-            // XXX does not check type of lock (LOCK_SH/LOCK_EX)
-            return true;
-        }
-
-        if (!$this->_assertStateDir()) {
-            if ($mode == LOCK_EX) {
-                return $this->raiseError('Registry directory is not writeable by the current user');
-            }
-
-            return true;
-        }
-
-        $open_mode = 'w';
-        // XXX People reported problems with LOCK_SH and 'w'
-        if ($mode === LOCK_SH || $mode === LOCK_UN) {
-            if (!file_exists($this->lockfile)) {
-                touch($this->lockfile);
-            }
-            $open_mode = 'r';
-        }
-
-        if (!is_resource($this->lock_fp)) {
-            $this->lock_fp = @fopen($this->lockfile, $open_mode);
-        }
-
-        if (!is_resource($this->lock_fp)) {
-            $this->lock_fp = null;
-            return $this->raiseError("could not create lock file" .
-                                     (isset($php_errormsg) ? ": " . $php_errormsg : ""));
-        }
-
-        if (!(int)flock($this->lock_fp, $mode)) {
-            switch ($mode) {
-                case LOCK_SH: $str = 'shared';    break;
-                case LOCK_EX: $str = 'exclusive'; break;
-                case LOCK_UN: $str = 'unlock';    break;
-                default:      $str = 'unknown';   break;
-            }
-
-            //is resource at this point, close it on error.
-            fclose($this->lock_fp);
-            $this->lock_fp = null;
-            return $this->raiseError("could not acquire $str lock ($this->lockfile)",
-                                     PEAR_REGISTRY_ERROR_LOCK);
-        }
-
-        return true;
-    }
-
-    function _unlock()
-    {
-        $ret = $this->_lock(LOCK_UN);
-        if (is_resource($this->lock_fp)) {
-            fclose($this->lock_fp);
-        }
-
-        $this->lock_fp = null;
-        return $ret;
-    }
-
-    function _packageExists($package, $channel = false)
-    {
-        return file_exists($this->_packageFileName($package, $channel));
-    }
-
-    /**
-     * Determine whether a channel exists in the registry
-     * @param string Channel name
-     * @param bool if true, then aliases will be ignored
-     * @return boolean
-     */
-    function _channelExists($channel, $noaliases = false)
-    {
-        $a = file_exists($this->_channelFileName($channel, $noaliases));
-        if (!$a && $channel == 'pear.php.net') {
-            return true;
-        }
-
-        if (!$a && $channel == 'pecl.php.net') {
-            return true;
-        }
-
-        if (!$a && $channel == 'doc.php.net') {
-            return true;
-        }
-
-        return $a;
-    }
-
-    /**
-     * @param PEAR_ChannelFile Channel object
-     * @param donotuse
-     * @param string Last-Modified HTTP tag from remote request
-     * @return boolean|PEAR_Error True on creation, false if it already exists
-     */
-    function _addChannel($channel, $update = false, $lastmodified = false)
-    {
-        if (!is_a($channel, 'PEAR_ChannelFile')) {
-            return false;
-        }
-
-        if (!$channel->validate()) {
-            return false;
-        }
-
-        if (file_exists($this->_channelFileName($channel->getName()))) {
-            if (!$update) {
-                return false;
-            }
-
-            $checker = $this->_getChannel($channel->getName());
-            if (PEAR::isError($checker)) {
-                return $checker;
-            }
-
-            if ($channel->getAlias() != $checker->getAlias()) {
-                if (file_exists($this->_getChannelAliasFileName($checker->getAlias()))) {
-                    @unlink($this->_getChannelAliasFileName($checker->getAlias()));
-                }
-            }
-        } else {
-            if ($update && !in_array($channel->getName(), array('pear.php.net', 'pecl.php.net', 'doc.php.net'))) {
-                return false;
-            }
-        }
-
-        $ret = $this->_assertChannelDir();
-        if (PEAR::isError($ret)) {
-            return $ret;
-        }
-
-        $ret = $this->_assertChannelStateDir($channel->getName());
-        if (PEAR::isError($ret)) {
-            return $ret;
-        }
-
-        if ($channel->getAlias() != $channel->getName()) {
-            if (file_exists($this->_getChannelAliasFileName($channel->getAlias())) &&
-                  $this->_getChannelFromAlias($channel->getAlias()) != $channel->getName()) {
-                $channel->setAlias($channel->getName());
-            }
-
-            if (!$this->hasWriteAccess()) {
-                return false;
-            }
-
-            $fp = @fopen($this->_getChannelAliasFileName($channel->getAlias()), 'w');
-            if (!$fp) {
-                return false;
-            }
-
-            fwrite($fp, $channel->getName());
-            fclose($fp);
-        }
-
-        if (!$this->hasWriteAccess()) {
-            return false;
-        }
-
-        $fp = @fopen($this->_channelFileName($channel->getName()), 'wb');
-        if (!$fp) {
-            return false;
-        }
-
-        $info = $channel->toArray();
-        if ($lastmodified) {
-            $info['_lastmodified'] = $lastmodified;
-        } else {
-            $info['_lastmodified'] = date('r');
-        }
-
-        fwrite($fp, serialize($info));
-        fclose($fp);
-        return true;
-    }
-
-    /**
-     * Deletion fails if there are any packages installed from the channel
-     * @param string|PEAR_ChannelFile channel name
-     * @return boolean|PEAR_Error True on deletion, false if it doesn't exist
-     */
-    function _deleteChannel($channel)
-    {
-        if (!is_string($channel)) {
-            if (!is_a($channel, 'PEAR_ChannelFile')) {
-                return false;
-            }
-
-            if (!$channel->validate()) {
-                return false;
-            }
-            $channel = $channel->getName();
-        }
-
-        if ($this->_getChannelFromAlias($channel) == '__uri') {
-            return false;
-        }
-
-        if ($this->_getChannelFromAlias($channel) == 'pecl.php.net') {
-            return false;
-        }
-
-        if ($this->_getChannelFromAlias($channel) == 'doc.php.net') {
-            return false;
-        }
-
-        if (!$this->_channelExists($channel)) {
-            return false;
-        }
-
-        if (!$channel || $this->_getChannelFromAlias($channel) == 'pear.php.net') {
-            return false;
-        }
-
-        $channel = $this->_getChannelFromAlias($channel);
-        if ($channel == 'pear.php.net') {
-            return false;
-        }
-
-        $test = $this->_listChannelPackages($channel);
-        if (count($test)) {
-            return false;
-        }
-
-        $test = @rmdir($this->_channelDirectoryName($channel));
-        if (!$test) {
-            return false;
-        }
-
-        $file = $this->_getChannelAliasFileName($this->_getAlias($channel));
-        if (file_exists($file)) {
-            $test = @unlink($file);
-            if (!$test) {
-                return false;
-            }
-        }
-
-        $file = $this->_channelFileName($channel);
-        $ret = true;
-        if (file_exists($file)) {
-            $ret = @unlink($file);
-        }
-
-        return $ret;
-    }
-
-    /**
-     * Determine whether a channel exists in the registry
-     * @param string Channel Alias
-     * @return boolean
-     */
-    function _isChannelAlias($alias)
-    {
-        return file_exists($this->_getChannelAliasFileName($alias));
-    }
-
-    /**
-     * @param string|null
-     * @param string|null
-     * @param string|null
-     * @return array|null
-     * @access private
-     */
-    function _packageInfo($package = null, $key = null, $channel = 'pear.php.net')
-    {
-        if ($package === null) {
-            if ($channel === null) {
-                $channels = $this->_listChannels();
-                $ret = array();
-                foreach ($channels as $channel) {
-                    $channel = strtolower($channel);
-                    $ret[$channel] = array();
-                    $packages = $this->_listPackages($channel);
-                    foreach ($packages as $package) {
-                        $ret[$channel][] = $this->_packageInfo($package, null, $channel);
-                    }
-                }
-
-                return $ret;
-            }
-
-            $ps = $this->_listPackages($channel);
-            if (!count($ps)) {
-                return array();
-            }
-            return array_map(array(&$this, '_packageInfo'),
-                             $ps, array_fill(0, count($ps), null),
-                             array_fill(0, count($ps), $channel));
-        }
-
-        $fp = $this->_openPackageFile($package, 'r', $channel);
-        if ($fp === null) {
-            return null;
-        }
-
-        $rt = get_magic_quotes_runtime();
-        set_magic_quotes_runtime(0);
-        clearstatcache();
-        $this->_closePackageFile($fp);
-        $data = file_get_contents($this->_packageFileName($package, $channel));
-        set_magic_quotes_runtime($rt);
-        $data = unserialize($data);
-        if ($key === null) {
-            return $data;
-        }
-
-        // compatibility for package.xml version 2.0
-        if (isset($data['old'][$key])) {
-            return $data['old'][$key];
-        }
-
-        if (isset($data[$key])) {
-            return $data[$key];
-        }
-
-        return null;
-    }
-
-    /**
-     * @param string Channel name
-     * @param bool whether to strictly retrieve info of channels, not just aliases
-     * @return array|null
-     */
-    function _channelInfo($channel, $noaliases = false)
-    {
-        if (!$this->_channelExists($channel, $noaliases)) {
-            return null;
-        }
-
-        $fp = $this->_openChannelFile($channel, 'r');
-        if ($fp === null) {
-            return null;
-        }
-
-        $rt = get_magic_quotes_runtime();
-        set_magic_quotes_runtime(0);
-        clearstatcache();
-        $this->_closeChannelFile($fp);
-        $data = file_get_contents($this->_channelFileName($channel));
-        set_magic_quotes_runtime($rt);
-        $data = unserialize($data);
-        return $data;
-    }
-
-    function _listChannels()
-    {
-        $channellist = array();
-        if (!file_exists($this->channelsdir) || !is_dir($this->channelsdir)) {
-            return array('pear.php.net', 'pecl.php.net', 'doc.php.net', '__uri');
-        }
-
-        $dp = opendir($this->channelsdir);
-        while ($ent = readdir($dp)) {
-            if ($ent{0} == '.' || substr($ent, -4) != '.reg') {
-                continue;
-            }
-
-            if ($ent == '__uri.reg') {
-                $channellist[] = '__uri';
-                continue;
-            }
-
-            $channellist[] = str_replace('_', '/', substr($ent, 0, -4));
-        }
-
-        closedir($dp);
-        if (!in_array('pear.php.net', $channellist)) {
-            $channellist[] = 'pear.php.net';
-        }
-
-        if (!in_array('pecl.php.net', $channellist)) {
-            $channellist[] = 'pecl.php.net';
-        }
-
-        if (!in_array('doc.php.net', $channellist)) {
-            $channellist[] = 'doc.php.net';
-        }
-
-
-        if (!in_array('__uri', $channellist)) {
-            $channellist[] = '__uri';
-        }
-
-        natsort($channellist);
-        return $channellist;
-    }
-
-    function _listPackages($channel = false)
-    {
-        if ($channel && $this->_getChannelFromAlias($channel) != 'pear.php.net') {
-            return $this->_listChannelPackages($channel);
-        }
-
-        if (!file_exists($this->statedir) || !is_dir($this->statedir)) {
-            return array();
-        }
-
-        $pkglist = array();
-        $dp = opendir($this->statedir);
-        if (!$dp) {
-            return $pkglist;
-        }
-
-        while ($ent = readdir($dp)) {
-            if ($ent{0} == '.' || substr($ent, -4) != '.reg') {
-                continue;
-            }
-
-            $pkglist[] = substr($ent, 0, -4);
-        }
-        closedir($dp);
-        return $pkglist;
-    }
-
-    function _listChannelPackages($channel)
-    {
-        $pkglist = array();
-        if (!file_exists($this->_channelDirectoryName($channel)) ||
-              !is_dir($this->_channelDirectoryName($channel))) {
-            return array();
-        }
-
-        $dp = opendir($this->_channelDirectoryName($channel));
-        if (!$dp) {
-            return $pkglist;
-        }
-
-        while ($ent = readdir($dp)) {
-            if ($ent{0} == '.' || substr($ent, -4) != '.reg') {
-                continue;
-            }
-            $pkglist[] = substr($ent, 0, -4);
-        }
-
-        closedir($dp);
-        return $pkglist;
-    }
-
-    function _listAllPackages()
-    {
-        $ret = array();
-        foreach ($this->_listChannels() as $channel) {
-            $ret[$channel] = $this->_listPackages($channel);
-        }
-
-        return $ret;
-    }
-
-    /**
-     * Add an installed package to the registry
-     * @param string package name
-     * @param array package info (parsed by PEAR_Common::infoFrom*() methods)
-     * @return bool success of saving
-     * @access private
-     */
-    function _addPackage($package, $info)
-    {
-        if ($this->_packageExists($package)) {
-            return false;
-        }
-
-        $fp = $this->_openPackageFile($package, 'wb');
-        if ($fp === null) {
-            return false;
-        }
-
-        $info['_lastmodified'] = time();
-        fwrite($fp, serialize($info));
-        $this->_closePackageFile($fp);
-        if (isset($info['filelist'])) {
-            $this->_rebuildFileMap();
-        }
-
-        return true;
-    }
-
-    /**
-     * @param PEAR_PackageFile_v1|PEAR_PackageFile_v2
-     * @return bool
-     * @access private
-     */
-    function _addPackage2($info)
-    {
-        if (!is_a($info, 'PEAR_PackageFile_v1') && !is_a($info, 'PEAR_PackageFile_v2')) {
-            return false;
-        }
-
-        if (!$info->validate()) {
-            if (class_exists('PEAR_Common')) {
-                $ui = PEAR_Frontend::singleton();
-                if ($ui) {
-                    foreach ($info->getValidationWarnings() as $err) {
-                        $ui->log($err['message'], true);
-                    }
-                }
-            }
-            return false;
-        }
-
-        $channel = $info->getChannel();
-        $package = $info->getPackage();
-        $save = $info;
-        if ($this->_packageExists($package, $channel)) {
-            return false;
-        }
-
-        if (!$this->_channelExists($channel, true)) {
-            return false;
-        }
-
-        $info = $info->toArray(true);
-        if (!$info) {
-            return false;
-        }
-
-        $fp = $this->_openPackageFile($package, 'wb', $channel);
-        if ($fp === null) {
-            return false;
-        }
-
-        $info['_lastmodified'] = time();
-        fwrite($fp, serialize($info));
-        $this->_closePackageFile($fp);
-        $this->_rebuildFileMap();
-        return true;
-    }
-
-    /**
-     * @param string Package name
-     * @param array parsed package.xml 1.0
-     * @param bool this parameter is only here for BC.  Don't use it.
-     * @access private
-     */
-    function _updatePackage($package, $info, $merge = true)
-    {
-        $oldinfo = $this->_packageInfo($package);
-        if (empty($oldinfo)) {
-            return false;
-        }
-
-        $fp = $this->_openPackageFile($package, 'w');
-        if ($fp === null) {
-            return false;
-        }
-
-        if (is_object($info)) {
-            $info = $info->toArray();
-        }
-        $info['_lastmodified'] = time();
-
-        $newinfo = $info;
-        if ($merge) {
-            $info = array_merge($oldinfo, $info);
-        } else {
-            $diff = $info;
-        }
-
-        fwrite($fp, serialize($info));
-        $this->_closePackageFile($fp);
-        if (isset($newinfo['filelist'])) {
-            $this->_rebuildFileMap();
-        }
-
-        return true;
-    }
-
-    /**
-     * @param PEAR_PackageFile_v1|PEAR_PackageFile_v2
-     * @return bool
-     * @access private
-     */
-    function _updatePackage2($info)
-    {
-        if (!$this->_packageExists($info->getPackage(), $info->getChannel())) {
-            return false;
-        }
-
-        $fp = $this->_openPackageFile($info->getPackage(), 'w', $info->getChannel());
-        if ($fp === null) {
-            return false;
-        }
-
-        $save = $info;
-        $info = $save->getArray(true);
-        $info['_lastmodified'] = time();
-        fwrite($fp, serialize($info));
-        $this->_closePackageFile($fp);
-        $this->_rebuildFileMap();
-        return true;
-    }
-
-    /**
-     * @param string Package name
-     * @param string Channel name
-     * @return PEAR_PackageFile_v1|PEAR_PackageFile_v2|null
-     * @access private
-     */
-    function &_getPackage($package, $channel = 'pear.php.net')
-    {
-        $info = $this->_packageInfo($package, null, $channel);
-        if ($info === null) {
-            return $info;
-        }
-
-        $a = $this->_config;
-        if (!$a) {
-            $this->_config = &new PEAR_Config;
-            $this->_config->set('php_dir', $this->statedir);
-        }
-
-        if (!class_exists('PEAR_PackageFile')) {
-            require_once 'PEAR/PackageFile.php';
-        }
-
-        $pkg = &new PEAR_PackageFile($this->_config);
-        $pf = &$pkg->fromArray($info);
-        return $pf;
-    }
-
-    /**
-     * @param string channel name
-     * @param bool whether to strictly retrieve channel names
-     * @return PEAR_ChannelFile|PEAR_Error
-     * @access private
-     */
-    function &_getChannel($channel, $noaliases = false)
-    {
-        $ch = false;
-        if ($this->_channelExists($channel, $noaliases)) {
-            $chinfo = $this->_channelInfo($channel, $noaliases);
-            if ($chinfo) {
-                if (!class_exists('PEAR_ChannelFile')) {
-                    require_once 'PEAR/ChannelFile.php';
-                }
-
-                $ch = &PEAR_ChannelFile::fromArrayWithErrors($chinfo);
-            }
-        }
-
-        if ($ch) {
-            if ($ch->validate()) {
-                return $ch;
-            }
-
-            foreach ($ch->getErrors(true) as $err) {
-                $message = $err['message'] . "\n";
-            }
-
-            $ch = PEAR::raiseError($message);
-            return $ch;
-        }
-
-        if ($this->_getChannelFromAlias($channel) == 'pear.php.net') {
-            // the registry is not properly set up, so use defaults
-            if (!class_exists('PEAR_ChannelFile')) {
-                require_once 'PEAR/ChannelFile.php';
-            }
-
-            $pear_channel = new PEAR_ChannelFile;
-            $pear_channel->setName('pear.php.net');
-            $pear_channel->setAlias('pear');
-            $pear_channel->setSummary('PHP Extension and Application Repository');
-            $pear_channel->setDefaultPEARProtocols();
-            $pear_channel->setBaseURL('REST1.0', 'http://pear.php.net/rest/');
-            $pear_channel->setBaseURL('REST1.1', 'http://pear.php.net/rest/');
-            return $pear_channel;
-        }
-
-        if ($this->_getChannelFromAlias($channel) == 'pecl.php.net') {
-            // the registry is not properly set up, so use defaults
-            if (!class_exists('PEAR_ChannelFile')) {
-                require_once 'PEAR/ChannelFile.php';
-            }
-            $pear_channel = new PEAR_ChannelFile;
-            $pear_channel->setName('pecl.php.net');
-            $pear_channel->setAlias('pecl');
-            $pear_channel->setSummary('PHP Extension Community Library');
-            $pear_channel->setDefaultPEARProtocols();
-            $pear_channel->setBaseURL('REST1.0', 'http://pecl.php.net/rest/');
-            $pear_channel->setBaseURL('REST1.1', 'http://pecl.php.net/rest/');
-            $pear_channel->setValidationPackage('PEAR_Validator_PECL', '1.0');
-            return $pear_channel;
-        }
-
-        if ($this->_getChannelFromAlias($channel) == 'doc.php.net') {
-            // the registry is not properly set up, so use defaults
-            if (!class_exists('PEAR_ChannelFile')) {
-                require_once 'PEAR/ChannelFile.php';
-            }
-
-            $doc_channel = new PEAR_ChannelFile;
-            $doc_channel->setName('doc.php.net');
-            $doc_channel->setAlias('phpdocs');
-            $doc_channel->setSummary('PHP Documentation Team');
-            $doc_channel->setDefaultPEARProtocols();
-            $doc_channel->setBaseURL('REST1.0', 'http://doc.php.net/Chiara_PEAR_Server_REST/');
-            $doc_channel->setBaseURL('REST1.1', 'http://doc.php.net/Chiara_PEAR_Server_REST/');
-            return $doc_channel;
-        }
-
-
-        if ($this->_getChannelFromAlias($channel) == '__uri') {
-            // the registry is not properly set up, so use defaults
-            if (!class_exists('PEAR_ChannelFile')) {
-                require_once 'PEAR/ChannelFile.php';
-            }
-
-            $private = new PEAR_ChannelFile;
-            $private->setName('__uri');
-            $private->setDefaultPEARProtocols();
-            $private->setBaseURL('REST1.0', '****');
-            $private->setSummary('Pseudo-channel for static packages');
-            return $private;
-        }
-
-        return $ch;
-    }
-
-    /**
-     * @param string Package name
-     * @param string Channel name
-     * @return bool
-     */
-    function packageExists($package, $channel = 'pear.php.net')
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_packageExists($package, $channel);
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-
-    // {{{ channelExists()
-
-    /**
-     * @param string channel name
-     * @param bool if true, then aliases will be ignored
-     * @return bool
-     */
-    function channelExists($channel, $noaliases = false)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_channelExists($channel, $noaliases);
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-
-    // {{{ isAlias()
-
-    /**
-     * Determines whether the parameter is an alias of a channel
-     * @param string
-     * @return bool
-     */
-    function isAlias($alias)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_isChannelAlias($alias);
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-    // {{{ packageInfo()
-
-    /**
-     * @param string|null
-     * @param string|null
-     * @param string
-     * @return array|null
-     */
-    function packageInfo($package = null, $key = null, $channel = 'pear.php.net')
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_packageInfo($package, $key, $channel);
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-    // {{{ channelInfo()
-
-    /**
-     * Retrieve a raw array of channel data.
-     *
-     * Do not use this, instead use {@link getChannel()} for normal
-     * operations.  Array structure is undefined in this method
-     * @param string channel name
-     * @param bool whether to strictly retrieve information only on non-aliases
-     * @return array|null|PEAR_Error
-     */
-    function channelInfo($channel = null, $noaliases = false)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_channelInfo($channel, $noaliases);
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-
-    /**
-     * @param string
-     */
-    function channelName($channel)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_getChannelFromAlias($channel);
-        $this->_unlock();
-        return $ret;
-    }
-
-    /**
-     * @param string
-     */
-    function channelAlias($channel)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_getAlias($channel);
-        $this->_unlock();
-        return $ret;
-    }
-    // {{{ listPackages()
-
-    function listPackages($channel = false)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_listPackages($channel);
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-    // {{{ listAllPackages()
-
-    function listAllPackages()
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_listAllPackages();
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-    // {{{ listChannel()
-
-    function listChannels()
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_listChannels();
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-    // {{{ addPackage()
-
-    /**
-     * Add an installed package to the registry
-     * @param string|PEAR_PackageFile_v1|PEAR_PackageFile_v2 package name or object
-     *               that will be passed to {@link addPackage2()}
-     * @param array package info (parsed by PEAR_Common::infoFrom*() methods)
-     * @return bool success of saving
-     */
-    function addPackage($package, $info)
-    {
-        if (is_object($info)) {
-            return $this->addPackage2($info);
-        }
-        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
-            return $e;
-        }
-        $ret = $this->_addPackage($package, $info);
-        $this->_unlock();
-        if ($ret) {
-            if (!class_exists('PEAR_PackageFile_v1')) {
-                require_once 'PEAR/PackageFile/v1.php';
-            }
-            $pf = new PEAR_PackageFile_v1;
-            $pf->setConfig($this->_config);
-            $pf->fromArray($info);
-            $this->_dependencyDB->uninstallPackage($pf);
-            $this->_dependencyDB->installPackage($pf);
-        }
-        return $ret;
-    }
-
-    // }}}
-    // {{{ addPackage2()
-
-    function addPackage2($info)
-    {
-        if (!is_object($info)) {
-            return $this->addPackage($info['package'], $info);
-        }
-        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
-            return $e;
-        }
-        $ret = $this->_addPackage2($info);
-        $this->_unlock();
-        if ($ret) {
-            $this->_dependencyDB->uninstallPackage($info);
-            $this->_dependencyDB->installPackage($info);
-        }
-        return $ret;
-    }
-
-    // }}}
-    // {{{ updateChannel()
-
-    /**
-     * For future expandibility purposes, separate this
-     * @param PEAR_ChannelFile
-     */
-    function updateChannel($channel, $lastmodified = null)
-    {
-        if ($channel->getName() == '__uri') {
-            return false;
-        }
-        return $this->addChannel($channel, $lastmodified, true);
-    }
-
-    // }}}
-    // {{{ deleteChannel()
-
-    /**
-     * Deletion fails if there are any packages installed from the channel
-     * @param string|PEAR_ChannelFile channel name
-     * @return boolean|PEAR_Error True on deletion, false if it doesn't exist
-     */
-    function deleteChannel($channel)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
-            return $e;
-        }
-        $ret = $this->_deleteChannel($channel);
-        $this->_unlock();
-        if ($ret && is_a($this->_config, 'PEAR_Config')) {
-            $this->_config->setChannels($this->listChannels());
-        }
-        return $ret;
-    }
-
-    // }}}
-    // {{{ addChannel()
-
-    /**
-     * @param PEAR_ChannelFile Channel object
-     * @param string Last-Modified header from HTTP for caching
-     * @return boolean|PEAR_Error True on creation, false if it already exists
-     */
-    function addChannel($channel, $lastmodified = false, $update = false)
-    {
-        if (!is_a($channel, 'PEAR_ChannelFile')) {
-            return false;
-        }
-        if (!$channel->validate()) {
-            return false;
-        }
-        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
-            return $e;
-        }
-        $ret = $this->_addChannel($channel, $update, $lastmodified);
-        $this->_unlock();
-        if (!$update && $ret && is_a($this->_config, 'PEAR_Config')) {
-            $this->_config->setChannels($this->listChannels());
-        }
-        return $ret;
-    }
-
-    // }}}
-    // {{{ deletePackage()
-
-    function deletePackage($package, $channel = 'pear.php.net')
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
-            return $e;
-        }
-        $file = $this->_packageFileName($package, $channel);
-        if (file_exists($file)) {
-            $ret = @unlink($file);
-        } else {
-            $ret = false;
-        }
-        $this->_rebuildFileMap();
-        $this->_unlock();
-        $p = array('channel' => $channel, 'package' => $package);
-        $this->_dependencyDB->uninstallPackage($p);
-        return $ret;
-    }
-
-    // }}}
-    // {{{ updatePackage()
-
-    function updatePackage($package, $info, $merge = true)
-    {
-        if (is_object($info)) {
-            return $this->updatePackage2($info, $merge);
-        }
-        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
-            return $e;
-        }
-        $ret = $this->_updatePackage($package, $info, $merge);
-        $this->_unlock();
-        if ($ret) {
-            if (!class_exists('PEAR_PackageFile_v1')) {
-                require_once 'PEAR/PackageFile/v1.php';
-            }
-            $pf = new PEAR_PackageFile_v1;
-            $pf->setConfig($this->_config);
-            $pf->fromArray($this->packageInfo($package));
-            $this->_dependencyDB->uninstallPackage($pf);
-            $this->_dependencyDB->installPackage($pf);
-        }
-        return $ret;
-    }
-
-    // }}}
-    // {{{ updatePackage2()
-
-    function updatePackage2($info)
-    {
-
-        if (!is_object($info)) {
-            return $this->updatePackage($info['package'], $info, $merge);
-        }
-
-        if (!$info->validate(PEAR_VALIDATE_DOWNLOADING)) {
-            return false;
-        }
-
-        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
-            return $e;
-        }
-
-        $ret = $this->_updatePackage2($info);
-        $this->_unlock();
-        if ($ret) {
-            $this->_dependencyDB->uninstallPackage($info);
-            $this->_dependencyDB->installPackage($info);
-        }
-
-        return $ret;
-    }
-
-    // }}}
-    // {{{ getChannel()
-    /**
-     * @param string channel name
-     * @param bool whether to strictly return raw channels (no aliases)
-     * @return PEAR_ChannelFile|PEAR_Error
-     */
-    function &getChannel($channel, $noaliases = false)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = &$this->_getChannel($channel, $noaliases);
-        $this->_unlock();
-        if (!$ret) {
-            return PEAR::raiseError('Unknown channel: ' . $channel);
-        }
-        return $ret;
-    }
-
-    // }}}
-    // {{{ getPackage()
-    /**
-     * @param string package name
-     * @param string channel name
-     * @return PEAR_PackageFile_v1|PEAR_PackageFile_v2|null
-     */
-    function &getPackage($package, $channel = 'pear.php.net')
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $pf = &$this->_getPackage($package, $channel);
-        $this->_unlock();
-        return $pf;
-    }
-
-    // }}}
-
-    /**
-     * Get PEAR_PackageFile_v[1/2] objects representing the contents of
-     * a dependency group that are installed.
-     *
-     * This is used at uninstall-time
-     * @param array
-     * @return array|false
-     */
-    function getInstalledGroup($group)
-    {
-        $ret = array();
-        if (isset($group['package'])) {
-            if (!isset($group['package'][0])) {
-                $group['package'] = array($group['package']);
-            }
-            foreach ($group['package'] as $package) {
-                $depchannel = isset($package['channel']) ? $package['channel'] : '__uri';
-                $p = &$this->getPackage($package['name'], $depchannel);
-                if ($p) {
-                    $save = &$p;
-                    $ret[] = &$save;
-                }
-            }
-        }
-        if (isset($group['subpackage'])) {
-            if (!isset($group['subpackage'][0])) {
-                $group['subpackage'] = array($group['subpackage']);
-            }
-            foreach ($group['subpackage'] as $package) {
-                $depchannel = isset($package['channel']) ? $package['channel'] : '__uri';
-                $p = &$this->getPackage($package['name'], $depchannel);
-                if ($p) {
-                    $save = &$p;
-                    $ret[] = &$save;
-                }
-            }
-        }
-        if (!count($ret)) {
-            return false;
-        }
-        return $ret;
-    }
-
-    // {{{ getChannelValidator()
-    /**
-     * @param string channel name
-     * @return PEAR_Validate|false
-     */
-    function &getChannelValidator($channel)
-    {
-        $chan = $this->getChannel($channel);
-        if (PEAR::isError($chan)) {
-            return $chan;
-        }
-        $val = $chan->getValidationObject();
-        return $val;
-    }
-    // }}}
-    // {{{ getChannels()
-    /**
-     * @param string channel name
-     * @return array an array of PEAR_ChannelFile objects representing every installed channel
-     */
-    function &getChannels()
-    {
-        $ret = array();
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        foreach ($this->_listChannels() as $channel) {
-            $e = &$this->_getChannel($channel);
-            if (!$e || PEAR::isError($e)) {
-                continue;
-            }
-            $ret[] = $e;
-        }
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-    // {{{ checkFileMap()
-
-    /**
-     * Test whether a file or set of files belongs to a package.
-     *
-     * If an array is passed in
-     * @param string|array file path, absolute or relative to the pear
-     *                     install dir
-     * @param string|array name of PEAR package or array('package' => name, 'channel' =>
-     *                     channel) of a package that will be ignored
-     * @param string API version - 1.1 will exclude any files belonging to a package
-     * @param array private recursion variable
-     * @return array|false which package and channel the file belongs to, or an empty
-     *                     string if the file does not belong to an installed package,
-     *                     or belongs to the second parameter's package
-     */
-    function checkFileMap($path, $package = false, $api = '1.0', $attrs = false)
-    {
-        if (is_array($path)) {
-            static $notempty;
-            if (empty($notempty)) {
-                if (!class_exists('PEAR_Installer_Role')) {
-                    require_once 'PEAR/Installer/Role.php';
-                }
-                $notempty = create_function('$a','return !empty($a);');
-            }
-            $package = is_array($package) ? array(strtolower($package[0]), strtolower($package[1]))
-                : strtolower($package);
-            $pkgs = array();
-            foreach ($path as $name => $attrs) {
-                if (is_array($attrs)) {
-                    if (isset($attrs['install-as'])) {
-                        $name = $attrs['install-as'];
-                    }
-                    if (!in_array($attrs['role'], PEAR_Installer_Role::getInstallableRoles())) {
-                        // these are not installed
-                        continue;
-                    }
-                    if (!in_array($attrs['role'], PEAR_Installer_Role::getBaseinstallRoles())) {
-                        $attrs['baseinstalldir'] = is_array($package) ? $package[1] : $package;
-                    }
-                    if (isset($attrs['baseinstalldir'])) {
-                        $name = $attrs['baseinstalldir'] . DIRECTORY_SEPARATOR . $name;
-                    }
-                }
-                $pkgs[$name] = $this->checkFileMap($name, $package, $api, $attrs);
-                if (PEAR::isError($pkgs[$name])) {
-                    return $pkgs[$name];
-                }
-            }
-            return array_filter($pkgs, $notempty);
-        }
-        if (empty($this->filemap_cache)) {
-            if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-                return $e;
-            }
-            $err = $this->_readFileMap();
-            $this->_unlock();
-            if (PEAR::isError($err)) {
-                return $err;
-            }
-        }
-        if (!$attrs) {
-            $attrs = array('role' => 'php'); // any old call would be for PHP role only
-        }
-        if (isset($this->filemap_cache[$attrs['role']][$path])) {
-            if ($api >= '1.1' && $this->filemap_cache[$attrs['role']][$path] == $package) {
-                return false;
-            }
-            return $this->filemap_cache[$attrs['role']][$path];
-        }
-        $l = strlen($this->install_dir);
-        if (substr($path, 0, $l) == $this->install_dir) {
-            $path = preg_replace('!^'.DIRECTORY_SEPARATOR.'+!', '', substr($path, $l));
-        }
-        if (isset($this->filemap_cache[$attrs['role']][$path])) {
-            if ($api >= '1.1' && $this->filemap_cache[$attrs['role']][$path] == $package) {
-                return false;
-            }
-            return $this->filemap_cache[$attrs['role']][$path];
-        }
-        return false;
-    }
-
-    // }}}
-    // {{{ flush()
-    /**
-     * Force a reload of the filemap
-     * @since 1.5.0RC3
-     */
-    function flushFileMap()
-    {
-        $this->filemap_cache = null;
-        clearstatcache(); // ensure that the next read gets the full, current filemap
-    }
-
-    // }}}
-    // {{{ apiVersion()
-    /**
-     * Get the expected API version.  Channels API is version 1.1, as it is backwards
-     * compatible with 1.0
-     * @return string
-     */
-    function apiVersion()
-    {
-        return '1.1';
-    }
-    // }}}
-
-
-    /**
-     * Parse a package name, or validate a parsed package name array
-     * @param string|array pass in an array of format
-     *                     array(
-     *                      'package' => 'pname',
-     *                     ['channel' => 'channame',]
-     *                     ['version' => 'version',]
-     *                     ['state' => 'state',]
-     *                     ['group' => 'groupname'])
-     *                     or a string of format
-     *                     [channel://][channame/]pname[-version|-state][/group=groupname]
-     * @return array|PEAR_Error
-     */
-    function parsePackageName($param, $defaultchannel = 'pear.php.net')
-    {
-        $saveparam = $param;
-        if (is_array($param)) {
-            // convert to string for error messages
-            $saveparam = $this->parsedPackageNameToString($param);
-            // process the array
-            if (!isset($param['package'])) {
-                return PEAR::raiseError('parsePackageName(): array $param ' .
-                    'must contain a valid package name in index "param"',
-                    'package', null, null, $param);
-            }
-            if (!isset($param['uri'])) {
-                if (!isset($param['channel'])) {
-                    $param['channel'] = $defaultchannel;
-                }
-            } else {
-                $param['channel'] = '__uri';
-            }
-        } else {
-            $components = @parse_url((string) $param);
-            if (isset($components['scheme'])) {
-                if ($components['scheme'] == 'http') {
-                    // uri package
-                    $param = array('uri' => $param, 'channel' => '__uri');
-                } elseif($components['scheme'] != 'channel') {
-                    return PEAR::raiseError('parsePackageName(): only channel:// uris may ' .
-                        'be downloaded, not "' . $param . '"', 'invalid', null, null, $param);
-                }
-            }
-            if (!isset($components['path'])) {
-                return PEAR::raiseError('parsePackageName(): array $param ' .
-                    'must contain a valid package name in "' . $param . '"',
-                    'package', null, null, $param);
-            }
-            if (isset($components['host'])) {
-                // remove the leading "/"
-                $components['path'] = substr($components['path'], 1);
-            }
-            if (!isset($components['scheme'])) {
-                if (strpos($components['path'], '/') !== false) {
-                    if ($components['path']{0} == '/') {
-                        return PEAR::raiseError('parsePackageName(): this is not ' .
-                            'a package name, it begins with "/" in "' . $param . '"',
-                            'invalid', null, null, $param);
-                    }
-                    $parts = explode('/', $components['path']);
-                    $components['host'] = array_shift($parts);
-                    if (count($parts) > 1) {
-                        $components['path'] = array_pop($parts);
-                        $components['host'] .= '/' . implode('/', $parts);
-                    } else {
-                        $components['path'] = implode('/', $parts);
-                    }
-                } else {
-                    $components['host'] = $defaultchannel;
-                }
-            } else {
-                if (strpos($components['path'], '/')) {
-                    $parts = explode('/', $components['path']);
-                    $components['path'] = array_pop($parts);
-                    $components['host'] .= '/' . implode('/', $parts);
-                }
-            }
-
-            if (is_array($param)) {
-                $param['package'] = $components['path'];
-            } else {
-                $param = array(
-                    'package' => $components['path']
-                    );
-                if (isset($components['host'])) {
-                    $param['channel'] = $components['host'];
-                }
-            }
-            if (isset($components['fragment'])) {
-                $param['group'] = $components['fragment'];
-            }
-            if (isset($components['user'])) {
-                $param['user'] = $components['user'];
-            }
-            if (isset($components['pass'])) {
-                $param['pass'] = $components['pass'];
-            }
-            if (isset($components['query'])) {
-                parse_str($components['query'], $param['opts']);
-            }
-            // check for extension
-            $pathinfo = pathinfo($param['package']);
-            if (isset($pathinfo['extension']) &&
-                  in_array(strtolower($pathinfo['extension']), array('tgz', 'tar'))) {
-                $param['extension'] = $pathinfo['extension'];
-                $param['package'] = substr($pathinfo['basename'], 0,
-                    strlen($pathinfo['basename']) - 4);
-            }
-            // check for version
-            if (strpos($param['package'], '-')) {
-                $test = explode('-', $param['package']);
-                if (count($test) != 2) {
-                    return PEAR::raiseError('parsePackageName(): only one version/state ' .
-                        'delimiter "-" is allowed in "' . $saveparam . '"',
-                        'version', null, null, $param);
-                }
-                list($param['package'], $param['version']) = $test;
-            }
-        }
-        // validation
-        $info = $this->channelExists($param['channel']);
-        if (PEAR::isError($info)) {
-            return $info;
-        }
-        if (!$info) {
-            return PEAR::raiseError('unknown channel "' . $param['channel'] .
-                '" in "' . $saveparam . '"', 'channel', null, null, $param);
-        }
-        $chan = $this->getChannel($param['channel']);
-        if (PEAR::isError($chan)) {
-            return $chan;
-        }
-        if (!$chan) {
-            return PEAR::raiseError("Exception: corrupt registry, could not " .
-                "retrieve channel " . $param['channel'] . " information",
-                'registry', null, null, $param);
-        }
-        $param['channel'] = $chan->getName();
-        $validate = $chan->getValidationObject();
-        $vpackage = $chan->getValidationPackage();
-        // validate package name
-        if (!$validate->validPackageName($param['package'], $vpackage['_content'])) {
-            return PEAR::raiseError('parsePackageName(): invalid package name "' .
-                $param['package'] . '" in "' . $saveparam . '"',
-                'package', null, null, $param);
-        }
-        if (isset($param['group'])) {
-            if (!PEAR_Validate::validGroupName($param['group'])) {
-                return PEAR::raiseError('parsePackageName(): dependency group "' . $param['group'] .
-                    '" is not a valid group name in "' . $saveparam . '"', 'group', null, null,
-                    $param);
-            }
-        }
-        if (isset($param['state'])) {
-            if (!in_array(strtolower($param['state']), $validate->getValidStates())) {
-                return PEAR::raiseError('parsePackageName(): state "' . $param['state']
-                    . '" is not a valid state in "' . $saveparam . '"',
-                    'state', null, null, $param);
-            }
-        }
-        if (isset($param['version'])) {
-            if (isset($param['state'])) {
-                return PEAR::raiseError('parsePackageName(): cannot contain both ' .
-                    'a version and a stability (state) in "' . $saveparam . '"',
-                    'version/state', null, null, $param);
-            }
-            // check whether version is actually a state
-            if (in_array(strtolower($param['version']), $validate->getValidStates())) {
-                $param['state'] = strtolower($param['version']);
-                unset($param['version']);
-            } else {
-                if (!$validate->validVersion($param['version'])) {
-                    return PEAR::raiseError('parsePackageName(): "' . $param['version'] .
-                        '" is neither a valid version nor a valid state in "' .
-                        $saveparam . '"', 'version/state', null, null, $param);
-                }
-            }
-        }
-        return $param;
-    }
-
-    /**
-     * @param array
-     * @return string
-     */
-    function parsedPackageNameToString($parsed, $brief = false)
-    {
-        if (is_string($parsed)) {
-            return $parsed;
-        }
-        if (is_object($parsed)) {
-            $p = $parsed;
-            $parsed = array(
-                'package' => $p->getPackage(),
-                'channel' => $p->getChannel(),
-                'version' => $p->getVersion(),
-            );
-        }
-        if (isset($parsed['uri'])) {
-            return $parsed['uri'];
-        }
-        if ($brief) {
-            if ($channel = $this->channelAlias($parsed['channel'])) {
-                return $channel . '/' . $parsed['package'];
-            }
-        }
-        $upass = '';
-        if (isset($parsed['user'])) {
-            $upass = $parsed['user'];
-            if (isset($parsed['pass'])) {
-                $upass .= ':' . $parsed['pass'];
-            }
-            $upass = "$upass@";
-        }
-        $ret = 'channel://' . $upass . $parsed['channel'] . '/' . $parsed['package'];
-        if (isset($parsed['version']) || isset($parsed['state'])) {
-            $ver = isset($parsed['version']) ? $parsed['version'] : '';
-            $ver .= isset($parsed['state']) ? $parsed['state'] : '';
-            $ret .= '-' . $ver;
-        }
-        if (isset($parsed['extension'])) {
-            $ret .= '.' . $parsed['extension'];
-        }
-        if (isset($parsed['opts'])) {
-            $ret .= '?';
-            foreach ($parsed['opts'] as $name => $value) {
-                $parsed['opts'][$name] = "$name=$value";
-            }
-            $ret .= implode('&', $parsed['opts']);
-        }
-        if (isset($parsed['group'])) {
-            $ret .= '#' . $parsed['group'];
-        }
-        return $ret;
-    }
-}                                                                                                                                 PEAR-1.8.0/PEAR/REST.php                                                                            100664     764     764        36152      100664   7351                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                                                                                                                                                                                                                                                       PEAR-1.9.0/PEAR/Registry.php                                                                        100664     764     764       224124      100664  10423                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * PEAR_Registry
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Stig Bakken <ssb at php.net>
+ * @author     Tomas V. V. Cox <cox at idecnet.com>
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Registry.php 287555 2009-08-21 21:27:27Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 0.1
+ */
+
+/**
+ * for PEAR_Error
+ */
+require_once 'PEAR.php';
+require_once 'PEAR/DependencyDB.php';
+
+define('PEAR_REGISTRY_ERROR_LOCK',         -2);
+define('PEAR_REGISTRY_ERROR_FORMAT',       -3);
+define('PEAR_REGISTRY_ERROR_FILE',         -4);
+define('PEAR_REGISTRY_ERROR_CONFLICT',     -5);
+define('PEAR_REGISTRY_ERROR_CHANNEL_FILE', -6);
+
+/**
+ * Administration class used to maintain the installed package database.
+ * @category   pear
+ * @package    PEAR
+ * @author     Stig Bakken <ssb at php.net>
+ * @author     Tomas V. V. Cox <cox at idecnet.com>
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Registry extends PEAR
+{
+    /**
+     * File containing all channel information.
+     * @var string
+     */
+    var $channels = '';
+
+    /** Directory where registry files are stored.
+     * @var string
+     */
+    var $statedir = '';
+
+    /** File where the file map is stored
+     * @var string
+     */
+    var $filemap = '';
+
+    /** Directory where registry files for channels are stored.
+     * @var string
+     */
+    var $channelsdir = '';
+
+    /** Name of file used for locking the registry
+     * @var string
+     */
+    var $lockfile = '';
+
+    /** File descriptor used during locking
+     * @var resource
+     */
+    var $lock_fp = null;
+
+    /** Mode used during locking
+     * @var int
+     */
+    var $lock_mode = 0; // XXX UNUSED
+
+    /** Cache of package information.  Structure:
+     * array(
+     *   'package' => array('id' => ... ),
+     *   ... )
+     * @var array
+     */
+    var $pkginfo_cache = array();
+
+    /** Cache of file map.  Structure:
+     * array( '/path/to/file' => 'package', ... )
+     * @var array
+     */
+    var $filemap_cache = array();
+
+    /**
+     * @var false|PEAR_ChannelFile
+     */
+    var $_pearChannel;
+
+    /**
+     * @var false|PEAR_ChannelFile
+     */
+    var $_peclChannel;
+
+    /**
+     * @var false|PEAR_ChannelFile
+     */
+    var $_docChannel;
+
+    /**
+     * @var PEAR_DependencyDB
+     */
+    var $_dependencyDB;
+
+    /**
+     * @var PEAR_Config
+     */
+    var $_config;
+
+    /**
+     * PEAR_Registry constructor.
+     *
+     * @param string (optional) PEAR install directory (for .php files)
+     * @param PEAR_ChannelFile PEAR_ChannelFile object representing the PEAR channel, if
+     *        default values are not desired.  Only used the very first time a PEAR
+     *        repository is initialized
+     * @param PEAR_ChannelFile PEAR_ChannelFile object representing the PECL channel, if
+     *        default values are not desired.  Only used the very first time a PEAR
+     *        repository is initialized
+     *
+     * @access public
+     */
+    function PEAR_Registry($pear_install_dir = PEAR_INSTALL_DIR, $pear_channel = false,
+                           $pecl_channel = false)
+    {
+        parent::PEAR();
+        $this->setInstallDir($pear_install_dir);
+        $this->_pearChannel = $pear_channel;
+        $this->_peclChannel = $pecl_channel;
+        $this->_config      = false;
+    }
+
+    function setInstallDir($pear_install_dir = PEAR_INSTALL_DIR)
+    {
+        $ds = DIRECTORY_SEPARATOR;
+        $this->install_dir = $pear_install_dir;
+        $this->channelsdir = $pear_install_dir.$ds.'.channels';
+        $this->statedir    = $pear_install_dir.$ds.'.registry';
+        $this->filemap     = $pear_install_dir.$ds.'.filemap';
+        $this->lockfile    = $pear_install_dir.$ds.'.lock';
+    }
+
+    function hasWriteAccess()
+    {
+        if (!file_exists($this->install_dir)) {
+            $dir = $this->install_dir;
+            while ($dir && $dir != '.') {
+                $olddir = $dir;
+                $dir    = dirname($dir);
+                if ($dir != '.' && file_exists($dir)) {
+                    if (is_writeable($dir)) {
+                        return true;
+                    }
+
+                    return false;
+                }
+
+                if ($dir == $olddir) { // this can happen in safe mode
+                    return @is_writable($dir);
+                }
+            }
+
+            return false;
+        }
+
+        return is_writeable($this->install_dir);
+    }
+
+    function setConfig(&$config, $resetInstallDir = true)
+    {
+        $this->_config = &$config;
+        if ($resetInstallDir) {
+            $this->setInstallDir($config->get('php_dir'));
+        }
+    }
+
+    function _initializeChannelDirs()
+    {
+        static $running = false;
+        if (!$running) {
+            $running = true;
+            $ds = DIRECTORY_SEPARATOR;
+            if (!is_dir($this->channelsdir) ||
+                  !file_exists($this->channelsdir . $ds . 'pear.php.net.reg') ||
+                  !file_exists($this->channelsdir . $ds . 'pecl.php.net.reg') ||
+                  !file_exists($this->channelsdir . $ds . 'doc.php.net.reg') ||
+                  !file_exists($this->channelsdir . $ds . '__uri.reg')) {
+                if (!file_exists($this->channelsdir . $ds . 'pear.php.net.reg')) {
+                    $pear_channel = $this->_pearChannel;
+                    if (!is_a($pear_channel, 'PEAR_ChannelFile') || !$pear_channel->validate()) {
+                        if (!class_exists('PEAR_ChannelFile')) {
+                            require_once 'PEAR/ChannelFile.php';
+                        }
+
+                        $pear_channel = new PEAR_ChannelFile;
+                        $pear_channel->setAlias('pear');
+                        $pear_channel->setServer('pear.php.net');
+                        $pear_channel->setSummary('PHP Extension and Application Repository');
+                        $pear_channel->setDefaultPEARProtocols();
+                        $pear_channel->setBaseURL('REST1.0', 'http://pear.php.net/rest/');
+                        $pear_channel->setBaseURL('REST1.1', 'http://pear.php.net/rest/');
+                        $pear_channel->setBaseURL('REST1.3', 'http://pear.php.net/rest/');
+                        //$pear_channel->setBaseURL('REST1.4', 'http://pear.php.net/rest/');
+                    } else {
+                        $pear_channel->setServer('pear.php.net');
+                        $pear_channel->setAlias('pear');
+                    }
+
+                    $pear_channel->validate();
+                    $this->_addChannel($pear_channel);
+                }
+
+                if (!file_exists($this->channelsdir . $ds . 'pecl.php.net.reg')) {
+                    $pecl_channel = $this->_peclChannel;
+                    if (!is_a($pecl_channel, 'PEAR_ChannelFile') || !$pecl_channel->validate()) {
+                        if (!class_exists('PEAR_ChannelFile')) {
+                            require_once 'PEAR/ChannelFile.php';
+                        }
+
+                        $pecl_channel = new PEAR_ChannelFile;
+                        $pecl_channel->setAlias('pecl');
+                        $pecl_channel->setServer('pecl.php.net');
+                        $pecl_channel->setSummary('PHP Extension Community Library');
+                        $pecl_channel->setDefaultPEARProtocols();
+                        $pecl_channel->setBaseURL('REST1.0', 'http://pecl.php.net/rest/');
+                        $pecl_channel->setBaseURL('REST1.1', 'http://pecl.php.net/rest/');
+                        $pecl_channel->setValidationPackage('PEAR_Validator_PECL', '1.0');
+                    } else {
+                        $pecl_channel->setServer('pecl.php.net');
+                        $pecl_channel->setAlias('pecl');
+                    }
+
+                    $pecl_channel->validate();
+                    $this->_addChannel($pecl_channel);
+                }
+
+                if (!file_exists($this->channelsdir . $ds . 'doc.php.net.reg')) {
+                    $doc_channel = $this->_docChannel;
+                    if (!is_a($doc_channel, 'PEAR_ChannelFile') || !$doc_channel->validate()) {
+                        if (!class_exists('PEAR_ChannelFile')) {
+                            require_once 'PEAR/ChannelFile.php';
+                        }
+
+                        $doc_channel = new PEAR_ChannelFile;
+                        $doc_channel->setAlias('phpdocs');
+                        $doc_channel->setServer('doc.php.net');
+                        $doc_channel->setSummary('PHP Documentation Team');
+                        $doc_channel->setDefaultPEARProtocols();
+                        $doc_channel->setBaseURL('REST1.0', 'http://doc.php.net/rest/');
+                        $doc_channel->setBaseURL('REST1.1', 'http://doc.php.net/rest/');
+                        $doc_channel->setBaseURL('REST1.3', 'http://doc.php.net/rest/');
+                    } else {
+                        $doc_channel->setServer('doc.php.net');
+                        $doc_channel->setAlias('doc');
+                    }
+
+                    $doc_channel->validate();
+                    $this->_addChannel($doc_channel);
+                }
+
+                if (!file_exists($this->channelsdir . $ds . '__uri.reg')) {
+                    if (!class_exists('PEAR_ChannelFile')) {
+                        require_once 'PEAR/ChannelFile.php';
+                    }
+
+                    $private = new PEAR_ChannelFile;
+                    $private->setName('__uri');
+                    $private->setDefaultPEARProtocols();
+                    $private->setBaseURL('REST1.0', '****');
+                    $private->setSummary('Pseudo-channel for static packages');
+                    $this->_addChannel($private);
+                }
+                $this->_rebuildFileMap();
+            }
+
+            $running = false;
+        }
+    }
+
+    function _initializeDirs()
+    {
+        $ds = DIRECTORY_SEPARATOR;
+        // XXX Compatibility code should be removed in the future
+        // rename all registry files if any to lowercase
+        if (!OS_WINDOWS && file_exists($this->statedir) && is_dir($this->statedir) &&
+              $handle = opendir($this->statedir)) {
+            $dest = $this->statedir . $ds;
+            while (false !== ($file = readdir($handle))) {
+                if (preg_match('/^.*[A-Z].*\.reg\\z/', $file)) {
+                    rename($dest . $file, $dest . strtolower($file));
+                }
+            }
+            closedir($handle);
+        }
+
+        $this->_initializeChannelDirs();
+        if (!file_exists($this->filemap)) {
+            $this->_rebuildFileMap();
+        }
+        $this->_initializeDepDB();
+    }
+
+    function _initializeDepDB()
+    {
+        if (!isset($this->_dependencyDB)) {
+            static $initializing = false;
+            if (!$initializing) {
+                $initializing = true;
+                if (!$this->_config) { // never used?
+                    $file = OS_WINDOWS ? 'pear.ini' : '.pearrc';
+                    $this->_config = &new PEAR_Config($this->statedir . DIRECTORY_SEPARATOR .
+                        $file);
+                    $this->_config->setRegistry($this);
+                    $this->_config->set('php_dir', $this->install_dir);
+                }
+
+                $this->_dependencyDB = &PEAR_DependencyDB::singleton($this->_config);
+                if (PEAR::isError($this->_dependencyDB)) {
+                    // attempt to recover by removing the dep db
+                    if (file_exists($this->_config->get('php_dir', null, 'pear.php.net') .
+                        DIRECTORY_SEPARATOR . '.depdb')) {
+                        @unlink($this->_config->get('php_dir', null, 'pear.php.net') .
+                            DIRECTORY_SEPARATOR . '.depdb');
+                    }
+
+                    $this->_dependencyDB = &PEAR_DependencyDB::singleton($this->_config);
+                    if (PEAR::isError($this->_dependencyDB)) {
+                        echo $this->_dependencyDB->getMessage();
+                        echo 'Unrecoverable error';
+                        exit(1);
+                    }
+                }
+
+                $initializing = false;
+            }
+        }
+    }
+
+    /**
+     * PEAR_Registry destructor.  Makes sure no locks are forgotten.
+     *
+     * @access private
+     */
+    function _PEAR_Registry()
+    {
+        parent::_PEAR();
+        if (is_resource($this->lock_fp)) {
+            $this->_unlock();
+        }
+    }
+
+    /**
+     * Make sure the directory where we keep registry files exists.
+     *
+     * @return bool TRUE if directory exists, FALSE if it could not be
+     * created
+     *
+     * @access private
+     */
+    function _assertStateDir($channel = false)
+    {
+        if ($channel && $this->_getChannelFromAlias($channel) != 'pear.php.net') {
+            return $this->_assertChannelStateDir($channel);
+        }
+
+        static $init = false;
+        if (!file_exists($this->statedir)) {
+            if (!$this->hasWriteAccess()) {
+                return false;
+            }
+
+            require_once 'System.php';
+            if (!System::mkdir(array('-p', $this->statedir))) {
+                return $this->raiseError("could not create directory '{$this->statedir}'");
+            }
+            $init = true;
+        } elseif (!is_dir($this->statedir)) {
+            return $this->raiseError('Cannot create directory ' . $this->statedir . ', ' .
+                'it already exists and is not a directory');
+        }
+
+        $ds = DIRECTORY_SEPARATOR;
+        if (!file_exists($this->channelsdir)) {
+            if (!file_exists($this->channelsdir . $ds . 'pear.php.net.reg') ||
+                  !file_exists($this->channelsdir . $ds . 'pecl.php.net.reg') ||
+                  !file_exists($this->channelsdir . $ds . 'doc.php.net.reg') ||
+                  !file_exists($this->channelsdir . $ds . '__uri.reg')) {
+                $init = true;
+            }
+        } elseif (!is_dir($this->channelsdir)) {
+            return $this->raiseError('Cannot create directory ' . $this->channelsdir . ', ' .
+                'it already exists and is not a directory');
+        }
+
+        if ($init) {
+            static $running = false;
+            if (!$running) {
+                $running = true;
+                $this->_initializeDirs();
+                $running = false;
+                $init = false;
+            }
+        } else {
+            $this->_initializeDepDB();
+        }
+
+        return true;
+    }
+
+    /**
+     * Make sure the directory where we keep registry files exists for a non-standard channel.
+     *
+     * @param string channel name
+     * @return bool TRUE if directory exists, FALSE if it could not be
+     * created
+     *
+     * @access private
+     */
+    function _assertChannelStateDir($channel)
+    {
+        $ds = DIRECTORY_SEPARATOR;
+        if (!$channel || $this->_getChannelFromAlias($channel) == 'pear.php.net') {
+            if (!file_exists($this->channelsdir . $ds . 'pear.php.net.reg')) {
+                $this->_initializeChannelDirs();
+            }
+            return $this->_assertStateDir($channel);
+        }
+
+        $channelDir = $this->_channelDirectoryName($channel);
+        if (!is_dir($this->channelsdir) ||
+              !file_exists($this->channelsdir . $ds . 'pear.php.net.reg')) {
+            $this->_initializeChannelDirs();
+        }
+
+        if (!file_exists($channelDir)) {
+            if (!$this->hasWriteAccess()) {
+                return false;
+            }
+
+            require_once 'System.php';
+            if (!System::mkdir(array('-p', $channelDir))) {
+                return $this->raiseError("could not create directory '" . $channelDir .
+                    "'");
+            }
+        } elseif (!is_dir($channelDir)) {
+            return $this->raiseError("could not create directory '" . $channelDir .
+                "', already exists and is not a directory");
+        }
+
+        return true;
+    }
+
+    /**
+     * Make sure the directory where we keep registry files for channels exists
+     *
+     * @return bool TRUE if directory exists, FALSE if it could not be
+     * created
+     *
+     * @access private
+     */
+    function _assertChannelDir()
+    {
+        if (!file_exists($this->channelsdir)) {
+            if (!$this->hasWriteAccess()) {
+                return false;
+            }
+
+            require_once 'System.php';
+            if (!System::mkdir(array('-p', $this->channelsdir))) {
+                return $this->raiseError("could not create directory '{$this->channelsdir}'");
+            }
+        } elseif (!is_dir($this->channelsdir)) {
+            return $this->raiseError("could not create directory '{$this->channelsdir}" .
+                "', it already exists and is not a directory");
+        }
+
+        if (!file_exists($this->channelsdir . DIRECTORY_SEPARATOR . '.alias')) {
+            if (!$this->hasWriteAccess()) {
+                return false;
+            }
+
+            require_once 'System.php';
+            if (!System::mkdir(array('-p', $this->channelsdir . DIRECTORY_SEPARATOR . '.alias'))) {
+                return $this->raiseError("could not create directory '{$this->channelsdir}/.alias'");
+            }
+        } elseif (!is_dir($this->channelsdir . DIRECTORY_SEPARATOR . '.alias')) {
+            return $this->raiseError("could not create directory '{$this->channelsdir}" .
+                "/.alias', it already exists and is not a directory");
+        }
+
+        return true;
+    }
+
+    /**
+     * Get the name of the file where data for a given package is stored.
+     *
+     * @param string channel name, or false if this is a PEAR package
+     * @param string package name
+     *
+     * @return string registry file name
+     *
+     * @access public
+     */
+    function _packageFileName($package, $channel = false)
+    {
+        if ($channel && $this->_getChannelFromAlias($channel) != 'pear.php.net') {
+            return $this->_channelDirectoryName($channel) . DIRECTORY_SEPARATOR .
+                strtolower($package) . '.reg';
+        }
+
+        return $this->statedir . DIRECTORY_SEPARATOR . strtolower($package) . '.reg';
+    }
+
+    /**
+     * Get the name of the file where data for a given channel is stored.
+     * @param string channel name
+     * @return string registry file name
+     */
+    function _channelFileName($channel, $noaliases = false)
+    {
+        if (!$noaliases) {
+            if (file_exists($this->_getChannelAliasFileName($channel))) {
+                $channel = implode('', file($this->_getChannelAliasFileName($channel)));
+            }
+        }
+        return $this->channelsdir . DIRECTORY_SEPARATOR . str_replace('/', '_',
+            strtolower($channel)) . '.reg';
+    }
+
+    /**
+     * @param string
+     * @return string
+     */
+    function _getChannelAliasFileName($alias)
+    {
+        return $this->channelsdir . DIRECTORY_SEPARATOR . '.alias' .
+              DIRECTORY_SEPARATOR . str_replace('/', '_', strtolower($alias)) . '.txt';
+    }
+
+    /**
+     * Get the name of a channel from its alias
+     */
+    function _getChannelFromAlias($channel)
+    {
+        if (!$this->_channelExists($channel)) {
+            if ($channel == 'pear.php.net') {
+                return 'pear.php.net';
+            }
+
+            if ($channel == 'pecl.php.net') {
+                return 'pecl.php.net';
+            }
+
+            if ($channel == 'doc.php.net') {
+                return 'doc.php.net';
+            }
+
+            if ($channel == '__uri') {
+                return '__uri';
+            }
+
+            return false;
+        }
+
+        $channel = strtolower($channel);
+        if (file_exists($this->_getChannelAliasFileName($channel))) {
+            // translate an alias to an actual channel
+            return implode('', file($this->_getChannelAliasFileName($channel)));
+        }
+
+        return $channel;
+    }
+
+    /**
+     * Get the alias of a channel from its alias or its name
+     */
+    function _getAlias($channel)
+    {
+        if (!$this->_channelExists($channel)) {
+            if ($channel == 'pear.php.net') {
+                return 'pear';
+            }
+
+            if ($channel == 'pecl.php.net') {
+                return 'pecl';
+            }
+
+            if ($channel == 'doc.php.net') {
+                return 'phpdocs';
+            }
+
+            return false;
+        }
+
+        $channel = $this->_getChannel($channel);
+        if (PEAR::isError($channel)) {
+            return $channel;
+        }
+
+        return $channel->getAlias();
+    }
+
+    /**
+     * Get the name of the file where data for a given package is stored.
+     *
+     * @param string channel name, or false if this is a PEAR package
+     * @param string package name
+     *
+     * @return string registry file name
+     *
+     * @access public
+     */
+    function _channelDirectoryName($channel)
+    {
+        if (!$channel || $this->_getChannelFromAlias($channel) == 'pear.php.net') {
+            return $this->statedir;
+        }
+
+        $ch = $this->_getChannelFromAlias($channel);
+        if (!$ch) {
+            $ch = $channel;
+        }
+
+        return $this->statedir . DIRECTORY_SEPARATOR . strtolower('.channel.' .
+            str_replace('/', '_', $ch));
+    }
+
+    function _openPackageFile($package, $mode, $channel = false)
+    {
+        if (!$this->_assertStateDir($channel)) {
+            return null;
+        }
+
+        if (!in_array($mode, array('r', 'rb')) && !$this->hasWriteAccess()) {
+            return null;
+        }
+
+        $file = $this->_packageFileName($package, $channel);
+        if (!file_exists($file) && $mode == 'r' || $mode == 'rb') {
+            return null;
+        }
+
+        $fp = @fopen($file, $mode);
+        if (!$fp) {
+            return null;
+        }
+
+        return $fp;
+    }
+
+    function _closePackageFile($fp)
+    {
+        fclose($fp);
+    }
+
+    function _openChannelFile($channel, $mode)
+    {
+        if (!$this->_assertChannelDir()) {
+            return null;
+        }
+
+        if (!in_array($mode, array('r', 'rb')) && !$this->hasWriteAccess()) {
+            return null;
+        }
+
+        $file = $this->_channelFileName($channel);
+        if (!file_exists($file) && $mode == 'r' || $mode == 'rb') {
+            return null;
+        }
+
+        $fp = @fopen($file, $mode);
+        if (!$fp) {
+            return null;
+        }
+
+        return $fp;
+    }
+
+    function _closeChannelFile($fp)
+    {
+        fclose($fp);
+    }
+
+    function _rebuildFileMap()
+    {
+        if (!class_exists('PEAR_Installer_Role')) {
+            require_once 'PEAR/Installer/Role.php';
+        }
+
+        $channels = $this->_listAllPackages();
+        $files = array();
+        foreach ($channels as $channel => $packages) {
+            foreach ($packages as $package) {
+                $version = $this->_packageInfo($package, 'version', $channel);
+                $filelist = $this->_packageInfo($package, 'filelist', $channel);
+                if (!is_array($filelist)) {
+                    continue;
+                }
+
+                foreach ($filelist as $name => $attrs) {
+                    if (isset($attrs['attribs'])) {
+                        $attrs = $attrs['attribs'];
+                    }
+
+                    // it is possible for conflicting packages in different channels to
+                    // conflict with data files/doc files
+                    if ($name == 'dirtree') {
+                        continue;
+                    }
+
+                    if (isset($attrs['role']) && !in_array($attrs['role'],
+                          PEAR_Installer_Role::getInstallableRoles())) {
+                        // these are not installed
+                        continue;
+                    }
+
+                    if (isset($attrs['role']) && !in_array($attrs['role'],
+                          PEAR_Installer_Role::getBaseinstallRoles())) {
+                        $attrs['baseinstalldir'] = $package;
+                    }
+
+                    if (isset($attrs['baseinstalldir'])) {
+                        $file = $attrs['baseinstalldir'].DIRECTORY_SEPARATOR.$name;
+                    } else {
+                        $file = $name;
+                    }
+
+                    $file = preg_replace(',^/+,', '', $file);
+                    if ($channel != 'pear.php.net') {
+                        if (!isset($files[$attrs['role']])) {
+                            $files[$attrs['role']] = array();
+                        }
+                        $files[$attrs['role']][$file] = array(strtolower($channel),
+                            strtolower($package));
+                    } else {
+                        if (!isset($files[$attrs['role']])) {
+                            $files[$attrs['role']] = array();
+                        }
+                        $files[$attrs['role']][$file] = strtolower($package);
+                    }
+                }
+            }
+        }
+
+
+        $this->_assertStateDir();
+        if (!$this->hasWriteAccess()) {
+            return false;
+        }
+
+        $fp = @fopen($this->filemap, 'wb');
+        if (!$fp) {
+            return false;
+        }
+
+        $this->filemap_cache = $files;
+        fwrite($fp, serialize($files));
+        fclose($fp);
+        return true;
+    }
+
+    function _readFileMap()
+    {
+        if (!file_exists($this->filemap)) {
+            return array();
+        }
+
+        $fp = @fopen($this->filemap, 'r');
+        if (!$fp) {
+            return $this->raiseError('PEAR_Registry: could not open filemap "' . $this->filemap . '"', PEAR_REGISTRY_ERROR_FILE, null, null, $php_errormsg);
+        }
+
+        clearstatcache();
+        $rt = get_magic_quotes_runtime();
+        set_magic_quotes_runtime(0);
+        $fsize = filesize($this->filemap);
+        fclose($fp);
+        $data = file_get_contents($this->filemap);
+        set_magic_quotes_runtime($rt);
+        $tmp = unserialize($data);
+        if (!$tmp && $fsize > 7) {
+            return $this->raiseError('PEAR_Registry: invalid filemap data', PEAR_REGISTRY_ERROR_FORMAT, null, null, $data);
+        }
+
+        $this->filemap_cache = $tmp;
+        return true;
+    }
+
+    /**
+     * Lock the registry.
+     *
+     * @param integer lock mode, one of LOCK_EX, LOCK_SH or LOCK_UN.
+     *                See flock manual for more information.
+     *
+     * @return bool TRUE on success, FALSE if locking failed, or a
+     *              PEAR error if some other error occurs (such as the
+     *              lock file not being writable).
+     *
+     * @access private
+     */
+    function _lock($mode = LOCK_EX)
+    {
+        if (stristr(php_uname(), 'Windows 9')) {
+            return true;
+        }
+
+        if ($mode != LOCK_UN && is_resource($this->lock_fp)) {
+            // XXX does not check type of lock (LOCK_SH/LOCK_EX)
+            return true;
+        }
+
+        if (!$this->_assertStateDir()) {
+            if ($mode == LOCK_EX) {
+                return $this->raiseError('Registry directory is not writeable by the current user');
+            }
+
+            return true;
+        }
+
+        $open_mode = 'w';
+        // XXX People reported problems with LOCK_SH and 'w'
+        if ($mode === LOCK_SH || $mode === LOCK_UN) {
+            if (!file_exists($this->lockfile)) {
+                touch($this->lockfile);
+            }
+            $open_mode = 'r';
+        }
+
+        if (!is_resource($this->lock_fp)) {
+            $this->lock_fp = @fopen($this->lockfile, $open_mode);
+        }
+
+        if (!is_resource($this->lock_fp)) {
+            $this->lock_fp = null;
+            return $this->raiseError("could not create lock file" .
+                                     (isset($php_errormsg) ? ": " . $php_errormsg : ""));
+        }
+
+        if (!(int)flock($this->lock_fp, $mode)) {
+            switch ($mode) {
+                case LOCK_SH: $str = 'shared';    break;
+                case LOCK_EX: $str = 'exclusive'; break;
+                case LOCK_UN: $str = 'unlock';    break;
+                default:      $str = 'unknown';   break;
+            }
+
+            //is resource at this point, close it on error.
+            fclose($this->lock_fp);
+            $this->lock_fp = null;
+            return $this->raiseError("could not acquire $str lock ($this->lockfile)",
+                                     PEAR_REGISTRY_ERROR_LOCK);
+        }
+
+        return true;
+    }
+
+    function _unlock()
+    {
+        $ret = $this->_lock(LOCK_UN);
+        if (is_resource($this->lock_fp)) {
+            fclose($this->lock_fp);
+        }
+
+        $this->lock_fp = null;
+        return $ret;
+    }
+
+    function _packageExists($package, $channel = false)
+    {
+        return file_exists($this->_packageFileName($package, $channel));
+    }
+
+    /**
+     * Determine whether a channel exists in the registry
+     *
+     * @param string Channel name
+     * @param bool if true, then aliases will be ignored
+     * @return boolean
+     */
+    function _channelExists($channel, $noaliases = false)
+    {
+        $a = file_exists($this->_channelFileName($channel, $noaliases));
+        if (!$a && $channel == 'pear.php.net') {
+            return true;
+        }
+
+        if (!$a && $channel == 'pecl.php.net') {
+            return true;
+        }
+
+        if (!$a && $channel == 'doc.php.net') {
+            return true;
+        }
+
+        return $a;
+    }
+
+    /**
+     * Determine whether a mirror exists within the deafult channel in the registry
+     *
+     * @param string Channel name
+     * @param string Mirror name
+     *
+     * @return boolean
+     */
+    function _mirrorExists($channel, $mirror)
+    {
+        $data = $this->_channelInfo($channel);
+        if (!isset($data['servers']['mirror'])) {
+            return false;
+        }
+
+        foreach ($data['servers']['mirror'] as $m) {
+            if ($m['attribs']['host'] == $mirror) {
+                return true;
+            }
+        }
+
+        return false;
+    }
+
+    /**
+     * @param PEAR_ChannelFile Channel object
+     * @param donotuse
+     * @param string Last-Modified HTTP tag from remote request
+     * @return boolean|PEAR_Error True on creation, false if it already exists
+     */
+    function _addChannel($channel, $update = false, $lastmodified = false)
+    {
+        if (!is_a($channel, 'PEAR_ChannelFile')) {
+            return false;
+        }
+
+        if (!$channel->validate()) {
+            return false;
+        }
+
+        if (file_exists($this->_channelFileName($channel->getName()))) {
+            if (!$update) {
+                return false;
+            }
+
+            $checker = $this->_getChannel($channel->getName());
+            if (PEAR::isError($checker)) {
+                return $checker;
+            }
+
+            if ($channel->getAlias() != $checker->getAlias()) {
+                if (file_exists($this->_getChannelAliasFileName($checker->getAlias()))) {
+                    @unlink($this->_getChannelAliasFileName($checker->getAlias()));
+                }
+            }
+        } else {
+            if ($update && !in_array($channel->getName(), array('pear.php.net', 'pecl.php.net', 'doc.php.net'))) {
+                return false;
+            }
+        }
+
+        $ret = $this->_assertChannelDir();
+        if (PEAR::isError($ret)) {
+            return $ret;
+        }
+
+        $ret = $this->_assertChannelStateDir($channel->getName());
+        if (PEAR::isError($ret)) {
+            return $ret;
+        }
+
+        if ($channel->getAlias() != $channel->getName()) {
+            if (file_exists($this->_getChannelAliasFileName($channel->getAlias())) &&
+                  $this->_getChannelFromAlias($channel->getAlias()) != $channel->getName()) {
+                $channel->setAlias($channel->getName());
+            }
+
+            if (!$this->hasWriteAccess()) {
+                return false;
+            }
+
+            $fp = @fopen($this->_getChannelAliasFileName($channel->getAlias()), 'w');
+            if (!$fp) {
+                return false;
+            }
+
+            fwrite($fp, $channel->getName());
+            fclose($fp);
+        }
+
+        if (!$this->hasWriteAccess()) {
+            return false;
+        }
+
+        $fp = @fopen($this->_channelFileName($channel->getName()), 'wb');
+        if (!$fp) {
+            return false;
+        }
+
+        $info = $channel->toArray();
+        if ($lastmodified) {
+            $info['_lastmodified'] = $lastmodified;
+        } else {
+            $info['_lastmodified'] = date('r');
+        }
+
+        fwrite($fp, serialize($info));
+        fclose($fp);
+        return true;
+    }
+
+    /**
+     * Deletion fails if there are any packages installed from the channel
+     * @param string|PEAR_ChannelFile channel name
+     * @return boolean|PEAR_Error True on deletion, false if it doesn't exist
+     */
+    function _deleteChannel($channel)
+    {
+        if (!is_string($channel)) {
+            if (!is_a($channel, 'PEAR_ChannelFile')) {
+                return false;
+            }
+
+            if (!$channel->validate()) {
+                return false;
+            }
+            $channel = $channel->getName();
+        }
+
+        if ($this->_getChannelFromAlias($channel) == '__uri') {
+            return false;
+        }
+
+        if ($this->_getChannelFromAlias($channel) == 'pecl.php.net') {
+            return false;
+        }
+
+        if ($this->_getChannelFromAlias($channel) == 'doc.php.net') {
+            return false;
+        }
+
+        if (!$this->_channelExists($channel)) {
+            return false;
+        }
+
+        if (!$channel || $this->_getChannelFromAlias($channel) == 'pear.php.net') {
+            return false;
+        }
+
+        $channel = $this->_getChannelFromAlias($channel);
+        if ($channel == 'pear.php.net') {
+            return false;
+        }
+
+        $test = $this->_listChannelPackages($channel);
+        if (count($test)) {
+            return false;
+        }
+
+        $test = @rmdir($this->_channelDirectoryName($channel));
+        if (!$test) {
+            return false;
+        }
+
+        $file = $this->_getChannelAliasFileName($this->_getAlias($channel));
+        if (file_exists($file)) {
+            $test = @unlink($file);
+            if (!$test) {
+                return false;
+            }
+        }
+
+        $file = $this->_channelFileName($channel);
+        $ret = true;
+        if (file_exists($file)) {
+            $ret = @unlink($file);
+        }
+
+        return $ret;
+    }
+
+    /**
+     * Determine whether a channel exists in the registry
+     * @param string Channel Alias
+     * @return boolean
+     */
+    function _isChannelAlias($alias)
+    {
+        return file_exists($this->_getChannelAliasFileName($alias));
+    }
+
+    /**
+     * @param string|null
+     * @param string|null
+     * @param string|null
+     * @return array|null
+     * @access private
+     */
+    function _packageInfo($package = null, $key = null, $channel = 'pear.php.net')
+    {
+        if ($package === null) {
+            if ($channel === null) {
+                $channels = $this->_listChannels();
+                $ret = array();
+                foreach ($channels as $channel) {
+                    $channel = strtolower($channel);
+                    $ret[$channel] = array();
+                    $packages = $this->_listPackages($channel);
+                    foreach ($packages as $package) {
+                        $ret[$channel][] = $this->_packageInfo($package, null, $channel);
+                    }
+                }
+
+                return $ret;
+            }
+
+            $ps = $this->_listPackages($channel);
+            if (!count($ps)) {
+                return array();
+            }
+            return array_map(array(&$this, '_packageInfo'),
+                             $ps, array_fill(0, count($ps), null),
+                             array_fill(0, count($ps), $channel));
+        }
+
+        $fp = $this->_openPackageFile($package, 'r', $channel);
+        if ($fp === null) {
+            return null;
+        }
+
+        $rt = get_magic_quotes_runtime();
+        set_magic_quotes_runtime(0);
+        clearstatcache();
+        $this->_closePackageFile($fp);
+        $data = file_get_contents($this->_packageFileName($package, $channel));
+        set_magic_quotes_runtime($rt);
+        $data = unserialize($data);
+        if ($key === null) {
+            return $data;
+        }
+
+        // compatibility for package.xml version 2.0
+        if (isset($data['old'][$key])) {
+            return $data['old'][$key];
+        }
+
+        if (isset($data[$key])) {
+            return $data[$key];
+        }
+
+        return null;
+    }
+
+    /**
+     * @param string Channel name
+     * @param bool whether to strictly retrieve info of channels, not just aliases
+     * @return array|null
+     */
+    function _channelInfo($channel, $noaliases = false)
+    {
+        if (!$this->_channelExists($channel, $noaliases)) {
+            return null;
+        }
+
+        $fp = $this->_openChannelFile($channel, 'r');
+        if ($fp === null) {
+            return null;
+        }
+
+        $rt = get_magic_quotes_runtime();
+        set_magic_quotes_runtime(0);
+        clearstatcache();
+        $this->_closeChannelFile($fp);
+        $data = file_get_contents($this->_channelFileName($channel));
+        set_magic_quotes_runtime($rt);
+        $data = unserialize($data);
+        return $data;
+    }
+
+    function _listChannels()
+    {
+        $channellist = array();
+        if (!file_exists($this->channelsdir) || !is_dir($this->channelsdir)) {
+            return array('pear.php.net', 'pecl.php.net', 'doc.php.net', '__uri');
+        }
+
+        $dp = opendir($this->channelsdir);
+        while ($ent = readdir($dp)) {
+            if ($ent{0} == '.' || substr($ent, -4) != '.reg') {
+                continue;
+            }
+
+            if ($ent == '__uri.reg') {
+                $channellist[] = '__uri';
+                continue;
+            }
+
+            $channellist[] = str_replace('_', '/', substr($ent, 0, -4));
+        }
+
+        closedir($dp);
+        if (!in_array('pear.php.net', $channellist)) {
+            $channellist[] = 'pear.php.net';
+        }
+
+        if (!in_array('pecl.php.net', $channellist)) {
+            $channellist[] = 'pecl.php.net';
+        }
+
+        if (!in_array('doc.php.net', $channellist)) {
+            $channellist[] = 'doc.php.net';
+        }
+
+
+        if (!in_array('__uri', $channellist)) {
+            $channellist[] = '__uri';
+        }
+
+        natsort($channellist);
+        return $channellist;
+    }
+
+    function _listPackages($channel = false)
+    {
+        if ($channel && $this->_getChannelFromAlias($channel) != 'pear.php.net') {
+            return $this->_listChannelPackages($channel);
+        }
+
+        if (!file_exists($this->statedir) || !is_dir($this->statedir)) {
+            return array();
+        }
+
+        $pkglist = array();
+        $dp = opendir($this->statedir);
+        if (!$dp) {
+            return $pkglist;
+        }
+
+        while ($ent = readdir($dp)) {
+            if ($ent{0} == '.' || substr($ent, -4) != '.reg') {
+                continue;
+            }
+
+            $pkglist[] = substr($ent, 0, -4);
+        }
+        closedir($dp);
+        return $pkglist;
+    }
+
+    function _listChannelPackages($channel)
+    {
+        $pkglist = array();
+        if (!file_exists($this->_channelDirectoryName($channel)) ||
+              !is_dir($this->_channelDirectoryName($channel))) {
+            return array();
+        }
+
+        $dp = opendir($this->_channelDirectoryName($channel));
+        if (!$dp) {
+            return $pkglist;
+        }
+
+        while ($ent = readdir($dp)) {
+            if ($ent{0} == '.' || substr($ent, -4) != '.reg') {
+                continue;
+            }
+            $pkglist[] = substr($ent, 0, -4);
+        }
+
+        closedir($dp);
+        return $pkglist;
+    }
+
+    function _listAllPackages()
+    {
+        $ret = array();
+        foreach ($this->_listChannels() as $channel) {
+            $ret[$channel] = $this->_listPackages($channel);
+        }
+
+        return $ret;
+    }
+
+    /**
+     * Add an installed package to the registry
+     * @param string package name
+     * @param array package info (parsed by PEAR_Common::infoFrom*() methods)
+     * @return bool success of saving
+     * @access private
+     */
+    function _addPackage($package, $info)
+    {
+        if ($this->_packageExists($package)) {
+            return false;
+        }
+
+        $fp = $this->_openPackageFile($package, 'wb');
+        if ($fp === null) {
+            return false;
+        }
+
+        $info['_lastmodified'] = time();
+        fwrite($fp, serialize($info));
+        $this->_closePackageFile($fp);
+        if (isset($info['filelist'])) {
+            $this->_rebuildFileMap();
+        }
+
+        return true;
+    }
+
+    /**
+     * @param PEAR_PackageFile_v1|PEAR_PackageFile_v2
+     * @return bool
+     * @access private
+     */
+    function _addPackage2($info)
+    {
+        if (!is_a($info, 'PEAR_PackageFile_v1') && !is_a($info, 'PEAR_PackageFile_v2')) {
+            return false;
+        }
+
+        if (!$info->validate()) {
+            if (class_exists('PEAR_Common')) {
+                $ui = PEAR_Frontend::singleton();
+                if ($ui) {
+                    foreach ($info->getValidationWarnings() as $err) {
+                        $ui->log($err['message'], true);
+                    }
+                }
+            }
+            return false;
+        }
+
+        $channel = $info->getChannel();
+        $package = $info->getPackage();
+        $save = $info;
+        if ($this->_packageExists($package, $channel)) {
+            return false;
+        }
+
+        if (!$this->_channelExists($channel, true)) {
+            return false;
+        }
+
+        $info = $info->toArray(true);
+        if (!$info) {
+            return false;
+        }
+
+        $fp = $this->_openPackageFile($package, 'wb', $channel);
+        if ($fp === null) {
+            return false;
+        }
+
+        $info['_lastmodified'] = time();
+        fwrite($fp, serialize($info));
+        $this->_closePackageFile($fp);
+        $this->_rebuildFileMap();
+        return true;
+    }
+
+    /**
+     * @param string Package name
+     * @param array parsed package.xml 1.0
+     * @param bool this parameter is only here for BC.  Don't use it.
+     * @access private
+     */
+    function _updatePackage($package, $info, $merge = true)
+    {
+        $oldinfo = $this->_packageInfo($package);
+        if (empty($oldinfo)) {
+            return false;
+        }
+
+        $fp = $this->_openPackageFile($package, 'w');
+        if ($fp === null) {
+            return false;
+        }
+
+        if (is_object($info)) {
+            $info = $info->toArray();
+        }
+        $info['_lastmodified'] = time();
+
+        $newinfo = $info;
+        if ($merge) {
+            $info = array_merge($oldinfo, $info);
+        } else {
+            $diff = $info;
+        }
+
+        fwrite($fp, serialize($info));
+        $this->_closePackageFile($fp);
+        if (isset($newinfo['filelist'])) {
+            $this->_rebuildFileMap();
+        }
+
+        return true;
+    }
+
+    /**
+     * @param PEAR_PackageFile_v1|PEAR_PackageFile_v2
+     * @return bool
+     * @access private
+     */
+    function _updatePackage2($info)
+    {
+        if (!$this->_packageExists($info->getPackage(), $info->getChannel())) {
+            return false;
+        }
+
+        $fp = $this->_openPackageFile($info->getPackage(), 'w', $info->getChannel());
+        if ($fp === null) {
+            return false;
+        }
+
+        $save = $info;
+        $info = $save->getArray(true);
+        $info['_lastmodified'] = time();
+        fwrite($fp, serialize($info));
+        $this->_closePackageFile($fp);
+        $this->_rebuildFileMap();
+        return true;
+    }
+
+    /**
+     * @param string Package name
+     * @param string Channel name
+     * @return PEAR_PackageFile_v1|PEAR_PackageFile_v2|null
+     * @access private
+     */
+    function &_getPackage($package, $channel = 'pear.php.net')
+    {
+        $info = $this->_packageInfo($package, null, $channel);
+        if ($info === null) {
+            return $info;
+        }
+
+        $a = $this->_config;
+        if (!$a) {
+            $this->_config = &new PEAR_Config;
+            $this->_config->set('php_dir', $this->statedir);
+        }
+
+        if (!class_exists('PEAR_PackageFile')) {
+            require_once 'PEAR/PackageFile.php';
+        }
+
+        $pkg = &new PEAR_PackageFile($this->_config);
+        $pf = &$pkg->fromArray($info);
+        return $pf;
+    }
+
+    /**
+     * @param string channel name
+     * @param bool whether to strictly retrieve channel names
+     * @return PEAR_ChannelFile|PEAR_Error
+     * @access private
+     */
+    function &_getChannel($channel, $noaliases = false)
+    {
+        $ch = false;
+        if ($this->_channelExists($channel, $noaliases)) {
+            $chinfo = $this->_channelInfo($channel, $noaliases);
+            if ($chinfo) {
+                if (!class_exists('PEAR_ChannelFile')) {
+                    require_once 'PEAR/ChannelFile.php';
+                }
+
+                $ch = &PEAR_ChannelFile::fromArrayWithErrors($chinfo);
+            }
+        }
+
+        if ($ch) {
+            if ($ch->validate()) {
+                return $ch;
+            }
+
+            foreach ($ch->getErrors(true) as $err) {
+                $message = $err['message'] . "\n";
+            }
+
+            $ch = PEAR::raiseError($message);
+            return $ch;
+        }
+
+        if ($this->_getChannelFromAlias($channel) == 'pear.php.net') {
+            // the registry is not properly set up, so use defaults
+            if (!class_exists('PEAR_ChannelFile')) {
+                require_once 'PEAR/ChannelFile.php';
+            }
+
+            $pear_channel = new PEAR_ChannelFile;
+            $pear_channel->setServer('pear.php.net');
+            $pear_channel->setAlias('pear');
+            $pear_channel->setSummary('PHP Extension and Application Repository');
+            $pear_channel->setDefaultPEARProtocols();
+            $pear_channel->setBaseURL('REST1.0', 'http://pear.php.net/rest/');
+            $pear_channel->setBaseURL('REST1.1', 'http://pear.php.net/rest/');
+            $pear_channel->setBaseURL('REST1.3', 'http://pear.php.net/rest/');
+            return $pear_channel;
+        }
+
+        if ($this->_getChannelFromAlias($channel) == 'pecl.php.net') {
+            // the registry is not properly set up, so use defaults
+            if (!class_exists('PEAR_ChannelFile')) {
+                require_once 'PEAR/ChannelFile.php';
+            }
+            $pear_channel = new PEAR_ChannelFile;
+            $pear_channel->setServer('pecl.php.net');
+            $pear_channel->setAlias('pecl');
+            $pear_channel->setSummary('PHP Extension Community Library');
+            $pear_channel->setDefaultPEARProtocols();
+            $pear_channel->setBaseURL('REST1.0', 'http://pecl.php.net/rest/');
+            $pear_channel->setBaseURL('REST1.1', 'http://pecl.php.net/rest/');
+            $pear_channel->setValidationPackage('PEAR_Validator_PECL', '1.0');
+            return $pear_channel;
+        }
+
+        if ($this->_getChannelFromAlias($channel) == 'doc.php.net') {
+            // the registry is not properly set up, so use defaults
+            if (!class_exists('PEAR_ChannelFile')) {
+                require_once 'PEAR/ChannelFile.php';
+            }
+
+            $doc_channel = new PEAR_ChannelFile;
+            $doc_channel->setServer('doc.php.net');
+            $doc_channel->setAlias('phpdocs');
+            $doc_channel->setSummary('PHP Documentation Team');
+            $doc_channel->setDefaultPEARProtocols();
+            $doc_channel->setBaseURL('REST1.0', 'http://doc.php.net/rest/');
+            $doc_channel->setBaseURL('REST1.1', 'http://doc.php.net/rest/');
+            $doc_channel->setBaseURL('REST1.3', 'http://doc.php.net/rest/');
+            return $doc_channel;
+        }
+
+
+        if ($this->_getChannelFromAlias($channel) == '__uri') {
+            // the registry is not properly set up, so use defaults
+            if (!class_exists('PEAR_ChannelFile')) {
+                require_once 'PEAR/ChannelFile.php';
+            }
+
+            $private = new PEAR_ChannelFile;
+            $private->setName('__uri');
+            $private->setDefaultPEARProtocols();
+            $private->setBaseURL('REST1.0', '****');
+            $private->setSummary('Pseudo-channel for static packages');
+            return $private;
+        }
+
+        return $ch;
+    }
+
+    /**
+     * @param string Package name
+     * @param string Channel name
+     * @return bool
+     */
+    function packageExists($package, $channel = 'pear.php.net')
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_packageExists($package, $channel);
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+
+    // {{{ channelExists()
+
+    /**
+     * @param string channel name
+     * @param bool if true, then aliases will be ignored
+     * @return bool
+     */
+    function channelExists($channel, $noaliases = false)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_channelExists($channel, $noaliases);
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+
+    /**
+     * @param string channel name mirror is in
+     * @param string mirror name
+     *
+     * @return bool
+     */
+    function mirrorExists($channel, $mirror)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+
+        $ret = $this->_mirrorExists($channel, $mirror);
+        $this->_unlock();
+        return $ret;
+    }
+
+    // {{{ isAlias()
+
+    /**
+     * Determines whether the parameter is an alias of a channel
+     * @param string
+     * @return bool
+     */
+    function isAlias($alias)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_isChannelAlias($alias);
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+    // {{{ packageInfo()
+
+    /**
+     * @param string|null
+     * @param string|null
+     * @param string
+     * @return array|null
+     */
+    function packageInfo($package = null, $key = null, $channel = 'pear.php.net')
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_packageInfo($package, $key, $channel);
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+    // {{{ channelInfo()
+
+    /**
+     * Retrieve a raw array of channel data.
+     *
+     * Do not use this, instead use {@link getChannel()} for normal
+     * operations.  Array structure is undefined in this method
+     * @param string channel name
+     * @param bool whether to strictly retrieve information only on non-aliases
+     * @return array|null|PEAR_Error
+     */
+    function channelInfo($channel = null, $noaliases = false)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_channelInfo($channel, $noaliases);
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+
+    /**
+     * @param string
+     */
+    function channelName($channel)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_getChannelFromAlias($channel);
+        $this->_unlock();
+        return $ret;
+    }
+
+    /**
+     * @param string
+     */
+    function channelAlias($channel)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_getAlias($channel);
+        $this->_unlock();
+        return $ret;
+    }
+    // {{{ listPackages()
+
+    function listPackages($channel = false)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_listPackages($channel);
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+    // {{{ listAllPackages()
+
+    function listAllPackages()
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_listAllPackages();
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+    // {{{ listChannel()
+
+    function listChannels()
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_listChannels();
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+    // {{{ addPackage()
+
+    /**
+     * Add an installed package to the registry
+     * @param string|PEAR_PackageFile_v1|PEAR_PackageFile_v2 package name or object
+     *               that will be passed to {@link addPackage2()}
+     * @param array package info (parsed by PEAR_Common::infoFrom*() methods)
+     * @return bool success of saving
+     */
+    function addPackage($package, $info)
+    {
+        if (is_object($info)) {
+            return $this->addPackage2($info);
+        }
+        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
+            return $e;
+        }
+        $ret = $this->_addPackage($package, $info);
+        $this->_unlock();
+        if ($ret) {
+            if (!class_exists('PEAR_PackageFile_v1')) {
+                require_once 'PEAR/PackageFile/v1.php';
+            }
+            $pf = new PEAR_PackageFile_v1;
+            $pf->setConfig($this->_config);
+            $pf->fromArray($info);
+            $this->_dependencyDB->uninstallPackage($pf);
+            $this->_dependencyDB->installPackage($pf);
+        }
+        return $ret;
+    }
+
+    // }}}
+    // {{{ addPackage2()
+
+    function addPackage2($info)
+    {
+        if (!is_object($info)) {
+            return $this->addPackage($info['package'], $info);
+        }
+        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
+            return $e;
+        }
+        $ret = $this->_addPackage2($info);
+        $this->_unlock();
+        if ($ret) {
+            $this->_dependencyDB->uninstallPackage($info);
+            $this->_dependencyDB->installPackage($info);
+        }
+        return $ret;
+    }
+
+    // }}}
+    // {{{ updateChannel()
+
+    /**
+     * For future expandibility purposes, separate this
+     * @param PEAR_ChannelFile
+     */
+    function updateChannel($channel, $lastmodified = null)
+    {
+        if ($channel->getName() == '__uri') {
+            return false;
+        }
+        return $this->addChannel($channel, $lastmodified, true);
+    }
+
+    // }}}
+    // {{{ deleteChannel()
+
+    /**
+     * Deletion fails if there are any packages installed from the channel
+     * @param string|PEAR_ChannelFile channel name
+     * @return boolean|PEAR_Error True on deletion, false if it doesn't exist
+     */
+    function deleteChannel($channel)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
+            return $e;
+        }
+
+        $ret = $this->_deleteChannel($channel);
+        $this->_unlock();
+        if ($ret && is_a($this->_config, 'PEAR_Config')) {
+            $this->_config->setChannels($this->listChannels());
+        }
+
+        return $ret;
+    }
+
+    // }}}
+    // {{{ addChannel()
+
+    /**
+     * @param PEAR_ChannelFile Channel object
+     * @param string Last-Modified header from HTTP for caching
+     * @return boolean|PEAR_Error True on creation, false if it already exists
+     */
+    function addChannel($channel, $lastmodified = false, $update = false)
+    {
+        if (!is_a($channel, 'PEAR_ChannelFile') || !$channel->validate()) {
+            return false;
+        }
+
+        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
+            return $e;
+        }
+
+        $ret = $this->_addChannel($channel, $update, $lastmodified);
+        $this->_unlock();
+        if (!$update && $ret && is_a($this->_config, 'PEAR_Config')) {
+            $this->_config->setChannels($this->listChannels());
+        }
+
+        return $ret;
+    }
+
+    // }}}
+    // {{{ deletePackage()
+
+    function deletePackage($package, $channel = 'pear.php.net')
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
+            return $e;
+        }
+
+        $file = $this->_packageFileName($package, $channel);
+        $ret  = file_exists($file) ? @unlink($file) : false;
+        $this->_rebuildFileMap();
+        $this->_unlock();
+        $p = array('channel' => $channel, 'package' => $package);
+        $this->_dependencyDB->uninstallPackage($p);
+        return $ret;
+    }
+
+    // }}}
+    // {{{ updatePackage()
+
+    function updatePackage($package, $info, $merge = true)
+    {
+        if (is_object($info)) {
+            return $this->updatePackage2($info, $merge);
+        }
+        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
+            return $e;
+        }
+        $ret = $this->_updatePackage($package, $info, $merge);
+        $this->_unlock();
+        if ($ret) {
+            if (!class_exists('PEAR_PackageFile_v1')) {
+                require_once 'PEAR/PackageFile/v1.php';
+            }
+            $pf = new PEAR_PackageFile_v1;
+            $pf->setConfig($this->_config);
+            $pf->fromArray($this->packageInfo($package));
+            $this->_dependencyDB->uninstallPackage($pf);
+            $this->_dependencyDB->installPackage($pf);
+        }
+        return $ret;
+    }
+
+    // }}}
+    // {{{ updatePackage2()
+
+    function updatePackage2($info)
+    {
+
+        if (!is_object($info)) {
+            return $this->updatePackage($info['package'], $info, $merge);
+        }
+
+        if (!$info->validate(PEAR_VALIDATE_DOWNLOADING)) {
+            return false;
+        }
+
+        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
+            return $e;
+        }
+
+        $ret = $this->_updatePackage2($info);
+        $this->_unlock();
+        if ($ret) {
+            $this->_dependencyDB->uninstallPackage($info);
+            $this->_dependencyDB->installPackage($info);
+        }
+
+        return $ret;
+    }
+
+    // }}}
+    // {{{ getChannel()
+    /**
+     * @param string channel name
+     * @param bool whether to strictly return raw channels (no aliases)
+     * @return PEAR_ChannelFile|PEAR_Error
+     */
+    function &getChannel($channel, $noaliases = false)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = &$this->_getChannel($channel, $noaliases);
+        $this->_unlock();
+        if (!$ret) {
+            return PEAR::raiseError('Unknown channel: ' . $channel);
+        }
+        return $ret;
+    }
+
+    // }}}
+    // {{{ getPackage()
+    /**
+     * @param string package name
+     * @param string channel name
+     * @return PEAR_PackageFile_v1|PEAR_PackageFile_v2|null
+     */
+    function &getPackage($package, $channel = 'pear.php.net')
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $pf = &$this->_getPackage($package, $channel);
+        $this->_unlock();
+        return $pf;
+    }
+
+    // }}}
+
+    /**
+     * Get PEAR_PackageFile_v[1/2] objects representing the contents of
+     * a dependency group that are installed.
+     *
+     * This is used at uninstall-time
+     * @param array
+     * @return array|false
+     */
+    function getInstalledGroup($group)
+    {
+        $ret = array();
+        if (isset($group['package'])) {
+            if (!isset($group['package'][0])) {
+                $group['package'] = array($group['package']);
+            }
+            foreach ($group['package'] as $package) {
+                $depchannel = isset($package['channel']) ? $package['channel'] : '__uri';
+                $p = &$this->getPackage($package['name'], $depchannel);
+                if ($p) {
+                    $save = &$p;
+                    $ret[] = &$save;
+                }
+            }
+        }
+        if (isset($group['subpackage'])) {
+            if (!isset($group['subpackage'][0])) {
+                $group['subpackage'] = array($group['subpackage']);
+            }
+            foreach ($group['subpackage'] as $package) {
+                $depchannel = isset($package['channel']) ? $package['channel'] : '__uri';
+                $p = &$this->getPackage($package['name'], $depchannel);
+                if ($p) {
+                    $save = &$p;
+                    $ret[] = &$save;
+                }
+            }
+        }
+        if (!count($ret)) {
+            return false;
+        }
+        return $ret;
+    }
+
+    // {{{ getChannelValidator()
+    /**
+     * @param string channel name
+     * @return PEAR_Validate|false
+     */
+    function &getChannelValidator($channel)
+    {
+        $chan = $this->getChannel($channel);
+        if (PEAR::isError($chan)) {
+            return $chan;
+        }
+        $val = $chan->getValidationObject();
+        return $val;
+    }
+    // }}}
+    // {{{ getChannels()
+    /**
+     * @param string channel name
+     * @return array an array of PEAR_ChannelFile objects representing every installed channel
+     */
+    function &getChannels()
+    {
+        $ret = array();
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        foreach ($this->_listChannels() as $channel) {
+            $e = &$this->_getChannel($channel);
+            if (!$e || PEAR::isError($e)) {
+                continue;
+            }
+            $ret[] = $e;
+        }
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+    // {{{ checkFileMap()
+
+    /**
+     * Test whether a file or set of files belongs to a package.
+     *
+     * If an array is passed in
+     * @param string|array file path, absolute or relative to the pear
+     *                     install dir
+     * @param string|array name of PEAR package or array('package' => name, 'channel' =>
+     *                     channel) of a package that will be ignored
+     * @param string API version - 1.1 will exclude any files belonging to a package
+     * @param array private recursion variable
+     * @return array|false which package and channel the file belongs to, or an empty
+     *                     string if the file does not belong to an installed package,
+     *                     or belongs to the second parameter's package
+     */
+    function checkFileMap($path, $package = false, $api = '1.0', $attrs = false)
+    {
+        if (is_array($path)) {
+            static $notempty;
+            if (empty($notempty)) {
+                if (!class_exists('PEAR_Installer_Role')) {
+                    require_once 'PEAR/Installer/Role.php';
+                }
+                $notempty = create_function('$a','return !empty($a);');
+            }
+            $package = is_array($package) ? array(strtolower($package[0]), strtolower($package[1]))
+                : strtolower($package);
+            $pkgs = array();
+            foreach ($path as $name => $attrs) {
+                if (is_array($attrs)) {
+                    if (isset($attrs['install-as'])) {
+                        $name = $attrs['install-as'];
+                    }
+                    if (!in_array($attrs['role'], PEAR_Installer_Role::getInstallableRoles())) {
+                        // these are not installed
+                        continue;
+                    }
+                    if (!in_array($attrs['role'], PEAR_Installer_Role::getBaseinstallRoles())) {
+                        $attrs['baseinstalldir'] = is_array($package) ? $package[1] : $package;
+                    }
+                    if (isset($attrs['baseinstalldir'])) {
+                        $name = $attrs['baseinstalldir'] . DIRECTORY_SEPARATOR . $name;
+                    }
+                }
+                $pkgs[$name] = $this->checkFileMap($name, $package, $api, $attrs);
+                if (PEAR::isError($pkgs[$name])) {
+                    return $pkgs[$name];
+                }
+            }
+            return array_filter($pkgs, $notempty);
+        }
+        if (empty($this->filemap_cache)) {
+            if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+                return $e;
+            }
+            $err = $this->_readFileMap();
+            $this->_unlock();
+            if (PEAR::isError($err)) {
+                return $err;
+            }
+        }
+        if (!$attrs) {
+            $attrs = array('role' => 'php'); // any old call would be for PHP role only
+        }
+        if (isset($this->filemap_cache[$attrs['role']][$path])) {
+            if ($api >= '1.1' && $this->filemap_cache[$attrs['role']][$path] == $package) {
+                return false;
+            }
+            return $this->filemap_cache[$attrs['role']][$path];
+        }
+        $l = strlen($this->install_dir);
+        if (substr($path, 0, $l) == $this->install_dir) {
+            $path = preg_replace('!^'.DIRECTORY_SEPARATOR.'+!', '', substr($path, $l));
+        }
+        if (isset($this->filemap_cache[$attrs['role']][$path])) {
+            if ($api >= '1.1' && $this->filemap_cache[$attrs['role']][$path] == $package) {
+                return false;
+            }
+            return $this->filemap_cache[$attrs['role']][$path];
+        }
+        return false;
+    }
+
+    // }}}
+    // {{{ flush()
+    /**
+     * Force a reload of the filemap
+     * @since 1.5.0RC3
+     */
+    function flushFileMap()
+    {
+        $this->filemap_cache = null;
+        clearstatcache(); // ensure that the next read gets the full, current filemap
+    }
+
+    // }}}
+    // {{{ apiVersion()
+    /**
+     * Get the expected API version.  Channels API is version 1.1, as it is backwards
+     * compatible with 1.0
+     * @return string
+     */
+    function apiVersion()
+    {
+        return '1.1';
+    }
+    // }}}
+
+
+    /**
+     * Parse a package name, or validate a parsed package name array
+     * @param string|array pass in an array of format
+     *                     array(
+     *                      'package' => 'pname',
+     *                     ['channel' => 'channame',]
+     *                     ['version' => 'version',]
+     *                     ['state' => 'state',]
+     *                     ['group' => 'groupname'])
+     *                     or a string of format
+     *                     [channel://][channame/]pname[-version|-state][/group=groupname]
+     * @return array|PEAR_Error
+     */
+    function parsePackageName($param, $defaultchannel = 'pear.php.net')
+    {
+        $saveparam = $param;
+        if (is_array($param)) {
+            // convert to string for error messages
+            $saveparam = $this->parsedPackageNameToString($param);
+            // process the array
+            if (!isset($param['package'])) {
+                return PEAR::raiseError('parsePackageName(): array $param ' .
+                    'must contain a valid package name in index "param"',
+                    'package', null, null, $param);
+            }
+            if (!isset($param['uri'])) {
+                if (!isset($param['channel'])) {
+                    $param['channel'] = $defaultchannel;
+                }
+            } else {
+                $param['channel'] = '__uri';
+            }
+        } else {
+            $components = @parse_url((string) $param);
+            if (isset($components['scheme'])) {
+                if ($components['scheme'] == 'http') {
+                    // uri package
+                    $param = array('uri' => $param, 'channel' => '__uri');
+                } elseif($components['scheme'] != 'channel') {
+                    return PEAR::raiseError('parsePackageName(): only channel:// uris may ' .
+                        'be downloaded, not "' . $param . '"', 'invalid', null, null, $param);
+                }
+            }
+            if (!isset($components['path'])) {
+                return PEAR::raiseError('parsePackageName(): array $param ' .
+                    'must contain a valid package name in "' . $param . '"',
+                    'package', null, null, $param);
+            }
+            if (isset($components['host'])) {
+                // remove the leading "/"
+                $components['path'] = substr($components['path'], 1);
+            }
+            if (!isset($components['scheme'])) {
+                if (strpos($components['path'], '/') !== false) {
+                    if ($components['path']{0} == '/') {
+                        return PEAR::raiseError('parsePackageName(): this is not ' .
+                            'a package name, it begins with "/" in "' . $param . '"',
+                            'invalid', null, null, $param);
+                    }
+                    $parts = explode('/', $components['path']);
+                    $components['host'] = array_shift($parts);
+                    if (count($parts) > 1) {
+                        $components['path'] = array_pop($parts);
+                        $components['host'] .= '/' . implode('/', $parts);
+                    } else {
+                        $components['path'] = implode('/', $parts);
+                    }
+                } else {
+                    $components['host'] = $defaultchannel;
+                }
+            } else {
+                if (strpos($components['path'], '/')) {
+                    $parts = explode('/', $components['path']);
+                    $components['path'] = array_pop($parts);
+                    $components['host'] .= '/' . implode('/', $parts);
+                }
+            }
+
+            if (is_array($param)) {
+                $param['package'] = $components['path'];
+            } else {
+                $param = array(
+                    'package' => $components['path']
+                    );
+                if (isset($components['host'])) {
+                    $param['channel'] = $components['host'];
+                }
+            }
+            if (isset($components['fragment'])) {
+                $param['group'] = $components['fragment'];
+            }
+            if (isset($components['user'])) {
+                $param['user'] = $components['user'];
+            }
+            if (isset($components['pass'])) {
+                $param['pass'] = $components['pass'];
+            }
+            if (isset($components['query'])) {
+                parse_str($components['query'], $param['opts']);
+            }
+            // check for extension
+            $pathinfo = pathinfo($param['package']);
+            if (isset($pathinfo['extension']) &&
+                  in_array(strtolower($pathinfo['extension']), array('tgz', 'tar'))) {
+                $param['extension'] = $pathinfo['extension'];
+                $param['package'] = substr($pathinfo['basename'], 0,
+                    strlen($pathinfo['basename']) - 4);
+            }
+            // check for version
+            if (strpos($param['package'], '-')) {
+                $test = explode('-', $param['package']);
+                if (count($test) != 2) {
+                    return PEAR::raiseError('parsePackageName(): only one version/state ' .
+                        'delimiter "-" is allowed in "' . $saveparam . '"',
+                        'version', null, null, $param);
+                }
+                list($param['package'], $param['version']) = $test;
+            }
+        }
+        // validation
+        $info = $this->channelExists($param['channel']);
+        if (PEAR::isError($info)) {
+            return $info;
+        }
+        if (!$info) {
+            return PEAR::raiseError('unknown channel "' . $param['channel'] .
+                '" in "' . $saveparam . '"', 'channel', null, null, $param);
+        }
+        $chan = $this->getChannel($param['channel']);
+        if (PEAR::isError($chan)) {
+            return $chan;
+        }
+        if (!$chan) {
+            return PEAR::raiseError("Exception: corrupt registry, could not " .
+                "retrieve channel " . $param['channel'] . " information",
+                'registry', null, null, $param);
+        }
+        $param['channel'] = $chan->getName();
+        $validate = $chan->getValidationObject();
+        $vpackage = $chan->getValidationPackage();
+        // validate package name
+        if (!$validate->validPackageName($param['package'], $vpackage['_content'])) {
+            return PEAR::raiseError('parsePackageName(): invalid package name "' .
+                $param['package'] . '" in "' . $saveparam . '"',
+                'package', null, null, $param);
+        }
+        if (isset($param['group'])) {
+            if (!PEAR_Validate::validGroupName($param['group'])) {
+                return PEAR::raiseError('parsePackageName(): dependency group "' . $param['group'] .
+                    '" is not a valid group name in "' . $saveparam . '"', 'group', null, null,
+                    $param);
+            }
+        }
+        if (isset($param['state'])) {
+            if (!in_array(strtolower($param['state']), $validate->getValidStates())) {
+                return PEAR::raiseError('parsePackageName(): state "' . $param['state']
+                    . '" is not a valid state in "' . $saveparam . '"',
+                    'state', null, null, $param);
+            }
+        }
+        if (isset($param['version'])) {
+            if (isset($param['state'])) {
+                return PEAR::raiseError('parsePackageName(): cannot contain both ' .
+                    'a version and a stability (state) in "' . $saveparam . '"',
+                    'version/state', null, null, $param);
+            }
+            // check whether version is actually a state
+            if (in_array(strtolower($param['version']), $validate->getValidStates())) {
+                $param['state'] = strtolower($param['version']);
+                unset($param['version']);
+            } else {
+                if (!$validate->validVersion($param['version'])) {
+                    return PEAR::raiseError('parsePackageName(): "' . $param['version'] .
+                        '" is neither a valid version nor a valid state in "' .
+                        $saveparam . '"', 'version/state', null, null, $param);
+                }
+            }
+        }
+        return $param;
+    }
+
+    /**
+     * @param array
+     * @return string
+     */
+    function parsedPackageNameToString($parsed, $brief = false)
+    {
+        if (is_string($parsed)) {
+            return $parsed;
+        }
+        if (is_object($parsed)) {
+            $p = $parsed;
+            $parsed = array(
+                'package' => $p->getPackage(),
+                'channel' => $p->getChannel(),
+                'version' => $p->getVersion(),
+            );
+        }
+        if (isset($parsed['uri'])) {
+            return $parsed['uri'];
+        }
+        if ($brief) {
+            if ($channel = $this->channelAlias($parsed['channel'])) {
+                return $channel . '/' . $parsed['package'];
+            }
+        }
+        $upass = '';
+        if (isset($parsed['user'])) {
+            $upass = $parsed['user'];
+            if (isset($parsed['pass'])) {
+                $upass .= ':' . $parsed['pass'];
+            }
+            $upass = "$upass@";
+        }
+        $ret = 'channel://' . $upass . $parsed['channel'] . '/' . $parsed['package'];
+        if (isset($parsed['version']) || isset($parsed['state'])) {
+            $ver = isset($parsed['version']) ? $parsed['version'] : '';
+            $ver .= isset($parsed['state']) ? $parsed['state'] : '';
+            $ret .= '-' . $ver;
+        }
+        if (isset($parsed['extension'])) {
+            $ret .= '.' . $parsed['extension'];
+        }
+        if (isset($parsed['opts'])) {
+            $ret .= '?';
+            foreach ($parsed['opts'] as $name => $value) {
+                $parsed['opts'][$name] = "$name=$value";
+            }
+            $ret .= implode('&', $parsed['opts']);
+        }
+        if (isset($parsed['group'])) {
+            $ret .= '#' . $parsed['group'];
+        }
+        return $ret;
+    }
+}                                                                                                                                                                                                                                                                                                                                                                                                                                            PEAR-1.9.0/PEAR/REST.php                                                                            100664     764     764        36073      100664   7354                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_REST
  *
@@ -48430,7 +49001,7 @@ class PEAR_Registry extends PEAR
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: REST.php,v 1.40 2009/03/26 23:12:46 dufuz Exp $
+ * @version    CVS: $Id: REST.php 286489 2009-07-29 05:59:08Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -48449,7 +49020,7 @@ require_once 'PEAR/XMLParser.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -48460,7 +49031,7 @@ class PEAR_REST
 
     function PEAR_REST(&$config, $options = array())
     {
-        $this->config = &$config;
+        $this->config   = &$config;
         $this->_options = $options;
     }
 
@@ -48477,7 +49048,6 @@ class PEAR_REST
      */
     function retrieveCacheFirst($url, $accept = false, $forcestring = false, $channel = false)
     {
-
         $cachefile = $this->config->get('cache_dir') . DIRECTORY_SEPARATOR .
             md5($url) . 'rest.cachefile';
 
@@ -48634,11 +49204,9 @@ class PEAR_REST
      */
     function saveCache($url, $contents, $lastmodified, $nochange = false, $cacheid = null)
     {
-        $cacheidfile = $this->config->get('cache_dir') . DIRECTORY_SEPARATOR .
-            md5($url) . 'rest.cacheid';
-
-        $cachefile = $this->config->get('cache_dir') . DIRECTORY_SEPARATOR .
-            md5($url) . 'rest.cachefile';
+        $cachedir    = $this->config->get('cache_dir') . DIRECTORY_SEPARATOR . md5($url);
+        $cacheidfile = $cachedir . 'rest.cacheid';
+        $cachefile   = $cachedir . 'rest.cachefile';
 
         if ($cacheid === null && $nochange) {
             $cacheid = unserialize(implode('', file($cacheidfile)));
@@ -48772,7 +49340,7 @@ class PEAR_REST
         }
 
         $request .= $ifmodifiedsince .
-            "User-Agent: PEAR/1.8.0/PHP/" . PHP_VERSION . "\r\n";
+            "User-Agent: PEAR/1.9.0/PHP/" . PHP_VERSION . "\r\n";
 
         $username = $this->config->get('username', null, $channel);
         $password = $this->config->get('password', null, $channel);
@@ -48869,7 +49437,7 @@ class PEAR_REST
 
         return $data;
     }
-}                                                                                                                                                                                                                                                                                                                                                                                                                      PEAR-1.8.0/PEAR/RunTest.php                                                                         100664     764     764       104653      100664  10222                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                                                                                                                                                                                                                                                                                                     PEAR-1.9.0/PEAR/RunTest.php                                                                         100664     764     764       105252      100664  10217                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_RunTest
  *
@@ -48881,7 +49449,7 @@ class PEAR_REST
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: RunTest.php,v 1.74 2009/02/24 23:38:22 dufuz Exp $
+ * @version    CVS: $Id: RunTest.php 287447 2009-08-18 11:46:19Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.3.3
  */
@@ -48909,7 +49477,7 @@ putenv("PHP_PEAR_RUNTESTS=1");
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.3.3
  */
@@ -49116,12 +49684,11 @@ class PEAR_RunTest
     {
         if (!file_exists($file) && file_exists(getcwd() . DIRECTORY_SEPARATOR . $file)) {
             $file = realpath(getcwd() . DIRECTORY_SEPARATOR . $file);
-            break;
         } elseif (file_exists($file)) {
             $file = realpath($file);
         }
 
-        $cmd = $this->_preparePhpBin($this->_php, $file. $ini_settings);
+        $cmd = $this->_preparePhpBin($this->_php, $file, $ini_settings);
         if (isset($this->_logger)) {
             $this->_logger->log(2, 'Running command "' . $cmd . '"');
         }
@@ -49422,7 +49989,13 @@ class PEAR_RunTest
                     fclose($fp);
                     $section_text['EXPECT'] = file_get_contents($f);
                 }
-                $wanted = preg_replace('/\r\n/', "\n", trim($section_text['EXPECT']));
+
+                if (isset($section_text['EXPECT'])) {
+                    $wanted = preg_replace('/\r\n/', "\n", trim($section_text['EXPECT']));
+                } else {
+                    $wanted = '';
+                }
+
                 // compare and leave on success
                 if (!$returnfail && 0 == strcmp($output, $wanted)) {
                     if (file_exists($temp_file)) {
@@ -49805,13 +50378,16 @@ $text
         if ($section_text['CLEAN']) {
             // perform test cleanup
             $this->save_text($temp_clean, $section_text['CLEAN']);
-            $this->system_with_timeout("$this->_php $temp_clean");
+            $output = $this->system_with_timeout("$this->_php $temp_clean  2>&1");
+            if (strlen($output[1])) {
+                echo "BORKED --CLEAN-- section! output:\n", $output[1];
+            }
             if (file_exists($temp_clean)) {
                 unlink($temp_clean);
             }
         }
     }
-}                                                                                     PEAR-1.8.0/PEAR/Validate.php                                                                        100664     764     764        53060      100664  10322                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                                                                                                                                                                                      PEAR-1.9.0/PEAR/Validate.php                                                                        100664     764     764        53055      100664  10327                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_Validate
  *
@@ -49822,7 +50398,7 @@ $text
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Validate.php,v 1.54 2009/02/24 23:38:23 dufuz Exp $
+ * @version    CVS: $Id: Validate.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -49845,7 +50421,7 @@ require_once 'PEAR/Validator/PECL.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -50439,7 +51015,7 @@ class PEAR_Validate
     {
         return true;
     }
-}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                PEAR-1.8.0/PEAR/XMLParser.php                                                                       100664     764     764        16252      100664  10410                                                                                                                                                                                                                                                                                                                                                                      <?php
+}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   PEAR-1.9.0/PEAR/XMLParser.php                                                                       100664     764     764        16001      100664  10401                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR_XMLParser
  *
@@ -50451,7 +51027,7 @@ class PEAR_Validate
  * @author     Stephan Schmidt (original XML_Unserializer code)
  * @copyright  1997-2009 The Authors
  * @license   http://opensource.org/licenses/bsd-license New BSD License
- * @version    CVS: $Id: XMLParser.php,v 1.22 2009/03/08 00:45:39 dufuz Exp $
+ * @version    CVS: $Id: XMLParser.php 282970 2009-06-28 23:10:07Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -50464,7 +51040,7 @@ class PEAR_Validate
  * @author    Stephan Schmidt (original XML_Unserializer code)
  * @copyright 1997-2009 The Authors
  * @license   http://opensource.org/licenses/bsd-license New BSD License
- * @version   Release: 1.8.0
+ * @version   Release: 1.9.0
  * @link      http://pear.php.net/package/PEAR
  * @since     Class available since Release 1.4.0a1
  */
@@ -50486,13 +51062,13 @@ class PEAR_XMLParser
      * stack for all data that is found
      * @var array    $_dataStack
      */
-    var $_dataStack  =   array();
+    var $_dataStack = array();
 
     /**
      * stack for all values that are generated
      * @var array    $_valStack
      */
-    var $_valStack  =   array();
+    var $_valStack = array();
 
     /**
      * current tag depth
@@ -50524,8 +51100,7 @@ class PEAR_XMLParser
             include_once 'PEAR.php';
             return PEAR::raiseError("XML Extension not found", 1);
         }
-        $this->_valStack = array();
-        $this->_dataStack = array();
+        $this->_dataStack =  $this->_valStack = array();
         $this->_depth = 0;
 
         if (
@@ -50539,6 +51114,7 @@ class PEAR_XMLParser
 
         if (version_compare(phpversion(), '5.0.0', 'lt') && $this->encoding == 'UTF-8') {
             $data = utf8_decode($data);
+            $this->encoding = 'ISO-8859-1';
         }
 
         $xp = xml_parser_create($this->encoding);
@@ -50568,25 +51144,21 @@ class PEAR_XMLParser
      */
     function startHandler($parser, $element, $attribs)
     {
-        $type = 'string';
-
         $this->_depth++;
         $this->_dataStack[$this->_depth] = null;
 
         $val = array(
-                     'name'         => $element,
-                     'value'        => null,
-                     'type'         => $type,
-                     'childrenKeys' => array(),
-                     'aggregKeys'   => array()
-                    );
+            'name'         => $element,
+            'value'        => null,
+            'type'         => 'string',
+            'childrenKeys' => array(),
+            'aggregKeys'   => array()
+       );
 
         if (count($attribs) > 0) {
             $val['children'] = array();
             $val['type'] = 'array';
-
             $val['children']['attribs'] = $attribs;
-
         }
 
         array_push($this->_valStack, $val);
@@ -50617,18 +51189,14 @@ class PEAR_XMLParser
         $data  = $this->postProcess($this->_dataStack[$this->_depth], $element);
 
         // adjust type of the value
-        switch(strtolower($value['type'])) {
-
+        switch (strtolower($value['type'])) {
             // unserialize an array
             case 'array':
                 if ($data !== '') {
                     $value['children']['_content'] = $data;
                 }
-                if (isset($value['children'])) {
-                    $value['value'] = $value['children'];
-                } else {
-                    $value['value'] = array();
-                }
+
+                $value['value'] = isset($value['children']) ? $value['children'] : array();
                 break;
 
             /*
@@ -50699,7 +51267,7 @@ class PEAR_XMLParser
     {
         $this->_dataStack[$this->_depth] .= $cdata;
     }
-}                                                                                                                                                                                                                                                                                                                                                      PEAR-1.8.0/scripts/pear.bat                                                                         100777     764     764        11102      100777  10440                                                                                                                                                                                                                                                                                                                                                                      @ECHO OFF
+}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               PEAR-1.9.0/scripts/pear.bat                                                                         100775     764     764        11102      100775  10435                                                                                                                                                                                                                                                                                                                                                                      @ECHO OFF
 
 REM ----------------------------------------------------------------------
 REM PHP version 5
@@ -50813,7 +51381,7 @@ GOTO END
 :RUN
 "%PHP_PEAR_PHP_BIN%" -C -d output_buffering=1 -d safe_mode=0 -d open_basedir="" -d auto_prepend_file="" -d auto_append_file="" -d variables_order=EGPCS -d register_argc_argv="On" -d include_path="%PHP_PEAR_INSTALL_DIR%" -f "%PHP_PEAR_INSTALL_DIR%\pearcmd.php" -- %1 %2 %3 %4 %5 %6 %7 %8 %9
 :END
- at ECHO ON                                                                                                                                                                                                                                                                                                                                                                                                                                                              PEAR-1.8.0/scripts/peardev.bat                                                                      100777     764     764        11112      100777  11140                                                                                                                                                                                                                                                                                                                                                                      @ECHO OFF
+ at ECHO ON                                                                                                                                                                                                                                                                                                                                                                                                                                                              PEAR-1.9.0/scripts/peardev.bat                                                                      100664     764     764        11112      100664  11127                                                                                                                                                                                                                                                                                                                                                                      @ECHO OFF
 
 REM ----------------------------------------------------------------------
 REM PHP version 5
@@ -50831,7 +51399,7 @@ REM ----------------------------------------------------------------------
 REM  Authors:     Alexander Merz (alexmerz at php.net)
 REM ----------------------------------------------------------------------
 REM
-REM  $Id: peardev.bat,v 1.6 2007/09/03 03:00:17 cellog Exp $
+REM  $Id: peardev.bat,v 1.6 2007-09-03 03:00:17 cellog Exp $
 
 REM change this lines to match the paths of your system
 REM -------------------
@@ -50927,7 +51495,7 @@ GOTO END
 :RUN
 "%PHP_PEAR_PHP_BIN%" -C -d memory_limit="-1" -d safe_mode=0 -d register_argc_argv="On" -d auto_prepend_file="" -d auto_append_file="" -d variables_order=EGPCS -d open_basedir="" -d output_buffering=1 -d include_path="%PHP_PEAR_INSTALL_DIR%" -f "%PHP_PEAR_INSTALL_DIR%\pearcmd.php" -- %1 %2 %3 %4 %5 %6 %7 %8 %9
 :END
- at ECHO ON                                                                                                                                                                                                                                                                                                                                                                                                                                                      PEAR-1.8.0/scripts/pecl.bat                                                                         100777     764     764        11003      100777  10434                                                                                                                                                                                                                                                                                                                                                                      @ECHO OFF
+ at ECHO ON                                                                                                                                                                                                                                                                                                                                                                                                                                                      PEAR-1.9.0/scripts/pecl.bat                                                                         100664     764     764        11003      100664  10423                                                                                                                                                                                                                                                                                                                                                                      @ECHO OFF
 
 REM ----------------------------------------------------------------------
 REM PHP version 5
@@ -51041,7 +51609,7 @@ GOTO END
 :RUN
 "%PHP_PEAR_PHP_BIN%" -C -n -d output_buffering=1 -d safe_mode=0 -d include_path="%PHP_PEAR_INSTALL_DIR%" -d register_argc_argv="On" -d variables_order=EGPCS -f "%PHP_PEAR_INSTALL_DIR%\peclcmd.php" -- %1 %2 %3 %4 %5 %6 %7 %8 %9
 :END
- at ECHO ON                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             PEAR-1.8.0/scripts/pear.sh                                                                          100777     764     764         1362      100777  10273                                                                                                                                                                                                                                                                                                                                                                      #!/bin/sh
+ at ECHO ON                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             PEAR-1.9.0/scripts/pear.sh                                                                          100664     764     764         1362      100664  10262                                                                                                                                                                                                                                                                                                                                                                      #!/bin/sh
 
 # first find which PHP binary to use
 if test "x$PHP_PEAR_PHP_BIN" != "x"; then
@@ -51069,7 +51637,7 @@ else
 fi
 
 exec $PHP -C -q $INCARG -d output_buffering=1 -d variables_order=EGPCS -d open_basedir="" -d safe_mode=0 -d register_argc_argv="On" -d auto_prepend_file="" -d auto_append_file="" $INCDIR/pearcmd.php "$@"
-                                                                                                                                                                                                                                                                              PEAR-1.8.0/scripts/peardev.sh                                                                       100777     764     764         1407      100777  10772                                                                                                                                                                                                                                                                                                                                                                      #!/bin/sh
+                                                                                                                                                                                                                                                                              PEAR-1.9.0/scripts/peardev.sh                                                                       100664     764     764         1407      100664  10761                                                                                                                                                                                                                                                                                                                                                                      #!/bin/sh
 
 # first find which PHP binary to use
 if test "x$PHP_PEAR_PHP_BIN" != "x"; then
@@ -51097,7 +51665,7 @@ else
 fi
 
 exec $PHP -d memory_limit="-1" -C -q $INCARG -d output_buffering=1 -d open_basedir="" -d safe_mode=0 -d register_argc_argv="On" -d auto_prepend_file="" -d variables_order=EGPCS -d auto_append_file="" $INCDIR/pearcmd.php "$@"
-                                                                                                                                                                                                                                                         PEAR-1.8.0/scripts/pecl.sh                                                                          100777     764     764         1263      100777  10267                                                                                                                                                                                                                                                                                                                                                                      #!/bin/sh
+                                                                                                                                                                                                                                                         PEAR-1.9.0/scripts/pecl.sh                                                                          100664     764     764         1263      100664  10256                                                                                                                                                                                                                                                                                                                                                                      #!/bin/sh
 
 # first find which PHP binary to use
 if test "x$PHP_PEAR_PHP_BIN" != "x"; then
@@ -51125,7 +51693,7 @@ else
 fi
 
 exec $PHP -C -n -q $INCARG -d output_buffering=1 -d variables_order=EGPCS -d safe_mode=0 -d register_argc_argv="On" $INCDIR/peclcmd.php "$@"
-                                                                                                                                                                                                                                                                                                                                             PEAR-1.8.0/scripts/pearcmd.php                                                                      100664     764     764        34617      100664  11153                                                                                                                                                                                                                                                                                                                                                                      <?php
+                                                                                                                                                                                                                                                                                                                                             PEAR-1.9.0/scripts/pearcmd.php                                                                      100664     764     764        34076      100664  11153                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR, the PHP Extension and Application Repository
  *
@@ -51139,7 +51707,7 @@ exec $PHP -C -n -q $INCARG -d output_buffering=1 -d variables_order=EGPCS -d saf
  * @author     Tomas V.V.Cox <cox at idecnet.com>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: pearcmd.php,v 1.41 2009/03/04 20:05:56 dufuz Exp $
+ * @version    CVS: $Id: pearcmd.php 286487 2009-07-29 05:57:28Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  */
 
@@ -51187,6 +51755,7 @@ if (!isset($_SERVER['argv']) && !isset($argv) && !isset($HTTP_SERVER_VARS['argv'
     echo 'ERROR: either use the CLI php executable, or set register_argc_argv=On in php.ini';
     exit(1);
 }
+
 $argv = Console_Getopt::readPHPArgv();
 // fix CGI sapi oddity - the -- in pear.bat/pear is not removed
 if (php_sapi_name() != 'cli' && isset($argv[1]) && $argv[1] == '--') {
@@ -51194,12 +51763,8 @@ if (php_sapi_name() != 'cli' && isset($argv[1]) && $argv[1] == '--') {
     $argv = array_values($argv);
 }
 $progname = PEAR_RUNTYPE;
-if (in_array('getopt2', get_class_methods('Console_Getopt'))) {
-    array_shift($argv);
-    $options = Console_Getopt::getopt2($argv, "c:C:d:D:Gh?sSqu:vV");
-} else {
-    $options = Console_Getopt::getopt($argv, "c:C:d:D:Gh?sSqu:vV");
-}
+array_shift($argv);
+$options = Console_Getopt::getopt2($argv, "c:C:d:D:Gh?sSqu:vV");
 if (PEAR::isError($options)) {
     usage($options);
 }
@@ -51372,7 +51937,6 @@ if ($store_user_config) {
 }
 
 $command = (isset($options[1][0])) ? $options[1][0] : null;
-
 if (empty($command) && ($store_user_config || $store_system_config)) {
     exit;
 }
@@ -51388,6 +51952,7 @@ if ($fetype == 'Gtk' || $fetype == 'Gtk2') {
     if ($command == 'help') {
         usage(null, @$options[1][1]);
     }
+
     if (!$config->validConfiguration()) {
         PEAR::raiseError('CRITICAL ERROR: no existing valid configuration files found in files ' .
             "'$pear_user_config' or '$pear_system_config', please copy an existing configuration" .
@@ -51403,15 +51968,13 @@ if ($fetype == 'Gtk' || $fetype == 'Gtk2') {
 
     $short_args = $long_args = null;
     PEAR_Command::getGetoptArgs($command, $short_args, $long_args);
-    if (in_array('getopt2', get_class_methods('Console_Getopt'))) {
-        array_shift($options[1]);
-        $tmp = Console_Getopt::getopt2($options[1], $short_args, $long_args);
-    } else {
-        $tmp = Console_Getopt::getopt($options[1], $short_args, $long_args);
-    }
+    array_shift($options[1]);
+    $tmp = Console_Getopt::getopt2($options[1], $short_args, $long_args);
+
     if (PEAR::isError($tmp)) {
         break;
     }
+
     list($tmpopt, $params) = $tmp;
     $opts = array();
     foreach ($tmpopt as $foo => $tmp2) {
@@ -51419,6 +51982,7 @@ if ($fetype == 'Gtk' || $fetype == 'Gtk2') {
         if ($value === null) {
             $value = true; // options without args
         }
+
         if (strlen($opt) == 1) {
             $cmdoptions = $cmd->getOptions($command);
             foreach ($cmdoptions as $o => $d) {
@@ -51432,10 +51996,12 @@ if ($fetype == 'Gtk' || $fetype == 'Gtk2') {
             }
         }
     }
+
     $ok = $cmd->run($command, $opts, $params);
     if ($ok === false) {
         PEAR::raiseError("unknown command `$command'");
     }
+
     if (PEAR::isError($ok)) {
         PEAR::setErrorHandling(PEAR_ERROR_CALLBACK, array($ui, "displayFatalError"));
         PEAR::raiseError($ok);
@@ -51453,6 +52019,7 @@ function usage($error = null, $helpsubject = null)
     } elseif ($error !== null) {
         fputs($stderr, "$error\n");
     }
+
     if ($helpsubject != null) {
         $put = cmdHelp($helpsubject);
     } else {
@@ -51511,12 +52078,14 @@ function cmdHelp($command)
         if (is_string($help)) {
             return "$progname $command [options] $help\n";
         }
+
         if ($help[1] === null) {
             return "$progname $command $help[0]";
-        } else {
-            return "$progname $command [options] $help[0]\n$help[1]";
         }
+
+        return "$progname $command [options] $help[0]\n$help[1]";
     }
+
     return "Command '$command' is not valid, try '$progname help'";
 }
 
@@ -51568,7 +52137,7 @@ function error_handler($errno, $errmsg, $file, $line, $vars) {
  * mode: php
  * End:
  */
-// vim600:syn=php                                                                                                                 PEAR-1.8.0/scripts/peclcmd.php                                                                      100664     764     764         1640      100664  11115                                                                                                                                                                                                                                                                                                                                                                      <?php
+// vim600:syn=php                                                                                                                                                                                                                                                                                                                                                                                                                                                                  PEAR-1.9.0/scripts/peclcmd.php                                                                      100664     764     764         1636      100664  11123                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR, the PHP Extension and Application Repository
  *
@@ -51582,7 +52151,7 @@ function error_handler($errno, $errmsg, $file, $line, $vars) {
  * @author     Tomas V.V.Cox <cox at idecnet.com>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: peclcmd.php,v 1.2 2009/02/25 00:06:23 dufuz Exp $
+ * @version    CVS: $Id: peclcmd.php 276392 2009-02-25 00:06:23Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  */
 
@@ -51609,7 +52178,7 @@ require_once 'pearcmd.php';
 // vim600:syn=php
 
 ?>
-                                                                                                PEAR-1.8.0/LICENSE                                                                                  100664     764     764         2705      100664   6316                                                                                                                                                                                                                                                                                                                                                                      Copyright (c) 1997-2009,
+                                                                                                  PEAR-1.9.0/LICENSE                                                                                  100664     764     764         2705      100664   6317                                                                                                                                                                                                                                                                                                                                                                      Copyright (c) 1997-2009,
  Stig Bakken <ssb at php.net>,
  Gregory Beaver <cellog at php.net>,
  Helgi Þormar Þorbjörnsson <helgi at php.net>,
@@ -51636,7 +52205,7 @@ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
 CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
 OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
 OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
-                                                           PEAR-1.8.0/INSTALL                                                                                  100777     764     764         3643      100777   6356                                                                                                                                                                                                                                                                                                                                                                      PEAR - The PEAR Installer
+                                                           PEAR-1.9.0/INSTALL                                                                                  100664     764     764         3641      100664   6343                                                                                                                                                                                                                                                                                                                                                                      PEAR - The PEAR Installer
 =========================
 Installing the PEAR Installer.
 
@@ -51688,8 +52257,8 @@ related issues.
 
 Happy PHPing, we hope PEAR will be a great tool for your development work!
 
-$Id: INSTALL,v 1.1 2006/09/22 03:31:36 cellog Exp $                                                                                             PEAR-1.8.0/package.dtd                                                                              100777     764     764         6477      100777   7425                                                                                                                                                                                                                                                                                                                                                                      <!--
-     $Id: package.dtd,v 1.38 2005/11/12 02:23:07 cellog Exp $
+$Id: INSTALL 220345 2006-09-22 03:31:36Z cellog $                                                                                               PEAR-1.9.0/package.dtd                                                                              100664     764     764         6477      100664   7414                                                                                                                                                                                                                                                                                                                                                                      <!--
+     $Id: package.dtd,v 1.38 2005-11-12 02:23:07 cellog Exp $
 
      This is the PEAR package description, version 1.0.
      It should be used with the informal public identifier:
@@ -51791,7 +52360,39 @@ $Id: INSTALL,v 1.1 2006/09/22 03:31:36 cellog Exp $                             
                               to CDATA #REQUIRED>
 
 
-                                                                                                                                                                                                 PEAR-1.8.0/PEAR.php                                                                                 100664     764     764       105707      100664   6617                                                                                                                                                                                                                                                                                                                                                                      <?php
+                                                                                                                                                                                                 PEAR-1.9.0/PEAR5.php                                                                                100664     764     764         2077      100664   6641                                                                                                                                                                                                                                                                                                                                                                      <?php
+/**
+ * This is only meant for PHP 5 to get rid of certain strict warning
+ * that doesn't get hidden since it's in the shutdown function
+ */
+class PEAR5
+{
+    /**
+    * If you have a class that's mostly/entirely static, and you need static
+    * properties, you can use this method to simulate them. Eg. in your method(s)
+    * do this: $myVar = &PEAR5::getStaticProperty('myclass', 'myVar');
+    * You MUST use a reference, or they will not persist!
+    *
+    * @access public
+    * @param  string $class  The calling classname, to prevent clashes
+    * @param  string $var    The variable to retrieve.
+    * @return mixed   A reference to the variable. If not set it will be
+    *                 auto initialised to NULL.
+    */
+    static function &getStaticProperty($class, $var)
+    {
+        static $properties;
+        if (!isset($properties[$class])) {
+            $properties[$class] = array();
+        }
+
+        if (!array_key_exists($var, $properties[$class])) {
+            $properties[$class][$var] = null;
+        }
+
+        return $properties[$class][$var];
+    }
+}                                                                                                                                                                                                                                                                                                                                                                                                                                                                 PEAR-1.9.0/PEAR.php                                                                                 100664     764     764       103544      100664   6615                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * PEAR, the PHP Extension and Application Repository
  *
@@ -51807,7 +52408,7 @@ $Id: INSTALL,v 1.1 2006/09/22 03:31:36 cellog Exp $                             
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: PEAR.php,v 1.111 2009/04/08 23:32:04 dufuz Exp $
+ * @version    CVS: $Id: PEAR.php 286670 2009-08-02 14:16:06Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -51871,7 +52472,7 @@ $GLOBALS['_PEAR_error_handler_stack']    = array();
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2006 The PHP Group
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @see        PEAR_Error
  * @since      Class available since PHP 4.0.2
@@ -52556,38 +53157,7 @@ class PEAR
 }
 
 if (PEAR_ZE2) {
-    /**
-     * This is only meant for PHP 5 to get rid of certain strict warning
-     * that doesn't get hidden since it's in the shutdown function
-     */
-    class PEAR5
-    {
-        /**
-        * If you have a class that's mostly/entirely static, and you need static
-        * properties, you can use this method to simulate them. Eg. in your method(s)
-        * do this: $myVar = &PEAR5::getStaticProperty('myclass', 'myVar');
-        * You MUST use a reference, or they will not persist!
-        *
-        * @access public
-        * @param  string $class  The calling classname, to prevent clashes
-        * @param  string $var    The variable to retrieve.
-        * @return mixed   A reference to the variable. If not set it will be
-        *                 auto initialised to NULL.
-        */
-        static function &getStaticProperty($class, $var)
-        {
-            static $properties;
-            if (!isset($properties[$class])) {
-                $properties[$class] = array();
-            }
-
-            if (!array_key_exists($var, $properties[$class])) {
-                $properties[$class][$var] = null;
-            }
-
-            return $properties[$class][$var];
-        }
-    }
+    include_once 'PEAR5.php';
 }
 
 // {{{ _PEAR_call_destructors()
@@ -52627,7 +53197,7 @@ function _PEAR_call_destructors()
     }
 
     // Now call the shutdown functions
-    if (is_array($GLOBALS['_PEAR_shutdown_funcs']) AND !empty($GLOBALS['_PEAR_shutdown_funcs'])) {
+    if (isset($GLOBALS['_PEAR_shutdown_funcs']) AND is_array($GLOBALS['_PEAR_shutdown_funcs']) AND !empty($GLOBALS['_PEAR_shutdown_funcs'])) {
         foreach ($GLOBALS['_PEAR_shutdown_funcs'] as $value) {
             call_user_func_array($value[0], $value[1]);
         }
@@ -52647,7 +53217,7 @@ function _PEAR_call_destructors()
  * @author     Gregory Beaver <cellog at php.net>
  * @copyright  1997-2006 The PHP Group
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/manual/en/core.pear.pear-error.php
  * @see        PEAR::raiseError(), PEAR::throwError()
  * @since      Class available since PHP 4.0.2
@@ -52710,6 +53280,7 @@ class PEAR_Error
                 unset($this->backtrace[0]['object']);
             }
         }
+
         if ($mode & PEAR_ERROR_CALLBACK) {
             $this->level = E_USER_NOTICE;
             $this->callback = $options;
@@ -52717,20 +53288,25 @@ class PEAR_Error
             if ($options === null) {
                 $options = E_USER_NOTICE;
             }
+
             $this->level = $options;
             $this->callback = null;
         }
+
         if ($this->mode & PEAR_ERROR_PRINT) {
             if (is_null($options) || is_int($options)) {
                 $format = "%s";
             } else {
                 $format = $options;
             }
+
             printf($format, $this->getMessage());
         }
+
         if ($this->mode & PEAR_ERROR_TRIGGER) {
             trigger_error($this->getMessage(), $this->level);
         }
+
         if ($this->mode & PEAR_ERROR_DIE) {
             $msg = $this->getMessage();
             if (is_null($options) || is_int($options)) {
@@ -52743,11 +53319,13 @@ class PEAR_Error
             }
             die(sprintf($format, $msg));
         }
+
         if ($this->mode & PEAR_ERROR_CALLBACK) {
             if (is_callable($this->callback)) {
                 call_user_func($this->callback, $this);
             }
         }
+
         if ($this->mode & PEAR_ERROR_EXCEPTION) {
             trigger_error("PEAR_ERROR_EXCEPTION is obsolete, use class PEAR_Exception for exceptions", E_USER_WARNING);
             eval('$e = new Exception($this->message, $this->code);throw($e);');
@@ -52950,7 +53528,8 @@ class PEAR_Error
  * tab-width: 4
  * c-basic-offset: 4
  * End:
- */                                                         PEAR-1.8.0/README                                                                                   100777     764     764         2251      100777   6177                                                                                                                                                                                                                                                                                                                                                                      PEAR - The PEAR Installer
+ */
+                                                                                                                                                            PEAR-1.9.0/README                                                                                   100664     764     764         2246      100664   6172                                                                                                                                                                                                                                                                                                                                                                      PEAR - The PEAR Installer
 =========================
 
 What is the PEAR Installer?  What is PEAR?
@@ -52981,7 +53560,7 @@ prior to use.
 
 Happy PHPing, we hope PEAR will be a great tool for your development work!
 
-$Id: README,v 1.11 2006/09/22 03:31:36 cellog Exp $                                                                                                                                                                                                                                                                                                                                                       PEAR-1.8.0/System.php                                                                               100664     764     764        47002      100664   7325                                                                                                                                                                                                                                                                                                                                                                      <?php
+$Id: README 220345 2006-09-22 03:31:36Z cellog $                                                                                                                                                                                                                                                                                                                                                          PEAR-1.9.0/System.php                                                                               100664     764     764        46777      100664   7350                                                                                                                                                                                                                                                                                                                                                                      <?php
 /**
  * File/Directory manipulation
  *
@@ -52992,7 +53571,7 @@ $Id: README,v 1.11 2006/09/22 03:31:36 cellog Exp $                             
  * @author     Tomas V.V.Cox <cox at idecnet.com>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: System.php,v 1.66 2009/02/24 23:52:56 dufuz Exp $
+ * @version    CVS: $Id: System.php 276386 2009-02-24 23:52:56Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -53034,7 +53613,7 @@ $GLOBALS['_System_temp_files'] = array();
 * @author     Tomas V.V. Cox <cox at idecnet.com>
 * @copyright  1997-2006 The PHP Group
 * @license    http://opensource.org/licenses/bsd-license.php New BSD License
-* @version    Release: 1.8.0
+* @version    Release: 1.9.0
 * @link       http://pear.php.net/package/PEAR
 * @since      Class available since Release 0.1
 * @static
@@ -53601,7 +54180,7 @@ class System
         }
         return $files;
     }
-}                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              PEAR-1.8.0/template.spec                                                                            100777     764     764         3725      100777  10015                                                                                                                                                                                                                                                                                                                                                                      Summary: PEAR: @summary@
+} PEAR-1.9.0/template.spec                                                                            100664     764     764         3725      100664  10004                                                                                                                                                                                                                                                                                                                                                                      Summary: PEAR: @summary@
 Name: @rpm_package@
 Version: @version@
 Release: 1
@@ -53673,9 +54252,9 @@ cp -p package at package2xml@.xml %{buildroot}@rpm_xml_dir@/@package at .xml
     %defattr(-,root,root)
     %doc @doc_files@
     /
-                                           package.xml                                                                                         100664     764     764        70773      100664   6267                                                                                                                                                                                                                                                                                                                                                                      <?xml version="1.0" encoding="UTF-8" ?>
+                                           package.xml                                                                                         100664     764     764        76000      100664   6254                                                                                                                                                                                                                                                                                                                                                                      <?xml version="1.0" encoding="UTF-8" ?>
 <!DOCTYPE package SYSTEM "http://pear.php.net/dtd/package-1.0">
-<package version="1.0" packagerversion="1.8.0">
+<package version="1.0" packagerversion="1.9.0RC4">
  <name>PEAR</name>
  <summary>PEAR Base System</summary>
  <description>The PEAR package contains:
@@ -53761,14 +54340,11 @@ cp -p package at package2xml@.xml %{buildroot}@rpm_xml_dir@/@package at .xml
   </maintainer>
   </maintainers>
  <release>
-  <version>1.8.0</version>
-  <date>2009-04-10</date>
+  <version>1.9.0</version>
+  <date>2009-09-03</date>
   <license>New BSD License</license>
   <state>stable</state>
-  <notes>* Fix Bug #14792: Bad md5sum for files with replaced content [dufuz]
-* Fix Bug #16057:-r is limited to 4 directories in depth [dufuz]
-* Fix Bug #16077: PEAR5::getStaticProperty does not return a reference to the property [dufuz]
-Remove custom XML_Util class in favor of using upstream XML_Util package as dependency
+  <notes>* Fix  Bug #16547: The phar for PEAR installer uses ereg() which is deprecated [dufuz]
   </notes>
   <deps>
    <dep type="php" rel="ge" version="4.4.0"/>
@@ -54062,6 +54638,7 @@ Remove custom XML_Util class in favor of using upstream XML_Util package as depe
    <file role="php" baseinstalldir="/" name="PEAR.php">
     <replace from="@package_version@" to="version" type="package-info"/>
    </file>
+   <file role="php" baseinstalldir="/" name="PEAR5.php"/>
    <file role="doc" baseinstalldir="/" name="README"/>
    <file role="php" baseinstalldir="/" name="System.php">
     <replace from="@package_version@" to="version" type="package-info"/>
@@ -54232,9 +54809,73 @@ Alpha1 Release Notes:
   Move codebase from the PHP License to New BSD 2 clause license
     </notes>
    </release>
+   <release>
+    <version>1.8.1</version>
+    <date>2009-04-15</date>
+    <license>New BSD License</license>
+    <state>stable</state>
+    <notes>* Fix Bug #16099 	PEAR crash on PHP4 (parse error) [dufuz]
+    </notes>
+   </release>
+   <release>
+    <version>1.9.0RC1</version>
+    <date>2009-08-18</date>
+    <license>New BSD License</license>
+    <state>beta</state>
+    <notes>* Implement Request #16213: add alias to list-channels output [dufuz]
+* Implement Request #16378: pear svntag [dufuz]
+* Implement Request #16386: PEAR_Config::remove() does not support specifying a channel [timj]
+* Implement Request #16396: package-dependencies should allow package names [dufuz]
+* Fix Bug #11181: pear requests channel.xml from main server instead from mirror [dufuz]
+* Fix Bug #14493: pear install --offline doesn&apos;t print out errors [dufuz]
+* Fix Bug #11348: pear package-dependencies isn&apos;t well explained [dufuz]
+* Fix Bug #16108: PEAR_PackageFile_Generator_v2 PHP4 parse error when running upgrade-all [dufuz]
+* Fix Bug #16113: Installing certain packages fails due incorrect encoding handling [dufuz]
+* Fix Bug #16122: PEAR RunTest failed to run as expected [dufuz]
+* Fix Bug #16366: compiling 5.2.10 leads to non-functioning pear [dufuz]
+* Fix Bug #16387: channel-logout does not support logging out from a non-default channel [timj]
+* Fix Bug #16444: Setting preferred mirror fails [dufuz]
+* Fix the shutdown functions where a index might not exist and thus raise a notice [derick]
+    </notes>
+   </release>
+   <release>
+    <version>1.9.0RC2</version>
+    <date>2009-08-20</date>
+    <license>New BSD License</license>
+    <state>beta</state>
+    <notes>* REST 1.4 file was occasionally being included but REST 1.4 is not intended for this release cycle [dufuz]
+    </notes>
+   </release>
+   <release>
+    <version>1.9.0RC3</version>
+    <date>2009-08-21</date>
+    <license>New BSD License</license>
+    <state>beta</state>
+    <notes>* Improved svntag support to handle packages like PEAR it self [dufuz]
+    </notes>
+   </release>
+   <release>
+    <version>1.9.0RC4</version>
+    <date>2009-08-23</date>
+    <license>New BSD License</license>
+    <state>beta</state>
+    <notes>* Fixed a problem where the original channel could not be set as a preferred_mirror again [dufuz]
+* Make sure channel aliases can&apos;t be made to start with - [dufuz]
+* Output issues with pear search [dufuz]
+* Fixed couple of stray notices [dufuz]
+    </notes>
+   </release>
+   <release>
+    <version>1.9.0</version>
+    <date>2009-09-03</date>
+    <license>New BSD License</license>
+    <state>stable</state>
+    <notes>* Fix  Bug #16547: The phar for PEAR installer uses ereg() which is deprecated [dufuz]
+    </notes>
+   </release>
  </changelog>
 </package>
-                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                     <?php
+                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <?php
 /**
  * PEAR, the PHP Extension and Application Repository
  *
@@ -54250,7 +54891,7 @@ Alpha1 Release Notes:
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: PEAR.php,v 1.111 2009/04/08 23:32:04 dufuz Exp $
+ * @version    CVS: $Id: PEAR.php 286670 2009-08-02 14:16:06Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -54314,7 +54955,7 @@ $GLOBALS['_PEAR_error_handler_stack']    = array();
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2006 The PHP Group
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @see        PEAR_Error
  * @since      Class available since PHP 4.0.2
@@ -54999,38 +55640,7 @@ class PEAR
 }
 
 if (PEAR_ZE2) {
-    /**
-     * This is only meant for PHP 5 to get rid of certain strict warning
-     * that doesn't get hidden since it's in the shutdown function
-     */
-    class PEAR5
-    {
-        /**
-        * If you have a class that's mostly/entirely static, and you need static
-        * properties, you can use this method to simulate them. Eg. in your method(s)
-        * do this: $myVar = &PEAR5::getStaticProperty('myclass', 'myVar');
-        * You MUST use a reference, or they will not persist!
-        *
-        * @access public
-        * @param  string $class  The calling classname, to prevent clashes
-        * @param  string $var    The variable to retrieve.
-        * @return mixed   A reference to the variable. If not set it will be
-        *                 auto initialised to NULL.
-        */
-        static function &getStaticProperty($class, $var)
-        {
-            static $properties;
-            if (!isset($properties[$class])) {
-                $properties[$class] = array();
-            }
-
-            if (!array_key_exists($var, $properties[$class])) {
-                $properties[$class][$var] = null;
-            }
-
-            return $properties[$class][$var];
-        }
-    }
+    include_once 'phar://install-pear-nozlib.phar/' . 'PEAR5.php';
 }
 
 // {{{ _PEAR_call_destructors()
@@ -55070,7 +55680,7 @@ function _PEAR_call_destructors()
     }
 
     // Now call the shutdown functions
-    if (is_array($GLOBALS['_PEAR_shutdown_funcs']) AND !empty($GLOBALS['_PEAR_shutdown_funcs'])) {
+    if (isset($GLOBALS['_PEAR_shutdown_funcs']) AND is_array($GLOBALS['_PEAR_shutdown_funcs']) AND !empty($GLOBALS['_PEAR_shutdown_funcs'])) {
         foreach ($GLOBALS['_PEAR_shutdown_funcs'] as $value) {
             call_user_func_array($value[0], $value[1]);
         }
@@ -55090,7 +55700,7 @@ function _PEAR_call_destructors()
  * @author     Gregory Beaver <cellog at php.net>
  * @copyright  1997-2006 The PHP Group
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/manual/en/core.pear.pear-error.php
  * @see        PEAR::raiseError(), PEAR::throwError()
  * @since      Class available since PHP 4.0.2
@@ -55153,6 +55763,7 @@ class PEAR_Error
                 unset($this->backtrace[0]['object']);
             }
         }
+
         if ($mode & PEAR_ERROR_CALLBACK) {
             $this->level = E_USER_NOTICE;
             $this->callback = $options;
@@ -55160,20 +55771,25 @@ class PEAR_Error
             if ($options === null) {
                 $options = E_USER_NOTICE;
             }
+
             $this->level = $options;
             $this->callback = null;
         }
+
         if ($this->mode & PEAR_ERROR_PRINT) {
             if (is_null($options) || is_int($options)) {
                 $format = "%s";
             } else {
                 $format = $options;
             }
+
             printf($format, $this->getMessage());
         }
+
         if ($this->mode & PEAR_ERROR_TRIGGER) {
             trigger_error($this->getMessage(), $this->level);
         }
+
         if ($this->mode & PEAR_ERROR_DIE) {
             $msg = $this->getMessage();
             if (is_null($options) || is_int($options)) {
@@ -55186,11 +55802,13 @@ class PEAR_Error
             }
             die(sprintf($format, $msg));
         }
+
         if ($this->mode & PEAR_ERROR_CALLBACK) {
             if (is_callable($this->callback)) {
                 call_user_func($this->callback, $this);
             }
         }
+
         if ($this->mode & PEAR_ERROR_EXCEPTION) {
             trigger_error("PEAR_ERROR_EXCEPTION is obsolete, use class PEAR_Exception for exceptions", E_USER_WARNING);
             eval('$e = new Exception($this->message, $this->code);throw($e);');
@@ -55393,7 +56011,8 @@ class PEAR_Error
  * tab-width: 4
  * c-basic-offset: 4
  * End:
- */<?php
+ */
+<?php
 /**
  * PEAR_ChannelFile, the channel handling class
  *
@@ -55404,7 +56023,7 @@ class PEAR_Error
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: ChannelFile.php,v 1.84 2009/03/09 01:03:51 dufuz Exp $
+ * @version    CVS: $Id: ChannelFile.php 286951 2009-08-09 14:41:22Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -55541,7 +56160,7 @@ $GLOBALS['_PEAR_CHANNELS_MIRROR_TYPES'] =  array('server');
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -55893,12 +56512,15 @@ class PEAR_ChannelFile
     function _makeRestXml($info, $indent)
     {
         $ret = $indent . "<rest>\n";
-        if (!isset($info['baseurl'][0])) {
+        if (isset($info['baseurl']) && !isset($info['baseurl'][0])) {
             $info['baseurl'] = array($info['baseurl']);
         }
-        foreach ($info['baseurl'] as $url) {
-            $ret .= "$indent <baseurl type=\"" . $url['attribs']['type'] . "\"";
-            $ret .= ">" . $url['_content'] . "</baseurl>\n";
+
+        if (isset($info['baseurl'])) {
+            foreach ($info['baseurl'] as $url) {
+                $ret .= "$indent <baseurl type=\"" . $url['attribs']['type'] . "\"";
+                $ret .= ">" . $url['_content'] . "</baseurl>\n";
+            }
         }
         $ret .= $indent . "</rest>\n";
         return $ret;
@@ -56082,15 +56704,17 @@ class PEAR_ChannelFile
         if (!isset($functions[0])) {
             $functions = array($functions);
         }
+
         foreach ($functions as $function) {
             if (!isset($function['_content']) || empty($function['_content'])) {
                 $this->_validateError(PEAR_CHANNELFILE_ERROR_NO_FUNCTIONNAME,
                     array('parent' => $parent, 'protocol' => $protocol));
             }
+
             if ($protocol == 'rest') {
                 if (!isset($function['attribs']['type']) ||
                       empty($function['attribs']['type'])) {
-                    $this->_validateError(PEAR_CHANNELFILE_ERROR_NO_BASEURLTYPE,
+                    $this->_validateError(PEAR_CHANNELFILE_ERROR_NOBASEURLTYPE,
                         array('parent' => $parent, 'protocol' => $protocol));
                 }
             } else {
@@ -56414,6 +57038,14 @@ class PEAR_ChannelFile
         switch ($version) {
             case '1.0' :
                 $this->resetREST($mirror);
+
+                if (!isset($this->_channelInfo['servers'])) {
+                    $this->_channelInfo['servers'] = array('primary' =>
+                        array('rest' => array()));
+                } elseif (!isset($this->_channelInfo['servers']['primary'])) {
+                    $this->_channelInfo['servers']['primary'] = array('rest' => array());
+                }
+
                 return true;
             break;
             default :
@@ -56949,7 +57581,7 @@ class PEAR_ChannelFile
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Parser.php,v 1.7 2009/02/24 23:39:07 dufuz Exp $
+ * @version    CVS: $Id: Parser.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -56966,7 +57598,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -57017,7 +57649,7 @@ class PEAR_ChannelFile_Parser extends PEAR_XMLParser
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Command.php,v 1.41 2009/02/24 23:38:22 dufuz Exp $
+ * @version    CVS: $Id: Command.php 286494 2009-07-29 06:57:11Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -57101,7 +57733,7 @@ $GLOBALS['_PEAR_Command_objects'] = array();
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -57248,27 +57880,31 @@ class PEAR_Command
         if (!$merge) {
             $GLOBALS['_PEAR_Command_commandlist'] = array();
         }
-        while ($entry = readdir($dp)) {
-            if ($entry{0} == '.' || substr($entry, -4) != '.xml') {
+
+        while ($file = readdir($dp)) {
+            if ($file{0} == '.' || substr($file, -4) != '.xml') {
                 continue;
             }
-            $class = "PEAR_Command_".substr($entry, 0, -4);
-            $file = "$dir/$entry";
-            $parser->parse(file_get_contents($file));
-            $implements = $parser->getData();
+
+            $f = substr($file, 0, -4);
+            $class = "PEAR_Command_" . $f;
             // List of commands
             if (empty($GLOBALS['_PEAR_Command_objects'][$class])) {
-                $GLOBALS['_PEAR_Command_objects'][$class] = "$dir/" . substr($entry, 0, -4) .
-                    '.php';
+                $GLOBALS['_PEAR_Command_objects'][$class] = "$dir/" . $f . '.php';
             }
+
+            $parser->parse(file_get_contents("$dir/$file"));
+            $implements = $parser->getData();
             foreach ($implements as $command => $desc) {
                 if ($command == 'attribs') {
                     continue;
                 }
+
                 if (isset($GLOBALS['_PEAR_Command_commandlist'][$command])) {
                     return PEAR::raiseError('Command "' . $command . '" already registered in ' .
                         'class "' . $GLOBALS['_PEAR_Command_commandlist'][$command] . '"');
                 }
+
                 $GLOBALS['_PEAR_Command_commandlist'][$command] = $class;
                 $GLOBALS['_PEAR_Command_commanddesc'][$command] = $desc['summary'];
                 if (isset($desc['shortcut'])) {
@@ -57280,6 +57916,7 @@ class PEAR_Command
                     }
                     $GLOBALS['_PEAR_Command_shortcuts'][$shortcut] = $command;
                 }
+
                 if (isset($desc['options']) && $desc['options']) {
                     foreach ($desc['options'] as $oname => $option) {
                         if (isset($option['shortopt']) && strlen($option['shortopt']) > 1) {
@@ -57292,6 +57929,7 @@ class PEAR_Command
                 }
             }
         }
+
         ksort($GLOBALS['_PEAR_Command_shortcuts']);
         ksort($GLOBALS['_PEAR_Command_commandlist']);
         @closedir($dp);
@@ -57424,7 +58062,7 @@ class PEAR_Command
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Common.php,v 1.39 2009/02/24 23:39:29 dufuz Exp $
+ * @version    CVS: $Id: Common.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -57443,7 +58081,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -57696,7 +58334,7 @@ class PEAR_Command_Common extends PEAR
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Install.php,v 1.153 2009/03/08 04:01:11 dufuz Exp $
+ * @version    CVS: $Id: Install.php 287477 2009-08-19 14:19:43Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -57716,7 +58354,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Command/Common.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -58249,8 +58887,7 @@ Run post-installation scripts in package <package>, if any exist.
             }
         }
 
-        $abstractpackages = array();
-        $otherpackages    = array();
+        $abstractpackages = $otherpackages = array();
         // parse params
         PEAR::staticPushErrorHandling(PEAR_ERROR_RETURN);
 
@@ -58344,7 +58981,7 @@ Run post-installation scripts in package <package>, if any exist.
         }
 
         $this->downloader = &$this->getDownloader($this->ui, $options, $this->config);
-        $errors = $downloaded = $binaries   = array();
+        $errors = $downloaded = $binaries = array();
         $downloaded = &$this->downloader->download($packages);
         if (PEAR::isError($downloaded)) {
             return $this->raiseError($downloaded);
@@ -58389,8 +59026,7 @@ Run post-installation scripts in package <package>, if any exist.
             return true;
         }
 
-        $extrainfo = array();
-        $binaries  = array();
+        $binaries = $extrainfo = array();
         foreach ($downloaded as $param) {
             PEAR::staticPushErrorHandling(PEAR_ERROR_RETURN);
             $info = $this->installer->install($param, $options);
@@ -58889,10 +59525,14 @@ Run post-installation scripts in package <package>, if any exist.
                     return $this->raiseError($chan);
                 }
 
+                $base2 = false;
                 $preferred_mirror = $this->config->get('preferred_mirror', null, $channel);
                 if ($chan->supportsREST($preferred_mirror) &&
-                      $base = $chan->getBaseURL('REST1.0', $preferred_mirror))
-                {
+                    (
+                       //($base2 = $chan->getBaseURL('REST1.4', $preferred_mirror)) ||
+                       ($base  = $chan->getBaseURL('REST1.0', $preferred_mirror))
+                    )
+                ) {
                     $dorest = true;
                 }
 
@@ -58904,10 +59544,15 @@ Run post-installation scripts in package <package>, if any exist.
                 }
 
                 if ($dorest) {
-                    $rest = &$this->config->getREST('1.0', array());
-                    $installed = array_flip($reg->listPackages($channel));
+                    if ($base2) {
+                        $rest = &$this->config->getREST('1.4', array());
+                        $base = $base2;
+                    } else {
+                        $rest = &$this->config->getREST('1.0', array());
+                    }
 
-                    $latest = $rest->listLatestUpgrades($base, $state, $installed, $channel, $reg);
+                    $installed = array_flip($reg->listPackages($channel));
+                    $latest    = $rest->listLatestUpgrades($base, $state, $installed, $channel, $reg);
                 }
 
                 PEAR::staticPopErrorHandling();
@@ -59174,7 +59819,7 @@ more stable.
     <arg>DIR</arg>
    </installroot>
    <ignore-errors>
-    <shortopt>f</shortopt>
+    <shortopt></shortopt>
     <doc>force install even if there were errors</doc>
    </ignore-errors>
    <offline>
@@ -59199,7 +59844,7 @@ channel not in your default channel ({config default_channel})
     <arg>DIR</arg>
    </destination>
    <force>
-    <shortopt></shortopt>
+    <shortopt>f</shortopt>
     <doc>Force the unpacking even if there were errors in the package</doc>
    </force>
   </options>
@@ -59230,7 +59875,7 @@ Run post-installation scripts in package &lt;package&gt;, if any exist.
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Common.php,v 1.168 2009/03/27 19:35:47 dufuz Exp $
+ * @version    CVS: $Id: Common.php 282969 2009-06-28 23:09:27Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1.0
  * @deprecated File deprecated since Release 1.4.0a1
@@ -59337,7 +59982,7 @@ $GLOBALS['_PEAR_Common_script_phases'] = array('pre-install', 'post-install', 'p
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  * @deprecated This class will disappear, and its components will be spread
@@ -59678,6 +60323,22 @@ class PEAR_Common extends PEAR
         return false;
     }
 
+    function _postProcessChecks($pf)
+    {
+        if (!PEAR::isError($pf)) {
+            return $this->_postProcessValidPackagexml($pf);
+        }
+
+        $errs = $pf->getUserinfo();
+        if (is_array($errs)) {
+            foreach ($errs as $error) {
+                $e = $this->raiseError($error['message'], $error['code'], null, null, $error);
+            }
+        }
+
+        return $pf;
+    }
+
     /**
      * Returns information about a package file.  Expects the name of
      * a gzipped tar file as input.
@@ -59694,18 +60355,7 @@ class PEAR_Common extends PEAR
     {
         $packagefile = &new PEAR_PackageFile($this->config);
         $pf = &$packagefile->fromTgzFile($file, PEAR_VALIDATE_NORMAL);
-        if (PEAR::isError($pf)) {
-            $errs = $pf->getUserinfo();
-            if (is_array($errs)) {
-                foreach ($errs as $error) {
-                    $e = $this->raiseError($error['message'], $error['code'], null, null, $error);
-                }
-            }
-
-            return $pf;
-        }
-
-        return $this->_postProcessValidPackagexml($pf);
+        return $this->_postProcessChecks($pf);
     }
 
     /**
@@ -59724,18 +60374,7 @@ class PEAR_Common extends PEAR
     {
         $packagefile = &new PEAR_PackageFile($this->config);
         $pf = &$packagefile->fromPackageFile($descfile, PEAR_VALIDATE_NORMAL);
-        if (PEAR::isError($pf)) {
-            $errs = $pf->getUserinfo();
-            if (is_array($errs)) {
-                foreach ($errs as $error) {
-                    $e = $this->raiseError($error['message'], $error['code'], null, null, $error);
-                }
-            }
-
-            return $pf;
-        }
-
-        return $this->_postProcessValidPackagexml($pf);
+        return $this->_postProcessChecks($pf);
     }
 
     /**
@@ -59754,18 +60393,7 @@ class PEAR_Common extends PEAR
     {
         $packagefile = &new PEAR_PackageFile($this->config);
         $pf = &$packagefile->fromXmlString($data, PEAR_VALIDATE_NORMAL, false);
-        if (PEAR::isError($pf)) {
-            $errs = $pf->getUserinfo();
-            if (is_array($errs)) {
-                foreach ($errs as $error) {
-                    $e = $this->raiseError($error['message'], $error['code'], null, null, $error);
-                }
-            }
-
-            return $pf;
-        }
-
-        return $this->_postProcessValidPackagexml($pf);
+        return $this->_postProcessChecks($pf);
     }
 
     /**
@@ -59783,23 +60411,11 @@ class PEAR_Common extends PEAR
         // changelog is not converted to old format.
         $arr = $pf->toArray(true);
         $arr = array_merge($arr, $arr['old']);
-        unset($arr['old']);
-        unset($arr['xsdversion']);
-        unset($arr['contents']);
-        unset($arr['compatible']);
-        unset($arr['channel']);
-        unset($arr['uri']);
-        unset($arr['dependencies']);
-        unset($arr['phprelease']);
-        unset($arr['extsrcrelease']);
-        unset($arr['zendextsrcrelease']);
-        unset($arr['extbinrelease']);
-        unset($arr['zendextbinrelease']);
-        unset($arr['bundle']);
-        unset($arr['lead']);
-        unset($arr['developer']);
-        unset($arr['helper']);
-        unset($arr['contributor']);
+        unset($arr['old'], $arr['xsdversion'], $arr['contents'], $arr['compatible'],
+              $arr['channel'], $arr['uri'], $arr['dependencies'], $arr['phprelease'],
+              $arr['extsrcrelease'], $arr['zendextsrcrelease'], $arr['extbinrelease'],
+              $arr['zendextbinrelease'], $arr['bundle'], $arr['lead'], $arr['developer'],
+              $arr['helper'], $arr['contributor']);
         $arr['filelist'] = $pf->getFilelist();
         $this->pkginfo = $arr;
         return $arr;
@@ -60094,7 +60710,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/PackageFile.php';<?php
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Config.php,v 1.157 2009/02/25 00:23:26 dufuz Exp $
+ * @version    CVS: $Id: Config.php 286480 2009-07-29 02:50:02Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -60330,7 +60946,7 @@ if (getenv('PHP_PEAR_SIG_KEYDIR')) {
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -61915,13 +62531,17 @@ class PEAR_Config extends PEAR
      *
      * @param string config key
      * @param string (optional) config layer
+     * @param string (optional) channel (defaults to default channel)
      * @return bool TRUE on success, FALSE on failure
      *
      * @access public
      */
-    function remove($key, $layer = 'user')
+    function remove($key, $layer = 'user', $channel = null)
     {
-        $channel = $this->getDefaultChannel();
+        if ($channel === null) {
+            $channel = $this->getDefaultChannel();
+        }
+
         if ($channel !== 'pear.php.net') {
             if (isset($this->configuration[$layer]['__channels'][$channel][$key])) {
                 unset($this->configuration[$layer]['__channels'][$channel][$key]);
@@ -62186,7 +62806,7 @@ class PEAR_Config extends PEAR
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Dependency2.php,v 1.59 2009/02/24 23:38:22 dufuz Exp $
+ * @version    CVS: $Id: Dependency2.php 286494 2009-07-29 06:57:11Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -62208,7 +62828,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Validate.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -62523,7 +63143,8 @@ class PEAR_Dependency2
         }
 
         if (!isset($dep['min']) && !isset($dep['max']) &&
-              !isset($dep['recommended']) && !isset($dep['exclude'])) {
+            !isset($dep['recommended']) && !isset($dep['exclude'])
+        ) {
             if ($loaded) {
                 if (isset($dep['conflicts'])) {
                     if (!isset($this->_options['nodeps']) && !isset($this->_options['force'])) {
@@ -62536,24 +63157,24 @@ class PEAR_Dependency2
                 }
 
                 return true;
-            } else {
-                if (isset($dep['conflicts'])) {
-                    return true;
-                }
+            }
 
-                if ($required) {
-                    if (!isset($this->_options['nodeps']) && !isset($this->_options['force'])) {
-                        return $this->raiseError('%s requires PHP extension "' .
-                            $dep['name'] . '"' . $extra);
-                    }
+            if (isset($dep['conflicts'])) {
+                return true;
+            }
 
-                    return $this->warning('warning: %s requires PHP extension "' .
+            if ($required) {
+                if (!isset($this->_options['nodeps']) && !isset($this->_options['force'])) {
+                    return $this->raiseError('%s requires PHP extension "' .
                         $dep['name'] . '"' . $extra);
                 }
 
-                return $this->warning('%s can optionally use PHP extension "' .
+                return $this->warning('warning: %s requires PHP extension "' .
                     $dep['name'] . '"' . $extra);
             }
+
+            return $this->warning('%s can optionally use PHP extension "' .
+                $dep['name'] . '"' . $extra);
         }
 
         if (!$loaded) {
@@ -62717,7 +63338,7 @@ class PEAR_Dependency2
      */
     function getPEARVersion()
     {
-        return '1.8.0';
+        return '1.9.0';
     }
 
     function validatePearinstallerDependency($dep)
@@ -63543,7 +64164,7 @@ class PEAR_Dependency2
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: DependencyDB.php,v 1.44 2009/03/21 15:15:26 dufuz Exp $
+ * @version    CVS: $Id: DependencyDB.php 286686 2009-08-02 17:38:57Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -63563,7 +64184,7 @@ $GLOBALS['_PEAR_DEPENDENCYDB_INSTANCE'] = array();
  * @author     Tomas V.V.Cox <cox at idec.net.com>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -63697,18 +64318,19 @@ class PEAR_DependencyDB
     {
         if (!is_file($this->_depdb)) {
             $this->rebuildDB();
-        } else {
-            $depdb = $this->_getDepDB();
-            // Datatype format has been changed, rebuild the Deps DB
-            if ($depdb['_version'] < $this->_version) {
-                $this->rebuildDB();
-            }
+            return;
+        }
 
-            if ($depdb['_version']{0} > $this->_version{0}) {
-                return PEAR::raiseError('Dependency database is version ' .
-                    $depdb['_version'] . ', and we are version ' .
-                    $this->_version . ', cannot continue');
-            }
+        $depdb = $this->_getDepDB();
+        // Datatype format has been changed, rebuild the Deps DB
+        if ($depdb['_version'] < $this->_version) {
+            $this->rebuildDB();
+        }
+
+        if ($depdb['_version']{0} > $this->_version{0}) {
+            return PEAR::raiseError('Dependency database is version ' .
+                $depdb['_version'] . ', and we are version ' .
+                $this->_version . ', cannot continue');
         }
     }
 
@@ -63761,9 +64383,10 @@ class PEAR_DependencyDB
         foreach ($depend as $info) {
             $temp = $this->getDependencies($info);
             foreach ($temp as $dep) {
-                if (isset($dep['dep'], $dep['dep']['channel'], $dep['dep']['name']) &&
-                      strtolower($dep['dep']['channel']) == $channel &&
-                      strtolower($dep['dep']['name']) == $package
+                if (
+                    isset($dep['dep'], $dep['dep']['channel'], $dep['dep']['name']) &&
+                    strtolower($dep['dep']['channel']) == $channel &&
+                    strtolower($dep['dep']['name']) == $package
                 ) {
                     if (!isset($dependencies[$info['channel']])) {
                         $dependencies[$info['channel']] = array();
@@ -64274,13 +64897,6 @@ class PEAR_DependencyDB
                     break;
                 }
             }
-
-            if (!$found) {
-                $data['packages'][$depchannel][$dep['name']][] = array(
-                    'channel' => $channel,
-                    'package' => $package
-                );
-            }
         } else {
             if (!isset($data['packages'])) {
                 $data['packages'] = array();
@@ -64294,6 +64910,10 @@ class PEAR_DependencyDB
                 $data['packages'][$depchannel][$dep['name']] = array();
             }
 
+            $found = false;
+        }
+
+        if (!$found) {
             $data['packages'][$depchannel][$dep['name']][] = array(
                 'channel' => $channel,
                 'package' => $package
@@ -64314,7 +64934,7 @@ class PEAR_DependencyDB
  * @author     Martin Jansen <mj at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Downloader.php,v 1.159 2009/03/08 04:01:08 dufuz Exp $
+ * @version    CVS: $Id: Downloader.php 287109 2009-08-11 18:50:30Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.3.0
  */
@@ -64341,7 +64961,7 @@ define('PEAR_INSTALLER_ERROR_NO_PREF_STATE', 2);
  * @author     Martin Jansen <mj at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.3.0
  */
@@ -64441,7 +65061,6 @@ class PEAR_Downloader extends PEAR_Common
      * @var string
      */
     var $_downloadDir;
-    // {{{ PEAR_Downloader()
 
     /**
      * @param PEAR_Frontend_*
@@ -64609,7 +65228,8 @@ class PEAR_Downloader extends PEAR_Common
                     }
 
                     if ($params[$i] && !isset($channelschecked[$params[$i]->getChannel()]) &&
-                          !isset($this->_options['offline'])) {
+                          !isset($this->_options['offline'])
+                    ) {
                         $channelschecked[$params[$i]->getChannel()] = true;
                         PEAR::staticPushErrorHandling(PEAR_ERROR_RETURN);
                         if (!class_exists('System')) {
@@ -64627,10 +65247,9 @@ class PEAR_Downloader extends PEAR_Common
                             break;
                         }
 
-                        $mirror = $this->config->get('preferred_mirror', null,
-                                                     $params[$i]->getChannel());
-                        $a = $this->downloadHttp('http://' . $mirror .
-                            '/channel.xml', $this->ui, $dir, null, $curchannel->lastModified());
+                        $mirror = $this->config->get('preferred_mirror', null, $params[$i]->getChannel());
+                        $url    = 'http://' . $mirror . '/channel.xml';
+                        $a = $this->downloadHttp($url, $this->ui, $dir, null, $curchannel->lastModified());
 
                         PEAR::staticPopErrorHandling();
                         if (PEAR::isError($a) || !$a) {
@@ -65059,8 +65678,6 @@ class PEAR_Downloader extends PEAR_Common
         $this->_downloadDir = $dir;
     }
 
-    // }}}
-    // {{{ configSet()
     function configSet($key, $value, $layer = 'user', $channel = false)
     {
         $this->config->set($key, $value, $layer, $channel);
@@ -65071,8 +65688,6 @@ class PEAR_Downloader extends PEAR_Common
         }
     }
 
-    // }}}
-    // {{{ setOptions()
     function setOptions($options)
     {
         $this->_options = $options;
@@ -65085,8 +65700,6 @@ class PEAR_Downloader extends PEAR_Common
         return $this->_options;
     }
 
-    // }}}
-
     /**
      * For simpler unit-testing
      * @param PEAR_Config
@@ -65102,8 +65715,6 @@ class PEAR_Downloader extends PEAR_Common
         return $a;
     }
 
-    // {{{ _getPackageDownloadUrl()
-
     /**
      * @param array output of {@link parsePackageName()}
      * @access private
@@ -65150,7 +65761,7 @@ class PEAR_Downloader extends PEAR_Common
                !($base = $chan->getBaseURL('REST1.0', $preferred_mirror))
               )
         ) {
-            return $this->raiseError($parr['channel'] . ' is using a unsupported protocal - This should never happen.');
+            return $this->raiseError($parr['channel'] . ' is using a unsupported protocol - This should never happen.');
         }
 
         if ($base2) {
@@ -65160,14 +65771,15 @@ class PEAR_Downloader extends PEAR_Common
             $rest = &$this->config->getREST('1.0', $this->_options);
         }
 
+        $downloadVersion = false;
         if (!isset($parr['version']) && !isset($parr['state']) && $version
               && !PEAR::isError($version)
-              && !isset($this->_options['downloadonly'])) {
-            $url = $rest->getDownloadURL($base, $parr, $state, $version, $chan->getName());
-        } else {
-            $url = $rest->getDownloadURL($base, $parr, $state, false, $chan->getName());
+              && !isset($this->_options['downloadonly'])
+        ) {
+            $downloadVersion = $version;
         }
 
+        $url = $rest->getDownloadURL($base, $parr, $state, $downloadVersion, $chan->getName());
         if (PEAR::isError($url)) {
             $this->configSet('default_channel', $curchannel);
             return $url;
@@ -65238,8 +65850,6 @@ class PEAR_Downloader extends PEAR_Common
 
         return $url;
     }
-    // }}}
-    // {{{ getDepPackageDownloadUrl()
 
     /**
      * @param array dependency array
@@ -65369,10 +65979,8 @@ class PEAR_Downloader extends PEAR_Common
             return $url;
         }
 
-        return $this->raiseError($parr['channel'] . ' is using a unsupported protocal - This should never happen.');
+        return $this->raiseError($parr['channel'] . ' is using a unsupported protocol - This should never happen.');
     }
-    // }}}
-    // {{{ getPackageDownloadUrl()
 
     /**
      * @deprecated in favor of _getPackageDownloadUrl
@@ -65397,9 +66005,6 @@ class PEAR_Downloader extends PEAR_Common
         return $package;
     }
 
-    // }}}
-    // {{{ getDownloadedPackages()
-
     /**
      * Retrieve a list of downloaded packages after a call to {@link download()}.
      *
@@ -65414,9 +66019,6 @@ class PEAR_Downloader extends PEAR_Common
         return $ret;
     }
 
-    // }}}
-    // {{{ _downloadCallback()
-
     function _downloadCallback($msg, $params = null)
     {
         switch ($msg) {
@@ -65449,9 +66051,6 @@ class PEAR_Downloader extends PEAR_Common
             $this->ui->_downloadCallback($msg, $params);
     }
 
-    // }}}
-    // {{{ _prependPath($path, $prepend)
-
     function _prependPath($path, $prepend)
     {
         if (strlen($prepend) > 0) {
@@ -65468,8 +66067,6 @@ class PEAR_Downloader extends PEAR_Common
         }
         return $path;
     }
-    // }}}
-    // {{{ pushError($errmsg, $code)
 
     /**
      * @param string
@@ -65480,9 +66077,6 @@ class PEAR_Downloader extends PEAR_Common
         array_push($this->_errorStack, array($errmsg, $code));
     }
 
-    // }}}
-    // {{{ getErrorMsgs()
-
     function getErrorMsgs()
     {
         $msgs = array();
@@ -65494,10 +66088,10 @@ class PEAR_Downloader extends PEAR_Common
         return $msgs;
     }
 
-    // }}}
-
     /**
      * for BC
+     *
+     * @deprecated
      */
     function sortPkgDeps(&$packages, $uninstall = false)
     {
@@ -65656,7 +66250,7 @@ class PEAR_Downloader extends PEAR_Common
 
         $installOrder = Structures_Graph_Manipulator_TopologicalSorter::sort($depgraph);
         $ret = array();
-        for ($i = 0; $i < count($installOrder); $i++) {
+        for ($i = 0, $count = count($installOrder); $i < $count; $i++) {
             foreach ($installOrder[$i] as $index => $sortedpackage) {
                 $data = &$installOrder[$i][$index]->getData();
                 $ret[] = &$nodes[$reg->parsedPackageNameToString(
@@ -65691,6 +66285,7 @@ class PEAR_Downloader extends PEAR_Common
                         if (count($deplinks[$dep]) == 0) {
                             unset($deplinks[$dep]);
                         }
+
                         continue 3;
                     }
                 }
@@ -65705,25 +66300,30 @@ class PEAR_Downloader extends PEAR_Common
             $visited = array();
             return;
         }
+
         // this happens when a parent has a dep cycle on another dependency
         // but the child is not part of the cycle
         if (isset($visited[$dep])) {
             return false;
         }
+
         $visited[$dep] = 1;
         if ($test == $dep) {
             return true;
         }
+
         if (isset($deplinks[$dep])) {
             if (in_array($test, array_keys($deplinks[$dep]), true)) {
                 return true;
             }
+
             foreach ($deplinks[$dep] as $parent => $unused) {
                 if ($this->_testCycle($test, $deplinks, $parent)) {
                     return true;
                 }
             }
         }
+
         return false;
     }
 
@@ -65960,7 +66560,7 @@ class PEAR_Downloader extends PEAR_Common
         }
 
         $request .= $ifmodifiedsince .
-            "User-Agent: PEAR/1.8.0/PHP/" . PHP_VERSION . "\r\n";
+            "User-Agent: PEAR/1.9.0/PHP/" . PHP_VERSION . "\r\n";
 
         if (isset($this)) { // only pass in authentication for non-static calls
             $username = $config->get('username', null, $channel);
@@ -66057,6 +66657,7 @@ class PEAR_Downloader extends PEAR_Common
                 return PEAR::raiseError("$dest_file: write failed ($php_errormsg)");
             }
         }
+
         fclose($fp);
         fclose($wp);
         if ($callback) {
@@ -66067,6 +66668,7 @@ class PEAR_Downloader extends PEAR_Common
             if (isset($headers['etag'])) {
                 $lastmodified = array('ETag' => $headers['etag']);
             }
+
             if (isset($headers['last-modified'])) {
                 if (is_array($lastmodified)) {
                     $lastmodified['Last-Modified'] = $headers['last-modified'];
@@ -66090,7 +66692,7 @@ class PEAR_Downloader extends PEAR_Common
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Package.php,v 1.126 2009/03/07 21:51:52 dufuz Exp $
+ * @version    CVS: $Id: Package.php 287560 2009-08-21 22:36:18Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -66131,7 +66733,7 @@ define('PEAR_DOWNLOADER_PACKAGE_PHPVERSION', -1004);
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -66246,6 +66848,12 @@ class PEAR_Downloader_Package
         $options = $this->_downloader->getOptions();
         if (isset($options['offline'])) {
             if (PEAR::isError($origErr) && !isset($options['soft'])) {
+                foreach ($origErr->getUserInfo() as $userInfo) {
+                    if (isset($userInfo['message'])) {
+                        $this->_downloader->log(0, $userInfo['message']);
+                    }
+                }
+
                 $this->_downloader->log(0, $origErr->getMessage());
             }
 
@@ -66343,8 +66951,15 @@ class PEAR_Downloader_Package
 
             if ($info != $newinfo) {
                 do {
-                    if ($info['package'] == 'pecl.php.net' && $newinfo['package'] == 'pear.php.net') {
-                        $info['package'] = 'pear.php.net';
+                    if ($info['channel'] == 'pecl.php.net' && $newinfo['channel'] == 'pear.php.net') {
+                        $info['channel'] = 'pear.php.net';
+                        if ($info == $newinfo) {
+                            // skip the channel check if a pecl package says it's a PEAR package
+                            break;
+                        }
+                    }
+                    if ($info['channel'] == 'pear.php.net' && $newinfo['channel'] == 'pecl.php.net') {
+                        $info['channel'] = 'pecl.php.net';
                         if ($info == $newinfo) {
                             // skip the channel check if a pecl package says it's a PEAR package
                             break;
@@ -66733,8 +67348,7 @@ class PEAR_Downloader_Package
         // we can't determine whether upgrade is necessary until we know what
         // version would be downloaded
         if (!isset($options['force']) && $this->isInstalled($ret, $oper)) {
-            $version = $this->_installRegistry->packageInfo($dep['name'], 'version',
-                $dep['channel']);
+            $version = $this->_installRegistry->packageInfo($dep['name'], 'version', $dep['channel']);
             $dep['package'] = $dep['name'];
             if (!isset($options['soft'])) {
                 $this->_downloader->log(3, $this->getShortName() . ': Skipping ' . $group .
@@ -66811,8 +67425,7 @@ class PEAR_Downloader_Package
                     $newdep = $newdep[0];
                     $newdep['channel'] = 'pecl.php.net';
                     $chan = 'pecl.php.net';
-                    $url =
-                        $this->_downloader->_getDepPackageDownloadUrl($newdep, $pname);
+                    $url = $this->_downloader->_getDepPackageDownloadUrl($newdep, $pname);
                     $obj = &$this->_installRegistry->getPackage($dep['name']);
                     if (PEAR::isError($url)) {
                         PEAR::popErrorHandling();
@@ -66896,8 +67509,7 @@ class PEAR_Downloader_Package
                         'optional';
                     $dep['package'] = $dep['name'];
                     if (isset($newdep)) {
-                        $version = $this->_installRegistry->packageInfo($newdep['name'], 'version',
-                            $newdep['channel']);
+                        $version = $this->_installRegistry->packageInfo($newdep['name'], 'version', $newdep['channel']);
                     } else {
                         $version = $this->_installRegistry->packageInfo($dep['name'], 'version');
                     }
@@ -67216,6 +67828,7 @@ class PEAR_Downloader_Package
                     $channel = 'pear.php.net';
                 }
             }
+
             return (strtolower($package) == strtolower($this->getPackage()) &&
                 $channel == $this->getChannel() &&
                 version_compare($newdep['min'], $this->getVersion(), '<=') &&
@@ -67360,13 +67973,9 @@ class PEAR_Downloader_Package
             if (!$param) {
                 continue;
             }
-            if ($param->getPackage()) {
-                if ($ignoreGroups) {
-                    $group = '';
-                } else {
-                    $group = $param->getGroup();
-                }
 
+            if ($param->getPackage()) {
+                $group = $ignoreGroups ? '' : $param->getGroup();
                 $pnames[$i] = $param->getChannel() . '/' .
                     $param->getPackage() . '-' . $param->getVersion() . '#' . $group;
             }
@@ -67896,7 +68505,7 @@ class PEAR_Downloader_Package
             if ($info['version'] === $package_version) {
                 if (!isset($options['soft'])) {
                     $this->_downloader->log(1, 'WARNING: failed to download ' . $pname['channel'] .
-                        '/' . $pname['package'] . '-' . $pname['version'] . ', additionally the suggested version' .
+                        '/' . $pname['package'] . '-' . $package_version. ', additionally the suggested version' .
                         ' (' . $package_version . ') is the same as the locally installed one.');
                 }
 
@@ -67906,7 +68515,7 @@ class PEAR_Downloader_Package
             if (version_compare($info['version'], $package_version, '<=')) {
                 if (!isset($options['soft'])) {
                     $this->_downloader->log(1, 'WARNING: failed to download ' . $pname['channel'] .
-                        '/' . $pname['package'] . '-' . $pname['version'] . ', additionally the suggested version' .
+                        '/' . $pname['package'] . '-' . $package_version . ', additionally the suggested version' .
                         ' (' . $info['version'] . ') is a lower version than the locally installed one (' . $package_version . ').');
                 }
 
@@ -68075,1218 +68684,1218 @@ class PEAR_Downloader_Package
 
         return $info;
     }
-}<?php
-/**
- * Error Stack Implementation
- * 
- * This is an incredibly simple implementation of a very complex error handling
- * facility.  It contains the ability
- * to track multiple errors from multiple packages simultaneously.  In addition,
- * it can track errors of many levels, save data along with the error, context
- * information such as the exact file, line number, class and function that
- * generated the error, and if necessary, it can raise a traditional PEAR_Error.
- * It has built-in support for PEAR::Log, to log errors as they occur
- * 
- * Since version 0.2alpha, it is also possible to selectively ignore errors,
- * through the use of an error callback, see {@link pushCallback()}
- * 
- * Since version 0.3alpha, it is possible to specify the exception class
- * returned from {@link push()}
- *
- * Since version PEAR1.3.2, ErrorStack no longer instantiates an exception class.  This can
- * still be done quite handily in an error callback or by manipulating the returned array
- * @category   Debugging
- * @package    PEAR_ErrorStack
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  2004-2008 Greg Beaver
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: ErrorStack.php,v 1.29 2009/02/24 23:38:22 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR_ErrorStack
- */
-
-/**
- * Singleton storage
- * 
- * Format:
- * <pre>
- * array(
- *  'package1' => PEAR_ErrorStack object,
- *  'package2' => PEAR_ErrorStack object,
- *  ...
- * )
- * </pre>
- * @access private
- * @global array $GLOBALS['_PEAR_ERRORSTACK_SINGLETON']
- */
-$GLOBALS['_PEAR_ERRORSTACK_SINGLETON'] = array();
-
-/**
- * Global error callback (default)
- * 
- * This is only used if set to non-false.  * is the default callback for
- * all packages, whereas specific packages may set a default callback
- * for all instances, regardless of whether they are a singleton or not.
- *
- * To exclude non-singletons, only set the local callback for the singleton
- * @see PEAR_ErrorStack::setDefaultCallback()
- * @access private
- * @global array $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK']
- */
-$GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'] = array(
-    '*' => false,
-);
-
-/**
- * Global Log object (default)
- * 
- * This is only used if set to non-false.  Use to set a default log object for
- * all stacks, regardless of instantiation order or location
- * @see PEAR_ErrorStack::setDefaultLogger()
- * @access private
- * @global array $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER']
- */
-$GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'] = false;
-
-/**
- * Global Overriding Callback
- * 
- * This callback will override any error callbacks that specific loggers have set.
- * Use with EXTREME caution
- * @see PEAR_ErrorStack::staticPushCallback()
- * @access private
- * @global array $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER']
- */
-$GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'] = array();
-
-/**#@+
- * One of four possible return values from the error Callback
- * @see PEAR_ErrorStack::_errorCallback()
- */
-/**
- * If this is returned, then the error will be both pushed onto the stack
- * and logged.
- */
-define('PEAR_ERRORSTACK_PUSHANDLOG', 1);
-/**
- * If this is returned, then the error will only be pushed onto the stack,
- * and not logged.
- */
-define('PEAR_ERRORSTACK_PUSH', 2);
-/**
- * If this is returned, then the error will only be logged, but not pushed
- * onto the error stack.
- */
-define('PEAR_ERRORSTACK_LOG', 3);
-/**
- * If this is returned, then the error is completely ignored.
- */
-define('PEAR_ERRORSTACK_IGNORE', 4);
-/**
- * If this is returned, then the error is logged and die() is called.
- */
-define('PEAR_ERRORSTACK_DIE', 5);
-/**#@-*/
-
-/**
- * Error code for an attempt to instantiate a non-class as a PEAR_ErrorStack in
- * the singleton method.
- */
-define('PEAR_ERRORSTACK_ERR_NONCLASS', 1);
-
-/**
- * Error code for an attempt to pass an object into {@link PEAR_ErrorStack::getMessage()}
- * that has no __toString() method
- */
-define('PEAR_ERRORSTACK_ERR_OBJTOSTRING', 2);
-/**
- * Error Stack Implementation
- *
- * Usage:
- * <code>
- * // global error stack
- * $global_stack = &PEAR_ErrorStack::singleton('MyPackage');
- * // local error stack
- * $local_stack = new PEAR_ErrorStack('MyPackage');
- * </code>
- * @author     Greg Beaver <cellog at php.net>
- * @version    1.8.0
- * @package    PEAR_ErrorStack
- * @category   Debugging
- * @copyright  2004-2008 Greg Beaver
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: ErrorStack.php,v 1.29 2009/02/24 23:38:22 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR_ErrorStack
- */
-class PEAR_ErrorStack {
-    /**
-     * Errors are stored in the order that they are pushed on the stack.
-     * @since 0.4alpha Errors are no longer organized by error level.
-     * This renders pop() nearly unusable, and levels could be more easily
-     * handled in a callback anyway
-     * @var array
-     * @access private
-     */
-    var $_errors = array();
-
-    /**
-     * Storage of errors by level.
-     *
-     * Allows easy retrieval and deletion of only errors from a particular level
-     * @since PEAR 1.4.0dev
-     * @var array
-     * @access private
-     */
-    var $_errorsByLevel = array();
-
-    /**
-     * Package name this error stack represents
-     * @var string
-     * @access protected
-     */
-    var $_package;
-    
-    /**
-     * Determines whether a PEAR_Error is thrown upon every error addition
-     * @var boolean
-     * @access private
-     */
-    var $_compat = false;
-    
-    /**
-     * If set to a valid callback, this will be used to generate the error
-     * message from the error code, otherwise the message passed in will be
-     * used
-     * @var false|string|array
-     * @access private
-     */
-    var $_msgCallback = false;
-    
-    /**
-     * If set to a valid callback, this will be used to generate the error
-     * context for an error.  For PHP-related errors, this will be a file
-     * and line number as retrieved from debug_backtrace(), but can be
-     * customized for other purposes.  The error might actually be in a separate
-     * configuration file, or in a database query.
-     * @var false|string|array
-     * @access protected
-     */
-    var $_contextCallback = false;
-    
-    /**
-     * If set to a valid callback, this will be called every time an error
-     * is pushed onto the stack.  The return value will be used to determine
-     * whether to allow an error to be pushed or logged.
-     * 
-     * The return value must be one an PEAR_ERRORSTACK_* constant
-     * @see PEAR_ERRORSTACK_PUSHANDLOG, PEAR_ERRORSTACK_PUSH, PEAR_ERRORSTACK_LOG
-     * @var false|string|array
-     * @access protected
-     */
-    var $_errorCallback = array();
-    
-    /**
-     * PEAR::Log object for logging errors
-     * @var false|Log
-     * @access protected
-     */
-    var $_logger = false;
-    
-    /**
-     * Error messages - designed to be overridden
-     * @var array
-     * @abstract
-     */
-    var $_errorMsgs = array();
-    
-    /**
-     * Set up a new error stack
-     * 
-     * @param string   $package name of the package this error stack represents
-     * @param callback $msgCallback callback used for error message generation
-     * @param callback $contextCallback callback used for context generation,
-     *                 defaults to {@link getFileLine()}
-     * @param boolean  $throwPEAR_Error
-     */
-    function PEAR_ErrorStack($package, $msgCallback = false, $contextCallback = false,
-                         $throwPEAR_Error = false)
-    {
-        $this->_package = $package;
-        $this->setMessageCallback($msgCallback);
-        $this->setContextCallback($contextCallback);
-        $this->_compat = $throwPEAR_Error;
-    }
-    
-    /**
-     * Return a single error stack for this package.
-     * 
-     * Note that all parameters are ignored if the stack for package $package
-     * has already been instantiated
-     * @param string   $package name of the package this error stack represents
-     * @param callback $msgCallback callback used for error message generation
-     * @param callback $contextCallback callback used for context generation,
-     *                 defaults to {@link getFileLine()}
-     * @param boolean  $throwPEAR_Error
-     * @param string   $stackClass class to instantiate
-     * @static
-     * @return PEAR_ErrorStack
-     */
-    function &singleton($package, $msgCallback = false, $contextCallback = false,
-                         $throwPEAR_Error = false, $stackClass = 'PEAR_ErrorStack')
-    {
-        if (isset($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package])) {
-            return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package];
-        }
-        if (!class_exists($stackClass)) {
-            if (function_exists('debug_backtrace')) {
-                $trace = debug_backtrace();
-            }
-            PEAR_ErrorStack::staticPush('PEAR_ErrorStack', PEAR_ERRORSTACK_ERR_NONCLASS,
-                'exception', array('stackclass' => $stackClass),
-                'stack class "%stackclass%" is not a valid class name (should be like PEAR_ErrorStack)',
-                false, $trace);
-        }
-        $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package] =
-            new $stackClass($package, $msgCallback, $contextCallback, $throwPEAR_Error);
-
-        return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package];
-    }
-
-    /**
-     * Internal error handler for PEAR_ErrorStack class
-     * 
-     * Dies if the error is an exception (and would have died anyway)
-     * @access private
-     */
-    function _handleError($err)
-    {
-        if ($err['level'] == 'exception') {
-            $message = $err['message'];
-            if (isset($_SERVER['REQUEST_URI'])) {
-                echo '<br />';
-            } else {
-                echo "\n";
-            }
-            var_dump($err['context']);
-            die($message);
-        }
-    }
-    
-    /**
-     * Set up a PEAR::Log object for all error stacks that don't have one
-     * @param Log $log 
-     * @static
-     */
-    function setDefaultLogger(&$log)
-    {
-        if (is_object($log) && method_exists($log, 'log') ) {
-            $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'] = &$log;
-        } elseif (is_callable($log)) {
-            $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'] = &$log;
-	}
-    }
-    
-    /**
-     * Set up a PEAR::Log object for this error stack
-     * @param Log $log 
-     */
-    function setLogger(&$log)
-    {
-        if (is_object($log) && method_exists($log, 'log') ) {
-            $this->_logger = &$log;
-        } elseif (is_callable($log)) {
-            $this->_logger = &$log;
-        }
-    }
-    
-    /**
-     * Set an error code => error message mapping callback
-     * 
-     * This method sets the callback that can be used to generate error
-     * messages for any instance
-     * @param array|string Callback function/method
-     */
-    function setMessageCallback($msgCallback)
-    {
-        if (!$msgCallback) {
-            $this->_msgCallback = array(&$this, 'getErrorMessage');
-        } else {
-            if (is_callable($msgCallback)) {
-                $this->_msgCallback = $msgCallback;
-            }
-        }
-    }
-    
-    /**
-     * Get an error code => error message mapping callback
-     * 
-     * This method returns the current callback that can be used to generate error
-     * messages
-     * @return array|string|false Callback function/method or false if none
-     */
-    function getMessageCallback()
-    {
-        return $this->_msgCallback;
-    }
-    
-    /**
-     * Sets a default callback to be used by all error stacks
-     * 
-     * This method sets the callback that can be used to generate error
-     * messages for a singleton
-     * @param array|string Callback function/method
-     * @param string Package name, or false for all packages
-     * @static
-     */
-    function setDefaultCallback($callback = false, $package = false)
-    {
-        if (!is_callable($callback)) {
-            $callback = false;
-        }
-        $package = $package ? $package : '*';
-        $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'][$package] = $callback;
-    }
-    
-    /**
-     * Set a callback that generates context information (location of error) for an error stack
-     * 
-     * This method sets the callback that can be used to generate context
-     * information for an error.  Passing in NULL will disable context generation
-     * and remove the expensive call to debug_backtrace()
-     * @param array|string|null Callback function/method
-     */
-    function setContextCallback($contextCallback)
-    {
-        if ($contextCallback === null) {
-            return $this->_contextCallback = false;
-        }
-        if (!$contextCallback) {
-            $this->_contextCallback = array(&$this, 'getFileLine');
-        } else {
-            if (is_callable($contextCallback)) {
-                $this->_contextCallback = $contextCallback;
-            }
-        }
-    }
-    
-    /**
-     * Set an error Callback
-     * If set to a valid callback, this will be called every time an error
-     * is pushed onto the stack.  The return value will be used to determine
-     * whether to allow an error to be pushed or logged.
-     * 
-     * The return value must be one of the ERRORSTACK_* constants.
-     * 
-     * This functionality can be used to emulate PEAR's pushErrorHandling, and
-     * the PEAR_ERROR_CALLBACK mode, without affecting the integrity of
-     * the error stack or logging
-     * @see PEAR_ERRORSTACK_PUSHANDLOG, PEAR_ERRORSTACK_PUSH, PEAR_ERRORSTACK_LOG
-     * @see popCallback()
-     * @param string|array $cb
-     */
-    function pushCallback($cb)
-    {
-        array_push($this->_errorCallback, $cb);
-    }
-    
-    /**
-     * Remove a callback from the error callback stack
-     * @see pushCallback()
-     * @return array|string|false
-     */
-    function popCallback()
-    {
-        if (!count($this->_errorCallback)) {
-            return false;
-        }
-        return array_pop($this->_errorCallback);
-    }
-    
-    /**
-     * Set a temporary overriding error callback for every package error stack
-     *
-     * Use this to temporarily disable all existing callbacks (can be used
-     * to emulate the @ operator, for instance)
-     * @see PEAR_ERRORSTACK_PUSHANDLOG, PEAR_ERRORSTACK_PUSH, PEAR_ERRORSTACK_LOG
-     * @see staticPopCallback(), pushCallback()
-     * @param string|array $cb
-     * @static
-     */
-    function staticPushCallback($cb)
-    {
-        array_push($GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'], $cb);
-    }
-    
-    /**
-     * Remove a temporary overriding error callback
-     * @see staticPushCallback()
-     * @return array|string|false
-     * @static
-     */
-    function staticPopCallback()
-    {
-        $ret = array_pop($GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK']);
-        if (!is_array($GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'])) {
-            $GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'] = array();
-        }
-        return $ret;
-    }
-    
-    /**
-     * Add an error to the stack
-     * 
-     * If the message generator exists, it is called with 2 parameters.
-     *  - the current Error Stack object
-     *  - an array that is in the same format as an error.  Available indices
-     *    are 'code', 'package', 'time', 'params', 'level', and 'context'
-     * 
-     * Next, if the error should contain context information, this is
-     * handled by the context grabbing method.
-     * Finally, the error is pushed onto the proper error stack
-     * @param int    $code      Package-specific error code
-     * @param string $level     Error level.  This is NOT spell-checked
-     * @param array  $params    associative array of error parameters
-     * @param string $msg       Error message, or a portion of it if the message
-     *                          is to be generated
-     * @param array  $repackage If this error re-packages an error pushed by
-     *                          another package, place the array returned from
-     *                          {@link pop()} in this parameter
-     * @param array  $backtrace Protected parameter: use this to pass in the
-     *                          {@link debug_backtrace()} that should be used
-     *                          to find error context
-     * @return PEAR_Error|array if compatibility mode is on, a PEAR_Error is also
-     * thrown.  If a PEAR_Error is returned, the userinfo
-     * property is set to the following array:
-     * 
-     * <code>
-     * array(
-     *    'code' => $code,
-     *    'params' => $params,
-     *    'package' => $this->_package,
-     *    'level' => $level,
-     *    'time' => time(),
-     *    'context' => $context,
-     *    'message' => $msg,
-     * //['repackage' => $err] repackaged error array/Exception class
-     * );
-     * </code>
-     * 
-     * Normally, the previous array is returned.
-     */
-    function push($code, $level = 'error', $params = array(), $msg = false,
-                  $repackage = false, $backtrace = false)
-    {
-        $context = false;
-        // grab error context
-        if ($this->_contextCallback) {
-            if (!$backtrace) {
-                $backtrace = debug_backtrace();
-            }
-            $context = call_user_func($this->_contextCallback, $code, $params, $backtrace);
-        }
-        
-        // save error
-        $time = explode(' ', microtime());
-        $time = $time[1] + $time[0];
-        $err = array(
-                'code' => $code,
-                'params' => $params,
-                'package' => $this->_package,
-                'level' => $level,
-                'time' => $time,
-                'context' => $context,
-                'message' => $msg,
-               );
-
-        if ($repackage) {
-            $err['repackage'] = $repackage;
-        }
-
-        // set up the error message, if necessary
-        if ($this->_msgCallback) {
-            $msg = call_user_func_array($this->_msgCallback,
-                                        array(&$this, $err));
-            $err['message'] = $msg;
-        }        
-        $push = $log = true;
-        $die = false;
-        // try the overriding callback first
-        $callback = $this->staticPopCallback();
-        if ($callback) {
-            $this->staticPushCallback($callback);
-        }
-        if (!is_callable($callback)) {
-            // try the local callback next
-            $callback = $this->popCallback();
-            if (is_callable($callback)) {
-                $this->pushCallback($callback);
-            } else {
-                // try the default callback
-                $callback = isset($GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'][$this->_package]) ?
-                    $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'][$this->_package] :
-                    $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK']['*'];
-            }
-        }
-        if (is_callable($callback)) {
-            switch(call_user_func($callback, $err)){
-            	case PEAR_ERRORSTACK_IGNORE: 
-            		return $err;
-        		break;
-            	case PEAR_ERRORSTACK_PUSH: 
-            		$log = false;
-        		break;
-            	case PEAR_ERRORSTACK_LOG: 
-            		$push = false;
-        		break;
-            	case PEAR_ERRORSTACK_DIE: 
-            		$die = true;
-        		break;
-                // anything else returned has the same effect as pushandlog
-            }
-        }
-        if ($push) {
-            array_unshift($this->_errors, $err);
-            if (!isset($this->_errorsByLevel[$err['level']])) {
-                $this->_errorsByLevel[$err['level']] = array();
-            }
-            $this->_errorsByLevel[$err['level']][] = &$this->_errors[0];
-        }
-        if ($log) {
-            if ($this->_logger || $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER']) {
-                $this->_log($err);
-            }
-        }
-        if ($die) {
-            die();
-        }
-        if ($this->_compat && $push) {
-            return $this->raiseError($msg, $code, null, null, $err);
-        }
-        return $err;
-    }
-    
-    /**
-     * Static version of {@link push()}
-     * 
-     * @param string $package   Package name this error belongs to
-     * @param int    $code      Package-specific error code
-     * @param string $level     Error level.  This is NOT spell-checked
-     * @param array  $params    associative array of error parameters
-     * @param string $msg       Error message, or a portion of it if the message
-     *                          is to be generated
-     * @param array  $repackage If this error re-packages an error pushed by
-     *                          another package, place the array returned from
-     *                          {@link pop()} in this parameter
-     * @param array  $backtrace Protected parameter: use this to pass in the
-     *                          {@link debug_backtrace()} that should be used
-     *                          to find error context
-     * @return PEAR_Error|array if compatibility mode is on, a PEAR_Error is also
-     *                          thrown.  see docs for {@link push()}
-     * @static
-     */
-    function staticPush($package, $code, $level = 'error', $params = array(),
-                        $msg = false, $repackage = false, $backtrace = false)
-    {
-        $s = &PEAR_ErrorStack::singleton($package);
-        if ($s->_contextCallback) {
-            if (!$backtrace) {
-                if (function_exists('debug_backtrace')) {
-                    $backtrace = debug_backtrace();
-                }
-            }
-        }
-        return $s->push($code, $level, $params, $msg, $repackage, $backtrace);
-    }
-    
-    /**
-     * Log an error using PEAR::Log
-     * @param array $err Error array
-     * @param array $levels Error level => Log constant map
-     * @access protected
-     */
-    function _log($err)
-    {
-        if ($this->_logger) {
-            $logger = &$this->_logger;
-        } else {
-            $logger = &$GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'];
-        }
-        if (is_a($logger, 'Log')) {
-            $levels = array(
-                'exception' => PEAR_LOG_CRIT,
-                'alert' => PEAR_LOG_ALERT,
-                'critical' => PEAR_LOG_CRIT,
-                'error' => PEAR_LOG_ERR,
-                'warning' => PEAR_LOG_WARNING,
-                'notice' => PEAR_LOG_NOTICE,
-                'info' => PEAR_LOG_INFO,
-                'debug' => PEAR_LOG_DEBUG);
-            if (isset($levels[$err['level']])) {
-                $level = $levels[$err['level']];
-            } else {
-                $level = PEAR_LOG_INFO;
-            }
-            $logger->log($err['message'], $level, $err);
-        } else { // support non-standard logs
-            call_user_func($logger, $err);
-        }
-    }
-
-    
-    /**
-     * Pop an error off of the error stack
-     * 
-     * @return false|array
-     * @since 0.4alpha it is no longer possible to specify a specific error
-     * level to return - the last error pushed will be returned, instead
-     */
-    function pop()
-    {
-        $err = @array_shift($this->_errors);
-        if (!is_null($err)) {
-            @array_pop($this->_errorsByLevel[$err['level']]);
-            if (!count($this->_errorsByLevel[$err['level']])) {
-                unset($this->_errorsByLevel[$err['level']]);
-            }
-        }
-        return $err;
-    }
-
-    /**
-     * Pop an error off of the error stack, static method
-     *
-     * @param string package name
-     * @return boolean
-     * @since PEAR1.5.0a1
-     */
-    function staticPop($package)
-    {
-        if ($package) {
-            if (!isset($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package])) {
-                return false;
-            }
-            return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package]->pop();
-        }
-    }
-
-    /**
-     * Determine whether there are any errors on the stack
-     * @param string|array Level name.  Use to determine if any errors
-     * of level (string), or levels (array) have been pushed
-     * @return boolean
-     */
-    function hasErrors($level = false)
-    {
-        if ($level) {
-            return isset($this->_errorsByLevel[$level]);
-        }
-        return count($this->_errors);
-    }
-    
-    /**
-     * Retrieve all errors since last purge
-     * 
-     * @param boolean set in order to empty the error stack
-     * @param string level name, to return only errors of a particular severity
-     * @return array
-     */
-    function getErrors($purge = false, $level = false)
-    {
-        if (!$purge) {
-            if ($level) {
-                if (!isset($this->_errorsByLevel[$level])) {
-                    return array();
-                } else {
-                    return $this->_errorsByLevel[$level];
-                }
-            } else {
-                return $this->_errors;
-            }
-        }
-        if ($level) {
-            $ret = $this->_errorsByLevel[$level];
-            foreach ($this->_errorsByLevel[$level] as $i => $unused) {
-                // entries are references to the $_errors array
-                $this->_errorsByLevel[$level][$i] = false;
-            }
-            // array_filter removes all entries === false
-            $this->_errors = array_filter($this->_errors);
-            unset($this->_errorsByLevel[$level]);
-            return $ret;
-        }
-        $ret = $this->_errors;
-        $this->_errors = array();
-        $this->_errorsByLevel = array();
-        return $ret;
-    }
-    
-    /**
-     * Determine whether there are any errors on a single error stack, or on any error stack
-     *
-     * The optional parameter can be used to test the existence of any errors without the need of
-     * singleton instantiation
-     * @param string|false Package name to check for errors
-     * @param string Level name to check for a particular severity
-     * @return boolean
-     * @static
-     */
-    function staticHasErrors($package = false, $level = false)
-    {
-        if ($package) {
-            if (!isset($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package])) {
-                return false;
-            }
-            return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package]->hasErrors($level);
-        }
-        foreach ($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'] as $package => $obj) {
-            if ($obj->hasErrors($level)) {
-                return true;
-            }
-        }
-        return false;
-    }
-    
-    /**
-     * Get a list of all errors since last purge, organized by package
-     * @since PEAR 1.4.0dev BC break! $level is now in the place $merge used to be
-     * @param boolean $purge Set to purge the error stack of existing errors
-     * @param string  $level Set to a level name in order to retrieve only errors of a particular level
-     * @param boolean $merge Set to return a flat array, not organized by package
-     * @param array   $sortfunc Function used to sort a merged array - default
-     *        sorts by time, and should be good for most cases
-     * @static
-     * @return array 
-     */
-    function staticGetErrors($purge = false, $level = false, $merge = false,
-                             $sortfunc = array('PEAR_ErrorStack', '_sortErrors'))
-    {
-        $ret = array();
-        if (!is_callable($sortfunc)) {
-            $sortfunc = array('PEAR_ErrorStack', '_sortErrors');
-        }
-        foreach ($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'] as $package => $obj) {
-            $test = $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package]->getErrors($purge, $level);
-            if ($test) {
-                if ($merge) {
-                    $ret = array_merge($ret, $test);
-                } else {
-                    $ret[$package] = $test;
-                }
-            }
-        }
-        if ($merge) {
-            usort($ret, $sortfunc);
-        }
-        return $ret;
-    }
-    
-    /**
-     * Error sorting function, sorts by time
-     * @access private
-     */
-    function _sortErrors($a, $b)
-    {
-        if ($a['time'] == $b['time']) {
-            return 0;
-        }
-        if ($a['time'] < $b['time']) {
-            return 1;
-        }
-        return -1;
-    }
-
-    /**
-     * Standard file/line number/function/class context callback
-     *
-     * This function uses a backtrace generated from {@link debug_backtrace()}
-     * and so will not work at all in PHP < 4.3.0.  The frame should
-     * reference the frame that contains the source of the error.
-     * @return array|false either array('file' => file, 'line' => line,
-     *         'function' => function name, 'class' => class name) or
-     *         if this doesn't work, then false
-     * @param unused
-     * @param integer backtrace frame.
-     * @param array Results of debug_backtrace()
-     * @static
-     */
-    function getFileLine($code, $params, $backtrace = null)
-    {
-        if ($backtrace === null) {
-            return false;
-        }
-        $frame = 0;
-        $functionframe = 1;
-        if (!isset($backtrace[1])) {
-            $functionframe = 0;
-        } else {
-            while (isset($backtrace[$functionframe]['function']) &&
-                  $backtrace[$functionframe]['function'] == 'eval' &&
-                  isset($backtrace[$functionframe + 1])) {
-                $functionframe++;
-            }
-        }
-        if (isset($backtrace[$frame])) {
-            if (!isset($backtrace[$frame]['file'])) {
-                $frame++;
-            }
-            $funcbacktrace = $backtrace[$functionframe];
-            $filebacktrace = $backtrace[$frame];
-            $ret = array('file' => $filebacktrace['file'],
-                         'line' => $filebacktrace['line']);
-            // rearrange for eval'd code or create function errors
-            if (strpos($filebacktrace['file'], '(') && 
-            	  preg_match(';^(.*?)\((\d+)\) : (.*?)\\z;', $filebacktrace['file'],
-                  $matches)) {
-                $ret['file'] = $matches[1];
-                $ret['line'] = $matches[2] + 0;
-            }
-            if (isset($funcbacktrace['function']) && isset($backtrace[1])) {
-                if ($funcbacktrace['function'] != 'eval') {
-                    if ($funcbacktrace['function'] == '__lambda_func') {
-                        $ret['function'] = 'create_function() code';
-                    } else {
-                        $ret['function'] = $funcbacktrace['function'];
-                    }
-                }
-            }
-            if (isset($funcbacktrace['class']) && isset($backtrace[1])) {
-                $ret['class'] = $funcbacktrace['class'];
-            }
-            return $ret;
-        }
-        return false;
-    }
-    
-    /**
-     * Standard error message generation callback
-     * 
-     * This method may also be called by a custom error message generator
-     * to fill in template values from the params array, simply
-     * set the third parameter to the error message template string to use
-     * 
-     * The special variable %__msg% is reserved: use it only to specify
-     * where a message passed in by the user should be placed in the template,
-     * like so:
-     * 
-     * Error message: %msg% - internal error
-     * 
-     * If the message passed like so:
-     * 
-     * <code>
-     * $stack->push(ERROR_CODE, 'error', array(), 'server error 500');
-     * </code>
-     * 
-     * The returned error message will be "Error message: server error 500 -
-     * internal error"
-     * @param PEAR_ErrorStack
-     * @param array
-     * @param string|false Pre-generated error message template
-     * @static
-     * @return string
-     */
-    function getErrorMessage(&$stack, $err, $template = false)
-    {
-        if ($template) {
-            $mainmsg = $template;
-        } else {
-            $mainmsg = $stack->getErrorMessageTemplate($err['code']);
-        }
-        $mainmsg = str_replace('%__msg%', $err['message'], $mainmsg);
-        if (is_array($err['params']) && count($err['params'])) {
-            foreach ($err['params'] as $name => $val) {
-                if (is_array($val)) {
-                    // @ is needed in case $val is a multi-dimensional array
-                    $val = @implode(', ', $val);
-                }
-                if (is_object($val)) {
-                    if (method_exists($val, '__toString')) {
-                        $val = $val->__toString();
-                    } else {
-                        PEAR_ErrorStack::staticPush('PEAR_ErrorStack', PEAR_ERRORSTACK_ERR_OBJTOSTRING,
-                            'warning', array('obj' => get_class($val)),
-                            'object %obj% passed into getErrorMessage, but has no __toString() method');
-                        $val = 'Object';
-                    }
-                }
-                $mainmsg = str_replace('%' . $name . '%', $val, $mainmsg);
-            }
-        }
-        return $mainmsg;
-    }
-    
-    /**
-     * Standard Error Message Template generator from code
-     * @return string
-     */
-    function getErrorMessageTemplate($code)
-    {
-        if (!isset($this->_errorMsgs[$code])) {
-            return '%__msg%';
-        }
-        return $this->_errorMsgs[$code];
-    }
-    
-    /**
-     * Set the Error Message Template array
-     * 
-     * The array format must be:
-     * <pre>
-     * array(error code => 'message template',...)
-     * </pre>
-     * 
-     * Error message parameters passed into {@link push()} will be used as input
-     * for the error message.  If the template is 'message %foo% was %bar%', and the
-     * parameters are array('foo' => 'one', 'bar' => 'six'), the error message returned will
-     * be 'message one was six'
-     * @return string
-     */
-    function setErrorMessageTemplate($template)
-    {
-        $this->_errorMsgs = $template;
-    }
-    
-    
-    /**
-     * emulate PEAR::raiseError()
-     * 
-     * @return PEAR_Error
-     */
-    function raiseError()
-    {
-        require_once 'phar://install-pear-nozlib.phar/' . 'PEAR.php';
-        $args = func_get_args();
-        return call_user_func_array(array('PEAR', 'raiseError'), $args);
-    }
-}
-$stack = &PEAR_ErrorStack::singleton('PEAR_ErrorStack');
-$stack->pushCallback(array('PEAR_ErrorStack', '_handleError'));
-?>
-<?php
-/**
- * PEAR_Frontend, the singleton-based frontend for user input/output
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Frontend.php,v 1.18 2009/02/24 23:38:22 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * Include error handling
- */
-//require_once 'PEAR.php';
-
-/**
- * Which user interface class is being used.
- * @var string class name
- */
-$GLOBALS['_PEAR_FRONTEND_CLASS'] = 'PEAR_Frontend_CLI';
-
-/**
- * Instance of $_PEAR_Command_uiclass.
- * @var object
- */
-$GLOBALS['_PEAR_FRONTEND_SINGLETON'] = null;
-
-/**
- * Singleton-based frontend for PEAR user input/output
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Frontend extends PEAR
-{
-    /**
-     * Retrieve the frontend object
-     * @return PEAR_Frontend_CLI|PEAR_Frontend_Web|PEAR_Frontend_Gtk
-     * @static
-     */
-    function &singleton($type = null)
-    {
-        if ($type === null) {
-            if (!isset($GLOBALS['_PEAR_FRONTEND_SINGLETON'])) {
-                $a = false;
-                return $a;
-            }
-            return $GLOBALS['_PEAR_FRONTEND_SINGLETON'];
-        }
-
-        $a = PEAR_Frontend::setFrontendClass($type);
-        return $a;
-    }
-
-    /**
-     * Set the frontend class that will be used by calls to {@link singleton()}
-     *
-     * Frontends are expected to conform to the PEAR naming standard of
-     * _ => DIRECTORY_SEPARATOR (PEAR_Frontend_CLI is in PEAR/Frontend/CLI.php)
-     * @param string $uiclass full class name
-     * @return PEAR_Frontend
-     * @static
-     */
-    function &setFrontendClass($uiclass)
-    {
-        if (is_object($GLOBALS['_PEAR_FRONTEND_SINGLETON']) &&
-              is_a($GLOBALS['_PEAR_FRONTEND_SINGLETON'], $uiclass)) {
-            return $GLOBALS['_PEAR_FRONTEND_SINGLETON'];
-        }
-
-        if (!class_exists($uiclass)) {
-            $file = 'phar://install-pear-nozlib.phar/' . str_replace('_', '/', $uiclass) . '.php';
-            if (PEAR_Frontend::isIncludeable($file)) {
-                include_once $file;
-            }
-        }
-
-        if (class_exists($uiclass)) {
-            $obj = &new $uiclass;
-            // quick test to see if this class implements a few of the most
-            // important frontend methods
-            if (is_a($obj, 'PEAR_Frontend')) {
-                $GLOBALS['_PEAR_FRONTEND_SINGLETON'] = &$obj;
-                $GLOBALS['_PEAR_FRONTEND_CLASS'] = $uiclass;
-                return $obj;
-            }
-
-            $err = PEAR::raiseError("not a frontend class: $uiclass");
-            return $err;
-        }
-
-        $err = PEAR::raiseError("no such class: $uiclass");
-        return $err;
-    }
-
-    /**
-     * Set the frontend class that will be used by calls to {@link singleton()}
-     *
-     * Frontends are expected to be a descendant of PEAR_Frontend
-     * @param PEAR_Frontend
-     * @return PEAR_Frontend
-     * @static
-     */
-    function &setFrontendObject($uiobject)
-    {
-        if (is_object($GLOBALS['_PEAR_FRONTEND_SINGLETON']) &&
-              is_a($GLOBALS['_PEAR_FRONTEND_SINGLETON'], get_class($uiobject))) {
-            return $GLOBALS['_PEAR_FRONTEND_SINGLETON'];
-        }
-
-        if (!is_a($uiobject, 'PEAR_Frontend')) {
-            $err = PEAR::raiseError('not a valid frontend class: (' .
-                get_class($uiobject) . ')');
-            return $err;
-        }
-
-        $GLOBALS['_PEAR_FRONTEND_SINGLETON'] = &$uiobject;
-        $GLOBALS['_PEAR_FRONTEND_CLASS'] = get_class($uiobject);
-        return $uiobject;
-    }
-
-    /**
-     * @param string $path relative or absolute include path
-     * @return boolean
-     * @static
-     */
-    function isIncludeable($path)
-    {
-        if (file_exists($path) && is_readable($path)) {
-            return true;
-        }
-
-        $fp = @fopen($path, 'r', true);
-        if ($fp) {
-            fclose($fp);
-            return true;
-        }
-
-        return false;
-    }
-
-    /**
-     * @param PEAR_Config
-     */
-    function setConfig(&$config)
-    {
-    }
-
-    /**
-     * This can be overridden to allow session-based temporary file management
-     *
-     * By default, all files are deleted at the end of a session.  The web installer
-     * needs to be able to sustain a list over many sessions in order to support
-     * user interaction with install scripts
-     */
-    function addTempFile($file)
-    {
-        $GLOBALS['_PEAR_Common_tempfiles'][] = $file;
-    }
-
-    /**
-     * Log an action
-     *
-     * @param string $msg the message to log
-     * @param boolean $append_crlf
-     * @return boolean true
-     * @abstract
-     */
-    function log($msg, $append_crlf = true)
-    {
-    }
-
-    /**
-     * Run a post-installation script
-     *
-     * @param array $scripts array of post-install scripts
-     * @abstract
-     */
-    function runPostinstallScripts(&$scripts)
-    {
-    }
-
-    /**
-     * Display human-friendly output formatted depending on the
-     * $command parameter.
-     *
-     * This should be able to handle basic output data with no command
-     * @param mixed  $data    data structure containing the information to display
-     * @param string $command command from which this method was called
-     * @abstract
-     */
-    function outputData($data, $command = '_default')
-    {
-    }
-
-    /**
-     * Display a modal form dialog and return the given input
-     *
-     * A frontend that requires multiple requests to retrieve and process
-     * data must take these needs into account, and implement the request
-     * handling code.
-     * @param string $command  command from which this method was called
-     * @param array  $prompts  associative array. keys are the input field names
-     *                         and values are the description
-     * @param array  $types    array of input field types (text, password,
-     *                         etc.) keys have to be the same like in $prompts
-     * @param array  $defaults array of default values. again keys have
-     *                         to be the same like in $prompts.  Do not depend
-     *                         on a default value being set.
-     * @return array input sent by the user
-     * @abstract
-     */
-    function userDialog($command, $prompts, $types = array(), $defaults = array())
-    {
-    }
+}<?php
+/**
+ * Error Stack Implementation
+ * 
+ * This is an incredibly simple implementation of a very complex error handling
+ * facility.  It contains the ability
+ * to track multiple errors from multiple packages simultaneously.  In addition,
+ * it can track errors of many levels, save data along with the error, context
+ * information such as the exact file, line number, class and function that
+ * generated the error, and if necessary, it can raise a traditional PEAR_Error.
+ * It has built-in support for PEAR::Log, to log errors as they occur
+ * 
+ * Since version 0.2alpha, it is also possible to selectively ignore errors,
+ * through the use of an error callback, see {@link pushCallback()}
+ * 
+ * Since version 0.3alpha, it is possible to specify the exception class
+ * returned from {@link push()}
+ *
+ * Since version PEAR1.3.2, ErrorStack no longer instantiates an exception class.  This can
+ * still be done quite handily in an error callback or by manipulating the returned array
+ * @category   Debugging
+ * @package    PEAR_ErrorStack
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  2004-2008 Greg Beaver
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: ErrorStack.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR_ErrorStack
+ */
+
+/**
+ * Singleton storage
+ * 
+ * Format:
+ * <pre>
+ * array(
+ *  'package1' => PEAR_ErrorStack object,
+ *  'package2' => PEAR_ErrorStack object,
+ *  ...
+ * )
+ * </pre>
+ * @access private
+ * @global array $GLOBALS['_PEAR_ERRORSTACK_SINGLETON']
+ */
+$GLOBALS['_PEAR_ERRORSTACK_SINGLETON'] = array();
+
+/**
+ * Global error callback (default)
+ * 
+ * This is only used if set to non-false.  * is the default callback for
+ * all packages, whereas specific packages may set a default callback
+ * for all instances, regardless of whether they are a singleton or not.
+ *
+ * To exclude non-singletons, only set the local callback for the singleton
+ * @see PEAR_ErrorStack::setDefaultCallback()
+ * @access private
+ * @global array $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK']
+ */
+$GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'] = array(
+    '*' => false,
+);
+
+/**
+ * Global Log object (default)
+ * 
+ * This is only used if set to non-false.  Use to set a default log object for
+ * all stacks, regardless of instantiation order or location
+ * @see PEAR_ErrorStack::setDefaultLogger()
+ * @access private
+ * @global array $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER']
+ */
+$GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'] = false;
+
+/**
+ * Global Overriding Callback
+ * 
+ * This callback will override any error callbacks that specific loggers have set.
+ * Use with EXTREME caution
+ * @see PEAR_ErrorStack::staticPushCallback()
+ * @access private
+ * @global array $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER']
+ */
+$GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'] = array();
+
+/**#@+
+ * One of four possible return values from the error Callback
+ * @see PEAR_ErrorStack::_errorCallback()
+ */
+/**
+ * If this is returned, then the error will be both pushed onto the stack
+ * and logged.
+ */
+define('PEAR_ERRORSTACK_PUSHANDLOG', 1);
+/**
+ * If this is returned, then the error will only be pushed onto the stack,
+ * and not logged.
+ */
+define('PEAR_ERRORSTACK_PUSH', 2);
+/**
+ * If this is returned, then the error will only be logged, but not pushed
+ * onto the error stack.
+ */
+define('PEAR_ERRORSTACK_LOG', 3);
+/**
+ * If this is returned, then the error is completely ignored.
+ */
+define('PEAR_ERRORSTACK_IGNORE', 4);
+/**
+ * If this is returned, then the error is logged and die() is called.
+ */
+define('PEAR_ERRORSTACK_DIE', 5);
+/**#@-*/
+
+/**
+ * Error code for an attempt to instantiate a non-class as a PEAR_ErrorStack in
+ * the singleton method.
+ */
+define('PEAR_ERRORSTACK_ERR_NONCLASS', 1);
+
+/**
+ * Error code for an attempt to pass an object into {@link PEAR_ErrorStack::getMessage()}
+ * that has no __toString() method
+ */
+define('PEAR_ERRORSTACK_ERR_OBJTOSTRING', 2);
+/**
+ * Error Stack Implementation
+ *
+ * Usage:
+ * <code>
+ * // global error stack
+ * $global_stack = &PEAR_ErrorStack::singleton('MyPackage');
+ * // local error stack
+ * $local_stack = new PEAR_ErrorStack('MyPackage');
+ * </code>
+ * @author     Greg Beaver <cellog at php.net>
+ * @version    1.9.0
+ * @package    PEAR_ErrorStack
+ * @category   Debugging
+ * @copyright  2004-2008 Greg Beaver
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: ErrorStack.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR_ErrorStack
+ */
+class PEAR_ErrorStack {
+    /**
+     * Errors are stored in the order that they are pushed on the stack.
+     * @since 0.4alpha Errors are no longer organized by error level.
+     * This renders pop() nearly unusable, and levels could be more easily
+     * handled in a callback anyway
+     * @var array
+     * @access private
+     */
+    var $_errors = array();
+
+    /**
+     * Storage of errors by level.
+     *
+     * Allows easy retrieval and deletion of only errors from a particular level
+     * @since PEAR 1.4.0dev
+     * @var array
+     * @access private
+     */
+    var $_errorsByLevel = array();
+
+    /**
+     * Package name this error stack represents
+     * @var string
+     * @access protected
+     */
+    var $_package;
+    
+    /**
+     * Determines whether a PEAR_Error is thrown upon every error addition
+     * @var boolean
+     * @access private
+     */
+    var $_compat = false;
+    
+    /**
+     * If set to a valid callback, this will be used to generate the error
+     * message from the error code, otherwise the message passed in will be
+     * used
+     * @var false|string|array
+     * @access private
+     */
+    var $_msgCallback = false;
+    
+    /**
+     * If set to a valid callback, this will be used to generate the error
+     * context for an error.  For PHP-related errors, this will be a file
+     * and line number as retrieved from debug_backtrace(), but can be
+     * customized for other purposes.  The error might actually be in a separate
+     * configuration file, or in a database query.
+     * @var false|string|array
+     * @access protected
+     */
+    var $_contextCallback = false;
+    
+    /**
+     * If set to a valid callback, this will be called every time an error
+     * is pushed onto the stack.  The return value will be used to determine
+     * whether to allow an error to be pushed or logged.
+     * 
+     * The return value must be one an PEAR_ERRORSTACK_* constant
+     * @see PEAR_ERRORSTACK_PUSHANDLOG, PEAR_ERRORSTACK_PUSH, PEAR_ERRORSTACK_LOG
+     * @var false|string|array
+     * @access protected
+     */
+    var $_errorCallback = array();
+    
+    /**
+     * PEAR::Log object for logging errors
+     * @var false|Log
+     * @access protected
+     */
+    var $_logger = false;
+    
+    /**
+     * Error messages - designed to be overridden
+     * @var array
+     * @abstract
+     */
+    var $_errorMsgs = array();
+    
+    /**
+     * Set up a new error stack
+     * 
+     * @param string   $package name of the package this error stack represents
+     * @param callback $msgCallback callback used for error message generation
+     * @param callback $contextCallback callback used for context generation,
+     *                 defaults to {@link getFileLine()}
+     * @param boolean  $throwPEAR_Error
+     */
+    function PEAR_ErrorStack($package, $msgCallback = false, $contextCallback = false,
+                         $throwPEAR_Error = false)
+    {
+        $this->_package = $package;
+        $this->setMessageCallback($msgCallback);
+        $this->setContextCallback($contextCallback);
+        $this->_compat = $throwPEAR_Error;
+    }
+    
+    /**
+     * Return a single error stack for this package.
+     * 
+     * Note that all parameters are ignored if the stack for package $package
+     * has already been instantiated
+     * @param string   $package name of the package this error stack represents
+     * @param callback $msgCallback callback used for error message generation
+     * @param callback $contextCallback callback used for context generation,
+     *                 defaults to {@link getFileLine()}
+     * @param boolean  $throwPEAR_Error
+     * @param string   $stackClass class to instantiate
+     * @static
+     * @return PEAR_ErrorStack
+     */
+    function &singleton($package, $msgCallback = false, $contextCallback = false,
+                         $throwPEAR_Error = false, $stackClass = 'PEAR_ErrorStack')
+    {
+        if (isset($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package])) {
+            return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package];
+        }
+        if (!class_exists($stackClass)) {
+            if (function_exists('debug_backtrace')) {
+                $trace = debug_backtrace();
+            }
+            PEAR_ErrorStack::staticPush('PEAR_ErrorStack', PEAR_ERRORSTACK_ERR_NONCLASS,
+                'exception', array('stackclass' => $stackClass),
+                'stack class "%stackclass%" is not a valid class name (should be like PEAR_ErrorStack)',
+                false, $trace);
+        }
+        $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package] =
+            new $stackClass($package, $msgCallback, $contextCallback, $throwPEAR_Error);
+
+        return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package];
+    }
+
+    /**
+     * Internal error handler for PEAR_ErrorStack class
+     * 
+     * Dies if the error is an exception (and would have died anyway)
+     * @access private
+     */
+    function _handleError($err)
+    {
+        if ($err['level'] == 'exception') {
+            $message = $err['message'];
+            if (isset($_SERVER['REQUEST_URI'])) {
+                echo '<br />';
+            } else {
+                echo "\n";
+            }
+            var_dump($err['context']);
+            die($message);
+        }
+    }
+    
+    /**
+     * Set up a PEAR::Log object for all error stacks that don't have one
+     * @param Log $log 
+     * @static
+     */
+    function setDefaultLogger(&$log)
+    {
+        if (is_object($log) && method_exists($log, 'log') ) {
+            $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'] = &$log;
+        } elseif (is_callable($log)) {
+            $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'] = &$log;
+	}
+    }
+    
+    /**
+     * Set up a PEAR::Log object for this error stack
+     * @param Log $log 
+     */
+    function setLogger(&$log)
+    {
+        if (is_object($log) && method_exists($log, 'log') ) {
+            $this->_logger = &$log;
+        } elseif (is_callable($log)) {
+            $this->_logger = &$log;
+        }
+    }
+    
+    /**
+     * Set an error code => error message mapping callback
+     * 
+     * This method sets the callback that can be used to generate error
+     * messages for any instance
+     * @param array|string Callback function/method
+     */
+    function setMessageCallback($msgCallback)
+    {
+        if (!$msgCallback) {
+            $this->_msgCallback = array(&$this, 'getErrorMessage');
+        } else {
+            if (is_callable($msgCallback)) {
+                $this->_msgCallback = $msgCallback;
+            }
+        }
+    }
+    
+    /**
+     * Get an error code => error message mapping callback
+     * 
+     * This method returns the current callback that can be used to generate error
+     * messages
+     * @return array|string|false Callback function/method or false if none
+     */
+    function getMessageCallback()
+    {
+        return $this->_msgCallback;
+    }
+    
+    /**
+     * Sets a default callback to be used by all error stacks
+     * 
+     * This method sets the callback that can be used to generate error
+     * messages for a singleton
+     * @param array|string Callback function/method
+     * @param string Package name, or false for all packages
+     * @static
+     */
+    function setDefaultCallback($callback = false, $package = false)
+    {
+        if (!is_callable($callback)) {
+            $callback = false;
+        }
+        $package = $package ? $package : '*';
+        $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'][$package] = $callback;
+    }
+    
+    /**
+     * Set a callback that generates context information (location of error) for an error stack
+     * 
+     * This method sets the callback that can be used to generate context
+     * information for an error.  Passing in NULL will disable context generation
+     * and remove the expensive call to debug_backtrace()
+     * @param array|string|null Callback function/method
+     */
+    function setContextCallback($contextCallback)
+    {
+        if ($contextCallback === null) {
+            return $this->_contextCallback = false;
+        }
+        if (!$contextCallback) {
+            $this->_contextCallback = array(&$this, 'getFileLine');
+        } else {
+            if (is_callable($contextCallback)) {
+                $this->_contextCallback = $contextCallback;
+            }
+        }
+    }
+    
+    /**
+     * Set an error Callback
+     * If set to a valid callback, this will be called every time an error
+     * is pushed onto the stack.  The return value will be used to determine
+     * whether to allow an error to be pushed or logged.
+     * 
+     * The return value must be one of the ERRORSTACK_* constants.
+     * 
+     * This functionality can be used to emulate PEAR's pushErrorHandling, and
+     * the PEAR_ERROR_CALLBACK mode, without affecting the integrity of
+     * the error stack or logging
+     * @see PEAR_ERRORSTACK_PUSHANDLOG, PEAR_ERRORSTACK_PUSH, PEAR_ERRORSTACK_LOG
+     * @see popCallback()
+     * @param string|array $cb
+     */
+    function pushCallback($cb)
+    {
+        array_push($this->_errorCallback, $cb);
+    }
+    
+    /**
+     * Remove a callback from the error callback stack
+     * @see pushCallback()
+     * @return array|string|false
+     */
+    function popCallback()
+    {
+        if (!count($this->_errorCallback)) {
+            return false;
+        }
+        return array_pop($this->_errorCallback);
+    }
+    
+    /**
+     * Set a temporary overriding error callback for every package error stack
+     *
+     * Use this to temporarily disable all existing callbacks (can be used
+     * to emulate the @ operator, for instance)
+     * @see PEAR_ERRORSTACK_PUSHANDLOG, PEAR_ERRORSTACK_PUSH, PEAR_ERRORSTACK_LOG
+     * @see staticPopCallback(), pushCallback()
+     * @param string|array $cb
+     * @static
+     */
+    function staticPushCallback($cb)
+    {
+        array_push($GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'], $cb);
+    }
+    
+    /**
+     * Remove a temporary overriding error callback
+     * @see staticPushCallback()
+     * @return array|string|false
+     * @static
+     */
+    function staticPopCallback()
+    {
+        $ret = array_pop($GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK']);
+        if (!is_array($GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'])) {
+            $GLOBALS['_PEAR_ERRORSTACK_OVERRIDE_CALLBACK'] = array();
+        }
+        return $ret;
+    }
+    
+    /**
+     * Add an error to the stack
+     * 
+     * If the message generator exists, it is called with 2 parameters.
+     *  - the current Error Stack object
+     *  - an array that is in the same format as an error.  Available indices
+     *    are 'code', 'package', 'time', 'params', 'level', and 'context'
+     * 
+     * Next, if the error should contain context information, this is
+     * handled by the context grabbing method.
+     * Finally, the error is pushed onto the proper error stack
+     * @param int    $code      Package-specific error code
+     * @param string $level     Error level.  This is NOT spell-checked
+     * @param array  $params    associative array of error parameters
+     * @param string $msg       Error message, or a portion of it if the message
+     *                          is to be generated
+     * @param array  $repackage If this error re-packages an error pushed by
+     *                          another package, place the array returned from
+     *                          {@link pop()} in this parameter
+     * @param array  $backtrace Protected parameter: use this to pass in the
+     *                          {@link debug_backtrace()} that should be used
+     *                          to find error context
+     * @return PEAR_Error|array if compatibility mode is on, a PEAR_Error is also
+     * thrown.  If a PEAR_Error is returned, the userinfo
+     * property is set to the following array:
+     * 
+     * <code>
+     * array(
+     *    'code' => $code,
+     *    'params' => $params,
+     *    'package' => $this->_package,
+     *    'level' => $level,
+     *    'time' => time(),
+     *    'context' => $context,
+     *    'message' => $msg,
+     * //['repackage' => $err] repackaged error array/Exception class
+     * );
+     * </code>
+     * 
+     * Normally, the previous array is returned.
+     */
+    function push($code, $level = 'error', $params = array(), $msg = false,
+                  $repackage = false, $backtrace = false)
+    {
+        $context = false;
+        // grab error context
+        if ($this->_contextCallback) {
+            if (!$backtrace) {
+                $backtrace = debug_backtrace();
+            }
+            $context = call_user_func($this->_contextCallback, $code, $params, $backtrace);
+        }
+        
+        // save error
+        $time = explode(' ', microtime());
+        $time = $time[1] + $time[0];
+        $err = array(
+                'code' => $code,
+                'params' => $params,
+                'package' => $this->_package,
+                'level' => $level,
+                'time' => $time,
+                'context' => $context,
+                'message' => $msg,
+               );
+
+        if ($repackage) {
+            $err['repackage'] = $repackage;
+        }
+
+        // set up the error message, if necessary
+        if ($this->_msgCallback) {
+            $msg = call_user_func_array($this->_msgCallback,
+                                        array(&$this, $err));
+            $err['message'] = $msg;
+        }        
+        $push = $log = true;
+        $die = false;
+        // try the overriding callback first
+        $callback = $this->staticPopCallback();
+        if ($callback) {
+            $this->staticPushCallback($callback);
+        }
+        if (!is_callable($callback)) {
+            // try the local callback next
+            $callback = $this->popCallback();
+            if (is_callable($callback)) {
+                $this->pushCallback($callback);
+            } else {
+                // try the default callback
+                $callback = isset($GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'][$this->_package]) ?
+                    $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK'][$this->_package] :
+                    $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_CALLBACK']['*'];
+            }
+        }
+        if (is_callable($callback)) {
+            switch(call_user_func($callback, $err)){
+            	case PEAR_ERRORSTACK_IGNORE: 
+            		return $err;
+        		break;
+            	case PEAR_ERRORSTACK_PUSH: 
+            		$log = false;
+        		break;
+            	case PEAR_ERRORSTACK_LOG: 
+            		$push = false;
+        		break;
+            	case PEAR_ERRORSTACK_DIE: 
+            		$die = true;
+        		break;
+                // anything else returned has the same effect as pushandlog
+            }
+        }
+        if ($push) {
+            array_unshift($this->_errors, $err);
+            if (!isset($this->_errorsByLevel[$err['level']])) {
+                $this->_errorsByLevel[$err['level']] = array();
+            }
+            $this->_errorsByLevel[$err['level']][] = &$this->_errors[0];
+        }
+        if ($log) {
+            if ($this->_logger || $GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER']) {
+                $this->_log($err);
+            }
+        }
+        if ($die) {
+            die();
+        }
+        if ($this->_compat && $push) {
+            return $this->raiseError($msg, $code, null, null, $err);
+        }
+        return $err;
+    }
+    
+    /**
+     * Static version of {@link push()}
+     * 
+     * @param string $package   Package name this error belongs to
+     * @param int    $code      Package-specific error code
+     * @param string $level     Error level.  This is NOT spell-checked
+     * @param array  $params    associative array of error parameters
+     * @param string $msg       Error message, or a portion of it if the message
+     *                          is to be generated
+     * @param array  $repackage If this error re-packages an error pushed by
+     *                          another package, place the array returned from
+     *                          {@link pop()} in this parameter
+     * @param array  $backtrace Protected parameter: use this to pass in the
+     *                          {@link debug_backtrace()} that should be used
+     *                          to find error context
+     * @return PEAR_Error|array if compatibility mode is on, a PEAR_Error is also
+     *                          thrown.  see docs for {@link push()}
+     * @static
+     */
+    function staticPush($package, $code, $level = 'error', $params = array(),
+                        $msg = false, $repackage = false, $backtrace = false)
+    {
+        $s = &PEAR_ErrorStack::singleton($package);
+        if ($s->_contextCallback) {
+            if (!$backtrace) {
+                if (function_exists('debug_backtrace')) {
+                    $backtrace = debug_backtrace();
+                }
+            }
+        }
+        return $s->push($code, $level, $params, $msg, $repackage, $backtrace);
+    }
+    
+    /**
+     * Log an error using PEAR::Log
+     * @param array $err Error array
+     * @param array $levels Error level => Log constant map
+     * @access protected
+     */
+    function _log($err)
+    {
+        if ($this->_logger) {
+            $logger = &$this->_logger;
+        } else {
+            $logger = &$GLOBALS['_PEAR_ERRORSTACK_DEFAULT_LOGGER'];
+        }
+        if (is_a($logger, 'Log')) {
+            $levels = array(
+                'exception' => PEAR_LOG_CRIT,
+                'alert' => PEAR_LOG_ALERT,
+                'critical' => PEAR_LOG_CRIT,
+                'error' => PEAR_LOG_ERR,
+                'warning' => PEAR_LOG_WARNING,
+                'notice' => PEAR_LOG_NOTICE,
+                'info' => PEAR_LOG_INFO,
+                'debug' => PEAR_LOG_DEBUG);
+            if (isset($levels[$err['level']])) {
+                $level = $levels[$err['level']];
+            } else {
+                $level = PEAR_LOG_INFO;
+            }
+            $logger->log($err['message'], $level, $err);
+        } else { // support non-standard logs
+            call_user_func($logger, $err);
+        }
+    }
+
+    
+    /**
+     * Pop an error off of the error stack
+     * 
+     * @return false|array
+     * @since 0.4alpha it is no longer possible to specify a specific error
+     * level to return - the last error pushed will be returned, instead
+     */
+    function pop()
+    {
+        $err = @array_shift($this->_errors);
+        if (!is_null($err)) {
+            @array_pop($this->_errorsByLevel[$err['level']]);
+            if (!count($this->_errorsByLevel[$err['level']])) {
+                unset($this->_errorsByLevel[$err['level']]);
+            }
+        }
+        return $err;
+    }
+
+    /**
+     * Pop an error off of the error stack, static method
+     *
+     * @param string package name
+     * @return boolean
+     * @since PEAR1.5.0a1
+     */
+    function staticPop($package)
+    {
+        if ($package) {
+            if (!isset($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package])) {
+                return false;
+            }
+            return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package]->pop();
+        }
+    }
+
+    /**
+     * Determine whether there are any errors on the stack
+     * @param string|array Level name.  Use to determine if any errors
+     * of level (string), or levels (array) have been pushed
+     * @return boolean
+     */
+    function hasErrors($level = false)
+    {
+        if ($level) {
+            return isset($this->_errorsByLevel[$level]);
+        }
+        return count($this->_errors);
+    }
+    
+    /**
+     * Retrieve all errors since last purge
+     * 
+     * @param boolean set in order to empty the error stack
+     * @param string level name, to return only errors of a particular severity
+     * @return array
+     */
+    function getErrors($purge = false, $level = false)
+    {
+        if (!$purge) {
+            if ($level) {
+                if (!isset($this->_errorsByLevel[$level])) {
+                    return array();
+                } else {
+                    return $this->_errorsByLevel[$level];
+                }
+            } else {
+                return $this->_errors;
+            }
+        }
+        if ($level) {
+            $ret = $this->_errorsByLevel[$level];
+            foreach ($this->_errorsByLevel[$level] as $i => $unused) {
+                // entries are references to the $_errors array
+                $this->_errorsByLevel[$level][$i] = false;
+            }
+            // array_filter removes all entries === false
+            $this->_errors = array_filter($this->_errors);
+            unset($this->_errorsByLevel[$level]);
+            return $ret;
+        }
+        $ret = $this->_errors;
+        $this->_errors = array();
+        $this->_errorsByLevel = array();
+        return $ret;
+    }
+    
+    /**
+     * Determine whether there are any errors on a single error stack, or on any error stack
+     *
+     * The optional parameter can be used to test the existence of any errors without the need of
+     * singleton instantiation
+     * @param string|false Package name to check for errors
+     * @param string Level name to check for a particular severity
+     * @return boolean
+     * @static
+     */
+    function staticHasErrors($package = false, $level = false)
+    {
+        if ($package) {
+            if (!isset($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package])) {
+                return false;
+            }
+            return $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package]->hasErrors($level);
+        }
+        foreach ($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'] as $package => $obj) {
+            if ($obj->hasErrors($level)) {
+                return true;
+            }
+        }
+        return false;
+    }
+    
+    /**
+     * Get a list of all errors since last purge, organized by package
+     * @since PEAR 1.4.0dev BC break! $level is now in the place $merge used to be
+     * @param boolean $purge Set to purge the error stack of existing errors
+     * @param string  $level Set to a level name in order to retrieve only errors of a particular level
+     * @param boolean $merge Set to return a flat array, not organized by package
+     * @param array   $sortfunc Function used to sort a merged array - default
+     *        sorts by time, and should be good for most cases
+     * @static
+     * @return array 
+     */
+    function staticGetErrors($purge = false, $level = false, $merge = false,
+                             $sortfunc = array('PEAR_ErrorStack', '_sortErrors'))
+    {
+        $ret = array();
+        if (!is_callable($sortfunc)) {
+            $sortfunc = array('PEAR_ErrorStack', '_sortErrors');
+        }
+        foreach ($GLOBALS['_PEAR_ERRORSTACK_SINGLETON'] as $package => $obj) {
+            $test = $GLOBALS['_PEAR_ERRORSTACK_SINGLETON'][$package]->getErrors($purge, $level);
+            if ($test) {
+                if ($merge) {
+                    $ret = array_merge($ret, $test);
+                } else {
+                    $ret[$package] = $test;
+                }
+            }
+        }
+        if ($merge) {
+            usort($ret, $sortfunc);
+        }
+        return $ret;
+    }
+    
+    /**
+     * Error sorting function, sorts by time
+     * @access private
+     */
+    function _sortErrors($a, $b)
+    {
+        if ($a['time'] == $b['time']) {
+            return 0;
+        }
+        if ($a['time'] < $b['time']) {
+            return 1;
+        }
+        return -1;
+    }
+
+    /**
+     * Standard file/line number/function/class context callback
+     *
+     * This function uses a backtrace generated from {@link debug_backtrace()}
+     * and so will not work at all in PHP < 4.3.0.  The frame should
+     * reference the frame that contains the source of the error.
+     * @return array|false either array('file' => file, 'line' => line,
+     *         'function' => function name, 'class' => class name) or
+     *         if this doesn't work, then false
+     * @param unused
+     * @param integer backtrace frame.
+     * @param array Results of debug_backtrace()
+     * @static
+     */
+    function getFileLine($code, $params, $backtrace = null)
+    {
+        if ($backtrace === null) {
+            return false;
+        }
+        $frame = 0;
+        $functionframe = 1;
+        if (!isset($backtrace[1])) {
+            $functionframe = 0;
+        } else {
+            while (isset($backtrace[$functionframe]['function']) &&
+                  $backtrace[$functionframe]['function'] == 'eval' &&
+                  isset($backtrace[$functionframe + 1])) {
+                $functionframe++;
+            }
+        }
+        if (isset($backtrace[$frame])) {
+            if (!isset($backtrace[$frame]['file'])) {
+                $frame++;
+            }
+            $funcbacktrace = $backtrace[$functionframe];
+            $filebacktrace = $backtrace[$frame];
+            $ret = array('file' => $filebacktrace['file'],
+                         'line' => $filebacktrace['line']);
+            // rearrange for eval'd code or create function errors
+            if (strpos($filebacktrace['file'], '(') && 
+            	  preg_match(';^(.*?)\((\d+)\) : (.*?)\\z;', $filebacktrace['file'],
+                  $matches)) {
+                $ret['file'] = $matches[1];
+                $ret['line'] = $matches[2] + 0;
+            }
+            if (isset($funcbacktrace['function']) && isset($backtrace[1])) {
+                if ($funcbacktrace['function'] != 'eval') {
+                    if ($funcbacktrace['function'] == '__lambda_func') {
+                        $ret['function'] = 'create_function() code';
+                    } else {
+                        $ret['function'] = $funcbacktrace['function'];
+                    }
+                }
+            }
+            if (isset($funcbacktrace['class']) && isset($backtrace[1])) {
+                $ret['class'] = $funcbacktrace['class'];
+            }
+            return $ret;
+        }
+        return false;
+    }
+    
+    /**
+     * Standard error message generation callback
+     * 
+     * This method may also be called by a custom error message generator
+     * to fill in template values from the params array, simply
+     * set the third parameter to the error message template string to use
+     * 
+     * The special variable %__msg% is reserved: use it only to specify
+     * where a message passed in by the user should be placed in the template,
+     * like so:
+     * 
+     * Error message: %msg% - internal error
+     * 
+     * If the message passed like so:
+     * 
+     * <code>
+     * $stack->push(ERROR_CODE, 'error', array(), 'server error 500');
+     * </code>
+     * 
+     * The returned error message will be "Error message: server error 500 -
+     * internal error"
+     * @param PEAR_ErrorStack
+     * @param array
+     * @param string|false Pre-generated error message template
+     * @static
+     * @return string
+     */
+    function getErrorMessage(&$stack, $err, $template = false)
+    {
+        if ($template) {
+            $mainmsg = $template;
+        } else {
+            $mainmsg = $stack->getErrorMessageTemplate($err['code']);
+        }
+        $mainmsg = str_replace('%__msg%', $err['message'], $mainmsg);
+        if (is_array($err['params']) && count($err['params'])) {
+            foreach ($err['params'] as $name => $val) {
+                if (is_array($val)) {
+                    // @ is needed in case $val is a multi-dimensional array
+                    $val = @implode(', ', $val);
+                }
+                if (is_object($val)) {
+                    if (method_exists($val, '__toString')) {
+                        $val = $val->__toString();
+                    } else {
+                        PEAR_ErrorStack::staticPush('PEAR_ErrorStack', PEAR_ERRORSTACK_ERR_OBJTOSTRING,
+                            'warning', array('obj' => get_class($val)),
+                            'object %obj% passed into getErrorMessage, but has no __toString() method');
+                        $val = 'Object';
+                    }
+                }
+                $mainmsg = str_replace('%' . $name . '%', $val, $mainmsg);
+            }
+        }
+        return $mainmsg;
+    }
+    
+    /**
+     * Standard Error Message Template generator from code
+     * @return string
+     */
+    function getErrorMessageTemplate($code)
+    {
+        if (!isset($this->_errorMsgs[$code])) {
+            return '%__msg%';
+        }
+        return $this->_errorMsgs[$code];
+    }
+    
+    /**
+     * Set the Error Message Template array
+     * 
+     * The array format must be:
+     * <pre>
+     * array(error code => 'message template',...)
+     * </pre>
+     * 
+     * Error message parameters passed into {@link push()} will be used as input
+     * for the error message.  If the template is 'message %foo% was %bar%', and the
+     * parameters are array('foo' => 'one', 'bar' => 'six'), the error message returned will
+     * be 'message one was six'
+     * @return string
+     */
+    function setErrorMessageTemplate($template)
+    {
+        $this->_errorMsgs = $template;
+    }
+    
+    
+    /**
+     * emulate PEAR::raiseError()
+     * 
+     * @return PEAR_Error
+     */
+    function raiseError()
+    {
+        require_once 'phar://install-pear-nozlib.phar/' . 'PEAR.php';
+        $args = func_get_args();
+        return call_user_func_array(array('PEAR', 'raiseError'), $args);
+    }
+}
+$stack = &PEAR_ErrorStack::singleton('PEAR_ErrorStack');
+$stack->pushCallback(array('PEAR_ErrorStack', '_handleError'));
+?>
+<?php
+/**
+ * PEAR_Frontend, the singleton-based frontend for user input/output
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Frontend.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * Include error handling
+ */
+//require_once 'PEAR.php';
+
+/**
+ * Which user interface class is being used.
+ * @var string class name
+ */
+$GLOBALS['_PEAR_FRONTEND_CLASS'] = 'PEAR_Frontend_CLI';
+
+/**
+ * Instance of $_PEAR_Command_uiclass.
+ * @var object
+ */
+$GLOBALS['_PEAR_FRONTEND_SINGLETON'] = null;
+
+/**
+ * Singleton-based frontend for PEAR user input/output
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Frontend extends PEAR
+{
+    /**
+     * Retrieve the frontend object
+     * @return PEAR_Frontend_CLI|PEAR_Frontend_Web|PEAR_Frontend_Gtk
+     * @static
+     */
+    function &singleton($type = null)
+    {
+        if ($type === null) {
+            if (!isset($GLOBALS['_PEAR_FRONTEND_SINGLETON'])) {
+                $a = false;
+                return $a;
+            }
+            return $GLOBALS['_PEAR_FRONTEND_SINGLETON'];
+        }
+
+        $a = PEAR_Frontend::setFrontendClass($type);
+        return $a;
+    }
+
+    /**
+     * Set the frontend class that will be used by calls to {@link singleton()}
+     *
+     * Frontends are expected to conform to the PEAR naming standard of
+     * _ => DIRECTORY_SEPARATOR (PEAR_Frontend_CLI is in PEAR/Frontend/CLI.php)
+     * @param string $uiclass full class name
+     * @return PEAR_Frontend
+     * @static
+     */
+    function &setFrontendClass($uiclass)
+    {
+        if (is_object($GLOBALS['_PEAR_FRONTEND_SINGLETON']) &&
+              is_a($GLOBALS['_PEAR_FRONTEND_SINGLETON'], $uiclass)) {
+            return $GLOBALS['_PEAR_FRONTEND_SINGLETON'];
+        }
+
+        if (!class_exists($uiclass)) {
+            $file = 'phar://install-pear-nozlib.phar/' . str_replace('_', '/', $uiclass) . '.php';
+            if (PEAR_Frontend::isIncludeable($file)) {
+                include_once $file;
+            }
+        }
+
+        if (class_exists($uiclass)) {
+            $obj = &new $uiclass;
+            // quick test to see if this class implements a few of the most
+            // important frontend methods
+            if (is_a($obj, 'PEAR_Frontend')) {
+                $GLOBALS['_PEAR_FRONTEND_SINGLETON'] = &$obj;
+                $GLOBALS['_PEAR_FRONTEND_CLASS'] = $uiclass;
+                return $obj;
+            }
+
+            $err = PEAR::raiseError("not a frontend class: $uiclass");
+            return $err;
+        }
+
+        $err = PEAR::raiseError("no such class: $uiclass");
+        return $err;
+    }
+
+    /**
+     * Set the frontend class that will be used by calls to {@link singleton()}
+     *
+     * Frontends are expected to be a descendant of PEAR_Frontend
+     * @param PEAR_Frontend
+     * @return PEAR_Frontend
+     * @static
+     */
+    function &setFrontendObject($uiobject)
+    {
+        if (is_object($GLOBALS['_PEAR_FRONTEND_SINGLETON']) &&
+              is_a($GLOBALS['_PEAR_FRONTEND_SINGLETON'], get_class($uiobject))) {
+            return $GLOBALS['_PEAR_FRONTEND_SINGLETON'];
+        }
+
+        if (!is_a($uiobject, 'PEAR_Frontend')) {
+            $err = PEAR::raiseError('not a valid frontend class: (' .
+                get_class($uiobject) . ')');
+            return $err;
+        }
+
+        $GLOBALS['_PEAR_FRONTEND_SINGLETON'] = &$uiobject;
+        $GLOBALS['_PEAR_FRONTEND_CLASS'] = get_class($uiobject);
+        return $uiobject;
+    }
+
+    /**
+     * @param string $path relative or absolute include path
+     * @return boolean
+     * @static
+     */
+    function isIncludeable($path)
+    {
+        if (file_exists($path) && is_readable($path)) {
+            return true;
+        }
+
+        $fp = @fopen($path, 'r', true);
+        if ($fp) {
+            fclose($fp);
+            return true;
+        }
+
+        return false;
+    }
+
+    /**
+     * @param PEAR_Config
+     */
+    function setConfig(&$config)
+    {
+    }
+
+    /**
+     * This can be overridden to allow session-based temporary file management
+     *
+     * By default, all files are deleted at the end of a session.  The web installer
+     * needs to be able to sustain a list over many sessions in order to support
+     * user interaction with install scripts
+     */
+    function addTempFile($file)
+    {
+        $GLOBALS['_PEAR_Common_tempfiles'][] = $file;
+    }
+
+    /**
+     * Log an action
+     *
+     * @param string $msg the message to log
+     * @param boolean $append_crlf
+     * @return boolean true
+     * @abstract
+     */
+    function log($msg, $append_crlf = true)
+    {
+    }
+
+    /**
+     * Run a post-installation script
+     *
+     * @param array $scripts array of post-install scripts
+     * @abstract
+     */
+    function runPostinstallScripts(&$scripts)
+    {
+    }
+
+    /**
+     * Display human-friendly output formatted depending on the
+     * $command parameter.
+     *
+     * This should be able to handle basic output data with no command
+     * @param mixed  $data    data structure containing the information to display
+     * @param string $command command from which this method was called
+     * @abstract
+     */
+    function outputData($data, $command = '_default')
+    {
+    }
+
+    /**
+     * Display a modal form dialog and return the given input
+     *
+     * A frontend that requires multiple requests to retrieve and process
+     * data must take these needs into account, and implement the request
+     * handling code.
+     * @param string $command  command from which this method was called
+     * @param array  $prompts  associative array. keys are the input field names
+     *                         and values are the description
+     * @param array  $types    array of input field types (text, password,
+     *                         etc.) keys have to be the same like in $prompts
+     * @param array  $defaults array of default values. again keys have
+     *                         to be the same like in $prompts.  Do not depend
+     *                         on a default value being set.
+     * @return array input sent by the user
+     * @abstract
+     */
+    function userDialog($command, $prompts, $types = array(), $defaults = array())
+    {
+    }
 }<?php
 /**
  * PEAR_Frontend_CLI
@@ -69299,7 +69908,7 @@ class PEAR_Frontend extends PEAR
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: CLI.php,v 1.76 2009/04/04 00:09:14 dufuz Exp $
+ * @version    CVS: $Id: CLI.php 278236 2009-04-04 00:09:14Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -69316,7 +69925,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Frontend.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -70032,7 +70641,7 @@ class PEAR_Frontend_CLI extends PEAR_Frontend
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Installer.php,v 1.259 2009/04/09 00:55:07 dufuz Exp $
+ * @version    CVS: $Id: Installer.php 287446 2009-08-18 11:45:05Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -70056,7 +70665,7 @@ define('PEAR_INSTALLER_NOBINARY', -240);
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 0.1
  */
@@ -71146,7 +71755,6 @@ class PEAR_Installer extends PEAR_Downloader
      *
      * @return array|PEAR_Error package info if successful
      */
-
     function install($pkgfile, $options = array())
     {
         $this->_options = $options;
@@ -71160,7 +71768,7 @@ class PEAR_Installer extends PEAR_Downloader
         } else {
             $descfile = $pkgfile;
             $tmpdir   = '';
-            $pkg      = &$this->_parsePackageXml($descfile, $tmpdir);
+            $pkg      = $this->_parsePackageXml($descfile, $tmpdir);
             if (PEAR::isError($pkg)) {
                 return $pkg;
             }
@@ -71414,11 +72022,7 @@ class PEAR_Installer extends PEAR_Downloader
         }
 
         $p = &$installregistry->getPackage($pkgname, $channel);
-        if (empty($options['register-only']) && $p) {
-            $dirtree = $p->getDirTree();
-        } else {
-            $dirtree = false;
-        }
+        $dirtree = (empty($options['register-only']) && $p) ? $p->getDirTree() : false;
 
         $pkg->resetFilelist();
         $pkg->setLastInstalledVersion($installregistry->packageInfo($pkg->getPackage(),
@@ -71591,11 +72195,8 @@ class PEAR_Installer extends PEAR_Downloader
             }
 
             $copyto = $this->_prependPath($dest, $packagingroot);
-            if ($copyto != $dest) {
-                $this->log(1, "Installing '$dest' as '$copyto'");
-            } else {
-                $this->log(1, "Installing '$dest'");
-            }
+            $extra  = $copyto != $dest ? " as '$copyto'" : '';
+            $this->log(1, "Installing '$dest'$extra");
 
             $copydir = dirname($copyto);
             // pretty much nothing happens if we are only registering the install
@@ -71624,24 +72225,20 @@ class PEAR_Installer extends PEAR_Downloader
                 }
             }
 
+
+            $data = array(
+                'role'         => $role,
+                'name'         => $bn,
+                'installed_as' => $dest,
+                'php_api'      => $ext['php_api'],
+                'zend_mod_api' => $ext['zend_mod_api'],
+                'zend_ext_api' => $ext['zend_ext_api'],
+            );
+
             if ($filelist->getPackageXmlVersion() == '1.0') {
-                $filelist->installedFile($bn, array(
-                    'role' => $role,
-                    'name' => $bn,
-                    'installed_as' => $dest,
-                    'php_api' => $ext['php_api'],
-                    'zend_mod_api' => $ext['zend_mod_api'],
-                    'zend_ext_api' => $ext['zend_ext_api'],
-                    ));
+                $filelist->installedFile($bn, $data);
             } else {
-                $filelist->installedFile($bn, array('attribs' => array(
-                    'role' => $role,
-                    'name' => $bn,
-                    'installed_as' => $dest,
-                    'php_api' => $ext['php_api'],
-                    'zend_mod_api' => $ext['zend_mod_api'],
-                    'zend_ext_api' => $ext['zend_ext_api'],
-                    )));
+                $filelist->installedFile($bn, array('attribs' => $data));
             }
         }
     }
@@ -71668,11 +72265,8 @@ class PEAR_Installer extends PEAR_Downloader
      */
     function uninstall($package, $options = array())
     {
-        if (isset($options['installroot'])) {
-            $this->config->setInstallRoot($options['installroot']);
-        } else {
-            $this->config->setInstallRoot('');
-        }
+        $installRoot = isset($options['installroot']) ? $options['installroot'] : '';
+        $this->config->setInstallRoot($installRoot);
 
         $this->installroot = '';
         $this->_registry = &$this->config->getRegistry();
@@ -71765,17 +72359,18 @@ class PEAR_Installer extends PEAR_Downloader
                 }
             } else {
                 $this->startFileTransaction();
-                if ($dirtree = $pkg->getDirTree()) {
-                    // attempt to delete empty directories
-                    uksort($dirtree, array($this, '_sortDirs'));
-                    foreach($dirtree as $dir => $notused) {
-                        $this->addFileOperation('rmdir', array($dir));
-                    }
-                } else {
+                $dirtree = $pkg->getDirTree();
+                if ($dirtree === false) {
                     $this->configSet('default_channel', $savechannel);
                     return $this->_registry->deletePackage($package, $channel);
                 }
 
+                // attempt to delete empty directories
+                uksort($dirtree, array($this, '_sortDirs'));
+                foreach($dirtree as $dir => $notused) {
+                    $this->addFileOperation('rmdir', array($dir));
+                }
+
                 if (!$this->commitFileTransaction()) {
                     $this->rollbackFileTransaction();
                     if (!isset($options['ignore-errors'])) {
@@ -71854,281 +72449,281 @@ class PEAR_Installer extends PEAR_Downloader
     }
 
     // }}}
-}<?php
-/**
- * PEAR_Installer_Role
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Role.php,v 1.22 2009/04/10 19:42:49 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * base class for installer roles
- */
-require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Installer/Role/Common.php';
-require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/XMLParser.php';
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Installer_Role
-{
-    /**
-     * Set up any additional configuration variables that file roles require
-     *
-     * Never call this directly, it is called by the PEAR_Config constructor
-     * @param PEAR_Config
-     * @access private
-     * @static
-     */
-    function initializeConfig(&$config)
-    {
-        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
-            PEAR_Installer_Role::registerRoles();
-        }
-
-        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $class => $info) {
-            if (!$info['config_vars']) {
-                continue;
-            }
-
-            $config->_addConfigVars($class, $info['config_vars']);
-        }
-    }
-
-    /**
-     * @param PEAR_PackageFile_v2
-     * @param string role name
-     * @param PEAR_Config
-     * @return PEAR_Installer_Role_Common
-     * @static
-     */
-    function &factory($pkg, $role, &$config)
-    {
-        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
-            PEAR_Installer_Role::registerRoles();
-        }
-
-        if (!in_array($role, PEAR_Installer_Role::getValidRoles($pkg->getPackageType()))) {
-            $a = false;
-            return $a;
-        }
-
-        $a = 'PEAR_Installer_Role_' . ucfirst($role);
-        if (!class_exists($a)) {
-            require_once 'phar://install-pear-nozlib.phar/' . str_replace('_', '/', $a) . '.php';
-        }
-
-        $b = new $a($config);
-        return $b;
-    }
-
-    /**
-     * Get a list of file roles that are valid for the particular release type.
-     *
-     * For instance, src files serve no purpose in regular php releases.
-     * @param string
-     * @param bool clear cache
-     * @return array
-     * @static
-     */
-    function getValidRoles($release, $clear = false)
-    {
-        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
-            PEAR_Installer_Role::registerRoles();
-        }
-
-        static $ret = array();
-        if ($clear) {
-            $ret = array();
-        }
-
-        if (isset($ret[$release])) {
-            return $ret[$release];
-        }
-
-        $ret[$release] = array();
-        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
-            if (in_array($release, $okreleases['releasetypes'])) {
-                $ret[$release][] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
-            }
-        }
-
-        return $ret[$release];
-    }
-
-    /**
-     * Get a list of roles that require their files to be installed
-     *
-     * Most roles must be installed, but src and package roles, for instance
-     * are pseudo-roles.  src files are compiled into a new extension.  Package
-     * roles are actually fully bundled releases of a package
-     * @param bool clear cache
-     * @return array
-     * @static
-     */
-    function getInstallableRoles($clear = false)
-    {
-        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
-            PEAR_Installer_Role::registerRoles();
-        }
-
-        static $ret;
-        if ($clear) {
-            unset($ret);
-        }
-
-        if (isset($ret)) {
-            return $ret;
-        }
-
-        $ret = array();
-        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
-            if ($okreleases['installable']) {
-                $ret[] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
-            }
-        }
-
-        return $ret;
-    }
-
-    /**
-     * Return an array of roles that are affected by the baseinstalldir attribute
-     *
-     * Most roles ignore this attribute, and instead install directly into:
-     * PackageName/filepath
-     * so a tests file tests/file.phpt is installed into PackageName/tests/filepath.php
-     * @param bool clear cache
-     * @return array
-     * @static
-     */
-    function getBaseinstallRoles($clear = false)
-    {
-        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
-            PEAR_Installer_Role::registerRoles();
-        }
-
-        static $ret;
-        if ($clear) {
-            unset($ret);
-        }
-
-        if (isset($ret)) {
-            return $ret;
-        }
-
-        $ret = array();
-        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
-            if ($okreleases['honorsbaseinstall']) {
-                $ret[] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
-            }
-        }
-
-        return $ret;
-    }
-
-    /**
-     * Return an array of file roles that should be analyzed for PHP content at package time,
-     * like the "php" role.
-     * @param bool clear cache
-     * @return array
-     * @static
-     */
-    function getPhpRoles($clear = false)
-    {
-        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
-            PEAR_Installer_Role::registerRoles();
-        }
-
-        static $ret;
-        if ($clear) {
-            unset($ret);
-        }
-
-        if (isset($ret)) {
-            return $ret;
-        }
-
-        $ret = array();
-        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
-            if ($okreleases['phpfile']) {
-                $ret[] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
-            }
-        }
-
-        return $ret;
-    }
-
-    /**
-     * Scan through the Command directory looking for classes
-     * and see what commands they implement.
-     * @param string which directory to look for classes, defaults to
-     *               the Installer/Roles subdirectory of
-     *               the directory from where this file (__FILE__) is
-     *               included.
-     *
-     * @return bool TRUE on success, a PEAR error on failure
-     * @access public
-     * @static
-     */
-    function registerRoles($dir = null)
-    {
-        $GLOBALS['_PEAR_INSTALLER_ROLES'] = array();
-        $parser = new PEAR_XMLParser;
-        if ($dir === null) {
-            $dir = dirname(__FILE__) . '/Role';
-        }
-
-        if (!file_exists($dir) || !is_dir($dir)) {
-            return PEAR::raiseError("registerRoles: opendir($dir) failed: does not exist/is not directory");
-        }
-
-        $dp = @opendir($dir);
-        if (empty($dp)) {
-            return PEAR::raiseError("registerRoles: opendir($dir) failed: $php_errmsg");
-        }
-
-        while ($entry = readdir($dp)) {
-            if ($entry{0} == '.' || substr($entry, -4) != '.xml') {
-                continue;
-            }
-
-            $class = "PEAR_Installer_Role_".substr($entry, 0, -4);
-            // List of roles
-            if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'][$class])) {
-                $file = "$dir/$entry";
-                $parser->parse(file_get_contents($file));
-                $data = $parser->getData();
-                if (!is_array($data['releasetypes'])) {
-                    $data['releasetypes'] = array($data['releasetypes']);
-                }
-
-                $GLOBALS['_PEAR_INSTALLER_ROLES'][$class] = $data;
-            }
-        }
-
-        closedir($dp);
-        ksort($GLOBALS['_PEAR_INSTALLER_ROLES']);
-        PEAR_Installer_Role::getBaseinstallRoles(true);
-        PEAR_Installer_Role::getInstallableRoles(true);
-        PEAR_Installer_Role::getPhpRoles(true);
-        PEAR_Installer_Role::getValidRoles('****', true);
-        return true;
-    }
+}<?php
+/**
+ * PEAR_Installer_Role
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Role.php 278552 2009-04-10 19:42:49Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * base class for installer roles
+ */
+require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Installer/Role/Common.php';
+require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/XMLParser.php';
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Installer_Role
+{
+    /**
+     * Set up any additional configuration variables that file roles require
+     *
+     * Never call this directly, it is called by the PEAR_Config constructor
+     * @param PEAR_Config
+     * @access private
+     * @static
+     */
+    function initializeConfig(&$config)
+    {
+        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
+            PEAR_Installer_Role::registerRoles();
+        }
+
+        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $class => $info) {
+            if (!$info['config_vars']) {
+                continue;
+            }
+
+            $config->_addConfigVars($class, $info['config_vars']);
+        }
+    }
+
+    /**
+     * @param PEAR_PackageFile_v2
+     * @param string role name
+     * @param PEAR_Config
+     * @return PEAR_Installer_Role_Common
+     * @static
+     */
+    function &factory($pkg, $role, &$config)
+    {
+        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
+            PEAR_Installer_Role::registerRoles();
+        }
+
+        if (!in_array($role, PEAR_Installer_Role::getValidRoles($pkg->getPackageType()))) {
+            $a = false;
+            return $a;
+        }
+
+        $a = 'PEAR_Installer_Role_' . ucfirst($role);
+        if (!class_exists($a)) {
+            require_once 'phar://install-pear-nozlib.phar/' . str_replace('_', '/', $a) . '.php';
+        }
+
+        $b = new $a($config);
+        return $b;
+    }
+
+    /**
+     * Get a list of file roles that are valid for the particular release type.
+     *
+     * For instance, src files serve no purpose in regular php releases.
+     * @param string
+     * @param bool clear cache
+     * @return array
+     * @static
+     */
+    function getValidRoles($release, $clear = false)
+    {
+        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
+            PEAR_Installer_Role::registerRoles();
+        }
+
+        static $ret = array();
+        if ($clear) {
+            $ret = array();
+        }
+
+        if (isset($ret[$release])) {
+            return $ret[$release];
+        }
+
+        $ret[$release] = array();
+        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
+            if (in_array($release, $okreleases['releasetypes'])) {
+                $ret[$release][] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
+            }
+        }
+
+        return $ret[$release];
+    }
+
+    /**
+     * Get a list of roles that require their files to be installed
+     *
+     * Most roles must be installed, but src and package roles, for instance
+     * are pseudo-roles.  src files are compiled into a new extension.  Package
+     * roles are actually fully bundled releases of a package
+     * @param bool clear cache
+     * @return array
+     * @static
+     */
+    function getInstallableRoles($clear = false)
+    {
+        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
+            PEAR_Installer_Role::registerRoles();
+        }
+
+        static $ret;
+        if ($clear) {
+            unset($ret);
+        }
+
+        if (isset($ret)) {
+            return $ret;
+        }
+
+        $ret = array();
+        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
+            if ($okreleases['installable']) {
+                $ret[] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
+            }
+        }
+
+        return $ret;
+    }
+
+    /**
+     * Return an array of roles that are affected by the baseinstalldir attribute
+     *
+     * Most roles ignore this attribute, and instead install directly into:
+     * PackageName/filepath
+     * so a tests file tests/file.phpt is installed into PackageName/tests/filepath.php
+     * @param bool clear cache
+     * @return array
+     * @static
+     */
+    function getBaseinstallRoles($clear = false)
+    {
+        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
+            PEAR_Installer_Role::registerRoles();
+        }
+
+        static $ret;
+        if ($clear) {
+            unset($ret);
+        }
+
+        if (isset($ret)) {
+            return $ret;
+        }
+
+        $ret = array();
+        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
+            if ($okreleases['honorsbaseinstall']) {
+                $ret[] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
+            }
+        }
+
+        return $ret;
+    }
+
+    /**
+     * Return an array of file roles that should be analyzed for PHP content at package time,
+     * like the "php" role.
+     * @param bool clear cache
+     * @return array
+     * @static
+     */
+    function getPhpRoles($clear = false)
+    {
+        if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'])) {
+            PEAR_Installer_Role::registerRoles();
+        }
+
+        static $ret;
+        if ($clear) {
+            unset($ret);
+        }
+
+        if (isset($ret)) {
+            return $ret;
+        }
+
+        $ret = array();
+        foreach ($GLOBALS['_PEAR_INSTALLER_ROLES'] as $role => $okreleases) {
+            if ($okreleases['phpfile']) {
+                $ret[] = strtolower(str_replace('PEAR_Installer_Role_', '', $role));
+            }
+        }
+
+        return $ret;
+    }
+
+    /**
+     * Scan through the Command directory looking for classes
+     * and see what commands they implement.
+     * @param string which directory to look for classes, defaults to
+     *               the Installer/Roles subdirectory of
+     *               the directory from where this file (__FILE__) is
+     *               included.
+     *
+     * @return bool TRUE on success, a PEAR error on failure
+     * @access public
+     * @static
+     */
+    function registerRoles($dir = null)
+    {
+        $GLOBALS['_PEAR_INSTALLER_ROLES'] = array();
+        $parser = new PEAR_XMLParser;
+        if ($dir === null) {
+            $dir = dirname(__FILE__) . '/Role';
+        }
+
+        if (!file_exists($dir) || !is_dir($dir)) {
+            return PEAR::raiseError("registerRoles: opendir($dir) failed: does not exist/is not directory");
+        }
+
+        $dp = @opendir($dir);
+        if (empty($dp)) {
+            return PEAR::raiseError("registerRoles: opendir($dir) failed: $php_errmsg");
+        }
+
+        while ($entry = readdir($dp)) {
+            if ($entry{0} == '.' || substr($entry, -4) != '.xml') {
+                continue;
+            }
+
+            $class = "PEAR_Installer_Role_".substr($entry, 0, -4);
+            // List of roles
+            if (!isset($GLOBALS['_PEAR_INSTALLER_ROLES'][$class])) {
+                $file = "$dir/$entry";
+                $parser->parse(file_get_contents($file));
+                $data = $parser->getData();
+                if (!is_array($data['releasetypes'])) {
+                    $data['releasetypes'] = array($data['releasetypes']);
+                }
+
+                $GLOBALS['_PEAR_INSTALLER_ROLES'][$class] = $data;
+            }
+        }
+
+        closedir($dp);
+        ksort($GLOBALS['_PEAR_INSTALLER_ROLES']);
+        PEAR_Installer_Role::getBaseinstallRoles(true);
+        PEAR_Installer_Role::getInstallableRoles(true);
+        PEAR_Installer_Role::getPhpRoles(true);
+        PEAR_Installer_Role::getValidRoles('****', true);
+        return true;
+    }
 }<?php
 /**
  * Base class for all installation roles.
@@ -72140,7 +72735,7 @@ class PEAR_Installer_Role
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2006 The PHP Group
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Common.php,v 1.13 2009/02/24 23:39:37 dufuz Exp $
+ * @version    CVS: $Id: Common.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -72155,7 +72750,7 @@ class PEAR_Installer_Role
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2006 The PHP Group
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -72302,33 +72897,33 @@ class PEAR_Installer_Role_Common
         return $roleInfo['phpextension'];
     }
 }
-?><?php
-/**
- * PEAR_Installer_Role_Data
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Data.php,v 1.8 2009/02/24 23:39:37 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Installer_Role_Data extends PEAR_Installer_Role_Common {}
+?><?php
+/**
+ * PEAR_Installer_Role_Data
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Data.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Installer_Role_Data extends PEAR_Installer_Role_Common {}
 ?><role version="1.0">
  <releasetypes>php</releasetypes>
  <releasetypes>extsrc</releasetypes>
@@ -72343,33 +72938,33 @@ class PEAR_Installer_Role_Data extends PEAR_Installer_Role_Common {}
  <executable />
  <phpextension />
  <config_vars />
-</role><?php
-/**
- * PEAR_Installer_Role_Doc
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Doc.php,v 1.8 2009/02/24 23:39:37 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Installer_Role_Doc extends PEAR_Installer_Role_Common {}
+</role><?php
+/**
+ * PEAR_Installer_Role_Doc
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Doc.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Installer_Role_Doc extends PEAR_Installer_Role_Common {}
 ?><role version="1.0">
  <releasetypes>php</releasetypes>
  <releasetypes>extsrc</releasetypes>
@@ -72384,33 +72979,33 @@ class PEAR_Installer_Role_Doc extends PEAR_Installer_Role_Common {}
  <executable />
  <phpextension />
  <config_vars />
-</role><?php
-/**
- * PEAR_Installer_Role_Php
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Php.php,v 1.9 2009/02/24 23:39:37 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Installer_Role_Php extends PEAR_Installer_Role_Common {}
+</role><?php
+/**
+ * PEAR_Installer_Role_Php
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Php.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Installer_Role_Php extends PEAR_Installer_Role_Common {}
 ?><role version="1.0">
  <releasetypes>php</releasetypes>
  <releasetypes>extsrc</releasetypes>
@@ -72425,33 +73020,33 @@ class PEAR_Installer_Role_Php extends PEAR_Installer_Role_Common {}
  <executable />
  <phpextension />
  <config_vars />
-</role><?php
-/**
- * PEAR_Installer_Role_Script
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Script.php,v 1.8 2009/02/24 23:39:37 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Installer_Role_Script extends PEAR_Installer_Role_Common {}
+</role><?php
+/**
+ * PEAR_Installer_Role_Script
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Script.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Installer_Role_Script extends PEAR_Installer_Role_Common {}
 ?><role version="1.0">
  <releasetypes>php</releasetypes>
  <releasetypes>extsrc</releasetypes>
@@ -72466,33 +73061,33 @@ class PEAR_Installer_Role_Script extends PEAR_Installer_Role_Common {}
  <executable>1</executable>
  <phpextension />
  <config_vars />
-</role><?php
-/**
- * PEAR_Installer_Role_Test
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Test.php,v 1.8 2009/02/24 23:39:37 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-
-/**
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Installer_Role_Test extends PEAR_Installer_Role_Common {}
+</role><?php
+/**
+ * PEAR_Installer_Role_Test
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Test.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+
+/**
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Installer_Role_Test extends PEAR_Installer_Role_Common {}
 ?><role version="1.0">
  <releasetypes>php</releasetypes>
  <releasetypes>extsrc</releasetypes>
@@ -72518,7 +73113,7 @@ class PEAR_Installer_Role_Test extends PEAR_Installer_Role_Common {}
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: PackageFile.php,v 1.48 2009/04/09 22:16:26 dufuz Exp $
+ * @version    CVS: $Id: PackageFile.php 286670 2009-08-02 14:16:06Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -72544,7 +73139,7 @@ define('PEAR_PACKAGEFILE_ERROR_INVALID_PACKAGEVERSION', 2);
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -72714,9 +73309,10 @@ class PEAR_PackageFile
                 return $pf;
             }
 
-            if (!$pf->validate($state)) {
+            if (!$pf->validate($state)) {;
                 if ($this->_config->get('verbose') > 0
-                    && $this->_logger && $pf->getValidationWarnings(false)) {
+                    && $this->_logger && $pf->getValidationWarnings(false)
+                ) {
                     foreach ($pf->getValidationWarnings(false) as $warning) {
                         $this->_logger->log(0, 'ERROR: ' . $warning['message']);
                     }
@@ -72832,11 +73428,11 @@ class PEAR_PackageFile
             $ret = PEAR::raiseError("Could not get contents of package \"$file\"".
                                      '. Invalid tgz file.');
             return $ret;
-        } else {
-            if (!count($content) && !@is_file($file)) {
-                $ret = PEAR::raiseError("could not open file \"$file\"");
-                return $ret;
-            }
+        }
+
+        if (!count($content) && !@is_file($file)) {
+            $ret = PEAR::raiseError("could not open file \"$file\"");
+            return $ret;
         }
 
         $xml      = null;
@@ -73017,7 +73613,7 @@ class PEAR_PackageFile
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: v1.php,v 1.76 2009/02/24 23:45:26 dufuz Exp $
+ * @version    CVS: $Id: v1.php 286494 2009-07-29 06:57:11Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -73037,7 +73633,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/PackageFile/v2.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -73054,7 +73650,7 @@ class PEAR_PackageFile_Generator_v1
 
     function getPackagerVersion()
     {
-        return '1.8.0';
+        return '1.9.0';
     }
 
     /**
@@ -73208,7 +73804,7 @@ class PEAR_PackageFile_Generator_v1
             );
         $ret = "<?xml version=\"1.0\" encoding=\"UTF-8\" ?>\n";
         $ret .= "<!DOCTYPE package SYSTEM \"http://pear.php.net/dtd/package-1.0\">\n";
-        $ret .= "<package version=\"1.0\" packagerversion=\"1.8.0\">\n" .
+        $ret .= "<package version=\"1.0\" packagerversion=\"1.9.0\">\n" .
 " <name>$pkginfo[package]</name>";
         if (isset($pkginfo['extends'])) {
             $ret .= "\n<extends>$pkginfo[extends]</extends>";
@@ -74223,16 +74819,15 @@ class PEAR_PackageFile_Generator_v1
      */
     function _processMultipleDepsName($deps)
     {
-        $tests = array();
+        $ret = $tests = array();
         foreach ($deps as $name => $dep) {
             foreach ($dep as $d) {
                 $tests[$name][] = $this->_processDep($d);
             }
         }
+
         foreach ($tests as $name => $test) {
-            $php = array();
-            $min = array();
-            $max = array();
+            $max = $min = $php = array();
             $php['name'] = $name;
             foreach ($test as $dep) {
                 if (!$dep) {
@@ -74302,7 +74897,7 @@ class PEAR_PackageFile_Generator_v1
  * @author     Stephan Schmidt (original XML_Serializer code)
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: v2.php,v 1.51 2009/03/27 17:11:18 dufuz Exp $
+ * @version    CVS: $Id: v2.php 278907 2009-04-17 21:10:04Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -74323,7 +74918,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'XML/Util.php';
  * @author     Stephan Schmidt (original XML_Serializer code)
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -74405,7 +75000,7 @@ http://pear.php.net/dtd/package-2.0.xsd',
      */
     function getPackagerVersion()
     {
-        return '1.8.0';
+        return '1.9.0';
     }
 
     /**
@@ -74669,7 +75264,8 @@ http://pear.php.net/dtd/package-2.0.xsd',
                 $arr['changelog']['release'][0] = $release;
             }
 
-            foreach ($arr['changelog']['release'] as &$c) {
+            foreach (array_keys($arr['changelog']['release']) as $key) {
+                $c =& $arr['changelog']['release'][$key];
                 if (isset($c['notes'])) {
                     // This trims out the indenting, needs fixing
                     $c['notes'] = "\n" . trim($c['notes']) . "\n";
@@ -74689,7 +75285,7 @@ http://pear.php.net/dtd/package-2.0.xsd',
             $this->options['beautifyFilelist'] = true;
         }
 
-        $arr['attribs']['packagerversion'] = '1.8.0';
+        $arr['attribs']['packagerversion'] = '1.9.0';
         if ($this->serialize($arr, $options)) {
             return $this->_serializedData . "\n";
         }
@@ -75163,7 +75759,7 @@ http://pear.php.net/dtd/package-2.0.xsd',
             if ($this->options['encoding'] == 'UTF-8' &&
                   version_compare(phpversion(), '5.0.0', 'lt')
             ) {
-                $tag = utf8_encode($tag);
+                $tag['content'] = utf8_encode($tag['content']);
             }
 
             if ($replaceEntities === true) {
@@ -75192,7 +75788,7 @@ http://pear.php.net/dtd/package-2.0.xsd',
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: v1.php,v 1.30 2009/02/24 23:45:22 dufuz Exp $
+ * @version    CVS: $Id: v1.php 276385 2009-02-24 23:46:03Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -75207,7 +75803,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/PackageFile/v1.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -75650,7 +76246,7 @@ class PEAR_PackageFile_Parser_v1
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: v2.php,v 1.24 2009/02/24 23:45:22 dufuz Exp $
+ * @version    CVS: $Id: v2.php 276385 2009-02-24 23:46:03Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -75666,7 +76262,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/PackageFile/v2.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -75751,1618 +76347,1618 @@ class PEAR_PackageFile_Parser_v2 extends PEAR_XMLParser
         $ret->setPackagefile($file, $archive);
         return $ret;
     }
-}<?php
-/**
- * PEAR_PackageFile_v1, package.xml version 1.0
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: v1.php,v 1.75 2009/02/24 23:39:16 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a1
- */
-/**
- * For error handling
- */
-require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ErrorStack.php';
-
-/**
- * Error code if parsing is attempted with no xml extension
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_XML_EXT', 3);
-
-/**
- * Error code if creating the xml parser resource fails
- */
-define('PEAR_PACKAGEFILE_ERROR_CANT_MAKE_PARSER', 4);
-
-/**
- * Error code used for all sax xml parsing errors
- */
-define('PEAR_PACKAGEFILE_ERROR_PARSER_ERROR', 5);
-
-/**
- * Error code used when there is no name
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_NAME', 6);
-
-/**
- * Error code when a package name is not valid
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_NAME', 7);
-
-/**
- * Error code used when no summary is parsed
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_SUMMARY', 8);
-
-/**
- * Error code for summaries that are more than 1 line
- */
-define('PEAR_PACKAGEFILE_ERROR_MULTILINE_SUMMARY', 9);
-
-/**
- * Error code used when no description is present
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_DESCRIPTION', 10);
-
-/**
- * Error code used when no license is present
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_LICENSE', 11);
-
-/**
- * Error code used when a <version> version number is not present
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_VERSION', 12);
-
-/**
- * Error code used when a <version> version number is invalid
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_VERSION', 13);
-
-/**
- * Error code when release state is missing
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_STATE', 14);
-
-/**
- * Error code when release state is invalid
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_STATE', 15);
-
-/**
- * Error code when release state is missing
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_DATE', 16);
-
-/**
- * Error code when release state is invalid
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_DATE', 17);
-
-/**
- * Error code when no release notes are found
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_NOTES', 18);
-
-/**
- * Error code when no maintainers are found
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_MAINTAINERS', 19);
-
-/**
- * Error code when a maintainer has no handle
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_MAINTHANDLE', 20);
-
-/**
- * Error code when a maintainer has no handle
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_MAINTROLE', 21);
-
-/**
- * Error code when a maintainer has no name
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_MAINTNAME', 22);
-
-/**
- * Error code when a maintainer has no email
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_MAINTEMAIL', 23);
-
-/**
- * Error code when a maintainer has no handle
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_MAINTROLE', 24);
-
-/**
- * Error code when a dependency is not a PHP dependency, but has no name
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_DEPNAME', 25);
-
-/**
- * Error code when a dependency has no type (pkg, php, etc.)
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_DEPTYPE', 26);
-
-/**
- * Error code when a dependency has no relation (lt, ge, has, etc.)
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_DEPREL', 27);
-
-/**
- * Error code when a dependency is not a 'has' relation, but has no version
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_DEPVERSION', 28);
-
-/**
- * Error code when a dependency has an invalid relation
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPREL', 29);
-
-/**
- * Error code when a dependency has an invalid type
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPTYPE', 30);
-
-/**
- * Error code when a dependency has an invalid optional option
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPOPTIONAL', 31);
-
-/**
- * Error code when a dependency is a pkg dependency, and has an invalid package name
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPNAME', 32);
-
-/**
- * Error code when a dependency has a channel="foo" attribute, and foo is not a registered channel
- */
-define('PEAR_PACKAGEFILE_ERROR_UNKNOWN_DEPCHANNEL', 33);
-
-/**
- * Error code when rel="has" and version attribute is present.
- */
-define('PEAR_PACKAGEFILE_ERROR_DEPVERSION_IGNORED', 34);
-
-/**
- * Error code when type="php" and dependency name is present
- */
-define('PEAR_PACKAGEFILE_ERROR_DEPNAME_IGNORED', 35);
-
-/**
- * Error code when a configure option has no name
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_CONFNAME', 36);
-
-/**
- * Error code when a configure option has no name
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_CONFPROMPT', 37);
-
-/**
- * Error code when a file in the filelist has an invalid role
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_FILEROLE', 38);
-
-/**
- * Error code when a file in the filelist has no role
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_FILEROLE', 39);
-
-/**
- * Error code when analyzing a php source file that has parse errors
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE', 40);
-
-/**
- * Error code when analyzing a php source file reveals a source element
- * without a package name prefix
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX', 41);
-
-/**
- * Error code when an unknown channel is specified
- */
-define('PEAR_PACKAGEFILE_ERROR_UNKNOWN_CHANNEL', 42);
-
-/**
- * Error code when no files are found in the filelist
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_FILES', 43);
-
-/**
- * Error code when a file is not valid php according to _analyzeSourceCode()
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_FILE', 44);
-
-/**
- * Error code when the channel validator returns an error or warning
- */
-define('PEAR_PACKAGEFILE_ERROR_CHANNELVAL', 45);
-
-/**
- * Error code when a php5 package is packaged in php4 (analysis doesn't work)
- */
-define('PEAR_PACKAGEFILE_ERROR_PHP5', 46);
-
-/**
- * Error code when a file is listed in package.xml but does not exist
- */
-define('PEAR_PACKAGEFILE_ERROR_FILE_NOTFOUND', 47);
-
-/**
- * Error code when a <dep type="php" rel="not"... is encountered (use rel="ne")
- */
-define('PEAR_PACKAGEFILE_PHP_NO_NOT', 48);
-
-/**
- * Error code when a package.xml contains non-ISO-8859-1 characters
- */
-define('PEAR_PACKAGEFILE_ERROR_NON_ISO_CHARS', 49);
-
-/**
- * Error code when a dependency is not a 'has' relation, but has no version
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_DEPPHPVERSION', 50);
-
-/**
- * Error code when a package has no lead developer
- */
-define('PEAR_PACKAGEFILE_ERROR_NO_LEAD', 51);
-
-/**
- * Error code when a filename begins with "."
- */
-define('PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME', 52);
-/**
- * package.xml encapsulator
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_PackageFile_v1
-{
-    /**
-     * @access private
-     * @var PEAR_ErrorStack
-     * @access private
-     */
-    var $_stack;
-
-    /**
-     * A registry object, used to access the package name validation regex for non-standard channels
-     * @var PEAR_Registry
-     * @access private
-     */
-    var $_registry;
-
-    /**
-     * An object that contains a log method that matches PEAR_Common::log's signature
-     * @var object
-     * @access private
-     */
-    var $_logger;
-
-    /**
-     * Parsed package information
-     * @var array
-     * @access private
-     */
-    var $_packageInfo;
-
-    /**
-     * path to package.xml
-     * @var string
-     * @access private
-     */
-    var $_packageFile;
-
-    /**
-     * path to package .tgz or false if this is a local/extracted package.xml
-     * @var string
-     * @access private
-     */
-    var $_archiveFile;
-
-    /**
-     * @var int
-     * @access private
-     */
-    var $_isValid = 0;
-
-    /**
-     * Determines whether this packagefile was initialized only with partial package info
-     *
-     * If this package file was constructed via parsing REST, it will only contain
-     *
-     * - package name
-     * - channel name
-     * - dependencies 
-     * @var boolean
-     * @access private
-     */
-    var $_incomplete = true;
-
-    /**
-     * @param bool determines whether to return a PEAR_Error object, or use the PEAR_ErrorStack
-     * @param string Name of Error Stack class to use.
-     */
-    function PEAR_PackageFile_v1()
-    {
-        $this->_stack = &new PEAR_ErrorStack('PEAR_PackageFile_v1');
-        $this->_stack->setErrorMessageTemplate($this->_getErrorMessage());
-        $this->_isValid = 0;
-    }
-
-    function installBinary($installer)
-    {
-        return false;
-    }
-
-    function isExtension($name)
-    {
-        return false;
-    }
-
-    function setConfig(&$config)
-    {
-        $this->_config = &$config;
-        $this->_registry = &$config->getRegistry();
-    }
-
-    function setRequestedGroup()
-    {
-        // placeholder
-    }
-
-    /**
-     * For saving in the registry.
-     *
-     * Set the last version that was installed
-     * @param string
-     */
-    function setLastInstalledVersion($version)
-    {
-        $this->_packageInfo['_lastversion'] = $version;
-    }
-
-    /**
-     * @return string|false
-     */
-    function getLastInstalledVersion()
-    {
-        if (isset($this->_packageInfo['_lastversion'])) {
-            return $this->_packageInfo['_lastversion'];
-        }
-        return false;
-    }
-
-    function getInstalledBinary()
-    {
-        return false;
-    }
-
-    function listPostinstallScripts()
-    {
-        return false;
-    }
-
-    function initPostinstallScripts()
-    {
-        return false;
-    }
-
-    function setLogger(&$logger)
-    {
-        if ($logger && (!is_object($logger) || !method_exists($logger, 'log'))) {
-            return PEAR::raiseError('Logger must be compatible with PEAR_Common::log');
-        }
-        $this->_logger = &$logger;
-    }
-
-    function setPackagefile($file, $archive = false)
-    {
-        $this->_packageFile = $file;
-        $this->_archiveFile = $archive ? $archive : $file;
-    }
-
-    function getPackageFile()
-    {
-        return isset($this->_packageFile) ? $this->_packageFile : false;
-    }
-
-    function getPackageType()
-    {
-        return 'php';
-    }
-
-    function getArchiveFile()
-    {
-        return $this->_archiveFile;
-    }
-
-    function packageInfo($field)
-    {
-        if (!is_string($field) || empty($field) ||
-            !isset($this->_packageInfo[$field])) {
-            return false;
-        }
-        return $this->_packageInfo[$field];
-    }
-
-    function setDirtree($path)
-    {
-        if (!isset($this->_packageInfo['dirtree'])) {
-            $this->_packageInfo['dirtree'] = array();
-        }
-        $this->_packageInfo['dirtree'][$path] = true;
-    }
-
-    function getDirtree()
-    {
-        if (isset($this->_packageInfo['dirtree']) && count($this->_packageInfo['dirtree'])) {
-            return $this->_packageInfo['dirtree'];
-        }
-        return false;
-    }
-
-    function resetDirtree()
-    {
-        unset($this->_packageInfo['dirtree']);
-    }
-
-    function fromArray($pinfo)
-    {
-        $this->_incomplete = false;
-        $this->_packageInfo = $pinfo;
-    }
-
-    function isIncomplete()
-    {
-        return $this->_incomplete;
-    }
-
-    function getChannel()
-    {
-        return 'pear.php.net';
-    }
-
-    function getUri()
-    {
-        return false;
-    }
-
-    function getTime()
-    {
-        return false;
-    }
-
-    function getExtends()
-    {
-        if (isset($this->_packageInfo['extends'])) {
-            return $this->_packageInfo['extends'];
-        }
-        return false;
-    }
-
-    /**
-     * @return array
-     */
-    function toArray()
-    {
-        if (!$this->validate(PEAR_VALIDATE_NORMAL)) {
-            return false;
-        }
-        return $this->getArray();
-    }
-
-    function getArray()
-    {
-        return $this->_packageInfo;
-    }
-
-    function getName()
-    {
-        return $this->getPackage();
-    }
-
-    function getPackage()
-    {
-        if (isset($this->_packageInfo['package'])) {
-            return $this->_packageInfo['package'];
-        }
-        return false;
-    }
-
-    /**
-     * WARNING - don't use this unless you know what you are doing
-     */
-    function setRawPackage($package)
-    {
-        $this->_packageInfo['package'] = $package;
-    }
-
-    function setPackage($package)
-    {
-        $this->_packageInfo['package'] = $package;
-        $this->_isValid = false;
-    }
-
-    function getVersion()
-    {
-        if (isset($this->_packageInfo['version'])) {
-            return $this->_packageInfo['version'];
-        }
-        return false;
-    }
-
-    function setVersion($version)
-    {
-        $this->_packageInfo['version'] = $version;
-        $this->_isValid = false;
-    }
-
-    function clearMaintainers()
-    {
-        unset($this->_packageInfo['maintainers']);
-    }
-
-    function getMaintainers()
-    {
-        if (isset($this->_packageInfo['maintainers'])) {
-            return $this->_packageInfo['maintainers'];
-        }
-        return false;
-    }
-
-    /**
-     * Adds a new maintainer - no checking of duplicates is performed, use
-     * updatemaintainer for that purpose.
-     */
-    function addMaintainer($role, $handle, $name, $email)
-    {
-        $this->_packageInfo['maintainers'][] =
-            array('handle' => $handle, 'role' => $role, 'email' => $email, 'name' => $name);
-        $this->_isValid = false;
-    }
-
-    function updateMaintainer($role, $handle, $name, $email)
-    {
-        $found = false;
-        if (!isset($this->_packageInfo['maintainers']) ||
-              !is_array($this->_packageInfo['maintainers'])) {
-            return $this->addMaintainer($role, $handle, $name, $email);
-        }
-        foreach ($this->_packageInfo['maintainers'] as $i => $maintainer) {
-            if ($maintainer['handle'] == $handle) {
-                $found = $i;
-                break;
-            }
-        }
-        if ($found !== false) {
-            unset($this->_packageInfo['maintainers'][$found]);
-            $this->_packageInfo['maintainers'] =
-                array_values($this->_packageInfo['maintainers']);
-        }
-        $this->addMaintainer($role, $handle, $name, $email);
-    }
-
-    function deleteMaintainer($handle)
-    {
-        $found = false;
-        foreach ($this->_packageInfo['maintainers'] as $i => $maintainer) {
-            if ($maintainer['handle'] == $handle) {
-                $found = $i;
-                break;
-            }
-        }
-        if ($found !== false) {
-            unset($this->_packageInfo['maintainers'][$found]);
-            $this->_packageInfo['maintainers'] =
-                array_values($this->_packageInfo['maintainers']);
-            return true;
-        }
-        return false;
-    }
-
-    function getState()
-    {
-        if (isset($this->_packageInfo['release_state'])) {
-            return $this->_packageInfo['release_state'];
-        }
-        return false;
-    }
-
-    function setRawState($state)
-    {
-        $this->_packageInfo['release_state'] = $state;
-    }
-
-    function setState($state)
-    {
-        $this->_packageInfo['release_state'] = $state;
-        $this->_isValid = false;
-    }
-
-    function getDate()
-    {
-        if (isset($this->_packageInfo['release_date'])) {
-            return $this->_packageInfo['release_date'];
-        }
-        return false;
-    }
-
-    function setDate($date)
-    {
-        $this->_packageInfo['release_date'] = $date;
-        $this->_isValid = false;
-    }
-
-    function getLicense()
-    {
-        if (isset($this->_packageInfo['release_license'])) {
-            return $this->_packageInfo['release_license'];
-        }
-        return false;
-    }
-
-    function setLicense($date)
-    {
-        $this->_packageInfo['release_license'] = $date;
-        $this->_isValid = false;
-    }
-
-    function getSummary()
-    {
-        if (isset($this->_packageInfo['summary'])) {
-            return $this->_packageInfo['summary'];
-        }
-        return false;
-    }
-
-    function setSummary($summary)
-    {
-        $this->_packageInfo['summary'] = $summary;
-        $this->_isValid = false;
-    }
-
-    function getDescription()
-    {
-        if (isset($this->_packageInfo['description'])) {
-            return $this->_packageInfo['description'];
-        }
-        return false;
-    }
-
-    function setDescription($desc)
-    {
-        $this->_packageInfo['description'] = $desc;
-        $this->_isValid = false;
-    }
-
-    function getNotes()
-    {
-        if (isset($this->_packageInfo['release_notes'])) {
-            return $this->_packageInfo['release_notes'];
-        }
-        return false;
-    }
-
-    function setNotes($notes)
-    {
-        $this->_packageInfo['release_notes'] = $notes;
-        $this->_isValid = false;
-    }
-
-    function getDeps()
-    {
-        if (isset($this->_packageInfo['release_deps'])) {
-            return $this->_packageInfo['release_deps'];
-        }
-        return false;
-    }
-
-    /**
-     * Reset dependencies prior to adding new ones
-     */
-    function clearDeps()
-    {
-        unset($this->_packageInfo['release_deps']);
-    }
-
-    function addPhpDep($version, $rel)
-    {
-        $this->_isValid = false;
-        $this->_packageInfo['release_deps'][] =
-            array('type' => 'php',
-                  'rel' => $rel,
-                  'version' => $version);
-    }
-
-    function addPackageDep($name, $version, $rel, $optional = 'no')
-    {
-        $this->_isValid = false;
-        $dep =
-            array('type' => 'pkg',
-                  'name' => $name,
-                  'rel' => $rel,
-                  'optional' => $optional);
-        if ($rel != 'has' && $rel != 'not') {
-            $dep['version'] = $version;
-        }
-        $this->_packageInfo['release_deps'][] = $dep;
-    }
-
-    function addExtensionDep($name, $version, $rel, $optional = 'no')
-    {
-        $this->_isValid = false;
-        $this->_packageInfo['release_deps'][] =
-            array('type' => 'ext',
-                  'name' => $name,
-                  'rel' => $rel,
-                  'version' => $version,
-                  'optional' => $optional);
-    }
-
-    /**
-     * WARNING - do not use this function directly unless you know what you're doing
-     */
-    function setDeps($deps)
-    {
-        $this->_packageInfo['release_deps'] = $deps;
-    }
-
-    function hasDeps()
-    {
-        return isset($this->_packageInfo['release_deps']) &&
-            count($this->_packageInfo['release_deps']);
-    }
-
-    function getDependencyGroup($group)
-    {
-        return false;
-    }
-
-    function isCompatible($pf)
-    {
-        return false;
-    }
-
-    function isSubpackageOf($p)
-    {
-        return $p->isSubpackage($this);
-    }
-
-    function isSubpackage($p)
-    {
-        return false;
-    }
-
-    function dependsOn($package, $channel)
-    {
-        if (strtolower($channel) != 'pear.php.net') {
-            return false;
-        }
-        if (!($deps = $this->getDeps())) {
-            return false;
-        }
-        foreach ($deps as $dep) {
-            if ($dep['type'] != 'pkg') {
-                continue;
-            }
-            if (strtolower($dep['name']) == strtolower($package)) {
-                return true;
-            }
-        }
-        return false;
-    }
-
-    function getConfigureOptions()
-    {
-        if (isset($this->_packageInfo['configure_options'])) {
-            return $this->_packageInfo['configure_options'];
-        }
-        return false;
-    }
-
-    function hasConfigureOptions()
-    {
-        return isset($this->_packageInfo['configure_options']) &&
-            count($this->_packageInfo['configure_options']);
-    }
-
-    function addConfigureOption($name, $prompt, $default = false)
-    {
-        $o = array('name' => $name, 'prompt' => $prompt);
-        if ($default !== false) {
-            $o['default'] = $default;
-        }
-        if (!isset($this->_packageInfo['configure_options'])) {
-            $this->_packageInfo['configure_options'] = array();
-        }
-        $this->_packageInfo['configure_options'][] = $o;
-    }
-
-    function clearConfigureOptions()
-    {
-        unset($this->_packageInfo['configure_options']);
-    }
-
-    function getProvides()
-    {
-        if (isset($this->_packageInfo['provides'])) {
-            return $this->_packageInfo['provides'];
-        }
-        return false;
-    }
-
-    function getProvidesExtension()
-    {
-        return false;
-    }
-
-    function addFile($dir, $file, $attrs)
-    {
-        $dir = preg_replace(array('!\\\\+!', '!/+!'), array('/', '/'), $dir);
-        if ($dir == '/' || $dir == '') {
-            $dir = '';
-        } else {
-            $dir .= '/';
-        }
-        $file = $dir . $file;
-        $file = preg_replace('![\\/]+!', '/', $file);
-        $this->_packageInfo['filelist'][$file] = $attrs;
-    }
-
-    function getInstallationFilelist()
-    {
-        return $this->getFilelist();
-    }
-
-    function getFilelist()
-    {
-        if (isset($this->_packageInfo['filelist'])) {
-            return $this->_packageInfo['filelist'];
-        }
-        return false;
-    }
-
-    function setFileAttribute($file, $attr, $value)
-    {
-        $this->_packageInfo['filelist'][$file][$attr] = $value;
-    }
-
-    function resetFilelist()
-    {
-        $this->_packageInfo['filelist'] = array();
-    }
-
-    function setInstalledAs($file, $path)
-    {
-        if ($path) {
-            return $this->_packageInfo['filelist'][$file]['installed_as'] = $path;
-        }
-        unset($this->_packageInfo['filelist'][$file]['installed_as']);
-    }
-
-    function installedFile($file, $atts)
-    {
-        if (isset($this->_packageInfo['filelist'][$file])) {
-            $this->_packageInfo['filelist'][$file] =
-                array_merge($this->_packageInfo['filelist'][$file], $atts);
-        } else {
-            $this->_packageInfo['filelist'][$file] = $atts;
-        }
-    }
-
-    function getChangelog()
-    {
-        if (isset($this->_packageInfo['changelog'])) {
-            return $this->_packageInfo['changelog'];
-        }
-        return false;
-    }
-
-    function getPackagexmlVersion()
-    {
-        return '1.0';
-    }
-
-    /**
-     * Wrapper to {@link PEAR_ErrorStack::getErrors()}
-     * @param boolean determines whether to purge the error stack after retrieving
-     * @return array
-     */
-    function getValidationWarnings($purge = true)
-    {
-        return $this->_stack->getErrors($purge);
-    }
-
-    // }}}
-    /**
-     * Validation error.  Also marks the object contents as invalid
-     * @param error code
-     * @param array error information
-     * @access private
-     */
-    function _validateError($code, $params = array())
-    {
-        $this->_stack->push($code, 'error', $params, false, false, debug_backtrace());
-        $this->_isValid = false;
-    }
-
-    /**
-     * Validation warning.  Does not mark the object contents invalid.
-     * @param error code
-     * @param array error information
-     * @access private
-     */
-    function _validateWarning($code, $params = array())
-    {
-        $this->_stack->push($code, 'warning', $params, false, false, debug_backtrace());
-    }
-
-    /**
-     * @param integer error code
-     * @access protected
-     */
-    function _getErrorMessage()
-    {
-        return array(
-                PEAR_PACKAGEFILE_ERROR_NO_NAME =>
-                    'Missing Package Name',
-                PEAR_PACKAGEFILE_ERROR_NO_SUMMARY =>
-                    'No summary found',
-                PEAR_PACKAGEFILE_ERROR_MULTILINE_SUMMARY =>
-                    'Summary should be on one line',
-                PEAR_PACKAGEFILE_ERROR_NO_DESCRIPTION =>
-                    'Missing description',
-                PEAR_PACKAGEFILE_ERROR_NO_LICENSE =>
-                    'Missing license',
-                PEAR_PACKAGEFILE_ERROR_NO_VERSION =>
-                    'No release version found',
-                PEAR_PACKAGEFILE_ERROR_NO_STATE =>
-                    'No release state found',
-                PEAR_PACKAGEFILE_ERROR_NO_DATE =>
-                    'No release date found',
-                PEAR_PACKAGEFILE_ERROR_NO_NOTES =>
-                    'No release notes found',
-                PEAR_PACKAGEFILE_ERROR_NO_LEAD =>
-                    'Package must have at least one lead maintainer',
-                PEAR_PACKAGEFILE_ERROR_NO_MAINTAINERS =>
-                    'No maintainers found, at least one must be defined',
-                PEAR_PACKAGEFILE_ERROR_NO_MAINTHANDLE =>
-                    'Maintainer %index% has no handle (user ID at channel server)',
-                PEAR_PACKAGEFILE_ERROR_NO_MAINTROLE =>
-                    'Maintainer %index% has no role',
-                PEAR_PACKAGEFILE_ERROR_NO_MAINTNAME =>
-                    'Maintainer %index% has no name',
-                PEAR_PACKAGEFILE_ERROR_NO_MAINTEMAIL =>
-                    'Maintainer %index% has no email',
-                PEAR_PACKAGEFILE_ERROR_NO_DEPNAME =>
-                    'Dependency %index% is not a php dependency, and has no name',
-                PEAR_PACKAGEFILE_ERROR_NO_DEPREL =>
-                    'Dependency %index% has no relation (rel)',
-                PEAR_PACKAGEFILE_ERROR_NO_DEPTYPE =>
-                    'Dependency %index% has no type',
-                PEAR_PACKAGEFILE_ERROR_DEPNAME_IGNORED =>
-                    'PHP Dependency %index% has a name attribute of "%name%" which will be' .
-                        ' ignored!',
-                PEAR_PACKAGEFILE_ERROR_NO_DEPVERSION =>
-                    'Dependency %index% is not a rel="has" or rel="not" dependency, ' .
-                        'and has no version',
-                PEAR_PACKAGEFILE_ERROR_NO_DEPPHPVERSION =>
-                    'Dependency %index% is a type="php" dependency, ' .
-                        'and has no version',
-                PEAR_PACKAGEFILE_ERROR_DEPVERSION_IGNORED =>
-                    'Dependency %index% is a rel="%rel%" dependency, versioning is ignored',
-                PEAR_PACKAGEFILE_ERROR_INVALID_DEPOPTIONAL =>
-                    'Dependency %index% has invalid optional value "%opt%", should be yes or no',
-                PEAR_PACKAGEFILE_PHP_NO_NOT =>
-                    'Dependency %index%: php dependencies cannot use "not" rel, use "ne"' .
-                        ' to exclude specific versions',
-                PEAR_PACKAGEFILE_ERROR_NO_CONFNAME =>
-                    'Configure Option %index% has no name',
-                PEAR_PACKAGEFILE_ERROR_NO_CONFPROMPT =>
-                    'Configure Option %index% has no prompt',
-                PEAR_PACKAGEFILE_ERROR_NO_FILES =>
-                    'No files in <filelist> section of package.xml',
-                PEAR_PACKAGEFILE_ERROR_NO_FILEROLE =>
-                    'File "%file%" has no role, expecting one of "%roles%"',
-                PEAR_PACKAGEFILE_ERROR_INVALID_FILEROLE =>
-                    'File "%file%" has invalid role "%role%", expecting one of "%roles%"',
-                PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME =>
-                    'File "%file%" cannot start with ".", cannot package or install',
-                PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE =>
-                    'Parser error: invalid PHP found in file "%file%"',
-                PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX =>
-                    'in %file%: %type% "%name%" not prefixed with package name "%package%"',
-                PEAR_PACKAGEFILE_ERROR_INVALID_FILE =>
-                    'Parser error: invalid PHP file "%file%"',
-                PEAR_PACKAGEFILE_ERROR_CHANNELVAL =>
-                    'Channel validator error: field "%field%" - %reason%',
-                PEAR_PACKAGEFILE_ERROR_PHP5 =>
-                    'Error, PHP5 token encountered in %file%, analysis should be in PHP5',
-                PEAR_PACKAGEFILE_ERROR_FILE_NOTFOUND =>
-                    'File "%file%" in package.xml does not exist',
-                PEAR_PACKAGEFILE_ERROR_NON_ISO_CHARS =>
-                    'Package.xml contains non-ISO-8859-1 characters, and may not validate',
-            );
-    }
-
-    /**
-     * Validate XML package definition file.
-     *
-     * @access public
-     * @return boolean
-     */
-    function validate($state = PEAR_VALIDATE_NORMAL, $nofilechecking = false)
-    {
-        if (($this->_isValid & $state) == $state) {
-            return true;
-        }
-        $this->_isValid = true;
-        $info = $this->_packageInfo;
-        if (empty($info['package'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_NAME);
-            $this->_packageName = $pn = 'unknown';
-        } else {
-            $this->_packageName = $pn = $info['package'];
-        }
-
-        if (empty($info['summary'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_SUMMARY);
-        } elseif (strpos(trim($info['summary']), "\n") !== false) {
-            $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_MULTILINE_SUMMARY,
-                array('summary' => $info['summary']));
-        }
-        if (empty($info['description'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DESCRIPTION);
-        }
-        if (empty($info['release_license'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_LICENSE);
-        }
-        if (empty($info['version'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_VERSION);
-        }
-        if (empty($info['release_state'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_STATE);
-        }
-        if (empty($info['release_date'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DATE);
-        }
-        if (empty($info['release_notes'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_NOTES);
-        }
-        if (empty($info['maintainers'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTAINERS);
-        } else {
-            $haslead = false;
-            $i = 1;
-            foreach ($info['maintainers'] as $m) {
-                if (empty($m['handle'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTHANDLE,
-                        array('index' => $i));
-                }
-                if (empty($m['role'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTROLE,
-                        array('index' => $i, 'roles' => PEAR_Common::getUserRoles()));
-                } elseif ($m['role'] == 'lead') {
-                    $haslead = true;
-                }
-                if (empty($m['name'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTNAME,
-                        array('index' => $i));
-                }
-                if (empty($m['email'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTEMAIL,
-                        array('index' => $i));
-                }
-                $i++;
-            }
-            if (!$haslead) {
-                $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_LEAD);
-            }
-        }
-        if (!empty($info['release_deps'])) {
-            $i = 1;
-            foreach ($info['release_deps'] as $d) {
-                if (!isset($d['type']) || empty($d['type'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPTYPE,
-                        array('index' => $i, 'types' => PEAR_Common::getDependencyTypes()));
-                    continue;
-                }
-                if (!isset($d['rel']) || empty($d['rel'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPREL,
-                        array('index' => $i, 'rels' => PEAR_Common::getDependencyRelations()));
-                    continue;
-                }
-                if (!empty($d['optional'])) {
-                    if (!in_array($d['optional'], array('yes', 'no'))) {
-                        $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_DEPOPTIONAL,
-                            array('index' => $i, 'opt' => $d['optional']));
-                    }
-                }
-                if ($d['rel'] != 'has' && $d['rel'] != 'not' && empty($d['version'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPVERSION,
-                        array('index' => $i));
-                } elseif (($d['rel'] == 'has' || $d['rel'] == 'not') && !empty($d['version'])) {
-                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_DEPVERSION_IGNORED,
-                        array('index' => $i, 'rel' => $d['rel']));
-                }
-                if ($d['type'] == 'php' && !empty($d['name'])) {
-                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_DEPNAME_IGNORED,
-                        array('index' => $i, 'name' => $d['name']));
-                } elseif ($d['type'] != 'php' && empty($d['name'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPNAME,
-                        array('index' => $i));
-                }
-                if ($d['type'] == 'php' && empty($d['version'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPPHPVERSION,
-                        array('index' => $i));
-                }
-                if (($d['rel'] == 'not') && ($d['type'] == 'php')) {
-                    $this->_validateError(PEAR_PACKAGEFILE_PHP_NO_NOT,
-                        array('index' => $i));
-                }
-                $i++;
-            }
-        }
-        if (!empty($info['configure_options'])) {
-            $i = 1;
-            foreach ($info['configure_options'] as $c) {
-                if (empty($c['name'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_CONFNAME,
-                        array('index' => $i));
-                }
-                if (empty($c['prompt'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_CONFPROMPT,
-                        array('index' => $i));
-                }
-                $i++;
-            }
-        }
-        if (empty($info['filelist'])) {
-            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_FILES);
-            $errors[] = 'no files';
-        } else {
-            foreach ($info['filelist'] as $file => $fa) {
-                if (empty($fa['role'])) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_FILEROLE,
-                        array('file' => $file, 'roles' => PEAR_Common::getFileRoles()));
-                    continue;
-                } elseif (!in_array($fa['role'], PEAR_Common::getFileRoles())) {
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILEROLE,
-                        array('file' => $file, 'role' => $fa['role'], 'roles' => PEAR_Common::getFileRoles()));
-                }
-                if (preg_match('~/\.\.?(/|\\z)|^\.\.?/~', str_replace('\\', '/', $file))) {
-                    // file contains .. parent directory or . cur directory references
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME,
-                        array('file' => $file));
-                }
-                if (isset($fa['install-as']) &&
-                      preg_match('~/\.\.?(/|\\z)|^\.\.?/~', 
-                                 str_replace('\\', '/', $fa['install-as']))) {
-                    // install-as contains .. parent directory or . cur directory references
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME,
-                        array('file' => $file . ' [installed as ' . $fa['install-as'] . ']'));
-                }
-                if (isset($fa['baseinstalldir']) &&
-                      preg_match('~/\.\.?(/|\\z)|^\.\.?/~', 
-                                 str_replace('\\', '/', $fa['baseinstalldir']))) {
-                    // install-as contains .. parent directory or . cur directory references
-                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME,
-                        array('file' => $file . ' [baseinstalldir ' . $fa['baseinstalldir'] . ']'));
-                }
-            }
-        }
-        if (isset($this->_registry) && $this->_isValid) {
-            $chan = $this->_registry->getChannel('pear.php.net');
-            if (PEAR::isError($chan)) {
-                $this->_validateError(PEAR_PACKAGEFILE_ERROR_CHANNELVAL, $chan->getMessage());
-                return $this->_isValid = 0;
-            }
-            $validator = $chan->getValidationObject();
-            $validator->setPackageFile($this);
-            $validator->validate($state);
-            $failures = $validator->getFailures();
-            foreach ($failures['errors'] as $error) {
-                $this->_validateError(PEAR_PACKAGEFILE_ERROR_CHANNELVAL, $error);
-            }
-            foreach ($failures['warnings'] as $warning) {
-                $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_CHANNELVAL, $warning);
-            }
-        }
-        if ($this->_isValid && $state == PEAR_VALIDATE_PACKAGING && !$nofilechecking) {
-            if ($this->_analyzePhpFiles()) {
-                $this->_isValid = true;
-            }
-        }
-        if ($this->_isValid) {
-            return $this->_isValid = $state;
-        }
-        return $this->_isValid = 0;
-    }
-
-    function _analyzePhpFiles()
-    {
-        if (!$this->_isValid) {
-            return false;
-        }
-        if (!isset($this->_packageFile)) {
-            return false;
-        }
-        $dir_prefix = dirname($this->_packageFile);
-        $common = new PEAR_Common;
-        $log = isset($this->_logger) ? array(&$this->_logger, 'log') :
-            array($common, 'log');
-        $info = $this->getFilelist();
-        foreach ($info as $file => $fa) {
-            if (!file_exists($dir_prefix . DIRECTORY_SEPARATOR . $file)) {
-                $this->_validateError(PEAR_PACKAGEFILE_ERROR_FILE_NOTFOUND,
-                    array('file' => realpath($dir_prefix) . DIRECTORY_SEPARATOR . $file));
-                continue;
-            }
-            if ($fa['role'] == 'php' && $dir_prefix) {
-                call_user_func_array($log, array(1, "Analyzing $file"));
-                $srcinfo = $this->_analyzeSourceCode($dir_prefix . DIRECTORY_SEPARATOR . $file);
-                if ($srcinfo) {
-                    $this->_buildProvidesArray($srcinfo);
-                }
-            }
-        }
-        $this->_packageName = $pn = $this->getPackage();
-        $pnl = strlen($pn);
-        if (isset($this->_packageInfo['provides'])) {
-            foreach ((array) $this->_packageInfo['provides'] as $key => $what) {
-                if (isset($what['explicit'])) {
-                    // skip conformance checks if the provides entry is
-                    // specified in the package.xml file
-                    continue;
-                }
-                extract($what);
-                if ($type == 'class') {
-                    if (!strncasecmp($name, $pn, $pnl)) {
-                        continue;
-                    }
-                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX,
-                        array('file' => $file, 'type' => $type, 'name' => $name, 'package' => $pn));
-                } elseif ($type == 'function') {
-                    if (strstr($name, '::') || !strncasecmp($name, $pn, $pnl)) {
-                        continue;
-                    }
-                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX,
-                        array('file' => $file, 'type' => $type, 'name' => $name, 'package' => $pn));
-                }
-            }
-        }
-        return $this->_isValid;
-    }
-
-    /**
-     * Get the default xml generator object
-     *
-     * @return PEAR_PackageFile_Generator_v1
-     */
-    function &getDefaultGenerator()
-    {
-        if (!class_exists('PEAR_PackageFile_Generator_v1')) {
-            require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/PackageFile/Generator/v1.php';
-        }
-        $a = &new PEAR_PackageFile_Generator_v1($this);
-        return $a;
-    }
-
-    /**
-     * Get the contents of a file listed within the package.xml
-     * @param string
-     * @return string
-     */
-    function getFileContents($file)
-    {
-        if ($this->_archiveFile == $this->_packageFile) { // unpacked
-            $dir = dirname($this->_packageFile);
-            $file = $dir . DIRECTORY_SEPARATOR . $file;
-            $file = str_replace(array('/', '\\'),
-                array(DIRECTORY_SEPARATOR, DIRECTORY_SEPARATOR), $file);
-            if (file_exists($file) && is_readable($file)) {
-                return implode('', file($file));
-            }
-        } else { // tgz
-            if (!class_exists('Archive_Tar')) {
-                require_once 'phar://install-pear-nozlib.phar/' . 'Archive/Tar.php';
-            }
-            $tar = &new Archive_Tar($this->_archiveFile);
-            $tar->pushErrorHandling(PEAR_ERROR_RETURN);
-            if ($file != 'package.xml' && $file != 'package2.xml') {
-                $file = $this->getPackage() . '-' . $this->getVersion() . '/' . $file;
-            }
-            $file = $tar->extractInString($file);
-            $tar->popErrorHandling();
-            if (PEAR::isError($file)) {
-                return PEAR::raiseError("Cannot locate file '$file' in archive");
-            }
-            return $file;
-        }
-    }
-
-    // {{{ analyzeSourceCode()
-    /**
-     * Analyze the source code of the given PHP file
-     *
-     * @param  string Filename of the PHP file
-     * @return mixed
-     * @access private
-     */
-    function _analyzeSourceCode($file)
-    {
-        if (!function_exists("token_get_all")) {
-            return false;
-        }
-        if (!defined('T_DOC_COMMENT')) {
-            define('T_DOC_COMMENT', T_COMMENT);
-        }
-        if (!defined('T_INTERFACE')) {
-            define('T_INTERFACE', -1);
-        }
-        if (!defined('T_IMPLEMENTS')) {
-            define('T_IMPLEMENTS', -1);
-        }
-        if (!$fp = @fopen($file, "r")) {
-            return false;
-        }
-        fclose($fp);
-        $contents = file_get_contents($file);
-        $tokens = token_get_all($contents);
-/*
-        for ($i = 0; $i < sizeof($tokens); $i++) {
-            @list($token, $data) = $tokens[$i];
-            if (is_string($token)) {
-                var_dump($token);
-            } else {
-                print token_name($token) . ' ';
-                var_dump(rtrim($data));
-            }
-        }
-*/
-        $look_for = 0;
-        $paren_level = 0;
-        $bracket_level = 0;
-        $brace_level = 0;
-        $lastphpdoc = '';
-        $current_class = '';
-        $current_interface = '';
-        $current_class_level = -1;
-        $current_function = '';
-        $current_function_level = -1;
-        $declared_classes = array();
-        $declared_interfaces = array();
-        $declared_functions = array();
-        $declared_methods = array();
-        $used_classes = array();
-        $used_functions = array();
-        $extends = array();
-        $implements = array();
-        $nodeps = array();
-        $inquote = false;
-        $interface = false;
-        for ($i = 0; $i < sizeof($tokens); $i++) {
-            if (is_array($tokens[$i])) {
-                list($token, $data) = $tokens[$i];
-            } else {
-                $token = $tokens[$i];
-                $data = '';
-            }
-            if ($inquote) {
-                if ($token != '"' && $token != T_END_HEREDOC) {
-                    continue;
-                } else {
-                    $inquote = false;
-                    continue;
-                }
-            }
-            switch ($token) {
-                case T_WHITESPACE :
-                    continue;
-                case ';':
-                    if ($interface) {
-                        $current_function = '';
-                        $current_function_level = -1;
-                    }
-                    break;
-                case '"':
-                case T_START_HEREDOC:
-                    $inquote = true;
-                    break;
-                case T_CURLY_OPEN:
-                case T_DOLLAR_OPEN_CURLY_BRACES:
-                case '{': $brace_level++; continue 2;
-                case '}':
-                    $brace_level--;
-                    if ($current_class_level == $brace_level) {
-                        $current_class = '';
-                        $current_class_level = -1;
-                    }
-                    if ($current_function_level == $brace_level) {
-                        $current_function = '';
-                        $current_function_level = -1;
-                    }
-                    continue 2;
-                case '[': $bracket_level++; continue 2;
-                case ']': $bracket_level--; continue 2;
-                case '(': $paren_level++;   continue 2;
-                case ')': $paren_level--;   continue 2;
-                case T_INTERFACE:
-                    $interface = true;
-                case T_CLASS:
-                    if (($current_class_level != -1) || ($current_function_level != -1)) {
-                        $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE,
-                            array('file' => $file));
-                        return false;
-                    }
-                case T_FUNCTION:
-                case T_NEW:
-                case T_EXTENDS:
-                case T_IMPLEMENTS:
-                    $look_for = $token;
-                    continue 2;
-                case T_STRING:
-                    if (version_compare(zend_version(), '2.0', '<')) {
-                        if (in_array(strtolower($data),
-                            array('public', 'private', 'protected', 'abstract',
-                                  'interface', 'implements', 'throw') 
-                                 )) {
-                            $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_PHP5,
-                                array($file));
-                        }
-                    }
-                    if ($look_for == T_CLASS) {
-                        $current_class = $data;
-                        $current_class_level = $brace_level;
-                        $declared_classes[] = $current_class;
-                    } elseif ($look_for == T_INTERFACE) {
-                        $current_interface = $data;
-                        $current_class_level = $brace_level;
-                        $declared_interfaces[] = $current_interface;
-                    } elseif ($look_for == T_IMPLEMENTS) {
-                        $implements[$current_class] = $data;
-                    } elseif ($look_for == T_EXTENDS) {
-                        $extends[$current_class] = $data;
-                    } elseif ($look_for == T_FUNCTION) {
-                        if ($current_class) {
-                            $current_function = "$current_class::$data";
-                            $declared_methods[$current_class][] = $data;
-                        } elseif ($current_interface) {
-                            $current_function = "$current_interface::$data";
-                            $declared_methods[$current_interface][] = $data;
-                        } else {
-                            $current_function = $data;
-                            $declared_functions[] = $current_function;
-                        }
-                        $current_function_level = $brace_level;
-                        $m = array();
-                    } elseif ($look_for == T_NEW) {
-                        $used_classes[$data] = true;
-                    }
-                    $look_for = 0;
-                    continue 2;
-                case T_VARIABLE:
-                    $look_for = 0;
-                    continue 2;
-                case T_DOC_COMMENT:
-                case T_COMMENT:
-                    if (preg_match('!^/\*\*\s!', $data)) {
-                        $lastphpdoc = $data;
-                        if (preg_match_all('/@nodep\s+(\S+)/', $lastphpdoc, $m)) {
-                            $nodeps = array_merge($nodeps, $m[1]);
-                        }
-                    }
-                    continue 2;
-                case T_DOUBLE_COLON:
-                    if (!($tokens[$i - 1][0] == T_WHITESPACE || $tokens[$i - 1][0] == T_STRING)) {
-                        $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE,
-                            array('file' => $file));
-                        return false;
-                    }
-                    $class = $tokens[$i - 1][1];
-                    if (strtolower($class) != 'parent') {
-                        $used_classes[$class] = true;
-                    }
-                    continue 2;
-            }
-        }
-        return array(
-            "source_file" => $file,
-            "declared_classes" => $declared_classes,
-            "declared_interfaces" => $declared_interfaces,
-            "declared_methods" => $declared_methods,
-            "declared_functions" => $declared_functions,
-            "used_classes" => array_diff(array_keys($used_classes), $nodeps),
-            "inheritance" => $extends,
-            "implements" => $implements,
-            );
-    }
-
-    /**
-     * Build a "provides" array from data returned by
-     * analyzeSourceCode().  The format of the built array is like
-     * this:
-     *
-     *  array(
-     *    'class;MyClass' => 'array('type' => 'class', 'name' => 'MyClass'),
-     *    ...
-     *  )
-     *
-     *
-     * @param array $srcinfo array with information about a source file
-     * as returned by the analyzeSourceCode() method.
-     *
-     * @return void
-     *
-     * @access private
-     *
-     */
-    function _buildProvidesArray($srcinfo)
-    {
-        if (!$this->_isValid) {
-            return false;
-        }
-        $file = basename($srcinfo['source_file']);
-        $pn = $this->getPackage();
-        $pnl = strlen($pn);
-        foreach ($srcinfo['declared_classes'] as $class) {
-            $key = "class;$class";
-            if (isset($this->_packageInfo['provides'][$key])) {
-                continue;
-            }
-            $this->_packageInfo['provides'][$key] =
-                array('file'=> $file, 'type' => 'class', 'name' => $class);
-            if (isset($srcinfo['inheritance'][$class])) {
-                $this->_packageInfo['provides'][$key]['extends'] =
-                    $srcinfo['inheritance'][$class];
-            }
-        }
-        foreach ($srcinfo['declared_methods'] as $class => $methods) {
-            foreach ($methods as $method) {
-                $function = "$class::$method";
-                $key = "function;$function";
-                if ($method{0} == '_' || !strcasecmp($method, $class) ||
-                    isset($this->_packageInfo['provides'][$key])) {
-                    continue;
-                }
-                $this->_packageInfo['provides'][$key] =
-                    array('file'=> $file, 'type' => 'function', 'name' => $function);
-            }
-        }
-
-        foreach ($srcinfo['declared_functions'] as $function) {
-            $key = "function;$function";
-            if ($function{0} == '_' || isset($this->_packageInfo['provides'][$key])) {
-                continue;
-            }
-            if (!strstr($function, '::') && strncasecmp($function, $pn, $pnl)) {
-                $warnings[] = "in1 " . $file . ": function \"$function\" not prefixed with package name \"$pn\"";
-            }
-            $this->_packageInfo['provides'][$key] =
-                array('file'=> $file, 'type' => 'function', 'name' => $function);
-        }
-    }
-
-    // }}}
-}
-?>
+}<?php
+/**
+ * PEAR_PackageFile_v1, package.xml version 1.0
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: v1.php 276383 2009-02-24 23:39:37Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a1
+ */
+/**
+ * For error handling
+ */
+require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ErrorStack.php';
+
+/**
+ * Error code if parsing is attempted with no xml extension
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_XML_EXT', 3);
+
+/**
+ * Error code if creating the xml parser resource fails
+ */
+define('PEAR_PACKAGEFILE_ERROR_CANT_MAKE_PARSER', 4);
+
+/**
+ * Error code used for all sax xml parsing errors
+ */
+define('PEAR_PACKAGEFILE_ERROR_PARSER_ERROR', 5);
+
+/**
+ * Error code used when there is no name
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_NAME', 6);
+
+/**
+ * Error code when a package name is not valid
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_NAME', 7);
+
+/**
+ * Error code used when no summary is parsed
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_SUMMARY', 8);
+
+/**
+ * Error code for summaries that are more than 1 line
+ */
+define('PEAR_PACKAGEFILE_ERROR_MULTILINE_SUMMARY', 9);
+
+/**
+ * Error code used when no description is present
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_DESCRIPTION', 10);
+
+/**
+ * Error code used when no license is present
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_LICENSE', 11);
+
+/**
+ * Error code used when a <version> version number is not present
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_VERSION', 12);
+
+/**
+ * Error code used when a <version> version number is invalid
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_VERSION', 13);
+
+/**
+ * Error code when release state is missing
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_STATE', 14);
+
+/**
+ * Error code when release state is invalid
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_STATE', 15);
+
+/**
+ * Error code when release state is missing
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_DATE', 16);
+
+/**
+ * Error code when release state is invalid
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_DATE', 17);
+
+/**
+ * Error code when no release notes are found
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_NOTES', 18);
+
+/**
+ * Error code when no maintainers are found
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_MAINTAINERS', 19);
+
+/**
+ * Error code when a maintainer has no handle
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_MAINTHANDLE', 20);
+
+/**
+ * Error code when a maintainer has no handle
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_MAINTROLE', 21);
+
+/**
+ * Error code when a maintainer has no name
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_MAINTNAME', 22);
+
+/**
+ * Error code when a maintainer has no email
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_MAINTEMAIL', 23);
+
+/**
+ * Error code when a maintainer has no handle
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_MAINTROLE', 24);
+
+/**
+ * Error code when a dependency is not a PHP dependency, but has no name
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_DEPNAME', 25);
+
+/**
+ * Error code when a dependency has no type (pkg, php, etc.)
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_DEPTYPE', 26);
+
+/**
+ * Error code when a dependency has no relation (lt, ge, has, etc.)
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_DEPREL', 27);
+
+/**
+ * Error code when a dependency is not a 'has' relation, but has no version
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_DEPVERSION', 28);
+
+/**
+ * Error code when a dependency has an invalid relation
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPREL', 29);
+
+/**
+ * Error code when a dependency has an invalid type
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPTYPE', 30);
+
+/**
+ * Error code when a dependency has an invalid optional option
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPOPTIONAL', 31);
+
+/**
+ * Error code when a dependency is a pkg dependency, and has an invalid package name
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_DEPNAME', 32);
+
+/**
+ * Error code when a dependency has a channel="foo" attribute, and foo is not a registered channel
+ */
+define('PEAR_PACKAGEFILE_ERROR_UNKNOWN_DEPCHANNEL', 33);
+
+/**
+ * Error code when rel="has" and version attribute is present.
+ */
+define('PEAR_PACKAGEFILE_ERROR_DEPVERSION_IGNORED', 34);
+
+/**
+ * Error code when type="php" and dependency name is present
+ */
+define('PEAR_PACKAGEFILE_ERROR_DEPNAME_IGNORED', 35);
+
+/**
+ * Error code when a configure option has no name
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_CONFNAME', 36);
+
+/**
+ * Error code when a configure option has no name
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_CONFPROMPT', 37);
+
+/**
+ * Error code when a file in the filelist has an invalid role
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_FILEROLE', 38);
+
+/**
+ * Error code when a file in the filelist has no role
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_FILEROLE', 39);
+
+/**
+ * Error code when analyzing a php source file that has parse errors
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE', 40);
+
+/**
+ * Error code when analyzing a php source file reveals a source element
+ * without a package name prefix
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX', 41);
+
+/**
+ * Error code when an unknown channel is specified
+ */
+define('PEAR_PACKAGEFILE_ERROR_UNKNOWN_CHANNEL', 42);
+
+/**
+ * Error code when no files are found in the filelist
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_FILES', 43);
+
+/**
+ * Error code when a file is not valid php according to _analyzeSourceCode()
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_FILE', 44);
+
+/**
+ * Error code when the channel validator returns an error or warning
+ */
+define('PEAR_PACKAGEFILE_ERROR_CHANNELVAL', 45);
+
+/**
+ * Error code when a php5 package is packaged in php4 (analysis doesn't work)
+ */
+define('PEAR_PACKAGEFILE_ERROR_PHP5', 46);
+
+/**
+ * Error code when a file is listed in package.xml but does not exist
+ */
+define('PEAR_PACKAGEFILE_ERROR_FILE_NOTFOUND', 47);
+
+/**
+ * Error code when a <dep type="php" rel="not"... is encountered (use rel="ne")
+ */
+define('PEAR_PACKAGEFILE_PHP_NO_NOT', 48);
+
+/**
+ * Error code when a package.xml contains non-ISO-8859-1 characters
+ */
+define('PEAR_PACKAGEFILE_ERROR_NON_ISO_CHARS', 49);
+
+/**
+ * Error code when a dependency is not a 'has' relation, but has no version
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_DEPPHPVERSION', 50);
+
+/**
+ * Error code when a package has no lead developer
+ */
+define('PEAR_PACKAGEFILE_ERROR_NO_LEAD', 51);
+
+/**
+ * Error code when a filename begins with "."
+ */
+define('PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME', 52);
+/**
+ * package.xml encapsulator
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_PackageFile_v1
+{
+    /**
+     * @access private
+     * @var PEAR_ErrorStack
+     * @access private
+     */
+    var $_stack;
+
+    /**
+     * A registry object, used to access the package name validation regex for non-standard channels
+     * @var PEAR_Registry
+     * @access private
+     */
+    var $_registry;
+
+    /**
+     * An object that contains a log method that matches PEAR_Common::log's signature
+     * @var object
+     * @access private
+     */
+    var $_logger;
+
+    /**
+     * Parsed package information
+     * @var array
+     * @access private
+     */
+    var $_packageInfo;
+
+    /**
+     * path to package.xml
+     * @var string
+     * @access private
+     */
+    var $_packageFile;
+
+    /**
+     * path to package .tgz or false if this is a local/extracted package.xml
+     * @var string
+     * @access private
+     */
+    var $_archiveFile;
+
+    /**
+     * @var int
+     * @access private
+     */
+    var $_isValid = 0;
+
+    /**
+     * Determines whether this packagefile was initialized only with partial package info
+     *
+     * If this package file was constructed via parsing REST, it will only contain
+     *
+     * - package name
+     * - channel name
+     * - dependencies 
+     * @var boolean
+     * @access private
+     */
+    var $_incomplete = true;
+
+    /**
+     * @param bool determines whether to return a PEAR_Error object, or use the PEAR_ErrorStack
+     * @param string Name of Error Stack class to use.
+     */
+    function PEAR_PackageFile_v1()
+    {
+        $this->_stack = &new PEAR_ErrorStack('PEAR_PackageFile_v1');
+        $this->_stack->setErrorMessageTemplate($this->_getErrorMessage());
+        $this->_isValid = 0;
+    }
+
+    function installBinary($installer)
+    {
+        return false;
+    }
+
+    function isExtension($name)
+    {
+        return false;
+    }
+
+    function setConfig(&$config)
+    {
+        $this->_config = &$config;
+        $this->_registry = &$config->getRegistry();
+    }
+
+    function setRequestedGroup()
+    {
+        // placeholder
+    }
+
+    /**
+     * For saving in the registry.
+     *
+     * Set the last version that was installed
+     * @param string
+     */
+    function setLastInstalledVersion($version)
+    {
+        $this->_packageInfo['_lastversion'] = $version;
+    }
+
+    /**
+     * @return string|false
+     */
+    function getLastInstalledVersion()
+    {
+        if (isset($this->_packageInfo['_lastversion'])) {
+            return $this->_packageInfo['_lastversion'];
+        }
+        return false;
+    }
+
+    function getInstalledBinary()
+    {
+        return false;
+    }
+
+    function listPostinstallScripts()
+    {
+        return false;
+    }
+
+    function initPostinstallScripts()
+    {
+        return false;
+    }
+
+    function setLogger(&$logger)
+    {
+        if ($logger && (!is_object($logger) || !method_exists($logger, 'log'))) {
+            return PEAR::raiseError('Logger must be compatible with PEAR_Common::log');
+        }
+        $this->_logger = &$logger;
+    }
+
+    function setPackagefile($file, $archive = false)
+    {
+        $this->_packageFile = $file;
+        $this->_archiveFile = $archive ? $archive : $file;
+    }
+
+    function getPackageFile()
+    {
+        return isset($this->_packageFile) ? $this->_packageFile : false;
+    }
+
+    function getPackageType()
+    {
+        return 'php';
+    }
+
+    function getArchiveFile()
+    {
+        return $this->_archiveFile;
+    }
+
+    function packageInfo($field)
+    {
+        if (!is_string($field) || empty($field) ||
+            !isset($this->_packageInfo[$field])) {
+            return false;
+        }
+        return $this->_packageInfo[$field];
+    }
+
+    function setDirtree($path)
+    {
+        if (!isset($this->_packageInfo['dirtree'])) {
+            $this->_packageInfo['dirtree'] = array();
+        }
+        $this->_packageInfo['dirtree'][$path] = true;
+    }
+
+    function getDirtree()
+    {
+        if (isset($this->_packageInfo['dirtree']) && count($this->_packageInfo['dirtree'])) {
+            return $this->_packageInfo['dirtree'];
+        }
+        return false;
+    }
+
+    function resetDirtree()
+    {
+        unset($this->_packageInfo['dirtree']);
+    }
+
+    function fromArray($pinfo)
+    {
+        $this->_incomplete = false;
+        $this->_packageInfo = $pinfo;
+    }
+
+    function isIncomplete()
+    {
+        return $this->_incomplete;
+    }
+
+    function getChannel()
+    {
+        return 'pear.php.net';
+    }
+
+    function getUri()
+    {
+        return false;
+    }
+
+    function getTime()
+    {
+        return false;
+    }
+
+    function getExtends()
+    {
+        if (isset($this->_packageInfo['extends'])) {
+            return $this->_packageInfo['extends'];
+        }
+        return false;
+    }
+
+    /**
+     * @return array
+     */
+    function toArray()
+    {
+        if (!$this->validate(PEAR_VALIDATE_NORMAL)) {
+            return false;
+        }
+        return $this->getArray();
+    }
+
+    function getArray()
+    {
+        return $this->_packageInfo;
+    }
+
+    function getName()
+    {
+        return $this->getPackage();
+    }
+
+    function getPackage()
+    {
+        if (isset($this->_packageInfo['package'])) {
+            return $this->_packageInfo['package'];
+        }
+        return false;
+    }
+
+    /**
+     * WARNING - don't use this unless you know what you are doing
+     */
+    function setRawPackage($package)
+    {
+        $this->_packageInfo['package'] = $package;
+    }
+
+    function setPackage($package)
+    {
+        $this->_packageInfo['package'] = $package;
+        $this->_isValid = false;
+    }
+
+    function getVersion()
+    {
+        if (isset($this->_packageInfo['version'])) {
+            return $this->_packageInfo['version'];
+        }
+        return false;
+    }
+
+    function setVersion($version)
+    {
+        $this->_packageInfo['version'] = $version;
+        $this->_isValid = false;
+    }
+
+    function clearMaintainers()
+    {
+        unset($this->_packageInfo['maintainers']);
+    }
+
+    function getMaintainers()
+    {
+        if (isset($this->_packageInfo['maintainers'])) {
+            return $this->_packageInfo['maintainers'];
+        }
+        return false;
+    }
+
+    /**
+     * Adds a new maintainer - no checking of duplicates is performed, use
+     * updatemaintainer for that purpose.
+     */
+    function addMaintainer($role, $handle, $name, $email)
+    {
+        $this->_packageInfo['maintainers'][] =
+            array('handle' => $handle, 'role' => $role, 'email' => $email, 'name' => $name);
+        $this->_isValid = false;
+    }
+
+    function updateMaintainer($role, $handle, $name, $email)
+    {
+        $found = false;
+        if (!isset($this->_packageInfo['maintainers']) ||
+              !is_array($this->_packageInfo['maintainers'])) {
+            return $this->addMaintainer($role, $handle, $name, $email);
+        }
+        foreach ($this->_packageInfo['maintainers'] as $i => $maintainer) {
+            if ($maintainer['handle'] == $handle) {
+                $found = $i;
+                break;
+            }
+        }
+        if ($found !== false) {
+            unset($this->_packageInfo['maintainers'][$found]);
+            $this->_packageInfo['maintainers'] =
+                array_values($this->_packageInfo['maintainers']);
+        }
+        $this->addMaintainer($role, $handle, $name, $email);
+    }
+
+    function deleteMaintainer($handle)
+    {
+        $found = false;
+        foreach ($this->_packageInfo['maintainers'] as $i => $maintainer) {
+            if ($maintainer['handle'] == $handle) {
+                $found = $i;
+                break;
+            }
+        }
+        if ($found !== false) {
+            unset($this->_packageInfo['maintainers'][$found]);
+            $this->_packageInfo['maintainers'] =
+                array_values($this->_packageInfo['maintainers']);
+            return true;
+        }
+        return false;
+    }
+
+    function getState()
+    {
+        if (isset($this->_packageInfo['release_state'])) {
+            return $this->_packageInfo['release_state'];
+        }
+        return false;
+    }
+
+    function setRawState($state)
+    {
+        $this->_packageInfo['release_state'] = $state;
+    }
+
+    function setState($state)
+    {
+        $this->_packageInfo['release_state'] = $state;
+        $this->_isValid = false;
+    }
+
+    function getDate()
+    {
+        if (isset($this->_packageInfo['release_date'])) {
+            return $this->_packageInfo['release_date'];
+        }
+        return false;
+    }
+
+    function setDate($date)
+    {
+        $this->_packageInfo['release_date'] = $date;
+        $this->_isValid = false;
+    }
+
+    function getLicense()
+    {
+        if (isset($this->_packageInfo['release_license'])) {
+            return $this->_packageInfo['release_license'];
+        }
+        return false;
+    }
+
+    function setLicense($date)
+    {
+        $this->_packageInfo['release_license'] = $date;
+        $this->_isValid = false;
+    }
+
+    function getSummary()
+    {
+        if (isset($this->_packageInfo['summary'])) {
+            return $this->_packageInfo['summary'];
+        }
+        return false;
+    }
+
+    function setSummary($summary)
+    {
+        $this->_packageInfo['summary'] = $summary;
+        $this->_isValid = false;
+    }
+
+    function getDescription()
+    {
+        if (isset($this->_packageInfo['description'])) {
+            return $this->_packageInfo['description'];
+        }
+        return false;
+    }
+
+    function setDescription($desc)
+    {
+        $this->_packageInfo['description'] = $desc;
+        $this->_isValid = false;
+    }
+
+    function getNotes()
+    {
+        if (isset($this->_packageInfo['release_notes'])) {
+            return $this->_packageInfo['release_notes'];
+        }
+        return false;
+    }
+
+    function setNotes($notes)
+    {
+        $this->_packageInfo['release_notes'] = $notes;
+        $this->_isValid = false;
+    }
+
+    function getDeps()
+    {
+        if (isset($this->_packageInfo['release_deps'])) {
+            return $this->_packageInfo['release_deps'];
+        }
+        return false;
+    }
+
+    /**
+     * Reset dependencies prior to adding new ones
+     */
+    function clearDeps()
+    {
+        unset($this->_packageInfo['release_deps']);
+    }
+
+    function addPhpDep($version, $rel)
+    {
+        $this->_isValid = false;
+        $this->_packageInfo['release_deps'][] =
+            array('type' => 'php',
+                  'rel' => $rel,
+                  'version' => $version);
+    }
+
+    function addPackageDep($name, $version, $rel, $optional = 'no')
+    {
+        $this->_isValid = false;
+        $dep =
+            array('type' => 'pkg',
+                  'name' => $name,
+                  'rel' => $rel,
+                  'optional' => $optional);
+        if ($rel != 'has' && $rel != 'not') {
+            $dep['version'] = $version;
+        }
+        $this->_packageInfo['release_deps'][] = $dep;
+    }
+
+    function addExtensionDep($name, $version, $rel, $optional = 'no')
+    {
+        $this->_isValid = false;
+        $this->_packageInfo['release_deps'][] =
+            array('type' => 'ext',
+                  'name' => $name,
+                  'rel' => $rel,
+                  'version' => $version,
+                  'optional' => $optional);
+    }
+
+    /**
+     * WARNING - do not use this function directly unless you know what you're doing
+     */
+    function setDeps($deps)
+    {
+        $this->_packageInfo['release_deps'] = $deps;
+    }
+
+    function hasDeps()
+    {
+        return isset($this->_packageInfo['release_deps']) &&
+            count($this->_packageInfo['release_deps']);
+    }
+
+    function getDependencyGroup($group)
+    {
+        return false;
+    }
+
+    function isCompatible($pf)
+    {
+        return false;
+    }
+
+    function isSubpackageOf($p)
+    {
+        return $p->isSubpackage($this);
+    }
+
+    function isSubpackage($p)
+    {
+        return false;
+    }
+
+    function dependsOn($package, $channel)
+    {
+        if (strtolower($channel) != 'pear.php.net') {
+            return false;
+        }
+        if (!($deps = $this->getDeps())) {
+            return false;
+        }
+        foreach ($deps as $dep) {
+            if ($dep['type'] != 'pkg') {
+                continue;
+            }
+            if (strtolower($dep['name']) == strtolower($package)) {
+                return true;
+            }
+        }
+        return false;
+    }
+
+    function getConfigureOptions()
+    {
+        if (isset($this->_packageInfo['configure_options'])) {
+            return $this->_packageInfo['configure_options'];
+        }
+        return false;
+    }
+
+    function hasConfigureOptions()
+    {
+        return isset($this->_packageInfo['configure_options']) &&
+            count($this->_packageInfo['configure_options']);
+    }
+
+    function addConfigureOption($name, $prompt, $default = false)
+    {
+        $o = array('name' => $name, 'prompt' => $prompt);
+        if ($default !== false) {
+            $o['default'] = $default;
+        }
+        if (!isset($this->_packageInfo['configure_options'])) {
+            $this->_packageInfo['configure_options'] = array();
+        }
+        $this->_packageInfo['configure_options'][] = $o;
+    }
+
+    function clearConfigureOptions()
+    {
+        unset($this->_packageInfo['configure_options']);
+    }
+
+    function getProvides()
+    {
+        if (isset($this->_packageInfo['provides'])) {
+            return $this->_packageInfo['provides'];
+        }
+        return false;
+    }
+
+    function getProvidesExtension()
+    {
+        return false;
+    }
+
+    function addFile($dir, $file, $attrs)
+    {
+        $dir = preg_replace(array('!\\\\+!', '!/+!'), array('/', '/'), $dir);
+        if ($dir == '/' || $dir == '') {
+            $dir = '';
+        } else {
+            $dir .= '/';
+        }
+        $file = $dir . $file;
+        $file = preg_replace('![\\/]+!', '/', $file);
+        $this->_packageInfo['filelist'][$file] = $attrs;
+    }
+
+    function getInstallationFilelist()
+    {
+        return $this->getFilelist();
+    }
+
+    function getFilelist()
+    {
+        if (isset($this->_packageInfo['filelist'])) {
+            return $this->_packageInfo['filelist'];
+        }
+        return false;
+    }
+
+    function setFileAttribute($file, $attr, $value)
+    {
+        $this->_packageInfo['filelist'][$file][$attr] = $value;
+    }
+
+    function resetFilelist()
+    {
+        $this->_packageInfo['filelist'] = array();
+    }
+
+    function setInstalledAs($file, $path)
+    {
+        if ($path) {
+            return $this->_packageInfo['filelist'][$file]['installed_as'] = $path;
+        }
+        unset($this->_packageInfo['filelist'][$file]['installed_as']);
+    }
+
+    function installedFile($file, $atts)
+    {
+        if (isset($this->_packageInfo['filelist'][$file])) {
+            $this->_packageInfo['filelist'][$file] =
+                array_merge($this->_packageInfo['filelist'][$file], $atts);
+        } else {
+            $this->_packageInfo['filelist'][$file] = $atts;
+        }
+    }
+
+    function getChangelog()
+    {
+        if (isset($this->_packageInfo['changelog'])) {
+            return $this->_packageInfo['changelog'];
+        }
+        return false;
+    }
+
+    function getPackagexmlVersion()
+    {
+        return '1.0';
+    }
+
+    /**
+     * Wrapper to {@link PEAR_ErrorStack::getErrors()}
+     * @param boolean determines whether to purge the error stack after retrieving
+     * @return array
+     */
+    function getValidationWarnings($purge = true)
+    {
+        return $this->_stack->getErrors($purge);
+    }
+
+    // }}}
+    /**
+     * Validation error.  Also marks the object contents as invalid
+     * @param error code
+     * @param array error information
+     * @access private
+     */
+    function _validateError($code, $params = array())
+    {
+        $this->_stack->push($code, 'error', $params, false, false, debug_backtrace());
+        $this->_isValid = false;
+    }
+
+    /**
+     * Validation warning.  Does not mark the object contents invalid.
+     * @param error code
+     * @param array error information
+     * @access private
+     */
+    function _validateWarning($code, $params = array())
+    {
+        $this->_stack->push($code, 'warning', $params, false, false, debug_backtrace());
+    }
+
+    /**
+     * @param integer error code
+     * @access protected
+     */
+    function _getErrorMessage()
+    {
+        return array(
+                PEAR_PACKAGEFILE_ERROR_NO_NAME =>
+                    'Missing Package Name',
+                PEAR_PACKAGEFILE_ERROR_NO_SUMMARY =>
+                    'No summary found',
+                PEAR_PACKAGEFILE_ERROR_MULTILINE_SUMMARY =>
+                    'Summary should be on one line',
+                PEAR_PACKAGEFILE_ERROR_NO_DESCRIPTION =>
+                    'Missing description',
+                PEAR_PACKAGEFILE_ERROR_NO_LICENSE =>
+                    'Missing license',
+                PEAR_PACKAGEFILE_ERROR_NO_VERSION =>
+                    'No release version found',
+                PEAR_PACKAGEFILE_ERROR_NO_STATE =>
+                    'No release state found',
+                PEAR_PACKAGEFILE_ERROR_NO_DATE =>
+                    'No release date found',
+                PEAR_PACKAGEFILE_ERROR_NO_NOTES =>
+                    'No release notes found',
+                PEAR_PACKAGEFILE_ERROR_NO_LEAD =>
+                    'Package must have at least one lead maintainer',
+                PEAR_PACKAGEFILE_ERROR_NO_MAINTAINERS =>
+                    'No maintainers found, at least one must be defined',
+                PEAR_PACKAGEFILE_ERROR_NO_MAINTHANDLE =>
+                    'Maintainer %index% has no handle (user ID at channel server)',
+                PEAR_PACKAGEFILE_ERROR_NO_MAINTROLE =>
+                    'Maintainer %index% has no role',
+                PEAR_PACKAGEFILE_ERROR_NO_MAINTNAME =>
+                    'Maintainer %index% has no name',
+                PEAR_PACKAGEFILE_ERROR_NO_MAINTEMAIL =>
+                    'Maintainer %index% has no email',
+                PEAR_PACKAGEFILE_ERROR_NO_DEPNAME =>
+                    'Dependency %index% is not a php dependency, and has no name',
+                PEAR_PACKAGEFILE_ERROR_NO_DEPREL =>
+                    'Dependency %index% has no relation (rel)',
+                PEAR_PACKAGEFILE_ERROR_NO_DEPTYPE =>
+                    'Dependency %index% has no type',
+                PEAR_PACKAGEFILE_ERROR_DEPNAME_IGNORED =>
+                    'PHP Dependency %index% has a name attribute of "%name%" which will be' .
+                        ' ignored!',
+                PEAR_PACKAGEFILE_ERROR_NO_DEPVERSION =>
+                    'Dependency %index% is not a rel="has" or rel="not" dependency, ' .
+                        'and has no version',
+                PEAR_PACKAGEFILE_ERROR_NO_DEPPHPVERSION =>
+                    'Dependency %index% is a type="php" dependency, ' .
+                        'and has no version',
+                PEAR_PACKAGEFILE_ERROR_DEPVERSION_IGNORED =>
+                    'Dependency %index% is a rel="%rel%" dependency, versioning is ignored',
+                PEAR_PACKAGEFILE_ERROR_INVALID_DEPOPTIONAL =>
+                    'Dependency %index% has invalid optional value "%opt%", should be yes or no',
+                PEAR_PACKAGEFILE_PHP_NO_NOT =>
+                    'Dependency %index%: php dependencies cannot use "not" rel, use "ne"' .
+                        ' to exclude specific versions',
+                PEAR_PACKAGEFILE_ERROR_NO_CONFNAME =>
+                    'Configure Option %index% has no name',
+                PEAR_PACKAGEFILE_ERROR_NO_CONFPROMPT =>
+                    'Configure Option %index% has no prompt',
+                PEAR_PACKAGEFILE_ERROR_NO_FILES =>
+                    'No files in <filelist> section of package.xml',
+                PEAR_PACKAGEFILE_ERROR_NO_FILEROLE =>
+                    'File "%file%" has no role, expecting one of "%roles%"',
+                PEAR_PACKAGEFILE_ERROR_INVALID_FILEROLE =>
+                    'File "%file%" has invalid role "%role%", expecting one of "%roles%"',
+                PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME =>
+                    'File "%file%" cannot start with ".", cannot package or install',
+                PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE =>
+                    'Parser error: invalid PHP found in file "%file%"',
+                PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX =>
+                    'in %file%: %type% "%name%" not prefixed with package name "%package%"',
+                PEAR_PACKAGEFILE_ERROR_INVALID_FILE =>
+                    'Parser error: invalid PHP file "%file%"',
+                PEAR_PACKAGEFILE_ERROR_CHANNELVAL =>
+                    'Channel validator error: field "%field%" - %reason%',
+                PEAR_PACKAGEFILE_ERROR_PHP5 =>
+                    'Error, PHP5 token encountered in %file%, analysis should be in PHP5',
+                PEAR_PACKAGEFILE_ERROR_FILE_NOTFOUND =>
+                    'File "%file%" in package.xml does not exist',
+                PEAR_PACKAGEFILE_ERROR_NON_ISO_CHARS =>
+                    'Package.xml contains non-ISO-8859-1 characters, and may not validate',
+            );
+    }
+
+    /**
+     * Validate XML package definition file.
+     *
+     * @access public
+     * @return boolean
+     */
+    function validate($state = PEAR_VALIDATE_NORMAL, $nofilechecking = false)
+    {
+        if (($this->_isValid & $state) == $state) {
+            return true;
+        }
+        $this->_isValid = true;
+        $info = $this->_packageInfo;
+        if (empty($info['package'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_NAME);
+            $this->_packageName = $pn = 'unknown';
+        } else {
+            $this->_packageName = $pn = $info['package'];
+        }
+
+        if (empty($info['summary'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_SUMMARY);
+        } elseif (strpos(trim($info['summary']), "\n") !== false) {
+            $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_MULTILINE_SUMMARY,
+                array('summary' => $info['summary']));
+        }
+        if (empty($info['description'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DESCRIPTION);
+        }
+        if (empty($info['release_license'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_LICENSE);
+        }
+        if (empty($info['version'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_VERSION);
+        }
+        if (empty($info['release_state'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_STATE);
+        }
+        if (empty($info['release_date'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DATE);
+        }
+        if (empty($info['release_notes'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_NOTES);
+        }
+        if (empty($info['maintainers'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTAINERS);
+        } else {
+            $haslead = false;
+            $i = 1;
+            foreach ($info['maintainers'] as $m) {
+                if (empty($m['handle'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTHANDLE,
+                        array('index' => $i));
+                }
+                if (empty($m['role'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTROLE,
+                        array('index' => $i, 'roles' => PEAR_Common::getUserRoles()));
+                } elseif ($m['role'] == 'lead') {
+                    $haslead = true;
+                }
+                if (empty($m['name'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTNAME,
+                        array('index' => $i));
+                }
+                if (empty($m['email'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_MAINTEMAIL,
+                        array('index' => $i));
+                }
+                $i++;
+            }
+            if (!$haslead) {
+                $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_LEAD);
+            }
+        }
+        if (!empty($info['release_deps'])) {
+            $i = 1;
+            foreach ($info['release_deps'] as $d) {
+                if (!isset($d['type']) || empty($d['type'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPTYPE,
+                        array('index' => $i, 'types' => PEAR_Common::getDependencyTypes()));
+                    continue;
+                }
+                if (!isset($d['rel']) || empty($d['rel'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPREL,
+                        array('index' => $i, 'rels' => PEAR_Common::getDependencyRelations()));
+                    continue;
+                }
+                if (!empty($d['optional'])) {
+                    if (!in_array($d['optional'], array('yes', 'no'))) {
+                        $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_DEPOPTIONAL,
+                            array('index' => $i, 'opt' => $d['optional']));
+                    }
+                }
+                if ($d['rel'] != 'has' && $d['rel'] != 'not' && empty($d['version'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPVERSION,
+                        array('index' => $i));
+                } elseif (($d['rel'] == 'has' || $d['rel'] == 'not') && !empty($d['version'])) {
+                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_DEPVERSION_IGNORED,
+                        array('index' => $i, 'rel' => $d['rel']));
+                }
+                if ($d['type'] == 'php' && !empty($d['name'])) {
+                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_DEPNAME_IGNORED,
+                        array('index' => $i, 'name' => $d['name']));
+                } elseif ($d['type'] != 'php' && empty($d['name'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPNAME,
+                        array('index' => $i));
+                }
+                if ($d['type'] == 'php' && empty($d['version'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_DEPPHPVERSION,
+                        array('index' => $i));
+                }
+                if (($d['rel'] == 'not') && ($d['type'] == 'php')) {
+                    $this->_validateError(PEAR_PACKAGEFILE_PHP_NO_NOT,
+                        array('index' => $i));
+                }
+                $i++;
+            }
+        }
+        if (!empty($info['configure_options'])) {
+            $i = 1;
+            foreach ($info['configure_options'] as $c) {
+                if (empty($c['name'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_CONFNAME,
+                        array('index' => $i));
+                }
+                if (empty($c['prompt'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_CONFPROMPT,
+                        array('index' => $i));
+                }
+                $i++;
+            }
+        }
+        if (empty($info['filelist'])) {
+            $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_FILES);
+            $errors[] = 'no files';
+        } else {
+            foreach ($info['filelist'] as $file => $fa) {
+                if (empty($fa['role'])) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_NO_FILEROLE,
+                        array('file' => $file, 'roles' => PEAR_Common::getFileRoles()));
+                    continue;
+                } elseif (!in_array($fa['role'], PEAR_Common::getFileRoles())) {
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILEROLE,
+                        array('file' => $file, 'role' => $fa['role'], 'roles' => PEAR_Common::getFileRoles()));
+                }
+                if (preg_match('~/\.\.?(/|\\z)|^\.\.?/~', str_replace('\\', '/', $file))) {
+                    // file contains .. parent directory or . cur directory references
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME,
+                        array('file' => $file));
+                }
+                if (isset($fa['install-as']) &&
+                      preg_match('~/\.\.?(/|\\z)|^\.\.?/~', 
+                                 str_replace('\\', '/', $fa['install-as']))) {
+                    // install-as contains .. parent directory or . cur directory references
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME,
+                        array('file' => $file . ' [installed as ' . $fa['install-as'] . ']'));
+                }
+                if (isset($fa['baseinstalldir']) &&
+                      preg_match('~/\.\.?(/|\\z)|^\.\.?/~', 
+                                 str_replace('\\', '/', $fa['baseinstalldir']))) {
+                    // install-as contains .. parent directory or . cur directory references
+                    $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_FILENAME,
+                        array('file' => $file . ' [baseinstalldir ' . $fa['baseinstalldir'] . ']'));
+                }
+            }
+        }
+        if (isset($this->_registry) && $this->_isValid) {
+            $chan = $this->_registry->getChannel('pear.php.net');
+            if (PEAR::isError($chan)) {
+                $this->_validateError(PEAR_PACKAGEFILE_ERROR_CHANNELVAL, $chan->getMessage());
+                return $this->_isValid = 0;
+            }
+            $validator = $chan->getValidationObject();
+            $validator->setPackageFile($this);
+            $validator->validate($state);
+            $failures = $validator->getFailures();
+            foreach ($failures['errors'] as $error) {
+                $this->_validateError(PEAR_PACKAGEFILE_ERROR_CHANNELVAL, $error);
+            }
+            foreach ($failures['warnings'] as $warning) {
+                $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_CHANNELVAL, $warning);
+            }
+        }
+        if ($this->_isValid && $state == PEAR_VALIDATE_PACKAGING && !$nofilechecking) {
+            if ($this->_analyzePhpFiles()) {
+                $this->_isValid = true;
+            }
+        }
+        if ($this->_isValid) {
+            return $this->_isValid = $state;
+        }
+        return $this->_isValid = 0;
+    }
+
+    function _analyzePhpFiles()
+    {
+        if (!$this->_isValid) {
+            return false;
+        }
+        if (!isset($this->_packageFile)) {
+            return false;
+        }
+        $dir_prefix = dirname($this->_packageFile);
+        $common = new PEAR_Common;
+        $log = isset($this->_logger) ? array(&$this->_logger, 'log') :
+            array($common, 'log');
+        $info = $this->getFilelist();
+        foreach ($info as $file => $fa) {
+            if (!file_exists($dir_prefix . DIRECTORY_SEPARATOR . $file)) {
+                $this->_validateError(PEAR_PACKAGEFILE_ERROR_FILE_NOTFOUND,
+                    array('file' => realpath($dir_prefix) . DIRECTORY_SEPARATOR . $file));
+                continue;
+            }
+            if ($fa['role'] == 'php' && $dir_prefix) {
+                call_user_func_array($log, array(1, "Analyzing $file"));
+                $srcinfo = $this->_analyzeSourceCode($dir_prefix . DIRECTORY_SEPARATOR . $file);
+                if ($srcinfo) {
+                    $this->_buildProvidesArray($srcinfo);
+                }
+            }
+        }
+        $this->_packageName = $pn = $this->getPackage();
+        $pnl = strlen($pn);
+        if (isset($this->_packageInfo['provides'])) {
+            foreach ((array) $this->_packageInfo['provides'] as $key => $what) {
+                if (isset($what['explicit'])) {
+                    // skip conformance checks if the provides entry is
+                    // specified in the package.xml file
+                    continue;
+                }
+                extract($what);
+                if ($type == 'class') {
+                    if (!strncasecmp($name, $pn, $pnl)) {
+                        continue;
+                    }
+                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX,
+                        array('file' => $file, 'type' => $type, 'name' => $name, 'package' => $pn));
+                } elseif ($type == 'function') {
+                    if (strstr($name, '::') || !strncasecmp($name, $pn, $pnl)) {
+                        continue;
+                    }
+                    $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_NO_PNAME_PREFIX,
+                        array('file' => $file, 'type' => $type, 'name' => $name, 'package' => $pn));
+                }
+            }
+        }
+        return $this->_isValid;
+    }
+
+    /**
+     * Get the default xml generator object
+     *
+     * @return PEAR_PackageFile_Generator_v1
+     */
+    function &getDefaultGenerator()
+    {
+        if (!class_exists('PEAR_PackageFile_Generator_v1')) {
+            require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/PackageFile/Generator/v1.php';
+        }
+        $a = &new PEAR_PackageFile_Generator_v1($this);
+        return $a;
+    }
+
+    /**
+     * Get the contents of a file listed within the package.xml
+     * @param string
+     * @return string
+     */
+    function getFileContents($file)
+    {
+        if ($this->_archiveFile == $this->_packageFile) { // unpacked
+            $dir = dirname($this->_packageFile);
+            $file = $dir . DIRECTORY_SEPARATOR . $file;
+            $file = str_replace(array('/', '\\'),
+                array(DIRECTORY_SEPARATOR, DIRECTORY_SEPARATOR), $file);
+            if (file_exists($file) && is_readable($file)) {
+                return implode('', file($file));
+            }
+        } else { // tgz
+            if (!class_exists('Archive_Tar')) {
+                require_once 'phar://install-pear-nozlib.phar/' . 'Archive/Tar.php';
+            }
+            $tar = &new Archive_Tar($this->_archiveFile);
+            $tar->pushErrorHandling(PEAR_ERROR_RETURN);
+            if ($file != 'package.xml' && $file != 'package2.xml') {
+                $file = $this->getPackage() . '-' . $this->getVersion() . '/' . $file;
+            }
+            $file = $tar->extractInString($file);
+            $tar->popErrorHandling();
+            if (PEAR::isError($file)) {
+                return PEAR::raiseError("Cannot locate file '$file' in archive");
+            }
+            return $file;
+        }
+    }
+
+    // {{{ analyzeSourceCode()
+    /**
+     * Analyze the source code of the given PHP file
+     *
+     * @param  string Filename of the PHP file
+     * @return mixed
+     * @access private
+     */
+    function _analyzeSourceCode($file)
+    {
+        if (!function_exists("token_get_all")) {
+            return false;
+        }
+        if (!defined('T_DOC_COMMENT')) {
+            define('T_DOC_COMMENT', T_COMMENT);
+        }
+        if (!defined('T_INTERFACE')) {
+            define('T_INTERFACE', -1);
+        }
+        if (!defined('T_IMPLEMENTS')) {
+            define('T_IMPLEMENTS', -1);
+        }
+        if (!$fp = @fopen($file, "r")) {
+            return false;
+        }
+        fclose($fp);
+        $contents = file_get_contents($file);
+        $tokens = token_get_all($contents);
+/*
+        for ($i = 0; $i < sizeof($tokens); $i++) {
+            @list($token, $data) = $tokens[$i];
+            if (is_string($token)) {
+                var_dump($token);
+            } else {
+                print token_name($token) . ' ';
+                var_dump(rtrim($data));
+            }
+        }
+*/
+        $look_for = 0;
+        $paren_level = 0;
+        $bracket_level = 0;
+        $brace_level = 0;
+        $lastphpdoc = '';
+        $current_class = '';
+        $current_interface = '';
+        $current_class_level = -1;
+        $current_function = '';
+        $current_function_level = -1;
+        $declared_classes = array();
+        $declared_interfaces = array();
+        $declared_functions = array();
+        $declared_methods = array();
+        $used_classes = array();
+        $used_functions = array();
+        $extends = array();
+        $implements = array();
+        $nodeps = array();
+        $inquote = false;
+        $interface = false;
+        for ($i = 0; $i < sizeof($tokens); $i++) {
+            if (is_array($tokens[$i])) {
+                list($token, $data) = $tokens[$i];
+            } else {
+                $token = $tokens[$i];
+                $data = '';
+            }
+            if ($inquote) {
+                if ($token != '"' && $token != T_END_HEREDOC) {
+                    continue;
+                } else {
+                    $inquote = false;
+                    continue;
+                }
+            }
+            switch ($token) {
+                case T_WHITESPACE :
+                    continue;
+                case ';':
+                    if ($interface) {
+                        $current_function = '';
+                        $current_function_level = -1;
+                    }
+                    break;
+                case '"':
+                case T_START_HEREDOC:
+                    $inquote = true;
+                    break;
+                case T_CURLY_OPEN:
+                case T_DOLLAR_OPEN_CURLY_BRACES:
+                case '{': $brace_level++; continue 2;
+                case '}':
+                    $brace_level--;
+                    if ($current_class_level == $brace_level) {
+                        $current_class = '';
+                        $current_class_level = -1;
+                    }
+                    if ($current_function_level == $brace_level) {
+                        $current_function = '';
+                        $current_function_level = -1;
+                    }
+                    continue 2;
+                case '[': $bracket_level++; continue 2;
+                case ']': $bracket_level--; continue 2;
+                case '(': $paren_level++;   continue 2;
+                case ')': $paren_level--;   continue 2;
+                case T_INTERFACE:
+                    $interface = true;
+                case T_CLASS:
+                    if (($current_class_level != -1) || ($current_function_level != -1)) {
+                        $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE,
+                            array('file' => $file));
+                        return false;
+                    }
+                case T_FUNCTION:
+                case T_NEW:
+                case T_EXTENDS:
+                case T_IMPLEMENTS:
+                    $look_for = $token;
+                    continue 2;
+                case T_STRING:
+                    if (version_compare(zend_version(), '2.0', '<')) {
+                        if (in_array(strtolower($data),
+                            array('public', 'private', 'protected', 'abstract',
+                                  'interface', 'implements', 'throw') 
+                                 )) {
+                            $this->_validateWarning(PEAR_PACKAGEFILE_ERROR_PHP5,
+                                array($file));
+                        }
+                    }
+                    if ($look_for == T_CLASS) {
+                        $current_class = $data;
+                        $current_class_level = $brace_level;
+                        $declared_classes[] = $current_class;
+                    } elseif ($look_for == T_INTERFACE) {
+                        $current_interface = $data;
+                        $current_class_level = $brace_level;
+                        $declared_interfaces[] = $current_interface;
+                    } elseif ($look_for == T_IMPLEMENTS) {
+                        $implements[$current_class] = $data;
+                    } elseif ($look_for == T_EXTENDS) {
+                        $extends[$current_class] = $data;
+                    } elseif ($look_for == T_FUNCTION) {
+                        if ($current_class) {
+                            $current_function = "$current_class::$data";
+                            $declared_methods[$current_class][] = $data;
+                        } elseif ($current_interface) {
+                            $current_function = "$current_interface::$data";
+                            $declared_methods[$current_interface][] = $data;
+                        } else {
+                            $current_function = $data;
+                            $declared_functions[] = $current_function;
+                        }
+                        $current_function_level = $brace_level;
+                        $m = array();
+                    } elseif ($look_for == T_NEW) {
+                        $used_classes[$data] = true;
+                    }
+                    $look_for = 0;
+                    continue 2;
+                case T_VARIABLE:
+                    $look_for = 0;
+                    continue 2;
+                case T_DOC_COMMENT:
+                case T_COMMENT:
+                    if (preg_match('!^/\*\*\s!', $data)) {
+                        $lastphpdoc = $data;
+                        if (preg_match_all('/@nodep\s+(\S+)/', $lastphpdoc, $m)) {
+                            $nodeps = array_merge($nodeps, $m[1]);
+                        }
+                    }
+                    continue 2;
+                case T_DOUBLE_COLON:
+                    if (!($tokens[$i - 1][0] == T_WHITESPACE || $tokens[$i - 1][0] == T_STRING)) {
+                        $this->_validateError(PEAR_PACKAGEFILE_ERROR_INVALID_PHPFILE,
+                            array('file' => $file));
+                        return false;
+                    }
+                    $class = $tokens[$i - 1][1];
+                    if (strtolower($class) != 'parent') {
+                        $used_classes[$class] = true;
+                    }
+                    continue 2;
+            }
+        }
+        return array(
+            "source_file" => $file,
+            "declared_classes" => $declared_classes,
+            "declared_interfaces" => $declared_interfaces,
+            "declared_methods" => $declared_methods,
+            "declared_functions" => $declared_functions,
+            "used_classes" => array_diff(array_keys($used_classes), $nodeps),
+            "inheritance" => $extends,
+            "implements" => $implements,
+            );
+    }
+
+    /**
+     * Build a "provides" array from data returned by
+     * analyzeSourceCode().  The format of the built array is like
+     * this:
+     *
+     *  array(
+     *    'class;MyClass' => 'array('type' => 'class', 'name' => 'MyClass'),
+     *    ...
+     *  )
+     *
+     *
+     * @param array $srcinfo array with information about a source file
+     * as returned by the analyzeSourceCode() method.
+     *
+     * @return void
+     *
+     * @access private
+     *
+     */
+    function _buildProvidesArray($srcinfo)
+    {
+        if (!$this->_isValid) {
+            return false;
+        }
+        $file = basename($srcinfo['source_file']);
+        $pn = $this->getPackage();
+        $pnl = strlen($pn);
+        foreach ($srcinfo['declared_classes'] as $class) {
+            $key = "class;$class";
+            if (isset($this->_packageInfo['provides'][$key])) {
+                continue;
+            }
+            $this->_packageInfo['provides'][$key] =
+                array('file'=> $file, 'type' => 'class', 'name' => $class);
+            if (isset($srcinfo['inheritance'][$class])) {
+                $this->_packageInfo['provides'][$key]['extends'] =
+                    $srcinfo['inheritance'][$class];
+            }
+        }
+        foreach ($srcinfo['declared_methods'] as $class => $methods) {
+            foreach ($methods as $method) {
+                $function = "$class::$method";
+                $key = "function;$function";
+                if ($method{0} == '_' || !strcasecmp($method, $class) ||
+                    isset($this->_packageInfo['provides'][$key])) {
+                    continue;
+                }
+                $this->_packageInfo['provides'][$key] =
+                    array('file'=> $file, 'type' => 'function', 'name' => $function);
+            }
+        }
+
+        foreach ($srcinfo['declared_functions'] as $function) {
+            $key = "function;$function";
+            if ($function{0} == '_' || isset($this->_packageInfo['provides'][$key])) {
+                continue;
+            }
+            if (!strstr($function, '::') && strncasecmp($function, $pn, $pnl)) {
+                $warnings[] = "in1 " . $file . ": function \"$function\" not prefixed with package name \"$pn\"";
+            }
+            $this->_packageInfo['provides'][$key] =
+                array('file'=> $file, 'type' => 'function', 'name' => $function);
+        }
+    }
+
+    // }}}
+}
+?>
 <?php
 /**
  * PEAR_PackageFile_v2, package.xml version 2.0
@@ -77374,7 +77970,7 @@ class PEAR_PackageFile_v1
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: v2.php,v 1.145 2009/02/24 23:39:16 dufuz Exp $
+ * @version    CVS: $Id: v2.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -77388,7 +77984,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ErrorStack.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -79419,7 +80015,7 @@ class PEAR_PackageFile_v2
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Validator.php,v 1.110 2009/03/27 19:29:31 dufuz Exp $
+ * @version    CVS: $Id: Validator.php 277885 2009-03-27 19:29:31Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a8
  */
@@ -79431,7 +80027,7 @@ class PEAR_PackageFile_v2
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a8
  * @access private
@@ -79522,7 +80118,7 @@ class PEAR_PackageFile_v2_Validator
               isset($test['dependencies']['required']) &&
               isset($test['dependencies']['required']['pearinstaller']) &&
               isset($test['dependencies']['required']['pearinstaller']['min']) &&
-              version_compare('1.8.0',
+              version_compare('1.9.0',
                 $test['dependencies']['required']['pearinstaller']['min'], '<')
         ) {
             $this->_pearVersionTooLow($test['dependencies']['required']['pearinstaller']['min']);
@@ -80761,7 +81357,7 @@ class PEAR_PackageFile_v2_Validator
         $this->_stack->push(__FUNCTION__, 'error',
             array('version' => $version),
             'This package.xml requires PEAR version %version% to parse properly, we are ' .
-            'version 1.8.0');
+            'version 1.9.0');
     }
 
     function _invalidTagOrder($oktags, $actual, $root)
@@ -81561,2357 +82157,2400 @@ class PEAR_PackageFile_v2_Validator
 
         return $providesret;
     }
-}<?php
-/**
- * PEAR_Registry
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Stig Bakken <ssb at php.net>
- * @author     Tomas V. V. Cox <cox at idecnet.com>
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Registry.php,v 1.179 2009/04/10 19:42:18 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 0.1
- */
-
-/**
- * for PEAR_Error
- */
-require_once 'phar://install-pear-nozlib.phar/' . 'PEAR.php';
-require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/DependencyDB.php';
-
-define('PEAR_REGISTRY_ERROR_LOCK',         -2);
-define('PEAR_REGISTRY_ERROR_FORMAT',       -3);
-define('PEAR_REGISTRY_ERROR_FILE',         -4);
-define('PEAR_REGISTRY_ERROR_CONFLICT',     -5);
-define('PEAR_REGISTRY_ERROR_CHANNEL_FILE', -6);
-
-/**
- * Administration class used to maintain the installed package database.
- * @category   pear
- * @package    PEAR
- * @author     Stig Bakken <ssb at php.net>
- * @author     Tomas V. V. Cox <cox at idecnet.com>
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a1
- */
-class PEAR_Registry extends PEAR
-{
-    /**
-     * File containing all channel information.
-     * @var string
-     */
-    var $channels = '';
-
-    /** Directory where registry files are stored.
-     * @var string
-     */
-    var $statedir = '';
-
-    /** File where the file map is stored
-     * @var string
-     */
-    var $filemap = '';
-
-    /** Directory where registry files for channels are stored.
-     * @var string
-     */
-    var $channelsdir = '';
-
-    /** Name of file used for locking the registry
-     * @var string
-     */
-    var $lockfile = '';
-
-    /** File descriptor used during locking
-     * @var resource
-     */
-    var $lock_fp = null;
-
-    /** Mode used during locking
-     * @var int
-     */
-    var $lock_mode = 0; // XXX UNUSED
-
-    /** Cache of package information.  Structure:
-     * array(
-     *   'package' => array('id' => ... ),
-     *   ... )
-     * @var array
-     */
-    var $pkginfo_cache = array();
-
-    /** Cache of file map.  Structure:
-     * array( '/path/to/file' => 'package', ... )
-     * @var array
-     */
-    var $filemap_cache = array();
-
-    /**
-     * @var false|PEAR_ChannelFile
-     */
-    var $_pearChannel;
-
-    /**
-     * @var false|PEAR_ChannelFile
-     */
-    var $_peclChannel;
-
-    /**
-     * @var false|PEAR_ChannelFile
-     */
-    var $_docChannel;
-
-    /**
-     * @var PEAR_DependencyDB
-     */
-    var $_dependencyDB;
-
-    /**
-     * @var PEAR_Config
-     */
-    var $_config;
-
-    /**
-     * PEAR_Registry constructor.
-     *
-     * @param string (optional) PEAR install directory (for .php files)
-     * @param PEAR_ChannelFile PEAR_ChannelFile object representing the PEAR channel, if
-     *        default values are not desired.  Only used the very first time a PEAR
-     *        repository is initialized
-     * @param PEAR_ChannelFile PEAR_ChannelFile object representing the PECL channel, if
-     *        default values are not desired.  Only used the very first time a PEAR
-     *        repository is initialized
-     *
-     * @access public
-     */
-    function PEAR_Registry($pear_install_dir = PEAR_INSTALL_DIR, $pear_channel = false,
-                           $pecl_channel = false)
-    {
-        parent::PEAR();
-        $this->setInstallDir($pear_install_dir);
-        $this->_pearChannel = $pear_channel;
-        $this->_peclChannel = $pecl_channel;
-        $this->_config      = false;
-    }
-
-    function setInstallDir($pear_install_dir = PEAR_INSTALL_DIR)
-    {
-        $ds = DIRECTORY_SEPARATOR;
-        $this->install_dir = $pear_install_dir;
-        $this->channelsdir = $pear_install_dir.$ds.'.channels';
-        $this->statedir    = $pear_install_dir.$ds.'.registry';
-        $this->filemap     = $pear_install_dir.$ds.'.filemap';
-        $this->lockfile    = $pear_install_dir.$ds.'.lock';
-    }
-
-    function hasWriteAccess()
-    {
-        if (!file_exists($this->install_dir)) {
-            $dir = $this->install_dir;
-            while ($dir && $dir != '.') {
-                $olddir = $dir;
-                $dir    = dirname($dir);
-                if ($dir != '.' && file_exists($dir)) {
-                    if (is_writeable($dir)) {
-                        return true;
-                    }
-
-                    return false;
-                }
-
-                if ($dir == $olddir) { // this can happen in safe mode
-                    return @is_writable($dir);
-                }
-            }
-
-            return false;
-        }
-
-        return is_writeable($this->install_dir);
-    }
-
-    function setConfig(&$config, $resetInstallDir = true)
-    {
-        $this->_config = &$config;
-        if ($resetInstallDir) {
-            $this->setInstallDir($config->get('php_dir'));
-        }
-    }
-
-    function _initializeChannelDirs()
-    {
-        static $running = false;
-        if (!$running) {
-            $running = true;
-            $ds = DIRECTORY_SEPARATOR;
-            if (!is_dir($this->channelsdir) ||
-                  !file_exists($this->channelsdir . $ds . 'pear.php.net.reg') ||
-                  !file_exists($this->channelsdir . $ds . 'pecl.php.net.reg') ||
-                  !file_exists($this->channelsdir . $ds . 'doc.php.net.reg') ||
-                  !file_exists($this->channelsdir . $ds . '__uri.reg')) {
-                if (!file_exists($this->channelsdir . $ds . 'pear.php.net.reg')) {
-                    $pear_channel = $this->_pearChannel;
-                    if (!is_a($pear_channel, 'PEAR_ChannelFile') || !$pear_channel->validate()) {
-                        if (!class_exists('PEAR_ChannelFile')) {
-                            require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
-                        }
-
-                        $pear_channel = new PEAR_ChannelFile;
-                        $pear_channel->setName('pear.php.net');
-                        $pear_channel->setAlias('pear');
-                        $pear_channel->setServer('pear.php.net');
-                        $pear_channel->setSummary('PHP Extension and Application Repository');
-                        $pear_channel->setDefaultPEARProtocols();
-                        $pear_channel->setBaseURL('REST1.0', 'http://pear.php.net/rest/');
-                        $pear_channel->setBaseURL('REST1.1', 'http://pear.php.net/rest/');
-                    } else {
-                        $pear_channel->setName('pear.php.net');
-                        $pear_channel->setAlias('pear');
-                    }
-
-                    $pear_channel->validate();
-                    $this->_addChannel($pear_channel);
-                }
-
-                if (!file_exists($this->channelsdir . $ds . 'pecl.php.net.reg')) {
-                    $pecl_channel = $this->_peclChannel;
-                    if (!is_a($pecl_channel, 'PEAR_ChannelFile') || !$pecl_channel->validate()) {
-                        if (!class_exists('PEAR_ChannelFile')) {
-                            require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
-                        }
-
-                        $pecl_channel = new PEAR_ChannelFile;
-                        $pecl_channel->setName('pecl.php.net');
-                        $pecl_channel->setAlias('pecl');
-                        $pecl_channel->setServer('pecl.php.net');
-                        $pecl_channel->setSummary('PHP Extension Community Library');
-                        $pecl_channel->setDefaultPEARProtocols();
-                        $pecl_channel->setBaseURL('REST1.0', 'http://pecl.php.net/rest/');
-                        $pecl_channel->setBaseURL('REST1.1', 'http://pecl.php.net/rest/');
-                        $pecl_channel->setValidationPackage('PEAR_Validator_PECL', '1.0');
-                    } else {
-                        $pecl_channel->setName('pecl.php.net');
-                        $pecl_channel->setAlias('pecl');
-                    }
-
-                    $pecl_channel->validate();
-                    $this->_addChannel($pecl_channel);
-                }
-
-                if (!file_exists($this->channelsdir . $ds . 'doc.php.net.reg')) {
-                    $doc_channel = $this->_docChannel;
-                    if (!is_a($doc_channel, 'PEAR_ChannelFile') || !$doc_channel->validate()) {
-                        if (!class_exists('PEAR_ChannelFile')) {
-                            require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
-                        }
-
-                        $doc_channel = new PEAR_ChannelFile;
-                        $doc_channel->setName('doc.php.net');
-                        $doc_channel->setAlias('phpdocs');
-                        $doc_channel->setServer('doc.php.net');
-                        $doc_channel->setSummary('PHP Documentation Team');
-                        $doc_channel->setDefaultPEARProtocols();
-                        $doc_channel->setBaseURL('REST1.0', 'http://doc.php.net/Chiara_PEAR_Server_REST/');
-                        $doc_channel->setBaseURL('REST1.1', 'http://doc.php.net/Chiara_PEAR_Server_REST/');
-                    } else {
-                        $doc_channel->setName('doc.php.net');
-                        $doc_channel->setAlias('doc');
-                    }
-
-                    $doc_channel->validate();
-                    $this->_addChannel($doc_channel);
-                }
-
-                if (!file_exists($this->channelsdir . $ds . '__uri.reg')) {
-                    if (!class_exists('PEAR_ChannelFile')) {
-                        require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
-                    }
-
-                    $private = new PEAR_ChannelFile;
-                    $private->setName('__uri');
-                    $private->setDefaultPEARProtocols();
-                    $private->setBaseURL('REST1.0', '****');
-                    $private->setSummary('Pseudo-channel for static packages');
-                    $this->_addChannel($private);
-                }
-                $this->_rebuildFileMap();
-            }
-
-            $running = false;
-        }
-    }
-
-    function _initializeDirs()
-    {
-        $ds = DIRECTORY_SEPARATOR;
-        // XXX Compatibility code should be removed in the future
-        // rename all registry files if any to lowercase
-        if (!OS_WINDOWS && file_exists($this->statedir) && is_dir($this->statedir) &&
-              $handle = opendir($this->statedir)) {
-            $dest = $this->statedir . $ds;
-            while (false !== ($file = readdir($handle))) {
-                if (preg_match('/^.*[A-Z].*\.reg\\z/', $file)) {
-                    rename($dest . $file, $dest . strtolower($file));
-                }
-            }
-            closedir($handle);
-        }
-
-        $this->_initializeChannelDirs();
-        if (!file_exists($this->filemap)) {
-            $this->_rebuildFileMap();
-        }
-        $this->_initializeDepDB();
-    }
-
-    function _initializeDepDB()
-    {
-        if (!isset($this->_dependencyDB)) {
-            static $initializing = false;
-            if (!$initializing) {
-                $initializing = true;
-                if (!$this->_config) { // never used?
-                    $file = OS_WINDOWS ? 'pear.ini' : '.pearrc';
-                    $this->_config = &new PEAR_Config($this->statedir . DIRECTORY_SEPARATOR .
-                        $file);
-                    $this->_config->setRegistry($this);
-                    $this->_config->set('php_dir', $this->install_dir);
-                }
-
-                $this->_dependencyDB = &PEAR_DependencyDB::singleton($this->_config);
-                if (PEAR::isError($this->_dependencyDB)) {
-                    // attempt to recover by removing the dep db
-                    if (file_exists($this->_config->get('php_dir', null, 'pear.php.net') .
-                        DIRECTORY_SEPARATOR . '.depdb')) {
-                        @unlink($this->_config->get('php_dir', null, 'pear.php.net') .
-                            DIRECTORY_SEPARATOR . '.depdb');
-                    }
-
-                    $this->_dependencyDB = &PEAR_DependencyDB::singleton($this->_config);
-                    if (PEAR::isError($this->_dependencyDB)) {
-                        echo $this->_dependencyDB->getMessage();
-                        echo 'Unrecoverable error';
-                        exit(1);
-                    }
-                }
-
-                $initializing = false;
-            }
-        }
-    }
-
-    /**
-     * PEAR_Registry destructor.  Makes sure no locks are forgotten.
-     *
-     * @access private
-     */
-    function _PEAR_Registry()
-    {
-        parent::_PEAR();
-        if (is_resource($this->lock_fp)) {
-            $this->_unlock();
-        }
-    }
-
-    /**
-     * Make sure the directory where we keep registry files exists.
-     *
-     * @return bool TRUE if directory exists, FALSE if it could not be
-     * created
-     *
-     * @access private
-     */
-    function _assertStateDir($channel = false)
-    {
-        if ($channel && $this->_getChannelFromAlias($channel) != 'pear.php.net') {
-            return $this->_assertChannelStateDir($channel);
-        }
-
-        static $init = false;
-        if (!file_exists($this->statedir)) {
-            if (!$this->hasWriteAccess()) {
-                return false;
-            }
-
-            require_once 'phar://install-pear-nozlib.phar/' . 'System.php';
-            if (!System::mkdir(array('-p', $this->statedir))) {
-                return $this->raiseError("could not create directory '{$this->statedir}'");
-            }
-            $init = true;
-        } elseif (!is_dir($this->statedir)) {
-            return $this->raiseError('Cannot create directory ' . $this->statedir . ', ' .
-                'it already exists and is not a directory');
-        }
-
-        $ds = DIRECTORY_SEPARATOR;
-        if (!file_exists($this->channelsdir)) {
-            if (!file_exists($this->channelsdir . $ds . 'pear.php.net.reg') ||
-                  !file_exists($this->channelsdir . $ds . 'pecl.php.net.reg') ||
-                  !file_exists($this->channelsdir . $ds . 'doc.php.net.reg') ||
-                  !file_exists($this->channelsdir . $ds . '__uri.reg')) {
-                $init = true;
-            }
-        } elseif (!is_dir($this->channelsdir)) {
-            return $this->raiseError('Cannot create directory ' . $this->channelsdir . ', ' .
-                'it already exists and is not a directory');
-        }
-
-        if ($init) {
-            static $running = false;
-            if (!$running) {
-                $running = true;
-                $this->_initializeDirs();
-                $running = false;
-                $init = false;
-            }
-        } else {
-            $this->_initializeDepDB();
-        }
-
-        return true;
-    }
-
-    /**
-     * Make sure the directory where we keep registry files exists for a non-standard channel.
-     *
-     * @param string channel name
-     * @return bool TRUE if directory exists, FALSE if it could not be
-     * created
-     *
-     * @access private
-     */
-    function _assertChannelStateDir($channel)
-    {
-        $ds = DIRECTORY_SEPARATOR;
-        if (!$channel || $this->_getChannelFromAlias($channel) == 'pear.php.net') {
-            if (!file_exists($this->channelsdir . $ds . 'pear.php.net.reg')) {
-                $this->_initializeChannelDirs();
-            }
-            return $this->_assertStateDir($channel);
-        }
-
-        $channelDir = $this->_channelDirectoryName($channel);
-        if (!is_dir($this->channelsdir) ||
-              !file_exists($this->channelsdir . $ds . 'pear.php.net.reg')) {
-            $this->_initializeChannelDirs();
-        }
-
-        if (!file_exists($channelDir)) {
-            if (!$this->hasWriteAccess()) {
-                return false;
-            }
-
-            require_once 'phar://install-pear-nozlib.phar/' . 'System.php';
-            if (!System::mkdir(array('-p', $channelDir))) {
-                return $this->raiseError("could not create directory '" . $channelDir .
-                    "'");
-            }
-        } elseif (!is_dir($channelDir)) {
-            return $this->raiseError("could not create directory '" . $channelDir .
-                "', already exists and is not a directory");
-        }
-
-        return true;
-    }
-
-    /**
-     * Make sure the directory where we keep registry files for channels exists
-     *
-     * @return bool TRUE if directory exists, FALSE if it could not be
-     * created
-     *
-     * @access private
-     */
-    function _assertChannelDir()
-    {
-        if (!file_exists($this->channelsdir)) {
-            if (!$this->hasWriteAccess()) {
-                return false;
-            }
-
-            require_once 'phar://install-pear-nozlib.phar/' . 'System.php';
-            if (!System::mkdir(array('-p', $this->channelsdir))) {
-                return $this->raiseError("could not create directory '{$this->channelsdir}'");
-            }
-        } elseif (!is_dir($this->channelsdir)) {
-            return $this->raiseError("could not create directory '{$this->channelsdir}" .
-                "', it already exists and is not a directory");
-        }
-
-        if (!file_exists($this->channelsdir . DIRECTORY_SEPARATOR . '.alias')) {
-            if (!$this->hasWriteAccess()) {
-                return false;
-            }
-
-            require_once 'phar://install-pear-nozlib.phar/' . 'System.php';
-            if (!System::mkdir(array('-p', $this->channelsdir . DIRECTORY_SEPARATOR . '.alias'))) {
-                return $this->raiseError("could not create directory '{$this->channelsdir}/.alias'");
-            }
-        } elseif (!is_dir($this->channelsdir . DIRECTORY_SEPARATOR . '.alias')) {
-            return $this->raiseError("could not create directory '{$this->channelsdir}" .
-                "/.alias', it already exists and is not a directory");
-        }
-
-        return true;
-    }
-
-    /**
-     * Get the name of the file where data for a given package is stored.
-     *
-     * @param string channel name, or false if this is a PEAR package
-     * @param string package name
-     *
-     * @return string registry file name
-     *
-     * @access public
-     */
-    function _packageFileName($package, $channel = false)
-    {
-        if ($channel && $this->_getChannelFromAlias($channel) != 'pear.php.net') {
-            return $this->_channelDirectoryName($channel) . DIRECTORY_SEPARATOR .
-                strtolower($package) . '.reg';
-        }
-
-        return $this->statedir . DIRECTORY_SEPARATOR . strtolower($package) . '.reg';
-    }
-
-    /**
-     * Get the name of the file where data for a given channel is stored.
-     * @param string channel name
-     * @return string registry file name
-     */
-    function _channelFileName($channel, $noaliases = false)
-    {
-        if (!$noaliases) {
-            if (file_exists($this->_getChannelAliasFileName($channel))) {
-                $channel = implode('', file($this->_getChannelAliasFileName($channel)));
-            }
-        }
-        return $this->channelsdir . DIRECTORY_SEPARATOR . str_replace('/', '_',
-            strtolower($channel)) . '.reg';
-    }
-
-    /**
-     * @param string
-     * @return string
-     */
-    function _getChannelAliasFileName($alias)
-    {
-        return $this->channelsdir . DIRECTORY_SEPARATOR . '.alias' .
-              DIRECTORY_SEPARATOR . str_replace('/', '_', strtolower($alias)) . '.txt';
-    }
-
-    /**
-     * Get the name of a channel from its alias
-     */
-    function _getChannelFromAlias($channel)
-    {
-        if (!$this->_channelExists($channel)) {
-            if ($channel == 'pear.php.net') {
-                return 'pear.php.net';
-            }
-
-            if ($channel == 'pecl.php.net') {
-                return 'pecl.php.net';
-            }
-
-            if ($channel == 'doc.php.net') {
-                return 'doc.php.net';
-            }
-
-            if ($channel == '__uri') {
-                return '__uri';
-            }
-
-            return false;
-        }
-
-        $channel = strtolower($channel);
-        if (file_exists($this->_getChannelAliasFileName($channel))) {
-            // translate an alias to an actual channel
-            return implode('', file($this->_getChannelAliasFileName($channel)));
-        }
-
-        return $channel;
-    }
-
-    /**
-     * Get the alias of a channel from its alias or its name
-     */
-    function _getAlias($channel)
-    {
-        if (!$this->_channelExists($channel)) {
-            if ($channel == 'pear.php.net') {
-                return 'pear';
-            }
-
-            if ($channel == 'pecl.php.net') {
-                return 'pecl';
-            }
-
-            if ($channel == 'doc.php.net') {
-                return 'phpdocs';
-            }
-
-            return false;
-        }
-
-        $channel = $this->_getChannel($channel);
-        if (PEAR::isError($channel)) {
-            return $channel;
-        }
-
-        return $channel->getAlias();
-    }
-
-    /**
-     * Get the name of the file where data for a given package is stored.
-     *
-     * @param string channel name, or false if this is a PEAR package
-     * @param string package name
-     *
-     * @return string registry file name
-     *
-     * @access public
-     */
-    function _channelDirectoryName($channel)
-    {
-        if (!$channel || $this->_getChannelFromAlias($channel) == 'pear.php.net') {
-            return $this->statedir;
-        }
-
-        $ch = $this->_getChannelFromAlias($channel);
-        if (!$ch) {
-            $ch = $channel;
-        }
-
-        return $this->statedir . DIRECTORY_SEPARATOR . strtolower('.channel.' .
-            str_replace('/', '_', $ch));
-    }
-
-    function _openPackageFile($package, $mode, $channel = false)
-    {
-        if (!$this->_assertStateDir($channel)) {
-            return null;
-        }
-
-        if (!in_array($mode, array('r', 'rb')) && !$this->hasWriteAccess()) {
-            return null;
-        }
-
-        $file = $this->_packageFileName($package, $channel);
-        if (!file_exists($file) && $mode == 'r' || $mode == 'rb') {
-            return null;
-        }
-
-        $fp = @fopen($file, $mode);
-        if (!$fp) {
-            return null;
-        }
-
-        return $fp;
-    }
-
-    function _closePackageFile($fp)
-    {
-        fclose($fp);
-    }
-
-    function _openChannelFile($channel, $mode)
-    {
-        if (!$this->_assertChannelDir()) {
-            return null;
-        }
-
-        if (!in_array($mode, array('r', 'rb')) && !$this->hasWriteAccess()) {
-            return null;
-        }
-
-        $file = $this->_channelFileName($channel);
-        if (!file_exists($file) && $mode == 'r' || $mode == 'rb') {
-            return null;
-        }
-
-        $fp = @fopen($file, $mode);
-        if (!$fp) {
-            return null;
-        }
-
-        return $fp;
-    }
-
-    function _closeChannelFile($fp)
-    {
-        fclose($fp);
-    }
-
-    function _rebuildFileMap()
-    {
-        if (!class_exists('PEAR_Installer_Role')) {
-            require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Installer/Role.php';
-        }
-
-        $channels = $this->_listAllPackages();
-        $files = array();
-        foreach ($channels as $channel => $packages) {
-            foreach ($packages as $package) {
-                $version = $this->_packageInfo($package, 'version', $channel);
-                $filelist = $this->_packageInfo($package, 'filelist', $channel);
-                if (!is_array($filelist)) {
-                    continue;
-                }
-
-                foreach ($filelist as $name => $attrs) {
-                    if (isset($attrs['attribs'])) {
-                        $attrs = $attrs['attribs'];
-                    }
-
-                    // it is possible for conflicting packages in different channels to
-                    // conflict with data files/doc files
-                    if ($name == 'dirtree') {
-                        continue;
-                    }
-
-                    if (isset($attrs['role']) && !in_array($attrs['role'],
-                          PEAR_Installer_Role::getInstallableRoles())) {
-                        // these are not installed
-                        continue;
-                    }
-
-                    if (isset($attrs['role']) && !in_array($attrs['role'],
-                          PEAR_Installer_Role::getBaseinstallRoles())) {
-                        $attrs['baseinstalldir'] = $package;
-                    }
-
-                    if (isset($attrs['baseinstalldir'])) {
-                        $file = $attrs['baseinstalldir'].DIRECTORY_SEPARATOR.$name;
-                    } else {
-                        $file = $name;
-                    }
-
-                    $file = preg_replace(',^/+,', '', $file);
-                    if ($channel != 'pear.php.net') {
-                        if (!isset($files[$attrs['role']])) {
-                            $files[$attrs['role']] = array();
-                        }
-                        $files[$attrs['role']][$file] = array(strtolower($channel),
-                            strtolower($package));
-                    } else {
-                        if (!isset($files[$attrs['role']])) {
-                            $files[$attrs['role']] = array();
-                        }
-                        $files[$attrs['role']][$file] = strtolower($package);
-                    }
-                }
-            }
-        }
-
-
-        $this->_assertStateDir();
-        if (!$this->hasWriteAccess()) {
-            return false;
-        }
-
-        $fp = @fopen($this->filemap, 'wb');
-        if (!$fp) {
-            return false;
-        }
-
-        $this->filemap_cache = $files;
-        fwrite($fp, serialize($files));
-        fclose($fp);
-        return true;
-    }
-
-    function _readFileMap()
-    {
-        if (!file_exists($this->filemap)) {
-            return array();
-        }
-
-        $fp = @fopen($this->filemap, 'r');
-        if (!$fp) {
-            return $this->raiseError('PEAR_Registry: could not open filemap "' . $this->filemap . '"', PEAR_REGISTRY_ERROR_FILE, null, null, $php_errormsg);
-        }
-
-        clearstatcache();
-        $rt = get_magic_quotes_runtime();
-        set_magic_quotes_runtime(0);
-        $fsize = filesize($this->filemap);
-        fclose($fp);
-        $data = file_get_contents($this->filemap);
-        set_magic_quotes_runtime($rt);
-        $tmp = unserialize($data);
-        if (!$tmp && $fsize > 7) {
-            return $this->raiseError('PEAR_Registry: invalid filemap data', PEAR_REGISTRY_ERROR_FORMAT, null, null, $data);
-        }
-
-        $this->filemap_cache = $tmp;
-        return true;
-    }
-
-    /**
-     * Lock the registry.
-     *
-     * @param integer lock mode, one of LOCK_EX, LOCK_SH or LOCK_UN.
-     *                See flock manual for more information.
-     *
-     * @return bool TRUE on success, FALSE if locking failed, or a
-     *              PEAR error if some other error occurs (such as the
-     *              lock file not being writable).
-     *
-     * @access private
-     */
-    function _lock($mode = LOCK_EX)
-    {
-        if (stristr(php_uname(), 'Windows 9')) {
-            return true;
-        }
-
-        if ($mode != LOCK_UN && is_resource($this->lock_fp)) {
-            // XXX does not check type of lock (LOCK_SH/LOCK_EX)
-            return true;
-        }
-
-        if (!$this->_assertStateDir()) {
-            if ($mode == LOCK_EX) {
-                return $this->raiseError('Registry directory is not writeable by the current user');
-            }
-
-            return true;
-        }
-
-        $open_mode = 'w';
-        // XXX People reported problems with LOCK_SH and 'w'
-        if ($mode === LOCK_SH || $mode === LOCK_UN) {
-            if (!file_exists($this->lockfile)) {
-                touch($this->lockfile);
-            }
-            $open_mode = 'r';
-        }
-
-        if (!is_resource($this->lock_fp)) {
-            $this->lock_fp = @fopen($this->lockfile, $open_mode);
-        }
-
-        if (!is_resource($this->lock_fp)) {
-            $this->lock_fp = null;
-            return $this->raiseError("could not create lock file" .
-                                     (isset($php_errormsg) ? ": " . $php_errormsg : ""));
-        }
-
-        if (!(int)flock($this->lock_fp, $mode)) {
-            switch ($mode) {
-                case LOCK_SH: $str = 'shared';    break;
-                case LOCK_EX: $str = 'exclusive'; break;
-                case LOCK_UN: $str = 'unlock';    break;
-                default:      $str = 'unknown';   break;
-            }
-
-            //is resource at this point, close it on error.
-            fclose($this->lock_fp);
-            $this->lock_fp = null;
-            return $this->raiseError("could not acquire $str lock ($this->lockfile)",
-                                     PEAR_REGISTRY_ERROR_LOCK);
-        }
-
-        return true;
-    }
-
-    function _unlock()
-    {
-        $ret = $this->_lock(LOCK_UN);
-        if (is_resource($this->lock_fp)) {
-            fclose($this->lock_fp);
-        }
-
-        $this->lock_fp = null;
-        return $ret;
-    }
-
-    function _packageExists($package, $channel = false)
-    {
-        return file_exists($this->_packageFileName($package, $channel));
-    }
-
-    /**
-     * Determine whether a channel exists in the registry
-     * @param string Channel name
-     * @param bool if true, then aliases will be ignored
-     * @return boolean
-     */
-    function _channelExists($channel, $noaliases = false)
-    {
-        $a = file_exists($this->_channelFileName($channel, $noaliases));
-        if (!$a && $channel == 'pear.php.net') {
-            return true;
-        }
-
-        if (!$a && $channel == 'pecl.php.net') {
-            return true;
-        }
-
-        if (!$a && $channel == 'doc.php.net') {
-            return true;
-        }
-
-        return $a;
-    }
-
-    /**
-     * @param PEAR_ChannelFile Channel object
-     * @param donotuse
-     * @param string Last-Modified HTTP tag from remote request
-     * @return boolean|PEAR_Error True on creation, false if it already exists
-     */
-    function _addChannel($channel, $update = false, $lastmodified = false)
-    {
-        if (!is_a($channel, 'PEAR_ChannelFile')) {
-            return false;
-        }
-
-        if (!$channel->validate()) {
-            return false;
-        }
-
-        if (file_exists($this->_channelFileName($channel->getName()))) {
-            if (!$update) {
-                return false;
-            }
-
-            $checker = $this->_getChannel($channel->getName());
-            if (PEAR::isError($checker)) {
-                return $checker;
-            }
-
-            if ($channel->getAlias() != $checker->getAlias()) {
-                if (file_exists($this->_getChannelAliasFileName($checker->getAlias()))) {
-                    @unlink($this->_getChannelAliasFileName($checker->getAlias()));
-                }
-            }
-        } else {
-            if ($update && !in_array($channel->getName(), array('pear.php.net', 'pecl.php.net', 'doc.php.net'))) {
-                return false;
-            }
-        }
-
-        $ret = $this->_assertChannelDir();
-        if (PEAR::isError($ret)) {
-            return $ret;
-        }
-
-        $ret = $this->_assertChannelStateDir($channel->getName());
-        if (PEAR::isError($ret)) {
-            return $ret;
-        }
-
-        if ($channel->getAlias() != $channel->getName()) {
-            if (file_exists($this->_getChannelAliasFileName($channel->getAlias())) &&
-                  $this->_getChannelFromAlias($channel->getAlias()) != $channel->getName()) {
-                $channel->setAlias($channel->getName());
-            }
-
-            if (!$this->hasWriteAccess()) {
-                return false;
-            }
-
-            $fp = @fopen($this->_getChannelAliasFileName($channel->getAlias()), 'w');
-            if (!$fp) {
-                return false;
-            }
-
-            fwrite($fp, $channel->getName());
-            fclose($fp);
-        }
-
-        if (!$this->hasWriteAccess()) {
-            return false;
-        }
-
-        $fp = @fopen($this->_channelFileName($channel->getName()), 'wb');
-        if (!$fp) {
-            return false;
-        }
-
-        $info = $channel->toArray();
-        if ($lastmodified) {
-            $info['_lastmodified'] = $lastmodified;
-        } else {
-            $info['_lastmodified'] = date('r');
-        }
-
-        fwrite($fp, serialize($info));
-        fclose($fp);
-        return true;
-    }
-
-    /**
-     * Deletion fails if there are any packages installed from the channel
-     * @param string|PEAR_ChannelFile channel name
-     * @return boolean|PEAR_Error True on deletion, false if it doesn't exist
-     */
-    function _deleteChannel($channel)
-    {
-        if (!is_string($channel)) {
-            if (!is_a($channel, 'PEAR_ChannelFile')) {
-                return false;
-            }
-
-            if (!$channel->validate()) {
-                return false;
-            }
-            $channel = $channel->getName();
-        }
-
-        if ($this->_getChannelFromAlias($channel) == '__uri') {
-            return false;
-        }
-
-        if ($this->_getChannelFromAlias($channel) == 'pecl.php.net') {
-            return false;
-        }
-
-        if ($this->_getChannelFromAlias($channel) == 'doc.php.net') {
-            return false;
-        }
-
-        if (!$this->_channelExists($channel)) {
-            return false;
-        }
-
-        if (!$channel || $this->_getChannelFromAlias($channel) == 'pear.php.net') {
-            return false;
-        }
-
-        $channel = $this->_getChannelFromAlias($channel);
-        if ($channel == 'pear.php.net') {
-            return false;
-        }
-
-        $test = $this->_listChannelPackages($channel);
-        if (count($test)) {
-            return false;
-        }
-
-        $test = @rmdir($this->_channelDirectoryName($channel));
-        if (!$test) {
-            return false;
-        }
-
-        $file = $this->_getChannelAliasFileName($this->_getAlias($channel));
-        if (file_exists($file)) {
-            $test = @unlink($file);
-            if (!$test) {
-                return false;
-            }
-        }
-
-        $file = $this->_channelFileName($channel);
-        $ret = true;
-        if (file_exists($file)) {
-            $ret = @unlink($file);
-        }
-
-        return $ret;
-    }
-
-    /**
-     * Determine whether a channel exists in the registry
-     * @param string Channel Alias
-     * @return boolean
-     */
-    function _isChannelAlias($alias)
-    {
-        return file_exists($this->_getChannelAliasFileName($alias));
-    }
-
-    /**
-     * @param string|null
-     * @param string|null
-     * @param string|null
-     * @return array|null
-     * @access private
-     */
-    function _packageInfo($package = null, $key = null, $channel = 'pear.php.net')
-    {
-        if ($package === null) {
-            if ($channel === null) {
-                $channels = $this->_listChannels();
-                $ret = array();
-                foreach ($channels as $channel) {
-                    $channel = strtolower($channel);
-                    $ret[$channel] = array();
-                    $packages = $this->_listPackages($channel);
-                    foreach ($packages as $package) {
-                        $ret[$channel][] = $this->_packageInfo($package, null, $channel);
-                    }
-                }
-
-                return $ret;
-            }
-
-            $ps = $this->_listPackages($channel);
-            if (!count($ps)) {
-                return array();
-            }
-            return array_map(array(&$this, '_packageInfo'),
-                             $ps, array_fill(0, count($ps), null),
-                             array_fill(0, count($ps), $channel));
-        }
-
-        $fp = $this->_openPackageFile($package, 'r', $channel);
-        if ($fp === null) {
-            return null;
-        }
-
-        $rt = get_magic_quotes_runtime();
-        set_magic_quotes_runtime(0);
-        clearstatcache();
-        $this->_closePackageFile($fp);
-        $data = file_get_contents($this->_packageFileName($package, $channel));
-        set_magic_quotes_runtime($rt);
-        $data = unserialize($data);
-        if ($key === null) {
-            return $data;
-        }
-
-        // compatibility for package.xml version 2.0
-        if (isset($data['old'][$key])) {
-            return $data['old'][$key];
-        }
-
-        if (isset($data[$key])) {
-            return $data[$key];
-        }
-
-        return null;
-    }
-
-    /**
-     * @param string Channel name
-     * @param bool whether to strictly retrieve info of channels, not just aliases
-     * @return array|null
-     */
-    function _channelInfo($channel, $noaliases = false)
-    {
-        if (!$this->_channelExists($channel, $noaliases)) {
-            return null;
-        }
-
-        $fp = $this->_openChannelFile($channel, 'r');
-        if ($fp === null) {
-            return null;
-        }
-
-        $rt = get_magic_quotes_runtime();
-        set_magic_quotes_runtime(0);
-        clearstatcache();
-        $this->_closeChannelFile($fp);
-        $data = file_get_contents($this->_channelFileName($channel));
-        set_magic_quotes_runtime($rt);
-        $data = unserialize($data);
-        return $data;
-    }
-
-    function _listChannels()
-    {
-        $channellist = array();
-        if (!file_exists($this->channelsdir) || !is_dir($this->channelsdir)) {
-            return array('pear.php.net', 'pecl.php.net', 'doc.php.net', '__uri');
-        }
-
-        $dp = opendir($this->channelsdir);
-        while ($ent = readdir($dp)) {
-            if ($ent{0} == '.' || substr($ent, -4) != '.reg') {
-                continue;
-            }
-
-            if ($ent == '__uri.reg') {
-                $channellist[] = '__uri';
-                continue;
-            }
-
-            $channellist[] = str_replace('_', '/', substr($ent, 0, -4));
-        }
-
-        closedir($dp);
-        if (!in_array('pear.php.net', $channellist)) {
-            $channellist[] = 'pear.php.net';
-        }
-
-        if (!in_array('pecl.php.net', $channellist)) {
-            $channellist[] = 'pecl.php.net';
-        }
-
-        if (!in_array('doc.php.net', $channellist)) {
-            $channellist[] = 'doc.php.net';
-        }
-
-
-        if (!in_array('__uri', $channellist)) {
-            $channellist[] = '__uri';
-        }
-
-        natsort($channellist);
-        return $channellist;
-    }
-
-    function _listPackages($channel = false)
-    {
-        if ($channel && $this->_getChannelFromAlias($channel) != 'pear.php.net') {
-            return $this->_listChannelPackages($channel);
-        }
-
-        if (!file_exists($this->statedir) || !is_dir($this->statedir)) {
-            return array();
-        }
-
-        $pkglist = array();
-        $dp = opendir($this->statedir);
-        if (!$dp) {
-            return $pkglist;
-        }
-
-        while ($ent = readdir($dp)) {
-            if ($ent{0} == '.' || substr($ent, -4) != '.reg') {
-                continue;
-            }
-
-            $pkglist[] = substr($ent, 0, -4);
-        }
-        closedir($dp);
-        return $pkglist;
-    }
-
-    function _listChannelPackages($channel)
-    {
-        $pkglist = array();
-        if (!file_exists($this->_channelDirectoryName($channel)) ||
-              !is_dir($this->_channelDirectoryName($channel))) {
-            return array();
-        }
-
-        $dp = opendir($this->_channelDirectoryName($channel));
-        if (!$dp) {
-            return $pkglist;
-        }
-
-        while ($ent = readdir($dp)) {
-            if ($ent{0} == '.' || substr($ent, -4) != '.reg') {
-                continue;
-            }
-            $pkglist[] = substr($ent, 0, -4);
-        }
-
-        closedir($dp);
-        return $pkglist;
-    }
-
-    function _listAllPackages()
-    {
-        $ret = array();
-        foreach ($this->_listChannels() as $channel) {
-            $ret[$channel] = $this->_listPackages($channel);
-        }
-
-        return $ret;
-    }
-
-    /**
-     * Add an installed package to the registry
-     * @param string package name
-     * @param array package info (parsed by PEAR_Common::infoFrom*() methods)
-     * @return bool success of saving
-     * @access private
-     */
-    function _addPackage($package, $info)
-    {
-        if ($this->_packageExists($package)) {
-            return false;
-        }
-
-        $fp = $this->_openPackageFile($package, 'wb');
-        if ($fp === null) {
-            return false;
-        }
-
-        $info['_lastmodified'] = time();
-        fwrite($fp, serialize($info));
-        $this->_closePackageFile($fp);
-        if (isset($info['filelist'])) {
-            $this->_rebuildFileMap();
-        }
-
-        return true;
-    }
-
-    /**
-     * @param PEAR_PackageFile_v1|PEAR_PackageFile_v2
-     * @return bool
-     * @access private
-     */
-    function _addPackage2($info)
-    {
-        if (!is_a($info, 'PEAR_PackageFile_v1') && !is_a($info, 'PEAR_PackageFile_v2')) {
-            return false;
-        }
-
-        if (!$info->validate()) {
-            if (class_exists('PEAR_Common')) {
-                $ui = PEAR_Frontend::singleton();
-                if ($ui) {
-                    foreach ($info->getValidationWarnings() as $err) {
-                        $ui->log($err['message'], true);
-                    }
-                }
-            }
-            return false;
-        }
-
-        $channel = $info->getChannel();
-        $package = $info->getPackage();
-        $save = $info;
-        if ($this->_packageExists($package, $channel)) {
-            return false;
-        }
-
-        if (!$this->_channelExists($channel, true)) {
-            return false;
-        }
-
-        $info = $info->toArray(true);
-        if (!$info) {
-            return false;
-        }
-
-        $fp = $this->_openPackageFile($package, 'wb', $channel);
-        if ($fp === null) {
-            return false;
-        }
-
-        $info['_lastmodified'] = time();
-        fwrite($fp, serialize($info));
-        $this->_closePackageFile($fp);
-        $this->_rebuildFileMap();
-        return true;
-    }
-
-    /**
-     * @param string Package name
-     * @param array parsed package.xml 1.0
-     * @param bool this parameter is only here for BC.  Don't use it.
-     * @access private
-     */
-    function _updatePackage($package, $info, $merge = true)
-    {
-        $oldinfo = $this->_packageInfo($package);
-        if (empty($oldinfo)) {
-            return false;
-        }
-
-        $fp = $this->_openPackageFile($package, 'w');
-        if ($fp === null) {
-            return false;
-        }
-
-        if (is_object($info)) {
-            $info = $info->toArray();
-        }
-        $info['_lastmodified'] = time();
-
-        $newinfo = $info;
-        if ($merge) {
-            $info = array_merge($oldinfo, $info);
-        } else {
-            $diff = $info;
-        }
-
-        fwrite($fp, serialize($info));
-        $this->_closePackageFile($fp);
-        if (isset($newinfo['filelist'])) {
-            $this->_rebuildFileMap();
-        }
-
-        return true;
-    }
-
-    /**
-     * @param PEAR_PackageFile_v1|PEAR_PackageFile_v2
-     * @return bool
-     * @access private
-     */
-    function _updatePackage2($info)
-    {
-        if (!$this->_packageExists($info->getPackage(), $info->getChannel())) {
-            return false;
-        }
-
-        $fp = $this->_openPackageFile($info->getPackage(), 'w', $info->getChannel());
-        if ($fp === null) {
-            return false;
-        }
-
-        $save = $info;
-        $info = $save->getArray(true);
-        $info['_lastmodified'] = time();
-        fwrite($fp, serialize($info));
-        $this->_closePackageFile($fp);
-        $this->_rebuildFileMap();
-        return true;
-    }
-
-    /**
-     * @param string Package name
-     * @param string Channel name
-     * @return PEAR_PackageFile_v1|PEAR_PackageFile_v2|null
-     * @access private
-     */
-    function &_getPackage($package, $channel = 'pear.php.net')
-    {
-        $info = $this->_packageInfo($package, null, $channel);
-        if ($info === null) {
-            return $info;
-        }
-
-        $a = $this->_config;
-        if (!$a) {
-            $this->_config = &new PEAR_Config;
-            $this->_config->set('php_dir', $this->statedir);
-        }
-
-        if (!class_exists('PEAR_PackageFile')) {
-            require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/PackageFile.php';
-        }
-
-        $pkg = &new PEAR_PackageFile($this->_config);
-        $pf = &$pkg->fromArray($info);
-        return $pf;
-    }
-
-    /**
-     * @param string channel name
-     * @param bool whether to strictly retrieve channel names
-     * @return PEAR_ChannelFile|PEAR_Error
-     * @access private
-     */
-    function &_getChannel($channel, $noaliases = false)
-    {
-        $ch = false;
-        if ($this->_channelExists($channel, $noaliases)) {
-            $chinfo = $this->_channelInfo($channel, $noaliases);
-            if ($chinfo) {
-                if (!class_exists('PEAR_ChannelFile')) {
-                    require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
-                }
-
-                $ch = &PEAR_ChannelFile::fromArrayWithErrors($chinfo);
-            }
-        }
-
-        if ($ch) {
-            if ($ch->validate()) {
-                return $ch;
-            }
-
-            foreach ($ch->getErrors(true) as $err) {
-                $message = $err['message'] . "\n";
-            }
-
-            $ch = PEAR::raiseError($message);
-            return $ch;
-        }
-
-        if ($this->_getChannelFromAlias($channel) == 'pear.php.net') {
-            // the registry is not properly set up, so use defaults
-            if (!class_exists('PEAR_ChannelFile')) {
-                require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
-            }
-
-            $pear_channel = new PEAR_ChannelFile;
-            $pear_channel->setName('pear.php.net');
-            $pear_channel->setAlias('pear');
-            $pear_channel->setSummary('PHP Extension and Application Repository');
-            $pear_channel->setDefaultPEARProtocols();
-            $pear_channel->setBaseURL('REST1.0', 'http://pear.php.net/rest/');
-            $pear_channel->setBaseURL('REST1.1', 'http://pear.php.net/rest/');
-            return $pear_channel;
-        }
-
-        if ($this->_getChannelFromAlias($channel) == 'pecl.php.net') {
-            // the registry is not properly set up, so use defaults
-            if (!class_exists('PEAR_ChannelFile')) {
-                require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
-            }
-            $pear_channel = new PEAR_ChannelFile;
-            $pear_channel->setName('pecl.php.net');
-            $pear_channel->setAlias('pecl');
-            $pear_channel->setSummary('PHP Extension Community Library');
-            $pear_channel->setDefaultPEARProtocols();
-            $pear_channel->setBaseURL('REST1.0', 'http://pecl.php.net/rest/');
-            $pear_channel->setBaseURL('REST1.1', 'http://pecl.php.net/rest/');
-            $pear_channel->setValidationPackage('PEAR_Validator_PECL', '1.0');
-            return $pear_channel;
-        }
-
-        if ($this->_getChannelFromAlias($channel) == 'doc.php.net') {
-            // the registry is not properly set up, so use defaults
-            if (!class_exists('PEAR_ChannelFile')) {
-                require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
-            }
-
-            $doc_channel = new PEAR_ChannelFile;
-            $doc_channel->setName('doc.php.net');
-            $doc_channel->setAlias('phpdocs');
-            $doc_channel->setSummary('PHP Documentation Team');
-            $doc_channel->setDefaultPEARProtocols();
-            $doc_channel->setBaseURL('REST1.0', 'http://doc.php.net/Chiara_PEAR_Server_REST/');
-            $doc_channel->setBaseURL('REST1.1', 'http://doc.php.net/Chiara_PEAR_Server_REST/');
-            return $doc_channel;
-        }
-
-
-        if ($this->_getChannelFromAlias($channel) == '__uri') {
-            // the registry is not properly set up, so use defaults
-            if (!class_exists('PEAR_ChannelFile')) {
-                require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
-            }
-
-            $private = new PEAR_ChannelFile;
-            $private->setName('__uri');
-            $private->setDefaultPEARProtocols();
-            $private->setBaseURL('REST1.0', '****');
-            $private->setSummary('Pseudo-channel for static packages');
-            return $private;
-        }
-
-        return $ch;
-    }
-
-    /**
-     * @param string Package name
-     * @param string Channel name
-     * @return bool
-     */
-    function packageExists($package, $channel = 'pear.php.net')
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_packageExists($package, $channel);
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-
-    // {{{ channelExists()
-
-    /**
-     * @param string channel name
-     * @param bool if true, then aliases will be ignored
-     * @return bool
-     */
-    function channelExists($channel, $noaliases = false)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_channelExists($channel, $noaliases);
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-
-    // {{{ isAlias()
-
-    /**
-     * Determines whether the parameter is an alias of a channel
-     * @param string
-     * @return bool
-     */
-    function isAlias($alias)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_isChannelAlias($alias);
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-    // {{{ packageInfo()
-
-    /**
-     * @param string|null
-     * @param string|null
-     * @param string
-     * @return array|null
-     */
-    function packageInfo($package = null, $key = null, $channel = 'pear.php.net')
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_packageInfo($package, $key, $channel);
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-    // {{{ channelInfo()
-
-    /**
-     * Retrieve a raw array of channel data.
-     *
-     * Do not use this, instead use {@link getChannel()} for normal
-     * operations.  Array structure is undefined in this method
-     * @param string channel name
-     * @param bool whether to strictly retrieve information only on non-aliases
-     * @return array|null|PEAR_Error
-     */
-    function channelInfo($channel = null, $noaliases = false)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_channelInfo($channel, $noaliases);
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-
-    /**
-     * @param string
-     */
-    function channelName($channel)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_getChannelFromAlias($channel);
-        $this->_unlock();
-        return $ret;
-    }
-
-    /**
-     * @param string
-     */
-    function channelAlias($channel)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_getAlias($channel);
-        $this->_unlock();
-        return $ret;
-    }
-    // {{{ listPackages()
-
-    function listPackages($channel = false)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_listPackages($channel);
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-    // {{{ listAllPackages()
-
-    function listAllPackages()
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_listAllPackages();
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-    // {{{ listChannel()
-
-    function listChannels()
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = $this->_listChannels();
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-    // {{{ addPackage()
-
-    /**
-     * Add an installed package to the registry
-     * @param string|PEAR_PackageFile_v1|PEAR_PackageFile_v2 package name or object
-     *               that will be passed to {@link addPackage2()}
-     * @param array package info (parsed by PEAR_Common::infoFrom*() methods)
-     * @return bool success of saving
-     */
-    function addPackage($package, $info)
-    {
-        if (is_object($info)) {
-            return $this->addPackage2($info);
-        }
-        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
-            return $e;
-        }
-        $ret = $this->_addPackage($package, $info);
-        $this->_unlock();
-        if ($ret) {
-            if (!class_exists('PEAR_PackageFile_v1')) {
-                require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/PackageFile/v1.php';
-            }
-            $pf = new PEAR_PackageFile_v1;
-            $pf->setConfig($this->_config);
-            $pf->fromArray($info);
-            $this->_dependencyDB->uninstallPackage($pf);
-            $this->_dependencyDB->installPackage($pf);
-        }
-        return $ret;
-    }
-
-    // }}}
-    // {{{ addPackage2()
-
-    function addPackage2($info)
-    {
-        if (!is_object($info)) {
-            return $this->addPackage($info['package'], $info);
-        }
-        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
-            return $e;
-        }
-        $ret = $this->_addPackage2($info);
-        $this->_unlock();
-        if ($ret) {
-            $this->_dependencyDB->uninstallPackage($info);
-            $this->_dependencyDB->installPackage($info);
-        }
-        return $ret;
-    }
-
-    // }}}
-    // {{{ updateChannel()
-
-    /**
-     * For future expandibility purposes, separate this
-     * @param PEAR_ChannelFile
-     */
-    function updateChannel($channel, $lastmodified = null)
-    {
-        if ($channel->getName() == '__uri') {
-            return false;
-        }
-        return $this->addChannel($channel, $lastmodified, true);
-    }
-
-    // }}}
-    // {{{ deleteChannel()
-
-    /**
-     * Deletion fails if there are any packages installed from the channel
-     * @param string|PEAR_ChannelFile channel name
-     * @return boolean|PEAR_Error True on deletion, false if it doesn't exist
-     */
-    function deleteChannel($channel)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
-            return $e;
-        }
-        $ret = $this->_deleteChannel($channel);
-        $this->_unlock();
-        if ($ret && is_a($this->_config, 'PEAR_Config')) {
-            $this->_config->setChannels($this->listChannels());
-        }
-        return $ret;
-    }
-
-    // }}}
-    // {{{ addChannel()
-
-    /**
-     * @param PEAR_ChannelFile Channel object
-     * @param string Last-Modified header from HTTP for caching
-     * @return boolean|PEAR_Error True on creation, false if it already exists
-     */
-    function addChannel($channel, $lastmodified = false, $update = false)
-    {
-        if (!is_a($channel, 'PEAR_ChannelFile')) {
-            return false;
-        }
-        if (!$channel->validate()) {
-            return false;
-        }
-        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
-            return $e;
-        }
-        $ret = $this->_addChannel($channel, $update, $lastmodified);
-        $this->_unlock();
-        if (!$update && $ret && is_a($this->_config, 'PEAR_Config')) {
-            $this->_config->setChannels($this->listChannels());
-        }
-        return $ret;
-    }
-
-    // }}}
-    // {{{ deletePackage()
-
-    function deletePackage($package, $channel = 'pear.php.net')
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
-            return $e;
-        }
-        $file = $this->_packageFileName($package, $channel);
-        if (file_exists($file)) {
-            $ret = @unlink($file);
-        } else {
-            $ret = false;
-        }
-        $this->_rebuildFileMap();
-        $this->_unlock();
-        $p = array('channel' => $channel, 'package' => $package);
-        $this->_dependencyDB->uninstallPackage($p);
-        return $ret;
-    }
-
-    // }}}
-    // {{{ updatePackage()
-
-    function updatePackage($package, $info, $merge = true)
-    {
-        if (is_object($info)) {
-            return $this->updatePackage2($info, $merge);
-        }
-        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
-            return $e;
-        }
-        $ret = $this->_updatePackage($package, $info, $merge);
-        $this->_unlock();
-        if ($ret) {
-            if (!class_exists('PEAR_PackageFile_v1')) {
-                require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/PackageFile/v1.php';
-            }
-            $pf = new PEAR_PackageFile_v1;
-            $pf->setConfig($this->_config);
-            $pf->fromArray($this->packageInfo($package));
-            $this->_dependencyDB->uninstallPackage($pf);
-            $this->_dependencyDB->installPackage($pf);
-        }
-        return $ret;
-    }
-
-    // }}}
-    // {{{ updatePackage2()
-
-    function updatePackage2($info)
-    {
-
-        if (!is_object($info)) {
-            return $this->updatePackage($info['package'], $info, $merge);
-        }
-
-        if (!$info->validate(PEAR_VALIDATE_DOWNLOADING)) {
-            return false;
-        }
-
-        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
-            return $e;
-        }
-
-        $ret = $this->_updatePackage2($info);
-        $this->_unlock();
-        if ($ret) {
-            $this->_dependencyDB->uninstallPackage($info);
-            $this->_dependencyDB->installPackage($info);
-        }
-
-        return $ret;
-    }
-
-    // }}}
-    // {{{ getChannel()
-    /**
-     * @param string channel name
-     * @param bool whether to strictly return raw channels (no aliases)
-     * @return PEAR_ChannelFile|PEAR_Error
-     */
-    function &getChannel($channel, $noaliases = false)
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $ret = &$this->_getChannel($channel, $noaliases);
-        $this->_unlock();
-        if (!$ret) {
-            return PEAR::raiseError('Unknown channel: ' . $channel);
-        }
-        return $ret;
-    }
-
-    // }}}
-    // {{{ getPackage()
-    /**
-     * @param string package name
-     * @param string channel name
-     * @return PEAR_PackageFile_v1|PEAR_PackageFile_v2|null
-     */
-    function &getPackage($package, $channel = 'pear.php.net')
-    {
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        $pf = &$this->_getPackage($package, $channel);
-        $this->_unlock();
-        return $pf;
-    }
-
-    // }}}
-
-    /**
-     * Get PEAR_PackageFile_v[1/2] objects representing the contents of
-     * a dependency group that are installed.
-     *
-     * This is used at uninstall-time
-     * @param array
-     * @return array|false
-     */
-    function getInstalledGroup($group)
-    {
-        $ret = array();
-        if (isset($group['package'])) {
-            if (!isset($group['package'][0])) {
-                $group['package'] = array($group['package']);
-            }
-            foreach ($group['package'] as $package) {
-                $depchannel = isset($package['channel']) ? $package['channel'] : '__uri';
-                $p = &$this->getPackage($package['name'], $depchannel);
-                if ($p) {
-                    $save = &$p;
-                    $ret[] = &$save;
-                }
-            }
-        }
-        if (isset($group['subpackage'])) {
-            if (!isset($group['subpackage'][0])) {
-                $group['subpackage'] = array($group['subpackage']);
-            }
-            foreach ($group['subpackage'] as $package) {
-                $depchannel = isset($package['channel']) ? $package['channel'] : '__uri';
-                $p = &$this->getPackage($package['name'], $depchannel);
-                if ($p) {
-                    $save = &$p;
-                    $ret[] = &$save;
-                }
-            }
-        }
-        if (!count($ret)) {
-            return false;
-        }
-        return $ret;
-    }
-
-    // {{{ getChannelValidator()
-    /**
-     * @param string channel name
-     * @return PEAR_Validate|false
-     */
-    function &getChannelValidator($channel)
-    {
-        $chan = $this->getChannel($channel);
-        if (PEAR::isError($chan)) {
-            return $chan;
-        }
-        $val = $chan->getValidationObject();
-        return $val;
-    }
-    // }}}
-    // {{{ getChannels()
-    /**
-     * @param string channel name
-     * @return array an array of PEAR_ChannelFile objects representing every installed channel
-     */
-    function &getChannels()
-    {
-        $ret = array();
-        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-            return $e;
-        }
-        foreach ($this->_listChannels() as $channel) {
-            $e = &$this->_getChannel($channel);
-            if (!$e || PEAR::isError($e)) {
-                continue;
-            }
-            $ret[] = $e;
-        }
-        $this->_unlock();
-        return $ret;
-    }
-
-    // }}}
-    // {{{ checkFileMap()
-
-    /**
-     * Test whether a file or set of files belongs to a package.
-     *
-     * If an array is passed in
-     * @param string|array file path, absolute or relative to the pear
-     *                     install dir
-     * @param string|array name of PEAR package or array('package' => name, 'channel' =>
-     *                     channel) of a package that will be ignored
-     * @param string API version - 1.1 will exclude any files belonging to a package
-     * @param array private recursion variable
-     * @return array|false which package and channel the file belongs to, or an empty
-     *                     string if the file does not belong to an installed package,
-     *                     or belongs to the second parameter's package
-     */
-    function checkFileMap($path, $package = false, $api = '1.0', $attrs = false)
-    {
-        if (is_array($path)) {
-            static $notempty;
-            if (empty($notempty)) {
-                if (!class_exists('PEAR_Installer_Role')) {
-                    require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Installer/Role.php';
-                }
-                $notempty = create_function('$a','return !empty($a);');
-            }
-            $package = is_array($package) ? array(strtolower($package[0]), strtolower($package[1]))
-                : strtolower($package);
-            $pkgs = array();
-            foreach ($path as $name => $attrs) {
-                if (is_array($attrs)) {
-                    if (isset($attrs['install-as'])) {
-                        $name = $attrs['install-as'];
-                    }
-                    if (!in_array($attrs['role'], PEAR_Installer_Role::getInstallableRoles())) {
-                        // these are not installed
-                        continue;
-                    }
-                    if (!in_array($attrs['role'], PEAR_Installer_Role::getBaseinstallRoles())) {
-                        $attrs['baseinstalldir'] = is_array($package) ? $package[1] : $package;
-                    }
-                    if (isset($attrs['baseinstalldir'])) {
-                        $name = $attrs['baseinstalldir'] . DIRECTORY_SEPARATOR . $name;
-                    }
-                }
-                $pkgs[$name] = $this->checkFileMap($name, $package, $api, $attrs);
-                if (PEAR::isError($pkgs[$name])) {
-                    return $pkgs[$name];
-                }
-            }
-            return array_filter($pkgs, $notempty);
-        }
-        if (empty($this->filemap_cache)) {
-            if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
-                return $e;
-            }
-            $err = $this->_readFileMap();
-            $this->_unlock();
-            if (PEAR::isError($err)) {
-                return $err;
-            }
-        }
-        if (!$attrs) {
-            $attrs = array('role' => 'php'); // any old call would be for PHP role only
-        }
-        if (isset($this->filemap_cache[$attrs['role']][$path])) {
-            if ($api >= '1.1' && $this->filemap_cache[$attrs['role']][$path] == $package) {
-                return false;
-            }
-            return $this->filemap_cache[$attrs['role']][$path];
-        }
-        $l = strlen($this->install_dir);
-        if (substr($path, 0, $l) == $this->install_dir) {
-            $path = preg_replace('!^'.DIRECTORY_SEPARATOR.'+!', '', substr($path, $l));
-        }
-        if (isset($this->filemap_cache[$attrs['role']][$path])) {
-            if ($api >= '1.1' && $this->filemap_cache[$attrs['role']][$path] == $package) {
-                return false;
-            }
-            return $this->filemap_cache[$attrs['role']][$path];
-        }
-        return false;
-    }
-
-    // }}}
-    // {{{ flush()
-    /**
-     * Force a reload of the filemap
-     * @since 1.5.0RC3
-     */
-    function flushFileMap()
-    {
-        $this->filemap_cache = null;
-        clearstatcache(); // ensure that the next read gets the full, current filemap
-    }
-
-    // }}}
-    // {{{ apiVersion()
-    /**
-     * Get the expected API version.  Channels API is version 1.1, as it is backwards
-     * compatible with 1.0
-     * @return string
-     */
-    function apiVersion()
-    {
-        return '1.1';
-    }
-    // }}}
-
-
-    /**
-     * Parse a package name, or validate a parsed package name array
-     * @param string|array pass in an array of format
-     *                     array(
-     *                      'package' => 'pname',
-     *                     ['channel' => 'channame',]
-     *                     ['version' => 'version',]
-     *                     ['state' => 'state',]
-     *                     ['group' => 'groupname'])
-     *                     or a string of format
-     *                     [channel://][channame/]pname[-version|-state][/group=groupname]
-     * @return array|PEAR_Error
-     */
-    function parsePackageName($param, $defaultchannel = 'pear.php.net')
-    {
-        $saveparam = $param;
-        if (is_array($param)) {
-            // convert to string for error messages
-            $saveparam = $this->parsedPackageNameToString($param);
-            // process the array
-            if (!isset($param['package'])) {
-                return PEAR::raiseError('parsePackageName(): array $param ' .
-                    'must contain a valid package name in index "param"',
-                    'package', null, null, $param);
-            }
-            if (!isset($param['uri'])) {
-                if (!isset($param['channel'])) {
-                    $param['channel'] = $defaultchannel;
-                }
-            } else {
-                $param['channel'] = '__uri';
-            }
-        } else {
-            $components = @parse_url((string) $param);
-            if (isset($components['scheme'])) {
-                if ($components['scheme'] == 'http') {
-                    // uri package
-                    $param = array('uri' => $param, 'channel' => '__uri');
-                } elseif($components['scheme'] != 'channel') {
-                    return PEAR::raiseError('parsePackageName(): only channel:// uris may ' .
-                        'be downloaded, not "' . $param . '"', 'invalid', null, null, $param);
-                }
-            }
-            if (!isset($components['path'])) {
-                return PEAR::raiseError('parsePackageName(): array $param ' .
-                    'must contain a valid package name in "' . $param . '"',
-                    'package', null, null, $param);
-            }
-            if (isset($components['host'])) {
-                // remove the leading "/"
-                $components['path'] = substr($components['path'], 1);
-            }
-            if (!isset($components['scheme'])) {
-                if (strpos($components['path'], '/') !== false) {
-                    if ($components['path']{0} == '/') {
-                        return PEAR::raiseError('parsePackageName(): this is not ' .
-                            'a package name, it begins with "/" in "' . $param . '"',
-                            'invalid', null, null, $param);
-                    }
-                    $parts = explode('/', $components['path']);
-                    $components['host'] = array_shift($parts);
-                    if (count($parts) > 1) {
-                        $components['path'] = array_pop($parts);
-                        $components['host'] .= '/' . implode('/', $parts);
-                    } else {
-                        $components['path'] = implode('/', $parts);
-                    }
-                } else {
-                    $components['host'] = $defaultchannel;
-                }
-            } else {
-                if (strpos($components['path'], '/')) {
-                    $parts = explode('/', $components['path']);
-                    $components['path'] = array_pop($parts);
-                    $components['host'] .= '/' . implode('/', $parts);
-                }
-            }
-
-            if (is_array($param)) {
-                $param['package'] = $components['path'];
-            } else {
-                $param = array(
-                    'package' => $components['path']
-                    );
-                if (isset($components['host'])) {
-                    $param['channel'] = $components['host'];
-                }
-            }
-            if (isset($components['fragment'])) {
-                $param['group'] = $components['fragment'];
-            }
-            if (isset($components['user'])) {
-                $param['user'] = $components['user'];
-            }
-            if (isset($components['pass'])) {
-                $param['pass'] = $components['pass'];
-            }
-            if (isset($components['query'])) {
-                parse_str($components['query'], $param['opts']);
-            }
-            // check for extension
-            $pathinfo = pathinfo($param['package']);
-            if (isset($pathinfo['extension']) &&
-                  in_array(strtolower($pathinfo['extension']), array('tgz', 'tar'))) {
-                $param['extension'] = $pathinfo['extension'];
-                $param['package'] = substr($pathinfo['basename'], 0,
-                    strlen($pathinfo['basename']) - 4);
-            }
-            // check for version
-            if (strpos($param['package'], '-')) {
-                $test = explode('-', $param['package']);
-                if (count($test) != 2) {
-                    return PEAR::raiseError('parsePackageName(): only one version/state ' .
-                        'delimiter "-" is allowed in "' . $saveparam . '"',
-                        'version', null, null, $param);
-                }
-                list($param['package'], $param['version']) = $test;
-            }
-        }
-        // validation
-        $info = $this->channelExists($param['channel']);
-        if (PEAR::isError($info)) {
-            return $info;
-        }
-        if (!$info) {
-            return PEAR::raiseError('unknown channel "' . $param['channel'] .
-                '" in "' . $saveparam . '"', 'channel', null, null, $param);
-        }
-        $chan = $this->getChannel($param['channel']);
-        if (PEAR::isError($chan)) {
-            return $chan;
-        }
-        if (!$chan) {
-            return PEAR::raiseError("Exception: corrupt registry, could not " .
-                "retrieve channel " . $param['channel'] . " information",
-                'registry', null, null, $param);
-        }
-        $param['channel'] = $chan->getName();
-        $validate = $chan->getValidationObject();
-        $vpackage = $chan->getValidationPackage();
-        // validate package name
-        if (!$validate->validPackageName($param['package'], $vpackage['_content'])) {
-            return PEAR::raiseError('parsePackageName(): invalid package name "' .
-                $param['package'] . '" in "' . $saveparam . '"',
-                'package', null, null, $param);
-        }
-        if (isset($param['group'])) {
-            if (!PEAR_Validate::validGroupName($param['group'])) {
-                return PEAR::raiseError('parsePackageName(): dependency group "' . $param['group'] .
-                    '" is not a valid group name in "' . $saveparam . '"', 'group', null, null,
-                    $param);
-            }
-        }
-        if (isset($param['state'])) {
-            if (!in_array(strtolower($param['state']), $validate->getValidStates())) {
-                return PEAR::raiseError('parsePackageName(): state "' . $param['state']
-                    . '" is not a valid state in "' . $saveparam . '"',
-                    'state', null, null, $param);
-            }
-        }
-        if (isset($param['version'])) {
-            if (isset($param['state'])) {
-                return PEAR::raiseError('parsePackageName(): cannot contain both ' .
-                    'a version and a stability (state) in "' . $saveparam . '"',
-                    'version/state', null, null, $param);
-            }
-            // check whether version is actually a state
-            if (in_array(strtolower($param['version']), $validate->getValidStates())) {
-                $param['state'] = strtolower($param['version']);
-                unset($param['version']);
-            } else {
-                if (!$validate->validVersion($param['version'])) {
-                    return PEAR::raiseError('parsePackageName(): "' . $param['version'] .
-                        '" is neither a valid version nor a valid state in "' .
-                        $saveparam . '"', 'version/state', null, null, $param);
-                }
-            }
-        }
-        return $param;
-    }
-
-    /**
-     * @param array
-     * @return string
-     */
-    function parsedPackageNameToString($parsed, $brief = false)
-    {
-        if (is_string($parsed)) {
-            return $parsed;
-        }
-        if (is_object($parsed)) {
-            $p = $parsed;
-            $parsed = array(
-                'package' => $p->getPackage(),
-                'channel' => $p->getChannel(),
-                'version' => $p->getVersion(),
-            );
-        }
-        if (isset($parsed['uri'])) {
-            return $parsed['uri'];
-        }
-        if ($brief) {
-            if ($channel = $this->channelAlias($parsed['channel'])) {
-                return $channel . '/' . $parsed['package'];
-            }
-        }
-        $upass = '';
-        if (isset($parsed['user'])) {
-            $upass = $parsed['user'];
-            if (isset($parsed['pass'])) {
-                $upass .= ':' . $parsed['pass'];
-            }
-            $upass = "$upass@";
-        }
-        $ret = 'channel://' . $upass . $parsed['channel'] . '/' . $parsed['package'];
-        if (isset($parsed['version']) || isset($parsed['state'])) {
-            $ver = isset($parsed['version']) ? $parsed['version'] : '';
-            $ver .= isset($parsed['state']) ? $parsed['state'] : '';
-            $ret .= '-' . $ver;
-        }
-        if (isset($parsed['extension'])) {
-            $ret .= '.' . $parsed['extension'];
-        }
-        if (isset($parsed['opts'])) {
-            $ret .= '?';
-            foreach ($parsed['opts'] as $name => $value) {
-                $parsed['opts'][$name] = "$name=$value";
-            }
-            $ret .= implode('&', $parsed['opts']);
-        }
-        if (isset($parsed['group'])) {
-            $ret .= '#' . $parsed['group'];
-        }
-        return $ret;
-    }
+}<?php
+/**
+ * PEAR_Registry
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Stig Bakken <ssb at php.net>
+ * @author     Tomas V. V. Cox <cox at idecnet.com>
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: Registry.php 287555 2009-08-21 21:27:27Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 0.1
+ */
+
+/**
+ * for PEAR_Error
+ */
+require_once 'phar://install-pear-nozlib.phar/' . 'PEAR.php';
+require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/DependencyDB.php';
+
+define('PEAR_REGISTRY_ERROR_LOCK',         -2);
+define('PEAR_REGISTRY_ERROR_FORMAT',       -3);
+define('PEAR_REGISTRY_ERROR_FILE',         -4);
+define('PEAR_REGISTRY_ERROR_CONFLICT',     -5);
+define('PEAR_REGISTRY_ERROR_CHANNEL_FILE', -6);
+
+/**
+ * Administration class used to maintain the installed package database.
+ * @category   pear
+ * @package    PEAR
+ * @author     Stig Bakken <ssb at php.net>
+ * @author     Tomas V. V. Cox <cox at idecnet.com>
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a1
+ */
+class PEAR_Registry extends PEAR
+{
+    /**
+     * File containing all channel information.
+     * @var string
+     */
+    var $channels = '';
+
+    /** Directory where registry files are stored.
+     * @var string
+     */
+    var $statedir = '';
+
+    /** File where the file map is stored
+     * @var string
+     */
+    var $filemap = '';
+
+    /** Directory where registry files for channels are stored.
+     * @var string
+     */
+    var $channelsdir = '';
+
+    /** Name of file used for locking the registry
+     * @var string
+     */
+    var $lockfile = '';
+
+    /** File descriptor used during locking
+     * @var resource
+     */
+    var $lock_fp = null;
+
+    /** Mode used during locking
+     * @var int
+     */
+    var $lock_mode = 0; // XXX UNUSED
+
+    /** Cache of package information.  Structure:
+     * array(
+     *   'package' => array('id' => ... ),
+     *   ... )
+     * @var array
+     */
+    var $pkginfo_cache = array();
+
+    /** Cache of file map.  Structure:
+     * array( '/path/to/file' => 'package', ... )
+     * @var array
+     */
+    var $filemap_cache = array();
+
+    /**
+     * @var false|PEAR_ChannelFile
+     */
+    var $_pearChannel;
+
+    /**
+     * @var false|PEAR_ChannelFile
+     */
+    var $_peclChannel;
+
+    /**
+     * @var false|PEAR_ChannelFile
+     */
+    var $_docChannel;
+
+    /**
+     * @var PEAR_DependencyDB
+     */
+    var $_dependencyDB;
+
+    /**
+     * @var PEAR_Config
+     */
+    var $_config;
+
+    /**
+     * PEAR_Registry constructor.
+     *
+     * @param string (optional) PEAR install directory (for .php files)
+     * @param PEAR_ChannelFile PEAR_ChannelFile object representing the PEAR channel, if
+     *        default values are not desired.  Only used the very first time a PEAR
+     *        repository is initialized
+     * @param PEAR_ChannelFile PEAR_ChannelFile object representing the PECL channel, if
+     *        default values are not desired.  Only used the very first time a PEAR
+     *        repository is initialized
+     *
+     * @access public
+     */
+    function PEAR_Registry($pear_install_dir = PEAR_INSTALL_DIR, $pear_channel = false,
+                           $pecl_channel = false)
+    {
+        parent::PEAR();
+        $this->setInstallDir($pear_install_dir);
+        $this->_pearChannel = $pear_channel;
+        $this->_peclChannel = $pecl_channel;
+        $this->_config      = false;
+    }
+
+    function setInstallDir($pear_install_dir = PEAR_INSTALL_DIR)
+    {
+        $ds = DIRECTORY_SEPARATOR;
+        $this->install_dir = $pear_install_dir;
+        $this->channelsdir = $pear_install_dir.$ds.'.channels';
+        $this->statedir    = $pear_install_dir.$ds.'.registry';
+        $this->filemap     = $pear_install_dir.$ds.'.filemap';
+        $this->lockfile    = $pear_install_dir.$ds.'.lock';
+    }
+
+    function hasWriteAccess()
+    {
+        if (!file_exists($this->install_dir)) {
+            $dir = $this->install_dir;
+            while ($dir && $dir != '.') {
+                $olddir = $dir;
+                $dir    = dirname($dir);
+                if ($dir != '.' && file_exists($dir)) {
+                    if (is_writeable($dir)) {
+                        return true;
+                    }
+
+                    return false;
+                }
+
+                if ($dir == $olddir) { // this can happen in safe mode
+                    return @is_writable($dir);
+                }
+            }
+
+            return false;
+        }
+
+        return is_writeable($this->install_dir);
+    }
+
+    function setConfig(&$config, $resetInstallDir = true)
+    {
+        $this->_config = &$config;
+        if ($resetInstallDir) {
+            $this->setInstallDir($config->get('php_dir'));
+        }
+    }
+
+    function _initializeChannelDirs()
+    {
+        static $running = false;
+        if (!$running) {
+            $running = true;
+            $ds = DIRECTORY_SEPARATOR;
+            if (!is_dir($this->channelsdir) ||
+                  !file_exists($this->channelsdir . $ds . 'pear.php.net.reg') ||
+                  !file_exists($this->channelsdir . $ds . 'pecl.php.net.reg') ||
+                  !file_exists($this->channelsdir . $ds . 'doc.php.net.reg') ||
+                  !file_exists($this->channelsdir . $ds . '__uri.reg')) {
+                if (!file_exists($this->channelsdir . $ds . 'pear.php.net.reg')) {
+                    $pear_channel = $this->_pearChannel;
+                    if (!is_a($pear_channel, 'PEAR_ChannelFile') || !$pear_channel->validate()) {
+                        if (!class_exists('PEAR_ChannelFile')) {
+                            require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
+                        }
+
+                        $pear_channel = new PEAR_ChannelFile;
+                        $pear_channel->setAlias('pear');
+                        $pear_channel->setServer('pear.php.net');
+                        $pear_channel->setSummary('PHP Extension and Application Repository');
+                        $pear_channel->setDefaultPEARProtocols();
+                        $pear_channel->setBaseURL('REST1.0', 'http://pear.php.net/rest/');
+                        $pear_channel->setBaseURL('REST1.1', 'http://pear.php.net/rest/');
+                        $pear_channel->setBaseURL('REST1.3', 'http://pear.php.net/rest/');
+                        //$pear_channel->setBaseURL('REST1.4', 'http://pear.php.net/rest/');
+                    } else {
+                        $pear_channel->setServer('pear.php.net');
+                        $pear_channel->setAlias('pear');
+                    }
+
+                    $pear_channel->validate();
+                    $this->_addChannel($pear_channel);
+                }
+
+                if (!file_exists($this->channelsdir . $ds . 'pecl.php.net.reg')) {
+                    $pecl_channel = $this->_peclChannel;
+                    if (!is_a($pecl_channel, 'PEAR_ChannelFile') || !$pecl_channel->validate()) {
+                        if (!class_exists('PEAR_ChannelFile')) {
+                            require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
+                        }
+
+                        $pecl_channel = new PEAR_ChannelFile;
+                        $pecl_channel->setAlias('pecl');
+                        $pecl_channel->setServer('pecl.php.net');
+                        $pecl_channel->setSummary('PHP Extension Community Library');
+                        $pecl_channel->setDefaultPEARProtocols();
+                        $pecl_channel->setBaseURL('REST1.0', 'http://pecl.php.net/rest/');
+                        $pecl_channel->setBaseURL('REST1.1', 'http://pecl.php.net/rest/');
+                        $pecl_channel->setValidationPackage('PEAR_Validator_PECL', '1.0');
+                    } else {
+                        $pecl_channel->setServer('pecl.php.net');
+                        $pecl_channel->setAlias('pecl');
+                    }
+
+                    $pecl_channel->validate();
+                    $this->_addChannel($pecl_channel);
+                }
+
+                if (!file_exists($this->channelsdir . $ds . 'doc.php.net.reg')) {
+                    $doc_channel = $this->_docChannel;
+                    if (!is_a($doc_channel, 'PEAR_ChannelFile') || !$doc_channel->validate()) {
+                        if (!class_exists('PEAR_ChannelFile')) {
+                            require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
+                        }
+
+                        $doc_channel = new PEAR_ChannelFile;
+                        $doc_channel->setAlias('phpdocs');
+                        $doc_channel->setServer('doc.php.net');
+                        $doc_channel->setSummary('PHP Documentation Team');
+                        $doc_channel->setDefaultPEARProtocols();
+                        $doc_channel->setBaseURL('REST1.0', 'http://doc.php.net/rest/');
+                        $doc_channel->setBaseURL('REST1.1', 'http://doc.php.net/rest/');
+                        $doc_channel->setBaseURL('REST1.3', 'http://doc.php.net/rest/');
+                    } else {
+                        $doc_channel->setServer('doc.php.net');
+                        $doc_channel->setAlias('doc');
+                    }
+
+                    $doc_channel->validate();
+                    $this->_addChannel($doc_channel);
+                }
+
+                if (!file_exists($this->channelsdir . $ds . '__uri.reg')) {
+                    if (!class_exists('PEAR_ChannelFile')) {
+                        require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
+                    }
+
+                    $private = new PEAR_ChannelFile;
+                    $private->setName('__uri');
+                    $private->setDefaultPEARProtocols();
+                    $private->setBaseURL('REST1.0', '****');
+                    $private->setSummary('Pseudo-channel for static packages');
+                    $this->_addChannel($private);
+                }
+                $this->_rebuildFileMap();
+            }
+
+            $running = false;
+        }
+    }
+
+    function _initializeDirs()
+    {
+        $ds = DIRECTORY_SEPARATOR;
+        // XXX Compatibility code should be removed in the future
+        // rename all registry files if any to lowercase
+        if (!OS_WINDOWS && file_exists($this->statedir) && is_dir($this->statedir) &&
+              $handle = opendir($this->statedir)) {
+            $dest = $this->statedir . $ds;
+            while (false !== ($file = readdir($handle))) {
+                if (preg_match('/^.*[A-Z].*\.reg\\z/', $file)) {
+                    rename($dest . $file, $dest . strtolower($file));
+                }
+            }
+            closedir($handle);
+        }
+
+        $this->_initializeChannelDirs();
+        if (!file_exists($this->filemap)) {
+            $this->_rebuildFileMap();
+        }
+        $this->_initializeDepDB();
+    }
+
+    function _initializeDepDB()
+    {
+        if (!isset($this->_dependencyDB)) {
+            static $initializing = false;
+            if (!$initializing) {
+                $initializing = true;
+                if (!$this->_config) { // never used?
+                    $file = OS_WINDOWS ? 'pear.ini' : '.pearrc';
+                    $this->_config = &new PEAR_Config($this->statedir . DIRECTORY_SEPARATOR .
+                        $file);
+                    $this->_config->setRegistry($this);
+                    $this->_config->set('php_dir', $this->install_dir);
+                }
+
+                $this->_dependencyDB = &PEAR_DependencyDB::singleton($this->_config);
+                if (PEAR::isError($this->_dependencyDB)) {
+                    // attempt to recover by removing the dep db
+                    if (file_exists($this->_config->get('php_dir', null, 'pear.php.net') .
+                        DIRECTORY_SEPARATOR . '.depdb')) {
+                        @unlink($this->_config->get('php_dir', null, 'pear.php.net') .
+                            DIRECTORY_SEPARATOR . '.depdb');
+                    }
+
+                    $this->_dependencyDB = &PEAR_DependencyDB::singleton($this->_config);
+                    if (PEAR::isError($this->_dependencyDB)) {
+                        echo $this->_dependencyDB->getMessage();
+                        echo 'Unrecoverable error';
+                        exit(1);
+                    }
+                }
+
+                $initializing = false;
+            }
+        }
+    }
+
+    /**
+     * PEAR_Registry destructor.  Makes sure no locks are forgotten.
+     *
+     * @access private
+     */
+    function _PEAR_Registry()
+    {
+        parent::_PEAR();
+        if (is_resource($this->lock_fp)) {
+            $this->_unlock();
+        }
+    }
+
+    /**
+     * Make sure the directory where we keep registry files exists.
+     *
+     * @return bool TRUE if directory exists, FALSE if it could not be
+     * created
+     *
+     * @access private
+     */
+    function _assertStateDir($channel = false)
+    {
+        if ($channel && $this->_getChannelFromAlias($channel) != 'pear.php.net') {
+            return $this->_assertChannelStateDir($channel);
+        }
+
+        static $init = false;
+        if (!file_exists($this->statedir)) {
+            if (!$this->hasWriteAccess()) {
+                return false;
+            }
+
+            require_once 'phar://install-pear-nozlib.phar/' . 'System.php';
+            if (!System::mkdir(array('-p', $this->statedir))) {
+                return $this->raiseError("could not create directory '{$this->statedir}'");
+            }
+            $init = true;
+        } elseif (!is_dir($this->statedir)) {
+            return $this->raiseError('Cannot create directory ' . $this->statedir . ', ' .
+                'it already exists and is not a directory');
+        }
+
+        $ds = DIRECTORY_SEPARATOR;
+        if (!file_exists($this->channelsdir)) {
+            if (!file_exists($this->channelsdir . $ds . 'pear.php.net.reg') ||
+                  !file_exists($this->channelsdir . $ds . 'pecl.php.net.reg') ||
+                  !file_exists($this->channelsdir . $ds . 'doc.php.net.reg') ||
+                  !file_exists($this->channelsdir . $ds . '__uri.reg')) {
+                $init = true;
+            }
+        } elseif (!is_dir($this->channelsdir)) {
+            return $this->raiseError('Cannot create directory ' . $this->channelsdir . ', ' .
+                'it already exists and is not a directory');
+        }
+
+        if ($init) {
+            static $running = false;
+            if (!$running) {
+                $running = true;
+                $this->_initializeDirs();
+                $running = false;
+                $init = false;
+            }
+        } else {
+            $this->_initializeDepDB();
+        }
+
+        return true;
+    }
+
+    /**
+     * Make sure the directory where we keep registry files exists for a non-standard channel.
+     *
+     * @param string channel name
+     * @return bool TRUE if directory exists, FALSE if it could not be
+     * created
+     *
+     * @access private
+     */
+    function _assertChannelStateDir($channel)
+    {
+        $ds = DIRECTORY_SEPARATOR;
+        if (!$channel || $this->_getChannelFromAlias($channel) == 'pear.php.net') {
+            if (!file_exists($this->channelsdir . $ds . 'pear.php.net.reg')) {
+                $this->_initializeChannelDirs();
+            }
+            return $this->_assertStateDir($channel);
+        }
+
+        $channelDir = $this->_channelDirectoryName($channel);
+        if (!is_dir($this->channelsdir) ||
+              !file_exists($this->channelsdir . $ds . 'pear.php.net.reg')) {
+            $this->_initializeChannelDirs();
+        }
+
+        if (!file_exists($channelDir)) {
+            if (!$this->hasWriteAccess()) {
+                return false;
+            }
+
+            require_once 'phar://install-pear-nozlib.phar/' . 'System.php';
+            if (!System::mkdir(array('-p', $channelDir))) {
+                return $this->raiseError("could not create directory '" . $channelDir .
+                    "'");
+            }
+        } elseif (!is_dir($channelDir)) {
+            return $this->raiseError("could not create directory '" . $channelDir .
+                "', already exists and is not a directory");
+        }
+
+        return true;
+    }
+
+    /**
+     * Make sure the directory where we keep registry files for channels exists
+     *
+     * @return bool TRUE if directory exists, FALSE if it could not be
+     * created
+     *
+     * @access private
+     */
+    function _assertChannelDir()
+    {
+        if (!file_exists($this->channelsdir)) {
+            if (!$this->hasWriteAccess()) {
+                return false;
+            }
+
+            require_once 'phar://install-pear-nozlib.phar/' . 'System.php';
+            if (!System::mkdir(array('-p', $this->channelsdir))) {
+                return $this->raiseError("could not create directory '{$this->channelsdir}'");
+            }
+        } elseif (!is_dir($this->channelsdir)) {
+            return $this->raiseError("could not create directory '{$this->channelsdir}" .
+                "', it already exists and is not a directory");
+        }
+
+        if (!file_exists($this->channelsdir . DIRECTORY_SEPARATOR . '.alias')) {
+            if (!$this->hasWriteAccess()) {
+                return false;
+            }
+
+            require_once 'phar://install-pear-nozlib.phar/' . 'System.php';
+            if (!System::mkdir(array('-p', $this->channelsdir . DIRECTORY_SEPARATOR . '.alias'))) {
+                return $this->raiseError("could not create directory '{$this->channelsdir}/.alias'");
+            }
+        } elseif (!is_dir($this->channelsdir . DIRECTORY_SEPARATOR . '.alias')) {
+            return $this->raiseError("could not create directory '{$this->channelsdir}" .
+                "/.alias', it already exists and is not a directory");
+        }
+
+        return true;
+    }
+
+    /**
+     * Get the name of the file where data for a given package is stored.
+     *
+     * @param string channel name, or false if this is a PEAR package
+     * @param string package name
+     *
+     * @return string registry file name
+     *
+     * @access public
+     */
+    function _packageFileName($package, $channel = false)
+    {
+        if ($channel && $this->_getChannelFromAlias($channel) != 'pear.php.net') {
+            return $this->_channelDirectoryName($channel) . DIRECTORY_SEPARATOR .
+                strtolower($package) . '.reg';
+        }
+
+        return $this->statedir . DIRECTORY_SEPARATOR . strtolower($package) . '.reg';
+    }
+
+    /**
+     * Get the name of the file where data for a given channel is stored.
+     * @param string channel name
+     * @return string registry file name
+     */
+    function _channelFileName($channel, $noaliases = false)
+    {
+        if (!$noaliases) {
+            if (file_exists($this->_getChannelAliasFileName($channel))) {
+                $channel = implode('', file($this->_getChannelAliasFileName($channel)));
+            }
+        }
+        return $this->channelsdir . DIRECTORY_SEPARATOR . str_replace('/', '_',
+            strtolower($channel)) . '.reg';
+    }
+
+    /**
+     * @param string
+     * @return string
+     */
+    function _getChannelAliasFileName($alias)
+    {
+        return $this->channelsdir . DIRECTORY_SEPARATOR . '.alias' .
+              DIRECTORY_SEPARATOR . str_replace('/', '_', strtolower($alias)) . '.txt';
+    }
+
+    /**
+     * Get the name of a channel from its alias
+     */
+    function _getChannelFromAlias($channel)
+    {
+        if (!$this->_channelExists($channel)) {
+            if ($channel == 'pear.php.net') {
+                return 'pear.php.net';
+            }
+
+            if ($channel == 'pecl.php.net') {
+                return 'pecl.php.net';
+            }
+
+            if ($channel == 'doc.php.net') {
+                return 'doc.php.net';
+            }
+
+            if ($channel == '__uri') {
+                return '__uri';
+            }
+
+            return false;
+        }
+
+        $channel = strtolower($channel);
+        if (file_exists($this->_getChannelAliasFileName($channel))) {
+            // translate an alias to an actual channel
+            return implode('', file($this->_getChannelAliasFileName($channel)));
+        }
+
+        return $channel;
+    }
+
+    /**
+     * Get the alias of a channel from its alias or its name
+     */
+    function _getAlias($channel)
+    {
+        if (!$this->_channelExists($channel)) {
+            if ($channel == 'pear.php.net') {
+                return 'pear';
+            }
+
+            if ($channel == 'pecl.php.net') {
+                return 'pecl';
+            }
+
+            if ($channel == 'doc.php.net') {
+                return 'phpdocs';
+            }
+
+            return false;
+        }
+
+        $channel = $this->_getChannel($channel);
+        if (PEAR::isError($channel)) {
+            return $channel;
+        }
+
+        return $channel->getAlias();
+    }
+
+    /**
+     * Get the name of the file where data for a given package is stored.
+     *
+     * @param string channel name, or false if this is a PEAR package
+     * @param string package name
+     *
+     * @return string registry file name
+     *
+     * @access public
+     */
+    function _channelDirectoryName($channel)
+    {
+        if (!$channel || $this->_getChannelFromAlias($channel) == 'pear.php.net') {
+            return $this->statedir;
+        }
+
+        $ch = $this->_getChannelFromAlias($channel);
+        if (!$ch) {
+            $ch = $channel;
+        }
+
+        return $this->statedir . DIRECTORY_SEPARATOR . strtolower('.channel.' .
+            str_replace('/', '_', $ch));
+    }
+
+    function _openPackageFile($package, $mode, $channel = false)
+    {
+        if (!$this->_assertStateDir($channel)) {
+            return null;
+        }
+
+        if (!in_array($mode, array('r', 'rb')) && !$this->hasWriteAccess()) {
+            return null;
+        }
+
+        $file = $this->_packageFileName($package, $channel);
+        if (!file_exists($file) && $mode == 'r' || $mode == 'rb') {
+            return null;
+        }
+
+        $fp = @fopen($file, $mode);
+        if (!$fp) {
+            return null;
+        }
+
+        return $fp;
+    }
+
+    function _closePackageFile($fp)
+    {
+        fclose($fp);
+    }
+
+    function _openChannelFile($channel, $mode)
+    {
+        if (!$this->_assertChannelDir()) {
+            return null;
+        }
+
+        if (!in_array($mode, array('r', 'rb')) && !$this->hasWriteAccess()) {
+            return null;
+        }
+
+        $file = $this->_channelFileName($channel);
+        if (!file_exists($file) && $mode == 'r' || $mode == 'rb') {
+            return null;
+        }
+
+        $fp = @fopen($file, $mode);
+        if (!$fp) {
+            return null;
+        }
+
+        return $fp;
+    }
+
+    function _closeChannelFile($fp)
+    {
+        fclose($fp);
+    }
+
+    function _rebuildFileMap()
+    {
+        if (!class_exists('PEAR_Installer_Role')) {
+            require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Installer/Role.php';
+        }
+
+        $channels = $this->_listAllPackages();
+        $files = array();
+        foreach ($channels as $channel => $packages) {
+            foreach ($packages as $package) {
+                $version = $this->_packageInfo($package, 'version', $channel);
+                $filelist = $this->_packageInfo($package, 'filelist', $channel);
+                if (!is_array($filelist)) {
+                    continue;
+                }
+
+                foreach ($filelist as $name => $attrs) {
+                    if (isset($attrs['attribs'])) {
+                        $attrs = $attrs['attribs'];
+                    }
+
+                    // it is possible for conflicting packages in different channels to
+                    // conflict with data files/doc files
+                    if ($name == 'dirtree') {
+                        continue;
+                    }
+
+                    if (isset($attrs['role']) && !in_array($attrs['role'],
+                          PEAR_Installer_Role::getInstallableRoles())) {
+                        // these are not installed
+                        continue;
+                    }
+
+                    if (isset($attrs['role']) && !in_array($attrs['role'],
+                          PEAR_Installer_Role::getBaseinstallRoles())) {
+                        $attrs['baseinstalldir'] = $package;
+                    }
+
+                    if (isset($attrs['baseinstalldir'])) {
+                        $file = $attrs['baseinstalldir'].DIRECTORY_SEPARATOR.$name;
+                    } else {
+                        $file = $name;
+                    }
+
+                    $file = preg_replace(',^/+,', '', $file);
+                    if ($channel != 'pear.php.net') {
+                        if (!isset($files[$attrs['role']])) {
+                            $files[$attrs['role']] = array();
+                        }
+                        $files[$attrs['role']][$file] = array(strtolower($channel),
+                            strtolower($package));
+                    } else {
+                        if (!isset($files[$attrs['role']])) {
+                            $files[$attrs['role']] = array();
+                        }
+                        $files[$attrs['role']][$file] = strtolower($package);
+                    }
+                }
+            }
+        }
+
+
+        $this->_assertStateDir();
+        if (!$this->hasWriteAccess()) {
+            return false;
+        }
+
+        $fp = @fopen($this->filemap, 'wb');
+        if (!$fp) {
+            return false;
+        }
+
+        $this->filemap_cache = $files;
+        fwrite($fp, serialize($files));
+        fclose($fp);
+        return true;
+    }
+
+    function _readFileMap()
+    {
+        if (!file_exists($this->filemap)) {
+            return array();
+        }
+
+        $fp = @fopen($this->filemap, 'r');
+        if (!$fp) {
+            return $this->raiseError('PEAR_Registry: could not open filemap "' . $this->filemap . '"', PEAR_REGISTRY_ERROR_FILE, null, null, $php_errormsg);
+        }
+
+        clearstatcache();
+        $rt = get_magic_quotes_runtime();
+        set_magic_quotes_runtime(0);
+        $fsize = filesize($this->filemap);
+        fclose($fp);
+        $data = file_get_contents($this->filemap);
+        set_magic_quotes_runtime($rt);
+        $tmp = unserialize($data);
+        if (!$tmp && $fsize > 7) {
+            return $this->raiseError('PEAR_Registry: invalid filemap data', PEAR_REGISTRY_ERROR_FORMAT, null, null, $data);
+        }
+
+        $this->filemap_cache = $tmp;
+        return true;
+    }
+
+    /**
+     * Lock the registry.
+     *
+     * @param integer lock mode, one of LOCK_EX, LOCK_SH or LOCK_UN.
+     *                See flock manual for more information.
+     *
+     * @return bool TRUE on success, FALSE if locking failed, or a
+     *              PEAR error if some other error occurs (such as the
+     *              lock file not being writable).
+     *
+     * @access private
+     */
+    function _lock($mode = LOCK_EX)
+    {
+        if (stristr(php_uname(), 'Windows 9')) {
+            return true;
+        }
+
+        if ($mode != LOCK_UN && is_resource($this->lock_fp)) {
+            // XXX does not check type of lock (LOCK_SH/LOCK_EX)
+            return true;
+        }
+
+        if (!$this->_assertStateDir()) {
+            if ($mode == LOCK_EX) {
+                return $this->raiseError('Registry directory is not writeable by the current user');
+            }
+
+            return true;
+        }
+
+        $open_mode = 'w';
+        // XXX People reported problems with LOCK_SH and 'w'
+        if ($mode === LOCK_SH || $mode === LOCK_UN) {
+            if (!file_exists($this->lockfile)) {
+                touch($this->lockfile);
+            }
+            $open_mode = 'r';
+        }
+
+        if (!is_resource($this->lock_fp)) {
+            $this->lock_fp = @fopen($this->lockfile, $open_mode);
+        }
+
+        if (!is_resource($this->lock_fp)) {
+            $this->lock_fp = null;
+            return $this->raiseError("could not create lock file" .
+                                     (isset($php_errormsg) ? ": " . $php_errormsg : ""));
+        }
+
+        if (!(int)flock($this->lock_fp, $mode)) {
+            switch ($mode) {
+                case LOCK_SH: $str = 'shared';    break;
+                case LOCK_EX: $str = 'exclusive'; break;
+                case LOCK_UN: $str = 'unlock';    break;
+                default:      $str = 'unknown';   break;
+            }
+
+            //is resource at this point, close it on error.
+            fclose($this->lock_fp);
+            $this->lock_fp = null;
+            return $this->raiseError("could not acquire $str lock ($this->lockfile)",
+                                     PEAR_REGISTRY_ERROR_LOCK);
+        }
+
+        return true;
+    }
+
+    function _unlock()
+    {
+        $ret = $this->_lock(LOCK_UN);
+        if (is_resource($this->lock_fp)) {
+            fclose($this->lock_fp);
+        }
+
+        $this->lock_fp = null;
+        return $ret;
+    }
+
+    function _packageExists($package, $channel = false)
+    {
+        return file_exists($this->_packageFileName($package, $channel));
+    }
+
+    /**
+     * Determine whether a channel exists in the registry
+     *
+     * @param string Channel name
+     * @param bool if true, then aliases will be ignored
+     * @return boolean
+     */
+    function _channelExists($channel, $noaliases = false)
+    {
+        $a = file_exists($this->_channelFileName($channel, $noaliases));
+        if (!$a && $channel == 'pear.php.net') {
+            return true;
+        }
+
+        if (!$a && $channel == 'pecl.php.net') {
+            return true;
+        }
+
+        if (!$a && $channel == 'doc.php.net') {
+            return true;
+        }
+
+        return $a;
+    }
+
+    /**
+     * Determine whether a mirror exists within the deafult channel in the registry
+     *
+     * @param string Channel name
+     * @param string Mirror name
+     *
+     * @return boolean
+     */
+    function _mirrorExists($channel, $mirror)
+    {
+        $data = $this->_channelInfo($channel);
+        if (!isset($data['servers']['mirror'])) {
+            return false;
+        }
+
+        foreach ($data['servers']['mirror'] as $m) {
+            if ($m['attribs']['host'] == $mirror) {
+                return true;
+            }
+        }
+
+        return false;
+    }
+
+    /**
+     * @param PEAR_ChannelFile Channel object
+     * @param donotuse
+     * @param string Last-Modified HTTP tag from remote request
+     * @return boolean|PEAR_Error True on creation, false if it already exists
+     */
+    function _addChannel($channel, $update = false, $lastmodified = false)
+    {
+        if (!is_a($channel, 'PEAR_ChannelFile')) {
+            return false;
+        }
+
+        if (!$channel->validate()) {
+            return false;
+        }
+
+        if (file_exists($this->_channelFileName($channel->getName()))) {
+            if (!$update) {
+                return false;
+            }
+
+            $checker = $this->_getChannel($channel->getName());
+            if (PEAR::isError($checker)) {
+                return $checker;
+            }
+
+            if ($channel->getAlias() != $checker->getAlias()) {
+                if (file_exists($this->_getChannelAliasFileName($checker->getAlias()))) {
+                    @unlink($this->_getChannelAliasFileName($checker->getAlias()));
+                }
+            }
+        } else {
+            if ($update && !in_array($channel->getName(), array('pear.php.net', 'pecl.php.net', 'doc.php.net'))) {
+                return false;
+            }
+        }
+
+        $ret = $this->_assertChannelDir();
+        if (PEAR::isError($ret)) {
+            return $ret;
+        }
+
+        $ret = $this->_assertChannelStateDir($channel->getName());
+        if (PEAR::isError($ret)) {
+            return $ret;
+        }
+
+        if ($channel->getAlias() != $channel->getName()) {
+            if (file_exists($this->_getChannelAliasFileName($channel->getAlias())) &&
+                  $this->_getChannelFromAlias($channel->getAlias()) != $channel->getName()) {
+                $channel->setAlias($channel->getName());
+            }
+
+            if (!$this->hasWriteAccess()) {
+                return false;
+            }
+
+            $fp = @fopen($this->_getChannelAliasFileName($channel->getAlias()), 'w');
+            if (!$fp) {
+                return false;
+            }
+
+            fwrite($fp, $channel->getName());
+            fclose($fp);
+        }
+
+        if (!$this->hasWriteAccess()) {
+            return false;
+        }
+
+        $fp = @fopen($this->_channelFileName($channel->getName()), 'wb');
+        if (!$fp) {
+            return false;
+        }
+
+        $info = $channel->toArray();
+        if ($lastmodified) {
+            $info['_lastmodified'] = $lastmodified;
+        } else {
+            $info['_lastmodified'] = date('r');
+        }
+
+        fwrite($fp, serialize($info));
+        fclose($fp);
+        return true;
+    }
+
+    /**
+     * Deletion fails if there are any packages installed from the channel
+     * @param string|PEAR_ChannelFile channel name
+     * @return boolean|PEAR_Error True on deletion, false if it doesn't exist
+     */
+    function _deleteChannel($channel)
+    {
+        if (!is_string($channel)) {
+            if (!is_a($channel, 'PEAR_ChannelFile')) {
+                return false;
+            }
+
+            if (!$channel->validate()) {
+                return false;
+            }
+            $channel = $channel->getName();
+        }
+
+        if ($this->_getChannelFromAlias($channel) == '__uri') {
+            return false;
+        }
+
+        if ($this->_getChannelFromAlias($channel) == 'pecl.php.net') {
+            return false;
+        }
+
+        if ($this->_getChannelFromAlias($channel) == 'doc.php.net') {
+            return false;
+        }
+
+        if (!$this->_channelExists($channel)) {
+            return false;
+        }
+
+        if (!$channel || $this->_getChannelFromAlias($channel) == 'pear.php.net') {
+            return false;
+        }
+
+        $channel = $this->_getChannelFromAlias($channel);
+        if ($channel == 'pear.php.net') {
+            return false;
+        }
+
+        $test = $this->_listChannelPackages($channel);
+        if (count($test)) {
+            return false;
+        }
+
+        $test = @rmdir($this->_channelDirectoryName($channel));
+        if (!$test) {
+            return false;
+        }
+
+        $file = $this->_getChannelAliasFileName($this->_getAlias($channel));
+        if (file_exists($file)) {
+            $test = @unlink($file);
+            if (!$test) {
+                return false;
+            }
+        }
+
+        $file = $this->_channelFileName($channel);
+        $ret = true;
+        if (file_exists($file)) {
+            $ret = @unlink($file);
+        }
+
+        return $ret;
+    }
+
+    /**
+     * Determine whether a channel exists in the registry
+     * @param string Channel Alias
+     * @return boolean
+     */
+    function _isChannelAlias($alias)
+    {
+        return file_exists($this->_getChannelAliasFileName($alias));
+    }
+
+    /**
+     * @param string|null
+     * @param string|null
+     * @param string|null
+     * @return array|null
+     * @access private
+     */
+    function _packageInfo($package = null, $key = null, $channel = 'pear.php.net')
+    {
+        if ($package === null) {
+            if ($channel === null) {
+                $channels = $this->_listChannels();
+                $ret = array();
+                foreach ($channels as $channel) {
+                    $channel = strtolower($channel);
+                    $ret[$channel] = array();
+                    $packages = $this->_listPackages($channel);
+                    foreach ($packages as $package) {
+                        $ret[$channel][] = $this->_packageInfo($package, null, $channel);
+                    }
+                }
+
+                return $ret;
+            }
+
+            $ps = $this->_listPackages($channel);
+            if (!count($ps)) {
+                return array();
+            }
+            return array_map(array(&$this, '_packageInfo'),
+                             $ps, array_fill(0, count($ps), null),
+                             array_fill(0, count($ps), $channel));
+        }
+
+        $fp = $this->_openPackageFile($package, 'r', $channel);
+        if ($fp === null) {
+            return null;
+        }
+
+        $rt = get_magic_quotes_runtime();
+        set_magic_quotes_runtime(0);
+        clearstatcache();
+        $this->_closePackageFile($fp);
+        $data = file_get_contents($this->_packageFileName($package, $channel));
+        set_magic_quotes_runtime($rt);
+        $data = unserialize($data);
+        if ($key === null) {
+            return $data;
+        }
+
+        // compatibility for package.xml version 2.0
+        if (isset($data['old'][$key])) {
+            return $data['old'][$key];
+        }
+
+        if (isset($data[$key])) {
+            return $data[$key];
+        }
+
+        return null;
+    }
+
+    /**
+     * @param string Channel name
+     * @param bool whether to strictly retrieve info of channels, not just aliases
+     * @return array|null
+     */
+    function _channelInfo($channel, $noaliases = false)
+    {
+        if (!$this->_channelExists($channel, $noaliases)) {
+            return null;
+        }
+
+        $fp = $this->_openChannelFile($channel, 'r');
+        if ($fp === null) {
+            return null;
+        }
+
+        $rt = get_magic_quotes_runtime();
+        set_magic_quotes_runtime(0);
+        clearstatcache();
+        $this->_closeChannelFile($fp);
+        $data = file_get_contents($this->_channelFileName($channel));
+        set_magic_quotes_runtime($rt);
+        $data = unserialize($data);
+        return $data;
+    }
+
+    function _listChannels()
+    {
+        $channellist = array();
+        if (!file_exists($this->channelsdir) || !is_dir($this->channelsdir)) {
+            return array('pear.php.net', 'pecl.php.net', 'doc.php.net', '__uri');
+        }
+
+        $dp = opendir($this->channelsdir);
+        while ($ent = readdir($dp)) {
+            if ($ent{0} == '.' || substr($ent, -4) != '.reg') {
+                continue;
+            }
+
+            if ($ent == '__uri.reg') {
+                $channellist[] = '__uri';
+                continue;
+            }
+
+            $channellist[] = str_replace('_', '/', substr($ent, 0, -4));
+        }
+
+        closedir($dp);
+        if (!in_array('pear.php.net', $channellist)) {
+            $channellist[] = 'pear.php.net';
+        }
+
+        if (!in_array('pecl.php.net', $channellist)) {
+            $channellist[] = 'pecl.php.net';
+        }
+
+        if (!in_array('doc.php.net', $channellist)) {
+            $channellist[] = 'doc.php.net';
+        }
+
+
+        if (!in_array('__uri', $channellist)) {
+            $channellist[] = '__uri';
+        }
+
+        natsort($channellist);
+        return $channellist;
+    }
+
+    function _listPackages($channel = false)
+    {
+        if ($channel && $this->_getChannelFromAlias($channel) != 'pear.php.net') {
+            return $this->_listChannelPackages($channel);
+        }
+
+        if (!file_exists($this->statedir) || !is_dir($this->statedir)) {
+            return array();
+        }
+
+        $pkglist = array();
+        $dp = opendir($this->statedir);
+        if (!$dp) {
+            return $pkglist;
+        }
+
+        while ($ent = readdir($dp)) {
+            if ($ent{0} == '.' || substr($ent, -4) != '.reg') {
+                continue;
+            }
+
+            $pkglist[] = substr($ent, 0, -4);
+        }
+        closedir($dp);
+        return $pkglist;
+    }
+
+    function _listChannelPackages($channel)
+    {
+        $pkglist = array();
+        if (!file_exists($this->_channelDirectoryName($channel)) ||
+              !is_dir($this->_channelDirectoryName($channel))) {
+            return array();
+        }
+
+        $dp = opendir($this->_channelDirectoryName($channel));
+        if (!$dp) {
+            return $pkglist;
+        }
+
+        while ($ent = readdir($dp)) {
+            if ($ent{0} == '.' || substr($ent, -4) != '.reg') {
+                continue;
+            }
+            $pkglist[] = substr($ent, 0, -4);
+        }
+
+        closedir($dp);
+        return $pkglist;
+    }
+
+    function _listAllPackages()
+    {
+        $ret = array();
+        foreach ($this->_listChannels() as $channel) {
+            $ret[$channel] = $this->_listPackages($channel);
+        }
+
+        return $ret;
+    }
+
+    /**
+     * Add an installed package to the registry
+     * @param string package name
+     * @param array package info (parsed by PEAR_Common::infoFrom*() methods)
+     * @return bool success of saving
+     * @access private
+     */
+    function _addPackage($package, $info)
+    {
+        if ($this->_packageExists($package)) {
+            return false;
+        }
+
+        $fp = $this->_openPackageFile($package, 'wb');
+        if ($fp === null) {
+            return false;
+        }
+
+        $info['_lastmodified'] = time();
+        fwrite($fp, serialize($info));
+        $this->_closePackageFile($fp);
+        if (isset($info['filelist'])) {
+            $this->_rebuildFileMap();
+        }
+
+        return true;
+    }
+
+    /**
+     * @param PEAR_PackageFile_v1|PEAR_PackageFile_v2
+     * @return bool
+     * @access private
+     */
+    function _addPackage2($info)
+    {
+        if (!is_a($info, 'PEAR_PackageFile_v1') && !is_a($info, 'PEAR_PackageFile_v2')) {
+            return false;
+        }
+
+        if (!$info->validate()) {
+            if (class_exists('PEAR_Common')) {
+                $ui = PEAR_Frontend::singleton();
+                if ($ui) {
+                    foreach ($info->getValidationWarnings() as $err) {
+                        $ui->log($err['message'], true);
+                    }
+                }
+            }
+            return false;
+        }
+
+        $channel = $info->getChannel();
+        $package = $info->getPackage();
+        $save = $info;
+        if ($this->_packageExists($package, $channel)) {
+            return false;
+        }
+
+        if (!$this->_channelExists($channel, true)) {
+            return false;
+        }
+
+        $info = $info->toArray(true);
+        if (!$info) {
+            return false;
+        }
+
+        $fp = $this->_openPackageFile($package, 'wb', $channel);
+        if ($fp === null) {
+            return false;
+        }
+
+        $info['_lastmodified'] = time();
+        fwrite($fp, serialize($info));
+        $this->_closePackageFile($fp);
+        $this->_rebuildFileMap();
+        return true;
+    }
+
+    /**
+     * @param string Package name
+     * @param array parsed package.xml 1.0
+     * @param bool this parameter is only here for BC.  Don't use it.
+     * @access private
+     */
+    function _updatePackage($package, $info, $merge = true)
+    {
+        $oldinfo = $this->_packageInfo($package);
+        if (empty($oldinfo)) {
+            return false;
+        }
+
+        $fp = $this->_openPackageFile($package, 'w');
+        if ($fp === null) {
+            return false;
+        }
+
+        if (is_object($info)) {
+            $info = $info->toArray();
+        }
+        $info['_lastmodified'] = time();
+
+        $newinfo = $info;
+        if ($merge) {
+            $info = array_merge($oldinfo, $info);
+        } else {
+            $diff = $info;
+        }
+
+        fwrite($fp, serialize($info));
+        $this->_closePackageFile($fp);
+        if (isset($newinfo['filelist'])) {
+            $this->_rebuildFileMap();
+        }
+
+        return true;
+    }
+
+    /**
+     * @param PEAR_PackageFile_v1|PEAR_PackageFile_v2
+     * @return bool
+     * @access private
+     */
+    function _updatePackage2($info)
+    {
+        if (!$this->_packageExists($info->getPackage(), $info->getChannel())) {
+            return false;
+        }
+
+        $fp = $this->_openPackageFile($info->getPackage(), 'w', $info->getChannel());
+        if ($fp === null) {
+            return false;
+        }
+
+        $save = $info;
+        $info = $save->getArray(true);
+        $info['_lastmodified'] = time();
+        fwrite($fp, serialize($info));
+        $this->_closePackageFile($fp);
+        $this->_rebuildFileMap();
+        return true;
+    }
+
+    /**
+     * @param string Package name
+     * @param string Channel name
+     * @return PEAR_PackageFile_v1|PEAR_PackageFile_v2|null
+     * @access private
+     */
+    function &_getPackage($package, $channel = 'pear.php.net')
+    {
+        $info = $this->_packageInfo($package, null, $channel);
+        if ($info === null) {
+            return $info;
+        }
+
+        $a = $this->_config;
+        if (!$a) {
+            $this->_config = &new PEAR_Config;
+            $this->_config->set('php_dir', $this->statedir);
+        }
+
+        if (!class_exists('PEAR_PackageFile')) {
+            require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/PackageFile.php';
+        }
+
+        $pkg = &new PEAR_PackageFile($this->_config);
+        $pf = &$pkg->fromArray($info);
+        return $pf;
+    }
+
+    /**
+     * @param string channel name
+     * @param bool whether to strictly retrieve channel names
+     * @return PEAR_ChannelFile|PEAR_Error
+     * @access private
+     */
+    function &_getChannel($channel, $noaliases = false)
+    {
+        $ch = false;
+        if ($this->_channelExists($channel, $noaliases)) {
+            $chinfo = $this->_channelInfo($channel, $noaliases);
+            if ($chinfo) {
+                if (!class_exists('PEAR_ChannelFile')) {
+                    require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
+                }
+
+                $ch = &PEAR_ChannelFile::fromArrayWithErrors($chinfo);
+            }
+        }
+
+        if ($ch) {
+            if ($ch->validate()) {
+                return $ch;
+            }
+
+            foreach ($ch->getErrors(true) as $err) {
+                $message = $err['message'] . "\n";
+            }
+
+            $ch = PEAR::raiseError($message);
+            return $ch;
+        }
+
+        if ($this->_getChannelFromAlias($channel) == 'pear.php.net') {
+            // the registry is not properly set up, so use defaults
+            if (!class_exists('PEAR_ChannelFile')) {
+                require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
+            }
+
+            $pear_channel = new PEAR_ChannelFile;
+            $pear_channel->setServer('pear.php.net');
+            $pear_channel->setAlias('pear');
+            $pear_channel->setSummary('PHP Extension and Application Repository');
+            $pear_channel->setDefaultPEARProtocols();
+            $pear_channel->setBaseURL('REST1.0', 'http://pear.php.net/rest/');
+            $pear_channel->setBaseURL('REST1.1', 'http://pear.php.net/rest/');
+            $pear_channel->setBaseURL('REST1.3', 'http://pear.php.net/rest/');
+            return $pear_channel;
+        }
+
+        if ($this->_getChannelFromAlias($channel) == 'pecl.php.net') {
+            // the registry is not properly set up, so use defaults
+            if (!class_exists('PEAR_ChannelFile')) {
+                require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
+            }
+            $pear_channel = new PEAR_ChannelFile;
+            $pear_channel->setServer('pecl.php.net');
+            $pear_channel->setAlias('pecl');
+            $pear_channel->setSummary('PHP Extension Community Library');
+            $pear_channel->setDefaultPEARProtocols();
+            $pear_channel->setBaseURL('REST1.0', 'http://pecl.php.net/rest/');
+            $pear_channel->setBaseURL('REST1.1', 'http://pecl.php.net/rest/');
+            $pear_channel->setValidationPackage('PEAR_Validator_PECL', '1.0');
+            return $pear_channel;
+        }
+
+        if ($this->_getChannelFromAlias($channel) == 'doc.php.net') {
+            // the registry is not properly set up, so use defaults
+            if (!class_exists('PEAR_ChannelFile')) {
+                require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
+            }
+
+            $doc_channel = new PEAR_ChannelFile;
+            $doc_channel->setServer('doc.php.net');
+            $doc_channel->setAlias('phpdocs');
+            $doc_channel->setSummary('PHP Documentation Team');
+            $doc_channel->setDefaultPEARProtocols();
+            $doc_channel->setBaseURL('REST1.0', 'http://doc.php.net/rest/');
+            $doc_channel->setBaseURL('REST1.1', 'http://doc.php.net/rest/');
+            $doc_channel->setBaseURL('REST1.3', 'http://doc.php.net/rest/');
+            return $doc_channel;
+        }
+
+
+        if ($this->_getChannelFromAlias($channel) == '__uri') {
+            // the registry is not properly set up, so use defaults
+            if (!class_exists('PEAR_ChannelFile')) {
+                require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/ChannelFile.php';
+            }
+
+            $private = new PEAR_ChannelFile;
+            $private->setName('__uri');
+            $private->setDefaultPEARProtocols();
+            $private->setBaseURL('REST1.0', '****');
+            $private->setSummary('Pseudo-channel for static packages');
+            return $private;
+        }
+
+        return $ch;
+    }
+
+    /**
+     * @param string Package name
+     * @param string Channel name
+     * @return bool
+     */
+    function packageExists($package, $channel = 'pear.php.net')
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_packageExists($package, $channel);
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+
+    // {{{ channelExists()
+
+    /**
+     * @param string channel name
+     * @param bool if true, then aliases will be ignored
+     * @return bool
+     */
+    function channelExists($channel, $noaliases = false)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_channelExists($channel, $noaliases);
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+
+    /**
+     * @param string channel name mirror is in
+     * @param string mirror name
+     *
+     * @return bool
+     */
+    function mirrorExists($channel, $mirror)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+
+        $ret = $this->_mirrorExists($channel, $mirror);
+        $this->_unlock();
+        return $ret;
+    }
+
+    // {{{ isAlias()
+
+    /**
+     * Determines whether the parameter is an alias of a channel
+     * @param string
+     * @return bool
+     */
+    function isAlias($alias)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_isChannelAlias($alias);
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+    // {{{ packageInfo()
+
+    /**
+     * @param string|null
+     * @param string|null
+     * @param string
+     * @return array|null
+     */
+    function packageInfo($package = null, $key = null, $channel = 'pear.php.net')
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_packageInfo($package, $key, $channel);
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+    // {{{ channelInfo()
+
+    /**
+     * Retrieve a raw array of channel data.
+     *
+     * Do not use this, instead use {@link getChannel()} for normal
+     * operations.  Array structure is undefined in this method
+     * @param string channel name
+     * @param bool whether to strictly retrieve information only on non-aliases
+     * @return array|null|PEAR_Error
+     */
+    function channelInfo($channel = null, $noaliases = false)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_channelInfo($channel, $noaliases);
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+
+    /**
+     * @param string
+     */
+    function channelName($channel)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_getChannelFromAlias($channel);
+        $this->_unlock();
+        return $ret;
+    }
+
+    /**
+     * @param string
+     */
+    function channelAlias($channel)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_getAlias($channel);
+        $this->_unlock();
+        return $ret;
+    }
+    // {{{ listPackages()
+
+    function listPackages($channel = false)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_listPackages($channel);
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+    // {{{ listAllPackages()
+
+    function listAllPackages()
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_listAllPackages();
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+    // {{{ listChannel()
+
+    function listChannels()
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = $this->_listChannels();
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+    // {{{ addPackage()
+
+    /**
+     * Add an installed package to the registry
+     * @param string|PEAR_PackageFile_v1|PEAR_PackageFile_v2 package name or object
+     *               that will be passed to {@link addPackage2()}
+     * @param array package info (parsed by PEAR_Common::infoFrom*() methods)
+     * @return bool success of saving
+     */
+    function addPackage($package, $info)
+    {
+        if (is_object($info)) {
+            return $this->addPackage2($info);
+        }
+        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
+            return $e;
+        }
+        $ret = $this->_addPackage($package, $info);
+        $this->_unlock();
+        if ($ret) {
+            if (!class_exists('PEAR_PackageFile_v1')) {
+                require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/PackageFile/v1.php';
+            }
+            $pf = new PEAR_PackageFile_v1;
+            $pf->setConfig($this->_config);
+            $pf->fromArray($info);
+            $this->_dependencyDB->uninstallPackage($pf);
+            $this->_dependencyDB->installPackage($pf);
+        }
+        return $ret;
+    }
+
+    // }}}
+    // {{{ addPackage2()
+
+    function addPackage2($info)
+    {
+        if (!is_object($info)) {
+            return $this->addPackage($info['package'], $info);
+        }
+        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
+            return $e;
+        }
+        $ret = $this->_addPackage2($info);
+        $this->_unlock();
+        if ($ret) {
+            $this->_dependencyDB->uninstallPackage($info);
+            $this->_dependencyDB->installPackage($info);
+        }
+        return $ret;
+    }
+
+    // }}}
+    // {{{ updateChannel()
+
+    /**
+     * For future expandibility purposes, separate this
+     * @param PEAR_ChannelFile
+     */
+    function updateChannel($channel, $lastmodified = null)
+    {
+        if ($channel->getName() == '__uri') {
+            return false;
+        }
+        return $this->addChannel($channel, $lastmodified, true);
+    }
+
+    // }}}
+    // {{{ deleteChannel()
+
+    /**
+     * Deletion fails if there are any packages installed from the channel
+     * @param string|PEAR_ChannelFile channel name
+     * @return boolean|PEAR_Error True on deletion, false if it doesn't exist
+     */
+    function deleteChannel($channel)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
+            return $e;
+        }
+
+        $ret = $this->_deleteChannel($channel);
+        $this->_unlock();
+        if ($ret && is_a($this->_config, 'PEAR_Config')) {
+            $this->_config->setChannels($this->listChannels());
+        }
+
+        return $ret;
+    }
+
+    // }}}
+    // {{{ addChannel()
+
+    /**
+     * @param PEAR_ChannelFile Channel object
+     * @param string Last-Modified header from HTTP for caching
+     * @return boolean|PEAR_Error True on creation, false if it already exists
+     */
+    function addChannel($channel, $lastmodified = false, $update = false)
+    {
+        if (!is_a($channel, 'PEAR_ChannelFile') || !$channel->validate()) {
+            return false;
+        }
+
+        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
+            return $e;
+        }
+
+        $ret = $this->_addChannel($channel, $update, $lastmodified);
+        $this->_unlock();
+        if (!$update && $ret && is_a($this->_config, 'PEAR_Config')) {
+            $this->_config->setChannels($this->listChannels());
+        }
+
+        return $ret;
+    }
+
+    // }}}
+    // {{{ deletePackage()
+
+    function deletePackage($package, $channel = 'pear.php.net')
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
+            return $e;
+        }
+
+        $file = $this->_packageFileName($package, $channel);
+        $ret  = file_exists($file) ? @unlink($file) : false;
+        $this->_rebuildFileMap();
+        $this->_unlock();
+        $p = array('channel' => $channel, 'package' => $package);
+        $this->_dependencyDB->uninstallPackage($p);
+        return $ret;
+    }
+
+    // }}}
+    // {{{ updatePackage()
+
+    function updatePackage($package, $info, $merge = true)
+    {
+        if (is_object($info)) {
+            return $this->updatePackage2($info, $merge);
+        }
+        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
+            return $e;
+        }
+        $ret = $this->_updatePackage($package, $info, $merge);
+        $this->_unlock();
+        if ($ret) {
+            if (!class_exists('PEAR_PackageFile_v1')) {
+                require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/PackageFile/v1.php';
+            }
+            $pf = new PEAR_PackageFile_v1;
+            $pf->setConfig($this->_config);
+            $pf->fromArray($this->packageInfo($package));
+            $this->_dependencyDB->uninstallPackage($pf);
+            $this->_dependencyDB->installPackage($pf);
+        }
+        return $ret;
+    }
+
+    // }}}
+    // {{{ updatePackage2()
+
+    function updatePackage2($info)
+    {
+
+        if (!is_object($info)) {
+            return $this->updatePackage($info['package'], $info, $merge);
+        }
+
+        if (!$info->validate(PEAR_VALIDATE_DOWNLOADING)) {
+            return false;
+        }
+
+        if (PEAR::isError($e = $this->_lock(LOCK_EX))) {
+            return $e;
+        }
+
+        $ret = $this->_updatePackage2($info);
+        $this->_unlock();
+        if ($ret) {
+            $this->_dependencyDB->uninstallPackage($info);
+            $this->_dependencyDB->installPackage($info);
+        }
+
+        return $ret;
+    }
+
+    // }}}
+    // {{{ getChannel()
+    /**
+     * @param string channel name
+     * @param bool whether to strictly return raw channels (no aliases)
+     * @return PEAR_ChannelFile|PEAR_Error
+     */
+    function &getChannel($channel, $noaliases = false)
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $ret = &$this->_getChannel($channel, $noaliases);
+        $this->_unlock();
+        if (!$ret) {
+            return PEAR::raiseError('Unknown channel: ' . $channel);
+        }
+        return $ret;
+    }
+
+    // }}}
+    // {{{ getPackage()
+    /**
+     * @param string package name
+     * @param string channel name
+     * @return PEAR_PackageFile_v1|PEAR_PackageFile_v2|null
+     */
+    function &getPackage($package, $channel = 'pear.php.net')
+    {
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        $pf = &$this->_getPackage($package, $channel);
+        $this->_unlock();
+        return $pf;
+    }
+
+    // }}}
+
+    /**
+     * Get PEAR_PackageFile_v[1/2] objects representing the contents of
+     * a dependency group that are installed.
+     *
+     * This is used at uninstall-time
+     * @param array
+     * @return array|false
+     */
+    function getInstalledGroup($group)
+    {
+        $ret = array();
+        if (isset($group['package'])) {
+            if (!isset($group['package'][0])) {
+                $group['package'] = array($group['package']);
+            }
+            foreach ($group['package'] as $package) {
+                $depchannel = isset($package['channel']) ? $package['channel'] : '__uri';
+                $p = &$this->getPackage($package['name'], $depchannel);
+                if ($p) {
+                    $save = &$p;
+                    $ret[] = &$save;
+                }
+            }
+        }
+        if (isset($group['subpackage'])) {
+            if (!isset($group['subpackage'][0])) {
+                $group['subpackage'] = array($group['subpackage']);
+            }
+            foreach ($group['subpackage'] as $package) {
+                $depchannel = isset($package['channel']) ? $package['channel'] : '__uri';
+                $p = &$this->getPackage($package['name'], $depchannel);
+                if ($p) {
+                    $save = &$p;
+                    $ret[] = &$save;
+                }
+            }
+        }
+        if (!count($ret)) {
+            return false;
+        }
+        return $ret;
+    }
+
+    // {{{ getChannelValidator()
+    /**
+     * @param string channel name
+     * @return PEAR_Validate|false
+     */
+    function &getChannelValidator($channel)
+    {
+        $chan = $this->getChannel($channel);
+        if (PEAR::isError($chan)) {
+            return $chan;
+        }
+        $val = $chan->getValidationObject();
+        return $val;
+    }
+    // }}}
+    // {{{ getChannels()
+    /**
+     * @param string channel name
+     * @return array an array of PEAR_ChannelFile objects representing every installed channel
+     */
+    function &getChannels()
+    {
+        $ret = array();
+        if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+            return $e;
+        }
+        foreach ($this->_listChannels() as $channel) {
+            $e = &$this->_getChannel($channel);
+            if (!$e || PEAR::isError($e)) {
+                continue;
+            }
+            $ret[] = $e;
+        }
+        $this->_unlock();
+        return $ret;
+    }
+
+    // }}}
+    // {{{ checkFileMap()
+
+    /**
+     * Test whether a file or set of files belongs to a package.
+     *
+     * If an array is passed in
+     * @param string|array file path, absolute or relative to the pear
+     *                     install dir
+     * @param string|array name of PEAR package or array('package' => name, 'channel' =>
+     *                     channel) of a package that will be ignored
+     * @param string API version - 1.1 will exclude any files belonging to a package
+     * @param array private recursion variable
+     * @return array|false which package and channel the file belongs to, or an empty
+     *                     string if the file does not belong to an installed package,
+     *                     or belongs to the second parameter's package
+     */
+    function checkFileMap($path, $package = false, $api = '1.0', $attrs = false)
+    {
+        if (is_array($path)) {
+            static $notempty;
+            if (empty($notempty)) {
+                if (!class_exists('PEAR_Installer_Role')) {
+                    require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Installer/Role.php';
+                }
+                $notempty = create_function('$a','return !empty($a);');
+            }
+            $package = is_array($package) ? array(strtolower($package[0]), strtolower($package[1]))
+                : strtolower($package);
+            $pkgs = array();
+            foreach ($path as $name => $attrs) {
+                if (is_array($attrs)) {
+                    if (isset($attrs['install-as'])) {
+                        $name = $attrs['install-as'];
+                    }
+                    if (!in_array($attrs['role'], PEAR_Installer_Role::getInstallableRoles())) {
+                        // these are not installed
+                        continue;
+                    }
+                    if (!in_array($attrs['role'], PEAR_Installer_Role::getBaseinstallRoles())) {
+                        $attrs['baseinstalldir'] = is_array($package) ? $package[1] : $package;
+                    }
+                    if (isset($attrs['baseinstalldir'])) {
+                        $name = $attrs['baseinstalldir'] . DIRECTORY_SEPARATOR . $name;
+                    }
+                }
+                $pkgs[$name] = $this->checkFileMap($name, $package, $api, $attrs);
+                if (PEAR::isError($pkgs[$name])) {
+                    return $pkgs[$name];
+                }
+            }
+            return array_filter($pkgs, $notempty);
+        }
+        if (empty($this->filemap_cache)) {
+            if (PEAR::isError($e = $this->_lock(LOCK_SH))) {
+                return $e;
+            }
+            $err = $this->_readFileMap();
+            $this->_unlock();
+            if (PEAR::isError($err)) {
+                return $err;
+            }
+        }
+        if (!$attrs) {
+            $attrs = array('role' => 'php'); // any old call would be for PHP role only
+        }
+        if (isset($this->filemap_cache[$attrs['role']][$path])) {
+            if ($api >= '1.1' && $this->filemap_cache[$attrs['role']][$path] == $package) {
+                return false;
+            }
+            return $this->filemap_cache[$attrs['role']][$path];
+        }
+        $l = strlen($this->install_dir);
+        if (substr($path, 0, $l) == $this->install_dir) {
+            $path = preg_replace('!^'.DIRECTORY_SEPARATOR.'+!', '', substr($path, $l));
+        }
+        if (isset($this->filemap_cache[$attrs['role']][$path])) {
+            if ($api >= '1.1' && $this->filemap_cache[$attrs['role']][$path] == $package) {
+                return false;
+            }
+            return $this->filemap_cache[$attrs['role']][$path];
+        }
+        return false;
+    }
+
+    // }}}
+    // {{{ flush()
+    /**
+     * Force a reload of the filemap
+     * @since 1.5.0RC3
+     */
+    function flushFileMap()
+    {
+        $this->filemap_cache = null;
+        clearstatcache(); // ensure that the next read gets the full, current filemap
+    }
+
+    // }}}
+    // {{{ apiVersion()
+    /**
+     * Get the expected API version.  Channels API is version 1.1, as it is backwards
+     * compatible with 1.0
+     * @return string
+     */
+    function apiVersion()
+    {
+        return '1.1';
+    }
+    // }}}
+
+
+    /**
+     * Parse a package name, or validate a parsed package name array
+     * @param string|array pass in an array of format
+     *                     array(
+     *                      'package' => 'pname',
+     *                     ['channel' => 'channame',]
+     *                     ['version' => 'version',]
+     *                     ['state' => 'state',]
+     *                     ['group' => 'groupname'])
+     *                     or a string of format
+     *                     [channel://][channame/]pname[-version|-state][/group=groupname]
+     * @return array|PEAR_Error
+     */
+    function parsePackageName($param, $defaultchannel = 'pear.php.net')
+    {
+        $saveparam = $param;
+        if (is_array($param)) {
+            // convert to string for error messages
+            $saveparam = $this->parsedPackageNameToString($param);
+            // process the array
+            if (!isset($param['package'])) {
+                return PEAR::raiseError('parsePackageName(): array $param ' .
+                    'must contain a valid package name in index "param"',
+                    'package', null, null, $param);
+            }
+            if (!isset($param['uri'])) {
+                if (!isset($param['channel'])) {
+                    $param['channel'] = $defaultchannel;
+                }
+            } else {
+                $param['channel'] = '__uri';
+            }
+        } else {
+            $components = @parse_url((string) $param);
+            if (isset($components['scheme'])) {
+                if ($components['scheme'] == 'http') {
+                    // uri package
+                    $param = array('uri' => $param, 'channel' => '__uri');
+                } elseif($components['scheme'] != 'channel') {
+                    return PEAR::raiseError('parsePackageName(): only channel:// uris may ' .
+                        'be downloaded, not "' . $param . '"', 'invalid', null, null, $param);
+                }
+            }
+            if (!isset($components['path'])) {
+                return PEAR::raiseError('parsePackageName(): array $param ' .
+                    'must contain a valid package name in "' . $param . '"',
+                    'package', null, null, $param);
+            }
+            if (isset($components['host'])) {
+                // remove the leading "/"
+                $components['path'] = substr($components['path'], 1);
+            }
+            if (!isset($components['scheme'])) {
+                if (strpos($components['path'], '/') !== false) {
+                    if ($components['path']{0} == '/') {
+                        return PEAR::raiseError('parsePackageName(): this is not ' .
+                            'a package name, it begins with "/" in "' . $param . '"',
+                            'invalid', null, null, $param);
+                    }
+                    $parts = explode('/', $components['path']);
+                    $components['host'] = array_shift($parts);
+                    if (count($parts) > 1) {
+                        $components['path'] = array_pop($parts);
+                        $components['host'] .= '/' . implode('/', $parts);
+                    } else {
+                        $components['path'] = implode('/', $parts);
+                    }
+                } else {
+                    $components['host'] = $defaultchannel;
+                }
+            } else {
+                if (strpos($components['path'], '/')) {
+                    $parts = explode('/', $components['path']);
+                    $components['path'] = array_pop($parts);
+                    $components['host'] .= '/' . implode('/', $parts);
+                }
+            }
+
+            if (is_array($param)) {
+                $param['package'] = $components['path'];
+            } else {
+                $param = array(
+                    'package' => $components['path']
+                    );
+                if (isset($components['host'])) {
+                    $param['channel'] = $components['host'];
+                }
+            }
+            if (isset($components['fragment'])) {
+                $param['group'] = $components['fragment'];
+            }
+            if (isset($components['user'])) {
+                $param['user'] = $components['user'];
+            }
+            if (isset($components['pass'])) {
+                $param['pass'] = $components['pass'];
+            }
+            if (isset($components['query'])) {
+                parse_str($components['query'], $param['opts']);
+            }
+            // check for extension
+            $pathinfo = pathinfo($param['package']);
+            if (isset($pathinfo['extension']) &&
+                  in_array(strtolower($pathinfo['extension']), array('tgz', 'tar'))) {
+                $param['extension'] = $pathinfo['extension'];
+                $param['package'] = substr($pathinfo['basename'], 0,
+                    strlen($pathinfo['basename']) - 4);
+            }
+            // check for version
+            if (strpos($param['package'], '-')) {
+                $test = explode('-', $param['package']);
+                if (count($test) != 2) {
+                    return PEAR::raiseError('parsePackageName(): only one version/state ' .
+                        'delimiter "-" is allowed in "' . $saveparam . '"',
+                        'version', null, null, $param);
+                }
+                list($param['package'], $param['version']) = $test;
+            }
+        }
+        // validation
+        $info = $this->channelExists($param['channel']);
+        if (PEAR::isError($info)) {
+            return $info;
+        }
+        if (!$info) {
+            return PEAR::raiseError('unknown channel "' . $param['channel'] .
+                '" in "' . $saveparam . '"', 'channel', null, null, $param);
+        }
+        $chan = $this->getChannel($param['channel']);
+        if (PEAR::isError($chan)) {
+            return $chan;
+        }
+        if (!$chan) {
+            return PEAR::raiseError("Exception: corrupt registry, could not " .
+                "retrieve channel " . $param['channel'] . " information",
+                'registry', null, null, $param);
+        }
+        $param['channel'] = $chan->getName();
+        $validate = $chan->getValidationObject();
+        $vpackage = $chan->getValidationPackage();
+        // validate package name
+        if (!$validate->validPackageName($param['package'], $vpackage['_content'])) {
+            return PEAR::raiseError('parsePackageName(): invalid package name "' .
+                $param['package'] . '" in "' . $saveparam . '"',
+                'package', null, null, $param);
+        }
+        if (isset($param['group'])) {
+            if (!PEAR_Validate::validGroupName($param['group'])) {
+                return PEAR::raiseError('parsePackageName(): dependency group "' . $param['group'] .
+                    '" is not a valid group name in "' . $saveparam . '"', 'group', null, null,
+                    $param);
+            }
+        }
+        if (isset($param['state'])) {
+            if (!in_array(strtolower($param['state']), $validate->getValidStates())) {
+                return PEAR::raiseError('parsePackageName(): state "' . $param['state']
+                    . '" is not a valid state in "' . $saveparam . '"',
+                    'state', null, null, $param);
+            }
+        }
+        if (isset($param['version'])) {
+            if (isset($param['state'])) {
+                return PEAR::raiseError('parsePackageName(): cannot contain both ' .
+                    'a version and a stability (state) in "' . $saveparam . '"',
+                    'version/state', null, null, $param);
+            }
+            // check whether version is actually a state
+            if (in_array(strtolower($param['version']), $validate->getValidStates())) {
+                $param['state'] = strtolower($param['version']);
+                unset($param['version']);
+            } else {
+                if (!$validate->validVersion($param['version'])) {
+                    return PEAR::raiseError('parsePackageName(): "' . $param['version'] .
+                        '" is neither a valid version nor a valid state in "' .
+                        $saveparam . '"', 'version/state', null, null, $param);
+                }
+            }
+        }
+        return $param;
+    }
+
+    /**
+     * @param array
+     * @return string
+     */
+    function parsedPackageNameToString($parsed, $brief = false)
+    {
+        if (is_string($parsed)) {
+            return $parsed;
+        }
+        if (is_object($parsed)) {
+            $p = $parsed;
+            $parsed = array(
+                'package' => $p->getPackage(),
+                'channel' => $p->getChannel(),
+                'version' => $p->getVersion(),
+            );
+        }
+        if (isset($parsed['uri'])) {
+            return $parsed['uri'];
+        }
+        if ($brief) {
+            if ($channel = $this->channelAlias($parsed['channel'])) {
+                return $channel . '/' . $parsed['package'];
+            }
+        }
+        $upass = '';
+        if (isset($parsed['user'])) {
+            $upass = $parsed['user'];
+            if (isset($parsed['pass'])) {
+                $upass .= ':' . $parsed['pass'];
+            }
+            $upass = "$upass@";
+        }
+        $ret = 'channel://' . $upass . $parsed['channel'] . '/' . $parsed['package'];
+        if (isset($parsed['version']) || isset($parsed['state'])) {
+            $ver = isset($parsed['version']) ? $parsed['version'] : '';
+            $ver .= isset($parsed['state']) ? $parsed['state'] : '';
+            $ret .= '-' . $ver;
+        }
+        if (isset($parsed['extension'])) {
+            $ret .= '.' . $parsed['extension'];
+        }
+        if (isset($parsed['opts'])) {
+            $ret .= '?';
+            foreach ($parsed['opts'] as $name => $value) {
+                $parsed['opts'][$name] = "$name=$value";
+            }
+            $ret .= implode('&', $parsed['opts']);
+        }
+        if (isset($parsed['group'])) {
+            $ret .= '#' . $parsed['group'];
+        }
+        return $ret;
+    }
 }<?php
 /**
  * PEAR_REST
@@ -83923,7 +84562,7 @@ class PEAR_Registry extends PEAR
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: REST.php,v 1.40 2009/03/26 23:12:46 dufuz Exp $
+ * @version    CVS: $Id: REST.php 286489 2009-07-29 05:59:08Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -83942,7 +84581,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/XMLParser.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -83953,7 +84592,7 @@ class PEAR_REST
 
     function PEAR_REST(&$config, $options = array())
     {
-        $this->config = &$config;
+        $this->config   = &$config;
         $this->_options = $options;
     }
 
@@ -83970,7 +84609,6 @@ class PEAR_REST
      */
     function retrieveCacheFirst($url, $accept = false, $forcestring = false, $channel = false)
     {
-
         $cachefile = $this->config->get('cache_dir') . DIRECTORY_SEPARATOR .
             md5($url) . 'rest.cachefile';
 
@@ -84127,11 +84765,9 @@ class PEAR_REST
      */
     function saveCache($url, $contents, $lastmodified, $nochange = false, $cacheid = null)
     {
-        $cacheidfile = $this->config->get('cache_dir') . DIRECTORY_SEPARATOR .
-            md5($url) . 'rest.cacheid';
-
-        $cachefile = $this->config->get('cache_dir') . DIRECTORY_SEPARATOR .
-            md5($url) . 'rest.cachefile';
+        $cachedir    = $this->config->get('cache_dir') . DIRECTORY_SEPARATOR . md5($url);
+        $cacheidfile = $cachedir . 'rest.cacheid';
+        $cachefile   = $cachedir . 'rest.cachefile';
 
         if ($cacheid === null && $nochange) {
             $cacheid = unserialize(implode('', file($cacheidfile)));
@@ -84265,7 +84901,7 @@ class PEAR_REST
         }
 
         $request .= $ifmodifiedsince .
-            "User-Agent: PEAR/1.8.0/PHP/" . PHP_VERSION . "\r\n";
+            "User-Agent: PEAR/1.9.0/PHP/" . PHP_VERSION . "\r\n";
 
         $username = $this->config->get('username', null, $channel);
         $password = $this->config->get('password', null, $channel);
@@ -84373,7 +85009,7 @@ class PEAR_REST
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: 10.php,v 1.60 2009/03/07 23:09:56 dufuz Exp $
+ * @version    CVS: $Id: 10.php 287558 2009-08-21 22:21:28Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a12
  */
@@ -84391,7 +85027,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/REST.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a12
  */
@@ -84425,16 +85061,18 @@ class PEAR_REST_10
      */
     function getDownloadURL($base, $packageinfo, $prefstate, $installed, $channel = false)
     {
-        $channel = $packageinfo['channel'];
-        $package = $packageinfo['package'];
         $states = $this->betterStates($prefstate, true);
         if (!$states) {
             return PEAR::raiseError('"' . $prefstate . '" is not a valid state');
         }
 
-        $state   = isset($packageinfo['state'])   ? $packageinfo['state']   : null;
-        $version = isset($packageinfo['version']) ? $packageinfo['version'] : null;
-        $info = $this->_rest->retrieveData($base . 'r/' . strtolower($package) . '/allreleases.xml', false, false, $channel);
+        $channel  = $packageinfo['channel'];
+        $package  = $packageinfo['package'];
+        $state    = isset($packageinfo['state'])   ? $packageinfo['state']   : null;
+        $version  = isset($packageinfo['version']) ? $packageinfo['version'] : null;
+        $restFile = $base . 'r/' . strtolower($package) . '/allreleases.xml';
+
+        $info = $this->_rest->retrieveData($restFile, false, false, $channel);
         if (PEAR::isError($info)) {
             return PEAR::raiseError('No releases available for package "' .
                 $channel . '/' . $package . '"');
@@ -84486,22 +85124,27 @@ class PEAR_REST_10
     function getDepDownloadURL($base, $xsdversion, $dependency, $deppackage,
                                $prefstate = 'stable', $installed = false, $channel = false)
     {
-        $channel = $dependency['channel'];
-        $package = $dependency['name'];
         $states = $this->betterStates($prefstate, true);
         if (!$states) {
             return PEAR::raiseError('"' . $prefstate . '" is not a valid state');
         }
-        $state   = isset($dependency['state'])   ? $dependency['state']   : null;
-        $version = isset($dependency['version']) ? $dependency['version'] : null;
-        $info = $this->_rest->retrieveData($base . 'r/' . strtolower($package) . '/allreleases.xml', false, false, $channel);
+
+        $channel  = $dependency['channel'];
+        $package  = $dependency['name'];
+        $state    = isset($dependency['state'])   ? $dependency['state']   : null;
+        $version  = isset($dependency['version']) ? $dependency['version'] : null;
+        $restFile = $base . 'r/' . strtolower($package) . '/allreleases.xml';
+
+        $info = $this->_rest->retrieveData($restFile, false, false, $channel);
         if (PEAR::isError($info)) {
             return PEAR::raiseError('Package "' . $deppackage['channel'] . '/' . $deppackage['package']
                 . '" dependency "' . $channel . '/' . $package . '" has no releases');
         }
+
         if (!is_array($info) || !isset($info['r'])) {
             return false;
         }
+
         $exclude = array();
         $min = $max = $recommended = false;
         if ($xsdversion == '1.0') {
@@ -84619,19 +85262,23 @@ class PEAR_REST_10
         if (!$found) {
             $release = $info['r'][0];
         }
-        $pinfo = $this->_rest->retrieveCacheFirst($base . 'p/' . strtolower($package) . '/' .
+
+        $packageLower = strtolower($package);
+        $pinfo = $this->_rest->retrieveCacheFirst($base . 'p/' . $packageLower . '/' .
             'info.xml', false, false, $channel);
         if (PEAR::isError($pinfo)) {
             return PEAR::raiseError('Package "' . $package .
                 '" does not have REST info xml available');
         }
-        $releaseinfo = $this->_rest->retrieveCacheFirst($base . 'r/' . strtolower($package) . '/' .
+
+        $releaseinfo = $this->_rest->retrieveCacheFirst($base . 'r/' . $packageLower . '/' .
             $release['v'] . '.xml', false, false, $channel);
         if (PEAR::isError($releaseinfo)) {
             return PEAR::raiseError('Package "' . $package . '" Version "' . $release['v'] .
                 '" does not have REST xml available');
         }
-        $packagexml = $this->_rest->retrieveCacheFirst($base . 'r/' . strtolower($package) . '/' .
+
+        $packagexml = $this->_rest->retrieveCacheFirst($base . 'r/' . $packageLower . '/' .
             'deps.' . $release['v'] . '.txt', false, true, $channel);
         if (PEAR::isError($packagexml)) {
             return PEAR::raiseError('Package "' . $package . '" Version "' . $release['v'] .
@@ -84642,39 +85289,49 @@ class PEAR_REST_10
         if (!$packagexml) {
             $packagexml = array();
         }
-        $allinfo = $this->_rest->retrieveData($base . 'r/' . strtolower($package) .
+
+        $allinfo = $this->_rest->retrieveData($base . 'r/' . $packageLower .
             '/allreleases.xml', false, false, $channel);
         if (!is_array($allinfo['r']) || !isset($allinfo['r'][0])) {
             $allinfo['r'] = array($allinfo['r']);
         }
+
         $compatible = false;
         foreach ($allinfo['r'] as $release) {
             if ($release['v'] != $releaseinfo['v']) {
                 continue;
             }
+
             if (!isset($release['co'])) {
                 break;
             }
+
             $compatible = array();
             if (!is_array($release['co']) || !isset($release['co'][0])) {
                 $release['co'] = array($release['co']);
             }
+
             foreach ($release['co'] as $entry) {
                 $comp = array();
-                $comp['name'] = $entry['p'];
+                $comp['name']    = $entry['p'];
                 $comp['channel'] = $entry['c'];
-                $comp['min'] = $entry['min'];
-                $comp['max'] = $entry['max'];
+                $comp['min']     = $entry['min'];
+                $comp['max']     = $entry['max'];
                 if (isset($entry['x']) && !is_array($entry['x'])) {
                     $comp['exclude'] = $entry['x'];
                 }
+
                 $compatible[] = $comp;
             }
+
             if (count($compatible) == 1) {
                 $compatible = $compatible[0];
             }
+
             break;
         }
+
+        $deprecated = false;
         if (isset($pinfo['dc']) && isset($pinfo['dp'])) {
             if (is_array($pinfo['dp'])) {
                 $deprecated = array('channel' => (string) $pinfo['dc'],
@@ -84683,30 +85340,24 @@ class PEAR_REST_10
                 $deprecated = array('channel' => (string) $pinfo['dc'],
                                     'package' => trim($pinfo['dp']));
             }
-        } else {
-            $deprecated = false;
         }
+
+        $return = array(
+            'version'    => $releaseinfo['v'],
+            'info'       => $packagexml,
+            'package'    => $releaseinfo['p']['_content'],
+            'stability'  => $releaseinfo['st'],
+            'compatible' => $compatible,
+            'deprecated' => $deprecated,
+        );
+
         if ($found) {
-            return
-                array('version' => $releaseinfo['v'],
-                      'info' => $packagexml,
-                      'package' => $releaseinfo['p']['_content'],
-                      'stability' => $releaseinfo['st'],
-                      'url' => $releaseinfo['g'],
-                      'compatible' => $compatible,
-                      'deprecated' => $deprecated,
-                );
-        } else {
-            return
-                array('version' => $releaseinfo['v'],
-                      'package' => $releaseinfo['p']['_content'],
-                      'stability' => $releaseinfo['st'],
-                      'info' => $packagexml,
-                      'compatible' => $compatible,
-                      'deprecated' => $deprecated,
-                      'php' => $phpversion
-                );
+            $return['url'] = $releaseinfo['g'];
+            return $return;
         }
+
+        $return['php'] = $phpversion;
+        return $return;
     }
 
     function listPackages($base, $channel = false)
@@ -84715,12 +85366,15 @@ class PEAR_REST_10
         if (PEAR::isError($packagelist)) {
             return $packagelist;
         }
+
         if (!is_array($packagelist) || !isset($packagelist['p'])) {
             return array();
         }
+
         if (!is_array($packagelist['p'])) {
             $packagelist['p'] = array($packagelist['p']);
         }
+
         return $packagelist['p'];
     }
 
@@ -84741,10 +85395,12 @@ class PEAR_REST_10
         if (PEAR::isError($packagelist)) {
             return $packagelist;
         }
+
         if (!is_array($packagelist) || !isset($packagelist['p'])) {
             $ret = array();
             return $ret;
         }
+
         if (!is_array($packagelist['p'])) {
             $packagelist['p'] = array($packagelist['p']);
         }
@@ -84761,6 +85417,7 @@ class PEAR_REST_10
                     $categories[$cat] = $inf['ca'];
                 }
         }
+
         return array_values($categories);
     }
 
@@ -84779,9 +85436,11 @@ class PEAR_REST_10
         if (PEAR::isError($packagelist)) {
             return $packagelist;
         }
+
         if (!is_array($packagelist) || !isset($packagelist['p'])) {
             return array();
         }
+
         if (!is_array($packagelist['p']) ||
             !isset($packagelist['p'][0])) { // only 1 pkg
             $packagelist = array($packagelist['p']);
@@ -84825,7 +85484,7 @@ class PEAR_REST_10
         }
         if ($this->_rest->config->get('verbose') > 0) {
             $ui = &PEAR_Frontend::singleton();
-            $ui->log('Retrieving data...0%', false);
+            $ui->log('Retrieving data...0%', true);
         }
         $ret = array();
         if (!is_array($packagelist) || !isset($packagelist['p'])) {
@@ -86232,7 +86891,7 @@ Double-click this file to add it to the current user registry.
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Common.php,v 1.20 2009/02/25 00:15:49 dufuz Exp $
+ * @version    CVS: $Id: Common.php 276394 2009-02-25 00:15:49Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -86270,7 +86929,7 @@ define('PEAR_TASK_PACKAGEANDINSTALL', 3);
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  * @abstract
@@ -86433,7 +87092,7 @@ class PEAR_Task_Common
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Postinstallscript.php,v 1.22 2009/02/24 23:45:56 dufuz Exp $
+ * @version    CVS: $Id: Postinstallscript.php 276385 2009-02-24 23:46:03Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -86451,7 +87110,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Task/Common.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -86755,7 +87414,7 @@ class PEAR_Task_Postinstallscript extends PEAR_Task_Common
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: rw.php,v 1.14 2009/02/24 23:45:32 dufuz Exp $
+ * @version    CVS: $Id: rw.php 276385 2009-02-24 23:46:03Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a10
  */
@@ -86770,7 +87429,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Task/Postinstallscript.p
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a10
  */
@@ -86923,7 +87582,7 @@ class PEAR_Task_Postinstallscript_rw extends PEAR_Task_Postinstallscript
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Replace.php,v 1.19 2009/02/25 00:15:49 dufuz Exp $
+ * @version    CVS: $Id: Replace.php 276394 2009-02-25 00:15:49Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -86938,7 +87597,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Task/Common.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -87087,66 +87746,66 @@ class PEAR_Task_Replace extends PEAR_Task_Common
         return $contents;
     }
 }
-?><?php
-/**
- * <tasks:replace> - read/write version
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: rw.php,v 1.5 2009/02/24 23:45:44 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a10
- */
-/**
- * Base class
- */
-require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Task/Replace.php';
-/**
- * Abstracts the replace task xml.
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a10
- */
-class PEAR_Task_Replace_rw extends PEAR_Task_Replace
-{
-    function PEAR_Task_Replace_rw(&$pkg, &$config, &$logger, $fileXml)
-    {
-        parent::PEAR_Task_Common($config, $logger, PEAR_TASK_PACKAGE);
-        $this->_contents = $fileXml;
-        $this->_pkg = &$pkg;
-        $this->_params = array();
-    }
-
-    function validate()
-    {
-        return $this->validateXml($this->_pkg, $this->_params, $this->config, $this->_contents);
-    }
-
-    function setInfo($from, $to, $type)
-    {
-        $this->_params = array('attribs' => array('from' => $from, 'to' => $to, 'type' => $type));
-    }
-
-    function getName()
-    {
-        return 'replace';
-    }
-
-    function getXml()
-    {
-        return $this->_params;
-    }
-}
+?><?php
+/**
+ * <tasks:replace> - read/write version
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: rw.php 276385 2009-02-24 23:46:03Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a10
+ */
+/**
+ * Base class
+ */
+require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Task/Replace.php';
+/**
+ * Abstracts the replace task xml.
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a10
+ */
+class PEAR_Task_Replace_rw extends PEAR_Task_Replace
+{
+    function PEAR_Task_Replace_rw(&$pkg, &$config, &$logger, $fileXml)
+    {
+        parent::PEAR_Task_Common($config, $logger, PEAR_TASK_PACKAGE);
+        $this->_contents = $fileXml;
+        $this->_pkg = &$pkg;
+        $this->_params = array();
+    }
+
+    function validate()
+    {
+        return $this->validateXml($this->_pkg, $this->_params, $this->config, $this->_contents);
+    }
+
+    function setInfo($from, $to, $type)
+    {
+        $this->_params = array('attribs' => array('from' => $from, 'to' => $to, 'type' => $type));
+    }
+
+    function getName()
+    {
+        return 'replace';
+    }
+
+    function getXml()
+    {
+        return $this->_params;
+    }
+}
 ?><?php
 /**
  * <tasks:unixeol>
@@ -87158,7 +87817,7 @@ class PEAR_Task_Replace_rw extends PEAR_Task_Replace
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Unixeol.php,v 1.12 2009/02/25 00:15:49 dufuz Exp $
+ * @version    CVS: $Id: Unixeol.php 276394 2009-02-25 00:15:49Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -87173,7 +87832,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Task/Common.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -87223,61 +87882,61 @@ class PEAR_Task_Unixeol extends PEAR_Task_Common
         return preg_replace("/\r\n|\n\r|\r|\n/", "\n", $contents);
     }
 }
-?><?php
-/**
- * <tasks:unixeol> - read/write version
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: rw.php,v 1.6 2009/02/24 23:45:30 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a10
- */
-/**
- * Base class
- */
-require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Task/Unixeol.php';
-/**
- * Abstracts the unixeol task xml.
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a10
- */
-class PEAR_Task_Unixeol_rw extends PEAR_Task_Unixeol
-{
-    function PEAR_Task_Unixeol_rw(&$pkg, &$config, &$logger, $fileXml)
-    {
-        parent::PEAR_Task_Common($config, $logger, PEAR_TASK_PACKAGE);
-        $this->_contents = $fileXml;
-        $this->_pkg = &$pkg;
-        $this->_params = array();
-    }
-
-    function validate()
-    {
-        return true;
-    }
-
-    function getName()
-    {
-        return 'unixeol';
-    }
-
-    function getXml()
-    {
-        return '';
-    }
-}
+?><?php
+/**
+ * <tasks:unixeol> - read/write version
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: rw.php 276385 2009-02-24 23:46:03Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a10
+ */
+/**
+ * Base class
+ */
+require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Task/Unixeol.php';
+/**
+ * Abstracts the unixeol task xml.
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a10
+ */
+class PEAR_Task_Unixeol_rw extends PEAR_Task_Unixeol
+{
+    function PEAR_Task_Unixeol_rw(&$pkg, &$config, &$logger, $fileXml)
+    {
+        parent::PEAR_Task_Common($config, $logger, PEAR_TASK_PACKAGE);
+        $this->_contents = $fileXml;
+        $this->_pkg = &$pkg;
+        $this->_params = array();
+    }
+
+    function validate()
+    {
+        return true;
+    }
+
+    function getName()
+    {
+        return 'unixeol';
+    }
+
+    function getXml()
+    {
+        return '';
+    }
+}
 ?><?php
 /**
  * <tasks:windowseol>
@@ -87289,7 +87948,7 @@ class PEAR_Task_Unixeol_rw extends PEAR_Task_Unixeol
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Windowseol.php,v 1.11 2009/02/25 00:15:49 dufuz Exp $
+ * @version    CVS: $Id: Windowseol.php 276394 2009-02-25 00:15:49Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -87304,7 +87963,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Task/Common.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -87354,61 +88013,61 @@ class PEAR_Task_Windowseol extends PEAR_Task_Common
         return preg_replace("/\r\n|\n\r|\r|\n/", "\r\n", $contents);
     }
 }
-?><?php
-/**
- * <tasks:windowseol> - read/write version
- *
- * PHP versions 4 and 5
- *
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: rw.php,v 1.6 2009/02/24 23:45:20 dufuz Exp $
- * @link       http://pear.php.net/package/PEAR
- * @since      File available since Release 1.4.0a10
- */
-/**
- * Base class
- */
-require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Task/Windowseol.php';
-/**
- * Abstracts the windowseol task xml.
- * @category   pear
- * @package    PEAR
- * @author     Greg Beaver <cellog at php.net>
- * @copyright  1997-2009 The Authors
- * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
- * @link       http://pear.php.net/package/PEAR
- * @since      Class available since Release 1.4.0a10
- */
-class PEAR_Task_Windowseol_rw extends PEAR_Task_Windowseol
-{
-    function PEAR_Task_Windowseol_rw(&$pkg, &$config, &$logger, $fileXml)
-    {
-        parent::PEAR_Task_Common($config, $logger, PEAR_TASK_PACKAGE);
-        $this->_contents = $fileXml;
-        $this->_pkg = &$pkg;
-        $this->_params = array();
-    }
-
-    function validate()
-    {
-        return true;
-    }
-
-    function getName()
-    {
-        return 'windowseol';
-    }
-
-    function getXml()
-    {
-        return '';
-    }
-}
+?><?php
+/**
+ * <tasks:windowseol> - read/write version
+ *
+ * PHP versions 4 and 5
+ *
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    CVS: $Id: rw.php 276385 2009-02-24 23:46:03Z dufuz $
+ * @link       http://pear.php.net/package/PEAR
+ * @since      File available since Release 1.4.0a10
+ */
+/**
+ * Base class
+ */
+require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Task/Windowseol.php';
+/**
+ * Abstracts the windowseol task xml.
+ * @category   pear
+ * @package    PEAR
+ * @author     Greg Beaver <cellog at php.net>
+ * @copyright  1997-2009 The Authors
+ * @license    http://opensource.org/licenses/bsd-license.php New BSD License
+ * @version    Release: 1.9.0
+ * @link       http://pear.php.net/package/PEAR
+ * @since      Class available since Release 1.4.0a10
+ */
+class PEAR_Task_Windowseol_rw extends PEAR_Task_Windowseol
+{
+    function PEAR_Task_Windowseol_rw(&$pkg, &$config, &$logger, $fileXml)
+    {
+        parent::PEAR_Task_Common($config, $logger, PEAR_TASK_PACKAGE);
+        $this->_contents = $fileXml;
+        $this->_pkg = &$pkg;
+        $this->_params = array();
+    }
+
+    function validate()
+    {
+        return true;
+    }
+
+    function getName()
+    {
+        return 'windowseol';
+    }
+
+    function getXml()
+    {
+        return '';
+    }
+}
 ?><?php
 /**
  * PEAR_Validate
@@ -87420,7 +88079,7 @@ class PEAR_Task_Windowseol_rw extends PEAR_Task_Windowseol
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: Validate.php,v 1.54 2009/02/24 23:38:23 dufuz Exp $
+ * @version    CVS: $Id: Validate.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -87443,7 +88102,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Validator/PECL.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a1
  */
@@ -88048,7 +88707,7 @@ class PEAR_Validate
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2006 The PHP Group
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: PECL.php,v 1.10 2009/02/24 23:39:19 dufuz Exp $
+ * @version    CVS: $Id: PECL.php 276383 2009-02-24 23:39:37Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a5
  */
@@ -88063,7 +88722,7 @@ require_once 'phar://install-pear-nozlib.phar/' . 'PEAR/Validate.php';
  * @author     Greg Beaver <cellog at php.net>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    Release: 1.8.0
+ * @version    Release: 1.9.0
  * @link       http://pear.php.net/package/PEAR
  * @since      Class available since Release 1.4.0a5
  */
@@ -88111,7 +88770,7 @@ class PEAR_Validator_PECL extends PEAR_Validate
  * @author     Stephan Schmidt (original XML_Unserializer code)
  * @copyright  1997-2009 The Authors
  * @license   http://opensource.org/licenses/bsd-license New BSD License
- * @version    CVS: $Id: XMLParser.php,v 1.22 2009/03/08 00:45:39 dufuz Exp $
+ * @version    CVS: $Id: XMLParser.php 282970 2009-06-28 23:10:07Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 1.4.0a1
  */
@@ -88124,7 +88783,7 @@ class PEAR_Validator_PECL extends PEAR_Validate
  * @author    Stephan Schmidt (original XML_Unserializer code)
  * @copyright 1997-2009 The Authors
  * @license   http://opensource.org/licenses/bsd-license New BSD License
- * @version   Release: 1.8.0
+ * @version   Release: 1.9.0
  * @link      http://pear.php.net/package/PEAR
  * @since     Class available since Release 1.4.0a1
  */
@@ -88146,13 +88805,13 @@ class PEAR_XMLParser
      * stack for all data that is found
      * @var array    $_dataStack
      */
-    var $_dataStack  =   array();
+    var $_dataStack = array();
 
     /**
      * stack for all values that are generated
      * @var array    $_valStack
      */
-    var $_valStack  =   array();
+    var $_valStack = array();
 
     /**
      * current tag depth
@@ -88184,8 +88843,7 @@ class PEAR_XMLParser
             include_once 'phar://install-pear-nozlib.phar/' . 'PEAR.php';
             return PEAR::raiseError("XML Extension not found", 1);
         }
-        $this->_valStack = array();
-        $this->_dataStack = array();
+        $this->_dataStack =  $this->_valStack = array();
         $this->_depth = 0;
 
         if (
@@ -88199,6 +88857,7 @@ class PEAR_XMLParser
 
         if (version_compare(phpversion(), '5.0.0', 'lt') && $this->encoding == 'UTF-8') {
             $data = utf8_decode($data);
+            $this->encoding = 'ISO-8859-1';
         }
 
         $xp = xml_parser_create($this->encoding);
@@ -88228,25 +88887,21 @@ class PEAR_XMLParser
      */
     function startHandler($parser, $element, $attribs)
     {
-        $type = 'string';
-
         $this->_depth++;
         $this->_dataStack[$this->_depth] = null;
 
         $val = array(
-                     'name'         => $element,
-                     'value'        => null,
-                     'type'         => $type,
-                     'childrenKeys' => array(),
-                     'aggregKeys'   => array()
-                    );
+            'name'         => $element,
+            'value'        => null,
+            'type'         => 'string',
+            'childrenKeys' => array(),
+            'aggregKeys'   => array()
+       );
 
         if (count($attribs) > 0) {
             $val['children'] = array();
             $val['type'] = 'array';
-
             $val['children']['attribs'] = $attribs;
-
         }
 
         array_push($this->_valStack, $val);
@@ -88277,18 +88932,14 @@ class PEAR_XMLParser
         $data  = $this->postProcess($this->_dataStack[$this->_depth], $element);
 
         // adjust type of the value
-        switch(strtolower($value['type'])) {
-
+        switch (strtolower($value['type'])) {
             // unserialize an array
             case 'array':
                 if ($data !== '') {
                     $value['children']['_content'] = $data;
                 }
-                if (isset($value['children'])) {
-                    $value['value'] = $value['children'];
-                } else {
-                    $value['value'] = array();
-                }
+
+                $value['value'] = isset($value['children']) ? $value['children'] : array();
                 break;
 
             /*
@@ -88360,6 +89011,38 @@ class PEAR_XMLParser
         $this->_dataStack[$this->_depth] .= $cdata;
     }
 }<?php
+/**
+ * This is only meant for PHP 5 to get rid of certain strict warning
+ * that doesn't get hidden since it's in the shutdown function
+ */
+class PEAR5
+{
+    /**
+    * If you have a class that's mostly/entirely static, and you need static
+    * properties, you can use this method to simulate them. Eg. in your method(s)
+    * do this: $myVar = &PEAR5::getStaticProperty('myclass', 'myVar');
+    * You MUST use a reference, or they will not persist!
+    *
+    * @access public
+    * @param  string $class  The calling classname, to prevent clashes
+    * @param  string $var    The variable to retrieve.
+    * @return mixed   A reference to the variable. If not set it will be
+    *                 auto initialised to NULL.
+    */
+    static function &getStaticProperty($class, $var)
+    {
+        static $properties;
+        if (!isset($properties[$class])) {
+            $properties[$class] = array();
+        }
+
+        if (!array_key_exists($var, $properties[$class])) {
+            $properties[$class][$var] = null;
+        }
+
+        return $properties[$class][$var];
+    }
+}<?php
 /* vim: set expandtab tabstop=4 shiftwidth=4 foldmethod=marker: */
 // +-----------------------------------------------------------------------------+
 // | Copyright (c) 2003 Sérgio Gonçalves Carvalho                                |
@@ -93560,7 +94243,7 @@ as well as for characteristic extraction from the graph topology.
  * @author     Tomas V.V.Cox <cox at idecnet.com>
  * @copyright  1997-2009 The Authors
  * @license    http://opensource.org/licenses/bsd-license.php New BSD License
- * @version    CVS: $Id: System.php,v 1.66 2009/02/24 23:52:56 dufuz Exp $
+ * @version    CVS: $Id: System.php 276386 2009-02-24 23:52:56Z dufuz $
  * @link       http://pear.php.net/package/PEAR
  * @since      File available since Release 0.1
  */
@@ -93602,7 +94285,7 @@ $GLOBALS['_System_temp_files'] = array();
 * @author     Tomas V.V. Cox <cox at idecnet.com>
 * @copyright  1997-2006 The PHP Group
 * @license    http://opensource.org/licenses/bsd-license.php New BSD License
-* @version    Release: 1.8.0
+* @version    Release: 1.9.0
 * @link       http://pear.php.net/package/PEAR
 * @since      Class available since Release 0.1
 * @static
@@ -94214,7 +94897,7 @@ class System
  * @author    Stephan Schmidt <schst at php.net>
  * @copyright 2003-2008 Stephan Schmidt <schst at php.net>
  * @license   http://opensource.org/licenses/bsd-license New BSD License
- * @version   CVS: $Id: Util.php,v 1.39 2009/02/09 14:23:42 ashnazg Exp $
+ * @version   CVS: $Id: Util.php 275418 2009-02-09 14:23:42Z ashnazg $
  * @link      http://pear.php.net/package/XML_Util
  */
 
@@ -98095,4 +98778,4 @@ iEYEABECAAYFAkk8e2QACgkQcqMhusJF8XULZgCg0iwVLWueraJzK5s1AesDkVzv
 GucAn22sSv3QiTSUWG9BmakiW9hFsb4V
 =g2mr
 -----END PGP SIGNATURE-----
-                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           G\$UÈðÙD7ðˆ­TŸ   GBMB
\ No newline at end of file
+                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           ¢ùZß÷”?Aj˜¢^Ô½1   GBMB
\ No newline at end of file
diff --git a/php.ini-dist b/php.ini-dist
index 9c5d6b1..3fe4aa4 100644
--- a/php.ini-dist
+++ b/php.ini-dist
@@ -552,6 +552,9 @@ file_uploads = On
 upload_max_filesize = 2M
 
 
+; Maximum number of files that can be uploaded via a single request
+max_file_uploads = 20
+
 ;;;;;;;;;;;;;;;;;;
 ; Fopen wrappers ;
 ;;;;;;;;;;;;;;;;;;
diff --git a/php.ini-recommended b/php.ini-recommended
index 784912e..3ac591f 100644
--- a/php.ini-recommended
+++ b/php.ini-recommended
@@ -603,6 +603,9 @@ file_uploads = On
 upload_max_filesize = 2M
 
 
+; Maximum number of files that can be uploaded via a single request
+max_file_uploads = 20
+
 ;;;;;;;;;;;;;;;;;;
 ; Fopen wrappers ;
 ;;;;;;;;;;;;;;;;;;
diff --git a/run-tests.php b/run-tests.php
index 81f218b..1043e19 100755
--- a/run-tests.php
+++ b/run-tests.php
@@ -24,7 +24,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: run-tests.php 286503 2009-07-29 10:06:55Z cellog $ */
+/* $Id: run-tests.php 291972 2009-12-11 07:34:06Z jani $ */
 
 /* Sanity check to ensure that pcre extension needed by this script is available.
  * In the event it is not, print a nice error message indicating that this script will
@@ -634,7 +634,7 @@ if (isset($argc) && $argc > 1) {
 					$html_output = is_resource($html_file);
 					break;
 				case '--version':
-					echo '$Revision: 286503 $' . "\n";
+					echo '$Revision: 291972 $' . "\n";
 					exit(1);
 
 				default:
@@ -1426,7 +1426,7 @@ TEST $file
 				$env['USE_ZEND_ALLOC'] = '1';
 			}
 
-			$output = system_with_timeout("$extra $php $pass_options -q $ini_settings $test_skipif", $env);
+			$output = system_with_timeout("$extra $php $pass_options -q $ini_settings -d display_errors=0 $test_skipif", $env);
 
 			if (!$cfg['keep']['skip']) {
 				@unlink($test_skipif);
diff --git a/sapi/apache2handler/sapi_apache2.c b/sapi/apache2handler/sapi_apache2.c
index 4cdad3a..679a30f 100644
--- a/sapi/apache2handler/sapi_apache2.c
+++ b/sapi/apache2handler/sapi_apache2.c
@@ -18,7 +18,7 @@
    +----------------------------------------------------------------------+
  */
 
-/* $Id: sapi_apache2.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: sapi_apache2.c 291305 2009-11-25 12:35:42Z jani $ */
 
 #define ZEND_INCLUDE_FULL_WINDOWS_HEADERS
 
@@ -99,7 +99,7 @@ php_apache_sapi_header_handler(sapi_header_struct *sapi_header,sapi_headers_stru
 	ptr = val;
 
 	*val = '\0';
-	
+
 	do {
 		val++;
 	} while (*val == ' ');
@@ -115,7 +115,7 @@ php_apache_sapi_header_handler(sapi_header_struct *sapi_header,sapi_headers_stru
 		apr_table_add(ctx->r->headers_out, sapi_header->header, val);
 	}
 	*ptr = ':';
-	
+
 	return SAPI_HEADER_ADD;
 }
 
@@ -136,8 +136,8 @@ php_apache_sapi_send_headers(sapi_headers_struct *sapi_headers TSRMLS_DC)
 			apr_table_set(ctx->r->subprocess_env, "force-response-1.0", "true");
 		}
 	}
-	
-	/*	call ap_set_content_type only once, else each time we call it, 
+
+	/*	call ap_set_content_type only once, else each time we call it,
 		configured output filters for that content type will be added */
 	if (!ctx->content_type) {
 		ctx->content_type = sapi_get_default_content_type(TSRMLS_C);
@@ -177,7 +177,7 @@ php_apache_sapi_read_post(char *buf, uint count_bytes TSRMLS_DC)
 		buf += len;
 		len = count_bytes - tlen;
 	}
-	
+
 	return tlen;
 }
 
@@ -223,6 +223,10 @@ php_apache_sapi_getenv(char *name, size_t name_len TSRMLS_DC)
 {
 	php_struct *ctx = SG(server_context);
 	const char *env_var;
+
+	if (ctx == NULL) {
+		return NULL;
+	}
 	
 	env_var = apr_table_get(ctx->r->subprocess_env, name);
 
@@ -301,7 +305,8 @@ static void php_apache_sapi_log_message_ex(char *msg, request_rec *r)
 	}
 }
 
-static time_t php_apache_sapi_get_request_time(TSRMLS_D) {
+static time_t php_apache_sapi_get_request_time(TSRMLS_D)
+{
 	php_struct *ctx = SG(server_context);
 	return apr_time_sec(ctx->r->request_time);
 }
@@ -380,7 +385,7 @@ static int php_pre_config(apr_pool_t *pconf, apr_pool_t *plog, apr_pool_t *ptemp
 	int threaded_mpm;
 
 	ap_mpm_query(AP_MPMQ_IS_THREADED, &threaded_mpm);
-	if(threaded_mpm) {
+	if (threaded_mpm) {
 		ap_log_error(APLOG_MARK, APLOG_CRIT, 0, 0, "Apache is running a threaded MPM, but your PHP Module is not compiled to be threadsafe.  You need to recompile PHP.");
 		return DONE;
 	}
@@ -484,12 +489,12 @@ typedef struct {
 		uint str_len;
 		php_conf_rec *c = ap_get_module_config(r->per_dir_config, &php5_module);
 
-		for (zend_hash_internal_pointer_reset(&c->config); 
-				zend_hash_get_current_key_ex(&c->config, &str, &str_len, NULL, 0,  NULL) == HASH_KEY_IS_STRING;
-				zend_hash_move_forward(&c->config)
+		for (zend_hash_internal_pointer_reset(&c->config);
+			zend_hash_get_current_key_ex(&c->config, &str, &str_len, NULL, 0, NULL) == HASH_KEY_IS_STRING;
+			zend_hash_move_forward(&c->config)
 		) {
 			zend_restore_ini_entry(str, str_len, ZEND_INI_STAGE_SHUTDOWN);
-		}	
+		}
 	}
 	if (p) {
 		((php_struct *)SG(server_context))->r = p;
@@ -539,7 +544,7 @@ normal:
 	}
 
 	/* Give a 404 if PATH_INFO is used but is explicitly disabled in
-	 * the configuration; default behaviour is to accept. */ 
+	 * the configuration; default behaviour is to accept. */
 	if (r->used_path_info == AP_REQ_REJECT_PATH_INFO
 		&& r->path_info && r->path_info[0]) {
 		PHPAP_INI_OFF;
@@ -587,17 +592,17 @@ zend_first_try {
 		if (!parent_req) {
 			parent_req = ctx->r;
 		}
-		if (parent_req && parent_req->handler && 
-				strcmp(parent_req->handler, PHP_MAGIC_TYPE) && 
-				strcmp(parent_req->handler, PHP_SOURCE_MAGIC_TYPE) && 
+		if (parent_req && parent_req->handler &&
+				strcmp(parent_req->handler, PHP_MAGIC_TYPE) &&
+				strcmp(parent_req->handler, PHP_SOURCE_MAGIC_TYPE) &&
 				strcmp(parent_req->handler, PHP_SCRIPT)) {
 			if (php_apache_request_ctor(r, ctx TSRMLS_CC)!=SUCCESS) {
 				zend_bailout();
 			}
 		}
-		
-		/* 
-		 * check if comming due to ErrorDocument 
+
+		/*
+		 * check if comming due to ErrorDocument
 		 * We make a special exception of 413 (Invalid POST request) as the invalidity of the request occurs
 		 * during processing of the request by PHP during POST processing. Therefor we need to re-use the exiting
 		 * PHP instance to handle the request rather then creating a new one.
diff --git a/sapi/cgi/cgi_main.c b/sapi/cgi/cgi_main.c
index b38a645..e7481a9 100644
--- a/sapi/cgi/cgi_main.c
+++ b/sapi/cgi/cgi_main.c
@@ -21,7 +21,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: cgi_main.c 281870 2009-06-09 13:29:39Z dsp $ */
+/* $Id: cgi_main.c 291497 2009-11-30 14:43:22Z dmitry $ */
 
 #include "php.h"
 #include "php_globals.h"
@@ -1496,8 +1496,9 @@ int main(int argc, char *argv[])
 			   in case some server does something different than above */
 			&& (!CGIG(redirect_status_env) || !getenv(CGIG(redirect_status_env)))
 			) {
-			SG(sapi_headers).http_response_code = 400;
-			PUTS("<b>Security Alert!</b> The PHP CGI cannot be accessed directly.\n\n\
+			zend_try {
+				SG(sapi_headers).http_response_code = 400;
+				PUTS("<b>Security Alert!</b> The PHP CGI cannot be accessed directly.\n\n\
 <p>This PHP CGI binary was compiled with force-cgi-redirect enabled.  This\n\
 means that a page will only be served up if the REDIRECT_STATUS CGI variable is\n\
 set, e.g. via an Apache Action directive.</p>\n\
@@ -1506,7 +1507,8 @@ manual page for CGI security</a>.</p>\n\
 <p>For more information about changing this behaviour or re-enabling this webserver,\n\
 consult the installation file that came with this distribution, or visit \n\
 <a href=\"http://php.net/install.windows\">the manual page</a>.</p>\n");
-
+			} zend_catch {
+			} zend_end_try();
 #if defined(ZTS) && !defined(PHP_DEBUG)
 			/* XXX we're crashing here in msvc6 debug builds at
 			   php_message_handler_for_zend:839 because
@@ -1936,13 +1938,16 @@ consult the installation file that came with this distribution, or visit \n\
 			running from shell (so fp == NULL), then fail.
 		*/
 		if (retval == FAILURE && file_handle.handle.fp == NULL) {
-			if (errno == EACCES) {
-				SG(sapi_headers).http_response_code = 403;
-				PUTS("Access denied.\n");
-			} else {
-				SG(sapi_headers).http_response_code = 404;
-				PUTS("No input file specified.\n");
-			}
+			zend_try {
+				if (errno == EACCES) {
+					SG(sapi_headers).http_response_code = 403;
+					PUTS("Access denied.\n");
+				} else {
+					SG(sapi_headers).http_response_code = 404;
+					PUTS("No input file specified.\n");
+				}
+			} zend_catch {
+			} zend_end_try();
 #if PHP_FASTCGI
 			/* we want to serve more requests if this is fastcgi
 			   so cleanup and continue, request shutdown is
diff --git a/sapi/cli/php.1.in b/sapi/cli/php.1.in
index 68a24f5..1033bb5 100644
--- a/sapi/cli/php.1.in
+++ b/sapi/cli/php.1.in
@@ -69,7 +69,7 @@ specified by \-F to be executed.
 You can access the input line by \fB$argn\fP. While processing the input lines
 .B $argi 
 contains the number of the actual line being processed. Further more
-the paramters \-B and \-E can be used to execute 
+the parameters \-B and \-E can be used to execute 
 .IR code
 (see \-r) before and
 after all input lines have been processed respectively. Notice that the
@@ -304,6 +304,9 @@ Shows information about extension
 .IR name
 Shows configuration for extension
 .B name
+.TP
+.B \-\-ini
+Show configuration file names
 .SH FILES
 .TP 15
 .B php\-cli.ini
@@ -315,7 +318,7 @@ The standard configuration file will only be used when
 cannot be found.
 .SH EXAMPLES
 .TP 5
-\fIphp -r 'echo "Hello World\\n";'\fP
+\fIphp \-r 'echo "Hello World\\n";'\fP
 This command simply writes the text "Hello World" to standard out.
 .TP
 \fIphp \-r 'print_r(gd_info());'\fP
@@ -339,7 +342,7 @@ configuration information. If you then combine those two
 Using this PHP command you can count the lines being input.
 .TP
 \fIphp \-R '@$l+=count(file($argn));' \-E 'echo "Lines:$l\\n";'\fP
-In this example PHP expects each input line beeing a file. It counts all lines 
+In this example PHP expects each input line being a file. It counts all lines 
 of the files specified by each input line and shows the summarized result. 
 You may combine this with tools like find and change the php scriptlet.
 .TP
@@ -372,11 +375,6 @@ For a more or less complete description of PHP look here:
 .B http://www.php.net/manual/
 .PD 1
 .P
-A nice introduction to PHP by Stig Bakken can be found here:
-.PD 0
-.P
-.B http://www.zend.com/zend/art/intro.php
-.PD 1
 .SH BUGS
 You can view the list of known bugs or report any new bug you
 found at:
diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c
index ba767f5..891c551 100644
--- a/sapi/cli/php_cli.c
+++ b/sapi/cli/php_cli.c
@@ -20,7 +20,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: php_cli.c 284649 2009-07-23 14:54:04Z jani $ */
+/* $Id: php_cli.c 292081 2009-12-13 17:06:47Z felipe $ */
 
 #include "php.h"
 #include "php_globals.h"
@@ -76,8 +76,11 @@
 #endif
 
 #if (HAVE_LIBREADLINE || HAVE_LIBEDIT) && !defined(COMPILE_DL_READLINE)
+
+#if HAVE_LIBEDIT
+#include <editline/readline.h>
+#else
 #include <readline/readline.h>
-#if !HAVE_LIBEDIT
 #include <readline/history.h>
 #endif
 #include "php_cli_readline.h"
diff --git a/sapi/cli/php_cli_readline.c b/sapi/cli/php_cli_readline.c
index e6398f2..ca4535a 100644
--- a/sapi/cli/php_cli_readline.c
+++ b/sapi/cli/php_cli_readline.c
@@ -17,7 +17,7 @@
    +----------------------------------------------------------------------+
 */
 
-/* $Id: php_cli_readline.c 272374 2008-12-31 11:17:49Z sebastian $ */
+/* $Id: php_cli_readline.c 292081 2009-12-13 17:06:47Z felipe $ */
 
 #include "php.h"
 
@@ -49,8 +49,10 @@
 #include <unixlib/local.h>
 #endif
 
+#if HAVE_LIBEDIT
+#include <editline/readline.h>
+#else
 #include <readline/readline.h>
-#if !HAVE_LIBEDIT
 #include <readline/history.h>
 #endif
 
diff --git a/tests/classes/interface_constant_inheritance_001.phpt b/tests/classes/interface_constant_inheritance_001.phpt
index ae3e71e..f982a4a 100644
--- a/tests/classes/interface_constant_inheritance_001.phpt
+++ b/tests/classes/interface_constant_inheritance_001.phpt
@@ -14,4 +14,4 @@ echo "Done\n";
 ?>
 --EXPECTF--
 
-Fatal error: Cannot inherit previously-inherited constant FOO from interface I1 in %s on line 6
\ No newline at end of file
+Fatal error: Cannot inherit previously-inherited or override constant FOO from interface I1 in %s on line 6
diff --git a/tests/classes/interface_constant_inheritance_002.phpt b/tests/classes/interface_constant_inheritance_002.phpt
index d5001ba..af4ce69 100644
--- a/tests/classes/interface_constant_inheritance_002.phpt
+++ b/tests/classes/interface_constant_inheritance_002.phpt
@@ -14,4 +14,4 @@ echo "Done\n";
 ?>
 --EXPECTF--
 
-Fatal error: Cannot inherit previously-inherited constant FOO from interface I in %s on line 6
\ No newline at end of file
+Fatal error: Cannot inherit previously-inherited or override constant FOO from interface I in %s on line 6
diff --git a/tests/classes/interface_constant_inheritance_003.phpt b/tests/classes/interface_constant_inheritance_003.phpt
index a3ba815..6b4139b 100644
--- a/tests/classes/interface_constant_inheritance_003.phpt
+++ b/tests/classes/interface_constant_inheritance_003.phpt
@@ -17,4 +17,4 @@ echo "Done\n";
 ?>
 --EXPECTF--
 
-Fatal error: Cannot inherit previously-inherited constant FOO from interface I2 in %s on line 10
+Fatal error: Cannot inherit previously-inherited or override constant FOO from interface I2 in %s on line 10
diff --git a/tests/output/ob_011.phpt b/tests/output/ob_011.phpt
index 7c68dc9..6f9d5ab 100644
--- a/tests/output/ob_011.phpt
+++ b/tests/output/ob_011.phpt
@@ -1,8 +1,7 @@
 --TEST--
 output buffering - fatalism
 --XFAIL--
-This test will fail until the fix in version 1.178 of ext/main/output.c
-is backported from php 6
+This test will fail until the fix in revision r214155 is backported from php 6
 --FILE--
 <?php
 function obh($s)
diff --git a/tests/output/ob_start_basic_unerasable_005.phpt b/tests/output/ob_start_basic_unerasable_005.phpt
index 48d611c..aca4557 100644
--- a/tests/output/ob_start_basic_unerasable_005.phpt
+++ b/tests/output/ob_start_basic_unerasable_005.phpt
@@ -1,5 +1,5 @@
 --TEST--
-ob_start(): Ensure unerasable buffer cannot be flushed by ob_flush().
+ob_start(): Ensure unerasable buffer cannot be flushed by ob_flush()
 --XFAIL--
 On PHP5, ob_flush() DOES clear the buffer. See bug: 46897
 --FILE--
@@ -24,4 +24,4 @@ bool(false)
 string(%d) "Attempt to flush unerasable buffer - should fail... 
 Notice: ob_flush(): failed to flush buffer callback in %s on line 11
 bool(false)
-"
\ No newline at end of file
+"
-- 
1.6.3.3





More information about the Pkg-php-commits mailing list