changeset 377:d883f39b8495 r21-2b4

Import from CVS: tag r21-2b4
author cvs
date Mon, 13 Aug 2007 11:05:42 +0200
parents e2295b4d9f2e
children d39c528a738d
files CHANGES-beta ChangeLog configure configure.in etc/NEWS etc/package-index.LATEST.pgp lib-src/ChangeLog lib-src/Makefile.in.in lib-src/movemail.c lisp/ChangeLog lisp/about.el lisp/auto-autoloads.el lisp/cus-face.el lisp/custom-load.el lisp/easymenu.el lisp/etags.el lisp/faces.el lisp/isearch-mode.el lisp/menubar-items.el lisp/menubar.el lisp/msw-faces.el lisp/package-get.el lisp/package-ui.el lisp/process.el lisp/subr.el lisp/wid-edit.el man/ChangeLog man/internals/internals.texi man/lispref/text.texi nt/ChangeLog nt/xemacs.mak src/ChangeLog src/chartab.c src/chartab.h src/config.h.in src/dgif_lib.c src/dired.c src/editfns.c src/emacs.c src/fileio.c src/fns.c src/frame-msw.c src/gifrlib.h src/glyphs-msw.c src/gui.c src/gui.h src/input-method-motif.c src/input-method-xfs.c src/input-method-xlib.c src/insdel.c src/linuxplay.c src/lisp.h src/m/arm.h src/m/mips-nec.h src/menubar-x.c src/menubar.c src/mule-charset.c src/process-unix.c src/s/cygwin32.h version.sh
diffstat 60 files changed, 5124 insertions(+), 1164 deletions(-) [+]
line wrap: on
line diff
--- a/CHANGES-beta	Mon Aug 13 11:04:53 2007 +0200
+++ b/CHANGES-beta	Mon Aug 13 11:05:42 2007 +0200
@@ -1,4 +1,14 @@
 							-*- indented-text -*-
+to 21.2 beta4 "Aglaophonos"
+-- isearch keymap fix from Katsumi Yamaoka
+-- directory_files cleanup from Hrvoje Niksic
+-- C implementation of base64 from Hrvoje Niksic
+-- C implementation of `buffer-substring-no-properties' from Hrvoje Niksic
+-- Experimental fix for spurious `file has changed on disk' message from
+   Charles Waldman
+-- Fix for etags.el hook calling from Malcolm Box
+-- User-name-completion fix for MS Windows NT from Greg Klanderman
+
 to 21.2 beta3 "Aglaia"
 -- case sensitiveness improvements from Didier Verna
 -- Bug fixes from 21.0
--- a/ChangeLog	Mon Aug 13 11:04:53 2007 +0200
+++ b/ChangeLog	Mon Aug 13 11:05:42 2007 +0200
@@ -1,3 +1,28 @@
+1998-11-28  SL Baur  <steve@altair.xemacs.org>
+
+	* XEmacs 21.2-beta4 is released.
+
+1998-11-27  SL Baur  <steve@altair.xemacs.org>
+
+	* configure.in: Linux/Arm Support.
+	From James LewisMoss <dres@ioa.com>
+
+1998-11-27  Takeshi Hagiwara  <hagiwara@ie.niigata-u.ac.jp>
+
+	* configure.in:
+	Fix the realpath() problem of UnixWare2.1.3.
+	Patches for NEC's sysv4.2 machine.
+
+1998-11-09  Kazuyuki IENAGA  <ienaga@jsys.co.jp>
+
+	* configure.in: Check if there's wnn4.2 or wnn6 specific library
+	installed. The Wnn library will be checked if the --with-wnn
+	and/or --with-wnn6 was specified compulsory.
+
+1998-07-28  Jan Vroonhof  <vroonhof@math.ethz.ch>
+
+	* configure.in (CPP): Too many spaces im run-patch flag detection.
+
 1998-10-15  SL Baur  <steve@altair.xemacs.org>
 
 	* XEmacs 21.2-beta3 is released.
--- a/configure	Mon Aug 13 11:04:53 2007 +0200
+++ b/configure	Mon Aug 13 11:05:42 2007 +0200
@@ -1242,6 +1242,12 @@
     NON_GNU_CPP=/usr/ccs/lib/cpp
   ;;
 
+    mips-nec-sysv*)
+    machine=mips-nec
+    NON_GNU_CC=/usr/ccs/bin/cc
+    NON_GNU_CPP=/usr/ccs/lib/cpp
+  ;;
+
       m68*-sgi-iris3.5* ) machine=irist opsys=iris3-5 ;;
   m68*-sgi-iris3.6* | m68*-sgi-iris*) machine=irist opsys=iris3-6 ;;
     mips-sgi-irix3.*    ) opsys=irix3-3 ;;
@@ -1371,6 +1377,8 @@
 
     m68k-*-linux* ) machine=m68k opsys=linux ;;
 
+    arm-*-linux* ) machine=arm opsys=linux ;;
+
 esac
 
 if test -z "$machine" -o -z "$opsys"; then
@@ -1469,7 +1477,7 @@
 # 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:1473: checking for $ac_word" >&5
+echo "configure:1481: checking for $ac_word" >&5
 
 if test -n "$CC"; then
   ac_cv_prog_CC="$CC" # Let the user override the test.
@@ -1495,7 +1503,7 @@
   # 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:1499: checking for $ac_word" >&5
+echo "configure:1507: checking for $ac_word" >&5
 
 if test -n "$CC"; then
   ac_cv_prog_CC="$CC" # Let the user override the test.
@@ -1540,7 +1548,7 @@
 fi
 
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1544: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1552: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
 
 ac_ext=c
 xe_cppflags='$CPPFLAGS $c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS'
@@ -1552,11 +1560,11 @@
 cross_compiling=no
 
 cat > conftest.$ac_ext <<EOF
-#line 1556 "configure"
+#line 1564 "configure"
 #include "confdefs.h"
 main(){return(0);}
 EOF
-if { (eval echo configure:1560: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:1568: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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
@@ -1576,19 +1584,19 @@
   { 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:1580: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1588: 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:1585: checking whether we are using GNU C" >&5
+echo "configure:1593: checking whether we are using GNU C" >&5
 
 cat > conftest.c <<EOF
 #ifdef __GNUC__
   yes;
 #endif
 EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1592: \"$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:1600: \"$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
@@ -1602,7 +1610,7 @@
   ac_save_CFLAGS="$CFLAGS"
   CFLAGS=
   echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1606: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1614: checking whether ${CC-cc} accepts -g" >&5
 
 echo 'void f(){}' > conftest.c
 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
@@ -1631,7 +1639,7 @@
   # 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:1635: checking for $ac_word" >&5
+echo "configure:1643: checking for $ac_word" >&5
 
 if test -n "$CC"; then
   ac_cv_prog_CC="$CC" # Let the user override the test.
@@ -1657,7 +1665,7 @@
   # 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:1661: checking for $ac_word" >&5
+echo "configure:1669: checking for $ac_word" >&5
 
 if test -n "$CC"; then
   ac_cv_prog_CC="$CC" # Let the user override the test.
@@ -1702,7 +1710,7 @@
 fi
 
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1706: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1714: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
 
 ac_ext=c
 xe_cppflags='$CPPFLAGS $c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS'
@@ -1714,11 +1722,11 @@
 cross_compiling=no
 
 cat > conftest.$ac_ext <<EOF
-#line 1718 "configure"
+#line 1726 "configure"
 #include "confdefs.h"
 main(){return(0);}
 EOF
-if { (eval echo configure:1722: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:1730: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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
@@ -1738,19 +1746,19 @@
   { 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:1742: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1750: 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:1747: checking whether we are using GNU C" >&5
+echo "configure:1755: checking whether we are using GNU C" >&5
 
 cat > conftest.c <<EOF
 #ifdef __GNUC__
   yes;
 #endif
 EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1754: \"$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:1762: \"$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
@@ -1764,7 +1772,7 @@
   ac_save_CFLAGS="$CFLAGS"
   CFLAGS=
   echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1768: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1776: checking whether ${CC-cc} accepts -g" >&5
 
 echo 'void f(){}' > conftest.c
 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
@@ -1793,7 +1801,7 @@
   # 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:1797: checking for $ac_word" >&5
+echo "configure:1805: checking for $ac_word" >&5
 
 if test -n "$CC"; then
   ac_cv_prog_CC="$CC" # Let the user override the test.
@@ -1819,7 +1827,7 @@
   # 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:1823: checking for $ac_word" >&5
+echo "configure:1831: checking for $ac_word" >&5
 
 if test -n "$CC"; then
   ac_cv_prog_CC="$CC" # Let the user override the test.
@@ -1864,7 +1872,7 @@
 fi
 
 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1868: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1876: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
 
 ac_ext=c
 xe_cppflags='$CPPFLAGS $c_switch_site $c_switch_machine $c_switch_system $c_switch_x_site $X_CFLAGS'
@@ -1876,11 +1884,11 @@
 cross_compiling=no
 
 cat > conftest.$ac_ext <<EOF
-#line 1880 "configure"
+#line 1888 "configure"
 #include "confdefs.h"
 main(){return(0);}
 EOF
-if { (eval echo configure:1884: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:1892: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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
@@ -1900,19 +1908,19 @@
   { 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:1904: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1912: 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:1909: checking whether we are using GNU C" >&5
+echo "configure:1917: checking whether we are using GNU C" >&5
 
 cat > conftest.c <<EOF
 #ifdef __GNUC__
   yes;
 #endif
 EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1916: \"$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:1924: \"$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
@@ -1926,7 +1934,7 @@
   ac_save_CFLAGS="$CFLAGS"
   CFLAGS=
   echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1930: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1938: checking whether ${CC-cc} accepts -g" >&5
 
 echo 'void f(){}' > conftest.c
 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
@@ -1959,7 +1967,7 @@
 test -n "$NON_GNU_CPP" -a "$GCC" != "yes" -a -z "$CPP" && CPP="$NON_GNU_CPP"
 
 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:1963: checking how to run the C preprocessor" >&5
+echo "configure:1971: checking how to run the C preprocessor" >&5
 # On Suns, sometimes $CPP names a directory.
 if test -n "$CPP" && test -d "$CPP"; then
   CPP=
@@ -1972,13 +1980,13 @@
   # On the NeXT, cc -E runs the code through the compiler's parser,
   # not just through cpp.
   cat > conftest.$ac_ext <<EOF
-#line 1976 "configure"
+#line 1984 "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:1982: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:1990: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   :
@@ -1989,13 +1997,13 @@
   rm -rf conftest*
   CPP="${CC-cc} -E -traditional-cpp"
   cat > conftest.$ac_ext <<EOF
-#line 1993 "configure"
+#line 2001 "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:1999: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2007: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   :
@@ -2018,9 +2026,9 @@
 
 
 echo $ac_n "checking for AIX""... $ac_c" 1>&6
-echo "configure:2022: checking for AIX" >&5
-cat > conftest.$ac_ext <<EOF
-#line 2024 "configure"
+echo "configure:2030: checking for AIX" >&5
+cat > conftest.$ac_ext <<EOF
+#line 2032 "configure"
 #include "confdefs.h"
 #ifdef _AIX
   yes
@@ -2047,9 +2055,9 @@
 
 
 echo $ac_n "checking for GNU libc""... $ac_c" 1>&6
-echo "configure:2051: checking for GNU libc" >&5
-cat > conftest.$ac_ext <<EOF
-#line 2053 "configure"
+echo "configure:2059: checking for GNU libc" >&5
+cat > conftest.$ac_ext <<EOF
+#line 2061 "configure"
 #include "confdefs.h"
 #include <features.h>
 int main() {
@@ -2061,7 +2069,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:2065: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2073: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   have_glibc=yes
 else
@@ -2083,7 +2091,7 @@
 
 
 cat > conftest.$ac_ext <<EOF
-#line 2087 "configure"
+#line 2095 "configure"
 #include "confdefs.h"
 int main () {
 #if defined __SUNPRO_C
@@ -2095,7 +2103,7 @@
 #endif
 }
 EOF
-if { (eval echo configure:2099: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:2107: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   :
 else
@@ -2365,7 +2373,7 @@
  fi
 
 echo $ac_n "checking for dynodump""... $ac_c" 1>&6
-echo "configure:2369: checking for dynodump" >&5
+echo "configure:2377: checking for dynodump" >&5
 if test "$unexec" != "unexsol2.o"; then
   echo "$ac_t""no" 1>&6
 else
@@ -2403,12 +2411,12 @@
   done
   
 echo $ac_n "checking for terminateAndUnload in -lC""... $ac_c" 1>&6
-echo "configure:2407: checking for terminateAndUnload in -lC" >&5
+echo "configure:2415: checking for terminateAndUnload in -lC" >&5
 ac_lib_var=`echo C'_'terminateAndUnload | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lC "
 cat > conftest.$ac_ext <<EOF
-#line 2412 "configure"
+#line 2420 "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
@@ -2419,7 +2427,7 @@
 terminateAndUnload()
 ; return 0; }
 EOF
-if { (eval echo configure:2423: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2431: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -2503,10 +2511,10 @@
 
 if test "$add_runtime_path" = "yes"; then
       echo $ac_n "checking "for runtime libraries flag"""... $ac_c" 1>&6
-echo "configure:2507: checking "for runtime libraries flag"" >&5
+echo "configure:2515: checking "for runtime libraries flag"" >&5
   case "$opsys" in
-    sol2 ) dash_r = "-R" ;;
-    decosf* | linux* ) dash_r = "-rpath " ;;
+    sol2 ) dash_r="-R" ;;
+    decosf* | linux* ) dash_r="-rpath " ;;
     *)
       dash_r=""
       for try_dash_r in "-R" "-R " "-rpath "; do
@@ -2525,14 +2533,14 @@
   done
 fi
         cat > conftest.$ac_ext <<EOF
-#line 2529 "configure"
-#include "confdefs.h"
-
-int main() {
-
-; return 0; }
-EOF
-if { (eval echo configure:2536: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+#line 2537 "configure"
+#include "confdefs.h"
+
+int main() {
+
+; return 0; }
+EOF
+if { (eval echo configure:2544: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   dash_r="$try_dash_r"
 else
@@ -2633,10 +2641,10 @@
 fi
 after_morecore_hook_exists=yes
 echo $ac_n "checking for malloc_get_state""... $ac_c" 1>&6
-echo "configure:2637: checking for malloc_get_state" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 2640 "configure"
+echo "configure:2645: checking for malloc_get_state" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 2648 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char malloc_get_state(); below.  */
@@ -2659,7 +2667,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:2663: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2671: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_malloc_get_state=yes"
 else
@@ -2679,10 +2687,10 @@
 fi
 
 echo $ac_n "checking for malloc_set_state""... $ac_c" 1>&6
-echo "configure:2683: checking for malloc_set_state" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 2686 "configure"
+echo "configure:2691: checking for malloc_set_state" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 2694 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char malloc_set_state(); below.  */
@@ -2705,7 +2713,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:2709: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2717: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_malloc_set_state=yes"
 else
@@ -2725,16 +2733,16 @@
 fi
 
 echo $ac_n "checking whether __after_morecore_hook exists""... $ac_c" 1>&6
-echo "configure:2729: checking whether __after_morecore_hook exists" >&5
-cat > conftest.$ac_ext <<EOF
-#line 2731 "configure"
+echo "configure:2737: checking whether __after_morecore_hook exists" >&5
+cat > conftest.$ac_ext <<EOF
+#line 2739 "configure"
 #include "confdefs.h"
 extern void (* __after_morecore_hook)();
 int main() {
 __after_morecore_hook = 0
 ; return 0; }
 EOF
-if { (eval echo configure:2738: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2746: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   echo "$ac_t""yes" 1>&6
 else
@@ -2793,7 +2801,7 @@
 # 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:2797: checking for $ac_word" >&5
+echo "configure:2805: checking for $ac_word" >&5
 
 if test -n "$RANLIB"; then
   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
@@ -2846,7 +2854,7 @@
 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
 # ./install, which can be erroneously created by make from ./install.sh.
 echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:2850: checking for a BSD compatible install" >&5
+echo "configure:2858: checking for a BSD compatible install" >&5
 if test -z "$INSTALL"; then
 
   IFS="${IFS= 	}"; ac_save_IFS="$IFS"; IFS="${IFS}:"
@@ -2897,7 +2905,7 @@
 # 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:2901: checking for $ac_word" >&5
+echo "configure:2909: checking for $ac_word" >&5
 
 if test -n "$YACC"; then
   ac_cv_prog_YACC="$YACC" # Let the user override the test.
@@ -2928,15 +2936,15 @@
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2932: checking for $ac_hdr" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 2935 "configure"
+echo "configure:2940: checking for $ac_hdr" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 2943 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2940: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2948: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -2965,19 +2973,19 @@
 fi
 done
 
-for ac_hdr in utime.h locale.h libgen.h fcntl.h ulimit.h cygwin32/version.h
+for ac_hdr in utime.h locale.h libgen.h fcntl.h ulimit.h cygwin/version.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2973: checking for $ac_hdr" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 2976 "configure"
+echo "configure:2981: checking for $ac_hdr" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 2984 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2981: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2989: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -3010,15 +3018,15 @@
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3014: checking for $ac_hdr" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3017 "configure"
+echo "configure:3022: checking for $ac_hdr" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3025 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3022: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3030: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -3048,10 +3056,10 @@
 done
 
 echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
-echo "configure:3052: checking for sys/wait.h that is POSIX.1 compatible" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3055 "configure"
+echo "configure:3060: checking for sys/wait.h that is POSIX.1 compatible" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3063 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/wait.h>
@@ -3067,7 +3075,7 @@
 s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
 ; return 0; }
 EOF
-if { (eval echo configure:3071: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3079: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_header_sys_wait_h=yes
 else
@@ -3091,10 +3099,10 @@
 fi
 
 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:3095: checking for ANSI C header files" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3098 "configure"
+echo "configure:3103: checking for ANSI C header files" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3106 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 #include <stdarg.h>
@@ -3102,7 +3110,7 @@
 #include <float.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3106: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3114: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -3119,7 +3127,7 @@
 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 3123 "configure"
+#line 3131 "configure"
 #include "confdefs.h"
 #include <string.h>
 EOF
@@ -3137,7 +3145,7 @@
 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 3141 "configure"
+#line 3149 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 EOF
@@ -3155,7 +3163,7 @@
 if test $ac_cv_header_stdc = yes; then
   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
 cat > conftest.$ac_ext <<EOF
-#line 3159 "configure"
+#line 3167 "configure"
 #include "confdefs.h"
 #include <ctype.h>
 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -3166,7 +3174,7 @@
 exit (0); }
 
 EOF
-if { (eval echo configure:3170: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:3178: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   :
 else
@@ -3192,10 +3200,10 @@
 fi
 
 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
-echo "configure:3196: checking whether time.h and sys/time.h may both be included" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3199 "configure"
+echo "configure:3204: checking whether time.h and sys/time.h may both be included" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3207 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/time.h>
@@ -3204,7 +3212,7 @@
 struct tm *tp;
 ; return 0; }
 EOF
-if { (eval echo configure:3208: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3216: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_header_time=yes
 else
@@ -3228,10 +3236,10 @@
 fi
 
 echo $ac_n "checking for sys_siglist declaration in signal.h or unistd.h""... $ac_c" 1>&6
-echo "configure:3232: checking for sys_siglist declaration in signal.h or unistd.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3235 "configure"
+echo "configure:3240: checking for sys_siglist declaration in signal.h or unistd.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3243 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <signal.h>
@@ -3243,7 +3251,7 @@
 char *msg = *(sys_siglist + 1);
 ; return 0; }
 EOF
-if { (eval echo configure:3247: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3255: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_decl_sys_siglist=yes
 else
@@ -3268,9 +3276,9 @@
 
 
 echo $ac_n "checking for struct utimbuf""... $ac_c" 1>&6
-echo "configure:3272: checking for struct utimbuf" >&5
-cat > conftest.$ac_ext <<EOF
-#line 3274 "configure"
+echo "configure:3280: checking for struct utimbuf" >&5
+cat > conftest.$ac_ext <<EOF
+#line 3282 "configure"
 #include "confdefs.h"
 #ifdef TIME_WITH_SYS_TIME
 #include <sys/time.h>
@@ -3289,7 +3297,7 @@
 static struct utimbuf x; x.actime = x.modtime;
 ; return 0; }
 EOF
-if { (eval echo configure:3293: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3301: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   echo "$ac_t""yes" 1>&6
    { test "$extra_verbose" = "yes" && cat << \EOF
@@ -3309,10 +3317,10 @@
 rm -f conftest*
 
 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
-echo "configure:3313: checking return type of signal handlers" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3316 "configure"
+echo "configure:3321: checking return type of signal handlers" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3324 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <signal.h>
@@ -3329,7 +3337,7 @@
 int i;
 ; return 0; }
 EOF
-if { (eval echo configure:3333: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3341: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_type_signal=void
 else
@@ -3351,10 +3359,10 @@
 
 
 echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:3355: checking for size_t" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3358 "configure"
+echo "configure:3363: checking for size_t" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3366 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -3385,10 +3393,10 @@
 fi
 
 echo $ac_n "checking for pid_t""... $ac_c" 1>&6
-echo "configure:3389: checking for pid_t" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3392 "configure"
+echo "configure:3397: checking for pid_t" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3400 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -3419,10 +3427,10 @@
 fi
 
 echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
-echo "configure:3423: checking for uid_t in sys/types.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3426 "configure"
+echo "configure:3431: checking for uid_t in sys/types.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3434 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 EOF
@@ -3458,10 +3466,10 @@
 fi
 
 echo $ac_n "checking for mode_t""... $ac_c" 1>&6
-echo "configure:3462: checking for mode_t" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3465 "configure"
+echo "configure:3470: checking for mode_t" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3473 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -3492,10 +3500,10 @@
 fi
 
 echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:3496: checking for off_t" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3499 "configure"
+echo "configure:3504: checking for off_t" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3507 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -3527,9 +3535,9 @@
 
 
 echo $ac_n "checking for struct timeval""... $ac_c" 1>&6
-echo "configure:3531: checking for struct timeval" >&5
-cat > conftest.$ac_ext <<EOF
-#line 3533 "configure"
+echo "configure:3539: checking for struct timeval" >&5
+cat > conftest.$ac_ext <<EOF
+#line 3541 "configure"
 #include "confdefs.h"
 #ifdef TIME_WITH_SYS_TIME
 #include <sys/time.h>
@@ -3545,7 +3553,7 @@
 static struct timeval x; x.tv_sec = x.tv_usec;
 ; return 0; }
 EOF
-if { (eval echo configure:3549: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3557: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   echo "$ac_t""yes" 1>&6
   HAVE_TIMEVAL=yes
@@ -3567,10 +3575,10 @@
 rm -f conftest*
 
 echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
-echo "configure:3571: checking whether struct tm is in sys/time.h or time.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3574 "configure"
+echo "configure:3579: checking whether struct tm is in sys/time.h or time.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3582 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <time.h>
@@ -3578,7 +3586,7 @@
 struct tm *tp; tp->tm_sec;
 ; return 0; }
 EOF
-if { (eval echo configure:3582: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3590: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_struct_tm=time.h
 else
@@ -3602,10 +3610,10 @@
 fi
 
 echo $ac_n "checking for tm_zone in struct tm""... $ac_c" 1>&6
-echo "configure:3606: checking for tm_zone in struct tm" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3609 "configure"
+echo "configure:3614: checking for tm_zone in struct tm" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3617 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <$ac_cv_struct_tm>
@@ -3613,7 +3621,7 @@
 struct tm tm; tm.tm_zone;
 ; return 0; }
 EOF
-if { (eval echo configure:3617: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3625: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_struct_tm_zone=yes
 else
@@ -3636,10 +3644,10 @@
 
 else
   echo $ac_n "checking for tzname""... $ac_c" 1>&6
-echo "configure:3640: checking for tzname" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3643 "configure"
+echo "configure:3648: checking for tzname" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3651 "configure"
 #include "confdefs.h"
 #include <time.h>
 #ifndef tzname /* For SGI.  */
@@ -3649,7 +3657,7 @@
 atoi(*tzname);
 ; return 0; }
 EOF
-if { (eval echo configure:3653: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3661: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   ac_cv_var_tzname=yes
 else
@@ -3675,10 +3683,10 @@
 
 
 echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:3679: checking for working const" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3682 "configure"
+echo "configure:3687: checking for working const" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3690 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -3727,7 +3735,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:3731: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3739: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_const=yes
 else
@@ -3752,7 +3760,7 @@
 
 
 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:3756: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:3764: checking whether ${MAKE-make} sets \${MAKE}" >&5
 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
 
 cat > conftestmake <<\EOF
@@ -3777,12 +3785,12 @@
 
 
 echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
-echo "configure:3781: checking whether byte ordering is bigendian" >&5
+echo "configure:3789: checking whether byte ordering is bigendian" >&5
 
 ac_cv_c_bigendian=unknown
 # See if sys/param.h defines the BYTE_ORDER macro.
 cat > conftest.$ac_ext <<EOF
-#line 3786 "configure"
+#line 3794 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/param.h>
@@ -3793,11 +3801,11 @@
 #endif
 ; return 0; }
 EOF
-if { (eval echo configure:3797: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3805: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   # It does; now see whether it defined to BIG_ENDIAN or not.
 cat > conftest.$ac_ext <<EOF
-#line 3801 "configure"
+#line 3809 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/param.h>
@@ -3808,7 +3816,7 @@
 #endif
 ; return 0; }
 EOF
-if { (eval echo configure:3812: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3820: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_bigendian=yes
 else
@@ -3825,7 +3833,7 @@
 rm -f conftest*
 if test $ac_cv_c_bigendian = unknown; then
 cat > conftest.$ac_ext <<EOF
-#line 3829 "configure"
+#line 3837 "configure"
 #include "confdefs.h"
 main () {
   /* Are we little or big endian?  From Harbison&Steele.  */
@@ -3838,7 +3846,7 @@
   exit (u.c[sizeof (long) - 1] == 1);
 }
 EOF
-if { (eval echo configure:3842: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:3850: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   ac_cv_c_bigendian=no
 else
@@ -3865,10 +3873,10 @@
 
 
 echo $ac_n "checking size of short""... $ac_c" 1>&6
-echo "configure:3869: checking size of short" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3872 "configure"
+echo "configure:3877: checking size of short" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3880 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 main()
@@ -3879,7 +3887,7 @@
   exit(0);
 }
 EOF
-if { (eval echo configure:3883: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:3891: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   ac_cv_sizeof_short=`cat conftestval`
 else
@@ -3907,10 +3915,10 @@
   exit 1
 fi
 echo $ac_n "checking size of int""... $ac_c" 1>&6
-echo "configure:3911: checking size of int" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3914 "configure"
+echo "configure:3919: checking size of int" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3922 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 main()
@@ -3921,7 +3929,7 @@
   exit(0);
 }
 EOF
-if { (eval echo configure:3925: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:3933: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   ac_cv_sizeof_int=`cat conftestval`
 else
@@ -3943,10 +3951,10 @@
 
 
 echo $ac_n "checking size of long""... $ac_c" 1>&6
-echo "configure:3947: checking size of long" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3950 "configure"
+echo "configure:3955: checking size of long" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3958 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 main()
@@ -3957,7 +3965,7 @@
   exit(0);
 }
 EOF
-if { (eval echo configure:3961: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:3969: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   ac_cv_sizeof_long=`cat conftestval`
 else
@@ -3979,10 +3987,10 @@
 
 
 echo $ac_n "checking size of long long""... $ac_c" 1>&6
-echo "configure:3983: checking size of long long" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 3986 "configure"
+echo "configure:3991: checking size of long long" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 3994 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 main()
@@ -3993,7 +4001,7 @@
   exit(0);
 }
 EOF
-if { (eval echo configure:3997: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:4005: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   ac_cv_sizeof_long_long=`cat conftestval`
 else
@@ -4015,10 +4023,10 @@
 
 
 echo $ac_n "checking size of void *""... $ac_c" 1>&6
-echo "configure:4019: checking size of void *" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 4022 "configure"
+echo "configure:4027: checking size of void *" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 4030 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 main()
@@ -4029,7 +4037,7 @@
   exit(0);
 }
 EOF
-if { (eval echo configure:4033: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:4041: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   ac_cv_sizeof_void_p=`cat conftestval`
 else
@@ -4052,7 +4060,7 @@
 
 
 echo $ac_n "checking for long file names""... $ac_c" 1>&6
-echo "configure:4056: checking for long file names" >&5
+echo "configure:4064: checking for long file names" >&5
 
 ac_cv_sys_long_file_names=yes
 # Test for long file names in all the places we know might matter:
@@ -4099,12 +4107,12 @@
 
 
 echo $ac_n "checking for sin in -lm""... $ac_c" 1>&6
-echo "configure:4103: checking for sin in -lm" >&5
+echo "configure:4111: checking for sin in -lm" >&5
 ac_lib_var=`echo m'_'sin | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lm "
 cat > conftest.$ac_ext <<EOF
-#line 4108 "configure"
+#line 4116 "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
@@ -4115,7 +4123,7 @@
 sin()
 ; return 0; }
 EOF
-if { (eval echo configure:4119: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:4127: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -4157,14 +4165,14 @@
 
 
 cat > conftest.$ac_ext <<EOF
-#line 4161 "configure"
+#line 4169 "configure"
 #include "confdefs.h"
 #include <math.h>
 int main() {
 return atanh(1.0) + asinh(1.0) + acosh(1.0); 
 ; return 0; }
 EOF
-if { (eval echo configure:4168: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:4176: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   { test "$extra_verbose" = "yes" && cat << \EOF
     Defining HAVE_INVERSE_HYPERBOLIC
@@ -4181,7 +4189,7 @@
 rm -f conftest*
 
 echo "checking type of mail spool file locking" 1>&6
-echo "configure:4185: checking type of mail spool file locking" >&5
+echo "configure:4193: checking type of mail spool file locking" >&5
 test -z "$mail_locking" -a "$mail_use_flock" = "yes" && mail_locking=flock
 test -z "$mail_locking" -a "$mail_use_lockf" = "yes" && mail_locking=lockf
 if   test "$mail_locking" = "lockf"; then { test "$extra_verbose" = "yes" && cat << \EOF
@@ -4205,12 +4213,12 @@
 
 
 echo $ac_n "checking for kstat_open in -lkstat""... $ac_c" 1>&6
-echo "configure:4209: checking for kstat_open in -lkstat" >&5
+echo "configure:4217: checking for kstat_open in -lkstat" >&5
 ac_lib_var=`echo kstat'_'kstat_open | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lkstat "
 cat > conftest.$ac_ext <<EOF
-#line 4214 "configure"
+#line 4222 "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
@@ -4221,7 +4229,7 @@
 kstat_open()
 ; return 0; }
 EOF
-if { (eval echo configure:4225: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:4233: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -4255,12 +4263,12 @@
 
 
 echo $ac_n "checking for kvm_read in -lkvm""... $ac_c" 1>&6
-echo "configure:4259: checking for kvm_read in -lkvm" >&5
+echo "configure:4267: checking for kvm_read in -lkvm" >&5
 ac_lib_var=`echo kvm'_'kvm_read | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lkvm "
 cat > conftest.$ac_ext <<EOF
-#line 4264 "configure"
+#line 4272 "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
@@ -4271,7 +4279,7 @@
 kvm_read()
 ; return 0; }
 EOF
-if { (eval echo configure:4275: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:4283: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -4306,12 +4314,12 @@
 case "$opsys" in decosf*)
   
 echo $ac_n "checking for cma_open in -lpthreads""... $ac_c" 1>&6
-echo "configure:4310: checking for cma_open in -lpthreads" >&5
+echo "configure:4318: checking for cma_open in -lpthreads" >&5
 ac_lib_var=`echo pthreads'_'cma_open | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lpthreads "
 cat > conftest.$ac_ext <<EOF
-#line 4315 "configure"
+#line 4323 "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
@@ -4322,7 +4330,7 @@
 cma_open()
 ; return 0; }
 EOF
-if { (eval echo configure:4326: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:4334: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -4358,7 +4366,7 @@
 esac
 
 echo $ac_n "checking whether the -xildoff compiler flag is required""... $ac_c" 1>&6
-echo "configure:4362: checking whether the -xildoff compiler flag is required" >&5
+echo "configure:4370: checking whether the -xildoff compiler flag is required" >&5
 if   ${CC-cc} '-###' -xildon  no_such_file.c 2>&1 | grep '^[^ ]*/ild ' > /dev/null ; then
   if ${CC-cc} '-###' -xildoff no_such_file.c 2>&1 | grep '^[^ ]*/ild ' > /dev/null ;
     then echo "$ac_t""no" 1>&6;
@@ -4369,7 +4377,7 @@
 
 if test "$opsys" = "sol2" && test "$OS_RELEASE" -ge 56; then
   echo $ac_n "checking for \"-z ignore\" linker flag""... $ac_c" 1>&6
-echo "configure:4373: checking for \"-z ignore\" linker flag" >&5
+echo "configure:4381: checking for \"-z ignore\" linker flag" >&5
   case "`ld -h 2>&1`" in
     *-z\ ignore\|record* ) echo "$ac_t""yes" 1>&6
       ld_switch_site="-z ignore $ld_switch_site" &&  if test "$extra_verbose" = "yes"; then echo "    Prepending \"-z ignore\" to \$ld_switch_site"; fi ;;
@@ -4379,7 +4387,7 @@
 
 
 echo "checking "for specified window system"" 1>&6
-echo "configure:4383: checking "for specified window system"" >&5
+echo "configure:4391: checking "for specified window system"" >&5
 
 if test "$with_x11" != "no"; then
     test "$x_includes $x_libraries" != "NONE NONE" && \
@@ -4412,7 +4420,7 @@
 # Uses ac_ vars as temps to allow command line to override cache and checks.
 # --without-x overrides everything else, but does not touch the cache.
 echo $ac_n "checking for X""... $ac_c" 1>&6
-echo "configure:4416: checking for X" >&5
+echo "configure:4424: checking for X" >&5
 
 # Check whether --with-x or --without-x was given.
 if test "${with_x+set}" = set; then
@@ -4472,12 +4480,12 @@
 
   # First, try using that file with no special directory specified.
 cat > conftest.$ac_ext <<EOF
-#line 4476 "configure"
+#line 4484 "configure"
 #include "confdefs.h"
 #include <$x_direct_test_include>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:4481: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:4489: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -4546,14 +4554,14 @@
   ac_save_LIBS="$LIBS"
   LIBS="-l$x_direct_test_library $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 4550 "configure"
+#line 4558 "configure"
 #include "confdefs.h"
 
 int main() {
 ${x_direct_test_function}()
 ; return 0; }
 EOF
-if { (eval echo configure:4557: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:4565: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   LIBS="$ac_save_LIBS"
 # We can link X programs with no special library path.
@@ -4662,17 +4670,17 @@
     case "`(uname -sr) 2>/dev/null`" in
     "SunOS 5"*)
       echo $ac_n "checking whether -R must be followed by a space""... $ac_c" 1>&6
-echo "configure:4666: checking whether -R must be followed by a space" >&5
+echo "configure:4674: checking whether -R must be followed by a space" >&5
       ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries"
       cat > conftest.$ac_ext <<EOF
-#line 4669 "configure"
-#include "confdefs.h"
-
-int main() {
-
-; return 0; }
-EOF
-if { (eval echo configure:4676: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+#line 4677 "configure"
+#include "confdefs.h"
+
+int main() {
+
+; return 0; }
+EOF
+if { (eval echo configure:4684: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   ac_R_nospace=yes
 else
@@ -4688,14 +4696,14 @@
       else
 	LIBS="$ac_xsave_LIBS -R $x_libraries"
 	cat > conftest.$ac_ext <<EOF
-#line 4692 "configure"
-#include "confdefs.h"
-
-int main() {
-
-; return 0; }
-EOF
-if { (eval echo configure:4699: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+#line 4700 "configure"
+#include "confdefs.h"
+
+int main() {
+
+; return 0; }
+EOF
+if { (eval echo configure:4707: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   ac_R_space=yes
 else
@@ -4731,12 +4739,12 @@
 else
 
 echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6
-echo "configure:4735: checking for dnet_ntoa in -ldnet" >&5
+echo "configure:4743: checking for dnet_ntoa in -ldnet" >&5
 ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -ldnet "
 cat > conftest.$ac_ext <<EOF
-#line 4740 "configure"
+#line 4748 "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
@@ -4747,7 +4755,7 @@
 dnet_ntoa()
 ; return 0; }
 EOF
-if { (eval echo configure:4751: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:4759: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -4771,12 +4779,12 @@
     if test $ac_cv_lib_dnet_dnet_ntoa = no; then
       
 echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6
-echo "configure:4775: checking for dnet_ntoa in -ldnet_stub" >&5
+echo "configure:4783: checking for dnet_ntoa in -ldnet_stub" >&5
 ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -ldnet_stub "
 cat > conftest.$ac_ext <<EOF
-#line 4780 "configure"
+#line 4788 "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
@@ -4787,7 +4795,7 @@
 dnet_ntoa()
 ; return 0; }
 EOF
-if { (eval echo configure:4791: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:4799: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -4816,10 +4824,10 @@
     # The nsl library prevents programs from opening the X display
     # on Irix 5.2, according to dickey@clark.net.
     echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
-echo "configure:4820: checking for gethostbyname" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 4823 "configure"
+echo "configure:4828: checking for gethostbyname" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 4831 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char gethostbyname(); below.  */
@@ -4842,7 +4850,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:4846: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:4854: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_gethostbyname=yes"
 else
@@ -4863,12 +4871,12 @@
     if test $ac_cv_func_gethostbyname = no; then
       
 echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
-echo "configure:4867: checking for gethostbyname in -lnsl" >&5
+echo "configure:4875: checking for gethostbyname in -lnsl" >&5
 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lnsl "
 cat > conftest.$ac_ext <<EOF
-#line 4872 "configure"
+#line 4880 "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
@@ -4879,7 +4887,7 @@
 gethostbyname()
 ; return 0; }
 EOF
-if { (eval echo configure:4883: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:4891: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -4909,10 +4917,10 @@
     # -lsocket must be given before -lnsl if both are needed.
     # We assume that if connect needs -lnsl, so does gethostbyname.
     echo $ac_n "checking for connect""... $ac_c" 1>&6
-echo "configure:4913: checking for connect" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 4916 "configure"
+echo "configure:4921: checking for connect" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 4924 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char connect(); below.  */
@@ -4935,7 +4943,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:4939: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:4947: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_connect=yes"
 else
@@ -4958,12 +4966,12 @@
 xe_msg_checking="for connect in -lsocket"
 test -n "$X_EXTRA_LIBS" && xe_msg_checking="$xe_msg_checking using extra libs $X_EXTRA_LIBS"
 echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6
-echo "configure:4962: checking "$xe_msg_checking"" >&5
+echo "configure:4970: checking "$xe_msg_checking"" >&5
 ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lsocket $X_EXTRA_LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 4967 "configure"
+#line 4975 "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
@@ -4974,7 +4982,7 @@
 connect()
 ; return 0; }
 EOF
-if { (eval echo configure:4978: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:4986: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -4998,10 +5006,10 @@
 
     # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX.
     echo $ac_n "checking for remove""... $ac_c" 1>&6
-echo "configure:5002: checking for remove" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 5005 "configure"
+echo "configure:5010: checking for remove" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 5013 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char remove(); below.  */
@@ -5024,7 +5032,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:5028: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:5036: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_remove=yes"
 else
@@ -5045,12 +5053,12 @@
     if test $ac_cv_func_remove = no; then
       
 echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6
-echo "configure:5049: checking for remove in -lposix" >&5
+echo "configure:5057: checking for remove in -lposix" >&5
 ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lposix "
 cat > conftest.$ac_ext <<EOF
-#line 5054 "configure"
+#line 5062 "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
@@ -5061,7 +5069,7 @@
 remove()
 ; return 0; }
 EOF
-if { (eval echo configure:5065: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:5073: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5085,10 +5093,10 @@
 
     # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
     echo $ac_n "checking for shmat""... $ac_c" 1>&6
-echo "configure:5089: checking for shmat" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 5092 "configure"
+echo "configure:5097: checking for shmat" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 5100 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char shmat(); below.  */
@@ -5111,7 +5119,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:5115: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:5123: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_shmat=yes"
 else
@@ -5132,12 +5140,12 @@
     if test $ac_cv_func_shmat = no; then
       
 echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6
-echo "configure:5136: checking for shmat in -lipc" >&5
+echo "configure:5144: checking for shmat in -lipc" >&5
 ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lipc "
 cat > conftest.$ac_ext <<EOF
-#line 5141 "configure"
+#line 5149 "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
@@ -5148,7 +5156,7 @@
 shmat()
 ; return 0; }
 EOF
-if { (eval echo configure:5152: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:5160: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5182,12 +5190,12 @@
   #  --interran@uluru.Stanford.EDU, kb@cs.umb.edu.
   
 echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6
-echo "configure:5186: checking for IceConnectionNumber in -lICE" >&5
+echo "configure:5194: checking for IceConnectionNumber in -lICE" >&5
 ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lICE "
 cat > conftest.$ac_ext <<EOF
-#line 5191 "configure"
+#line 5199 "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
@@ -5198,7 +5206,7 @@
 IceConnectionNumber()
 ; return 0; }
 EOF
-if { (eval echo configure:5202: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:5210: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5367,7 +5375,7 @@
 
 
     echo "checking for X defines extracted by xmkmf" 1>&6
-echo "configure:5371: checking for X defines extracted by xmkmf" >&5
+echo "configure:5379: checking for X defines extracted by xmkmf" >&5
   rm -fr conftestdir
   if mkdir conftestdir; then
     cd conftestdir
@@ -5399,15 +5407,15 @@
 
     ac_safe=`echo "X11/Intrinsic.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for X11/Intrinsic.h""... $ac_c" 1>&6
-echo "configure:5403: checking for X11/Intrinsic.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 5406 "configure"
+echo "configure:5411: checking for X11/Intrinsic.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 5414 "configure"
 #include "confdefs.h"
 #include <X11/Intrinsic.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:5411: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:5419: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -5431,12 +5439,12 @@
 
       
 echo $ac_n "checking for XOpenDisplay in -lX11""... $ac_c" 1>&6
-echo "configure:5435: checking for XOpenDisplay in -lX11" >&5
+echo "configure:5443: checking for XOpenDisplay in -lX11" >&5
 ac_lib_var=`echo X11'_'XOpenDisplay | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lX11 "
 cat > conftest.$ac_ext <<EOF
-#line 5440 "configure"
+#line 5448 "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
@@ -5447,7 +5455,7 @@
 XOpenDisplay()
 ; return 0; }
 EOF
-if { (eval echo configure:5451: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:5459: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5472,12 +5480,12 @@
 xe_msg_checking="for XGetFontProperty in -lX11"
 test -n "-b i486-linuxaout" && xe_msg_checking="$xe_msg_checking using extra libs -b i486-linuxaout"
 echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6
-echo "configure:5476: checking "$xe_msg_checking"" >&5
+echo "configure:5484: checking "$xe_msg_checking"" >&5
 ac_lib_var=`echo X11'_'XGetFontProperty | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lX11 -b i486-linuxaout"
 cat > conftest.$ac_ext <<EOF
-#line 5481 "configure"
+#line 5489 "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
@@ -5488,7 +5496,7 @@
 XGetFontProperty()
 ; return 0; }
 EOF
-if { (eval echo configure:5492: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:5500: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5515,12 +5523,12 @@
 
     
 echo $ac_n "checking for XShapeSelectInput in -lXext""... $ac_c" 1>&6
-echo "configure:5519: checking for XShapeSelectInput in -lXext" >&5
+echo "configure:5527: checking for XShapeSelectInput in -lXext" >&5
 ac_lib_var=`echo Xext'_'XShapeSelectInput | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lXext "
 cat > conftest.$ac_ext <<EOF
-#line 5524 "configure"
+#line 5532 "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
@@ -5531,7 +5539,7 @@
 XShapeSelectInput()
 ; return 0; }
 EOF
-if { (eval echo configure:5535: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:5543: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5554,12 +5562,12 @@
 
     
 echo $ac_n "checking for XtOpenDisplay in -lXt""... $ac_c" 1>&6
-echo "configure:5558: checking for XtOpenDisplay in -lXt" >&5
+echo "configure:5566: checking for XtOpenDisplay in -lXt" >&5
 ac_lib_var=`echo Xt'_'XtOpenDisplay | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lXt "
 cat > conftest.$ac_ext <<EOF
-#line 5563 "configure"
+#line 5571 "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
@@ -5570,7 +5578,7 @@
 XtOpenDisplay()
 ; return 0; }
 EOF
-if { (eval echo configure:5574: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:5582: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5593,14 +5601,14 @@
 
 
   echo $ac_n "checking the version of X11 being used""... $ac_c" 1>&6
-echo "configure:5597: checking the version of X11 being used" >&5
+echo "configure:5605: checking the version of X11 being used" >&5
   cat > conftest.$ac_ext <<EOF
-#line 5599 "configure"
+#line 5607 "configure"
 #include "confdefs.h"
 #include <X11/Intrinsic.h>
     int main(int c, char *v[]) { return c>1 ? XlibSpecificationRelease : 0; }
 EOF
-if { (eval echo configure:5604: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:5612: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   ./conftest foobar; x11_release=$?
 else
@@ -5625,15 +5633,15 @@
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:5629: checking for $ac_hdr" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 5632 "configure"
+echo "configure:5637: checking for $ac_hdr" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 5640 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:5637: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:5645: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -5664,7 +5672,7 @@
 
 
     echo $ac_n "checking for XFree86""... $ac_c" 1>&6
-echo "configure:5668: checking for XFree86" >&5
+echo "configure:5676: checking for XFree86" >&5
   if test -d "/usr/X386/include" -o \
           -f "/etc/XF86Config"    -o \
 	  -f "/etc/X11/XF86Config" -o \
@@ -5684,12 +5692,12 @@
 
     test -z "$with_xmu" && { 
 echo $ac_n "checking for XmuReadBitmapDataFromFile in -lXmu""... $ac_c" 1>&6
-echo "configure:5688: checking for XmuReadBitmapDataFromFile in -lXmu" >&5
+echo "configure:5696: checking for XmuReadBitmapDataFromFile in -lXmu" >&5
 ac_lib_var=`echo Xmu'_'XmuReadBitmapDataFromFile | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lXmu "
 cat > conftest.$ac_ext <<EOF
-#line 5693 "configure"
+#line 5701 "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
@@ -5700,7 +5708,7 @@
 XmuReadBitmapDataFromFile()
 ; return 0; }
 EOF
-if { (eval echo configure:5704: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:5712: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5739,19 +5747,19 @@
 
       
 echo $ac_n "checking for main in -lXbsd""... $ac_c" 1>&6
-echo "configure:5743: checking for main in -lXbsd" >&5
+echo "configure:5751: checking for main in -lXbsd" >&5
 ac_lib_var=`echo Xbsd'_'main | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lXbsd "
 cat > conftest.$ac_ext <<EOF
-#line 5748 "configure"
+#line 5756 "configure"
 #include "confdefs.h"
 
 int main() {
 main()
 ; return 0; }
 EOF
-if { (eval echo configure:5755: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:5763: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5788,22 +5796,22 @@
 fi 
 if test "$with_msw" != "no"; then
   echo "checking for MS-Windows" 1>&6
-echo "configure:5792: checking for MS-Windows" >&5
+echo "configure:5800: checking for MS-Windows" >&5
   
 echo $ac_n "checking for main in -lgdi32""... $ac_c" 1>&6
-echo "configure:5795: checking for main in -lgdi32" >&5
+echo "configure:5803: checking for main in -lgdi32" >&5
 ac_lib_var=`echo gdi32'_'main | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lgdi32 "
 cat > conftest.$ac_ext <<EOF
-#line 5800 "configure"
+#line 5808 "configure"
 #include "confdefs.h"
 
 int main() {
 main()
 ; return 0; }
 EOF
-if { (eval echo configure:5807: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:5815: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5868,12 +5876,12 @@
  fi
     fi
         cat > conftest.$ac_ext <<EOF
-#line 5872 "configure"
+#line 5880 "configure"
 #include "confdefs.h"
 #include <fcntl.h>
     int main() { return (open("/dev/windows", O_RDONLY, 0) > 0)? 0 : 1; }
 EOF
-if { (eval echo configure:5877: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:5885: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   { test "$extra_verbose" = "yes" && cat << \EOF
     Defining HAVE_MSG_SELECT
@@ -5952,7 +5960,7 @@
 esac
 
 echo "checking for session-management option" 1>&6
-echo "configure:5956: checking for session-management option" >&5;
+echo "configure:5964: checking for session-management option" >&5;
 if test "$with_session" != "no"; then
   { test "$extra_verbose" = "yes" && cat << \EOF
     Defining HAVE_SESSION
@@ -5967,15 +5975,15 @@
 test -z "$with_xauth" && test "$window_system" = "none" && with_xauth=no
 test -z "$with_xauth" && { ac_safe=`echo "X11/Xauth.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for X11/Xauth.h""... $ac_c" 1>&6
-echo "configure:5971: checking for X11/Xauth.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 5974 "configure"
+echo "configure:5979: checking for X11/Xauth.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 5982 "configure"
 #include "confdefs.h"
 #include <X11/Xauth.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:5979: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:5987: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -5998,12 +6006,12 @@
  }
 test -z "$with_xauth" && { 
 echo $ac_n "checking for XauGetAuthByAddr in -lXau""... $ac_c" 1>&6
-echo "configure:6002: checking for XauGetAuthByAddr in -lXau" >&5
+echo "configure:6010: checking for XauGetAuthByAddr in -lXau" >&5
 ac_lib_var=`echo Xau'_'XauGetAuthByAddr | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lXau "
 cat > conftest.$ac_ext <<EOF
-#line 6007 "configure"
+#line 6015 "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
@@ -6014,7 +6022,7 @@
 XauGetAuthByAddr()
 ; return 0; }
 EOF
-if { (eval echo configure:6018: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:6026: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6059,15 +6067,15 @@
       for dir in "" "Tt/" "desktop/" ; do
     ac_safe=`echo "${dir}tt_c.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for ${dir}tt_c.h""... $ac_c" 1>&6
-echo "configure:6063: checking for ${dir}tt_c.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 6066 "configure"
+echo "configure:6071: checking for ${dir}tt_c.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 6074 "configure"
 #include "confdefs.h"
 #include <${dir}tt_c.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:6071: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:6079: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -6103,12 +6111,12 @@
 xe_msg_checking="for tt_message_create in -ltt"
 test -n "$extra_libs" && xe_msg_checking="$xe_msg_checking using extra libs $extra_libs"
 echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6
-echo "configure:6107: checking "$xe_msg_checking"" >&5
+echo "configure:6115: checking "$xe_msg_checking"" >&5
 ac_lib_var=`echo tt'_'tt_message_create | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -ltt $extra_libs"
 cat > conftest.$ac_ext <<EOF
-#line 6112 "configure"
+#line 6120 "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
@@ -6119,7 +6127,7 @@
 tt_message_create()
 ; return 0; }
 EOF
-if { (eval echo configure:6123: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:6131: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6176,15 +6184,15 @@
 
 test -z "$with_cde" && { ac_safe=`echo "Dt/Dt.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for Dt/Dt.h""... $ac_c" 1>&6
-echo "configure:6180: checking for Dt/Dt.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 6183 "configure"
+echo "configure:6188: checking for Dt/Dt.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 6191 "configure"
 #include "confdefs.h"
 #include <Dt/Dt.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:6188: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:6196: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -6207,12 +6215,12 @@
  }
 test -z "$with_cde" && { 
 echo $ac_n "checking for DtDndDragStart in -lDtSvc""... $ac_c" 1>&6
-echo "configure:6211: checking for DtDndDragStart in -lDtSvc" >&5
+echo "configure:6219: checking for DtDndDragStart in -lDtSvc" >&5
 ac_lib_var=`echo DtSvc'_'DtDndDragStart | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lDtSvc "
 cat > conftest.$ac_ext <<EOF
-#line 6216 "configure"
+#line 6224 "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
@@ -6223,7 +6231,7 @@
 DtDndDragStart()
 ; return 0; }
 EOF
-if { (eval echo configure:6227: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:6235: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6292,7 +6300,7 @@
 fi
 
 echo $ac_n "checking if drag and drop API is needed""... $ac_c" 1>&6
-echo "configure:6296: checking if drag and drop API is needed" >&5
+echo "configure:6304: checking if drag and drop API is needed" >&5
 if test "$with_dragndrop" != "no" ; then
   if test -n "$dragndrop_proto" ; then
     with_dragndrop=yes
@@ -6313,18 +6321,18 @@
 fi
 
 echo "checking for LDAP" 1>&6
-echo "configure:6317: checking for LDAP" >&5
+echo "configure:6325: checking for LDAP" >&5
 test -z "$with_ldap" && { ac_safe=`echo "ldap.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for ldap.h""... $ac_c" 1>&6
-echo "configure:6320: checking for ldap.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 6323 "configure"
+echo "configure:6328: checking for ldap.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 6331 "configure"
 #include "confdefs.h"
 #include <ldap.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:6328: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:6336: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -6347,15 +6355,15 @@
  }
 test -z "$with_ldap" && { ac_safe=`echo "lber.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for lber.h""... $ac_c" 1>&6
-echo "configure:6351: checking for lber.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 6354 "configure"
+echo "configure:6359: checking for lber.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 6362 "configure"
 #include "confdefs.h"
 #include <lber.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:6359: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:6367: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -6381,12 +6389,12 @@
 xe_msg_checking="for ldap_open in -lldap"
 test -n "-llber" && xe_msg_checking="$xe_msg_checking using extra libs -llber"
 echo $ac_n "checking "$xe_msg_checking"""... $ac_c" 1>&6
-echo "configure:6385: checking "$xe_msg_checking"" >&5
+echo "configure:6393: checking "$xe_msg_checking"" >&5
 ac_lib_var=`echo ldap'_'ldap_open | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lldap -llber"
 cat > conftest.$ac_ext <<EOF
-#line 6390 "configure"
+#line 6398 "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
@@ -6397,7 +6405,7 @@
 ldap_open()
 ; return 0; }
 EOF
-if { (eval echo configure:6401: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:6409: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6420,12 +6428,12 @@
  }
   test "$with_umich_ldap" = "no" && { 
 echo $ac_n "checking for ldap_set_option in -lldap10""... $ac_c" 1>&6
-echo "configure:6424: checking for ldap_set_option in -lldap10" >&5
+echo "configure:6432: checking for ldap_set_option in -lldap10" >&5
 ac_lib_var=`echo ldap10'_'ldap_set_option | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lldap10 "
 cat > conftest.$ac_ext <<EOF
-#line 6429 "configure"
+#line 6437 "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
@@ -6436,7 +6444,7 @@
 ldap_set_option()
 ; return 0; }
 EOF
-if { (eval echo configure:6440: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:6448: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6500,15 +6508,15 @@
 
 if test "$window_system" != "none"; then
   echo "checking for graphics libraries" 1>&6
-echo "configure:6504: checking for graphics libraries" >&5
+echo "configure:6512: checking for graphics libraries" >&5
 
     xpm_problem=""
   if test -z "$with_xpm"; then
     echo $ac_n "checking for Xpm - no older than 3.4f""... $ac_c" 1>&6
-echo "configure:6509: checking for Xpm - no older than 3.4f" >&5
+echo "configure:6517: checking for Xpm - no older than 3.4f" >&5
     xe_check_libs=-lXpm
     cat > conftest.$ac_ext <<EOF
-#line 6512 "configure"
+#line 6520 "configure"
 #include "confdefs.h"
 #include <X11/xpm.h>
     int main(int c, char **v) {
@@ -6516,7 +6524,7 @@
       XpmIncludeVersion != XpmLibraryVersion() ? 1 :
       XpmIncludeVersion < 30406 ? 2 : 0 ;}
 EOF
-if { (eval echo configure:6520: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:6528: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   ./conftest dummy_arg; xpm_status=$?;
       if test "$xpm_status" = "0"; then
@@ -6558,17 +6566,17 @@
 
     libs_x="-lXpm $libs_x" &&  if test "$extra_verbose" = "yes"; then echo "    Prepending \"-lXpm\" to \$libs_x"; fi
     echo $ac_n "checking for \"FOR_MSW\" xpm""... $ac_c" 1>&6
-echo "configure:6562: checking for \"FOR_MSW\" xpm" >&5
+echo "configure:6570: checking for \"FOR_MSW\" xpm" >&5
     xe_check_libs=-lXpm
     cat > conftest.$ac_ext <<EOF
-#line 6565 "configure"
+#line 6573 "configure"
 #include "confdefs.h"
 
 int main() {
 XpmCreatePixmapFromData()
 ; return 0; }
 EOF
-if { (eval echo configure:6572: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:6580: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   xpm_for_msw=no
 else
@@ -6610,12 +6618,12 @@
       if test "$with_png $with_tiff" != "no no"; then
     
 echo $ac_n "checking for inflate in -lc""... $ac_c" 1>&6
-echo "configure:6614: checking for inflate in -lc" >&5
+echo "configure:6622: checking for inflate in -lc" >&5
 ac_lib_var=`echo c'_'inflate | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lc "
 cat > conftest.$ac_ext <<EOF
-#line 6619 "configure"
+#line 6627 "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
@@ -6626,7 +6634,7 @@
 inflate()
 ; return 0; }
 EOF
-if { (eval echo configure:6630: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:6638: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6645,12 +6653,12 @@
   echo "$ac_t""no" 1>&6
 
 echo $ac_n "checking for inflate in -lz""... $ac_c" 1>&6
-echo "configure:6649: checking for inflate in -lz" >&5
+echo "configure:6657: checking for inflate in -lz" >&5
 ac_lib_var=`echo z'_'inflate | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lz "
 cat > conftest.$ac_ext <<EOF
-#line 6654 "configure"
+#line 6662 "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
@@ -6661,7 +6669,7 @@
 inflate()
 ; return 0; }
 EOF
-if { (eval echo configure:6665: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:6673: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6680,12 +6688,12 @@
   echo "$ac_t""no" 1>&6
 
 echo $ac_n "checking for inflate in -lgz""... $ac_c" 1>&6
-echo "configure:6684: checking for inflate in -lgz" >&5
+echo "configure:6692: checking for inflate in -lgz" >&5
 ac_lib_var=`echo gz'_'inflate | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lgz "
 cat > conftest.$ac_ext <<EOF
-#line 6689 "configure"
+#line 6697 "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
@@ -6696,7 +6704,7 @@
 inflate()
 ; return 0; }
 EOF
-if { (eval echo configure:6700: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:6708: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6726,15 +6734,15 @@
 
     test -z "$with_jpeg" && { ac_safe=`echo "jpeglib.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for jpeglib.h""... $ac_c" 1>&6
-echo "configure:6730: checking for jpeglib.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 6733 "configure"
+echo "configure:6738: checking for jpeglib.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 6741 "configure"
 #include "confdefs.h"
 #include <jpeglib.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:6738: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:6746: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -6757,12 +6765,12 @@
  }
   test -z "$with_jpeg" && { 
 echo $ac_n "checking for jpeg_destroy_decompress in -ljpeg""... $ac_c" 1>&6
-echo "configure:6761: checking for jpeg_destroy_decompress in -ljpeg" >&5
+echo "configure:6769: checking for jpeg_destroy_decompress in -ljpeg" >&5
 ac_lib_var=`echo jpeg'_'jpeg_destroy_decompress | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -ljpeg "
 cat > conftest.$ac_ext <<EOF
-#line 6766 "configure"
+#line 6774 "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
@@ -6773,7 +6781,7 @@
 jpeg_destroy_decompress()
 ; return 0; }
 EOF
-if { (eval echo configure:6777: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:6785: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6809,10 +6817,10 @@
 
     png_problem=""
   test -z "$with_png" && { echo $ac_n "checking for pow""... $ac_c" 1>&6
-echo "configure:6813: checking for pow" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 6816 "configure"
+echo "configure:6821: checking for pow" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 6824 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char pow(); below.  */
@@ -6835,7 +6843,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:6839: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:6847: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_pow=yes"
 else
@@ -6856,15 +6864,15 @@
  }
   test -z "$with_png" && { ac_safe=`echo "png.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for png.h""... $ac_c" 1>&6
-echo "configure:6860: checking for png.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 6863 "configure"
+echo "configure:6868: checking for png.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 6871 "configure"
 #include "confdefs.h"
 #include <png.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:6868: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:6876: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -6887,12 +6895,12 @@
  }
   test -z "$with_png" && { 
 echo $ac_n "checking for png_read_image in -lpng""... $ac_c" 1>&6
-echo "configure:6891: checking for png_read_image in -lpng" >&5
+echo "configure:6899: checking for png_read_image in -lpng" >&5
 ac_lib_var=`echo png'_'png_read_image | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lpng "
 cat > conftest.$ac_ext <<EOF
-#line 6896 "configure"
+#line 6904 "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
@@ -6903,7 +6911,7 @@
 png_read_image()
 ; return 0; }
 EOF
-if { (eval echo configure:6907: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:6915: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6926,10 +6934,10 @@
  }
   if test -z "$with_png"; then
     echo $ac_n "checking for workable png version information""... $ac_c" 1>&6
-echo "configure:6930: checking for workable png version information" >&5
+echo "configure:6938: checking for workable png version information" >&5
     xe_check_libs="-lpng -lz"
     cat > conftest.$ac_ext <<EOF
-#line 6933 "configure"
+#line 6941 "configure"
 #include "confdefs.h"
 #include <png.h>
     int main(int c, char **v) {
@@ -6937,7 +6945,7 @@
     if (strcmp(png_libpng_ver, PNG_LIBPNG_VER_STRING) != 0) return 1;
     return (PNG_LIBPNG_VER < 10002) ? 2 : 0 ;}
 EOF
-if { (eval echo configure:6941: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:6949: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   ./conftest dummy_arg; png_status=$?;
       if test "$png_status" = "0"; then
@@ -6980,15 +6988,15 @@
 
     test -z "$with_tiff" && { ac_safe=`echo "tiffio.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for tiffio.h""... $ac_c" 1>&6
-echo "configure:6984: checking for tiffio.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 6987 "configure"
+echo "configure:6992: checking for tiffio.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 6995 "configure"
 #include "confdefs.h"
 #include <tiffio.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:6992: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:7000: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -7011,12 +7019,12 @@
  }
   test -z "$with_tiff" && { 
 echo $ac_n "checking for TIFFClientOpen in -ltiff""... $ac_c" 1>&6
-echo "configure:7015: checking for TIFFClientOpen in -ltiff" >&5
+echo "configure:7023: checking for TIFFClientOpen in -ltiff" >&5
 ac_lib_var=`echo tiff'_'TIFFClientOpen | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -ltiff "
 cat > conftest.$ac_ext <<EOF
-#line 7020 "configure"
+#line 7028 "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
@@ -7027,7 +7035,7 @@
 TIFFClientOpen()
 ; return 0; }
 EOF
-if { (eval echo configure:7031: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:7039: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7066,19 +7074,19 @@
 if test "$with_x11" = "yes"; then
 
   echo "checking for X11 graphics libraries" 1>&6
-echo "configure:7070: checking for X11 graphics libraries" >&5
+echo "configure:7078: checking for X11 graphics libraries" >&5
 
     test -z "$with_xface" && { ac_safe=`echo "compface.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for compface.h""... $ac_c" 1>&6
-echo "configure:7074: checking for compface.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 7077 "configure"
+echo "configure:7082: checking for compface.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 7085 "configure"
 #include "confdefs.h"
 #include <compface.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:7082: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:7090: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -7101,12 +7109,12 @@
  }
   test -z "$with_xface" && { 
 echo $ac_n "checking for UnGenFace in -lcompface""... $ac_c" 1>&6
-echo "configure:7105: checking for UnGenFace in -lcompface" >&5
+echo "configure:7113: checking for UnGenFace in -lcompface" >&5
 ac_lib_var=`echo compface'_'UnGenFace | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lcompface "
 cat > conftest.$ac_ext <<EOF
-#line 7110 "configure"
+#line 7118 "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
@@ -7117,7 +7125,7 @@
 UnGenFace()
 ; return 0; }
 EOF
-if { (eval echo configure:7121: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:7129: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7153,12 +7161,12 @@
 
     
 echo $ac_n "checking for XawScrollbarSetThumb in -lXaw""... $ac_c" 1>&6
-echo "configure:7157: checking for XawScrollbarSetThumb in -lXaw" >&5
+echo "configure:7165: checking for XawScrollbarSetThumb in -lXaw" >&5
 ac_lib_var=`echo Xaw'_'XawScrollbarSetThumb | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lXaw "
 cat > conftest.$ac_ext <<EOF
-#line 7162 "configure"
+#line 7170 "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
@@ -7169,7 +7177,7 @@
 XawScrollbarSetThumb()
 ; return 0; }
 EOF
-if { (eval echo configure:7173: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:7181: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7193,15 +7201,15 @@
                     
     ac_safe=`echo "Xm/Xm.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for Xm/Xm.h""... $ac_c" 1>&6
-echo "configure:7197: checking for Xm/Xm.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 7200 "configure"
+echo "configure:7205: checking for Xm/Xm.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 7208 "configure"
 #include "confdefs.h"
 #include <Xm/Xm.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:7205: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:7213: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -7218,12 +7226,12 @@
   echo "$ac_t""yes" 1>&6
   
 echo $ac_n "checking for XmStringFree in -lXm""... $ac_c" 1>&6
-echo "configure:7222: checking for XmStringFree in -lXm" >&5
+echo "configure:7230: checking for XmStringFree in -lXm" >&5
 ac_lib_var=`echo Xm'_'XmStringFree | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lXm "
 cat > conftest.$ac_ext <<EOF
-#line 7227 "configure"
+#line 7235 "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
@@ -7234,7 +7242,7 @@
 XmStringFree()
 ; return 0; }
 EOF
-if { (eval echo configure:7238: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:7246: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7263,9 +7271,9 @@
 
   if test "$have_motif" = "yes"; then
         echo $ac_n "checking for Lesstif""... $ac_c" 1>&6
-echo "configure:7267: checking for Lesstif" >&5
+echo "configure:7275: checking for Lesstif" >&5
     cat > conftest.$ac_ext <<EOF
-#line 7269 "configure"
+#line 7277 "configure"
 #include "confdefs.h"
 #include <Xm/Xm.h>
 #ifdef LESSTIF_VERSION
@@ -7549,7 +7557,7 @@
 
 if test "$with_mule" = "yes" ; then
   echo "checking for Mule-related features" 1>&6
-echo "configure:7553: checking for Mule-related features" >&5
+echo "configure:7561: checking for Mule-related features" >&5
   { test "$extra_verbose" = "yes" && cat << \EOF
     Defining MULE
 EOF
@@ -7574,15 +7582,15 @@
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:7578: checking for $ac_hdr" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 7581 "configure"
+echo "configure:7586: checking for $ac_hdr" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 7589 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:7586: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:7594: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -7613,12 +7621,12 @@
 
   
 echo $ac_n "checking for strerror in -lintl""... $ac_c" 1>&6
-echo "configure:7617: checking for strerror in -lintl" >&5
+echo "configure:7625: checking for strerror in -lintl" >&5
 ac_lib_var=`echo intl'_'strerror | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lintl "
 cat > conftest.$ac_ext <<EOF
-#line 7622 "configure"
+#line 7630 "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
@@ -7629,7 +7637,7 @@
 strerror()
 ; return 0; }
 EOF
-if { (eval echo configure:7633: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:7641: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7662,19 +7670,19 @@
 
 
   echo "checking for Mule input methods" 1>&6
-echo "configure:7666: checking for Mule input methods" >&5
+echo "configure:7674: checking for Mule input methods" >&5
         case "$with_xim" in "" | "yes" )
     echo "checking for XIM" 1>&6
-echo "configure:7669: checking for XIM" >&5
+echo "configure:7677: checking for XIM" >&5
         if test "$have_lesstif" = "yes"; then with_xim=xlib
     else 
 echo $ac_n "checking for XmImMbLookupString in -lXm""... $ac_c" 1>&6
-echo "configure:7673: checking for XmImMbLookupString in -lXm" >&5
+echo "configure:7681: checking for XmImMbLookupString in -lXm" >&5
 ac_lib_var=`echo Xm'_'XmImMbLookupString | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lXm "
 cat > conftest.$ac_ext <<EOF
-#line 7678 "configure"
+#line 7686 "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
@@ -7685,7 +7693,7 @@
 XmImMbLookupString()
 ; return 0; }
 EOF
-if { (eval echo configure:7689: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:7697: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7751,15 +7759,15 @@
 
     if test "$with_xfs" = "yes" ; then
     echo "checking for XFontSet" 1>&6
-echo "configure:7755: checking for XFontSet" >&5
+echo "configure:7763: checking for XFontSet" >&5
     
 echo $ac_n "checking for XmbDrawString in -lX11""... $ac_c" 1>&6
-echo "configure:7758: checking for XmbDrawString in -lX11" >&5
+echo "configure:7766: checking for XmbDrawString in -lX11" >&5
 ac_lib_var=`echo X11'_'XmbDrawString | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lX11 "
 cat > conftest.$ac_ext <<EOF
-#line 7763 "configure"
+#line 7771 "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
@@ -7770,7 +7778,7 @@
 XmbDrawString()
 ; return 0; }
 EOF
-if { (eval echo configure:7774: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:7782: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7810,15 +7818,15 @@
     test "$with_wnn6" = "yes" && with_wnn=yes # wnn6 implies wnn support
   test -z "$with_wnn" && { ac_safe=`echo "wnn/jllib.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for wnn/jllib.h""... $ac_c" 1>&6
-echo "configure:7814: checking for wnn/jllib.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 7817 "configure"
+echo "configure:7822: checking for wnn/jllib.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 7825 "configure"
 #include "confdefs.h"
 #include <wnn/jllib.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:7822: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:7830: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -7843,10 +7851,10 @@
     for ac_func in crypt
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:7847: checking for $ac_func" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 7850 "configure"
+echo "configure:7855: checking for $ac_func" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 7858 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -7869,7 +7877,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:7873: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:7881: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -7898,12 +7906,12 @@
 
     test "$ac_cv_func_crypt" != "yes" && { 
 echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6
-echo "configure:7902: checking for crypt in -lcrypt" >&5
+echo "configure:7910: checking for crypt in -lcrypt" >&5
 ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lcrypt "
 cat > conftest.$ac_ext <<EOF
-#line 7907 "configure"
+#line 7915 "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
@@ -7914,7 +7922,7 @@
 crypt()
 ; return 0; }
 EOF
-if { (eval echo configure:7918: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:7926: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7946,14 +7954,15 @@
 
  }
   fi
-    test -z "$with_wnn" && { 
+    if test -z "$with_wnn" -o "$with_wnn" = "yes"; then
+    
 echo $ac_n "checking for jl_dic_list_e in -lwnn""... $ac_c" 1>&6
-echo "configure:7952: checking for jl_dic_list_e in -lwnn" >&5
+echo "configure:7961: checking for jl_dic_list_e in -lwnn" >&5
 ac_lib_var=`echo wnn'_'jl_dic_list_e | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lwnn "
 cat > conftest.$ac_ext <<EOF
-#line 7957 "configure"
+#line 7966 "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
@@ -7964,7 +7973,41 @@
 jl_dic_list_e()
 ; return 0; }
 EOF
-if { (eval echo configure:7968: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:7977: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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*
+xe_check_libs=""
+
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then
+  echo "$ac_t""yes" 1>&6
+  libwnn=wnn
+else
+  echo "$ac_t""no" 1>&6
+echo $ac_n "checking for jl_dic_list_e in -lwnn4""... $ac_c" 1>&6
+echo "configure:7995: checking for jl_dic_list_e in -lwnn4" >&5
+ac_lib_var=`echo wnn4'_'jl_dic_list_e | sed 'y%./+-%__p_%'`
+
+xe_check_libs=" -lwnn4 "
+cat > conftest.$ac_ext <<EOF
+#line 8000 "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 jl_dic_list_e();
+
+int main() {
+jl_dic_list_e()
+; return 0; }
+EOF
+if { (eval echo configure:8011: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7978,13 +8021,91 @@
 
 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then
   echo "$ac_t""yes" 1>&6
-  :
+  libwnn=wnn4
+else
+  echo "$ac_t""no" 1>&6
+echo $ac_n "checking for jl_dic_list_e in -lwnn6""... $ac_c" 1>&6
+echo "configure:8029: checking for jl_dic_list_e in -lwnn6" >&5
+ac_lib_var=`echo wnn6'_'jl_dic_list_e | sed 'y%./+-%__p_%'`
+
+xe_check_libs=" -lwnn6 "
+cat > conftest.$ac_ext <<EOF
+#line 8034 "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 jl_dic_list_e();
+
+int main() {
+jl_dic_list_e()
+; return 0; }
+EOF
+if { (eval echo configure:8045: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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*
+xe_check_libs=""
+
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then
+  echo "$ac_t""yes" 1>&6
+  libwnn=wnn6
+else
+  echo "$ac_t""no" 1>&6
+echo $ac_n "checking for dic_list_e in -lwnn6_fromsrc""... $ac_c" 1>&6
+echo "configure:8063: checking for dic_list_e in -lwnn6_fromsrc" >&5
+ac_lib_var=`echo wnn6_fromsrc'_'dic_list_e | sed 'y%./+-%__p_%'`
+
+xe_check_libs=" -lwnn6_fromsrc "
+cat > conftest.$ac_ext <<EOF
+#line 8068 "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 dic_list_e();
+
+int main() {
+dic_list_e()
+; return 0; }
+EOF
+if { (eval echo configure:8079: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; 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*
+xe_check_libs=""
+
+if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes" ; then
+  echo "$ac_t""yes" 1>&6
+  libwnn=wnn6_fromsrc
 else
   echo "$ac_t""no" 1>&6
 with_wnn=no
 fi
 
- }
+
+fi
+
+
+fi
+
+
+fi
+
+
+  fi
   test -z "$with_wnn" && with_wnn=yes
   if test "$with_wnn" = "yes"; then
     { test "$extra_verbose" = "yes" && cat << \EOF
@@ -7995,19 +8116,19 @@
 EOF
 }
 
-    libs_x="-lwnn $libs_x" &&  if test "$extra_verbose" = "yes"; then echo "    Prepending \"-lwnn\" to \$libs_x"; fi
+    libs_x="-l$libwnn $libs_x" &&  if test "$extra_verbose" = "yes"; then echo "    Prepending \"-l$libwnn\" to \$libs_x"; fi
     extra_objs="$extra_objs mule-wnnfns.o" &&  if test "$extra_verbose" = "yes"; then
    echo "    xemacs will be linked with \"mule-wnnfns.o\""
  fi
     if test "$with_wnn6" != "no"; then
       
-echo $ac_n "checking for jl_fi_dic_list in -lwnn""... $ac_c" 1>&6
-echo "configure:8006: checking for jl_fi_dic_list in -lwnn" >&5
-ac_lib_var=`echo wnn'_'jl_fi_dic_list | sed 'y%./+-%__p_%'`
-
-xe_check_libs=" -lwnn "
-cat > conftest.$ac_ext <<EOF
-#line 8011 "configure"
+echo $ac_n "checking for jl_fi_dic_list in -l$libwnn""... $ac_c" 1>&6
+echo "configure:8127: checking for jl_fi_dic_list in -l$libwnn" >&5
+ac_lib_var=`echo $libwnn'_'jl_fi_dic_list | sed 'y%./+-%__p_%'`
+
+xe_check_libs=" -l$libwnn "
+cat > conftest.$ac_ext <<EOF
+#line 8132 "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
@@ -8018,7 +8139,7 @@
 jl_fi_dic_list()
 ; return 0; }
 EOF
-if { (eval echo configure:8022: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:8143: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -8053,15 +8174,15 @@
   if test "$with_canna" != "no"; then
     ac_safe=`echo "canna/jrkanji.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for canna/jrkanji.h""... $ac_c" 1>&6
-echo "configure:8057: checking for canna/jrkanji.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 8060 "configure"
+echo "configure:8178: checking for canna/jrkanji.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 8181 "configure"
 #include "confdefs.h"
 #include <canna/jrkanji.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8065: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8186: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -8088,15 +8209,15 @@
     c_switch_site="$c_switch_site -I/usr/local/canna/include"
     ac_safe=`echo "canna/jrkanji.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for canna/jrkanji.h""... $ac_c" 1>&6
-echo "configure:8092: checking for canna/jrkanji.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 8095 "configure"
+echo "configure:8213: checking for canna/jrkanji.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 8216 "configure"
 #include "confdefs.h"
 #include <canna/jrkanji.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8100: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8221: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -8124,15 +8245,15 @@
 
   test -z "$with_canna" && { ac_safe=`echo "canna/RK.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for canna/RK.h""... $ac_c" 1>&6
-echo "configure:8128: checking for canna/RK.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 8131 "configure"
+echo "configure:8249: checking for canna/RK.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 8252 "configure"
 #include "confdefs.h"
 #include <canna/RK.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8136: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8257: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -8155,12 +8276,12 @@
  }
   test -z "$with_canna" && { 
 echo $ac_n "checking for RkBgnBun in -lRKC""... $ac_c" 1>&6
-echo "configure:8159: checking for RkBgnBun in -lRKC" >&5
+echo "configure:8280: checking for RkBgnBun in -lRKC" >&5
 ac_lib_var=`echo RKC'_'RkBgnBun | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lRKC "
 cat > conftest.$ac_ext <<EOF
-#line 8164 "configure"
+#line 8285 "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
@@ -8171,7 +8292,7 @@
 RkBgnBun()
 ; return 0; }
 EOF
-if { (eval echo configure:8175: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:8296: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -8194,12 +8315,12 @@
  }
   test -z "$with_canna" && { 
 echo $ac_n "checking for jrKanjiControl in -lcanna""... $ac_c" 1>&6
-echo "configure:8198: checking for jrKanjiControl in -lcanna" >&5
+echo "configure:8319: checking for jrKanjiControl in -lcanna" >&5
 ac_lib_var=`echo canna'_'jrKanjiControl | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lcanna "
 cat > conftest.$ac_ext <<EOF
-#line 8203 "configure"
+#line 8324 "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
@@ -8210,7 +8331,7 @@
 jrKanjiControl()
 ; return 0; }
 EOF
-if { (eval echo configure:8214: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:8335: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -8259,12 +8380,12 @@
   libs_x="-lXm $libs_x" &&  if test "$extra_verbose" = "yes"; then echo "    Prepending \"-lXm\" to \$libs_x"; fi
     
 echo $ac_n "checking for layout_object_getvalue in -li18n""... $ac_c" 1>&6
-echo "configure:8263: checking for layout_object_getvalue in -li18n" >&5
+echo "configure:8384: checking for layout_object_getvalue in -li18n" >&5
 ac_lib_var=`echo i18n'_'layout_object_getvalue | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -li18n "
 cat > conftest.$ac_ext <<EOF
-#line 8268 "configure"
+#line 8389 "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
@@ -8275,7 +8396,7 @@
 layout_object_getvalue()
 ; return 0; }
 EOF
-if { (eval echo configure:8279: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:8400: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -8361,10 +8482,10 @@
 for ac_func in cbrt closedir dup2 eaccess fmod fpathconf frexp ftime gethostname getpagesize gettimeofday getcwd getwd logb lrand48 matherr mkdir mktime perror poll random rename res_init rint rmdir select setitimer setpgid setlocale setsid sigblock sighold sigprocmask snprintf strcasecmp strerror tzset ulimit usleep utimes waitpid vsnprintf
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:8365: checking for $ac_func" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 8368 "configure"
+echo "configure:8486: checking for $ac_func" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 8489 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -8387,7 +8508,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:8391: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:8512: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -8421,13 +8542,17 @@
    echo "    xemacs will be linked with \"realpath.o\""
  fi ;;
   * )
-    for ac_func in realpath
+    case "$canonical" in
+      *-*-sysv4.2uw2* ) extra_objs="$extra_objs realpath.o" &&  if test "$extra_verbose" = "yes"; then
+   echo "    xemacs will be linked with \"realpath.o\""
+ fi ;;
+      * ) for ac_func in realpath
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:8428: checking for $ac_func" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 8431 "configure"
+echo "configure:8553: checking for $ac_func" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 8556 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -8450,7 +8575,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:8454: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:8579: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -8477,22 +8602,23 @@
 fi
 done
 
-    test "$ac_cv_func_realpath" != "yes" && extra_objs="$extra_objs realpath.o" &&  if test "$extra_verbose" = "yes"; then
+	  test "$ac_cv_func_realpath" != "yes" && extra_objs="$extra_objs realpath.o" &&  if test "$extra_verbose" = "yes"; then
    echo "    xemacs will be linked with \"realpath.o\""
  fi ;;
+    esac ;;
 esac
 
 echo $ac_n "checking whether netdb declares h_errno""... $ac_c" 1>&6
-echo "configure:8487: checking whether netdb declares h_errno" >&5
-cat > conftest.$ac_ext <<EOF
-#line 8489 "configure"
+echo "configure:8613: checking whether netdb declares h_errno" >&5
+cat > conftest.$ac_ext <<EOF
+#line 8615 "configure"
 #include "confdefs.h"
 #include <netdb.h>
 int main() {
 return h_errno;
 ; return 0; }
 EOF
-if { (eval echo configure:8496: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:8622: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   echo "$ac_t""yes" 1>&6
    { test "$extra_verbose" = "yes" && cat << \EOF
@@ -8512,16 +8638,16 @@
 rm -f conftest*
 
 echo $ac_n "checking for sigsetjmp""... $ac_c" 1>&6
-echo "configure:8516: checking for sigsetjmp" >&5
-cat > conftest.$ac_ext <<EOF
-#line 8518 "configure"
+echo "configure:8642: checking for sigsetjmp" >&5
+cat > conftest.$ac_ext <<EOF
+#line 8644 "configure"
 #include "confdefs.h"
 #include <setjmp.h>
 int main() {
 sigjmp_buf bar; sigsetjmp (bar, 0);
 ; return 0; }
 EOF
-if { (eval echo configure:8525: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:8651: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   echo "$ac_t""yes" 1>&6
    { test "$extra_verbose" = "yes" && cat << \EOF
@@ -8541,11 +8667,11 @@
 rm -f conftest*
 
 echo $ac_n "checking whether localtime caches TZ""... $ac_c" 1>&6
-echo "configure:8545: checking whether localtime caches TZ" >&5
+echo "configure:8671: checking whether localtime caches TZ" >&5
 
 if test "$ac_cv_func_tzset" = "yes"; then
 cat > conftest.$ac_ext <<EOF
-#line 8549 "configure"
+#line 8675 "configure"
 #include "confdefs.h"
 #include <time.h>
 #if STDC_HEADERS
@@ -8580,7 +8706,7 @@
   exit (0);
 }
 EOF
-if { (eval echo configure:8584: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:8710: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   emacs_cv_localtime_cache=no
 else
@@ -8610,9 +8736,9 @@
 
 if test "$HAVE_TIMEVAL" = "yes"; then
 echo $ac_n "checking whether gettimeofday accepts one or two arguments""... $ac_c" 1>&6
-echo "configure:8614: checking whether gettimeofday accepts one or two arguments" >&5
-cat > conftest.$ac_ext <<EOF
-#line 8616 "configure"
+echo "configure:8740: checking whether gettimeofday accepts one or two arguments" >&5
+cat > conftest.$ac_ext <<EOF
+#line 8742 "configure"
 #include "confdefs.h"
 
 #ifdef TIME_WITH_SYS_TIME
@@ -8634,7 +8760,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:8638: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:8764: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   echo "$ac_t""two" 1>&6
 else
@@ -8656,19 +8782,19 @@
 
 
 echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:8660: checking for inline" >&5
+echo "configure:8786: checking for inline" >&5
 
 ac_cv_c_inline=no
 for ac_kw in inline __inline__ __inline; do
   cat > conftest.$ac_ext <<EOF
-#line 8665 "configure"
+#line 8791 "configure"
 #include "confdefs.h"
 
 int main() {
 } $ac_kw foo() {
 ; return 0; }
 EOF
-if { (eval echo configure:8672: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:8798: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_inline=$ac_kw; break
 else
@@ -8718,17 +8844,17 @@
 # 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:8722: checking for working alloca.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 8725 "configure"
+echo "configure:8848: checking for working alloca.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 8851 "configure"
 #include "confdefs.h"
 #include <alloca.h>
 int main() {
 char *p = alloca(2 * sizeof(int));
 ; return 0; }
 EOF
-if { (eval echo configure:8732: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:8858: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   ac_cv_header_alloca_h=yes
 else
@@ -8752,10 +8878,10 @@
 fi
 
 echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:8756: checking for alloca" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 8759 "configure"
+echo "configure:8882: checking for alloca" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 8885 "configure"
 #include "confdefs.h"
 
 #ifdef __GNUC__
@@ -8778,7 +8904,7 @@
 char *p = (char *) alloca(1);
 ; return 0; }
 EOF
-if { (eval echo configure:8782: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:8908: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   ac_cv_func_alloca_works=yes
 else
@@ -8817,10 +8943,10 @@
 
 
 echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:8821: checking whether alloca needs Cray hooks" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 8824 "configure"
+echo "configure:8947: checking whether alloca needs Cray hooks" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 8950 "configure"
 #include "confdefs.h"
 #if defined(CRAY) && ! defined(CRAY2)
 webecray
@@ -8844,10 +8970,10 @@
 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:8848: checking for $ac_func" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 8851 "configure"
+echo "configure:8974: checking for $ac_func" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 8977 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -8870,7 +8996,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:8874: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:9000: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -8900,10 +9026,10 @@
 fi
 
 echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:8904: checking stack direction for C alloca" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 8907 "configure"
+echo "configure:9030: checking stack direction for C alloca" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 9033 "configure"
 #include "confdefs.h"
 find_stack_direction ()
 {
@@ -8922,7 +9048,7 @@
   exit (find_stack_direction() < 0);
 }
 EOF
-if { (eval echo configure:8926: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:9052: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   ac_cv_c_stack_direction=1
 else
@@ -8951,15 +9077,15 @@
 
 ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for vfork.h""... $ac_c" 1>&6
-echo "configure:8955: checking for vfork.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 8958 "configure"
+echo "configure:9081: checking for vfork.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 9084 "configure"
 #include "confdefs.h"
 #include <vfork.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8963: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:9089: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -8987,10 +9113,10 @@
 fi
 
 echo $ac_n "checking for working vfork""... $ac_c" 1>&6
-echo "configure:8991: checking for working vfork" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 8994 "configure"
+echo "configure:9117: checking for working vfork" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 9120 "configure"
 #include "confdefs.h"
 /* Thanks to Paul Eggert for this test.  */
 #include <stdio.h>
@@ -9085,7 +9211,7 @@
   }
 }
 EOF
-if { (eval echo configure:9089: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:9215: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   ac_cv_func_vfork_works=yes
 else
@@ -9111,10 +9237,10 @@
 
 
 echo $ac_n "checking for working strcoll""... $ac_c" 1>&6
-echo "configure:9115: checking for working strcoll" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 9118 "configure"
+echo "configure:9241: checking for working strcoll" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 9244 "configure"
 #include "confdefs.h"
 #include <string.h>
 main ()
@@ -9124,7 +9250,7 @@
 	strcoll ("123", "456") >= 0);
 }
 EOF
-if { (eval echo configure:9128: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:9254: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   ac_cv_func_strcoll_works=yes
 else
@@ -9152,10 +9278,10 @@
 for ac_func in getpgrp
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:9156: checking for $ac_func" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 9159 "configure"
+echo "configure:9282: checking for $ac_func" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 9285 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -9178,7 +9304,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:9182: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:9308: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -9206,10 +9332,10 @@
 done
 
 echo $ac_n "checking whether getpgrp takes no argument""... $ac_c" 1>&6
-echo "configure:9210: checking whether getpgrp takes no argument" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 9213 "configure"
+echo "configure:9336: checking whether getpgrp takes no argument" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 9339 "configure"
 #include "confdefs.h"
 
 /*
@@ -9264,7 +9390,7 @@
 }
 
 EOF
-if { (eval echo configure:9268: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:9394: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   ac_cv_func_getpgrp_void=yes
 else
@@ -9291,10 +9417,10 @@
 
 
 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:9295: checking for working mmap" >&5
+echo "configure:9421: checking for working mmap" >&5
 case "$opsys" in ultrix* ) have_mmap=no ;; *)
 cat > conftest.$ac_ext <<EOF
-#line 9298 "configure"
+#line 9424 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 #include <unistd.h>
@@ -9327,7 +9453,7 @@
   return 1;
 }
 EOF
-if { (eval echo configure:9331: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:9457: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   have_mmap=yes
 else
@@ -9352,15 +9478,15 @@
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:9356: checking for $ac_hdr" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 9359 "configure"
+echo "configure:9482: checking for $ac_hdr" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 9485 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:9364: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:9490: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -9392,10 +9518,10 @@
 for ac_func in getpagesize
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:9396: checking for $ac_func" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 9399 "configure"
+echo "configure:9522: checking for $ac_func" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 9525 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -9418,7 +9544,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:9422: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:9548: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -9446,10 +9572,10 @@
 done
 
 echo $ac_n "checking for working mmap""... $ac_c" 1>&6
-echo "configure:9450: checking for working mmap" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 9453 "configure"
+echo "configure:9576: checking for working mmap" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 9579 "configure"
 #include "confdefs.h"
 
 /* Thanks to Mike Haertel and Jim Avera for this test.
@@ -9589,7 +9715,7 @@
 }
 
 EOF
-if { (eval echo configure:9593: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:9719: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   ac_cv_func_mmap_fixed_mapped=yes
 else
@@ -9627,15 +9753,15 @@
 
 ac_safe=`echo "termios.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for termios.h""... $ac_c" 1>&6
-echo "configure:9631: checking for termios.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 9634 "configure"
+echo "configure:9757: checking for termios.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 9760 "configure"
 #include "confdefs.h"
 #include <termios.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:9639: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:9765: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -9678,15 +9804,15 @@
   echo "$ac_t""no" 1>&6
 ac_safe=`echo "termio.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for termio.h""... $ac_c" 1>&6
-echo "configure:9682: checking for termio.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 9685 "configure"
+echo "configure:9808: checking for termio.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 9811 "configure"
 #include "confdefs.h"
 #include <termio.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:9690: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:9816: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -9718,10 +9844,10 @@
 
 
 echo $ac_n "checking for socket""... $ac_c" 1>&6
-echo "configure:9722: checking for socket" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 9725 "configure"
+echo "configure:9848: checking for socket" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 9851 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char socket(); below.  */
@@ -9744,7 +9870,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:9748: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:9874: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_socket=yes"
 else
@@ -9759,15 +9885,15 @@
   echo "$ac_t""yes" 1>&6
   ac_safe=`echo "netinet/in.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for netinet/in.h""... $ac_c" 1>&6
-echo "configure:9763: checking for netinet/in.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 9766 "configure"
+echo "configure:9889: checking for netinet/in.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 9892 "configure"
 #include "confdefs.h"
 #include <netinet/in.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:9771: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:9897: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -9784,15 +9910,15 @@
   echo "$ac_t""yes" 1>&6
   ac_safe=`echo "arpa/inet.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for arpa/inet.h""... $ac_c" 1>&6
-echo "configure:9788: checking for arpa/inet.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 9791 "configure"
+echo "configure:9914: checking for arpa/inet.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 9917 "configure"
 #include "confdefs.h"
 #include <arpa/inet.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:9796: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:9922: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -9817,9 +9943,9 @@
 }
 
       echo $ac_n "checking "for sun_len member in struct sockaddr_un"""... $ac_c" 1>&6
-echo "configure:9821: checking "for sun_len member in struct sockaddr_un"" >&5
+echo "configure:9947: checking "for sun_len member in struct sockaddr_un"" >&5
       cat > conftest.$ac_ext <<EOF
-#line 9823 "configure"
+#line 9949 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -9830,7 +9956,7 @@
 static struct sockaddr_un x; x.sun_len = 1;
 ; return 0; }
 EOF
-if { (eval echo configure:9834: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:9960: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   echo "$ac_t""yes" 1>&6; { test "$extra_verbose" = "yes" && cat << \EOF
     Defining HAVE_SOCKADDR_SUN_LEN
@@ -9848,9 +9974,9 @@
 fi
 rm -f conftest*
       echo $ac_n "checking "for ip_mreq struct in netinet/in.h"""... $ac_c" 1>&6
-echo "configure:9852: checking "for ip_mreq struct in netinet/in.h"" >&5
+echo "configure:9978: checking "for ip_mreq struct in netinet/in.h"" >&5
       cat > conftest.$ac_ext <<EOF
-#line 9854 "configure"
+#line 9980 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -9860,7 +9986,7 @@
 static struct ip_mreq x;
 ; return 0; }
 EOF
-if { (eval echo configure:9864: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:9990: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   echo "$ac_t""yes" 1>&6; { test "$extra_verbose" = "yes" && cat << \EOF
     Defining HAVE_MULTICAST
@@ -9891,10 +10017,10 @@
 
 
 echo $ac_n "checking for msgget""... $ac_c" 1>&6
-echo "configure:9895: checking for msgget" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 9898 "configure"
+echo "configure:10021: checking for msgget" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 10024 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char msgget(); below.  */
@@ -9917,7 +10043,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:9921: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:10047: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_msgget=yes"
 else
@@ -9932,15 +10058,15 @@
   echo "$ac_t""yes" 1>&6
   ac_safe=`echo "sys/ipc.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for sys/ipc.h""... $ac_c" 1>&6
-echo "configure:9936: checking for sys/ipc.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 9939 "configure"
+echo "configure:10062: checking for sys/ipc.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 10065 "configure"
 #include "confdefs.h"
 #include <sys/ipc.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:9944: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:10070: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -9957,15 +10083,15 @@
   echo "$ac_t""yes" 1>&6
   ac_safe=`echo "sys/msg.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for sys/msg.h""... $ac_c" 1>&6
-echo "configure:9961: checking for sys/msg.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 9964 "configure"
+echo "configure:10087: checking for sys/msg.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 10090 "configure"
 #include "confdefs.h"
 #include <sys/msg.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:9969: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:10095: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -10003,15 +10129,15 @@
 
 ac_safe=`echo "dirent.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for dirent.h""... $ac_c" 1>&6
-echo "configure:10007: checking for dirent.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 10010 "configure"
+echo "configure:10133: checking for dirent.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 10136 "configure"
 #include "confdefs.h"
 #include <dirent.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:10015: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:10141: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -10038,15 +10164,15 @@
   echo "$ac_t""no" 1>&6
 ac_safe=`echo "sys/dir.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for sys/dir.h""... $ac_c" 1>&6
-echo "configure:10042: checking for sys/dir.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 10045 "configure"
+echo "configure:10168: checking for sys/dir.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 10171 "configure"
 #include "confdefs.h"
 #include <sys/dir.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:10050: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:10176: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -10079,15 +10205,15 @@
 
 ac_safe=`echo "nlist.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for nlist.h""... $ac_c" 1>&6
-echo "configure:10083: checking for nlist.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 10086 "configure"
+echo "configure:10209: checking for nlist.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 10212 "configure"
 #include "confdefs.h"
 #include <nlist.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:10091: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:10217: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -10117,7 +10243,7 @@
 
 
 echo "checking "for sound support"" 1>&6
-echo "configure:10121: checking "for sound support"" >&5
+echo "configure:10247: checking "for sound support"" >&5
 case "$with_sound" in
   native | both ) with_native_sound=yes;;
   nas    | no   ) with_native_sound=no;;
@@ -10128,15 +10254,15 @@
     if test -n "$native_sound_lib"; then
     ac_safe=`echo "multimedia/audio_device.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for multimedia/audio_device.h""... $ac_c" 1>&6
-echo "configure:10132: checking for multimedia/audio_device.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 10135 "configure"
+echo "configure:10258: checking for multimedia/audio_device.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 10261 "configure"
 #include "confdefs.h"
 #include <multimedia/audio_device.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:10140: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:10266: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -10184,12 +10310,12 @@
       if test -z "$native_sound_lib"; then
         
 echo $ac_n "checking for ALopenport in -laudio""... $ac_c" 1>&6
-echo "configure:10188: checking for ALopenport in -laudio" >&5
+echo "configure:10314: checking for ALopenport in -laudio" >&5
 ac_lib_var=`echo audio'_'ALopenport | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -laudio "
 cat > conftest.$ac_ext <<EOF
-#line 10193 "configure"
+#line 10319 "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
@@ -10200,7 +10326,7 @@
 ALopenport()
 ; return 0; }
 EOF
-if { (eval echo configure:10204: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:10330: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -10231,12 +10357,12 @@
       if test -z "$native_sound_lib"; then
 	
 echo $ac_n "checking for AOpenAudio in -lAlib""... $ac_c" 1>&6
-echo "configure:10235: checking for AOpenAudio in -lAlib" >&5
+echo "configure:10361: checking for AOpenAudio in -lAlib" >&5
 ac_lib_var=`echo Alib'_'AOpenAudio | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lAlib "
 cat > conftest.$ac_ext <<EOF
-#line 10240 "configure"
+#line 10366 "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
@@ -10247,7 +10373,7 @@
 AOpenAudio()
 ; return 0; }
 EOF
-if { (eval echo configure:10251: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:10377: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -10285,15 +10411,15 @@
     for dir in "machine" "sys" "linux"; do
       ac_safe=`echo "${dir}/soundcard.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for ${dir}/soundcard.h""... $ac_c" 1>&6
-echo "configure:10289: checking for ${dir}/soundcard.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 10292 "configure"
+echo "configure:10415: checking for ${dir}/soundcard.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 10418 "configure"
 #include "confdefs.h"
 #include <${dir}/soundcard.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:10297: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:10423: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -10363,7 +10489,7 @@
  fi
   libs_x="-laudio $libs_x" &&  if test "$extra_verbose" = "yes"; then echo "    Prepending \"-laudio\" to \$libs_x"; fi
       cat > conftest.$ac_ext <<EOF
-#line 10367 "configure"
+#line 10493 "configure"
 #include "confdefs.h"
 #include <audio/Xtutil.h>
 EOF
@@ -10390,7 +10516,7 @@
 
 if test "$with_tty" = "yes"  ; then
   echo "checking for TTY-related features" 1>&6
-echo "configure:10394: checking for TTY-related features" >&5
+echo "configure:10520: checking for TTY-related features" >&5
   { test "$extra_verbose" = "yes" && cat << \EOF
     Defining HAVE_TTY
 EOF
@@ -10406,12 +10532,12 @@
     if test -z "$with_ncurses"; then
     
 echo $ac_n "checking for tgetent in -lncurses""... $ac_c" 1>&6
-echo "configure:10410: checking for tgetent in -lncurses" >&5
+echo "configure:10536: checking for tgetent in -lncurses" >&5
 ac_lib_var=`echo ncurses'_'tgetent | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lncurses "
 cat > conftest.$ac_ext <<EOF
-#line 10415 "configure"
+#line 10541 "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
@@ -10422,7 +10548,7 @@
 tgetent()
 ; return 0; }
 EOF
-if { (eval echo configure:10426: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:10552: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -10455,15 +10581,15 @@
 
     ac_safe=`echo "ncurses/curses.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for ncurses/curses.h""... $ac_c" 1>&6
-echo "configure:10459: checking for ncurses/curses.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 10462 "configure"
+echo "configure:10585: checking for ncurses/curses.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 10588 "configure"
 #include "confdefs.h"
 #include <ncurses/curses.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:10467: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:10593: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -10485,15 +10611,15 @@
 
     ac_safe=`echo "ncurses/term.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for ncurses/term.h""... $ac_c" 1>&6
-echo "configure:10489: checking for ncurses/term.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 10492 "configure"
+echo "configure:10615: checking for ncurses/term.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 10618 "configure"
 #include "confdefs.h"
 #include <ncurses/term.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:10497: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:10623: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -10523,15 +10649,15 @@
       c_switch_site="$c_switch_site -I/usr/include/ncurses"
       ac_safe=`echo "ncurses/curses.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for ncurses/curses.h""... $ac_c" 1>&6
-echo "configure:10527: checking for ncurses/curses.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 10530 "configure"
+echo "configure:10653: checking for ncurses/curses.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 10656 "configure"
 #include "confdefs.h"
 #include <ncurses/curses.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:10535: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:10661: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -10566,12 +10692,12 @@
 	for lib in curses termlib termcap; do
 	  
 echo $ac_n "checking for tgetent in -l$lib""... $ac_c" 1>&6
-echo "configure:10570: checking for tgetent in -l$lib" >&5
+echo "configure:10696: checking for tgetent in -l$lib" >&5
 ac_lib_var=`echo $lib'_'tgetent | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -l$lib "
 cat > conftest.$ac_ext <<EOF
-#line 10575 "configure"
+#line 10701 "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
@@ -10582,7 +10708,7 @@
 tgetent()
 ; return 0; }
 EOF
-if { (eval echo configure:10586: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:10712: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -10613,12 +10739,12 @@
       else
 	
 echo $ac_n "checking for tgetent in -lcurses""... $ac_c" 1>&6
-echo "configure:10617: checking for tgetent in -lcurses" >&5
+echo "configure:10743: checking for tgetent in -lcurses" >&5
 ac_lib_var=`echo curses'_'tgetent | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lcurses "
 cat > conftest.$ac_ext <<EOF
-#line 10622 "configure"
+#line 10748 "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
@@ -10629,7 +10755,7 @@
 tgetent()
 ; return 0; }
 EOF
-if { (eval echo configure:10633: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:10759: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -10647,12 +10773,12 @@
 else
   echo "$ac_t""no" 1>&6
 echo $ac_n "checking for tgetent in -ltermcap""... $ac_c" 1>&6
-echo "configure:10651: checking for tgetent in -ltermcap" >&5
+echo "configure:10777: checking for tgetent in -ltermcap" >&5
 ac_lib_var=`echo termcap'_'tgetent | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -ltermcap "
 cat > conftest.$ac_ext <<EOF
-#line 10656 "configure"
+#line 10782 "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
@@ -10663,7 +10789,7 @@
 tgetent()
 ; return 0; }
 EOF
-if { (eval echo configure:10667: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:10793: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -10711,15 +10837,15 @@
 
     test -z "$with_gpm" && { ac_safe=`echo "gpm.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for gpm.h""... $ac_c" 1>&6
-echo "configure:10715: checking for gpm.h" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 10718 "configure"
+echo "configure:10841: checking for gpm.h" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 10844 "configure"
 #include "confdefs.h"
 #include <gpm.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:10723: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:10849: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -10742,12 +10868,12 @@
  }
   test -z "$with_gpm" && { 
 echo $ac_n "checking for Gpm_Open in -lgpm""... $ac_c" 1>&6
-echo "configure:10746: checking for Gpm_Open in -lgpm" >&5
+echo "configure:10872: checking for Gpm_Open in -lgpm" >&5
 ac_lib_var=`echo gpm'_'Gpm_Open | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lgpm "
 cat > conftest.$ac_ext <<EOF
-#line 10751 "configure"
+#line 10877 "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
@@ -10758,7 +10884,7 @@
 Gpm_Open()
 ; return 0; }
 EOF
-if { (eval echo configure:10762: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:10888: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -10807,22 +10933,22 @@
 
 
 echo "checking for database support" 1>&6
-echo "configure:10811: checking for database support" >&5
+echo "configure:10937: checking for database support" >&5
 
 if test "$with_database_gnudbm" != "no"; then
   for ac_hdr in ndbm.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:10818: checking for $ac_hdr" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 10821 "configure"
+echo "configure:10944: checking for $ac_hdr" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 10947 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:10826: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:10952: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -10854,12 +10980,12 @@
   if test "$have_ndbm_h" = "yes"; then
     
 echo $ac_n "checking for dbm_open in -lgdbm""... $ac_c" 1>&6
-echo "configure:10858: checking for dbm_open in -lgdbm" >&5
+echo "configure:10984: checking for dbm_open in -lgdbm" >&5
 ac_lib_var=`echo gdbm'_'dbm_open | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lgdbm "
 cat > conftest.$ac_ext <<EOF
-#line 10863 "configure"
+#line 10989 "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
@@ -10870,7 +10996,7 @@
 dbm_open()
 ; return 0; }
 EOF
-if { (eval echo configure:10874: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:11000: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -10893,10 +11019,10 @@
   fi
   if test "$with_database_gnudbm" != "yes"; then
     echo $ac_n "checking for dbm_open""... $ac_c" 1>&6
-echo "configure:10897: checking for dbm_open" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 10900 "configure"
+echo "configure:11023: checking for dbm_open" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 11026 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char dbm_open(); below.  */
@@ -10919,7 +11045,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:10923: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:11049: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_dbm_open=yes"
 else
@@ -10955,10 +11081,10 @@
 
 if test "$with_database_dbm" != "no"; then
   echo $ac_n "checking for dbm_open""... $ac_c" 1>&6
-echo "configure:10959: checking for dbm_open" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 10962 "configure"
+echo "configure:11085: checking for dbm_open" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 11088 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char dbm_open(); below.  */
@@ -10981,7 +11107,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:10985: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:11111: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_dbm_open=yes"
 else
@@ -11002,12 +11128,12 @@
   if test "$need_libdbm" != "no"; then
     
 echo $ac_n "checking for dbm_open in -ldbm""... $ac_c" 1>&6
-echo "configure:11006: checking for dbm_open in -ldbm" >&5
+echo "configure:11132: checking for dbm_open in -ldbm" >&5
 ac_lib_var=`echo dbm'_'dbm_open | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -ldbm "
 cat > conftest.$ac_ext <<EOF
-#line 11011 "configure"
+#line 11137 "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
@@ -11018,7 +11144,7 @@
 dbm_open()
 ; return 0; }
 EOF
-if { (eval echo configure:11022: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:11148: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -11055,10 +11181,10 @@
 
 if test "$with_database_berkdb" != "no"; then
   echo $ac_n "checking for Berkeley db.h""... $ac_c" 1>&6
-echo "configure:11059: checking for Berkeley db.h" >&5
+echo "configure:11185: checking for Berkeley db.h" >&5
   for path in "db/db.h" "db.h"; do
     cat > conftest.$ac_ext <<EOF
-#line 11062 "configure"
+#line 11188 "configure"
 #include "confdefs.h"
 #ifdef HAVE_INTTYPES_H
 #define __BIT_TYPES_DEFINED__
@@ -11076,7 +11202,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:11080: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:11206: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   db_h_path="$path"; break
 else
@@ -11092,9 +11218,9 @@
 
   if test "$with_database_berkdb" != "no"; then
     echo $ac_n "checking for Berkeley DB version""... $ac_c" 1>&6
-echo "configure:11096: checking for Berkeley DB version" >&5
+echo "configure:11222: checking for Berkeley DB version" >&5
     cat > conftest.$ac_ext <<EOF
-#line 11098 "configure"
+#line 11224 "configure"
 #include "confdefs.h"
 #include <$db_h_path>
 #if DB_VERSION_MAJOR > 1
@@ -11113,10 +11239,10 @@
 rm -f conftest*
 
     echo $ac_n "checking for $dbfunc""... $ac_c" 1>&6
-echo "configure:11117: checking for $dbfunc" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 11120 "configure"
+echo "configure:11243: checking for $dbfunc" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 11246 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $dbfunc(); below.  */
@@ -11139,7 +11265,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:11143: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:11269: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_$dbfunc=yes"
 else
@@ -11158,12 +11284,12 @@
 
     
 echo $ac_n "checking for $dbfunc in -ldb""... $ac_c" 1>&6
-echo "configure:11162: checking for $dbfunc in -ldb" >&5
+echo "configure:11288: checking for $dbfunc in -ldb" >&5
 ac_lib_var=`echo db'_'$dbfunc | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -ldb "
 cat > conftest.$ac_ext <<EOF
-#line 11167 "configure"
+#line 11293 "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
@@ -11174,7 +11300,7 @@
 $dbfunc()
 ; return 0; }
 EOF
-if { (eval echo configure:11178: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:11304: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -11238,12 +11364,12 @@
 if test "$with_socks" = "yes"; then
   
 echo $ac_n "checking for SOCKSinit in -lsocks""... $ac_c" 1>&6
-echo "configure:11242: checking for SOCKSinit in -lsocks" >&5
+echo "configure:11368: checking for SOCKSinit in -lsocks" >&5
 ac_lib_var=`echo socks'_'SOCKSinit | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lsocks "
 cat > conftest.$ac_ext <<EOF
-#line 11247 "configure"
+#line 11373 "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
@@ -11254,7 +11380,7 @@
 SOCKSinit()
 ; return 0; }
 EOF
-if { (eval echo configure:11258: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:11384: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -11313,15 +11439,15 @@
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:11317: checking for $ac_hdr" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 11320 "configure"
+echo "configure:11443: checking for $ac_hdr" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 11446 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:11325: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:11451: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -11352,12 +11478,12 @@
 
 test -z "$with_shlib" && test ! -z "$have_dlfcn" && { 
 echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
-echo "configure:11356: checking for dlopen in -ldl" >&5
+echo "configure:11482: checking for dlopen in -ldl" >&5
 ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -ldl "
 cat > conftest.$ac_ext <<EOF
-#line 11361 "configure"
+#line 11487 "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
@@ -11368,7 +11494,7 @@
 dlopen()
 ; return 0; }
 EOF
-if { (eval echo configure:11372: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:11498: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -11397,12 +11523,12 @@
  }
 test -z "$with_shlib" && test ! -z "$have_dlfcn" && { 
 echo $ac_n "checking for _dlopen in -lc""... $ac_c" 1>&6
-echo "configure:11401: checking for _dlopen in -lc" >&5
+echo "configure:11527: checking for _dlopen in -lc" >&5
 ac_lib_var=`echo c'_'_dlopen | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lc "
 cat > conftest.$ac_ext <<EOF
-#line 11406 "configure"
+#line 11532 "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
@@ -11413,7 +11539,7 @@
 _dlopen()
 ; return 0; }
 EOF
-if { (eval echo configure:11417: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:11543: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -11442,12 +11568,12 @@
  }
 test -z "$with_shlib" && test ! -z "$have_dlfcn" && { 
 echo $ac_n "checking for dlopen in -lc""... $ac_c" 1>&6
-echo "configure:11446: checking for dlopen in -lc" >&5
+echo "configure:11572: checking for dlopen in -lc" >&5
 ac_lib_var=`echo c'_'dlopen | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -lc "
 cat > conftest.$ac_ext <<EOF
-#line 11451 "configure"
+#line 11577 "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
@@ -11458,7 +11584,7 @@
 dlopen()
 ; return 0; }
 EOF
-if { (eval echo configure:11462: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:11588: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -11487,12 +11613,12 @@
  }
 test -z "$with_shlib" && { 
 echo $ac_n "checking for shl_load in -ldld""... $ac_c" 1>&6
-echo "configure:11491: checking for shl_load in -ldld" >&5
+echo "configure:11617: checking for shl_load in -ldld" >&5
 ac_lib_var=`echo dld'_'shl_load | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -ldld "
 cat > conftest.$ac_ext <<EOF
-#line 11496 "configure"
+#line 11622 "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
@@ -11503,7 +11629,7 @@
 shl_load()
 ; return 0; }
 EOF
-if { (eval echo configure:11507: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:11633: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -11532,12 +11658,12 @@
  }
 test -z "$with_shlib" && { 
 echo $ac_n "checking for dld_init in -ldld""... $ac_c" 1>&6
-echo "configure:11536: checking for dld_init in -ldld" >&5
+echo "configure:11662: checking for dld_init in -ldld" >&5
 ac_lib_var=`echo dld'_'dld_init | sed 'y%./+-%__p_%'`
 
 xe_check_libs=" -ldld "
 cat > conftest.$ac_ext <<EOF
-#line 11541 "configure"
+#line 11667 "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
@@ -11548,7 +11674,7 @@
 dld_init()
 ; return 0; }
 EOF
-if { (eval echo configure:11552: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:11678: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -11598,7 +11724,7 @@
 dll_oflags="-o "
 
 echo $ac_n "checking how to build a shared library""... $ac_c" 1>&6
-echo "configure:11602: checking how to build a shared library" >&5
+echo "configure:11728: checking how to build a shared library" >&5
 case `uname -rs` in
 	UNIX_SV*|UNIX_System_V*)
 		dll_lflags="-G"
@@ -11689,10 +11815,10 @@
   for ac_func in dlerror
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:11693: checking for $ac_func" >&5
-
-cat > conftest.$ac_ext <<EOF
-#line 11696 "configure"
+echo "configure:11819: checking for $ac_func" >&5
+
+cat > conftest.$ac_ext <<EOF
+#line 11822 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -11715,7 +11841,7 @@
 
 ; return 0; }
 EOF
-if { (eval echo configure:11719: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:11845: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -11751,11 +11877,11 @@
 fi
 
 cat > conftest.$ac_ext <<EOF
-#line 11755 "configure"
+#line 11881 "configure"
 #include "confdefs.h"
 int main(int c,char *v[]){return 0;}
 EOF
-if { (eval echo configure:11759: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
+if { (eval echo configure:11885: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit $?) 2>&5
 then
   :
 else
--- a/configure.in	Mon Aug 13 11:04:53 2007 +0200
+++ b/configure.in	Mon Aug 13 11:05:42 2007 +0200
@@ -1325,6 +1325,13 @@
     NON_GNU_CPP=/usr/ccs/lib/cpp
   ;;
 
+  dnl NEC
+  mips-nec-sysv*)
+    machine=mips-nec
+    NON_GNU_CC=/usr/ccs/bin/cc
+    NON_GNU_CPP=/usr/ccs/lib/cpp
+  ;;
+
   dnl Silicon Graphics machines
   dnl Iris 2500 and Iris 2500 Turbo (aka the Iris 3030)
   m68*-sgi-iris3.5* ) machine=irist opsys=iris3-5 ;;
@@ -1482,6 +1489,9 @@
   dnl Linux/68k
   m68k-*-linux* ) machine=m68k opsys=linux ;;
 
+  dnl Linux/arm
+  arm-*-linux* ) machine=arm opsys=linux ;;
+
 esac
 
 if test -z "$machine" -o -z "$opsys"; then
@@ -1917,8 +1927,8 @@
   dnl and whether it works (or at least does no harm)
   AC_MSG_CHECKING("for runtime libraries flag")
   case "$opsys" in
-    sol2 ) dash_r = "-R" ;;
-    decosf* | linux* ) dash_r = "-rpath " ;;
+    sol2 ) dash_r="-R" ;;
+    decosf* | linux* ) dash_r="-rpath " ;;
     *)
       dash_r=""
       for try_dash_r in "-R" "-R " "-rpath "; do
@@ -2081,7 +2091,7 @@
 
 dnl checks for header files
 AC_CHECK_HEADERS(mach/mach.h sys/stropts.h sys/timeb.h sys/time.h unistd.h)
-AC_CHECK_HEADERS(utime.h locale.h libgen.h fcntl.h ulimit.h cygwin32/version.h)
+AC_CHECK_HEADERS(utime.h locale.h libgen.h fcntl.h ulimit.h cygwin/version.h)
 AC_CHECK_HEADERS(linux/version.h kstat.h sys/pstat.h inttypes.h sys/un.h a.out.h)
 AC_HEADER_SYS_WAIT
 AC_HEADER_STDC
@@ -3003,14 +3013,19 @@
     test "$ac_cv_func_crypt" != "yes" && { AC_CHECK_LIB(crypt, crypt) }
   fi
   dnl Back to our regularly scheduled wnn hunting
-  test -z "$with_wnn" && { AC_CHECK_LIB(wnn,jl_dic_list_e,[:],with_wnn=no) }
+  if test -z "$with_wnn" -o "$with_wnn" = "yes"; then
+    AC_CHECK_LIB(wnn,jl_dic_list_e,libwnn=wnn,
+      AC_CHECK_LIB(wnn4,jl_dic_list_e,libwnn=wnn4,
+	AC_CHECK_LIB(wnn6,jl_dic_list_e,libwnn=wnn6,
+	  AC_CHECK_LIB(wnn6_fromsrc,dic_list_e,libwnn=wnn6_fromsrc,with_wnn=no))))
+  fi
   test -z "$with_wnn" && with_wnn=yes
   if test "$with_wnn" = "yes"; then
     AC_DEFINE(HAVE_WNN)
-    XE_PREPEND(-lwnn, libs_x)
+    XE_PREPEND(-l$libwnn, libs_x)
     XE_ADD_OBJS(mule-wnnfns.o)
     if test "$with_wnn6" != "no"; then
-      AC_CHECK_LIB(wnn, jl_fi_dic_list, with_wnn6=yes)
+      AC_CHECK_LIB($libwnn, jl_fi_dic_list, with_wnn6=yes)
       test "$with_wnn6" = "yes" && AC_DEFINE(WNN6)
     fi
   fi
@@ -3068,11 +3083,15 @@
 dnl For example, call realpath on a file thirty-five or so directories deep
 dnl and you get ELOOP even if no symlinks at all are involved.
 dnl Reports as of 11/1997 indicate BSDi has problems too.
+dnl The realpath() in UnixWare2.1.3 could not get any pathname fragment in error condition.
 case "$opsys" in
   linuxaout* | bsdos3* | freebsd* | decosf4-0* | aix4* ) XE_ADD_OBJS(realpath.o) ;;
   * )
-    AC_CHECK_FUNCS(realpath)
-    test "$ac_cv_func_realpath" != "yes" && XE_ADD_OBJS(realpath.o) ;;
+    case "$canonical" in
+      *-*-sysv4.2uw2* ) XE_ADD_OBJS(realpath.o) ;;
+      * ) AC_CHECK_FUNCS(realpath)
+	  test "$ac_cv_func_realpath" != "yes" && XE_ADD_OBJS(realpath.o) ;;
+    esac ;;
 esac
 
 dnl If netdb.h does not declare h_errno, we must declare it by hand.
--- a/etc/NEWS	Mon Aug 13 11:04:53 2007 +0200
+++ b/etc/NEWS	Mon Aug 13 11:05:42 2007 +0200
@@ -33,7 +33,7 @@
 * Changes in XEmacs 21.2
 ========================
 
-*** You can now create an "indirect buffer", like in GNU Emacs.  An
+** You can now create "indirect buffers", like in GNU Emacs.  An
 indirect buffer shares its text with another buffer ("base buffer"),
 but has its own major mode, local variables, extents, and narrowing.
 An indirect buffer has a name of its own, distinct from those of the
@@ -53,9 +53,13 @@
 indirect).  `buffer-indirect-children' returns a list of the indirect
 children of a base buffer.
 
-#### The library `noutline' has versions of Outline mode and Outline
-minor mode which let you display different parts of the outline in
-different indirect buffers.
+
+* Lisp and internal changes in XEmacs 21.0
+==========================================
+
+** Functions for decoding base64 encoding are now available; see
+`base64-encode-region', `base64-encode-string', `base64-decode-region'
+and `base64-decode-string'.
 
 
 * Changes in XEmacs 21.0
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/etc/package-index.LATEST.pgp	Mon Aug 13 11:05:42 2007 +0200
@@ -0,0 +1,1819 @@
+-----BEGIN PGP SIGNED MESSAGE-----
+
+;; Package Index file -- Do not edit manually.
+;;;@@@
+(package-get-update-base-entry (quote
+(zenirc
+  (standards-version 1.0
+   version "1.04"
+   author-version "2.112"
+   date "1998-08-15"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "comm"
+   dump nil
+   description "ZENIRC IRC Client."
+   filename "zenirc-1.04-pkg.tar.gz"
+   md5sum "96d9e09c41de5c19d8aa092ad544ad6d"
+   size 276116
+   provides (zenirc)
+   requires (zenirc)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(w3
+  (standards-version 1.0
+   version "1.10"
+   author-version "4.0pre23"
+   date "1998-07-18"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution experimental
+   priority high
+   category "comm"
+   dump nil
+   description "A Web browser."
+   filename "w3-1.10-pkg.tar.gz"
+   md5sum "6113b455f82c5903b8bd6f4ca48afb00"
+   size 612442
+   provides (w3 url)
+   requires (w3 mail-lib xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(vm
+  (standards-version 1.0
+   version "1.14"
+   author-version "6.62"
+   date "1998-09-22"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "comm"
+   dump nil
+   description "An Emacs mailer."
+   filename "vm-1.14-pkg.tar.gz"
+   md5sum "e59383b955243ca90581fd6854bb5eff"
+   size 548815
+   provides (vm)
+   requires (mail-lib xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(tm
+  (standards-version 1.0
+   version "1.15"
+   author-version "21.0"
+   date "1998-08-27"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "comm"
+   dump nil
+   description "Emacs MIME support."
+   filename "tm-1.15-pkg.tar.gz"
+   md5sum "7769db3ab1473811a0622742c3e9bf69"
+   size 329539
+   provides (tm tm-edit tm-view mime-setup)
+   requires (gnus mh-e rmail vm mailcrypt mail-lib apel xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(supercite
+  (standards-version 1.0
+   version "1.10"
+   author-version "3.55x2"
+   date "1998-08-9"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "comm"
+   dump nil
+   description "An Emacs citation tool for News & Mail messages."
+   filename "supercite-1.10-pkg.tar.gz"
+   md5sum "09dee2a7f1400bc8680ea067a2399dcb"
+   size 99403
+   provides (supercite)
+   requires (mail-lib xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(rmail
+  (standards-version 1.0
+   version "1.07"
+   author-version "21.0"
+   date "1998-06-28"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution contrib
+   priority low
+   category "comm"
+   dump nil
+   description "An obsolete Emacs mailer."
+   filename "rmail-1.07-pkg.tar.gz"
+   md5sum "0b256dc4b02e832d939850f86951217a"
+   size 96475
+   provides (rmail rmailsum)
+   requires (tm apel mail-lib xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(mew
+  (standards-version 1.0
+   version "1.04"
+   author-version "1.93b38"
+   date "1998-06-21"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution contrib
+   priority low
+   category "comm"
+   dump nil
+   description "Messaging in an Emacs World."
+   filename "mew-1.04-pkg.tar.gz"
+   md5sum "896793a5d91c0ecfe4af5a7351f82fb7"
+   size 517164
+   provides (mew)
+   requires (mew)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(net-utils
+  (standards-version 1.0
+   version "1.10"
+   author-version "21.0"
+   date "1998-07-01"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "comm"
+   dump nil
+   description "Miscellaneous Networking Utilities."
+   filename "net-utils-1.10-pkg.tar.gz"
+   md5sum "89f6d1830b90e701ab57fcadd7337bb8"
+   size 107129
+   provides (ilisp-browse-cltl2 emacsbug feedmail metamail net-utils rcompile shadowfile webjump webster-www)
+   requires (w3 efs mail-lib xemacs-base)
+   type single
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(mh-e
+  (standards-version 1.0
+   version "1.08"
+   author-version "21.0"
+   date "1998-07-12"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution contrib
+   priority low
+   category "comm"
+   dump nil
+   description "Front end support for MH."
+   filename "mh-e-1.08-pkg.tar.gz"
+   md5sum "f1995b0f516668922a5f4331d0c13187"
+   size 176392
+   provides (mh-e)
+   requires (mail-lib xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(mailcryptng
+  (standards-version 1.0
+   version "1.01"
+   author-version "3.5b7"
+   date "1998-10-10"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "comm"
+   dump nil
+   description "Support for messaging encryption with PGP."
+   filename "mailcryptng-1.01-pkg.tar.gz"
+   md5sum "70bbfabaa083dc3a6178aa2be979705e"
+   size 120414
+   provides (mailcrypt)
+   requires (gnus vm mail-lib fsf-compat xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(mailcrypt
+  (standards-version 1.0
+   version "1.06"
+   author-version "3.4"
+   date "1998-01-24"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "comm"
+   dump nil
+   description "Support for messaging encryption with PGP."
+   filename "mailcrypt-1.06-pkg.tar.gz"
+   md5sum "e601fc5c1f43c5b7f577c7262c7877a9"
+   size 106355
+   provides (mailcrypt)
+   requires (gnus vm mail-lib xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(irchat
+  (standards-version 1.0
+   version "1.03"
+   author-version "980625-2"
+   date "1998-09-08"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "comm"
+   dump nil
+   description "ZENIRC IRC Client."
+   filename "irchat-1.03-pkg.tar.gz"
+   md5sum "9d066b2d79ab2dd5e01e1b8733289aa4"
+   size 219214
+   provides (irchat)
+   requires ()
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(gnats
+  (standards-version 1.0
+   version "1.07"
+   author-version "3.101"
+   date "1998-08-01"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority high
+   category "comm"
+   dump nil
+   description "XEmacs bug reports."
+   filename "gnats-1.07-pkg.tar.gz"
+   md5sum "40d23fbac2ea05d55be0d0822259b023"
+   size 189213
+   provides (gnats gnats-admin send-pr)
+   requires (mail-lib xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(footnote
+  (standards-version 1.0
+   version "1.07"
+   author-version "0.18x"
+   date "1998-08-27"
+   build-date "1998-10-12"
+   maintainer "SL Baur <steve@xemacs.org>"
+   distribution stable
+   priority low
+   category "comm"
+   dump nil
+   description "Footnoting in mail message editing modes."
+   filename "footnote-1.07-pkg.tar.gz"
+   md5sum "1064b49b7e13a467458af2bafd9e62fb"
+   size 13362
+   provides (footnote)
+   requires (mail-lib xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(eudc
+  (standards-version 1.0
+   version "1.24"
+   author-version "1.24"
+   date "1998-10-15"
+   build-date "1998-10-15"
+   maintainer "Oscar Figueiredo <Oscar.Figueiredo@epfl.ch>"
+   distribution stable
+   priority low
+   category "comm"
+   dump nil
+   description "Emacs Unified Directory Client (LDAP, PH)."
+   filename "eudc-1.24-pkg.tar.gz"
+   md5sum "43c173e7e052c81b196c617fb22b6e00"
+   size 50837
+   provides (eudc eudc-ldap eudc-ph)
+   requires (fsf-compat xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(bbdb
+  (standards-version 1.0
+   version "1.06"
+   author-version "2.00.02"
+   date "1998-10-08"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "comm"
+   dump nil
+   description "The Big Brother Data Base"
+   filename "bbdb-1.06-pkg.tar.gz"
+   md5sum "4889d21fded3ae5cddee558e0d136a20"
+   size 281992
+   provides (bbdb)
+   requires (bbdb edit-utils gnus mh-e rmail supercite vm tm apel mail-lib xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(gnus
+  (standards-version 1.0
+   version "1.33"
+   author-version "5.6.44"
+   date "1998-09-25"
+   build-date "1998-10-15"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "comm"
+   dump nil
+   description "The Gnus Newsreader and Mailreader."
+   filename "gnus-1.33-pkg.tar.gz"
+   md5sum "46a0466ec203cd7b0d78bfeb215a65f5"
+   size 1874633
+   provides (gnus message)
+   requires (gnus w3 mh-e mailcrypt rmail mail-lib xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(skk
+  (standards-version 1.0
+   version "1.11"
+   author-version "10.38"
+   date "1998-10-01"
+   build-date "1998-10-12"
+   maintainer "SL Baur <steve@altair.xemacs.org>"
+   distribution mule
+   priority medium
+   category "mule"
+   dump t
+   description "Japanese Language Input Method."
+   filename "skk-1.11-pkg.tar.gz"
+   md5sum "c158751b558299be9b5f8f9d10216a79"
+   size 1513975
+   provides (skk skk-tut)
+   requires (viper mule-base elib xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(mule-base
+  (standards-version 1.0
+   version "1.24"
+   author-version "21.0"
+   date "1998-08-12"
+   build-date "1998-10-12"
+   maintainer "SL Baur <steve@altair.xemacs.org>"
+   distribution mule
+   priority high
+   category "mule"
+   dump t
+   description "Basic Mule support, required for building with Mule."
+   filename "mule-base-1.24-pkg.tar.gz"
+   md5sum "9842af89469856fa1c7f3ed60c8c25cf"
+   size 508959
+   provides (canna-leim canna char-table china-util cyril-util isearch-ext japan-util ccl can-n-egg mule-help)
+   requires (fsf-compat xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(egg-its
+  (standards-version 1.0
+   version "1.13"
+   author-version "21.0"
+   date "1998-08-11"
+   build-date "1998-10-15"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution mule
+   priority high
+   category "mule"
+   dump t
+   description "Wnn (4.2 and 6) support.  SJ3 support."
+   filename "egg-its-1.13-pkg.tar.gz"
+   md5sum "e7a5d51eb734310b9bb151c4fba05868"
+   size 259686
+   provides (egg-cnpinyin egg-cnzhuyin egg-cwnn-leim egg-jisx0201 egg-jsymbol egg-kwnn-leim egg-leim egg-sj3-client egg-sj3-leim egg-sj3 egg-wnn egg)
+   requires (leim mule-base fsf-compat xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(edict
+  (standards-version 1.0
+   version "1.06"
+   author-version "0.9.8"
+   date "1998-07-23"
+   build-date "1998-10-12"
+   maintainer "Stephen J. Turnbull <turnbull@sk.tsukuba.ac.jp>"
+   distribution mule
+   priority high
+   category "mule"
+   dump nil
+   description "Lisp Interface to EDICT, Kanji Dictionary"
+   filename "edict-1.06-pkg.tar.gz"
+   md5sum "d9ba0f5372b2b83fe1499d1462dad3ca"
+   size 68008
+   provides (dui-registry dui edict-edit edict-english edict-japanese edict-morphology edict-test edict ts-mode)
+   requires (mule-base xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(leim
+  (standards-version 1.0
+   version "1.11"
+   author-version "21.0"
+   date "1998-07-23"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution mule
+   priority medium
+   category "mule"
+   dump nil
+   description "Quail.  All non-English and non-Japanese language support."
+   filename "leim-1.11-pkg.tar.gz"
+   md5sum "19f4745d0364b46c7526a34777c653e5"
+   size 1670560
+   provides ()
+   requires (mule-base fsf-compat xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(locale
+  (standards-version 1.0
+   version "1.10"
+   author-version "21.0"
+   date "1998-07-24"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution mule
+   priority high
+   category "mule"
+   dump nil
+   description "Localized menubars and localized splash screens."
+   filename "locale-1.10-pkg.tar.gz"
+   md5sum "8439f2d7e266f3e4c2f18a19aa967202"
+   size 32709
+   provides ()
+   requires (mule-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(time
+  (standards-version 1.0
+   version "1.06"
+   author-version "1.17"
+   date "1998-04-24"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "oa"
+   dump nil
+   description "Display time & date on the modeline."
+   filename "time-1.06-pkg.tar.gz"
+   md5sum "f55965f3ef08e038bd58ca8f4fb83fe6"
+   size 20018
+   provides (time)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(text-modes
+  (standards-version 1.0
+   version "1.13"
+   author-version "21.0"
+   date "1998-09-24"
+   build-date "1998-10-15"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority high
+   category "oa"
+   dump nil
+   description "Miscellaneous support for editing text files."
+   filename "text-modes-1.13-pkg.tar.gz"
+   md5sum "3209269c42e32e39f70259cb68855e4f"
+   size 195165
+   provides (autoinsert crontab-edit filladapt fold-isearch folding image-mode iso-acc iso-ascii iso-cvt iso-insert iso-swed swedish tabify whitespace-mode winmgr-mode xpm-mode xrdb-mode)
+   requires (ispell fsf-compat xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(strokes
+  (standards-version 1.0
+   version "1.03"
+   author-version "21.0"
+   date "1998-01-25"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "oa"
+   dump nil
+   description "Mouse enhancement utility."
+   filename "strokes-1.03-pkg.tar.gz"
+   md5sum "170257302196f106a54eb6dcf32fcc7a"
+   size 43480
+   provides (strokes)
+   requires (text-modes edit-utils mail-lib xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(speedbar
+  (standards-version 1.0
+   version "1.10"
+   author-version "0.6.2x"
+   date "1998-10-02"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "oa"
+   dump nil
+   description "Provides a seperate frame with convenient references."
+   filename "speedbar-1.10-pkg.tar.gz"
+   md5sum "eab230ae2aa7d6ed5739f46ec4099dcf"
+   size 64861
+   provides (speedbar)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(slider
+  (standards-version 1.0
+   version "1.08"
+   author-version "0.3x1"
+   date "1998-08-13"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution experimental
+   priority low
+   category "oa"
+   dump nil
+   description "User interface tool."
+   filename "slider-1.08-pkg.tar.gz"
+   md5sum "8d2fe53d7d58fa0af58ac0359caccaca"
+   size 12018
+   provides (slider color-selector)
+   requires ()
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(sgml
+  (standards-version 1.0
+   version "1.03"
+   author-version "21.0"
+   date "1998-01-25"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution contrib
+   priority low
+   category "oa"
+   dump nil
+   description "SGML/Linuxdoc-SGML editing."
+   filename "sgml-1.03-pkg.tar.gz"
+   md5sum "317c7f52a3215f53e964ad90f9c40909"
+   size 26928
+   provides (sgml linuxdoc-sgml)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(psgml
+  (standards-version 1.0
+   version "1.10"
+   author-version "1.01"
+   date "1998-07-06"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "oa"
+   dump nil
+   description "Validated HTML/SGML editing."
+   filename "psgml-1.10-pkg.tar.gz"
+   md5sum "15e584b90a2d2310a2be15ea2aa0717a"
+   size 424930
+   provides (psgml sgml)
+   requires (edit-utils)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(pc
+  (standards-version 1.0
+   version "1.13"
+   author-version "21.0"
+   date "1998-07-25"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "oa"
+   dump nil
+   description "PC style interface emulation."
+   filename "pc-1.13-pkg.tar.gz"
+   md5sum "e5355fb82d1dbd77ad522bffb334168d"
+   size 16306
+   provides (delbs fusion pc-select pending-del s-region)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(ispell
+  (standards-version 1.0
+   version "1.12"
+   author-version "3.0x2"
+   date "1998-09-15"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "oa"
+   dump nil
+   description "Spell-checking with GNU ispell."
+   filename "ispell-1.12-pkg.tar.gz"
+   md5sum "5786e4688024aae78fe75a5cbf92c446"
+   size 67168
+   provides (ispell)
+   requires ()
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(hm--html-menus
+  (standards-version 1.0
+   version "1.08"
+   author-version "5.9"
+   date "1998-01-25"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "oa"
+   dump nil
+   description "HTML editing."
+   filename "hm--html-menus-1.08-pkg.tar.gz"
+   md5sum "1f0fda934b84c5eed96fcfd02a046398"
+   size 168017
+   provides (adapt hm--date hm--html-configuration hm--html-drag-and-drop hm--html-indentation hm--html-keys hm--html-menu hm--html-mode hm--html-not-standard hm--html html-view tmpl-minor-mode)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(frame-icon
+  (standards-version 1.0
+   version "1.05"
+   author-version "21.0"
+   date "1998-07-14"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution contrib
+   priority low
+   category "oa"
+   dump nil
+   description "Set up mode-specific icons for each frame under XEmacs"
+   filename "frame-icon-1.05-pkg.tar.gz"
+   md5sum "3d1a67ba8a51f74746ecb14385a025ef"
+   size 33490
+   provides (forms forms-mode)
+   requires ()
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(forms
+  (standards-version 1.0
+   version "1.08"
+   author-version "2.10"
+   date "1998-01-25"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution contrib
+   priority low
+   category "oa"
+   dump nil
+   description "Forms editing support (obsolete, use Widget instead)."
+   filename "forms-1.08-pkg.tar.gz"
+   md5sum "8af074cfc164331838bc83eb79eed3b5"
+   size 47670
+   provides (forms forms-mode)
+   requires ()
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(edit-utils
+  (standards-version 1.0
+   version "1.33"
+   author-version "21.0"
+   date "1998-09-29"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority high
+   category "oa"
+   dump nil
+   description "Miscellaneous editor extensions, you probably need this."
+   filename "edit-utils-1.33-pkg.tar.gz"
+   md5sum "0aa0b5d2864dc02a62fb6e87880c4733"
+   size 564543
+   provides (abbrevlist atomic-extents avoid backup-dir balloon-help big-menubar blink-cursor blink-paren bookmark compare-w completion dabbrev desktop detached-minibuf edit-toolbar fast-lock file-part floating-toolbar flow-ctrl foldout func-menu hippie-exp icomplete id-select info-look iswitchb lazy-lock lazy-shot live-icon man mic-paren paren popper mode-motion+ outl-mouse page-ext blink-paren paren permanent-buffers recent-files redo reportmail rsz-minibuf saveconfsavehist saveplace scroll-in-place tempo toolbar-utils tree-menu uniquify where-was-i-db)
+   requires (xemacs-base)
+   type single
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(calendar
+  (standards-version 1.0
+   version "1.08"
+   author-version "21.0"
+   date "1998-09-01"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "oa"
+   dump nil
+   description "Calendar and diary support."
+   filename "calendar-1.08-pkg.tar.gz"
+   md5sum "afe4b31eb98b130960046bb3c2385ed3"
+   size 248313
+   provides (appt cal-dst cal-french cal-mayan cal-x cal-xemacs calendar diary-ins diary-lib holidays lunar solar)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(calc
+  (standards-version 1.0
+   version "1.09"
+   author-version "2.02fX3"
+   date "1998-07-25"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "oa"
+   dump nil
+   description "Emacs calculator"
+   filename "calc-1.09-pkg.tar.gz"
+   md5sum "f0eb907a308a96da7ac5c3fc8c7d8bea"
+   size 1616564
+   provides (calc)
+   requires ()
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(vhdl
+  (standards-version 1.0
+   version "1.06"
+   author-version "2.74"
+   date "1998-01-24"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "prog"
+   dump nil
+   description "Support for VHDL."
+   filename "vhdl-1.06-pkg.tar.gz"
+   md5sum "b6f786b7f682f76d57eeb94d3c917e56"
+   size 65943
+   provides (vhdl-mode)
+   requires ()
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(vc-cc
+  (standards-version 1.0
+   version "1.09"
+   author-version "21.0"
+   date "1998-07-24"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution contrib
+   priority low
+   category "prog"
+   dump nil
+   description "Version Control for ClearCase (UnFree) systems."
+   filename "vc-cc-1.09-pkg.tar.gz"
+   md5sum "43f4947aeb368164aada9dc2df827ce7"
+   size 96473
+   provides (vc)
+   requires (dired xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(vc
+  (standards-version 1.0
+   version "1.14"
+   author-version "21.0"
+   date "1998-10-07"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "prog"
+   dump nil
+   description "Version Control for Free systems."
+   filename "vc-1.14-pkg.tar.gz"
+   md5sum "64c350d9c5280e7545e3dc3936992a8a"
+   size 83885
+   provides (vc)
+   requires (dired xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(sh-script
+  (standards-version 1.0
+   version "1.07"
+   author-version "2.0e"
+   date "1998-05-12"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "prog"
+   dump nil
+   description "Support for editing shell scripts."
+   filename "sh-script-1.07-pkg.tar.gz"
+   md5sum "c5dd114d8e925fc7c8ec6d9130489421"
+   size 33895
+   provides (sh-script executable)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(scheme
+  (standards-version 1.0
+   version "1.06"
+   author-version "21.0"
+   date "1998-09-08"
+   build-date "1998-10-11"
+   maintainer "Karl M. Hegbloom <karlheg@bittersweet.inetarena.com>"
+   distribution contrib
+   priority low
+   category "prog"
+   dump nil
+   description "Front-end support for Inferior Scheme."
+   filename "scheme-1.06-pkg.tar.gz"
+   md5sum "86edb18517b7ed62929041c55ea68927"
+   size 36321
+   provides (scheme xscheme cmuscheme cmuscheme48)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(prog-modes
+  (standards-version 1.0
+   version "1.13"
+   author-version "21.0"
+   date "1998-10-15"
+   build-date "1998-10-15"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "prog"
+   dump nil
+   description "Support for various programming languages."
+   filename "prog-modes-1.13-pkg.tar.gz"
+   md5sum "6e78de455277b0fe757931532ca56a88"
+   size 574269
+   provides (autoconf-mode cperl-mode eiffel3 f90 fortran ksh-mode m4-mode makefile perl-mode postscript python-mode rexx-mode simula-mode tcl teco verilog-mod)
+   requires (mail-lib xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(pcl-cvs
+  (standards-version 1.0
+   version "1.34"
+   author-version "R-2_0-Beta_2"
+   date "1998-10-12"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "prog"
+   dump nil
+   description "CVS frontend."
+   filename "pcl-cvs-1.34-pkg.tar.gz"
+   md5sum "6a3f944402c486679e7cb33f60b8689b"
+   size 161529
+   provides (pcl-cvs generic-sc)
+   requires (xemacs-base elib dired)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(jde
+  (standards-version 1.0
+   version "1.06"
+   author-version "2.05"
+   date "1998-07-09"
+   build-date "1998-10-11"
+   maintainer "Andy Piper <andyp@parallax.co.uk>"
+   distribution stable
+   priority medium
+   category "prog"
+   dump nil
+   description "Java language and development support."
+   filename "jde-1.06-pkg.tar.gz"
+   md5sum "402a03ac6482ee28a586ee41164cf4f5"
+   size 126911
+   provides (jde)
+   requires (cc-mode debug speedbar edit-utils mail-lib xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(emerge
+  (standards-version 1.0
+   version "1.04"
+   author-version "21.0"
+   date "1998-04-07"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "prog"
+   dump nil
+   description "Another interface over GNU patch."
+   filename "emerge-1.04-pkg.tar.gz"
+   md5sum "681e35d3a0c167782db2e93f37ee3147"
+   size 60972
+   provides (emerge)
+   requires ()
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(ediff
+  (standards-version 1.0
+   version "1.13"
+   author-version "2.71"
+   date "up-mess): "
+   build-date "1998-10-15"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "prog"
+   dump nil
+   description "Interface over GNU patch."
+   filename "ediff-1.13-pkg.tar.gz"
+   md5sum "6435e57ce61d0b0262196866d62b63be"
+   size 281534
+   provides (ediff)
+   requires (pcl-cvs elib dired xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(debug
+  (standards-version 1.0
+   version "1.06"
+   author-version "21.0"
+   date "1998-07-09"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution contrib
+   priority low
+   category "prog"
+   dump nil
+   description "GUD, gdb, dbx debugging support."
+   filename "debug-1.06-pkg.tar.gz"
+   md5sum "807421911694a3c5853568efb71b88b0"
+   size 88964
+   provides (dbx gdb-highlight gdb gdbsrc gud history)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(cc-mode
+  (standards-version 1.0
+   version "1.13"
+   author-version "5.22"
+   date "1998-03-05"
+   build-date "1998-10-11"
+   maintainer "Barry Warsaw <cc-mode-help@python.org>"
+   distribution stable
+   priority medium
+   category "prog"
+   dump nil
+   description "C, C++ and Java language support."
+   filename "cc-mode-1.13-pkg.tar.gz"
+   md5sum "1ea7ffaa586063356ae65f4777cfb431"
+   size 186436
+   provides (cc-mode)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(c-support
+  (standards-version 1.0
+   version "1.09"
+   author-version "21.0"
+   date "1998-03-25"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution contrib
+   priority low
+   category "prog"
+   dump nil
+   description "Basic single-file add-ons for editing C code."
+   filename "c-support-1.09-pkg.tar.gz"
+   md5sum "f9dc7f8884203038f750d1e96087dc9c"
+   size 68730
+   provides (c-comment-edit cmacexp ctypes hideif hideshow)
+   requires (cc-mode xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(ada
+  (standards-version 1.0
+   version "1.05"
+   author-version "2.27"
+   date "1998-01-24"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "prog"
+   dump nil
+   description "Ada language support."
+   filename "ada-1.05-pkg.tar.gz"
+   md5sum "374870f02139d0d80b56dab23f93b06d"
+   size 54388
+   provides (ada-mode ada-stmt)
+   requires ()
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(viper
+  (standards-version 1.0
+   version "1.10"
+   author-version "3.03"
+   date "1998-02-25"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "wp"
+   dump nil
+   description "VI emulation support."
+   filename "viper-1.10-pkg.tar.gz"
+   md5sum "f34ad536e27aa564849fcfb2fcf22a29"
+   size 315794
+   provides (viper)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(tpu
+  (standards-version 1.0
+   version "1.07"
+   author-version "4.2X"
+   date "1998-07-23"
+   build-date "1998-10-11"
+   maintainer "Kevin Oberman <oberman@es.net>"
+   distribution normal
+   priority medium
+   category "wp"
+   dump nil
+   description "DEC EDIT/TPU support."
+   filename "tpu-1.07-pkg.tar.gz"
+   md5sum "be15173be8a57fcb7b7244a143026f8c"
+   size 58801
+   provides (tpu)
+   requires ()
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(textools
+  (standards-version 1.0
+   version "1.07"
+   author-version "21.0"
+   date "1998-04-29"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stabl
+   priority medium
+   category "wp"
+   dump nil
+   description "Miscellaneous TeX support."
+   filename "textools-1.07-pkg.tar.gz"
+   md5sum "a7dff92bcb92c3401f7e6085216f72d7"
+   size 79178
+   provides (bib-mode bibtex refer-to-bibtex)
+   requires (xemacs-base)
+   type single
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(texinfo
+  (standards-version 1.0
+   version "1.13"
+   author-version "21.0"
+   date "1998-07-20"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority high
+   category "wp"
+   dump nil
+   description "XEmacs TeXinfo support."
+   filename "texinfo-1.13-pkg.tar.gz"
+   md5sum "460efede51ea17cd85872959fcf6474f"
+   size 127794
+   provides (makeinfo tex-mode texinfmt texinfo texnfo-tex texnfo-upd)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(reftex
+  (standards-version 1.0
+   version "1.09"
+   author-version "3.41"
+   date "1998-08-11"
+   build-date "1998-10-11"
+   maintainer "Carsten Dominik <dominik@strw.LeidenUniv.nl>"
+   distribution stable
+   priority medium
+   category "wp"
+   dump nil
+   description "Emacs support for LaTeX cross-references, citations.."
+   filename "reftex-1.09-pkg.tar.gz"
+   md5sum "c7c12198809741e20431cf14a6b965c4"
+   size 204664
+   provides (reftex)
+   requires (fsf-compat xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(edt
+  (standards-version 1.0
+   version "1.06"
+   author-version "21.0"
+   date "1998-04-07"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution contrib
+   priority low
+   category "wp"
+   dump nil
+   description "DEC EDIT/EDT emulation."
+   filename "edt-1.06-pkg.tar.gz"
+   md5sum "bb559e2a5c87b7b3f466b83a2ed7ef3b"
+   size 46138
+   provides (edt)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(crisp
+  (standards-version 1.0
+   version "1.08"
+   author-version "1.34"
+   date "1998-08-18"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "wp"
+   dump nil
+   description "Crisp/Brief emulation."
+   filename "crisp-1.08-pkg.tar.gz"
+   md5sum "2c18df3dd1eb14e01768832b2b208af4"
+   size 10077
+   provides (crisp scroll-lock)
+   requires ()
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(auctex
+  (standards-version 1.0
+   version "1.15"
+   author-version "9.7p"
+   date "1998-09-30"
+   build-date "1998-10-15"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "wp"
+   dump nil
+   description "Basic TeX/LaTeX support."
+   filename "auctex-1.15-pkg.tar.gz"
+   md5sum "491d156e8e1f91b6b1604eccdfddace3"
+   size 365003
+   provides (auc-old bib-cite font-latex latex multi-prompt tex-buf tex-info tex-jp tex-site tex)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(view-process
+  (standards-version 1.0
+   version "1.05"
+   author-version "2.4"
+   date "1998-01-24"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "os"
+   dump nil
+   description "A Unix process browsing tool."
+   filename "view-process-1.05-pkg.tar.gz"
+   md5sum "ec1ba005feb4ea54a832c9d07414de11"
+   size 59881
+   provides (view-process-mode)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(os-utils
+  (standards-version 1.0
+   version "1.12"
+   author-version "21.0"
+   date "1998-10-01"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "os"
+   dump nil
+   description "Miscellaneous O/S utilities."
+   filename "os-utils-1.12-pkg.tar.gz"
+   md5sum "603eb56b2af67de1663c9a3fa700b2ae"
+   size 227137
+   provides (archive-mode background crypt crypt++ inf-lisp jka-compr lpr mchat ps-print tar-mode telnet terminal uncompress)
+   requires (xemacs-base)
+   type single
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(ilisp
+  (standards-version 1.0
+   version "1.06"
+   author-version "5.8"
+   date "1998-01-24"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "os"
+   dump nil
+   description "Front-end for Inferior Lisp."
+   filename "ilisp-1.06-pkg.tar.gz"
+   md5sum "89c81fd6dac09a58d09e46ee10db4484"
+   size 262258
+   provides (ilisp completer)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(igrep
+  (standards-version 1.0
+   version "1.04"
+   author-version "2.83"
+   date "1998-08-11"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "os"
+   dump nil
+   description "Enhanced front-end for Grep."
+   filename "igrep-1.04-pkg.tar.gz"
+   md5sum "8621b52d6316c14821334191477a8ba7"
+   size 14904
+   provides (igrep)
+   requires (dired xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(eterm
+  (standards-version 1.0
+   version "1.07"
+   author-version "21.0"
+   date "1998-06-28"
+   build-date "1998-10-12"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "os"
+   dump nil
+   description "Terminal emulation."
+   filename "eterm-1.07-pkg.tar.gz"
+   md5sum "f25bfd3c591f9ca5be6f3705ea2681a3"
+   size 108929
+   provides (eterm)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(misc-games
+  (standards-version 1.0
+   version "1.08"
+   author-version "21.0"
+   date "1998-03-22"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "games"
+   dump nil
+   description "Other amusements and diversions."
+   filename "misc-games-1.08-pkg.tar.gz"
+   md5sum "ca010a30375137a14b3c37989ad61c48"
+   size 165701
+   provides (decipher gomoku hanoi life morse rot13)
+   requires (xemacs-base)
+   type single
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(mine
+  (standards-version 1.0
+   version "1.09"
+   author-version "1.9"
+   date "1998-05-09"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "games"
+   dump nil
+   description "Minehunt Game."
+   filename "mine-1.09-pkg.tar.gz"
+   md5sum "044c1e48ffca88adf46e0df91d456a49"
+   size 66794
+   provides (xmine)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(games
+  (standards-version 1.0
+   version "1.07"
+   author-version "1.04"
+   date "1998-06-04"
+   build-date "1998-10-11"
+   maintainer "Glynn Clements <glynn@sensei.co.uk>"
+   distribution stable
+   priority low
+   category "games"
+   dump nil
+   description "Tetris, Sokoban, and Snake."
+   filename "games-1.07-pkg.tar.gz"
+   md5sum "ac3fa3b5de00f0daa50c1f372e5b86e0"
+   size 32101
+   provides (gamegrid snake tetris sokoban)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(cookie
+  (standards-version 1.0
+   version "1.09"
+   author-version "21.0"
+   date "1998-04-07"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "games"
+   dump nil
+   description "Spook and Yow (Zippy quotes)."
+   filename "cookie-1.09-pkg.tar.gz"
+   md5sum "c0618f8a6db3951c081f053233fb75b5"
+   size 34228
+   provides (cookie1 yow)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(xemacs-devel
+  (standards-version 1.0
+   version "1.19"
+   author-version "21.0"
+   date "1998-09-18"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "libs"
+   dump nil
+   description "Emacs Lisp developer support."
+   filename "xemacs-devel-1.19-pkg.tar.gz"
+   md5sum "1a9a1d467ae39ce1e93f5fd238112b3e"
+   size 83669
+   provides (docref eldoc elp find-func hide-copyleft ielm regexp-opt trace)
+   requires (xemacs-base)
+   type single
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(xemacs-base
+  (standards-version 1.0
+   version "1.27"
+   author-version "21.0"
+   date "1998-10-08"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution mule
+   priority high
+   category "libs"
+   dump nil
+   description "Fundamental XEmacs support, you almost certainly need this."
+   filename "xemacs-base-1.27-pkg.tar.gz"
+   md5sum "bbede4998cdf5af078c0e41d7b9af7c8"
+   size 429962
+   provides (add-log advice annotations assoc case-table chistory comint-xemacs comint compile debug ebuff-menu echistory edmacro ehelp electric enriched env facemenu ffap helper imenu iso-syntax macros novice outline overlay passwd pp regi ring shell skeleton sort thing time-stamp timezone xbm-button xpm-button)
+   requires ()
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(tooltalk
+  (standards-version 1.0
+   version "1.08"
+   author-version "21.0"
+   date "1998-07-25"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution contrib
+   priority low
+   category "libs"
+   dump nil
+   description "Support for building with Tooltalk."
+   filename "tooltalk-1.08-pkg.tar.gz"
+   md5sum "9b4d7a73f9bd50273a011b1ed6522535"
+   size 9293
+   provides ()
+   requires ()
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(mail-lib
+  (standards-version 1.0
+   version "1.18"
+   author-version "21.0"
+   date "1998-06-08"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority medium
+   category "libs"
+   dump nil
+   description "Fundamental lisp files for providing email support."
+   filename "mail-lib-1.18-pkg.tar.gz"
+   md5sum "25896164b50a8c09a45fdf74342c48ea"
+   size 120245
+   provides (browse-url highlight-headers mail-abbrevs mail-extr mail-utils reporter rfc822 rmail-mini rmailout sendmail smtpmail)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(fsf-compat
+  (standards-version 1.0
+   version "1.04"
+   author-version "21.0"
+   date "1998-09-12"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution mule
+   priority high
+   category "libs"
+   dump nil
+   description "FSF Emacs compatibility files."
+   filename "fsf-compat-1.04-pkg.tar.gz"
+   md5sum "629a4f399a410e88841db23014d00300"
+   size 17419
+   provides (overlay thingatpt timer x-popup-menu)
+   requires ()
+   type single
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(elib
+  (standards-version 1.0
+   version "1.03"
+   author-version "1.0"
+   date "1998-10-01"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution mule
+   priority high
+   category "libs"
+   dump nil
+   description "Portable Emacs Lisp utilities library."
+   filename "elib-1.03-pkg.tar.gz"
+   md5sum "f65ecef3ac286ee59e102f5fc5ad62cc"
+   size 72830
+   provides (avltree bintree cookie dll elib-node queue-f queue-m read stack-f stack-m string)
+   requires ()
+   type single
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(efs
+  (standards-version 1.0
+   version "1.11"
+   author-version "1.17"
+   date "1998-08-23"
+   build-date "1998-10-11"
+   maintainer "Mike Sperber <sperber@informatik.uni-tuebingen.de>"
+   distribution stable
+   priority medium
+   category "libs"
+   dump nil
+   description "Treat files on remote systems the same as local files."
+   filename "efs-1.11-pkg.tar.gz"
+   md5sum "88a538a5016ae53380dba011db80887a"
+   size 368997
+   provides (efs)
+   requires (xemacs-base vm dired)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(edebug
+  (standards-version 1.0
+   version "1.06"
+   author-version "21.0"
+   date "1998-03-12"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority low
+   category "libs"
+   dump nil
+   description "An Emacs Lisp debugger."
+   filename "edebug-1.06-pkg.tar.gz"
+   md5sum "a897be415a8b68c1f79a3632374c9174"
+   size 112385
+   provides (edebug cl-read cust-print eval-reg cl-specs)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(dired
+  (standards-version 1.0
+   version "1.03"
+   author-version "7.9"
+   date "1998-05-05"
+   build-date "1998-10-11"
+   maintainer "Mike Sperber <sperber@informatik.uni-tuebingen.de>"
+   distribution stable
+   priority medium
+   category "libs"
+   dump nil
+   description "Manage file systems."
+   filename "dired-1.03-pkg.tar.gz"
+   md5sum "30e621efdf8b83e72ad3b68f4e795069"
+   size 187593
+   provides (diff dired)
+   requires (xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(apel
+  (standards-version 1.0
+   version "1.07"
+   author-version "3.3"
+   date "1998-07-23"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution mule
+   priority high
+   category "libs"
+   dump nil
+   description "A Portable Emacs Library.  Used by XEmacs MIME support."
+   filename "apel-1.07-pkg.tar.gz"
+   md5sum "a650a5235403b0a1b46b3269634498e3"
+   size 34784
+   provides (atype emu-20 emu-e19 emu-x20 emu-xemacs emu file-detect filename install mule-caesar path-util richtext std11-parse std11 tinyrich)
+   requires (fsf-compat xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(Sun
+  (standards-version 1.0
+   version "1.09"
+   author-version "21.0"
+   date "1998-07-25"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution sun
+   priority low
+   category "libs"
+   dump nil
+   description "Support for Sparcworks."
+   filename "Sun-1.09-pkg.tar.gz"
+   md5sum "dc41d791f7c66dc13e8d0d206689188b"
+   size 63916
+   provides (sccs eos-browser eos-common eos-debugger eos-debugger eos-editor eos-init eos-load eos-menubar eos-toolbar sunpro)
+   requires (cc-mode xemacs-base)
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(sounds-au
+  (standards-version 1.0
+   version "1.05"
+   author-version "21.0"
+   date "1998-06-30"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority high
+   category "libs"
+   dump nil
+   description "XEmacs Sun sound files."
+   filename "sounds-au-1.05-pkg.tar.gz"
+   md5sum "5e44ddd6754771e35303bf4e71c17a17"
+   size 125753
+   provides ()
+   requires ()
+   type regular
+))
+))
+;;;@@@
+(package-get-update-base-entry (quote
+(sounds-wav
+  (standards-version 1.0
+   version "1.05"
+   author-version "21.0"
+   date "1998-06-30"
+   build-date "1998-10-11"
+   maintainer "XEmacs Development Team <xemacs-beta@xemacs.org>"
+   distribution stable
+   priority high
+   category "libs"
+   dump nil
+   description "XEmacs Microsoft sound files."
+   filename "sounds-wav-1.05-pkg.tar.gz"
+   md5sum "e110bc6096bcd24181b45c1b7f83eb59"
+   size 148564
+   provides ()
+   requires ()
+   type regular
+))
+))
+;;;@@@
+;; Package Index file ends here
+
+-----BEGIN PGP SIGNATURE-----
+Version: 2.6.2
+
+iQCVAwUBNibr5aLJZEUiepcNAQHmWQP+PDjjOvmsdhu6RGXIFCUPV4ado8IWD8i8
+/aEwLHJRdoQWEg0ZuiNgmtF2iNPrNIOkSs9hF+sOF4xoszhxaytfFG7DEA5Q8Alb
+jKooHKEUEF7W0wAxihyGojz3VuH5i7GKAtOcVqFtgWS3eAkNaN4QWlmhxavh0Cdv
+p7wnfYTZYSs=
+=65go
+-----END PGP SIGNATURE-----
--- a/lib-src/ChangeLog	Mon Aug 13 11:04:53 2007 +0200
+++ b/lib-src/ChangeLog	Mon Aug 13 11:05:42 2007 +0200
@@ -1,3 +1,20 @@
+1998-11-28  SL Baur  <steve@altair.xemacs.org>
+
+	* XEmacs 21.2-beta4 is released.
+
+1998-10-14  Andy Piper  <andyp@parallax.co.uk>
+
+	* Makefile.in.in (movemail): add getopt.o to objects to link with.
+
+	* movemail.c (main): rewrite to use getopt(). Add options for
+	order reversal, progress output, regexp matching and message
+	deletion.
+	(popmail): add some optional verbose messages. Use pop_search_top
+	for getting messages. Make message deletion optional. Delete all
+	messages at the end rather than on a message my message basis.
+	(pop_search_top): new function. Looks for messages matching regexp.
+	(compile_regex): new function stolen from etags.
+
 1998-10-15  SL Baur  <steve@altair.xemacs.org>
 
 	* XEmacs 21.2-beta3 is released.
--- a/lib-src/Makefile.in.in	Mon Aug 13 11:04:53 2007 +0200
+++ b/lib-src/Makefile.in.in	Mon Aug 13 11:05:42 2007 +0200
@@ -310,8 +310,10 @@
 b2m: ${srcdir}/b2m.c ../src/config.h
 	$(CC) $(cflags) ${srcdir}/b2m.c $(ldflags) -o $@
 
-movemail: ${srcdir}/movemail.c ${srcdir}/pop.c ${srcdir}/pop.h ../src/config.h
-	$(CC) $(cflags) ${MOVE_FLAGS} ${srcdir}/movemail.c ${srcdir}/pop.c $(ldflags) ${MOVE_LIBS} -o $@
+movemail: ${srcdir}/movemail.c ${srcdir}/pop.c ${srcdir}/pop.h $(GETOPTDEPS) regex.o \
+	../src/config.h
+	$(CC) $(cflags) ${MOVE_FLAGS} ${srcdir}/movemail.c ${srcdir}/pop.c \
+	$(GETOPTOBJS) regex.o $(ldflags) ${MOVE_LIBS} -o $@
 
 cvtmail: ${srcdir}/cvtmail.c
 	$(CC) $(cflags) ${srcdir}/cvtmail.c $(ldflags) -o $@
--- a/lib-src/movemail.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/lib-src/movemail.c	Mon Aug 13 11:05:42 2007 +0200
@@ -65,10 +65,15 @@
 #include "../src/systime.h"
 #include <stdlib.h>
 #include <string.h>
+#include "getopt.h"
 #ifdef MAIL_USE_POP
 #include "pop.h"
+#include <regex.h>
 #endif
 
+extern char *optarg;
+extern int optind, opterr;
+
 #ifndef HAVE_STRERROR
 static char * strerror (int errnum);
 #endif /* HAVE_STRERROR */
@@ -146,15 +151,43 @@
 static int mbx_write (char *, FILE *);
 static int mbx_delimit_begin (FILE *);
 static int mbx_delimit_end (FILE *);
+static struct re_pattern_buffer* compile_regex (char* regexp_pattern);
+static int pop_search_top (popserver server, int msgno, int lines, 
+			   struct re_pattern_buffer* regexp);
 #endif
 
 /* Nonzero means this is name of a lock file to delete on fatal error.  */
 char *delete_lockname;
 
+int verbose=0;
+#ifdef MAIL_USE_POP
+int reverse=0;
+int keep_messages=0;
+struct re_pattern_buffer* regexp_pattern=0;
+int match_lines=10;
+#endif
+
+#define VERBOSE(x) if (verbose) { printf x; fflush(stdout); }
+
+struct option longopts[] =
+{
+  { "inbox",			required_argument,	   NULL,	'i'	},
+  { "outfile",			required_argument,	   NULL,	'o'	},
+#ifdef MAIL_USE_POP
+  { "password",			required_argument,	   NULL,	'p'	},
+  { "reverse-pop-order",		no_argument,		   NULL,	'x'	},
+  { "keep-messages",		no_argument,		   NULL,	'k'	},
+  { "regex",			required_argument,	   NULL,	'r' 	},
+  { "match-lines",		required_argument,	   NULL,	'l' 	},
+#endif
+  { "verbose", 			no_argument,		   NULL,	'v'	},
+  { 0 }
+};
+
 int
 main (int argc, char *argv[])
 {
-  char *inname, *outname;
+  char *inname=0, *outname=0, *poppass=0;
 #ifndef DISABLE_DIRECT_ACCESS
   int indesc, outdesc;
   int nread;
@@ -172,15 +205,73 @@
 
   delete_lockname = 0;
 
-  if (argc < 3)
+  while (1)
     {
-      fprintf (stderr, "Usage: movemail inbox destfile [POP-password]\n");
+#ifdef MAIL_USE_POP
+      char* optstring = "i:o:p:l:r:xvk";
+#else
+      char* optstring = "i:o:v";
+#endif
+      int opt = getopt_long (argc, argv, optstring, longopts, 0);
+  
+      if (opt == EOF)
+	break;
+
+      switch (opt)
+	{
+	case 0:
+	  break;
+	case 1:			/* one of the standard arguments seen */
+	  if (!inname)
+	    inname = optarg;
+	  else if (!outname)
+	    outname = optarg;
+	  else
+	    poppass = optarg;
+	  break;
+
+	case 'i':		/* infile */
+	  inname = optarg;
+	  break;
+	  
+	case 'o':		/* outfile */
+	  outname = optarg;
+	  break;
+#ifdef MAIL_USE_POP
+	case 'p':		/* pop password */
+	  poppass = optarg;	
+	  break;
+	case 'k':		keep_messages=1;	break;
+	case 'x':		reverse = 1;		break;
+	case 'l':		/* lines to match */
+	  match_lines = atoi (optarg);
+	  break;
+
+	case 'r':		/* regular expression */
+	  regexp_pattern = compile_regex (optarg);
+	  break;
+#endif
+	case 'v':		verbose = 1;	break;
+	}
+    }
+
+  while (optind < argc)
+      {
+	  if (!inname)
+	      inname = argv[optind];
+	  else if (!outname)
+	      outname = argv[optind];
+	  else
+	      poppass = argv[optind];
+	  optind++;
+      }
+    
+  if (!inname || !outname)
+    {
+      fprintf (stderr, "Usage: movemail [-rvxk] [-l lines ] [-i] inbox [-o] destfile [[-p] POP-password]\n");
       exit(1);
     }
 
-  inname = argv[1];
-  outname = argv[2];
-
 #ifdef MAIL_USE_MMDF
   mmdf_init (argv[0]);
 #endif
@@ -210,7 +301,7 @@
 #ifdef MAIL_USE_POP
   if (!strncmp (inname, "po:", 3))
     {
-      int retcode = popmail (inname + 3, outname, argc > 3 ? argv[3] : NULL);
+      int retcode = popmail (inname + 3, outname, poppass);
       exit (retcode);
     }
 
@@ -487,9 +578,9 @@
 #include <stdio.h>
 #include <pwd.h>
 
-#define NOTOK (-1)
-#define OK 0
-#define DONE 1
+#define POP_ERROR 	(-1)
+#define POP_RETRIEVED (0)
+#define POP_DONE (1)
 
 char *progname;
 FILE *sfi;
@@ -502,11 +593,13 @@
 popmail (char *user, char *outfile, char *password)
 {
   int nmsgs, nbytes;
-  register int i;
+  register int i, idx;
   int mbfi;
+  short* retrieved_list;
   FILE *mbf;
   popserver server;
 
+  VERBOSE(("opening server\r"));
   server = pop_open (0, user, password, POP_NO_GETPASS);
   if (! server)
     {
@@ -514,6 +607,7 @@
       return (1);
     }
 
+  VERBOSE(("stat'ing messages\r"));
   if (pop_stat (server, &nmsgs, &nbytes))
     {
       error (pop_error, NULL, NULL);
@@ -522,10 +616,15 @@
 
   if (!nmsgs)
     {
+      VERBOSE(("closing server\n"));
       pop_close (server);
       return (0);
     }
 
+  /* build a retrieved table */
+  retrieved_list = (short*) xmalloc (sizeof (short) * (nmsgs+1));
+  memset (retrieved_list, 0, sizeof (short) * (nmsgs+1));
+
   mbfi = open (outfile, O_WRONLY | O_CREAT | O_EXCL, 0666);
   if (mbfi < 0)
     {
@@ -546,23 +645,35 @@
       return (1);
     }
 
-  for (i = 1; i <= nmsgs; i++)
+  for (idx = 0; idx < nmsgs; idx++)
     {
-      mbx_delimit_begin (mbf);
-      if (pop_retr (server, i, mbx_write, mbf) != OK)
+      i = reverse ? nmsgs - idx : idx + 1;
+      VERBOSE(("checking message %d     \r", i));
+      
+      if (!regexp_pattern 
+	  || 
+	  pop_search_top (server, i, match_lines, regexp_pattern) == POP_RETRIEVED)
 	{
-	  error (Errmsg, NULL, NULL);
-	  close (mbfi);
-	  return (1);
-	}
-      mbx_delimit_end (mbf);
-      fflush (mbf);
-      if (ferror (mbf))
-	{
-	  error ("Error in fflush: %s", strerror (errno), NULL);
-	  pop_close (server);
-	  close (mbfi);
-	  return (1);
+	  VERBOSE(("retrieving message %d     \r", i));
+          mbx_delimit_begin (mbf);
+	  if (pop_retr (server, i, mbx_write, mbf) != POP_RETRIEVED)
+	    {
+	      error (Errmsg, NULL, NULL);
+	      close (mbfi);
+	      return (1);
+	    }
+
+	  retrieved_list[i]=1;
+
+	  mbx_delimit_end (mbf);
+	  fflush (mbf);
+	  if (ferror (mbf))
+	    {
+	      error ("Error in fflush: %s", strerror (errno), NULL);
+	      pop_close (server);
+	      close (mbfi);
+	      return (1);
+	    }
 	}
     }
 
@@ -586,16 +697,24 @@
       return (1);
     }
 
-  for (i = 1; i <= nmsgs; i++)
+  if (!keep_messages)
     {
-      if (pop_delete (server, i))
+      for (i = 1; i <= nmsgs; i++)
 	{
-	  error (pop_error, NULL, NULL);
-	  pop_close (server);
-	  return (1);
+	  if (retrieved_list[i] == 1)
+	    {
+	      VERBOSE(("deleting message %d     \r", i));
+	      if (pop_delete (server, i))
+		{
+		  error (pop_error, NULL, NULL);
+		  pop_close (server);
+		  return (1);
+		}
+	    }
 	}
     }
 
+  VERBOSE(("closing server             \n"));
   if (pop_quit (server))
     {
       error (pop_error, NULL, NULL);
@@ -615,7 +734,7 @@
     {
       strncpy (Errmsg, pop_error, sizeof (Errmsg));
       Errmsg[sizeof (Errmsg)-1] = '\0';
-      return (NOTOK);
+      return (POP_ERROR);
     }
 
   while (! (ret = pop_retrieve_next (server, &line)))
@@ -623,11 +742,11 @@
       if (! line)
 	break;
 
-      if ((*action)(line, arg) != OK)
+      if ((*action)(line, arg) != POP_RETRIEVED)
 	{
 	  strcpy (Errmsg, strerror (errno));
 	  pop_close (server);
-	  return (NOTOK);
+	  return (POP_ERROR);
 	}
     }
 
@@ -635,10 +754,56 @@
     {
       strncpy (Errmsg, pop_error, sizeof (Errmsg));
       Errmsg[sizeof (Errmsg)-1] = '\0';
-      return (NOTOK);
+      return (POP_ERROR);
+    }
+
+  return (POP_RETRIEVED);
+}
+
+/* search the top lines of each message looking for a match */
+static int
+pop_search_top (popserver server, int msgno, int lines, struct re_pattern_buffer* regexp)
+{
+  char *line;
+  int ret;
+  int match = POP_DONE;
+
+  if (pop_top_first (server, msgno, lines, &line))
+    {
+      strncpy (Errmsg, pop_error, sizeof (Errmsg));
+      Errmsg[sizeof (Errmsg)-1] = '\0';
+      return (POP_ERROR);
     }
 
-  return (OK);
+  while (! (ret = pop_top_next (server, &line)))
+    {
+      if (! line)
+	break;
+
+      /*      VERBOSE (("checking %s\n", line));*/
+      if (match != POP_RETRIEVED)
+	{
+	  if ((ret = re_match (regexp, line, strlen (line), 0, 0)) == -2 )
+	    {
+	      strcpy (Errmsg, "error in regular expression");
+	      pop_close (server);
+	      return (POP_ERROR);
+	    }
+	  else if (ret >=0)
+	    {
+	      match = POP_RETRIEVED;
+	    }
+	}
+    }
+
+  if (ret)
+    {
+      strncpy (Errmsg, pop_error, sizeof (Errmsg));
+      Errmsg[sizeof (Errmsg)-1] = '\0';
+      return (POP_ERROR);
+    }
+
+  return match;
 }
 
 /* Do this as a macro instead of using strcmp to save on execution time. */
@@ -654,31 +819,57 @@
   if (IS_FROM_LINE (line))
     {
       if (fputc ('>', mbf) == EOF)
-	return (NOTOK);
+	return (POP_ERROR);
     }
   if (fputs (line, mbf) == EOF) 
-    return (NOTOK);
+    return (POP_ERROR);
   if (fputc (0x0a, mbf) == EOF)
-    return (NOTOK);
-  return (OK);
+    return (POP_ERROR);
+  return (POP_RETRIEVED);
 }
 
 static int
 mbx_delimit_begin (FILE *mbf)
 {
   if (fputs ("\f\n0, unseen,,\n", mbf) == EOF)
-    return (NOTOK);
-  return (OK);
+    return (POP_ERROR);
+  return (POP_RETRIEVED);
 }
 
 static int
 mbx_delimit_end (FILE *mbf)
 {
   if (putc ('\037', mbf) == EOF)
-    return (NOTOK);
-  return (OK);
+    return (POP_ERROR);
+  return (POP_RETRIEVED);
 }
 
+/* Turn a name, which is an ed-style (but Emacs syntax) regular
+   expression, into a real regular expression by compiling it. */
+static struct re_pattern_buffer*
+compile_regex (char* regexp_pattern)
+{
+  char *err;
+  struct re_pattern_buffer *patbuf=0;
+  
+  patbuf = (struct re_pattern_buffer*) xmalloc (sizeof (struct re_pattern_buffer));
+  patbuf->translate = NULL;
+  patbuf->fastmap = NULL;
+  patbuf->buffer = NULL;
+  patbuf->allocated = 0;
+
+  err = (char*) re_compile_pattern (regexp_pattern, strlen (regexp_pattern), patbuf);
+  if (err != NULL)
+    {
+      error ("%s while compiling pattern", err, NULL);
+      return 0;
+    }
+
+  return patbuf;
+}
+
+
+
 #endif /* MAIL_USE_POP */
 
 #ifndef HAVE_STRERROR
--- a/lisp/ChangeLog	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/ChangeLog	Mon Aug 13 11:05:42 2007 +0200
@@ -1,3 +1,132 @@
+1998-11-28  SL Baur  <steve@altair.xemacs.org>
+
+	* XEmacs 21.2-beta4 is released.
+
+1998-11-27  Jan Vroonhof  <vroonhof@math.ethz.ch>
+
+	* easymenu.el (easy-menu-add-item): Wraper around add-menu-btton.
+	(easy-menu-item-present-p): Wrapper around find-menu-item.
+	(easy-menu-remove-item): Wrapper around delete-menu-item.
+
+	* menubar.el (delete-menu-item): Add 'from-menu' argument.
+	(add-menu-button): Add 'in-menu' argument.
+	(add-menu-item-1): Add in-menu support to helper function.
+
+1998-11-27  Katsumi Yamaoka  <yamaoka@jpl.org>
+
+	* isearch-mode.el (isearch-mode): Fix keymap lossage.
+
+1998-11-26  Jan Vroonhof  <vroonhof@math.ethz.ch>
+
+	* faces.el (get-custom-frame-properties): Revert Hrvoje Niksic change 
+	of Dec 4, 1997.
+
+1998-11-25  Hrvoje Niksic  <hniksic@srce.hr>
+
+	* process.el (shell-command-on-region): Report if the command
+	succeeded or failed.
+
+1998-11-24  Hrvoje Niksic  <hniksic@srce.hr>
+
+	* subr.el (buffer-substring-no-properties): Comment out.
+
+1998-11-07  Adrian Aichner  <aichner@ecf.teradyne.com>
+
+	* msw-faces.el (mswindows-find-smaller-font): Turning font names
+	  into font instances first, like `x-frob-font-size' does.
+	  (mswindows-find-larger-font): ditto
+
+1998-11-04  Greg Klanderman  <greg@alphatech.com>
+
+	* package-ui.el (pui-install-selected-packages): fix args in call
+	to `package-get'.
+
+1998-10-29  Jan Vroonhof  <vroonhof@math.ethz.ch>
+
+	* package-get.el (host-name): New widget type.
+	(package-get-remote): Better customization using new type.
+	(package-get-download-sites): idem dito.
+
+	(package-get-custom): Do not use package-get-all untill we have
+	runtime dependencies.
+
+	(package-get-remove-copy): Default to 't' we no longer need this
+	kludge as we do not currently use depenencies.
+	
+	(package-get-was-current): New variable.
+	(package-get-require-base): New 'force-current' argument.
+	(package-get-update-base): idem
+	(package-get-package-provider):  idem
+	(package-get-locate-index-file): New 'no-remote' argument.
+	(package-get-locate-file): idem.
+	
+	(package-get-maybe-save-index): New function.
+	(package-get-update-base): Use it.
+
+1998-10-28 Greg Klanderman <greg@alphatech.com>
+
+	* package-get.el (package-get-remote): default to nil; by default, 
+	don't go out to the net via EFS.  They must select a download site.
+	(package-get-download-sites): new variable.
+	(package-get-download-menu): new function.
+	(package-get-locate-index-file): new function.
+	(package-get-update-base): use it.
+
+	* menubar-items.el (default-menubar): add "Update Package Index"
+	and "Add Download Site" menus under Options | Manage Packages.
+
+1998-10-19  Greg Klanderman  <greg@alphatech.com>
+
+	* package-get.el (package-get): bugfix code checking installed version
+	for case where package is not currently installed.
+	(package-get-require-signed-base-updates): new variable.
+	(package-get-update-base-from-buffer): remove REMOTE-SOURCE arg, it was 
+	deemed not a goot thing.  Use the variable
+	package-get-allow-unsigned-base-updates instead.
+
+1998-10-16 Greg Klanderman <greg@alphatech.com>
+
+	* package-get.el (package-get): Don't install an older version than 
+	we already have unless explicitly told to.  Issue a warning.
+
+	* package-ui.el (pui-add-required-packages): when adding
+	dependencies, don't add packages that are up to date.
+	(pui-package-symbol-char):  Don't consider a package out of date 
+	if you have a newer version installed than the latest version in
+	package-get-base.
+
+	* package-get.el (package-get-base-filename): document that it may 
+	be a path relative to package-get-remote;  new default value.
+	(package-get-locate-file): new function.
+	(package-get-update-base): use it to expand package-get-base-filename.
+	(package-get-save-base): new function to save the package-get database
+	to file.
+	(package-get-update-base-from-buffer): add REMOTE-SOURCE argument.
+	(package-get-update-base): pass the REMOTE-SOURCE arg.
+	(package-get-update-base-entry): call package-get-custom-add-entry.
+	(package-get-file-installed-p): removed; no longer needed.
+	(package-get-create-custom): ditto.
+	(toplevel): remove code to build and load package-get-custom.el
+	(package-get-custom-add-entry): new function.
+
+1998-10-12  Hrvoje Niksic  <hniksic@srce.hr>
+
+	* wid-edit.el (widget-button-click): Don't switch window.
+
+1998-10-22  Jan Vroonhof  <vroonhof@math.ethz.ch>
+
+	* cus-face.el (custom-set-face-update-spec): Add autoload cookie
+
+1998-10-20  Malcolm Box  <malcolm@brownale.demon.co.uk>
+        
+	* etags.el (find-tag-default): Run find-tag-hook using
+	run-hooks rather than funcall
+
+1998-10-19  Hrvoje Niksic  <hniksic@srce.hr>
+
+	* isearch-mode.el (isearch-mode): Set the current minor mode maps
+	and the current local map as the parents to isearch-mode-map.
+
 1998-10-15  SL Baur  <steve@altair.xemacs.org>
 
 	* XEmacs 21.2-beta3 is released.
--- a/lisp/about.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/about.el	Mon Aug 13 11:05:42 2007 +0200
@@ -1384,6 +1384,7 @@
        (print-short "Yasuhiko Kiuchi" "kiuchi@dsp.ksp.fujixerox.co.jp")
        (print-short "Greg Klanderman" "greg.klanderman@alum.mit.edu")
        (print-short "Valdis Kletnieks" "Valdis.Kletnieks@vt.edu")
+       (print-short "Norbert Koch" "n.koch@delta-ii.de")
        (print-short "Rob Kooper" "kooper@cc.gatech.edu")
        (print-short "Peter Skov Knudsen" "knu@dde.dk")
        (print-short "Jens Krinke" "krinke@ips.cs.tu-bs.de")
@@ -1510,6 +1511,7 @@
        (print-short "Jason Yanowitz" "yanowitz@eternity.cs.umass.edu")
        (print-short "La Monte Yarroll" "piggy@hilbert.maths.utas.edu.au")
        (print-short "Blair Zajac" "blair@olympia.gps.caltech.edu")
+       (print-short "Volker Zell" "vzell@de.oracle.com")
        (print-short "Daniel Zivkovic" "daniel@canada.sun.com")
        (print-short "Karel Zuiderveld" "Karel.Zuiderveld@cv.ruu.nl")
        "\n"))
--- a/lisp/auto-autoloads.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/auto-autoloads.el	Mon Aug 13 11:05:42 2007 +0200
@@ -665,11 +665,15 @@
 
 ;;;***
 
-;;;### (autoloads (custom-set-faces custom-declare-face) "cus-face" "lisp/cus-face.el")
+;;;### (autoloads (custom-set-faces custom-set-face-update-spec custom-declare-face) "cus-face" "lisp/cus-face.el")
 
 (autoload 'custom-declare-face "cus-face" "\
 Like `defface', but FACE is evaluated as a normal argument." nil nil)
 
+(autoload 'custom-set-face-update-spec "cus-face" "\
+Customize the FACE for display types matching DISPLAY, merging
+  in the new items from PLIST" nil nil)
+
 (autoload 'custom-set-faces "cus-face" "\
 Initialize faces according to user preferences.
 The arguments should be a list where each entry has the form:
@@ -1204,22 +1208,38 @@
 
 ;;;***
 
-;;;### (autoloads (package-get-custom package-get-package-provider package-get package-get-dependencies package-get-all package-get-update-all package-get-delete-package package-get-update-base-from-buffer package-get-update-base package-get-update-base-entry package-get-require-base) "package-get" "lisp/package-get.el")
+;;;### (autoloads (package-get-custom package-get-package-provider package-get package-get-dependencies package-get-all package-get-update-all package-get-delete-package package-get-save-base package-get-update-base-from-buffer package-get-update-base package-get-update-base-entry package-get-require-base package-get-download-menu) "package-get" "lisp/package-get.el")
+
+(autoload 'package-get-download-menu "package-get" "\
+Build the `Add Download Site' menu." nil nil)
 
 (autoload 'package-get-require-base "package-get" "\
-Require that a package-get database has been loaded." nil nil)
+Require that a package-get database has been loaded.
+If the optional FORCE-CURRENT argument or the value of
+`package-get-always-update' is Non-nil, try to update the database
+from a location in `package-get-remote'. Otherwise a local copy is used
+if available and remote access is never done.
+
+Please use FORCE-CURRENT only when the user is explictly dealing with packages
+and remote access is likely in the near future." nil nil)
 
 (autoload 'package-get-update-base-entry "package-get" "\
 Update an entry in `package-get-base'." nil nil)
 
 (autoload 'package-get-update-base "package-get" "\
-Update the package-get database file with entries from DB-FILE." t nil)
+Update the package-get database file with entries from DB-FILE.
+Unless FORCE-CURRENT is non-nil never try to update the database." t nil)
 
 (autoload 'package-get-update-base-from-buffer "package-get" "\
 Update the package-get database with entries from BUFFER.
 BUFFER defaults to the current buffer.  This command can be
 used interactively, for example from a mail or news buffer." t nil)
 
+(autoload 'package-get-save-base "package-get" "\
+Write the package-get database to FILE.
+
+Note: This database will be unsigned of course." t nil)
+
 (autoload 'package-get-delete-package "package-get" "\
 Delete an installation of PACKAGE below directory PKG-TOPDIR.
 PACKAGE is a symbol, not a string.
@@ -1272,7 +1292,10 @@
 Search for a package that provides SYM and return the name and
   version.  Searches in `package-get-base' for SYM.   If SYM is a
   consp, then it must match a corresponding (provide (SYM VERSION)) from 
-  the package." t nil)
+  the package.
+
+If FORCE-CURRENT is non-nil make sure the database is up to date. This might
+lead to Emacs accessing remote sites." t nil)
 
 (autoload 'package-get-custom "package-get" "\
 Fetch and install the latest versions of all customized packages." t nil)
--- a/lisp/cus-face.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/cus-face.el	Mon Aug 13 11:05:42 2007 +0200
@@ -226,6 +226,7 @@
 	 (fontobj (font-create-object font)))
     (font-family fontobj)))
 
+;;;###autoload
 (defun custom-set-face-update-spec (face display plist)
   "Customize the FACE for display types matching DISPLAY, merging
   in the new items from PLIST"
--- a/lisp/custom-load.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/custom-load.el	Mon Aug 13 11:05:42 2007 +0200
@@ -75,7 +75,6 @@
 (custom-add-loads 'isearch '("isearch-mode"))
 (custom-add-loads 'font-lock-faces '("font-lock"))
 (custom-add-loads 'modeline '("modeline"))
-(custom-add-loads 'packages '("package-get-custom"))
 (custom-add-loads 'editing '("simple" "abbrev" "fill" "mouse" "cus-edit" "dragdrop"))
 (custom-add-loads 'matching '("simple" "isearch-mode" "hyper-apropos"))
 (custom-add-loads 'i18n '("cus-edit"))
--- a/lisp/easymenu.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/easymenu.el	Mon Aug 13 11:05:42 2007 +0200
@@ -23,7 +23,9 @@
 ;; Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
 ;; 02111-1307, USA.
 
-;;; Synched up with: Not synched with FSF.
+;;; Synched up with: Not synched with FSF but coordinated with the FSF
+;;;                  easymenu maintor for compatability with FSF 20.4.
+;;; Please: Coordinate changes with Inge Frick <inge@nada.kth.se>
 
 ;; Commentary:
 
@@ -63,6 +65,15 @@
 ;; - Function: easy-menu-remove MENU
 ;;     Remove MENU from the current menubar.
 
+;; - Function: easy-menu-add-item
+;;     Add item or submenu to existing menu
+
+;; - Function: easy-menu-item-present-p
+;;     Locate item
+
+;; - Function: easy-menu-remove-item
+;;     Delete item from menu.
+
 ;; Emacs 19 never uses `easy-menu-add' or `easy-menu-remove', menus
 ;; automatically appear and disappear when the keymaps specified by
 ;; the MAPS argument to `easy-menu-define' are activated.
@@ -200,6 +211,50 @@
 	     (assoc (car menu) current-menubar)
 	     (delete-menu-item (list (car menu)))))))
 
+(defsubst easy-menu-normalize (menu)
+  (if (symbolp menu)
+      (symbol-value menu)
+    menu))
+
+(defun easy-menu-add-item (menu path item &optional before)
+  "At the end of the submenu of MENU with path PATH add ITEM.
+If ITEM is already present in this submenu, then this item will be changed.
+otherwise ITEM will be added at the end of the submenu, unless the optional
+argument BEFORE is present, in which case ITEM will instead be added
+before the item named BEFORE.
+MENU is either a symbol, which have earlier been used as the first
+argument in a call to `easy-menu-define', or the value of such a symbol
+i.e. a menu, or nil which stands for the current menubar.
+PATH is a list of strings for locating the submenu where ITEM is to be
+added.  If PATH is nil, MENU itself is used.  Otherwise, the first
+element should be the name of a submenu directly under MENU.  This
+submenu is then traversed recursively with the remaining elements of PATH.
+ITEM is either defined as in `easy-menu-define', a menu defined earlier
+by `easy-menu-define' or `easy-menu-create-menu' or an item returned
+from `easy-menu-item-present-p' or `easy-menu-remove-item'."
+  (add-menu-button path item before (easy-menu-normalize menu)))		   
+
+(defun easy-menu-item-present-p (menu path name)
+  "In submenu of MENU with path PATH, return true iff item NAME is present.
+MENU and PATH are defined as in `easy-menu-add-item'.
+NAME should be a string, the name of the element to be looked for.
+
+The return value can be used as as an argument to `easy-menu-add-item'."
+  (car (find-menu-item (or (easy-menu-normalize menu) current-menubar)
+		       (append path (list name)))))
+
+(defun easy-menu-remove-item (menu path name)
+  "From submenu of MENU with path PATH remove item NAME.
+MENU and PATH are defined as in `easy-menu-add-item'.
+NAME should be a string, the name of the element to be removed.
+
+The return value can be used as as an argument to `easy-menu-add-item'."
+  (delete-menu-item (append path (list name))
+		    (easy-menu-normalize menu)))
+  
+
+
+
 ;; Think up a good title for the menu.  Take the major-mode of the
 ;; buffer, strip the -mode part, convert hyphens to spaces, and
 ;; capitalize it.
--- a/lisp/etags.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/etags.el	Mon Aug 13 11:05:42 2007 +0200
@@ -554,7 +554,7 @@
  arguments.")
 
 (defvar find-tag-hook nil
-  "Function to call after a tag is found.
+  "*Function to call after a tag is found.
 Make it buffer-local in a mode hook.  The function is called with no
  arguments.")
 
@@ -777,11 +777,11 @@
     (push-mark)
     (goto-char tag-point)
     (if find-tag-hook
-	(funcall find-tag-hook)
+		(run-hooks 'find-tag-hook)
       (if local-find-tag-hook
-	  (funcall local-find-tag-hook))))
+		  (run-hooks 'local-find-tag-hook))))
   (setq tags-loop-scan (list 'find-tag nil nil)
-	tags-loop-operate nil)
+		tags-loop-operate nil)
   ;; Return t in case used as the tags-loop-scan.
   t)
 
--- a/lisp/faces.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/faces.el	Mon Aug 13 11:05:42 2007 +0200
@@ -1249,9 +1249,7 @@
 	     ;; and cache it...
 	     (set-frame-property frame 'custom-properties cache))
 	   cache))
-	;; We avoid this cache, because various frame and device
-	;; properties can change.
-	;;(default-custom-frame-properties)
+	(default-custom-frame-properties)
 	(t
 	 (setq default-custom-frame-properties
 	       (extract-custom-frame-properties (selected-frame))))))
--- a/lisp/isearch-mode.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/isearch-mode.el	Mon Aug 13 11:05:42 2007 +0200
@@ -460,6 +460,10 @@
 
 	  isearch-mode (gettext " Isearch")
 	  )
+    (let ((map (append (current-minor-mode-maps)
+		       (list (current-local-map)))))
+      (if (keymapp map)
+	  (set-keymap-parents isearch-mode-map map)))
 
     ;; XEmacs change: without clearing the match data, sometimes old values
     ;; of isearch-other-end get used.  Don't ask me why...
--- a/lisp/menubar-items.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/menubar-items.el	Mon Aug 13 11:05:42 2007 +0200
@@ -234,6 +234,10 @@
        ["Browse..." customize-browse])
       
       ("Manage Packages"
+       ("Add Download Site"
+        :filter (lambda (&rest junk)
+                  (package-get-download-menu)))
+       ["Update Package Index" package-get-update-base]
        ["List & Install" pui-list-packages]
        ("Using Custom"
 	("Select" :filter (lambda (&rest junk)
--- a/lisp/menubar.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/menubar.el	Mon Aug 13 11:05:42 2007 +0200
@@ -218,7 +218,7 @@
 				      (car item-path-list)))))
 	(cons result parent)))))
 
-(defun add-menu-item-1 (leaf-p menu-path new-item before)
+(defun add-menu-item-1 (leaf-p menu-path new-item before in-menu)
   ;; This code looks like it could be cleaned up some more
   ;; Do we really need 6 calls to find-menu-item?
   (when before (setq before (normalize-menu-item-name before)))
@@ -226,7 +226,7 @@
 	  (cond ((vectorp new-item) (aref new-item 0))
 		((consp   new-item) (car  new-item))
 		(t nil)))
-	 (menubar current-menubar)
+	 (menubar (or in-menu current-menubar))
 	 (menu (condition-case ()
 		   (car (find-menu-item menubar menu-path))
 		 (error nil)))
@@ -292,7 +292,7 @@
     (set-menubar-dirty-flag)
     new-item))
 
-(defun add-menu-button (menu-path menu-leaf &optional before)
+(defun add-menu-button (menu-path menu-leaf &optional before in-menu)
   "Add a menu item to some menu, creating the menu first if necessary.
 If the named item exists already, it is changed.
 MENU-PATH identifies the menu under which the new menu item should be inserted.
@@ -301,12 +301,16 @@
 MENU-LEAF is a menubar leaf node.  See the documentation of `current-menubar'.
 BEFORE, if provided, is the name of a menu item before which this item should
  be added, if this item is not on the menu already.  If the item is already
- present, it will not be moved."
-  (add-menu-item-1 t menu-path menu-leaf before))
+ present, it will not be moved.
+If IN-MENU is present use that instead of `current-menubar' as the menu to
+change.
+"
+  ;; Note easymenu.el uses the fact that menu-leaf can be a submenu.
+  (add-menu-item-1 t menu-path menu-leaf before in-menu))
 
 ;; I actually liked the old name better, but the interface has changed too
 ;; drastically to keep it. --Stig 
-(defun add-submenu (menu-path submenu &optional before)
+(defun add-submenu (menu-path submenu &optional before in-menu)
   "Add a menu to the menubar or one of its submenus.
 If the named menu exists already, it is changed.
 MENU-PATH identifies the menu under which the new menu should be inserted.
@@ -319,7 +323,7 @@
  be added, if this menu is not on its parent already.  If the menu is already
  present, it will not be moved."
   (check-menu-syntax submenu nil)
-  (add-menu-item-1 nil menu-path submenu before))
+  (add-menu-item-1 nil menu-path submenu before in-menu))
 
 (defun purecopy-menubar (x)
   ;; this calls purecopy on the strings, and the contents of the vectors,
@@ -340,11 +344,12 @@
 	(t
 	 (purecopy x))))
 
-(defun delete-menu-item (path)
+(defun delete-menu-item (path &optional from-menu)
   "Remove the named menu item from the menu hierarchy.
 PATH is a list of strings which identify the position of the menu item in 
 the menu hierarchy.  The documentation of `add-submenu' describes menu-paths."
-  (let* ((pair (condition-case nil (find-menu-item current-menubar path)
+  (let* ((pair (condition-case nil (find-menu-item (or from-menu
+						       current-menubar) path)
 		 (error nil)))
 	 (item (car pair))
 	 (parent (or (cdr pair) current-menubar)))
--- a/lisp/msw-faces.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/msw-faces.el	Mon Aug 13 11:05:42 2007 +0200
@@ -145,6 +145,9 @@
 (defun mswindows-find-smaller-font (font &optional device)
   "Loads a new version of the given font (or font name) 1 point smaller.
 Returns the font if it succeeds, nil otherwise."
+  (if (stringp font) (setq font (make-font-instance font device)))
+  (if (font-instance-p font) (setq font (font-instance-truename font)))
+  (if (stringp font) (setq font (make-font-instance font device)))
   (if (font-instance-p font)
       (let (old-size (name (mswindows-font-canonicalize-name font)))
 	(string-match "^[a-zA-Z ]+:[a-zA-Z ]*:\\([0-9]+\\):" name)
@@ -160,6 +163,9 @@
 (defun mswindows-find-larger-font (font &optional device)
   "Loads a new version of the given font (or font name) 1 point larger.
 Returns the font if it succeeds, nil otherwise."
+  (if (stringp font) (setq font (make-font-instance font device)))
+  (if (font-instance-p font) (setq font (font-instance-truename font)))
+  (if (stringp font) (setq font (make-font-instance font device)))
   (if (font-instance-p font)
       (let (old-size (name (mswindows-font-canonicalize-name font)))
 	(string-match "^[a-zA-Z ]+:[a-zA-Z ]*:\\([0-9]+\\):" name)
--- a/lisp/package-get.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/package-get.el	Mon Aug 13 11:05:42 2007 +0200
@@ -3,6 +3,8 @@
 ;; Copyright (C) 1998 by Pete Ware
 
 ;; Author: Pete Ware <ware@cis.ohio-state.edu>
+;; Heavy-Modifications: Greg Klanderman <greg@alphatech.com>
+;;                      Jan Vroonhof    <vroonhof@math.ethz.ch>
 ;; Keywords: internal
 
 ;; This file is part of XEmacs.
@@ -29,6 +31,9 @@
 ;; package-get -
 ;;	Retrieve a package and any other required packages from an archive
 ;;
+;;
+;; Note (JV): Most of this no longer aplies!
+;;
 ;; The idea:
 ;;	A new XEmacs lisp-only release is generated with the following steps:
 ;;	1. The maintainer runs some yet to be written program that
@@ -160,39 +165,123 @@
   :type 'directory
   :group 'package-get)
 
-;; JV Any Custom expert know to get "Host" and "Dir" for the remote option
-(defcustom package-get-remote
-  '(("ftp.xemacs.org" "/pub/xemacs/packages"))
+(define-widget 'host-name 'string
+  "A Host name."
+  :tag "Host")
+
+(defcustom package-get-remote nil
   "*List of remote sites to contact for downloading packages.
 List format is '(site-name directory-on-site).  Each site is tried in
 order until the package is found.  As a special case, `site-name' can be
 `nil', in which case `directory-on-site' is treated as a local directory."
   :tag "Package repository"
   :type '(repeat (choice (list :tag "Local" (const :tag "Local" nil) directory )
-			 (list :tag "Remote" string string) ))
+			 (list :tag "Remote" host-name directory) ))
   :group 'package-get)
 
-(defcustom package-get-remove-copy nil
+(defcustom package-get-download-sites
+  '(
+    ;; North America
+    ("xemacs.org" "ftp.xemacs.org" "pub/xemacs/packages")
+    ("cso.uiuc.edu" "ftp.cso.uiuc.edu" "pub/packages/xemacs/packages")
+
+    ;; South America
+    ("unicamp.br" "ftp.unicamp.br" "pub/xemacs/packages")
+
+    ;; Europe
+    ("sunsite.cnlab-switch.ch" "sunsite.cnlab-switch.ch" "mirror/xemacs/packages")
+    ("tu-darmstadt.de" "ftp.tu-darmstadt.de" "pub/editors/xemacs/packages")
+    ("sunsite.auc.dk" "sunsite.auc.dk" "pub/emacs/xemacs/packages")
+    ("pasteur.fr" "ftp.pasteur.fr" "pub/computing/xemacs/packages")
+    ("cenatls.cena.dgac.fr" "ftp.cenatls.cena.dgac.fr" "pub/Emacs/xemacs/packages")
+    ("kfki.hu" "ftp.kfki.hu" "pub/packages/xemacs/packages")
+    ("uniroma2.it" "ftp.uniroma2.it" "unix/misc/dist/XEMACS/packages")
+    ("icm.edu.pl" "ftp.icm.edu.pl" "pub/unix/editors/xemacs/packages")
+    ("sunet.se" "ftp.sunet.se" "pub/gnu/xemacs/packages")
+    ("doc.ic.ac.uk" "ftp.doc.ic.ac.uk" "packages/xemacs/packages")
+    ("srcc.msu.su" "ftp1.srcc.msu.su" "mirror/ftp.xemacs.org/packages")
+
+    ;; Asia
+    ("usyd.edu.au" "ftp.usyd.edu.au" "pub/Xemacs/packages")
+    ("netlab.is.tsukuba.ac.jp" "ftp.netlab.is.tsukuba.ac.jp" "pub/GNU/xemacs/packages")
+    ("jaist.ac.jp" "ftp.jaist.ac.jp" "pub/GNU/xemacs/packages")
+    ("ring.aist.go.jp" "ring.aist.go.jp" "pub/text/xemacs/packages")
+    ("ring.asahi-net.or.jp" "ring.asahi-net.or.jp" "pub/text/xemacs/packages")
+    ("SunSITE.sut.ac.jp" "SunSITE.sut.ac.jp" "pub/archives/packages/xemacs/packages")
+    ("dti.ad.jp" "ftp.dti.ad.jp" "pub/unix/editor/xemacs/packages")
+    ("kreonet.re.kr" "ftp.kreonet.re.kr" "pub/tools/emacs/xemacs/packages")
+    )
+  "*List of remote sites available for downloading packages.
+List format is '(site-description site-name directory-on-site).
+SITE-DESCRIPTION is a textual description of the site.  SITE-NAME
+is the internet address of the download site.  DIRECTORY-ON-SITE
+is the directory on the site in which packages may be found.
+This variable is used to initialize `package-get-remote', the
+variable actually used to specify package download sites."
+  :tag "Package download sites"
+  :type '(repeat (list hostname directory))
+  :group 'package-get)
+
+(defcustom package-get-remove-copy t
   "*After copying and installing a package, if this is T, then remove the
 copy.  Otherwise, keep it around."
   :type 'boolean
   :group 'package-get)
 
-(defcustom package-get-base-filename
-  "/ftp.xemacs.org:/pub/xemacs/packages/package-index.LATEST"
-  "*Name of the default package database file, usually on ftp.xemacs.org."
+;; #### it may make sense for this to be a list of names.
+;; #### also, should we rename "*base*" to "*index*" or "*db*"?
+;;      "base" is a pretty poor name.
+(defcustom package-get-base-filename "package-index.LATEST.pgp"
+  "*Name of the default package-get database file.
+This may either be a relative path, in which case it is interpreted
+with respect to `package-get-remote', or an absolute path."
   :type 'file
   :group 'package-get)
 
+(defcustom package-get-always-update nil
+  "*If Non-nil always make sure we are using the latest package index (base).
+Otherwise respect the `force-current' argument of `package-get-require-base'."
+  :type 'boolean
+  :group 'package-get)
+
+(defcustom package-get-require-signed-base-updates t
+  "*If set to a non-nil value, require explicit user confirmation for updates
+to the package-get database which cannot have their signature verified via PGP.
+When nil, updates which are not PGP signed are allowed without confirmation."
+  :type 'boolean
+  :group 'package-get)
+
+(defvar package-get-was-current nil
+  "Non-nil we did our best to fetch a current database.")
+
 ;;;###autoload
-(defun package-get-require-base ()
-  "Require that a package-get database has been loaded."
-  (when (or (not (boundp 'package-get-base))
-            (not package-get-base))
-    (package-get-update-base))
-  (when (or (not (boundp 'package-get-base))
-            (not package-get-base))
-    (error "Package-get database not loaded")))
+(defun package-get-download-menu ()
+  "Build the `Add Download Site' menu."
+  (mapcar (lambda (site)
+            (vector (car site)
+                    `(push (quote ,(cdr site))
+                           package-get-remote)))
+          package-get-download-sites))
+
+;;;###autoload
+(defun package-get-require-base (&optional force-current)
+  "Require that a package-get database has been loaded.
+If the optional FORCE-CURRENT argument or the value of
+`package-get-always-update' is Non-nil, try to update the database
+from a location in `package-get-remote'. Otherwise a local copy is used
+if available and remote access is never done.
+
+Please use FORCE-CURRENT only when the user is explictly dealing with packages
+and remote access is likely in the near future."
+  (setq force-current (or force-current package-get-always-update))
+  (unless (and (boundp 'package-get-base)
+	       package-get-base
+	       (or (not force-current) package-get-was-current))
+    (package-get-update-base nil force-current))
+  (if (or (not (boundp 'package-get-base))
+	  (not package-get-base))
+      (error "Package-get database not loaded")
+    (setq package-get-was-current force-current)))
 
 (defconst package-get-pgp-signed-begin-line "^-----BEGIN PGP SIGNED MESSAGE-----"
   "Text for start of PGP signed messages.")
@@ -204,21 +293,72 @@
 ;;;###autoload
 (defun package-get-update-base-entry (entry)
   "Update an entry in `package-get-base'."
-  (let ((existing (assoc (car entry) package-get-base)))
+  (let ((existing (assq (car entry) package-get-base)))
     (if existing
         (setcdr existing (cdr entry))
-      (setq package-get-base (cons entry package-get-base)))))
+      (setq package-get-base (cons entry package-get-base))
+      (package-get-custom-add-entry (car entry) (car (cdr entry))))))
+
+(defun package-get-locate-file (file &optional nil-if-not-found no-remote)
+  "Locate an existing FILE with respect to `package-get-remote'.
+If FILE is an absolute path or is not found, simply return FILE.
+If optional argument NIL-IF-NOT-FOUND is non-nil, return nil
+if FILE can not be located.
+If NO-REMOTE is non-nil never search remote locations."
+  (if (file-name-absolute-p file)
+      file
+    (let ((entries package-get-remote)
+          (expanded nil))
+      (while entries
+	(unless (and no-remote (caar entries))
+	  (let ((expn (package-get-remote-filename (car entries) file)))
+	    (if (and expn (file-exists-p expn))
+		(setq entries  nil
+		      expanded expn))))
+        (setq entries (cdr entries)))
+      (or expanded
+          (and (not nil-if-not-found)
+               file)))))
+
+(defun package-get-locate-index-file (no-remote)
+  "Locate the package-get index file.  Do not return remote paths if NO-REMOTE
+is non-nil."
+  (or (package-get-locate-file package-get-base-filename t no-remote)
+      (locate-data-file package-get-base-filename)
+      package-get-base-filename))
+
+(defvar package-get-user-package-location user-init-directory)
+
+(defun package-get-maybe-save-index (filename)
+  "Offer to save the current buffer as the local package index file,
+if different."
+  (let ((location (package-get-locate-index-file t)))
+    (unless (and filename (equal filename location))
+      (unless (equal (md5 (current-buffer))
+		     (with-temp-buffer
+		       (insert-file-contents location)
+		       (md5 (current-buffer))))
+	(unless (file-writable-p location)
+	  (setq location (expand-file-name package-get-base-filename
+		(expand-file-name "etc/" package-get-user-package-location))))
+	(when (y-or-n-p (concat "Update package index in" location "? "))
+	  (write-file location))))))
+      
 
 ;;;###autoload
-(defun package-get-update-base (&optional db-file)
-  "Update the package-get database file with entries from DB-FILE."
-  (interactive (list
-                (read-file-name "Load package-get database: "
-                                (file-name-directory package-get-base-filename)
-                                package-get-base-filename
-                                t
-                                (file-name-nondirectory package-get-base-filename))))
-  (setq db-file (expand-file-name (or db-file package-get-base-filename)))
+(defun package-get-update-base (&optional db-file force-current)
+  "Update the package-get database file with entries from DB-FILE.
+Unless FORCE-CURRENT is non-nil never try to update the database."
+  (interactive
+   (let ((dflt (package-get-locate-index-file nil)))
+     (list (read-file-name "Load package-get database: "
+                           (file-name-directory dflt)
+                           dflt
+                           t
+                           (file-name-nondirectory dflt)))))
+  (setq db-file (expand-file-name (or db-file
+                                      (package-get-locate-index-file
+				         (not force-current)))))
   (if (not (file-exists-p db-file))
       (error "Package-get database file `%s' does not exist" db-file))
   (if (not (file-readable-p db-file))
@@ -229,7 +369,9 @@
           (set-buffer buf)
           (erase-buffer buf)
           (insert-file-contents-internal db-file)
-          (package-get-update-base-from-buffer buf))
+          (package-get-update-base-from-buffer buf)
+	  (if (file-remote-p db-file)
+	      (package-get-maybe-save-index db-file)))
       (kill-buffer buf))))
 
 ;;;###autoload
@@ -253,7 +395,8 @@
       (when (re-search-forward package-get-pgp-signature-end-line nil t)
         (setq end (point)))
       (if (not (and content-beg content-end beg end))
-          (or (yes-or-no-p "Package-get entries not PGP signed, continue? ")
+          (or (not package-get-require-signed-base-updates)
+              (yes-or-no-p "Package-get entries not PGP signed, continue? ")
               (error "Package-get database not updated")))
       (if (and content-beg content-end beg end)
           (if (not (condition-case nil
@@ -261,7 +404,8 @@
                            (load-library "mc-pgp")
                            (fboundp 'mc-pgp-verify-region))
                      (error nil)))
-              (or (yes-or-no-p
+              (or (not package-get-require-signed-base-updates)
+                  (yes-or-no-p
                    "No mailcrypt; can't verify package-get DB signature, continue? ")
                   (error "Package-get database not updated"))))
       (if (and beg end
@@ -271,10 +415,13 @@
                         (mc-pgp-verify-region beg end)
                       (file-error
                        (and (string-match "No such file" (nth 2 err))
-                            (yes-or-no-p
-                             "Can't find PGP, continue without package-get DB verification? ")))
+                            (or (not package-get-require-signed-base-updates)
+                                (yes-or-no-p
+                                 (concat "Can't find PGP, continue without "
+                                         "package-get DB verification? ")))))
                       (t nil)))))
           (error "Package-get PGP signature failed to verify"))
+      ;; ToDo: We shoud call package-get-maybe-save-index on the region
       (package-get-update-base-entries content-beg content-end)
       (message "Updated package-get database"))))
 
@@ -299,12 +446,45 @@
           (setq count (1+ count))))
       (message "Got %d package-get database entries" count))))
 
+;;;###autoload
+(defun package-get-save-base (file)
+  "Write the package-get database to FILE.
+
+Note: This database will be unsigned of course."
+  (interactive "FSave package-get database to: ")
+  (package-get-require-base t)
+  (let ((buf (get-buffer-create "*package database*")))
+    (unwind-protect
+        (save-excursion
+          (set-buffer buf)
+          (erase-buffer buf)
+          (goto-char (point-min))
+          (let ((entries package-get-base) entry plist)
+            (insert ";; Package Index file -- Do not edit manually.\n")
+            (insert ";;;@@@\n")
+            (while entries
+              (setq entry (car entries))
+              (setq plist (car (cdr entry)))
+              (insert "(package-get-update-base-entry (quote\n")
+              (insert (format "(%s\n" (symbol-name (car entry))))
+              (while plist
+                (insert (format "  %s%s %S\n"
+                                (if (eq plist (car (cdr entry))) "(" " ")
+                                (symbol-name (car plist))
+                                (car (cdr plist))))
+                (setq plist (cdr (cdr plist))))
+              (insert "))\n))\n;;;@@@\n")
+              (setq entries (cdr entries))))
+          (insert ";; Package Index file ends here\n")
+          (write-region (point-min) (point-max) file))
+      (kill-buffer buf))))
+
 (defun package-get-interactive-package-query (get-version package-symbol)
   "Perform interactive querying for package and optional version.
 Query for a version if GET-VERSION is non-nil.  Return package name as
 a symbol instead of a string if PACKAGE-SYMBOL is non-nil.
 The return value is suitable for direct passing to `interactive'."
-  (package-get-require-base)
+  (package-get-require-base t)
   (let ( (table (mapcar '(lambda (item)
 			   (let ( (name (symbol-name (car item))) )
 			     (cons name name)
@@ -347,7 +527,7 @@
 (defun package-get-update-all ()
   "Fetch and install the latest versions of all currently installed packages."
   (interactive)
-  (package-get-require-base)
+  (package-get-require-base t)
   ;; Load a fresh copy
   (catch 'exit
     (mapcar (lambda (pkg)
@@ -392,7 +572,7 @@
       (while this-requires
 	(if (not (member (car this-requires) fetched-packages))
 	    (let* ((reqd-package (package-get-package-provider
-				  (car this-requires)))
+				  (car this-requires) t))
 		   (reqd-version (cadr reqd-package))
 		   (reqd-name (car reqd-package)))
 	      (if (null reqd-name)
@@ -415,7 +595,7 @@
 Uses `package-get-base' to determine just what is required and what
 package provides that functionality.  Returns the list of packages
 required by PACKAGES."
-  (package-get-require-base)
+  (package-get-require-base t)
   (let ((orig-packages packages)
         dependencies provided)
     (while packages
@@ -509,10 +689,13 @@
 successfully installed but errors occurred during initialization, or
 `nil' upon error."
   (interactive (package-get-interactive-package-query nil t))
+  (catch 'skip-update
   (let* ((this-package
 	  (package-get-info-version
 	   (package-get-info-find-package package-get-base
 					  package) version))
+         (latest (package-get-info-prop this-package 'version))
+         (installed (package-get-key package :version))
 	 (this-requires (package-get-info-prop this-package 'requires))
 	 (found nil)
 	 (search-dirs package-get-remote)
@@ -529,6 +712,22 @@
 	  (package-admin-get-install-dir package install-dir
 		(or (eq package 'mule-base) (memq 'mule-base this-requires))))
 
+    ;; If they asked for the latest using version=nil, don't get an older
+    ;; version than we already have.
+    (if installed
+        (if (> (if (stringp installed)
+                   (string-to-number installed)
+                 installed)
+               (if (stringp latest)
+                   (string-to-number latest)
+                 latest))
+            (if (not (null version))
+                (warn "Installing %s package version %s, you had a newer version %s"
+                      package latest installed)
+              (warn "Skipping %s package, you have a newer version %s"
+                    package installed)
+              (throw 'skip-update t))))
+
     ;; Contrive a list of possible package filenames.
     ;; Ugly.  Is there a better way to do this?
     (setq filenames (cons base-filename nil))
@@ -537,7 +736,7 @@
 				(list (concat (match-string 1 base-filename)
 					      ".tgz")))))
 
-    (setq version (package-get-info-prop this-package 'version))
+    (setq version latest)
     (unless (and (eq conflict 'never)
 		 (package-get-installedp package version))
       ;; Find the package from the search list in package-get-remote
@@ -657,7 +856,7 @@
     (if (and found package-get-remove-copy)
 	(delete-file full-package-filename))
     package-status
-    ))
+    )))
 
 (defun package-get-info-find-package (which name)
   "Look in WHICH for the package called NAME and return all the info
@@ -758,13 +957,16 @@
 	 (if (floatp version) version (string-to-number version))))
 
 ;;;###autoload
-(defun package-get-package-provider (sym)
+(defun package-get-package-provider (sym &optional force-current)
   "Search for a package that provides SYM and return the name and
   version.  Searches in `package-get-base' for SYM.   If SYM is a
   consp, then it must match a corresponding (provide (SYM VERSION)) from 
-  the package."
+  the package.
+
+If FORCE-CURRENT is non-nil make sure the database is up to date. This might
+lead to Emacs accessing remote sites."
   (interactive "SSymbol: ")
-  (package-get-require-base)
+  (package-get-require-base force-current)
   (let ((packages package-get-base)
 	(done nil)
 	(found nil))
@@ -774,12 +976,14 @@
 	(while (and (not done) this-package)
 	  (if (or (eq this-name sym)
 		  (eq (cons this-name
-			    (package-get-info-prop (car this-package) 'version))
+			  (package-get-info-prop (car this-package) 'version))
 		      sym)
-		  (member sym (package-get-info-prop (car this-package) 'provides)))
+		  (member sym
+			(package-get-info-prop (car this-package) 'provides)))
 	      (progn (setq done t)
-		     (setq found (list (caar packages)
-				       (package-get-info-prop (car this-package) 'version))))
+		     (setq found
+		       (list (caar packages)
+			 (package-get-info-prop (car this-package) 'version))))
 	    (setq this-package (cdr this-package)))))
       (setq packages (cdr packages)))
     found))
@@ -796,12 +1000,12 @@
 (defun package-get-custom ()
   "Fetch and install the latest versions of all customized packages."
   (interactive)
-  (package-get-require-base)
+  (package-get-require-base t)
   ;; Load a fresh copy
   (load "package-get-custom.el")
   (mapcar (lambda (pkg)
 	    (if (eval (intern (concat (symbol-name (car pkg)) "-package")))
-		(package-get-all (car pkg) nil))
+		(package-get (car pkg) nil))
 	    t)
 	  package-get-base))
 
@@ -814,83 +1018,26 @@
 	(intern (substring (symbol-name pkg) 0 (match-beginning 0))))
        t)))
 
-(defun package-get-file-installed-p (file &optional paths)
-  "Return absolute-path of FILE if FILE exists in PATHS.
-If PATHS is omitted, `load-path' is used."
-  (if (null paths)
-      (setq paths load-path)
-    )
-  (catch 'tag
-    (let (path)
-      (while paths
-	(setq path (expand-file-name file (car paths)))
-	(if (file-exists-p path)
-	    (throw 'tag path)
-	  )
-	(setq paths (cdr paths))
-	))))
-
-(defun package-get-create-custom ()
-  "Creates a package customization file package-get-custom.el.
-Entries in the customization file are retrieved from package-get-base.el."
-  (interactive)
-  ;; Load a fresh copy
-  (let ((custom-buffer (find-file-noselect 
-			(or (package-get-file-installed-p 
-			     "package-get-custom.el")
-			    (expand-file-name
-			     "package-get-custom.el"
-			     (file-name-directory 
-			      (package-get-file-installed-p 
-			       "package-get-base.el"))
-			     ))))
-	(pkg-groups nil))
-
-    ;; clear existing stuff
-    (delete-region (point-min custom-buffer) 
-		   (point-max custom-buffer) custom-buffer)
-    (insert-string "(require 'package-get)\n" custom-buffer)
+(defvar package-get-custom-groups nil
+  "List of package-get-custom groups")
 
-    (mapcar (lambda (pkg)
-	      (let ((category (plist-get (car (cdr pkg)) 'category)))
-		(or (memq (intern category) pkg-groups)
-		    (progn
-		      (setq pkg-groups (cons (intern category) pkg-groups))
-		      (insert-string 
-		       (concat "(defgroup " category "-packages nil\n"
-			       "  \"" category " package group\"\n"
-			       "  :group 'packages)\n\n") custom-buffer)))
-		
-		(insert-string 
-		 (concat "(defcustom " (symbol-name (car pkg)) 
-			 "-package nil \n"
-			 "  \"" (plist-get (car (cdr pkg)) 'description) "\"\n"
-			 "  :group '" category "-packages\n"
-			 "  :initialize 'package-get-ever-installed-p\n"
-			 "  :type 'boolean)\n\n") custom-buffer)))
-	    package-get-base) custom-buffer)
-  )
+(defun package-get-custom-add-entry (package props)
+  (let* ((category (plist-get props 'category))
+         (group (intern (concat category "-packages")))
+         (custom-var (intern (concat (symbol-name package) "-package")))
+         (description (plist-get props 'description)))
+    (when (not (memq group package-get-custom-groups))
+      (setq package-get-custom-groups (cons package
+                                            package-get-custom-groups))
+      (eval `(defgroup ,group nil
+               ,(concat category " package group")
+               :group 'packages)))
+    (eval `(defcustom ,custom-var nil
+             ,description
+             :group ',group
+             :initialize 'package-get-ever-installed-p
+             :type 'boolean))))
 
-;; need this first to avoid infinite dependency loops
+
 (provide 'package-get)
-
-;; potentially update the custom dependencies every time we load this
-(when nil ;; #### disable for now... -gk
-(unless noninteractive
-(let ((custom-file (package-get-file-installed-p "package-get-custom.el"))
-      (package-file (package-get-file-installed-p "package-get-base.el")))
-  ;; update custom file if it doesn't exist
-  (if (or (not custom-file)
-	  (and (< (car (nth 5 (file-attributes custom-file)))
-		  (car (nth 5 (file-attributes package-file))))
-	       (< (car (nth 5 (file-attributes custom-file)))
-		  (car (nth 5 (file-attributes package-file))))))
-      (save-excursion
-	(message "generating package customizations...")
-	(set-buffer (package-get-create-custom))
-	(save-buffer)
-	(message "generating package customizations...done")))
-  (load "package-get-custom.el")))
-)
-
 ;;; package-get.el ends here
--- a/lisp/package-ui.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/package-ui.el	Mon Aug 13 11:05:42 2007 +0200
@@ -213,9 +213,15 @@
 (defun pui-package-symbol-char (pkg-sym version)
   (progn
     (if (package-get-info-find-package packages-package-list pkg-sym)
-	(if (package-get-installedp pkg-sym version)
-	    (list " " pui-up-to-date-package-face)
-	  (list "*" pui-outdated-package-face))
+        (let ((installed (package-get-key pkg-sym :version)))
+          (if (>= (if (stringp installed)
+                      (string-to-number installed)
+                    installed)
+                  (if (stringp version)
+                      (string-to-number version)
+                    version))
+              (list " " pui-up-to-date-package-face)
+            (list "*" pui-outdated-package-face)))
       (list "-" pui-uninstalled-package-face))
     ))
 
@@ -332,8 +338,8 @@
 		(message "Installing selected packages ...") (sit-for 0)
 		(if (catch 'done
 		      (mapcar (lambda (pkg)
-				(if (not (package-get pkg
-					pui-package-install-dest-dir))
+				(if (not (package-get pkg nil nil
+                                                      pui-package-install-dest-dir))
 				    (throw 'done nil)))
 			      pui-selected-packages)
 		      t)
@@ -353,7 +359,26 @@
   (interactive)
   (let ((tmpbuf "*Required-Packages*") do-select)
     (if pui-selected-packages
-	(let ((dependencies (package-get-dependencies pui-selected-packages)))
+	(let ((dependencies
+               (delq nil (mapcar
+                          (lambda (pkg)
+                            (let ((installed
+                                   (package-get-key pkg :version))
+                                  (current
+                                   (package-get-info-prop
+                                    (package-get-info-version
+                                     (package-get-info-find-package
+                                      package-get-base pkg) nil)
+                                    'version)))
+                              (if (< (if (stringp installed)
+                                         (string-to-number installed)
+                                       installed)
+                                     (if (stringp current)
+                                         (string-to-number current)
+                                       current))
+                                  pkg
+                                nil)))
+                          (package-get-dependencies pui-selected-packages)))))
 	  ;; Don't change window config when asking the user if he really
 	  ;; wants to add the packages.  We do this to avoid messing up
 	  ;; the window configuration if errors occur (we don't want to
@@ -471,7 +496,7 @@
 which are out-of-date (a newer version is available).  The user can then
 select packages for installation via the keyboard or mouse."
   (interactive)
-  (package-get-require-base)
+  (package-get-require-base t)
   (let ( (outbuf (get-buffer-create pui-info-buffer))
 	 (sep-string "===============================================================================\n")
 	 start )
--- a/lisp/process.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/process.el	Mon Aug 13 11:05:42 2007 +0200
@@ -245,6 +245,7 @@
     (let ((buffer (get-buffer-create
 		   (or output-buffer "*Shell Command Output*")))
 	  (success nil)
+	  (exit-status nil)
 	  (directory default-directory))
       (unwind-protect
 	  (if (eq buffer (current-buffer))
@@ -254,9 +255,10 @@
 	      (progn (setq buffer-read-only nil)
 		     (delete-region (max start end) (point-max))
 		     (delete-region (point-min) (max start end))
-		     (call-process-region (point-min) (point-max)
-					  shell-file-name t t nil
-					  shell-command-switch command)
+		     (setq exit-status
+			   (call-process-region (point-min) (point-max)
+						shell-file-name t t nil
+						shell-command-switch command))
 		     (setq success t))
 	    ;; Clear the output buffer, 
 	    ;; then run the command with output there.
@@ -266,9 +268,10 @@
 	      ;; XEmacs change
 	      (setq default-directory directory)
 	      (erase-buffer))
-	    (call-process-region start end shell-file-name
-				 nil buffer nil
-				 shell-command-switch command)
+	    (setq exit-status
+		  (call-process-region start end shell-file-name
+				       nil buffer nil
+				       shell-command-switch command))
 	    (setq success t))
 	;; Report the amount of output.
 	(let ((lines (save-excursion
@@ -280,7 +283,9 @@
 		 (if success
 		     (display-message
 		      'command
-		      "(Shell command completed with no output)"))
+		      (if (eql exit-status 0)
+			  "(Shell command succeeded with no output)"
+			"(Shell command failed with no output)")))
 		 (kill-buffer buffer))
 		((and success (= lines 1))
 		 (message "%s"
--- a/lisp/subr.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/subr.el	Mon Aug 13 11:05:42 2007 +0200
@@ -540,11 +540,12 @@
 
 ;;;; Miscellanea.
 
-(defun buffer-substring-no-properties (beg end)
-  "Return the text from BEG to END, without text properties, as a string."
-  (let ((string (buffer-substring beg end)))
-    (set-text-properties 0 (length string) nil string)
-    string))
+;; This is now in C.
+;(defun buffer-substring-no-properties (beg end)
+;  "Return the text from BEG to END, without text properties, as a string."
+;  (let ((string (buffer-substring beg end)))
+;    (set-text-properties 0 (length string) nil string)
+;    string))
 
 (defun get-buffer-window-list (&optional buffer minibuf frame)
   "Return windows currently displaying BUFFER, or nil if none.
--- a/lisp/wid-edit.el	Mon Aug 13 11:04:53 2007 +0200
+++ b/lisp/wid-edit.el	Mon Aug 13 11:05:42 2007 +0200
@@ -1063,48 +1063,49 @@
 
 (defun widget-button-click (event)
   "Invoke button below mouse pointer."
-  (interactive "@e")
-  (cond ((event-glyph event)
-	 (widget-glyph-click event))
-	((widget-event-point event)
-	 (let* ((pos (widget-event-point event))
-		(button (get-char-property pos 'button)))
-	   (if button
-	       (let* ((extent (widget-get button :button-extent))
-		      (face (extent-property extent 'face))
-		      (mouse-face (extent-property extent 'mouse-face))
-		      (help-echo (extent-property extent 'help-echo)))
-		 (unwind-protect
-		     (progn
-		       ;; Merge relevant faces, and make the result mouse-face.
-		       (let ((merge `(widget-button-pressed-face ,mouse-face)))
-			 (nconc merge (if (listp face)
-					  face (list face)))
-			 (setq merge (delete-if-not 'find-face merge))
-			 (set-extent-property extent 'mouse-face merge))
-		       (unless (widget-apply button :mouse-down-action event)
-			 ;; Wait for button release.
-			 (while (not (button-release-event-p
-				      (setq event (next-event))))
-			   (dispatch-event event)))
-		       ;; Disallow mouse-face and help-echo.
-		       (set-extent-property extent 'mouse-face nil)
-		       (set-extent-property extent 'help-echo nil)
-		       (setq pos (widget-event-point event))
-		       (unless (eq (current-buffer) (extent-object extent))
-			 ;; Barf if dispatch-event tripped us by
-			 ;; changing buffer.
-			 (error "Buffer changed during mouse motion"))
-		       ;; Do the associated action.
-		       (when (and pos (extent-in-region-p extent pos pos))
-			 (widget-apply-action button event)))
-		   ;; Unwinding: fully release the button.
-		   (set-extent-property extent 'mouse-face mouse-face)
-		   (set-extent-property extent 'help-echo help-echo)))
-	     ;; This should not happen!
-	     (error "`widget-button-click' called outside button"))))
-	(t
-	 (message "You clicked somewhere weird"))))
+  (interactive "e")
+  (with-current-buffer (event-buffer event)
+    (cond ((event-glyph event)
+	   (widget-glyph-click event))
+	  ((widget-event-point event)
+	   (let* ((pos (widget-event-point event))
+		  (button (get-char-property pos 'button)))
+	     (if button
+		 (let* ((extent (widget-get button :button-extent))
+			(face (extent-property extent 'face))
+			(mouse-face (extent-property extent 'mouse-face))
+			(help-echo (extent-property extent 'help-echo)))
+		   (unwind-protect
+		       (progn
+			 ;; Merge relevant faces, and make the result mouse-face.
+			 (let ((merge `(widget-button-pressed-face ,mouse-face)))
+			   (nconc merge (if (listp face)
+					    face (list face)))
+			   (setq merge (delete-if-not 'find-face merge))
+			   (set-extent-property extent 'mouse-face merge))
+			 (unless (widget-apply button :mouse-down-action event)
+			   ;; Wait for button release.
+			   (while (not (button-release-event-p
+					(setq event (next-event))))
+			     (dispatch-event event)))
+			 ;; Disallow mouse-face and help-echo.
+			 (set-extent-property extent 'mouse-face nil)
+			 (set-extent-property extent 'help-echo nil)
+			 (setq pos (widget-event-point event))
+			 (unless (eq (current-buffer) (extent-object extent))
+			   ;; Barf if dispatch-event tripped us by
+			   ;; changing buffer.
+			   (error "Buffer changed during mouse motion"))
+			 ;; Do the associated action.
+			 (when (and pos (extent-in-region-p extent pos pos))
+			   (widget-apply-action button event)))
+		     ;; Unwinding: fully release the button.
+		     (set-extent-property extent 'mouse-face mouse-face)
+		     (set-extent-property extent 'help-echo help-echo)))
+	       ;; This should not happen!
+	       (error "`widget-button-click' called outside button"))))
+	  (t
+	   (message "You clicked somewhere weird")))))
 
 (defun widget-button1-click (event)
   "Invoke glyph below mouse pointer."
--- a/man/ChangeLog	Mon Aug 13 11:04:53 2007 +0200
+++ b/man/ChangeLog	Mon Aug 13 11:05:42 2007 +0200
@@ -1,3 +1,7 @@
+1998-11-28  SL Baur  <steve@altair.xemacs.org>
+
+	* XEmacs 21.2-beta4 is released.
+
 1998-10-15  SL Baur  <steve@altair.xemacs.org>
 
 	* XEmacs 21.2-beta3 is released.
--- a/man/internals/internals.texi	Mon Aug 13 11:04:53 2007 +0200
+++ b/man/internals/internals.texi	Mon Aug 13 11:05:42 2007 +0200
@@ -2045,7 +2045,7 @@
 @menu
 * Character-Related Data Types::
 * Working With Character and Byte Positions::
-* Conversion of External Data::
+* Conversion to and from External Data::
 * General Guidelines for Writing Mule-Aware Code::
 * An Example of Mule-Aware Code::
 @end menu
@@ -2053,9 +2053,9 @@
 @node Character-Related Data Types
 @subsection Character-Related Data Types
 
-First, we will list the basic character-related datatypes used by
-XEmacs.  Note that the separate @code{typedef}s are not required for the 
-code to work (all of them boil down to @code{unsigned char} or
+First, let's review the basic character-related datatypes used by
+XEmacs.  Note that the separate @code{typedef}s are not mandatory in the
+current implementation (all of them boil down to @code{unsigned char} or
 @code{int}), but they improve clarity of code a great deal, because one
 glance at the declaration can tell the intended use of the variable.
 
@@ -2093,6 +2093,8 @@
 
 @item Bufpos
 @itemx Charcount
+@cindex Bufpos
+@cindex Charcount
 A @code{Bufpos} represents a character position in a buffer or string.
 A @code{Charcount} represents a number (count) of characters.
 Logically, subtracting two @code{Bufpos} values yields a
@@ -2105,6 +2107,8 @@
 
 @item Bytind
 @itemx Bytecount
+@cindex Bytind
+@cindex Bytecount
 A @code{Bytind} represents a byte position in a buffer or string.  A
 @code{Bytecount} represents the distance between two positions in bytes.
 The relationship between @code{Bytind} and @code{Bytecount} is the same
@@ -2112,6 +2116,8 @@
 
 @item Extbyte
 @itemx Extcount
+@cindex Extbyte
+@cindex Extcount
 When dealing with the outside world, XEmacs works with @code{Extbyte}s,
 which are equivalent to @code{unsigned char}.  Obviously, an
 @code{Extcount} is the distance between two @code{Extbyte}s.  Extbytes
@@ -2130,6 +2136,7 @@
 
 @table @code
 @item MAX_EMCHAR_LEN
+@cindex MAX_EMCHAR_LEN
 This preprocessor constant is the maximum number of buffer bytes per
 Emacs character, i.e. the byte length of an @code{Emchar}.  It is useful
 when allocating temporary strings to keep a known number of characters.
@@ -2155,10 +2162,12 @@
 Without Mule, it is 1.
 
 @item charptr_emchar
-@item set_charptr_emchar
-@code{charptr_emchar} macro takes a @code{Bufbyte} pointer and returns
-the underlying @code{Emchar}.  If it were a function, its prototype
-would be:
+@itemx set_charptr_emchar
+@cindex charptr_emchar
+@cindex set_charptr_emchar
+The @code{charptr_emchar} macro takes a @code{Bufbyte} pointer and
+returns the @code{Emchar} stored at that position.  If it were a
+function, its prototype would be:
 
 @example
 Emchar charptr_emchar (Bufbyte *p);
@@ -2200,14 +2209,19 @@
 
 @item INC_CHARPTR
 @itemx DEC_CHARPTR
+@cindex INC_CHARPTR
+@cindex DEC_CHARPTR
 These two macros increment and decrement a @code{Bufbyte} pointer,
-respectively.  The pointer needs to be correctly positioned at the
-beginning of a valid character position.
+respectively.  They will adjust the pointer by the appropriate number of
+bytes according to the byte length of the character stored there.  Both
+macros assume that the memory address is located at the beginning of a
+valid character.
 
 Without Mule support, @code{INC_CHARPTR (p)} and @code{DEC_CHARPTR (p)}
 simply expand to @code{p++} and @code{p--}, respectively.
 
 @item bytecount_to_charcount
+@cindex bytecount_to_charcount
 Given a pointer to a text string and a length in bytes, return the
 equivalent length in characters.
 
@@ -2216,6 +2230,7 @@
 @end example
 
 @item charcount_to_bytecount
+@cindex charcount_to_bytecount
 Given a pointer to a text string and a length in characters, return the
 equivalent length in bytes.
 
@@ -2224,6 +2239,7 @@
 @end example
 
 @item charptr_n_addr
+@cindex charptr_n_addr
 Return a pointer to the beginning of the character offset @var{cc} (in
 characters) from @var{p}.
 
@@ -2232,55 +2248,118 @@
 @end example
 @end table
 
-@node Conversion of External Data
-@subsection Conversion of External Data
+@node Conversion to and from External Data
+@subsection Conversion to and from External Data
 
 When an external function, such as a C library function, returns a
-@code{char} pointer, you should never treat it as @code{Bufbyte}.  This
-is because these returned strings may contain 8bit characters which can
-be misinterpreted by XEmacs, and cause a crash.  Instead, you should use
-a conversion macro.  Many different conversion macros are defined in
-@file{buffer.h}, so I will try to order them logically, by direction and
-by format.
-
-Thus the basic conversion macros are @code{GET_CHARPTR_INT_DATA_ALLOCA}
-and @code{GET_CHARPTR_EXT_DATA_ALLOCA}.  The former is used to convert
-external data to internal format, and the latter is used to convert the
-other way around.  The arguments each of these receives are @var{ptr}
-(pointer to the text in external format), @var{len} (length of texts in
-bytes), @var{fmt} (format of the external text), @var{ptr_out} (lvalue
-to which new text should be copied), and @var{len_out} (lvalue which
-will be assigned the length of the internal text in bytes).  The
-resulting text is stored to a stack-allocated buffer.  If the text
-doesn't need changing, these macros will do nothing, except for setting
-@var{len_out}.
+@code{char} pointer, you should almost never treat it as @code{Bufbyte}.
+This is because these returned strings may contain 8bit characters which
+can be misinterpreted by XEmacs, and cause a crash.  Likewise, when
+exporting a piece of internal text to the outside world, you should
+always convert it to an appropriate external encoding, lest the internal 
+stuff (such as the infamous \201 characters) leak out.
+
+The interface to conversion between the internal and external
+representations of text are the numerous conversion macros defined in
+@file{buffer.h}.  Before looking at them, we'll look at the external
+formats supported by these macros.
 
 Currently meaningful formats are @code{FORMAT_BINARY},
-@code{FORMAT_FILENAME}, @code{FORMAT_OS}, and @code{FORMAT_CTEXT}.
-
-The two macros above take many arguments which makes them unwieldy.  For
-this reason, several convenience macros are defined with obvious
-functionality, but accepting less arguments:
+@code{FORMAT_FILENAME}, @code{FORMAT_OS}, and @code{FORMAT_CTEXT}.  Here 
+is a description of these.
 
 @table @code
-@item GET_C_CHARPTR_EXT_DATA_ALLOCA
-@itemx GET_C_CHARPTR_INT_DATA_ALLOCA
-These two macros work on ``C char pointers'', which are zero-terminated, 
-and thus do not need @var{len} or @var{len_out} parameters.
+@item FORMAT_BINARY
+Binary format.  This is the simplest format and is what we use in the
+absence of a more appropriate format.  This converts according to the
+@code{binary} coding system:
+
+@enumerate a
+@item
+On input, bytes 0--255 are converted into characters 0--255.
+@item
+On output, characters 0--255 are converted into bytes 0--255 and other
+characters are converted into `X'.
+@end enumerate
+
+@item FORMAT_FILENAME
+Format used for filenames.  In the original Mule, this is user-definable
+with the @code{pathname-coding-system} variable.  For the moment, we
+just use the @code{binary} coding system.
+
+@item FORMAT_OS
+Format used for the external Unix environment---@code{argv[]}, stuff
+from @code{getenv()}, stuff from the @file{/etc/passwd} file, etc.
+
+Perhaps should be the same as FORMAT_FILENAME.
+
+@item FORMAT_CTEXT
+Compound--text format.  This is the standard X format used for data
+stored in properties, selections, and the like.  This is an 8-bit
+no-lock-shift ISO2022 coding system.
+@end table
+
+The macros to convert between these formats and the internal format, and 
+vice versa, follow.
+
+@table @code
+@item GET_CHARPTR_INT_DATA_ALLOCA
+@itemx GET_CHARPTR_EXT_DATA_ALLOCA
+These two are the most basic conversion macros.
+@code{GET_CHARPTR_INT_DATA_ALLOCA} converts external data to internal
+format, and @code{GET_CHARPTR_EXT_DATA_ALLOCA} converts the other way
+around.  The arguments each of these receives are @var{ptr} (pointer to
+the text in external format), @var{len} (length of texts in bytes),
+@var{fmt} (format of the external text), @var{ptr_out} (lvalue to which
+new text should be copied), and @var{len_out} (lvalue which will be
+assigned the length of the internal text in bytes).  The resulting text
+is stored to a stack-allocated buffer.  If the text doesn't need
+changing, these macros will do nothing, except for setting
+@var{len_out}.
+
+The macros above take many arguments which makes them unwieldy.  For
+this reason, a number of convenience macros are defined with obvious
+functionality, but accepting less arguments.  The general rule is that
+macros with @samp{INT} in their name convert text to internal Emacs
+representation, whereas the @samp{EXT} macros convert to external
+representation.
+
+@item GET_C_CHARPTR_INT_DATA_ALLOCA
+@itemx GET_C_CHARPTR_EXT_DATA_ALLOCA
+As their names imply, these macros work on C char pointers, which are
+zero-terminated, and thus do not need @var{len} or @var{len_out}
+parameters.
 
 @item GET_STRING_EXT_DATA_ALLOCA
 @itemx GET_C_STRING_EXT_DATA_ALLOCA
-These two macros work on Lisp strings, thus also not needing a @var{len}
-parameter.  However, @code{GET_STRING_EXT_DATA_ALLOCA} still provides a
-@var{len_out} parameter.  Note that for Lisp strings only one conversion
-direction makes sense.
+These two macros convert a Lisp string into an external representation.
+The difference between them is that @code{GET_STRING_EXT_DATA_ALLOCA}
+stores its output to a generic string, providing @var{len_out}, the
+length of the resulting external string.  On the other hand,
+@code{GET_C_STRING_EXT_DATA_ALLOCA} assumes that the caller will be
+satisfied with output string being zero-terminated.
+
+Note that for Lisp strings only one conversion direction makes sense.
 
 @item GET_C_CHARPTR_EXT_BINARY_DATA_ALLOCA
+@itemx GET_CHARPTR_EXT_BINARY_DATA_ALLOCA
+@itemx GET_STRING_BINARY_DATA_ALLOCA
+@itemx GET_C_STRING_BINARY_DATA_ALLOCA
 @itemx GET_C_CHARPTR_EXT_FILENAME_DATA_ALLOCA
-@itemx GET_C_CHARPTR_EXT_CTEXT_DATA_ALLOCA
 @itemx ...
-These macros are a combination of the above, but with the @var{fmt}
-argument encoded into the name of the macro.
+These macros convert internal text to a specific external
+representation, with the external format being encoded into the name of
+the macro.  Note that the @code{GET_STRING_...} and
+@code{GET_C_STRING...}  macros lack the @samp{EXT} tag, because they
+only make sense in that direction.
+
+@item GET_C_CHARPTR_INT_BINARY_DATA_ALLOCA
+@itemx GET_CHARPTR_INT_BINARY_DATA_ALLOCA
+@itemx GET_C_CHARPTR_INT_FILENAME_DATA_ALLOCA
+@itemx ...
+These macros convert external text of a specific format to its internal
+representation, with the external format being incoded into the name of
+the macro.
 @end table
 
 @node General Guidelines for Writing Mule-Aware Code
--- a/man/lispref/text.texi	Mon Aug 13 11:04:53 2007 +0200
+++ b/man/lispref/text.texi	Mon Aug 13 11:05:42 2007 +0200
@@ -53,6 +53,7 @@
                        position stored in a register.
 * Transposition::    Swapping two portions of a buffer.
 * Change Hooks::     Supplying functions to be run when text is changed.
+* Transformations::  MD5 and base64 support.
 @end menu
 
 @node Near Point
@@ -2668,3 +2669,139 @@
 This variable is a normal hook that is run whenever a buffer is changed
 that was previously in the unmodified state.
 @end defvar
+
+@node Transformations
+@section Textual transformations---MD5 and base64 support
+@cindex MD5 digests
+@cindex base64
+
+Some textual operations inherently require examining each character in
+turn, and performing arithmetic operations on them.  Such operations
+can, of course, be implemented in Emacs Lisp, but tend to be very slow
+for large portions of text or data.  This is why some of them are
+implemented in C, with an appropriate interface for Lisp programmers.
+Examples of algorithms thus provided are MD5 and base64 support.
+
+MD5 is an algorithm for calculating message digests, as described in
+rfc1321.  Given a message of arbitrary length, MD5 produces an 128-bit
+``fingerprint'' (``message digest'') corresponding to that message.  It
+is considered computationally infeasible to produce two messages having
+the same MD5 digest, or to produce a message having a prespecified
+target digest.  MD5 is used heavily by various authentication schemes.
+
+Emacs Lisp interface to MD5 consists of a single function @code{md5}:
+
+@defun md5 object &optional start end
+This function returns the MD5 message digest of @var{object}, a buffer
+or string.
+
+Optional arguments @var{start} and @var{end} denote positions for
+computing the digest of a portion of @var{object}.
+
+Some examples of usage:
+
+@example
+@group
+;; @r{Calculate the digest of the entire buffer}
+(md5 (current-buffer))
+     @result{} "8842b04362899b1cda8d2d126dc11712"
+@end group
+
+@group
+;; @r{Calculate the digest of the current line}
+(md5 (current-buffer) (point-at-bol) (point-at-eol))
+     @result{} "60614d21e9dee27dfdb01fa4e30d6d00"
+@end group
+
+@group
+;; @r{Calculate the digest of your name and email address}
+(md5 (concat (format "%s <%s>" (user-full-name) user-mail-address)))
+     @result{} "0a2188c40fd38922d941fe6032fce516"
+@end group
+@end example
+@end defun
+
+Base64 is a portable encoding for arbitrary sequences of octets, in a
+form that need not be readable by humans.  It uses a 65-character subset
+of US-ASCII, as described in rfc2045.  Base64 is used by MIME to encode
+binary bodies, and to encode binary characters in message headers.
+
+The Lisp interface to base64 consists of four functions:
+
+@defun base64-encode-region beg end &optional no-line-break
+This function encodes the region between @var{beg} and @var{end} of the
+current buffer to base64 format.  This means that the original region is 
+deleted, and replaced with its base64 equivalent.
+
+Normally, encoded base64 output is multi-line, with 76-character lines.
+If @var{no-line-break} is non-@code{nil}, newlines will not be inserted, 
+resulting in single-line output.
+
+Mule note: you should make sure that you convert the multibyte
+characters (those that do not fit into 0--255 range) to something else,
+because they cannot be meaningfully converted to base64.  If the
+@code{base64-encode-region} encounters such characters, it will signal
+an error.
+
+@code{base64-encode-region} returns the length of the encoded text.
+
+@example
+@group
+;; @r{Encode the whole buffer in base64}
+(base64-encode-region (point-min) (point-max))
+@end group
+@end example
+
+The function can also be used interactively, in which case it works on
+the currently active region.
+@end defun
+
+@defun base64-encode-string string
+This function encodes @var{string} to base64, and returns the encoded
+string.
+
+For Mule, the same considerations apply as for
+@code{base64-encode-region}.
+
+@example
+@group
+(base64-encode-string "fubar")
+    @result{} "ZnViYXI="
+@end group
+@end example
+@end defun
+
+@defun base64-decode-region beg end
+This function decodes the region between @var{beg} and @var{end} of the
+current buffer.  The region should be in base64 encoding.
+
+If the region was decoded correctly, @code{base64-decode-region} returns
+the length of the decoded region.  If the decoding failed, @code{nil} is 
+returned.
+
+@example
+@group
+;; @r{Decode a base64 buffer, and replace it with the decoded version}
+(base64-decode-region (point-min) (point-max))
+@end group
+@end example
+@end defun
+
+@defun base64-decode-string string
+This function decodes @var{string} to base64, and returns the decoded
+string.  @var{string} should be valid base64-encoded text.
+
+If encoding was not possible, @code{nil} is returned.
+
+@example
+@group
+(base64-decode-string "ZnViYXI=")
+    @result{} "fubar"
+@end group
+
+@group
+(base64-decode-string "totally bogus")
+    @result{} nil
+@end group
+@end example
+@end defun
--- a/nt/ChangeLog	Mon Aug 13 11:04:53 2007 +0200
+++ b/nt/ChangeLog	Mon Aug 13 11:05:42 2007 +0200
@@ -1,3 +1,12 @@
+1998-11-28  SL Baur  <steve@altair.xemacs.org>
+
+	* XEmacs 21.2-beta4 is released.
+
+1998-10-29  Andy Piper  <andyp@parallax.co.uk>
+
+	* xemacs.mak ($(LIB_SRC)/movemail.exe): add etags dependencies to
+	pull in getopt and friends.
+
 1998-10-15  SL Baur  <steve@altair.xemacs.org>
 
 	* XEmacs 21.2-beta3 is released.
--- a/nt/xemacs.mak	Mon Aug 13 11:04:53 2007 +0200
+++ b/nt/xemacs.mak	Mon Aug 13 11:05:42 2007 +0200
@@ -439,7 +439,7 @@
 # Individual dependencies
 ETAGS_DEPS = $(LIB_SRC)/getopt.c $(LIB_SRC)/getopt1.c $(LIB_SRC)/../src/regex.c
 $(LIB_SRC)/etags.exe : $(LIB_SRC)/etags.c $(ETAGS_DEPS)
-#### ootags???
+$(LIB_SRC)/movemail.exe: $(LIB_SRC)/movemail.c $(ETAGS_DEPS)
 
 LIB_SRC_TOOLS = \
 	$(LIB_SRC)/make-docfile.exe	\
--- a/src/ChangeLog	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/ChangeLog	Mon Aug 13 11:05:42 2007 +0200
@@ -1,3 +1,165 @@
+1998-11-28  SL Baur  <steve@altair.xemacs.org>
+
+	* XEmacs 21.2-beta4 is released.
+
+1998-11-27  SL Baur  <steve@altair.xemacs.org>
+
+	* mule-charset.c (complex_vars_of_mule_charset): Fix graphic
+	property in control-1 charset.
+	From Julian Bradfield <jcb@daimi.au.dk>
+
+1998-11-26  Jan Vroonhof  <vroonhof@math.ethz.ch>
+
+	* gui-x.c (button_item_to_widget_value): Ignore :key-sequence
+	keyword.
+	Add stub for :label.
+
+	* gui.c (gui_item_add_keyval_pair): ditto.
+
+	* menubar-x.c (menu_item_descriptor_to_widget_value_1): Ignore
+	:key-sequence keyword.
+	Add stub for:label.
+	Support :active for submenus like the Windows code and FSF Emacs.
+
+1998-11-27  Hrvoje Niksic  <hniksic@srce.hr>
+
+	* dired.c (make_directory_hash_table): make_string() is OK because 
+	readdir() Mule-encapsulates.
+
+1998-11-26  Hrvoje Niksic  <hniksic@srce.hr>
+
+	* fns.c (Fbase64_encode_string): Fix docstring.
+	(Fbase64_decode_string): Ditto.
+
+1998-11-26  Hrvoje Niksic  <hniksic@srce.hr>
+
+	* editfns.c (Ftranslate_region): Use
+	convert_bufbyte_string_into_emchar_string().
+
+1998-11-25  Hrvoje Niksic  <hniksic@srce.hr>
+
+	* editfns.c (Ftranslate_region): Accept vectors and char-tables as 
+	well as strings.
+	(Ftranslate_region): Turn table into an array of Emchars for
+	larger regions.
+
+1998-11-25  Hrvoje Niksic  <hniksic@srce.hr>
+
+	* chartab.c (Freset_char_table): Fix wrong placement of #endif.
+
+1998-11-24  Hrvoje Niksic  <hniksic@srce.hr>
+
+	* chartab.c (Freset_char_table): Don't blindly fill chartables of
+	type `char' with nils.
+
+	* chartab.c (canonicalize_char_table_value): Coerce ints to chars
+	for tables of type `char'.
+
+1998-11-26  Didier Verna  <verna@inf.enst.fr>
+
+	* input-method-xlib.c (Initialize_Locale): don't call
+	XtSetLanguageProc. We've done the whole work here.
+	* input-method-xfs.c (Initialize_Locale): ditto.
+	* input-method-motif.c (Initialize_Locale): ditto.
+
+1998-11-26  Didier Verna  <verna@inf.enst.fr>
+
+	* process-unix.c (unix_create_process): handle properly
+	Vfile_name_coding_system for converting the program and directory
+	names. 
+
+1998-11-27  SL Baur  <steve@altair.xemacs.org>
+
+	* m/arm.h: New file.
+	From James LewisMoss <dres@ioa.com>
+
+1998-11-27  Takeshi Hagiwara  <hagiwara@ie.niigata-u.ac.jp>
+
+	* m/mips-nec.h:
+	Fix the realpath() problem of UnixWare2.1.3.
+	Patches for NEC's sysv4.2 machine.
+
+1998-11-25  Hrvoje Niksic  <hniksic@srce.hr>
+
+	* dired.c (Fdirectory_files): Remove redundant code.
+
+1998-11-25  Hrvoje Niksic  <hniksic@srce.hr>
+
+	* fns.c (free_malloced_ptr): New function.
+	(XMALLOC_OR_ALLOCA): New macro.
+	(XMALLOC_UNBIND): Ditto.
+	(Fbase64_encode_region): Use malloc() for large blocks; arrange it 
+	to be freed in case of non-local exit.
+	(Fbase64_encode_string): Ditto.
+	(Fbase64_decode_region): Ditto.
+	(Fbase64_decode_string): Ditto.
+	(STORE_BYTE): New macro.
+	(base64_decode_1): Use it.
+
+1998-11-25  Hrvoje Niksic  <hniksic@srce.hr>
+
+	* fns.c (base64_value_to_char): Base64 stuff.
+
+1998-11-24  Hrvoje Niksic  <hniksic@srce.hr>
+
+	* editfns.c (Fbuffer_substring): New function.
+
+	* lisp.h: Declare make_string_from_buffer_no_extents().
+
+	* insdel.c (make_string_from_buffer_1): New function.
+	(make_string_from_buffer_no_extents): Ditto.
+
+1998-11-15  Michael Sperber [Mr. Preprocessor]  <sperber@informatik.uni-tuebingen.de>
+
+	* linuxplay.c: Including <fcntl.h> instead of <sys/fcntl.h> makes
+	sound work on AIX with OSS installed.  Linux should still work.
+
+1998-11-03  Andy Piper  <andyp@parallax.co.uk>
+
+	* config.h.in: name change for cygwin/version.h
+
+	* configure.in: check for cygwin/version.h now.
+
+	* cygwin32.h: track CYGWIN_DLL_VERSION_MAJOR ->
+	CYGWIN_VERSION_DLL_MAJOR name change in cygwin b20.
+	move cygwin32/version.h to cygwin/version.h
+
+1998-11-03  Olivier Galibert  <galibert@pobox.com>
+
+	* lisp.h  (struct  Lisp_Bit_Vector): Fix declaration of  bits from
+	int to long.
+
+1998-10-22  Andy Piper  <andyp@parallax.co.uk>
+
+	* cygwin32.h: track CYGWIN_DLL_VERSION_MAJOR ->
+	CYGWIN_VERSION_DLL_MAJOR name change in cygwin b20.
+	enable BROKEN_SIGIO under b20 to make QUIT work.
+
+1998-10-22  Andy Piper  <andyp@parallax.co.uk>
+
+	* frame-msw.c (mswindows_size_frame_internal): force frame sizing
+	to fit within the constraints of the screen size. I.e. make the
+	frame small enough to fit and move it if some of it will be
+	off-screen.
+
+1998-10-19  Greg Klanderman  <greg@alphatech.com>
+
+	* dired.c: conditionalize inclusion of user-name-completion
+	primitives on non-Windows NT.  The needed functions don't exist on NT.
+
+1998-11-24  SL Baur  <steve@altair.xemacs.org>
+
+	* gifrlib.h: Clean up types for 64 bit compile.
+	* dgif_lib.c (DGifInitRead): Ditto.
+	(MakeSavedImage): Ditto.
+	* emacs.c (decode_path): Ditto.
+	From Steve Carney <carney@pa.dec.com>
+
+1998-10-16  William M. Perry  <wmperry@aventail.com>
+
+	* glyphs-msw.c (bitmap_table): Fixed typo in builtin bitmaps
+	  (cehckboxes instead of checkboxes).
+
 1998-10-15  SL Baur  <steve@altair.xemacs.org>
 
 	* XEmacs 21.2-beta3 is released.
--- a/src/chartab.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/chartab.c	Mon Aug 13 11:05:42 2007 +0200
@@ -552,13 +552,15 @@
   switch (ct->type)
     {
     case CHAR_TABLE_TYPE_CHAR:
+      fill_char_table (ct, make_char (0));
+      break;
     case CHAR_TABLE_TYPE_DISPLAY:
     case CHAR_TABLE_TYPE_GENERIC:
 #ifdef MULE
     case CHAR_TABLE_TYPE_CATEGORY:
+#endif /* MULE */
       fill_char_table (ct, Qnil);
       break;
-#endif /* MULE */
 
     case CHAR_TABLE_TYPE_SYNTAX:
       fill_char_table (ct, make_int (Sinherit));
@@ -775,7 +777,7 @@
 
 #endif /* MULE */
 
-static Lisp_Object
+Lisp_Object
 get_char_table (Emchar ch, struct Lisp_Char_Table *ct)
 {
 #ifdef MULE
@@ -987,6 +989,10 @@
 	  CHECK_CHAR_COERCE_INT (cdr);
 	  return Fcons (car, cdr);
 	}
+      break;
+    case CHAR_TABLE_TYPE_CHAR:
+      CHECK_CHAR_COERCE_INT (value);
+      break;
     default:
       break;
     }
--- a/src/chartab.h	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/chartab.h	Mon Aug 13 11:05:42 2007 +0200
@@ -180,6 +180,7 @@
 void fill_char_table (struct Lisp_Char_Table *ct, Lisp_Object value);
 void put_char_table (struct Lisp_Char_Table *ct, struct chartab_range *range,
 		     Lisp_Object val);
+Lisp_Object get_char_table (Emchar, struct Lisp_Char_Table *);
 int map_char_table (struct Lisp_Char_Table *ct,
 		    struct chartab_range *range,
 		    int (*fn) (struct chartab_range *range,
--- a/src/config.h.in	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/config.h.in	Mon Aug 13 11:05:42 2007 +0200
@@ -194,7 +194,7 @@
 #undef HAVE_ULIMIT_H
 #undef HAVE_X11_XLOCALE_H
 #undef HAVE_LINUX_VERSION_H
-#undef HAVE_CYGWIN32_VERSION_H
+#undef HAVE_CYGWIN_VERSION_H
 #undef HAVE_INTTYPES_H
 #undef HAVE_SYS_UN_H
 #undef HAVE_A_OUT_H
--- a/src/dgif_lib.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/dgif_lib.c	Mon Aug 13 11:05:42 2007 +0200
@@ -110,7 +110,7 @@
     /* The GIF Version number is ignored at this time. Maybe we should do    */
     /* something more useful with it.					     */
     Buf[GIF_STAMP_LEN] = 0;
-    if (strncmp(GIF_STAMP, Buf, GIF_VERSION_POS) != 0) {
+    if (strncmp(GIF_STAMP, (const char *) Buf, GIF_VERSION_POS) != 0) {
 	GifInternError(GifFile, D_GIF_ERR_NOT_GIF_FILE);
     }
 
@@ -856,7 +856,7 @@
 				  CopyFrom->ImageDesc.ColorMap->Colors);
 
 	    /* next, the raster */
-	    sp->RasterBits = (char *)malloc(sizeof(GifPixelType)
+	    sp->RasterBits = (GifPixelType*)malloc(sizeof(GifPixelType)
 				* CopyFrom->ImageDesc.Height
 				* CopyFrom->ImageDesc.Width);
 	    memcpy(sp->RasterBits,
--- a/src/dired.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/dired.c	Mon Aug 13 11:05:42 2007 +0200
@@ -376,9 +376,7 @@
 	  dp = readdir (d);
 	  if (!dp) break;
 
-	  /* #### This is a bad idea, because d_name can contain
-             control characters, which can make XEmacs crash.  This
-             should be handled properly with FORMAT_FILENAME.  */
+	  /* Cast to Bufbyte* is OK, as readdir() Mule-encapsulates.  */
 	  d_name = (Bufbyte *) dp->d_name;
 	  len = NAMLEN (dp);
 	  cclen = bytecount_to_charcount (d_name, len);
@@ -531,6 +529,10 @@
 }
 
 
+
+/* The *pwent() functions do not exist on NT */
+#ifndef  WINDOWSNT
+
 static Lisp_Object user_name_completion (Lisp_Object user,
                                          int all_flag,
                                          int *uniq);
@@ -775,6 +777,7 @@
     return Qt;
   return Fsubstring (bestmatch, Qzero, make_int (bestmatchsize));
 }
+#endif   /* ! defined WINDOWSNT */
 
 
 Lisp_Object
@@ -791,8 +794,8 @@
 	{
 	  Bytecount len = NAMLEN (dp);
 	  if (DIRENTRY_NONEMPTY (dp))
-	    Fputhash (make_ext_string ((Bufbyte *) dp->d_name, len,
-				       FORMAT_FILENAME), Qt, hash);
+	    /* Cast to Bufbyte* is OK, as readdir() Mule-encapsulates.  */
+	    Fputhash (make_string ((Bufbyte *) dp->d_name, len), Qt, hash);
 	}
       closedir (d);
     }
@@ -938,9 +941,11 @@
   DEFSUBR (Fdirectory_files);
   DEFSUBR (Ffile_name_completion);
   DEFSUBR (Ffile_name_all_completions);
+#ifndef  WINDOWSNT
   DEFSUBR (Fuser_name_completion);
   DEFSUBR (Fuser_name_completion_1);
   DEFSUBR (Fuser_name_all_completions);
+#endif
   DEFSUBR (Ffile_attributes);
 }
 
--- a/src/editfns.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/editfns.c	Mon Aug 13 11:05:42 2007 +0200
@@ -39,6 +39,7 @@
 #include "frame.h"
 #include "insdel.h"
 #include "window.h"
+#include "chartab.h"
 #include "line-number.h"
 
 #include "systime.h"
@@ -1622,6 +1623,23 @@
   return make_string_from_buffer (b, begv, zv - begv);
 }
 
+/* It might make more sense to name this
+   `buffer-substring-no-extents', but this name is FSFmacs-compatible,
+   and what the function does is probably good enough for what the
+   user-code will typically want to use it for. */
+DEFUN ("buffer-substring-no-properties", Fbuffer_substring_no_properties, 0, 3, 0, /*
+Return the text from BEG to END, as a string, without copying the extents.
+*/
+       (start, end, buffer))
+{
+  /* This function can GC */
+  Bufpos begv, zv;
+  struct buffer *b = decode_buffer (buffer, 1);
+
+  get_buffer_range_char (b, start, end, &begv, &zv, GB_ALLOW_NIL);
+  return make_string_from_buffer_no_extents (b, begv, zv - begv);
+}
+
 DEFUN ("insert-buffer-substring", Finsert_buffer_substring, 1, 3, 0, /*
 Insert before point a substring of the contents of buffer BUFFER.
 BUFFER may be a buffer or a buffer name.
@@ -1783,42 +1801,149 @@
   return Qnil;
 }
 
+/* #### Shouldn't this also accept a BUFFER argument, in the good old
+   XEmacs tradition?  */
 DEFUN ("translate-region", Ftranslate_region, 3, 3, 0, /*
-From START to END, translate characters according to TABLE.
-TABLE is a string; the Nth character in it is the mapping
-for the character with code N.  Returns the number of characters changed.
+Translate characters from START to END according to TABLE.
+
+If TABLE is a string, the Nth character in it is the mapping for the
+character with code N.
+
+If TABLE is a vector, its Nth element is the mapping for character
+with code N.  The values of elements may be characters, strings, or
+nil (nil meaning don't replace.)
+
+If TABLE is a char-table, its elements describe the mapping between
+characters and their replacements.  The char-table should be of type
+`char' or `generic'.
+
+Returns the number of substitutions performed.
 */
        (start, end, table))
 {
   /* This function can GC */
   Bufpos pos, stop;	/* Limits of the region. */
-  REGISTER Emchar oc;		/* Old character. */
-  REGISTER Emchar nc;		/* New character. */
-  int cnt;		/* Number of changes made. */
-  Charcount size;	/* Size of translate table. */
+  int cnt = 0;		/* Number of changes made. */
   int mc_count;
   struct buffer *buf = current_buffer;
+  Emchar oc;
 
   get_buffer_range_char (buf, start, end, &pos, &stop, 0);
-  CHECK_STRING (table);
-
-  size = XSTRING_CHAR_LENGTH (table);
-
-  cnt = 0;
   mc_count = begin_multiple_change (buf, pos, stop);
-  for (; pos < stop; pos++)
+  if (STRINGP (table))
     {
-      oc = BUF_FETCH_CHAR (buf, pos);
-      if (oc >= 0 && oc < size)
+      struct Lisp_String *stable = XSTRING (table);
+      Charcount size = string_char_length (stable);
+#ifdef MULE
+      /* Under Mule, string_char(n) is O(n), so for large tables or
+         large regions it makes sense to create an array of Emchars.  */
+      if (size * (stop - pos) > 65536)
 	{
-	  nc = string_char (XSTRING (table), oc);
-	  if (nc != oc)
+	  Emchar *etable = alloca_array (Emchar, size);
+	  convert_bufbyte_string_into_emchar_string
+	    (string_data (stable), string_length (stable), etable);
+	  for (; pos < stop && (oc = BUF_FETCH_CHAR (buf, pos), 1); pos++)
 	    {
-	      buffer_replace_char (buf, pos, nc, 0, 0);
-	      ++cnt;
+	      if (oc < size)
+		{
+		  Emchar nc = etable[oc];
+		  if (nc != oc)
+		    {
+		      buffer_replace_char (buf, pos, nc, 0, 0);
+		      ++cnt;
+		    }
+		}
+	    }
+	}
+      else
+#endif /* MULE */
+	{
+	  for (; pos < stop && (oc = BUF_FETCH_CHAR (buf, pos), 1); pos++)
+	    {
+	      if (oc < size)
+		{
+		  Emchar nc = string_char (stable, oc);
+		  if (nc != oc)
+		    {
+		      buffer_replace_char (buf, pos, nc, 0, 0);
+		      ++cnt;
+		    }
+		}
 	    }
 	}
     }
+  else if (VECTORP (table))
+    {
+      Charcount size = XVECTOR_LENGTH (table);
+      Lisp_Object *vtable = XVECTOR_DATA (table);
+
+      for (; pos < stop && (oc = BUF_FETCH_CHAR (buf, pos), 1); pos++)
+	{
+	  if (oc < size)
+	    {
+	      Lisp_Object replacement = vtable[oc];
+	    retry:
+	      if (CHAR_OR_CHAR_INTP (replacement))
+		{
+		  Emchar nc = XCHAR_OR_CHAR_INT (replacement);
+		  if (nc != oc)
+		    {
+		      buffer_replace_char (buf, pos, nc, 0, 0);
+		      ++cnt;
+		    }
+		}
+	      else if (STRINGP (replacement))
+		{
+		  Charcount incr = XSTRING_CHAR_LENGTH (replacement) - 1;
+		  buffer_delete_range (buf, pos, pos + 1, 0);
+		  buffer_insert_lisp_string_1 (buf, pos, replacement, 0);
+		  pos += incr, stop += incr;
+		  ++cnt;
+		}
+	      else if (!NILP (replacement))
+		{
+		  replacement = wrong_type_argument (Qchar_or_string_p, replacement);
+		  goto retry;
+		}
+	    }
+	}
+    }
+  else if (CHAR_TABLEP (table)
+	   && (XCHAR_TABLE_TYPE (table) == CHAR_TABLE_TYPE_GENERIC
+	       || XCHAR_TABLE_TYPE (table) == CHAR_TABLE_TYPE_CHAR))
+    {
+      struct Lisp_Char_Table *ctable = XCHAR_TABLE (table);
+
+      for (; pos < stop && (oc = BUF_FETCH_CHAR (buf, pos), 1); pos++)
+	{
+	  Lisp_Object replacement = get_char_table (oc, ctable);
+	retry2:
+	  if (CHAR_OR_CHAR_INTP (replacement))
+	    {
+	      Emchar nc = XCHAR_OR_CHAR_INT (replacement);
+	      if (nc != oc)
+		{
+		  buffer_replace_char (buf, pos, nc, 0, 0);
+		  ++cnt;
+		}
+	    }
+	  else if (STRINGP (replacement))
+	    {
+	      Charcount incr = XSTRING_CHAR_LENGTH (replacement) - 1;
+	      buffer_delete_range (buf, pos, pos + 1, 0);
+	      buffer_insert_lisp_string_1 (buf, pos, replacement, 0);
+	      pos += incr, stop += incr;
+	      ++cnt;
+	    }
+	  else if (!NILP (replacement))
+	    {
+	      replacement = wrong_type_argument (Qchar_or_string_p, replacement);
+	      goto retry2;
+	    }
+	}
+    }
+  else
+    dead_wrong_type_argument (Qstringp, table);
   end_multiple_change (buf, mc_count);
 
   return make_int (cnt);
@@ -2263,6 +2388,7 @@
   DEFSUBR (Fstring_to_char);
   DEFSUBR (Fchar_to_string);
   DEFSUBR (Fbuffer_substring);
+  DEFSUBR (Fbuffer_substring_no_properties);
 
   DEFSUBR (Fpoint_marker);
   DEFSUBR (Fmark_marker);
--- a/src/emacs.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/emacs.c	Mon Aug 13 11:05:42 2007 +0200
@@ -2513,7 +2513,7 @@
 
   GET_C_CHARPTR_INT_FILENAME_DATA_ALLOCA (path, newpath);
 
-  len = strlen (newpath);
+  len = strlen ((const char *) newpath);
   /* #### Does this make sense?  It certainly does for
      decode_env_path(), but it looks dubious here.  Does any code
      depend on decode_path("") returning nil instead of an empty
--- a/src/fileio.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/fileio.c	Mon Aug 13 11:05:42 2007 +0200
@@ -3346,7 +3346,10 @@
     /* On VMS and APOLLO, must do the stat after the close
        since closing changes the modtime.  */
     /* As it does on Windows too - kkm */
-#if !defined (WINDOWSNT) /* !defined (VMS) && !defined (APOLLO) */
+    /* The spurious warnings appear on Linux too.  Rather than handling 
+       this on a per-system basis, unconditionally do the stat after the close - cgw */
+       
+#if 0 /* !defined (WINDOWSNT)  /* !defined (VMS) && !defined (APOLLO) */
     fstat (desc, &st);
 #endif
 
@@ -3364,9 +3367,9 @@
     unbind_to (speccount, Qnil);
   }
 
-#if defined (WINDOWSNT) /* defined (VMS) || defined (APOLLO) */
+  /* # if defined (WINDOWSNT) /* defined (VMS) || defined (APOLLO) */
   stat ((char *) XSTRING_DATA (fn), &st);
-#endif
+  /* #endif */
 
 #ifdef CLASH_DETECTION
   if (!auto_saving)
--- a/src/fns.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/fns.c	Mon Aug 13 11:05:42 2007 +0200
@@ -49,6 +49,9 @@
 #include "extents.h"
 #include "frame.h"
 #include "systime.h"
+#include "insdel.h"
+#include "lstream.h"
+#include "opaque.h"
 
 /* NOTE: This symbol is also used in lread.c */
 #define FEATUREP_SYNTAX
@@ -3522,7 +3525,428 @@
       return unbind_to (speccount, feature);
     }
 }
-
+
+/* base64 encode/decode functions.
+   Based on code from GNU recode. */
+
+#define MIME_LINE_LENGTH 76
+
+#define IS_ASCII(Character) \
+  ((Character) < 128)
+#define IS_BASE64(Character) \
+  (IS_ASCII (Character) && base64_char_to_value[Character] >= 0)
+
+/* Table of characters coding the 64 values.  */
+static char base64_value_to_char[64] =
+{
+  'A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J',	/*  0- 9 */
+  'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T',	/* 10-19 */
+  'U', 'V', 'W', 'X', 'Y', 'Z', 'a', 'b', 'c', 'd',	/* 20-29 */
+  'e', 'f', 'g', 'h', 'i', 'j', 'k', 'l', 'm', 'n',	/* 30-39 */
+  'o', 'p', 'q', 'r', 's', 't', 'u', 'v', 'w', 'x',	/* 40-49 */
+  'y', 'z', '0', '1', '2', '3', '4', '5', '6', '7',	/* 50-59 */
+  '8', '9', '+', '/'					/* 60-63 */
+};
+
+/* Table of base64 values for first 128 characters.  */
+static short base64_char_to_value[128] =
+{
+  -1,  -1,  -1,  -1,  -1,  -1,  -1,  -1,  -1,  -1,	/*   0-  9 */
+  -1,  -1,  -1,  -1,  -1,  -1,  -1,  -1,  -1,  -1,	/*  10- 19 */
+  -1,  -1,  -1,  -1,  -1,  -1,  -1,  -1,  -1,  -1,	/*  20- 29 */
+  -1,  -1,  -1,  -1,  -1,  -1,  -1,  -1,  -1,  -1,	/*  30- 39 */
+  -1,  -1,  -1,  62,  -1,  -1,  -1,  63,  52,  53,	/*  40- 49 */
+  54,  55,  56,  57,  58,  59,  60,  61,  -1,  -1,	/*  50- 59 */
+  -1,  -1,  -1,  -1,  -1,  0,   1,   2,   3,   4,	/*  60- 69 */
+  5,   6,   7,   8,   9,   10,  11,  12,  13,  14,	/*  70- 79 */
+  15,  16,  17,  18,  19,  20,  21,  22,  23,  24,	/*  80- 89 */
+  25,  -1,  -1,  -1,  -1,  -1,  -1,  26,  27,  28,	/*  90- 99 */
+  29,  30,  31,  32,  33,  34,  35,  36,  37,  38,	/* 100-109 */
+  39,  40,  41,  42,  43,  44,  45,  46,  47,  48,	/* 110-119 */
+  49,  50,  51,  -1,  -1,  -1,  -1,  -1			/* 120-127 */
+};
+
+/* The following diagram shows the logical steps by which three octets
+   get transformed into four base64 characters.
+
+		 .--------.  .--------.  .--------.
+		 |aaaaaabb|  |bbbbcccc|  |ccdddddd|
+		 `--------'  `--------'  `--------'
+                    6   2      4   4       2   6
+	       .--------+--------+--------+--------.
+	       |00aaaaaa|00bbbbbb|00cccccc|00dddddd|
+	       `--------+--------+--------+--------'
+
+	       .--------+--------+--------+--------.
+	       |AAAAAAAA|BBBBBBBB|CCCCCCCC|DDDDDDDD|
+	       `--------+--------+--------+--------'
+
+   The octets are divided into 6 bit chunks, which are then encoded into
+   base64 characters.  */
+
+#define ADVANCE_INPUT(c, stream)				\
+ (ec = Lstream_get_emchar (stream),				\
+  ec == -1 ? 0 :						\
+  ((ec > 255) ?							\
+   (error ("Non-ascii character detected in base64 input"), 0)	\
+   : (c = (Bufbyte)ec, 1)))
+
+static Bytind
+base64_encode_1 (Lstream *istream, Bufbyte *to, int line_break)
+{
+  EMACS_INT counter = 0;
+  Bufbyte *e = to;
+  Emchar ec;
+  unsigned int value;
+
+  while (1)
+    {
+      Bufbyte c;
+      if (!ADVANCE_INPUT (c, istream))
+	break;
+
+      /* Wrap line every 76 characters.  */
+      if (line_break)
+	{
+	  if (counter < MIME_LINE_LENGTH / 4)
+	    counter++;
+	  else
+	    {
+	      *e++ = '\n';
+	      counter = 1;
+	    }
+	}
+
+      /* Process first byte of a triplet.  */
+      *e++ = base64_value_to_char[0x3f & c >> 2];
+      value = (0x03 & c) << 4;
+
+      /* Process second byte of a triplet.  */
+      if (!ADVANCE_INPUT (c, istream))
+	{
+	  *e++ = base64_value_to_char[value];
+	  *e++ = '=';
+	  *e++ = '=';
+	  break;
+	}
+
+      *e++ = base64_value_to_char[value | (0x0f & c >> 4)];
+      value = (0x0f & c) << 2;
+
+      /* Process third byte of a triplet.  */
+      if (!ADVANCE_INPUT (c, istream))
+	{
+	  *e++ = base64_value_to_char[value];
+	  *e++ = '=';
+	  break;
+	}
+
+      *e++ = base64_value_to_char[value | (0x03 & c >> 6)];
+      *e++ = base64_value_to_char[0x3f & c];
+    }
+
+  /* Complete last partial line.  */
+  if (line_break)
+    if (counter > 0)
+      *e++ = '\n';
+
+  return e - to;
+}
+#undef ADVANCE_INPUT
+
+#define ADVANCE_INPUT(c, stream)		\
+ (ec = Lstream_get_emchar (stream),		\
+  ec == -1 ? 0 : (c = (Bufbyte)ec, 1))
+
+#define INPUT_EOF_P(stream)				\
+ (ADVANCE_INPUT (c2, stream)				\
+  ? (Lstream_unget_emchar (stream, (Emchar)c2), 0)	\
+  : 1)
+
+#define STORE_BYTE(pos, val) do {					\
+  pos += set_charptr_emchar (pos, (Emchar)((unsigned char)(val)));	\
+  ++*ccptr;								\
+} while (0)
+
+static Bytind
+base64_decode_1 (Lstream *istream, Bufbyte *to, Charcount *ccptr)
+{
+  EMACS_INT counter = 0;
+  Emchar ec;
+  Bufbyte *e = to;
+  unsigned long value;
+
+  *ccptr = 0;
+  while (1)
+    {
+      Bufbyte c, c2;
+
+      if (!ADVANCE_INPUT (c, istream))
+	break;
+
+      /* Accept wrapping lines, reversibly if at each 76 characters.  */
+      if (c == '\n')
+	{
+	  if (!ADVANCE_INPUT (c, istream))
+	    break;
+	  if (INPUT_EOF_P (istream))
+	    break;
+	  /* FSF Emacs has this check, apparently inherited from
+             recode.  However, I see no reason to be this picky about
+             line length -- why reject base64 with say 72-byte lines?
+             (yes, there are programs that generate them.)  */
+	  /*if (counter != MIME_LINE_LENGTH / 4) return -1;*/
+	  counter = 1;
+	}
+      else
+	counter++;
+
+      /* Process first byte of a quadruplet.  */
+      if (!IS_BASE64 (c))
+	return -1;
+      value = base64_char_to_value[c] << 18;
+
+      /* Process second byte of a quadruplet.  */
+      if (!ADVANCE_INPUT (c, istream))
+	return -1;
+
+      if (!IS_BASE64 (c))
+	return -1;
+      value |= base64_char_to_value[c] << 12;
+
+      STORE_BYTE (e, value >> 16);
+
+      /* Process third byte of a quadruplet.  */
+      if (!ADVANCE_INPUT (c, istream))
+	return -1;
+
+      if (c == '=')
+	{
+	  if (!ADVANCE_INPUT (c, istream))
+	    return -1;
+	  if (c != '=')
+	    return -1;
+	  continue;
+	}
+
+      if (!IS_BASE64 (c))
+	return -1;
+      value |= base64_char_to_value[c] << 6;
+
+      STORE_BYTE (e, 0xff & value >> 8);
+
+      /* Process fourth byte of a quadruplet.  */
+      if (!ADVANCE_INPUT (c, istream))
+	return -1;
+
+      if (c == '=')
+	continue;
+
+      if (!IS_BASE64 (c))
+	return -1;
+      value |= base64_char_to_value[c];
+
+      STORE_BYTE (e, 0xff & value);
+    }
+
+  return e - to;
+}
+#undef ADVANCE_INPUT
+#undef INPUT_EOF_P
+
+static Lisp_Object
+free_malloced_ptr (Lisp_Object unwind_obj)
+{
+  void *ptr = (void *)get_opaque_ptr (unwind_obj);
+  xfree (ptr);
+  free_opaque_ptr (unwind_obj);
+  return Qnil;
+}
+
+/* Don't use alloca for regions larger than this, lest we overflow
+   the stack.  */
+#define MAX_ALLOCA 65536
+
+/* We need to setup proper unwinding, because there is a number of
+   ways these functions can blow up, and we don't want to have memory
+   leaks in those cases.  */
+#define XMALLOC_OR_ALLOCA(ptr, len, type) do {			\
+  if ((len) > MAX_ALLOCA)					\
+    {								\
+      ptr = (type *)xmalloc ((len) * sizeof (type));		\
+      speccount = specpdl_depth ();				\
+      record_unwind_protect (free_malloced_ptr,			\
+			     make_opaque_ptr ((void *)ptr));	\
+    }								\
+  else								\
+    ptr = alloca_array (type, len);				\
+} while (0)
+
+#define XMALLOC_UNBIND(ptr, len) do {		\
+  if ((len) > MAX_ALLOCA)			\
+    unbind_to (speccount, Qnil);		\
+} while (0)
+
+DEFUN ("base64-encode-region", Fbase64_encode_region, 2, 3, "r", /*
+Base64-encode the region between BEG and END.
+Return the length of the encoded text.
+Optional third argument NO-LINE-BREAK means do not break long lines
+into shorter lines.
+*/
+       (beg, end, no_line_break))
+{
+  Bufbyte *encoded;
+  Bytind encoded_length;
+  Charcount allength, length;
+  struct buffer *buf = current_buffer;
+  Bufpos begv, zv, old_pt = BUF_PT (buf);
+  Lisp_Object input;
+  int speccount;
+
+  get_buffer_range_char (buf, beg, end, &begv, &zv, 0);
+
+  /* We need to allocate enough room for encoding the text.
+     We need 33 1/3% more space, plus a newline every 76
+     characters, and then we round up. */
+  length = zv - begv;
+  allength = length + length/3 + 1;
+  allength += allength / MIME_LINE_LENGTH + 1 + 6;
+
+  input = make_lisp_buffer_input_stream (buf, begv, zv, 0);
+  /* We needn't multiply allength with MAX_EMCHAR_LEN because all the
+     base64 characters will be single-byte.  */
+  XMALLOC_OR_ALLOCA (encoded, allength, Bufbyte);
+  encoded_length = base64_encode_1 (XLSTREAM (input), encoded,
+				    NILP (no_line_break));
+  if (encoded_length > allength)
+    abort ();
+  Lstream_delete (XLSTREAM (input));
+
+  /* Now we have encoded the region, so we insert the new contents
+     and delete the old.  (Insert first in order to preserve markers.)  */
+  buffer_insert_raw_string_1 (buf, begv, encoded, encoded_length, 0);
+  XMALLOC_UNBIND (encoded, allength);
+  buffer_delete_range (buf, begv + encoded_length, zv + encoded_length, 0);
+
+  /* Simulate FSF Emacs: if point was in the region, place it at the
+     beginning.  */
+  if (old_pt >= begv && old_pt < zv)
+    BUF_SET_PT (buf, begv);
+
+  /* We return the length of the encoded text. */
+  return make_int (encoded_length);
+}
+
+DEFUN ("base64-encode-string", Fbase64_encode_string, 1, 1, 0, /*
+Base64 encode STRING and return the result.
+*/
+       (string))
+{
+  Charcount allength, length;
+  Bytind encoded_length;
+  Bufbyte *encoded;
+  Lisp_Object input, result;
+  int speccount;
+
+  CHECK_STRING (string);
+
+  length = XSTRING_CHAR_LENGTH (string);
+  allength = length + length/3 + 1 + 6;
+
+  input = make_lisp_string_input_stream (string, 0, -1);
+  XMALLOC_OR_ALLOCA (encoded, allength, Bufbyte);
+  encoded_length = base64_encode_1 (XLSTREAM (input), encoded, 0);
+  if (encoded_length > allength)
+    abort ();
+  Lstream_delete (XLSTREAM (input));
+  result = make_string (encoded, encoded_length);
+  XMALLOC_UNBIND (encoded, allength);
+  return result;
+}
+
+DEFUN ("base64-decode-region", Fbase64_decode_region, 2, 2, "r", /*
+Base64-decode the region between BEG and END.
+Return the length of the decoded text.
+If the region can't be decoded, return nil and don't modify the buffer.
+*/
+       (beg, end))
+{
+  struct buffer *buf = current_buffer;
+  Bufpos begv, zv, old_pt = BUF_PT (buf);
+  Bufbyte *decoded;
+  Bytind decoded_length;
+  Charcount length, cc_decoded_length;
+  Lisp_Object input;
+  int speccount;
+
+  get_buffer_range_char (buf, beg, end, &begv, &zv, 0);
+  length = zv - begv;
+
+  input = make_lisp_buffer_input_stream (buf, begv, zv, 0);
+  /* We need to allocate enough room for decoding the text. */
+  XMALLOC_OR_ALLOCA (decoded, length * MAX_EMCHAR_LEN, Bufbyte);
+  decoded_length = base64_decode_1 (XLSTREAM (input), decoded, &cc_decoded_length);
+  if (decoded_length > length * MAX_EMCHAR_LEN)
+    abort ();
+  Lstream_delete (XLSTREAM (input));
+
+  if (decoded_length < 0)
+    {
+      /* The decoding wasn't possible. */
+      XMALLOC_UNBIND (decoded, length * MAX_EMCHAR_LEN);
+      return Qnil;
+    }
+
+  /* Now we have decoded the region, so we insert the new contents
+     and delete the old.  (Insert first in order to preserve markers.)  */
+  BUF_SET_PT (buf, begv);
+  buffer_insert_raw_string_1 (buf, begv, decoded, decoded_length, 0);
+  XMALLOC_UNBIND (decoded, length * MAX_EMCHAR_LEN);
+  buffer_delete_range (buf, begv + cc_decoded_length,
+		       zv + cc_decoded_length, 0);
+
+  /* Simulate FSF Emacs: if point was in the region, place it at the
+     beginning.  */
+  if (old_pt >= begv && old_pt < zv)
+    BUF_SET_PT (buf, begv);
+
+  return make_int (cc_decoded_length);
+}
+
+DEFUN ("base64-decode-string", Fbase64_decode_string, 1, 1, 0, /*
+Base64-decode STRING and return the result.
+*/
+       (string))
+{
+  Bufbyte *decoded;
+  Bytind decoded_length;
+  Charcount length, cc_decoded_length;
+  Lisp_Object input, result;
+  int speccount;
+
+  CHECK_STRING (string);
+
+  length = XSTRING_CHAR_LENGTH (string);
+  /* We need to allocate enough room for decoding the text. */
+  XMALLOC_OR_ALLOCA (decoded, length * MAX_EMCHAR_LEN, Bufbyte);
+
+  input = make_lisp_string_input_stream (string, 0, -1);
+  decoded_length = base64_decode_1 (XLSTREAM (input), decoded,
+				    &cc_decoded_length);
+  if (decoded_length > length * MAX_EMCHAR_LEN)
+    abort ();
+  Lstream_delete (XLSTREAM (input));
+
+  if (decoded_length < 0)
+    {
+      return Qnil;
+      XMALLOC_UNBIND (decoded, length * MAX_EMCHAR_LEN);
+    }
+
+  result = make_string (decoded, decoded_length);
+  XMALLOC_UNBIND (decoded, length * MAX_EMCHAR_LEN);
+  return result;
+}
 
 Lisp_Object Qyes_or_no_p;
 
@@ -3608,6 +4032,10 @@
   DEFSUBR (Ffeaturep);
   DEFSUBR (Frequire);
   DEFSUBR (Fprovide);
+  DEFSUBR (Fbase64_encode_region);
+  DEFSUBR (Fbase64_encode_string);
+  DEFSUBR (Fbase64_decode_region);
+  DEFSUBR (Fbase64_decode_string);
 }
 
 void
--- a/src/frame-msw.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/frame-msw.c	Mon Aug 13 11:05:42 2007 +0200
@@ -26,6 +26,7 @@
    Ultimately based on FSF.
    Substantially rewritten for XEmacs by Ben Wing.
    Rewritten for mswindows by Jonathan Harris, November 1997 for 21.0.
+   Graphics features added and frame resizing fiddled with by Andy Piper.
  */
 
 #include <config.h>
@@ -594,7 +595,7 @@
   int pixel_width, pixel_height;
   int size_p = (dest->width >=0 || dest->height >=0);
   int move_p = (dest->top >=0 || dest->left >=0);
-
+  struct device* d = XDEVICE (FRAME_DEVICE (f));
   char_to_real_pixel_size (f, dest->width, dest->height, &pixel_width, &pixel_height);
   
   if (dest->width < 0)
@@ -607,7 +608,7 @@
     dest->left = rect.left;
   if (dest->top < 0)
     dest->top = rect.top;
-
+  
   rect.left = rect.top = 0;
   rect.right = pixel_width;
   rect.bottom = pixel_height;
@@ -617,12 +618,41 @@
 		      GetMenu (FRAME_MSWINDOWS_HANDLE(f)) != NULL,
 		      GetWindowLong (FRAME_MSWINDOWS_HANDLE(f), GWL_EXSTYLE));
 
+  /* resize and move the window so that it fits on the screen. This is
+  not restrictive since this will happen later anyway in WM_SIZE.  We
+  have to do this after adjusting the rect to account for menubar
+  etc. */
+  pixel_width = rect.right - rect.left;
+  pixel_height = rect.bottom - rect.top;
+  if (pixel_width > DEVICE_MSWINDOWS_HORZRES(d))
+    {
+      pixel_width = DEVICE_MSWINDOWS_HORZRES(d);
+      size_p=1;
+    }
+  if (pixel_height > DEVICE_MSWINDOWS_VERTRES(d))
+    {
+      pixel_height = DEVICE_MSWINDOWS_VERTRES(d);
+      size_p=1;
+    }
+
+  /* adjust position so window is on screen */
+  if (dest->left + pixel_width > DEVICE_MSWINDOWS_HORZRES(d))
+    {
+      dest->left = DEVICE_MSWINDOWS_HORZRES(d) - pixel_width;
+      move_p=1;
+    }
+  if (dest->top + pixel_height > DEVICE_MSWINDOWS_VERTRES(d))
+    {
+      dest->top = DEVICE_MSWINDOWS_VERTRES(d) - pixel_height;
+      move_p=1;
+    }
+
   if (IsIconic (FRAME_MSWINDOWS_HANDLE(f)) 
       || IsZoomed (FRAME_MSWINDOWS_HANDLE(f)))
     ShowWindow (FRAME_MSWINDOWS_HANDLE(f), SW_RESTORE);
 
   SetWindowPos (FRAME_MSWINDOWS_HANDLE(f), NULL, 
-		dest->left, dest->top, rect.right - rect.left, rect.bottom - rect.top,
+		dest->left, dest->top, pixel_width, pixel_height,
 		SWP_NOACTIVATE | SWP_NOZORDER | SWP_NOSENDCHANGING
 		| (size_p ? 0 : SWP_NOSIZE)
 		| (move_p ? 0 : SWP_NOMOVE));
--- a/src/gifrlib.h	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/gifrlib.h	Mon Aug 13 11:05:42 2007 +0200
@@ -167,15 +167,15 @@
 
 /* This is the in-core version of an extension record */
 typedef struct {
-    int		ByteCount;
-    char	*Bytes;		/* on malloc(3) heap */
+    int		    ByteCount;
+    GifByteType	*Bytes;		/* on malloc(3) heap */
 } ExtensionBlock;
 
 /* This holds an image header, its unpacked raster bits, and extensions */
 typedef struct SavedImage {
     GifImageDesc	ImageDesc;
 
-    char		*RasterBits;		/* on malloc(3) heap */
+    GifPixelType	*RasterBits;		/* on malloc(3) heap */
 
     int			Function;
     int			ExtensionBlockCount;
--- a/src/glyphs-msw.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/glyphs-msw.c	Mon Aug 13 11:05:42 2007 +0200
@@ -1041,7 +1041,7 @@
   { "size", OBM_SIZE },
   { "btsize", OBM_BTSIZE },
   { "check", OBM_CHECK },
-  { "cehckboxes", OBM_CHECKBOXES },
+  { "checkboxes", OBM_CHECKBOXES },
   { "btncorners" , OBM_BTNCORNERS },
   {0}
 };
--- a/src/gui.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/gui.c	Mon Aug 13 11:05:42 2007 +0200
@@ -29,8 +29,8 @@
 #include "bytecode.h"		/* for struct Lisp_Compiled_Function */
 
 Lisp_Object Q_active, Q_suffix, Q_keys, Q_style, Q_selected;
-Lisp_Object Q_filter, Q_config, Q_included;
-Lisp_Object Q_accelerator;
+Lisp_Object Q_filter, Q_config, Q_included, Q_key_sequence;
+Lisp_Object Q_accelerator, Q_label;
 Lisp_Object Qtoggle, Qradio;
 
 #ifdef HAVE_POPUPS
@@ -134,6 +134,8 @@
   else if (EQ (key, Q_style))	 pgui_item->style    = val;
   else if (EQ (key, Q_selected)) pgui_item->selected = val;
   else if (EQ (key, Q_keys))	 pgui_item->keys     = val;
+  else if (EQ (key, Q_key_sequence)) ;   /* ignored for FSF compatability */
+  else if (EQ (key, Q_label)) ;   /* ignored for 21.0 implement in 21.2  */
   else
     signal_simple_error_2 ("Unknown keyword in gui item", key, pgui_item->name);
 }
@@ -337,12 +339,14 @@
   defkeyword (&Q_active,   ":active");
   defkeyword (&Q_suffix,   ":suffix");
   defkeyword (&Q_keys,     ":keys");
+  defkeyword (&Q_key_sequence,":key-sequence");
   defkeyword (&Q_style,    ":style");
   defkeyword (&Q_selected, ":selected");
   defkeyword (&Q_filter,   ":filter");
   defkeyword (&Q_config,   ":config");
   defkeyword (&Q_included, ":included");
   defkeyword (&Q_accelerator, ":accelerator");
+  defkeyword (&Q_label, ":label");
 
   defsymbol (&Qtoggle, "toggle");
   defsymbol (&Qradio, "radio");
--- a/src/gui.h	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/gui.h	Mon Aug 13 11:05:42 2007 +0200
@@ -69,6 +69,7 @@
 
 extern Lisp_Object Q_accelerator, Q_active, Q_config, Q_filter, Q_included;
 extern Lisp_Object Q_keys, Q_selected, Q_suffix, Qradio, Qtoggle;
+extern Lisp_Object Q_key_sequence, Q_label;
 
 void gui_item_init (struct gui_item *pgui_item);
 void gui_item_add_keyval_pair (struct gui_item *pgui_item,
--- a/src/input-method-motif.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/input-method-motif.c	Mon Aug 13 11:05:42 2007 +0200
@@ -41,7 +41,12 @@
 {
   char *locale;
 
-  XtSetLanguageProc (NULL, (XtLanguageProc) NULL, NULL);
+  /* dverna - Nov. 98: ### DON'T DO THIS !!! The default XtLanguageProc
+     routine calls setlocale(LC_ALL, lang) which fucks up our lower-level
+     locale management, and especially the value of LC_NUMERIC. Anyway, since
+     at this point, we don't know yet whether we're gonna need an X11 frame,
+     we should really do it manually and not use Xlib's dumb default routine */
+  /*XtSetLanguageProc (NULL, (XtLanguageProc) NULL, NULL);*/
   if ((locale = setlocale (LC_ALL, "")) == NULL)
     {
       stderr_out ("Can't set locale.\n");
--- a/src/input-method-xfs.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/input-method-xfs.c	Mon Aug 13 11:05:42 2007 +0200
@@ -42,7 +42,12 @@
 {
   char *locale;
 
-  XtSetLanguageProc (NULL, (XtLanguageProc) NULL, NULL);
+  /* dverna - Nov. 98: ### DON'T DO THIS !!! The default XtLanguageProc
+     routine calls setlocale(LC_ALL, lang) which fucks up our lower-level
+     locale management, and especially the value of LC_NUMERIC. Anyway, since
+     at this point, we don't know yet whether we're gonna need an X11 frame,
+     we should really do it manually and not use Xlib's dumb default routine */
+  /*XtSetLanguageProc (NULL, (XtLanguageProc) NULL, NULL);*/
   if ((locale = setlocale (LC_ALL, "")) == NULL)
     {
       stderr_out ("Can't set locale.\n");
--- a/src/input-method-xlib.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/input-method-xlib.c	Mon Aug 13 11:05:42 2007 +0200
@@ -79,7 +79,12 @@
 {
   char *locale;
 
-  XtSetLanguageProc (NULL, (XtLanguageProc) NULL, NULL);
+  /* dverna - Nov. 98: ### DON'T DO THIS !!! The default XtLanguageProc
+     routine calls setlocale(LC_ALL, lang) which fucks up our lower-level
+     locale management, and especially the value of LC_NUMERIC. Anyway, since
+     at this point, we don't know yet whether we're gonna need an X11 frame,
+     we should really do it manually and not use Xlib's dumb default routine */
+  /*XtSetLanguageProc (NULL, (XtLanguageProc) NULL, NULL);*/
   if ((locale = setlocale (LC_ALL, "")) == NULL)
     {
       stderr_out ("Can't set locale.\n");
--- a/src/insdel.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/insdel.c	Mon Aug 13 11:05:42 2007 +0200
@@ -2992,22 +2992,20 @@
 /* Make a string from a buffer.  This needs to take into account the gap,
    and add any necessary extents from the buffer. */
 
-Lisp_Object
-make_string_from_buffer (struct buffer *buf, Bufpos pos, Charcount length)
+static Lisp_Object
+make_string_from_buffer_1 (struct buffer *buf, Bufpos pos, Charcount length,
+			   int no_extents)
 {
   /* This function can GC */
-  Lisp_Object val;
+  Bytind    bi_ind = bufpos_to_bytind (buf, pos);
+  Bytecount bi_len = bufpos_to_bytind (buf, pos + length) - bi_ind;
+  Lisp_Object  val = make_uninit_string (bi_len);
+
   struct gcpro gcpro1;
-  Bytind bi_ind;
-  Bytecount bi_len;
-
-  bi_ind = bufpos_to_bytind (buf, pos);
-  bi_len = bufpos_to_bytind (buf, pos + length) - bi_ind;
-
-  val = make_uninit_string (bi_len);
   GCPRO1 (val);
 
-  add_string_extents (val, buf, bi_ind, bi_len);
+  if (!no_extents)
+    add_string_extents (val, buf, bi_ind, bi_len);
 
   {
     Bytecount len1 = BI_BUF_GPT (buf) - bi_ind;
@@ -3039,6 +3037,19 @@
   return val;
 }
 
+Lisp_Object
+make_string_from_buffer (struct buffer *buf, Bufpos pos, Charcount length)
+{
+  return make_string_from_buffer_1 (buf, pos, length, 0);
+}
+
+Lisp_Object
+make_string_from_buffer_no_extents (struct buffer *buf, Bufpos pos,
+				    Charcount length)
+{
+  return make_string_from_buffer_1 (buf, pos, length, 1);
+}
+
 void
 barf_if_buffer_read_only (struct buffer *buf, Bufpos from, Bufpos to)
 {
--- a/src/linuxplay.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/linuxplay.c	Mon Aug 13 11:05:42 2007 +0200
@@ -65,7 +65,7 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
-#include <sys/fcntl.h>
+#include <fcntl.h>
 #include <sys/file.h>
 #include <sys/ioctl.h>
 #include <sys/signal.h>
--- a/src/lisp.h	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/lisp.h	Mon Aug 13 11:05:42 2007 +0200
@@ -960,7 +960,7 @@
   struct lrecord_header lheader;
   Lisp_Object next;
   long size;
-  unsigned int bits[1];
+  unsigned long bits[1];
 };
 
 DECLARE_LRECORD (bit_vector, struct Lisp_Bit_Vector);
@@ -2048,6 +2048,7 @@
 Bytind bytind_clip_to_bounds (Bytind, Bytind, Bytind);
 void buffer_insert1 (struct buffer *, Lisp_Object);
 Lisp_Object make_string_from_buffer (struct buffer *, int, int);
+Lisp_Object make_string_from_buffer_no_extents (struct buffer *, int, int);
 Lisp_Object save_excursion_save (void);
 Lisp_Object save_restriction_save (void);
 Lisp_Object save_excursion_restore (Lisp_Object);
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/m/arm.h	Mon Aug 13 11:05:42 2007 +0200
@@ -0,0 +1,135 @@
+/* Machine description file for digital/intel arm/strongarm
+   Copyright (C) 1987 Free Software Foundation, Inc.
+
+This file is part of GNU Emacs.
+
+GNU Emacs is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Emacs is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with XEmacs; see the file COPYING.  If not, write to
+the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+Boston, MA 02111-1307, USA.  */
+
+/* Synched up with: FSF 19.31. */
+
+/* Define WORD_MACHINE if addresses and such have
+ * to be corrected before they can be used as byte counts.  */
+
+#undef WORD_MACHINE
+
+/* Now define a symbol for the cpu type, if your compiler
+   does not define it automatically:
+   Ones defined so far include vax, m68000, ns16000, pyramid,
+   orion, tahoe, APOLLO and many others */
+
+#ifndef arm
+#define arm
+#endif
+
+/* crt0.c, if it is used, should use the i386-bsd style of entry.
+   with no extra dummy args.  On USG and XENIX,
+   NO_REMAP says this isn't used. */
+
+/* Mly 16-Jan-96 16:38:32: this is part of a prototype -- same bug present in 
+   other m*.h files */
+#define CRT0_DUMMIES int bogus_fp,
+
+/* crt0.c should define a symbol `start' and do .globl with a dot.  */
+
+#define DOT_GLOBAL_START
+
+#ifdef USG5_4 /* Older USG systems do not support the load average.  */
+/* Data type of load average, as read out of kmem.  */
+
+#define LOAD_AVE_TYPE long
+
+/* Convert that into an integer that is 100 for a load average of 1.0  */
+/* This is totally uncalibrated. */
+
+
+/* FSHIFT and FSCALE are defined in param.h, but are required by
+   LOAD_AVE_CVT, so they need to be defined here.  */
+
+#ifndef FSHIFT
+#define FSHIFT	8	/* bits to right of fixed binary point */
+#endif
+
+#ifndef FSCALE
+#define FSCALE	(1<<FSHIFT)
+#endif
+
+#define LOAD_AVE_CVT(x) ((int) (((double) (x)) * 100.0 / FSCALE))
+#endif
+
+
+/* Define CANNOT_DUMP on machines where unexec does not work.
+   Then the function dump-emacs will not be defined
+   and temacs will do (load "loadup") automatically unless told otherwise.  */
+
+#undef CANNOT_DUMP
+
+/* Define VIRT_ADDR_VARIES if the virtual addresses of
+   pure and impure space as loaded can vary, and even their
+   relative order cannot be relied on.
+
+   Otherwise Emacs assumes that text space precedes data space,
+   numerically.  */
+
+#undef VIRT_ADDR_VARIES
+
+
+/* this brings in alloca() if we're using cc */
+#ifdef USG
+#define NO_REMAP 
+#define TEXT_START 0
+#endif /* USG */
+
+
+#ifdef USG5_4
+#define DATA_SEG_BITS 0x08000000
+#endif
+
+#ifdef MSDOS
+#define NO_REMAP
+#endif
+
+#ifdef WINDOWSNT
+#define VIRT_ADDR_VARIES
+#define DATA_END 	get_data_end ()
+#define DATA_START 	get_data_start ()
+#define HAVE_ALLOCA
+#endif
+
+#ifdef linux
+/* libc-linux/sysdeps/linux/i386/ulimit.c says that due to shared library, */
+/* we cannot get the maximum address for brk */
+#define ULIMIT_BREAK_VALUE (32*1024*1024)
+
+#define SEGMENT_MASK ((SEGMENT_SIZE)-1)
+#endif
+
+#if 0
+#ifdef __GNUC__
+/* GCC's alloca() is semi-broken.  See lisp.h.
+
+   This brokenness has been confirmed under both Linux and NetBSD.
+   It may also exist on non-Intel architectures. */
+#define BROKEN_ALLOCA_IN_FUNCTION_CALLS
+#endif
+#endif
+
+
+/* XEmacs change: John Hughes <john@AtlanTech.COM> says using vfork
+   under i386-unknown-sysv4.2 makes C-g sometimes cause a SIGSEGV
+   in TTY mode; the problem goes away if you use fork */
+#ifdef USG5_4_2
+#define vfork fork
+#endif
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/m/mips-nec.h	Mon Aug 13 11:05:42 2007 +0200
@@ -0,0 +1,145 @@
+/* m- file for Mips machines.
+   Copyright (C) 1987, 1992, 1993, 1995 Free Software Foundation, Inc.
+
+   This file contains some changes for our SVR4 based SINIX-Mips 5.4.
+   I hope this is helpful to port the emacs to our RM?00 series and
+   maybe to the DC/OSx (Mips-based) machines of Pyramid Inc.
+     (Marco.Walther@mch.sni.de)
+
+This file is part of GNU Emacs.
+
+GNU Emacs is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU Emacs is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with XEmacs; see the file COPYING.  If not, write to
+the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+Boston, MA 02111-1307, USA.  */
+
+/* Synched up with: FSF 19.31. */
+
+/* The following line tells the configuration script what sort of 
+   operating system this machine is likely to run.
+   USUAL-OPSYS="note"
+
+NOTE-START
+Use m-mips4.h for RISCOS version 4; use s-bsd4-3.h with the BSD world.
+Note that the proper m- file for the Decstation is m-pmax.h.
+This is the m- file for SNI RM*00 machines. Use s- sinix5-4.h file!
+With this the file mips-siemens.h is obsolete.
+NOTE-END  */
+
+/* Define WORD_MACHINE if addresses and such have
+ * to be corrected before they can be used as byte counts.  */
+
+#undef WORD_MACHINE
+
+/* Define how to take a char and sign-extend into an int.
+   On machines where char is signed, this is a no-op.  */
+
+#define SIGN_EXTEND_CHAR(c) ((signed char)(c))
+
+/* Now define a symbol for the cpu type, if your compiler
+   does not define it automatically:
+   Ones defined so far include vax, m68000, ns16000, pyramid,
+   orion, tahoe, APOLLO and many others */
+#ifndef mips
+#	define mips
+#endif
+
+/* Define EXPLICIT_SIGN_EXTEND if XINT must explicitly sign-extend
+   the 24-bit bit field into an int.  In other words, if bit fields
+   are always unsigned.
+
+   If you use NO_UNION_TYPE, this flag does not matter.  */
+
+#define EXPLICIT_SIGN_EXTEND
+
+/* Data type of load average, as read out of kmem.  */
+
+#define LOAD_AVE_TYPE long
+
+/* Convert that into an integer that is 100 for a load average of 1.0  */
+
+#define LOAD_AVE_CVT(x) (int) (((double) (x)) * 100.0 / 256.0)
+
+/* CDC EP/IX 1.4.3 uses /unix */
+
+#undef KERNEL_FILE
+#define KERNEL_FILE "/unix"
+
+/* Define CANNOT_DUMP on machines where unexec does not work.
+   Then the function dump-emacs will not be defined
+   and temacs will do (load "loadup") automatically unless told otherwise.  */
+
+#undef CANNOT_DUMP
+
+/* Define VIRT_ADDR_VARIES if the virtual addresses of
+   pure and impure space as loaded can vary, and even their
+   relative order cannot be relied on.
+
+   Otherwise Emacs assumes that text space precedes data space,
+   numerically.  */
+
+/* #define VIRT_ADDR_VARIES */
+
+/* Define C_ALLOCA if this machine does not support a true alloca
+   and the one written in C should be used instead.
+   Define HAVE_ALLOCA to say that the system provides a properly
+   working alloca function and it should be used.
+   Define neither one if an assembler-language alloca
+   in the file alloca.s should be used.  */
+
+#ifdef __GNUC__
+#define HAVE_ALLOCA
+#else
+#define C_ALLOCA
+#endif
+
+/* Define NO_REMAP if memory segmentation makes it not work well
+   to change the boundary between the text section and data section
+   when Emacs is dumped.  If you define this, the preloaded Lisp
+   code will not be sharable; but that's better than failing completely.  */
+
+#define NO_REMAP
+
+/* Describe layout of the address space in an executing process.  */
+/* MARCO ???
+*/
+#define TEXT_START 0x400000
+/*
+#define DATA_START 0x10000000
+#define DATA_SEG_BITS	0x10000000
+*/
+
+#undef ORDINARY_LINK
+
+#undef LIBS_DEBUG
+
+/* Alter some of the options used when linking.  */
+
+#undef LIBS_MACHINE
+/* #define LIBS_MACHINE "-lmld" */ /* mrb */
+#define START_FILES "pre-crt0.o /usr/ccs/lib/crt1.o /usr/ccs/lib/crti.o /usr/ccs/lib/values-Xt.o"
+
+#ifdef LIB_STANDARD
+#undef LIB_STANDARD
+#endif
+#define LIB_STANDARD "-lc /usr/ccs/lib/crtn.o"
+
+#ifdef __GNUC__
+#define C_DEBUG_SWITCH
+#define C_OPTIMIZE_SWITCH "-O"
+#define LD_SWITCH_MACHINE 
+#else
+#define C_DEBUG_SWITCH "-DSYSV"
+#define C_OPTIMIZE_SWITCH "-DSYSV "
+#define LD_SWITCH_MACHINE
+#endif
--- a/src/menubar-x.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/menubar-x.c	Mon Aug 13 11:05:42 2007 +0200
@@ -146,8 +146,10 @@
 	{
 	  Lisp_Object key, val;
 	  Lisp_Object include_p = Qnil, hook_fn = Qnil, config_tag = Qnil;
+	  Lisp_Object active_p = Qt;
 	  Lisp_Object accel;
 	  int included_spec = 0;
+	  int active_spec = 0;
 	  wv->type = CASCADE_TYPE;
 	  wv->enabled = 1;
 	  wv->name = (char *) XSTRING_DATA (LISP_GETTEXT (XCAR (desc)));
@@ -172,6 +174,8 @@
 		config_tag = val;
 	      else if (EQ (key, Q_filter))
 		hook_fn = val;
+	      else if (EQ (key, Q_active))
+		active_p = val, active_spec = 1;
 	      else if (EQ (key, Q_accelerator))
 		{
 		  if ( SYMBOLP (val)
@@ -180,6 +184,10 @@
 		  else
 		    signal_simple_error ("bad keyboard accelerator", val);
 		}
+	      else if (EQ (key, Q_label))
+		{
+		  /* implement in 21.2 */
+		}
 	      else
 		signal_simple_error ("unknown menu cascade keyword", cascade);
 	    }
@@ -191,7 +199,11 @@
 	      wv = NULL;
 	      goto menu_item_done;
 	    }
-	  if (!NILP (hook_fn))
+
+	  if (active_spec)
+	    active_p = Feval (active_p);
+	  
+	  if (!NILP (hook_fn) && !NILP (active_p))
 	    {
 #if defined LWLIB_MENUBARS_LUCID || defined LWLIB_MENUBARS_MOTIF
 	      if (filter_p || depth == 0)
@@ -236,6 +248,24 @@
 	      wv->contents = title_wv;
 	      prev = sep_wv;
 	    }
+	  wv->enabled = ! NILP (active_p);
+	  if (deep_p && !wv->enabled  && !NILP (desc))
+	    {
+	      widget_value *dummy;
+	      /* Add a fake entry so the menus show up */
+	      wv->contents = dummy = xmalloc_widget_value ();
+	      dummy->name = "(inactive)";
+	      dummy->accel = NULL;
+	      dummy->enabled = 0;
+	      dummy->selected = 0;
+	      dummy->value = NULL;
+	      dummy->type = BUTTON_TYPE;
+	      dummy->call_data = NULL;
+	      dummy->next = NULL;
+	      
+	      goto menu_item_done;
+	}
+
 	}
       else if (menubar_root_p)
 	{
@@ -248,8 +278,7 @@
 	  signal_simple_error ("menu name (first element) must be a string",
                                desc);
 	}
-
-      wv->enabled = 1;
+      
       if (deep_p || menubar_root_p)
 	{
 	  widget_value *next;
--- a/src/menubar.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/menubar.c	Mon Aug 13 11:05:42 2007 +0200
@@ -501,6 +501,13 @@
 		     Basically, the filter function should have no
 		     side-effects.
 
+ :key-sequence keys  Used in FSF Emacs as an hint to an equivalent keybinding.
+                     Ignored by XEnacs for easymenu.el compatability.
+
+ :label <form>       (unimplemented!) Like :suffix, but replaces label
+                     completely.
+                     (might be added in 21.2).
+ 
 For example:
 
  ("File"
--- a/src/mule-charset.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/mule-charset.c	Mon Aug 13 11:05:42 2007 +0200
@@ -1249,7 +1249,7 @@
 		  build_string ("iso8859-1"));
   Vcharset_control_1 =
     make_charset (-1, Qcontrol_1, LEADING_BYTE_CONTROL_1, 2,
-		  CHARSET_TYPE_94, 1, 0, 0,
+		  CHARSET_TYPE_94, 1, 1, 0,
 		  CHARSET_LEFT_TO_RIGHT,
 		  build_string ("Control characters"),
 		  build_string (""));
--- a/src/process-unix.c	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/process-unix.c	Mon Aug 13 11:05:42 2007 +0200
@@ -735,7 +735,7 @@
 
   /* Nothing below here GCs so our string pointers shouldn't move. */
   new_argv = alloca_array (char *, nargv + 2);
-  new_argv[0] = (char *) XSTRING_DATA (program);
+  GET_C_STRING_FILENAME_DATA_ALLOCA (program, new_argv[0]);
   for (i = 0; i < nargv; i++)
     {
       Lisp_Object tem = argv[i];
@@ -743,7 +743,7 @@
       new_argv[i + 1] = (char *) XSTRING_DATA (tem);
     }
   new_argv[i + 1] = 0;
-  current_dir = (char *) XSTRING_DATA (cur_dir);
+  GET_C_STRING_FILENAME_DATA_ALLOCA (cur_dir, current_dir);
 
 #ifdef HAVE_PTYS
   if (!NILP (Vprocess_connection_type))
--- a/src/s/cygwin32.h	Mon Aug 13 11:04:53 2007 +0200
+++ b/src/s/cygwin32.h	Mon Aug 13 11:05:42 2007 +0200
@@ -71,8 +71,8 @@
 /* cheesy way to determine cygwin version */
 #ifndef NOT_C_CODE
 #include <signal.h>
-#ifdef HAVE_CYGWIN32_VERSION_H
-#include <cygwin32/version.h>
+#ifdef HAVE_CYGWIN_VERSION_H
+#include <cygwin/version.h>
 #else
 #ifdef SIGIO
 #define CYGWIN_B19
@@ -85,7 +85,7 @@
 extern int cygwin32_win32_to_posix_path_list_buf_size(const char*);
 extern void cygwin32_posix_to_win32_path_list(const char*, char*);
 extern int cygwin32_posix_to_win32_path_list_buf_size(const char*);
-#ifndef CYGWIN_DLL_VERSION_MAJOR
+#ifndef CYGWIN_VERSION_DLL_MAJOR
 struct timeval;
 struct timezone;
 struct itimerval;
@@ -151,8 +151,12 @@
 #define DATA_END -1
 #define HEAP_IN_DATA
 #define UNEXEC "unexcw.o"
-/* #define BROKEN_SIGIO */
+
+#ifdef CYGWIN_VERSION_DLL_MAJOR
+#define BROKEN_SIGIO
+#else
 #define PROCESS_IO_BLOCKING
+#endif
 #define strnicmp strncasecmp
 #ifndef HAVE_SOCKETS
 #define HAVE_SOCKETS
--- a/version.sh	Mon Aug 13 11:04:53 2007 +0200
+++ b/version.sh	Mon Aug 13 11:05:42 2007 +0200
@@ -1,8 +1,8 @@
 #!/bin/sh
 emacs_major_version=21
 emacs_minor_version=2
-emacs_beta_version=3
-xemacs_codename="Aglaia"
+emacs_beta_version=4
+xemacs_codename="Aglaophonos"
 infodock_major_version=4
 infodock_minor_version=0
 infodock_build_version=1