Index: configure.in
===================================================================
--- configure.in	(revision 26938)
+++ configure.in	(working copy)
@@ -1,7 +1,7 @@
 dnl configure.in: Autoconfiscation for Subversion
 dnl Process this file with autoconf to produce a configure script.
 
-AC_PREREQ(2.50)
+AC_PREREQ(2.58)
 
 dnl Get the version of Subversion, using m4's esyscmd() command to do this
 dnl at m4-time, since AC_INIT() requires it then.
@@ -74,7 +74,7 @@
 NEON_URL="http://www.webdav.org/neon/neon-${NEON_RECOMMENDED_VER}.tar.gz"
 dnl You can skip the neon version check only if you know what you are doing 
 AC_ARG_ENABLE(neon-version-check,
-  AC_HELP_STRING([--disable-neon-version-check],
+  AS_HELP_STRING([--disable-neon-version-check],
 		 [do not check the Neon version]),
   [
     if test "$enableval" = "no" ; then
@@ -137,7 +137,7 @@
 dnl Check for libtool -- we'll definitely need it for all our shared libs!
 echo "configuring libtool now"
 AC_ARG_ENABLE(experimental-libtool,
-  AC_HELP_STRING([--enable-experimental-libtool],[Use APR's libtool]),
+  AS_HELP_STRING([--enable-experimental-libtool],[Use APR's libtool]),
   [experimental_libtool=$enableval],[experimental_libtool=no])
 
 if test "$experimental_libtool" = "yes"; then
@@ -175,7 +175,7 @@
 
 dnl Before configuring libtool check for --enable-all-static option
 AC_ARG_ENABLE(all-static,
-  AC_HELP_STRING([--enable-all-static],
+  AS_HELP_STRING([--enable-all-static],
                  [Build completely static (standalone) binaries.]),
   [
     if test "$enableval" = "yes" ; then
@@ -216,7 +216,7 @@
 dnl Check for trang.
 trang=yes
 AC_ARG_WITH(trang,
-AC_HELP_STRING([--with-trang=PATH],
+AS_HELP_STRING([--with-trang=PATH],
 	       [Specify the command to run the trang schema converter]),
 [
     trang="$withval"
@@ -270,7 +270,7 @@
 dnl Mac OS KeyChain -------------------
 
 AC_ARG_ENABLE(keychain,
-  AC_HELP_STRING([--disable-keychain], 
+  AS_HELP_STRING([--disable-keychain], 
   [Disable use of Mac OS KeyChain for auth credentials]),
   [enable_keychain=$enableval],[enable_keychain=yes])
 
@@ -308,7 +308,7 @@
 dnl I18n -------------------
 
 AC_ARG_ENABLE(nls,
-  AC_HELP_STRING([--disable-nls],[Disable gettext functionality]),
+  AS_HELP_STRING([--disable-nls],[Disable gettext functionality]),
   [enable_nls=$enableval],[enable_nls=yes])
 
 USE_NLS="no"
@@ -434,7 +434,7 @@
 dnl Process some configuration options ----------
 
 AC_ARG_WITH(ssl,
-AC_HELP_STRING([--with-ssl],
+AS_HELP_STRING([--with-ssl],
                [This option does NOT affect the Subversion build process in any
                 way. It enables OpenSSL support in the Neon library. If and
                 only if you are building Neon as an integrated part of the
@@ -445,7 +445,7 @@
 [])
 
 AC_ARG_ENABLE(debug,
-AC_HELP_STRING([--enable-debug],
+AS_HELP_STRING([--enable-debug],
 	       [Turn on debugging]),
 [
     if test "$enableval" = "yes" ; then
@@ -456,7 +456,7 @@
 ])
 
 AC_ARG_ENABLE(maintainer-mode,
-AC_HELP_STRING([--enable-maintainer-mode],
+AS_HELP_STRING([--enable-maintainer-mode],
 	       [Turn on debugging and very strict compile-time warnings]),
 [
     if test "$enableval" = "yes" ; then
@@ -489,7 +489,7 @@
 
 
 AC_ARG_WITH(editor,
-AC_HELP_STRING([--with-editor=PATH],
+AS_HELP_STRING([--with-editor=PATH],
                [Specify a default editor for the subversion client.]),
 [
 
@@ -508,7 +508,7 @@
 
 MOD_ACTIVATION="-a"
 AC_ARG_ENABLE(mod-activation,
-AC_HELP_STRING([--disable-mod-activation],
+AS_HELP_STRING([--disable-mod-activation],
 	       [Do not enable mod_dav_svn in httpd.conf]),
 [
     if test "$enableval" = "no" ; then
@@ -523,7 +523,7 @@
 
 
 AC_ARG_ENABLE(gprof,
-AC_HELP_STRING([--enable-gprof],
+AS_HELP_STRING([--enable-gprof],
 	       [Produce gprof profiling data in 'gmon.out' (GCC only).]),
 [
     if test "$enableval" = "yes" ; then
@@ -600,7 +600,7 @@
 
 dnl decide whether we want to link against the RA libraries
 AC_ARG_ENABLE(dso,
-AC_HELP_STRING([--enable-dso], [Turn on DSO loading of RA libraries]),
+AS_HELP_STRING([--enable-dso], [Turn on DSO loading of RA libraries]),
 [
     if test "$enableval" = "yes"; then
       enable_dso=yes
@@ -678,7 +678,7 @@
 dnl Possibly compile JavaHL
 do_javahl_build=no
 AC_ARG_ENABLE(javahl,
-  AC_HELP_STRING([--enable-javahl],
+  AS_HELP_STRING([--enable-javahl],
              [Enable compilation of Java high-level bindings (requires C++)]),
   [ if test "$enableval" = "yes" ; then
         do_javahl_build="yes"
@@ -729,7 +729,7 @@
 AC_SUBST(LT_CXX_LIBADD)
 
 AC_ARG_WITH(junit,
-AC_HELP_STRING([--with-junit=PATH],
+AS_HELP_STRING([--with-junit=PATH],
                [Specify a path to the junit JAR file.]),
 [
     if test "$withval" = "yes" ; then
Index: build/ac-macros/zlib.m4
===================================================================
--- build/ac-macros/zlib.m4	(revision 26938)
+++ build/ac-macros/zlib.m4	(working copy)
@@ -9,8 +9,8 @@
 [
   zlib_found=no
 
-  AC_ARG_WITH(zlib,AC_HELP_STRING([--with-zlib=PREFIX],
-                                  [zlib compression library]),
+  AC_ARG_WITH(zlib,[AS_HELP_STRING([--with-zlib=PREFIX],
+                                   [zlib compression library])],
   [
     if test "$withval" = "yes" ; then
       AC_MSG_ERROR([--with-zlib requires an argument.])
Index: build/ac-macros/java.m4
===================================================================
--- build/ac-macros/java.m4	(revision 26938)
+++ build/ac-macros/java.m4	(working copy)
@@ -6,10 +6,10 @@
 [
   JAVA_OLDEST_WORKING_VER="$1"
   AC_ARG_WITH(jdk,
-              AC_HELP_STRING([--with-jdk=PATH],
-                             [Try to use 'PATH/include' to find the JNI
-                              headers.  If PATH is not specified, look 
-                              for a Java Development Kit at JAVA_HOME.]),
+              [AS_HELP_STRING([--with-jdk=PATH],
+                              [Try to use 'PATH/include' to find the JNI
+                               headers.  If PATH is not specified, look 
+                               for a Java Development Kit at JAVA_HOME.])],
   [
     case "$withval" in
       "no")
@@ -97,11 +97,11 @@
     dnl Prefer Jikes (for speed) if available.
     jikes_options="/usr/local/bin/jikes /usr/bin/jikes"
     AC_ARG_WITH(jikes,
-                AC_HELP_STRING([--with-jikes=PATH],
-                               [Specify the path to a jikes binary to use
-                                it as your Java compiler.  The default is to
-                                look for jikes (PATH optional).  This behavior
-                                can be switched off by supplying 'no'.]),
+                [AS_HELP_STRING([--with-jikes=PATH],
+                                [Specify the path to a jikes binary to use
+                                 it as your Java compiler.  The default is to
+                                 look for jikes (PATH optional).  This behavior
+                                 can be switched off by supplying 'no'.])],
     [
         if test "$withval" != "no" && test "$withval" != "yes"; then
           dnl Assume a path was provided.
Index: build/ac-macros/sqlite.m4
===================================================================
--- build/ac-macros/sqlite.m4	(revision 26938)
+++ build/ac-macros/sqlite.m4	(working copy)
@@ -29,8 +29,8 @@
   AC_MSG_NOTICE([checking sqlite library])
 
   AC_ARG_WITH(sqlite,
-              AC_HELP_STRING([--with-sqlite=PREFIX],
-                             [Use installed SQLite library.]),
+              [AS_HELP_STRING([--with-sqlite=PREFIX],
+                              [Use installed SQLite library.])],
   [
     if test "$withval" = "yes" ; then
       AC_MSG_ERROR([--with-sqlite requires an argument.])
Index: build/ac-macros/apache.m4
===================================================================
--- build/ac-macros/apache.m4	(revision 26938)
+++ build/ac-macros/apache.m4	(working copy)
@@ -15,7 +15,7 @@
 
 AC_MSG_CHECKING(for static Apache module support)
 AC_ARG_WITH(apache,
-AC_HELP_STRING([--with-apache=DIR],
+AS_HELP_STRING([--with-apache=DIR],
 	       [Build static Apache modules.  DIR is the path to the top-level
 		Apache source directory. IMPORTANT: Unless you are *absolutely*
                 certain that you want to build the modules *statically*, you
@@ -59,8 +59,9 @@
 
 AC_MSG_CHECKING(for Apache module support via DSO through APXS)
 AC_ARG_WITH(apxs,
-[[  --with-apxs[=FILE]      Build shared Apache modules.  FILE is the optional
-                          pathname to the Apache apxs tool; defaults to "apxs".]],
+[AS_HELP_STRING([--with-apxs[=FILE]],
+                [Build shared Apache modules.  FILE is the optional
+                 pathname to the Apache apxs tool; defaults to "apxs".])],
 [
     if test "$BINNAME" != ""; then
       AC_MSG_ERROR(--with-apache and --with-apxs are mutually exclusive)
Index: build/ac-macros/find_apr.m4
===================================================================
--- build/ac-macros/find_apr.m4	(revision 26938)
+++ build/ac-macros/find_apr.m4	(working copy)
@@ -73,8 +73,8 @@
 
   AC_MSG_CHECKING(for APR)
   AC_ARG_WITH(apr,
-  [  --with-apr=PATH         prefix for installed APR, path to APR build tree,
-                          or the full path to apr-config],
+  [AS_HELP_STRING([--with-apr=PATH],
+                  [prefix for installed APR, path to APR build tree, or the full path to apr-config])],
   [
     if test "$withval" = "no" || test "$withval" = "yes"; then
       AC_MSG_ERROR([--with-apr requires a directory or file to be provided])
Index: build/ac-macros/sasl.m4
===================================================================
--- build/ac-macros/sasl.m4	(revision 26938)
+++ build/ac-macros/sasl.m4	(working copy)
@@ -11,17 +11,16 @@
 AC_DEFUN(SVN_LIB_SASL,
 [
   AC_ARG_WITH(sasl, 
-  [
-  --with-sasl=PATH       Compile with libsasl2 in PATH
-  ],
-  [
-    with_sasl="$withval"
-    required="yes"
-  ],
-  [
-    with_sasl="yes"
-    required="no"
-  ])
+    [AS_HELP_STRING([--with-sasl=PATH],
+                    [Compile with libsasl2 in PATH])],
+    [
+      with_sasl="$withval"
+      required="yes"
+    ],
+    [
+      with_sasl="yes"
+      required="no"
+    ])
 
   AC_MSG_CHECKING([whether to look for SASL])
 
Index: build/ac-macros/berkeley-db.m4
===================================================================
--- build/ac-macros/berkeley-db.m4	(revision 26938)
+++ build/ac-macros/berkeley-db.m4	(working copy)
@@ -42,25 +42,25 @@
   dnl      for headers in HEADER and libraries in LIB.
 
   AC_ARG_WITH(berkeley-db,
-  [  --with-berkeley-db=PATH
-                          The Subversion Berkeley DB based filesystem library 
-                          requires Berkeley DB $db_version or newer.  If you
-                          specify `--without-berkeley-db', that library will
-                          not be built.  Otherwise, the configure script builds
-                          that library if and only if APR-UTIL is linked
-                          against a new enough version of Berkeley DB.
+    [AS_HELP_STRING([--with-berkeley-db=PATH],
+                    [The Subversion Berkeley DB based filesystem library 
+                    requires Berkeley DB $db_version or newer.  If you
+                    specify `--without-berkeley-db', that library will
+                    not be built.  Otherwise, the configure script builds
+                    that library if and only if APR-UTIL is linked
+                    against a new enough version of Berkeley DB.
 
-                          If and only if you are building APR-UTIL as part of
-                          the Subversion build process, you may help APR-UTIL
-                          to find the correct Berkeley DB installation by
-                          passing a PATH to this option, to cause APR-UTIL to
-                          look for the Berkeley DB header and library in
-                          `PATH/include' and `PATH/lib'.  If PATH is of the
-                          form `HEADER:LIB', then search for header files in
-                          HEADER, and the library in LIB.  If you omit the
-                          `=PATH' part completely, the configure script will
-                          search for Berkeley DB in a number of standard
-                          places.],
+                    If and only if you are building APR-UTIL as part of
+                    the Subversion build process, you may help APR-UTIL
+                    to find the correct Berkeley DB installation by
+                    passing a PATH to this option, to cause APR-UTIL to
+                    look for the Berkeley DB header and library in
+                   `PATH/include' and `PATH/lib'.  If PATH is of the
+                    form `HEADER:LIB', then search for header files in
+                    HEADER, and the library in LIB.  If you omit the
+                    `=PATH' part completely, the configure script will
+                    search for Berkeley DB in a number of standard
+                    places.])],
   [
     if test "$withval" = "no"; then
       status=skip
@@ -176,8 +176,8 @@
     CPPFLAGS="$SVN_APRUTIL_INCLUDES $CPPFLAGS" 
     LIBS="`$apu_config --ldflags` $svn_apu_bdb_lib $LIBS"
 
-    AC_TRY_RUN(
-      [
+    AC_RUN_IFELSE(
+      [AC_LANG_SOURCE([[
 #include <stdlib.h>
 #define APU_WANT_DB
 #include <apu_want.h>
@@ -211,7 +211,7 @@
   else
     exit (1);
 }
-      ],
+      ]])],
       [svn_have_berkeley_db=yes],
       [svn_have_berkeley_db=no],
       [svn_have_berkeley_db=yes]
Index: build/ac-macros/find_apu.m4
===================================================================
--- build/ac-macros/find_apu.m4	(revision 26938)
+++ build/ac-macros/find_apu.m4	(working copy)
@@ -83,8 +83,8 @@
 
   AC_MSG_CHECKING(for APR-util)
   AC_ARG_WITH(apr-util,
-  [  --with-apr-util=PATH    prefix for installed APU, path to APU build tree,
-                          or the full path to apu-config],
+  [AS_HELP_STRING([--with-apr-util=PATH],
+                  [prefix for installed APU, path to APU build tree, or the full path to apu-config])],
   [
     if test "$withval" = "no" || test "$withval" = "yes"; then
       AC_MSG_ERROR([--with-apr-util requires a directory or file to be provided])
Index: build/ac-macros/svn-macros.m4
===================================================================
--- build/ac-macros/svn-macros.m4	(revision 26938)
+++ build/ac-macros/svn-macros.m4	(working copy)
@@ -32,8 +32,8 @@
 AC_DEFUN([SVN_EXTERNAL_PROJECT_SETUP], [
   do_subdir_config="yes"
   AC_ARG_ENABLE([subdir-config],
-    AC_HELP_STRING([--disable-subdir-config],
-                   [do not reconfigure packages in subdirectories]),
+    [AS_HELP_STRING([--disable-subdir-config],
+                    [do not reconfigure packages in subdirectories])],
     [if test "$enableval" = "no"; then do_subdir_config="no"; fi])
   AC_SUBST([SVN_EXTERNAL_PROJECT_SUBDIRS], [""])
 ])
@@ -139,9 +139,9 @@
   svn_maybe_add_to_cflags_saved_flags="$CFLAGS"
   CFLAGS="$CFLAGS $option"
   AC_MSG_CHECKING([if $CC accepts $option])
-  AC_TRY_COMPILE(
-    [#include <apr_portable.h>],
-    [],
+  AC_COMPILE_IFELSE(
+    [AC_LANG_PROGRAM([[#include <apr_portable.h>]],
+      [[]])],,
     [svn_maybe_add_to_cflags_ok="yes"],
     [svn_maybe_add_to_cflags_ok="no"]
   )
Index: build/ac-macros/swig.m4
===================================================================
--- build/ac-macros/swig.m4	(revision 26938)
+++ build/ac-macros/swig.m4	(working copy)
@@ -8,10 +8,10 @@
 AC_DEFUN(SVN_CHECK_SWIG,
 [
   AC_ARG_WITH(swig,
-              AC_HELP_STRING([--with-swig=PATH],
-                             [Try to use 'PATH/bin/swig' to build the
-                              swig bindings.  If PATH is not specified,
-                              look for a 'swig' binary in your PATH.]),
+              [AS_HELP_STRING([--with-swig=PATH],
+                              [Try to use 'PATH/bin/swig' to build the
+                               swig bindings.  If PATH is not specified,
+                               look for a 'swig' binary in your PATH.])],
   [
     case "$withval" in
       "no")
@@ -204,9 +204,9 @@
       svn_cv_ruby_sitedir="$rbconfig_sitedir"
     ])
     AC_ARG_WITH([ruby-sitedir],
-    AC_HELP_STRING([--with-ruby-sitedir=SITEDIR],
-                               [install Ruby bindings in SITEDIR
-                                (default is same as ruby's one)]),
+      [AS_HELP_STRING([--with-ruby-sitedir=SITEDIR],
+                      [install Ruby bindings in SITEDIR
+                       (default is same as ruby's one)])],
     [svn_ruby_installdir="$withval"],
     [svn_ruby_installdir="$svn_cv_ruby_sitedir"])
 
@@ -231,9 +231,9 @@
       svn_cv_ruby_test_verbose="normal"
     ])
     AC_ARG_WITH([ruby-test-verbose],
-    AC_HELP_STRING([--with-ruby-test-verbose=LEVEL],
-                               [how to use output level for Ruby bindings tests
-                                (default is normal)]),
+      [AS_HELP_STRING([--with-ruby-test-verbose=LEVEL],
+                      [how to use output level for Ruby bindings tests
+                       (default is normal)])],
     [svn_ruby_test_verbose="$withval"],
 		  [svn_ruby_test_verbose="$svn_cv_ruby_test_verbose"])
       SWIG_RB_TEST_VERBOSE="$svn_ruby_test_verbose"
Index: build/ac-macros/neon.m4
===================================================================
--- build/ac-macros/neon.m4	(revision 26938)
+++ build/ac-macros/neon.m4	(working copy)
@@ -29,11 +29,11 @@
   AC_MSG_NOTICE([checking neon library])
 
   AC_ARG_WITH(neon,
-              AC_HELP_STRING([--with-neon=PREFIX], 
-	      [Determine neon library configuration based on 
-	      'PREFIX/bin/neon-config'. Default is to search for neon 
-	      in a subdirectory of the top source directory and then to
-	      look for neon-config in $PATH.]),
+              [AS_HELP_STRING([--with-neon=PREFIX], 
+                              [Determine neon library configuration based on 
+                               'PREFIX/bin/neon-config'. Default is to search for neon 
+                               in a subdirectory of the top source directory and then to
+                               look for neon-config in $PATH.])],
   [
     if test "$withval" = "yes" ; then
       AC_MSG_ERROR([--with-neon requires an argument.])
Index: build/ac-macros/serf.m4
===================================================================
--- build/ac-macros/serf.m4	(revision 26938)
+++ build/ac-macros/serf.m4	(working copy)
@@ -9,8 +9,8 @@
 [
   serf_found=no
 
-  AC_ARG_WITH(serf,AC_HELP_STRING([--with-serf=PREFIX],
-                                  [Serf WebDAV client library]),
+  AC_ARG_WITH(serf,[AS_HELP_STRING([--with-serf=PREFIX],
+                                   [Serf WebDAV client library])],
   [
     if test "$withval" = "yes" ; then
       AC_MSG_ERROR([--with-serf requires an argument.])

