APPROVE COMMIT
This fixes a number of problems that I came across while preparing the
mainline for autoconf 2.59.  It does not include Aidan's most recent recent
change because his patch is not on this branch.
I should have the main patch ready by the end of the weekend.
Malcolm
ChangeLog addition:
2005-03-05  Malcolm Purvis  <malcolmp(a)xemacs.org>
	* config.guess:
	* config.sub: Sync with the latest upstream versions.
	* configure.ac:  Use --verbose for --extra-verbose.   Better
	quoting of arguments.  Internal shell vars statr with '_' to avoid
	name clashes.  Pick up the latest changes to configure.in.
	Improve the testing of Athena 3d widgets.
tests/ChangeLog addition:
2005-03-05  Malcolm Purvis  <malcolmp(a)xemacs.org>
	* autoconf/regressiontest.pl: Added explict test for '--with-athena=3d'
xemacs-xft-bugfixes source patch:
Diff command:   cvs -q diff -u
Files affected: tests/autoconf/regressiontest.pl configure.ac config.sub config.guess
Index: config.guess
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/config.guess,v
retrieving revision 1.6.2.1
diff -u -r1.6.2.1 config.guess
--- config.guess	2005/02/01 15:46:05	1.6.2.1
+++ config.guess	2005/03/04 13:09:07
@@ -1,9 +1,9 @@
 #! /bin/sh
 # Attempt to guess a canonical system name.
 #   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-#   2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
+#   2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
 
-timestamp='2004-11-12'
+timestamp='2005-02-10'
 
 # 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
@@ -53,7 +53,7 @@
 GNU config.guess ($timestamp)
 
 Originally written by Per Bothner.
-Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
2004
+Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
2004, 2005
 Free Software Foundation, Inc.
 
 This is free software; see the source for copying conditions.  There is NO
@@ -804,6 +804,9 @@
     i*:UWIN*:*)
 	echo ${UNAME_MACHINE}-pc-uwin
 	exit 0 ;;
+    amd64:CYGWIN*:*:*)
+	echo x86_64-unknown-cygwin
+	exit 0 ;;
     p*:CYGWIN*:*)
 	echo powerpcle-unknown-cygwin
 	exit 0 ;;
@@ -1196,6 +1199,9 @@
 	exit 0 ;;
     *:QNX:*:4*)
 	echo i386-pc-qnx
+	exit 0 ;;
+    NSE-?:NONSTOP_KERNEL:*:*)
+	echo nse-tandem-nsk${UNAME_RELEASE}
 	exit 0 ;;
     NSR-?:NONSTOP_KERNEL:*:*)
 	echo nsr-tandem-nsk${UNAME_RELEASE}
Index: config.sub
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/config.sub,v
retrieving revision 1.5.20.1
diff -u -r1.5.20.1 config.sub
--- config.sub	2005/02/01 15:46:05	1.5.20.1
+++ config.sub	2005/03/04 13:09:09
@@ -1,9 +1,9 @@
 #! /bin/sh
 # Configuration validation subroutine script.
 #   Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999,
-#   2000, 2001, 2002, 2003, 2004 Free Software Foundation, Inc.
+#   2000, 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc.
 
-timestamp='2004-11-30'
+timestamp='2005-02-10'
 
 # This file is (in principle) common to ALL GNU software.
 # The presence of a machine in this file suggests that SOME GNU software
@@ -70,7 +70,7 @@
 version="\
 GNU config.sub ($timestamp)
 
-Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
2004
+Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
2004, 2005
 Free Software Foundation, Inc.
 
 This is free software; see the source for copying conditions.  There is NO
@@ -237,7 +237,7 @@
 	| h8300 | h8500 | hppa | hppa1.[01] | hppa2.0 | hppa2.0[nw] | hppa64 \
 	| i370 | i860 | i960 | ia64 \
 	| ip2k | iq2000 \
-	| m32r | m32rle | m68000 | m68k | m88k | mcore \
+	| m32r | m32rle | m68000 | m68k | m88k | maxq | mcore \
 	| mips | mipsbe | mipseb | mipsel | mipsle \
 	| mips16 \
 	| mips64 | mips64el \
@@ -310,7 +310,7 @@
 	| ip2k-* | iq2000-* \
 	| m32r-* | m32rle-* \
 	| m68000-* | m680[012346]0-* | m68360-* | m683?2-* | m68k-* \
-	| m88110-* | m88k-* | mcore-* \
+	| m88110-* | m88k-* | maxq-* | mcore-* \
 	| mips-* | mipsbe-* | mipseb-* | mipsel-* | mipsle-* \
 	| mips16-* \
 	| mips64-* | mips64el-* \
Index: configure.ac
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/configure.ac,v
retrieving revision 1.1.14.7
diff -u -r1.1.14.7 configure.ac
--- configure.ac	2005/02/22 10:17:07	1.1.14.7
+++ configure.ac	2005/03/04 13:10:49
@@ -98,32 +98,32 @@
 define([PRINT_VAR],[for var in patsubst([$1],[[
 ]+],[ ]); do eval "echo \"$var = '\$$var'\""; done])
 
-dnl XE_ADD_OBJS(foo.o ...)
+dnl XE_ADD_OBJS(foo.o)
 define([XE_ADD_OBJS],
 [extra_objs="$extra_objs [$1]" && dnl
- if test "$extra_verbose" = "yes"; then
+ if test "$verbose" = "yes"; then
    echo "    xemacs will be linked with \"[$1]\""
  fi])dnl XE_ADD_OBJS
 
 dnl XE_APPEND(value, varname)
 define([XE_APPEND],
 [[$2]="$[$2] [$1]" && dnl
- if test "$extra_verbose" = "yes"; then echo "    Appending
\"[$1]\" to \$[$2]"; fi])
+ if test "$verbose" = "yes"; then echo "    Appending
\"[$1]\" to \$[$2]"; fi])
 
 dnl XE_PREPEND(value, varname)
 define([XE_PREPEND],
 [[$2]="[$1] $[$2]" && dnl
- if test "$extra_verbose" = "yes"; then echo "    Prepending
\"[$1]\" to \$[$2]"; fi])
+ if test "$verbose" = "yes"; then echo "    Prepending
\"[$1]\" to \$[$2]"; fi])
 
 dnl XE_DIE(message)
 define([XE_DIE], [{ echo "Error:" $1 >&2; exit 1; }])
 
 dnl XE_CHECK_FEATURE_DEPENDENCY(feature1, feature2)
 define([XE_CHECK_FEATURE_DEPENDENCY],
-[if test "$with_$1 $with_$2" = "yes no"; then
-  USAGE_ERROR("--with-$1 requires --with-$2")
-elif test "$with_$2" = "no" ; then with_$1=no
-elif test "$with_$1" = "yes"; then with_$2=yes
+[if test "$with_[$1] $with_[$2]" = "yes no"; then
+  USAGE_ERROR("--with-[$1] requires --with-[$2]")
+elif test "$with_[$2]" = "no" ; then with_[$1]=no
+elif test "$with_[$1]" = "yes"; then with_[$2]=yes
 fi
 ])
 
@@ -213,7 +213,7 @@
   if test -n "$runpath"; then
     ld_switch_run="${dash_r}${runpath}"
     XE_PROTECT_LINKER_FLAGS(ld_switch_run)
-    test "$extra_verbose" = "yes" && echo "Setting
runpath to $runpath"
+    test "$verbose" = "yes" && echo "Setting runpath to
$runpath"
   fi
 fi
 ])dnl
@@ -247,16 +247,16 @@
 dnl found then an error is generated.
 dnl
 define([XE_PARSE_KEYWORD_OPTION],
-[[$1]_bogus=yes
+[_[$1]_bogus=yes
  for x in XE_KEYWORD_LIST ; do
    if test $x = $[$1] ; then
-	[$1]_bogus=no
+	_[$1]_bogus=no
    fi
  done
- if test "$[$1]_bogus" = "yes" ; then
+ if test "$_[$1]_bogus" = "yes" ; then
 	USAGE_ERROR(["The [$2] option must have one of these values:
m4_translit(XE_KEYWORD_VALUES,[:],[,])."])
  fi
-unset [$1]_bogus
+unset _[$1]_bogus
 undefine([XE_KEYWORD_LIST])dnl
 undefine([XE_KEYWORD_VALUES])])
 dnl
@@ -316,18 +316,16 @@
 dnl XE_EXPAND_COMPLEX_OPTION(prefix, component, yesno)
 dnl ---------------------------------------------------
 dnl
-dnl #### documented as XE_COMPLEX_OPTION_DEFAULT(prefix, component, yesno)
-dnl #### in Malcolm's version?
 dnl Internal macro create the option's shell variable containing the default
 dnl value and to note the values in an option list.
 dnl
 define([XE_EXPAND_COMPLEX_OPTION],
 [[$1]_[$2]=[$3]
-m4_append([XE_COMPONENT_LIST],[$2],[ ])
+m4_append([XE_COMPONENT_LIST],[$2],[ ])dnl
 dnl Separate with a ':' instead of a ',' (see <prefix>_default
below) to avoid
 dnl confusion with marco parameter lists.
-m4_append([XE_COMPONENT_DEFAULT],[m4_if([$3],no,no)[$2]],[:])
-])
+m4_append([XE_COMPONENT_DEFAULT],[m4_if([$3],no,no)[$2]],[:])dnl
+])dnl
 dnl
 dnl XE_EXPAND_COMPLEX_OPTIONS(prefix, option_list)
 dnl ----------------------------------------------
@@ -338,7 +336,7 @@
 [m4_if([$2], [[]], [],
        [XE_EXPAND_COMPLEX_OPTION([$1], m4_fst($2))[]dnl
 XE_EXPAND_COMPLEX_OPTIONS([$1], m4_cdr($2))])])
-
+dnl
 dnl XE_INIT_COMPLEX_OPTION(prefix, option_list)
 dnl -------------------------------------------
 dnl
@@ -352,8 +350,8 @@
 [[$1]_notfirst=""
 dnl
 XE_EXPAND_COMPLEX_OPTIONS($@)
-[$1]_types="XE_COMPONENT_LIST"
-[$1]_default="m4_translit(XE_COMPONENT_DEFAULT,[:],[,])"
+_[$1]_types="XE_COMPONENT_LIST"
+_[$1]_default="m4_translit(XE_COMPONENT_DEFAULT,[:],[,])"
 dnl Undefine these macros so that they can be reused by later complex
 dnl options.
 undefine([XE_COMPONENT_LIST])
@@ -368,45 +366,45 @@
 dnl
 define([XE_PARSE_COMPLEX_OPTION],
 [for x in `echo "$[$1]" | sed -e 's/,/ /g'` ; do
-    [$1]_all_default=""
-    [$1]_found=""
+    _[$1]_all_default=""
+    _[$1]_found=""
     case "$x" in
-        n | no | non | none ) [$1]_all_default=no ;;
-        a | al | all | both ) [$1]_all_default=yes ;;
+        n | no | non | none ) _[$1]_all_default=no ;;
+        a | al | all | both ) _[$1]_all_default=yes ;;
     esac
 
-    if test -z "$[$1]_all_default"; then
-        for y in $[$1]_types; do
+    if test -z "$_[$1]_all_default"; then
+        for y in $_[$1]_types; do
             dnl echo "testing x='$x' against y='$y'"
             if test "$x" = "$y"; then
 		dnl echo "$x" = "$y"
-                [$1]_found=yes
+                _[$1]_found=yes
                 dnl echo eval `echo "[$1]_$y=yes"`
                 eval "[$1]_$y=yes"
             elif test "$x" = "no$y"; then
                 dnl echo "$x" = "no$y"
-                [$1]_found=yes
+                _[$1]_found=yes
                 dnl echo eval `echo "[$1]_$y=no"`
                 eval "[$1]_$y=no"
             fi
         done
-        test -z "$[$1]_found" && [$1]_bogus=yes
+        test -z "$_[$1]_found" && _[$1]_bogus=yes
     fi
-    if test "$[$1]_bogus" = "yes" -o \
-         \( -n "$[$1]_all_default" -a -n "$[$1]_notfirst" \) ; then
+    if test "$_[$1]_bogus" = "yes" -o \
+         \( -n "$_[$1]_all_default" -a -n "$_[$1]_notfirst" \) ;
then
 	USAGE_ERROR(["Valid values for the [$2] option are:
-$[$1]_types.  With prefix \"no\", switch it off.
+$_[$1]_types.  With prefix \"no\", switch it off.
 Defaults may be overridden with \`all' or \`none' first in the list.
-Hardcoded default is: $[$1]_default."])
-    elif test -n "$[$1]_all_default" ; then
-        for y in $[$1]_types; do
-	    eval "[$1]_$y=$[$1]_all_default"
+Hardcoded default is: $_[$1]_default."])
+    elif test -n "$_[$1]_all_default" ; then
+        for y in $_[$1]_types; do
+	    eval "[$1]_$y=$_[$1]_all_default"
         done
     fi
-    [$1]_notfirst=yes
+    _[$1]_notfirst=yes
 done
-unset [$1]_bogus [$1]_found [$1]_notfirst [$1]_types
-unset [$1]_default [$1]_all_default x y
+unset _[$1]_bogus _[$1]_found _[$1]_notfirst _[$1]_types
+unset _[$1]_default _[$1]_all_default x y
 ])
 
 dnl XE_COMPLEX_OPTION(option, yesno)
@@ -416,7 +414,7 @@
 dnl yes or no or "" (which means maybe).
 dnl
 define([XE_COMPLEX_OPTION],[[$1,$2]])
-
+dnl
 dnl XE_COMPLEX_OPTION_HELP_STRING(flag, long, short, components, libraries)
 dnl -----------------------------------------------------------------------
 dnl Boilerplate help string for complex options.
@@ -426,7 +424,7 @@
 [AC_HELP_STRING([$1],[Compile with support for $2. Components that can use
 $3 are $4. Prefix component with `no' to disable its use of $3. Requires
 $5 support. Default is $6.])])
-
+dnl
 dnl XE_COMPLEX_ARG_WITH(PACKAGE, HELP-STRING, ACTION-IF-TRUE, ACTION-IF-FALSE,
 dnl                     [XE_COMPLEX_OPTION(a,yes), ....])
 dnl --------------------------------------------------------------------------
@@ -440,7 +438,7 @@
 [XE_PARSE_COMPLEX_OPTION([with_]patsubst([$1], -, _), [--with-$1])
 $3
 ],[$4])])
-
+dnl
 dnl XE_COMPLEX_ARG_ENABLE(FEATURE, HELP-STRING, ACTION-IF-TRUE, ACTION-IF-FALSE,
 dnl                     [XE_COMPLEX_OPTION, ....])
 dnl --------------------------------------------------------------------------
@@ -463,7 +461,7 @@
 dnl Command line argument processing.
 dnl Note that AC_HELP_STRING compresses whitespace, wraps, and indents the
 dnl string to fit the --help display; there's no need to preformat.
-
+dnl
 dnl Error-checking on old-style flags
 AC_ARG_WITH([mule],[],[XE_DIE([--enable-mule, NOT --with-mule])],[])
 AC_ARG_WITH([menubars],[],[XE_DIE([--enable-menubars, NOT --with-menubars])],[])
@@ -1047,7 +1045,7 @@
 . "$srcdir/version.sh" || exit 1;
 dnl Must do the following first to determine verbosity for AC_DEFINE
 if test -n "$emacs_is_beta"; then beta=yes; else beta=no; fi
-: "${extra_verbose=$beta}"
+: "${verbose=$beta}"
 version="${emacs_major_version}.${emacs_minor_version}"
 AC_DEFINE_UNQUOTED(EMACS_MAJOR_VERSION, $emacs_major_version)
 AC_DEFINE_UNQUOTED(EMACS_MINOR_VERSION, $emacs_minor_version)
@@ -1097,15 +1095,15 @@
 dnl Error checking default to "yes" in beta versions, to "no" in
releases.
 dnl Same goes for --enable-debug and --extra-verbosity.
 if test -n "$emacs_is_beta"; then beta=yes; else beta=no; fi
-test "${enable_error_checking_extents=$beta}"    = yes &&
AC_DEFINE(ERROR_CHECK_EXTENTS)
-test "${enable_error_checking_types=$beta}"      = yes &&
AC_DEFINE(ERROR_CHECK_TYPES)
-test "${enable_error_checking_text=$beta}"       = yes &&
AC_DEFINE(ERROR_CHECK_TEXT)
-test "${enable_error_checking_gc=$beta}"         = yes &&
AC_DEFINE(ERROR_CHECK_GC)
-test "${enable_error_checking_malloc=$beta}"     = yes &&
AC_DEFINE(ERROR_CHECK_MALLOC)
-test "${enable_error_checking_byte_code=$beta}"  = yes &&
AC_DEFINE(ERROR_CHECK_BYTE_CODE)
-test "${enable_error_checking_glyphs=$beta}"     = yes &&
AC_DEFINE(ERROR_CHECK_GLYPHS)
-test "${enable_error_checking_display=$beta}"    = yes &&
AC_DEFINE(ERROR_CHECK_DISPLAY)
-test "${enable_error_checking_structures=$beta}" = yes &&
AC_DEFINE(ERROR_CHECK_STRUCTURES)
+test "${enable_error_checking_extents:=$beta}"    = yes &&
AC_DEFINE(ERROR_CHECK_EXTENTS)
+test "${enable_error_checking_types:=$beta}"      = yes &&
AC_DEFINE(ERROR_CHECK_TYPES)
+test "${enable_error_checking_text:=$beta}"       = yes &&
AC_DEFINE(ERROR_CHECK_TEXT)
+test "${enable_error_checking_gc:=$beta}"         = yes &&
AC_DEFINE(ERROR_CHECK_GC)
+test "${enable_error_checking_malloc:=$beta}"     = yes &&
AC_DEFINE(ERROR_CHECK_MALLOC)
+test "${enable_error_checking_byte_code:=$beta}"  = yes &&
AC_DEFINE(ERROR_CHECK_BYTE_CODE)
+test "${enable_error_checking_glyphs:=$beta}"     = yes &&
AC_DEFINE(ERROR_CHECK_GLYPHS)
+test "${enable_error_checking_display:=$beta}"    = yes &&
AC_DEFINE(ERROR_CHECK_DISPLAY)
+test "${enable_error_checking_structures:=$beta}" = yes &&
AC_DEFINE(ERROR_CHECK_STRUCTURES)
 dnl enable_debug=yes must be set when error checking is present.  This should be
 dnl fixed up.
 dnl enable_debug implies other options
@@ -2014,7 +2012,7 @@
 fi
 
 dnl For debugging...
-dnl test "$extra_verbose" = "yes" && \
+test "$verbose" = "yes" && \
   PRINT_VAR(libs_machine libs_system libs_termcap libs_standard
   objects_machine objects_system c_switch_machine c_switch_system
   ld_switch_machine ld_switch_system unexec ld_switch_shared
@@ -2441,6 +2439,7 @@
 if test -z "$compiler_version"; then
   compiler_version="detection failed (please report this)"
 fi
+AC_MSG_RESULT([$compiler_version])
 
 AC_MSG_CHECKING(for standard C library version information)
 
@@ -2487,6 +2486,7 @@
 if test -z "libc_version"; then
   libc_version="detection failed (please report this)"
 fi
+AC_MSG_RESULT([$libc_version])
 
 dnl ---------------------------------------------------------------
 dnl Add site and system specific flags to compile and link commands
@@ -2841,7 +2841,7 @@
 AC_CHECK_FUNCS(mkstemp)
 
 dnl Determine type of mail locking from configure args and s&m headers
-AC_CHECKING(type of mail spool file locking)
+AC_CHECKING([type of mail spool file locking])
 AC_CHECK_FUNCS(lockf flock)
 dnl The mail_use_xxx variables are set according to the s&m headers.
 test -z "$with_mail_locking" -a "$mail_use_flock" = "yes"
&& with_mail_locking=flock
@@ -2904,7 +2904,7 @@
 dnl Choose a window system
 dnl ----------------------
 
-AC_CHECKING("for specified window system")
+AC_CHECKING([for specified window system])
 
 dnl Autodetection of Gdk libraries and includes
 dnl -------------------------------------------
@@ -3138,7 +3138,7 @@
 
   XE_COMPUTE_RUNPATH()
 
-  if test "$extra_verbose" = "yes"; then
+  if test "$verbose" = "yes"; then
     echo; echo "X11 compilation variables:"
     PRINT_VAR(x_libraries x_includes X_CFLAGS X_LIBS X_PRE_LIBS X_EXTRA_LIBS)
     echo
@@ -3164,7 +3164,7 @@
   test ! -z "$bitmapdirs" && AC_DEFINE_UNQUOTED(BITMAPDIR,
"$bitmapdirs")
 
   dnl Autodetect defines extracted from X config by xmkmf, e.g. NARROWPROTO
-  AC_CHECKING(for X defines extracted by xmkmf)
+  AC_CHECKING([for X defines extracted by xmkmf])
   rm -fr conftestdir
   if mkdir conftestdir; then
     cd conftestdir
@@ -3212,7 +3212,7 @@
       -b i486-linuxaout)
   fi
   libs_x="-lX11"
-  test "$extra_verbose" = "yes" && echo "    Setting
libs_x to \"-lX11\""
+  test "$verbose" = "yes" && echo "    Setting libs_x to
\"-lX11\""
 
   dnl Autodetect -lXext
   AC_CHECK_LIB(Xext, XShapeSelectInput, XE_PREPEND(-lXext, libs_x))
@@ -3237,7 +3237,7 @@
 
   AC_CHECK_FUNCS(XConvertCase)
 
-  AC_CHECK_HEADERS(X11/Xlocale.h)
+  AC_CHECK_HEADERS(X11/Xlocale.h X11/Xfuncproto.h)
 
   dnl XFree86 has a non-standard prototype for this X11R6 function
   AC_CHECK_FUNCS(XRegisterIMInstantiateCallback)
@@ -3328,7 +3328,7 @@
 fi dnl $with_x11 = yes
 
 if test "$with_msw" != "no"; then
-  AC_CHECKING(for MS-Windows)
+  AC_CHECKING([for MS-Windows])
   AC_CHECK_LIB(gdi32,main,with_msw=yes)
   if test "$with_msw" = "yes"; then
     AC_DEFINE(HAVE_MS_WINDOWS)
@@ -3402,7 +3402,7 @@
   dnl fi
   for feature in with_tooltalk with_cde with_offix with_wmcommand with_xim with_xmu
enable_sound_nas
   do
-    if eval "test -n \"\${feature}\" -a \"\${feature}\" !=
no" ; then
+    if eval "test -n \"\$${feature}\" -a \"\$${feature}\" !=
\"no\"" ; then
        AC_MSG_WARN([--$feature ignored:  Not valid without X support])
     fi
     eval "${feature}=no"
@@ -3437,7 +3437,7 @@
 esac
 
 dnl Enable or disable proper handling of WM_COMMAND
-AC_CHECKING(for WM_COMMAND option);
+AC_CHECKING([for WM_COMMAND option])
 dnl if test "$with_wmcommand" = "yes"; then
 if test "$with_wmcommand" != "no"; then
   AC_DEFINE(HAVE_WMCOMMAND)
@@ -3473,7 +3473,7 @@
 
 dnl This must come before the detection code for anything that is in a module
 if test "$enable_modules" != "no"; then
-  AC_CHECKING(for module support)
+  AC_CHECKING([for module support])
 
   case "$opsys" in
     mingw* | cygwin* ) have_dl=yes ;;
@@ -3677,7 +3677,7 @@
 fi
 
 dnl Autodetect LDAP
-AC_CHECKING(for LDAP)
+AC_CHECKING([for LDAP])
 ldap_libs=
 test -z "$with_ldap" && { AC_CHECK_HEADER(ldap.h, ,with_ldap=no) }
 test -z "$with_ldap" && { AC_CHECK_HEADER(lber.h, ,with_ldap=no) }
@@ -3727,7 +3727,7 @@
 dnl that prefix must be specified using the --with-site-prefixes flag.
 postgresql_libs=
 if test "$with_postgresql" != "no"; then
-  AC_CHECKING(for PostgreSQL)
+  AC_CHECKING([for PostgreSQL])
 
 dnl Look for these standard header file locations, known to be used on Linux
   for header_dir in "" "pgsql/" "postgresql/"; do
@@ -3948,7 +3948,7 @@
 dnl ----------------------
 
 if test "$with_x11" = "yes"; then
-  AC_CHECKING(for X11 graphics libraries)
+  AC_CHECKING([for X11 graphics libraries])
 fi
 
 dnl We don't automatically trigger widgets if athena is present
@@ -3960,7 +3960,7 @@
 esac
 
 if test "$with_x11" = "yes" -a "$detect_athena" =
"yes" ; then
-  AC_CHECKING(for the Athena widgets)
+  AC_CHECKING([for the Athena widgets])
 
   dnl What in heck did the user actually want?
   case "$with_athena" in
@@ -4008,13 +4008,23 @@
     dnl Curse this `Lets replace standard libraries' thing that they did. :/
     AC_CHECK_HEADER(X11/$athena_variant/XawInit.h,
       [AC_CHECK_HEADER(X11/$athena_variant/ThreeD.h,
-        [athena_h_path=X11/$athena_variant])])
+        [athena_h_path=X11/$athena_variant])],[],
+[
+#if HAVE_X11_XFUNCPROTO_H
+#include <X11/Xfuncproto.h>
+#endif
+])
 
     dnl Is the variant specific header directory directly under include?
     if test -z "$athena_h_path"; then
       AC_CHECK_HEADER($athena_variant/XawInit.h,
         [AC_CHECK_HEADER($athena_variant/ThreeD.h,
-          athena_h_path=$athena_variant)])
+          athena_h_path=$athena_variant)],[],
+[
+#if HAVE_X11_XFUNCPROTO_H
+#include <X11/Xfuncproto.h>
+#endif
+])
     fi
 
     dnl If we couldn't find the specific variant, try the generic Athena 3d headers
@@ -4024,7 +4034,12 @@
           [
             AC_MSG_WARN([Assuming that X11/Xaw3d headers are suitable for
$athena_variant.])
             athena_h_path=X11/Xaw3d
-          ])])
+          ])],[],
+[
+#if HAVE_X11_XFUNCPROTO_H
+#include <X11/Xfuncproto.h>
+#endif
+])
     fi
 
     dnl Also generic 3d headers directly under include dir
@@ -4034,7 +4049,12 @@
           [
             AC_MSG_WARN([Assuming that Xaw3d headers are suitable for $athena_variant.])
             athena_h_path=Xaw3d
-          ])])
+          ])],[],
+[
+#if HAVE_X11_XFUNCPROTO_H
+#include <X11/Xfuncproto.h>
+#endif
+])
     fi
 
     dnl If nothing yet found, see if Xaw is a 3d header set...
@@ -4242,19 +4262,19 @@
 fi
 
 if test "$enable_mule" = "yes" ; then
-  AC_CHECKING(for Mule-related features)
+  AC_CHECKING([for Mule-related features])
   AC_DEFINE(MULE)
 
   dnl Use -lintl to get internationalized strerror for Mule
   AC_CHECK_HEADERS(libintl.h)
   AC_CHECK_LIB(intl, strerror)
 
-  AC_CHECKING(for Mule input methods)
+  AC_CHECKING([for Mule input methods])
   dnl Do we have the XmIm* routines?  And if so, do we want to use them?
   dnl XIM seems to be flaky except on Solaris...
   dnl test -z "$with_xim" -a "$opsys" != "sol2" &&
with_xim=no
   case "$with_xim" in "" | "yes" )
-    AC_CHECKING(for XIM)
+    AC_CHECKING([for XIM])
     AC_CHECK_LIB(X11, XOpenIM, with_xim=xlib, with_xim=no)
     dnl XIM + Lesstif is not (yet?) usable
     if test "$have_motif $have_lesstif" = "yes no"; then
@@ -4279,7 +4299,7 @@
 
   dnl "with_xfs" = "yes"
   if test "$with_xfs" = "yes" ; then
-    AC_CHECKING(for XFontSet)
+    AC_CHECKING([for XFontSet])
     AC_CHECK_LIB(X11, XmbDrawString, [:], with_xfs=no)
     if test "$with_xfs" = "yes" && test
"$enable_menubars" = "lucid"; then
       AC_DEFINE(USE_XFONTSET)
@@ -4737,7 +4757,7 @@
 dnl Check for sound of various sorts.
 
 dnl Autodetect native sound
-AC_CHECKING("for sound support")
+AC_CHECKING([for sound support])
 test -n "$with_native_sound_lib" && enable_sound_native=yes
 
 if test "$enable_sound_native" != "no"; then
@@ -4901,7 +4921,7 @@
 test -z "$with_tty" && with_tty=yes
 
 if test "$with_tty" = "yes"  ; then
-  AC_CHECKING(for TTY-related features)
+  AC_CHECKING([for TTY-related features])
   AC_DEFINE(HAVE_TTY)
 
   dnl Autodetect ncurses.
@@ -4986,7 +5006,7 @@
 dnl By default, we check for DBM support in libgdbm, then libc, then libdbm.
 
 test "$enable_database_gdbm $enable_database_dbm $enable_database_berkdb" \
-  != "no no no" && AC_CHECKING(for database support)
+  != "no no no" && AC_CHECKING([for database support])
 
 dnl Check for ndbm.h, required for either kind of DBM support.
 if test "$enable_database_gdbm $enable_database_dbm" != "no no";
then
@@ -5241,7 +5261,7 @@
   done
 fi
 
-if test "$extra_verbose" = "yes"; then
+if test "$verbose" = "yes"; then
   echo ""
   PRINT_VAR(extra_objs
    c_switch_general  c_switch_window_system  c_switch_all
@@ -5256,26 +5276,26 @@
 
 dnl Create a .gdbinit useful for debugging XEmacs
 if test -f "$srcdir/src/.gdbinit" -a ! -f "src/.gdbinit"; then
-  test "$extra_verbose" = "yes" && echo "creating
src/.gdbinit"
+  test "$verbose" = "yes" && echo "creating
src/.gdbinit"
   echo "source $srcdir/src/.gdbinit" > "src/.gdbinit"
 fi
 
 dnl Create a .dbxrc useful for debugging XEmacs
 if test -f "$srcdir/src/.dbxrc" -a ! -f "src/.dbxrc"; then
-  test "$extra_verbose" = "yes" && echo "creating
src/.dbxrc"
+  test "$verbose" = "yes" && echo "creating
src/.dbxrc"
   echo ". $srcdir/src/.dbxrc" > "src/.dbxrc"
 fi
 
 dnl Create a useful TAGS file
 if test -f "$srcdir/TAGS" -a ! -f "TAGS"; then
-  test "$extra_verbose" = "yes" && echo "creating
TAGS"
+  test "$verbose" = "yes" && echo "creating TAGS"
   echo "
 $srcdir/TAGS,include" > "TAGS"
 fi
 
 dnl Create top level .sbinit for Sun compilers
 if test "$__SUNPRO_C" = "yes"; then
-  test "$extra_verbose" = "yes" && echo "creating
.sbinit"
+  test "$verbose" = "yes" && echo "creating
.sbinit"
   ( echo "# For use with Sun WorkShop's Source browser."
     echo "# See sbquery(1) and sbinit(4) for more information"
     for dir in $MAKE_SUBDIR; do echo "import $dir"; done
@@ -5567,6 +5587,12 @@
 
 XEmacs ${emacs_major_version}.${emacs_minor_version}${xemacs_betaname}
\"$xemacs_codename\" $xemacs_extra_name configured for \`$ac_cv_build'.
 "
+echo "  WARNING:
--------------------------------------------------------------"
+echo "  WARNING: This was produced from a new autoconf-2.5 based
configuration."
+echo "  WARNING: If this configuration seems buggy then copy
etc/configure-21.3"
+echo "  WARNING: to configure and try again.  Also please report the bug."
+echo "  WARNING:
--------------------------------------------------------------"
+
 echo "
 Compilation Environment and Installation Defaults:"
 echo "  Source code location:              $srcdir"
Index: tests/autoconf/regressiontest.pl
===================================================================
RCS file: /pack/xemacscvs/XEmacs/xemacs/tests/autoconf/Attic/regressiontest.pl,v
retrieving revision 1.1.2.1
diff -u -r1.1.2.1 regressiontest.pl
--- tests/autoconf/regressiontest.pl	2005/02/01 15:47:15	1.1.2.1
+++ tests/autoconf/regressiontest.pl	2005/03/04 13:10:56
@@ -82,6 +82,7 @@
    "--infodir=/tmp/foo" => undef,
    "--libdir=/tmp/foo" => undef,
    "--exec-prefix=/tmp/foo" => undef,
+   "--with-athena=3d" => undef,
    "--with-mule --with-xft=emacs --debug --error-checking=all --with-xim=xlib
--with-widgets=athena --with-athena=3d --with-dialogs=athena --memory-usage-stats
--use-number-lib=gmp --site-prefixes=/opt/local:/sw --with-ldap=no --use-union-type"
=> "--enable-mule --with-xft=emacs --enable-debug --enable-error-checking=all
--with-xim=xlib --enable-widgets=athena --with-athena=3d --enable-dialogs=athena
--enable-memory-usage-stats --enable-bignum=gmp --with-site-prefixes=/opt/local:/sw
--with-ldap=no --enable-union-type"
   );
 
-- 
		     Malcolm Purvis <malcolmp(a)xemacs.org>