about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--CHANGES33
-rw-r--r--aclocal.m4428
-rw-r--r--config.hin10
-rwxr-xr-xconfigure1994
-rw-r--r--configure.in71
-rw-r--r--intl/libintl.h182
-rw-r--r--lynx.cfg36
-rw-r--r--lynx.hlp351
-rw-r--r--lynx.man4
-rw-r--r--makefile.in9
-rwxr-xr-xscripts/cfg2html.pl124
-rw-r--r--src/HTInit.c8
-rw-r--r--src/LYGlobalDefs.h2
-rw-r--r--src/LYMain.c701
-rw-r--r--src/LYReadCFG.c2
-rw-r--r--src/LYUtils.c92
-rw-r--r--src/makefile.in2
-rw-r--r--userdefs.h4
18 files changed, 2289 insertions, 1764 deletions
diff --git a/CHANGES b/CHANGES
index 02660e6a..08063ada 100644
--- a/CHANGES
+++ b/CHANGES
@@ -1,6 +1,39 @@
 Changes since Lynx 2.8 release
 ===============================================================================
 
+2000-05-21 (2.8.4dev.2)
+* minor changes to HTInit.c to make it more tolerant of leading whitespace
+  in mailcap entries (reported by Sven Guckes <guckes@math.fu-berlin.de>) -TD
+* add option -stdin, which tells Lynx to read the startfile from standard
+  input -TD
+* simplify argument parsing in LYMain.c, moving the special cases into the
+  table-driven logic by adding a flag that denotes the argument parsing phase
+  that applies -TD
+* correct duplicate description of JUMPFILE in lynx.cfg -TD
+* refine cfg2html.pl changes to use command-line options to control the
+  sorting and marking features, as well as make the script work properly if
+  the markup data is not given -TD
+* moved entry for lynx.cfg setting "viewer" according to the alphabet in
+  LYReadCFG.c:Config_Table -VH
+* modify cfg2html.pl to mark unavailable options, and to provide for sorting
+  the options in body.html -VH
+* update NLS configure script macros using CF_BUNDLED_INTL from tin, etc. -TD
+* update utmp configure script macros from xterm -TD
+* fix (from tin) to autoconf macro AM_WITH_NLS to fix a case where it would
+  refuse to build with non-GNU gettext -TD
+* modified autoconf macros CF_HEADER_PATH and CF_LIBRARY_PATH, to look in more
+  places for the specified files, including $HOME -TD
+* remove intl/libintl.h since it is overwritten by a symbolic link (reported
+  by Atsuhito Kohda <kohda@pm.tokushima-u.ac.jp>) -TD
+* correct a few tests in configure script which must allow inclusion of either
+  ncurses.h or curses.h, otherwise color-style cannot be configured (reported
+  by Frederick Bruckman <fb@enteract.com>) -TD
+* move logic that makes subdirectory for more-secure temporary files into
+  LYOpenTemp() where it can perform that action on demand rather than for all
+  invocations of lynx.  Further refine this logic by ensuring that the umask is
+  set to allow execution permissions on the subdirectory (fixes problems
+  reported by Michael Abraham Shulman <mas@kurukshetra.cjb.net> and KW) -TD
+
 2000-05-05 (2.8.4dev.1)
 * use built-in LYCopyFile logic for CYGWIN rather than external cp program -DK
 * minor refinement to  LYValidateFilename() to avoid prepending a drive
diff --git a/aclocal.m4 b/aclocal.m4
index cdc66037..836c81f5 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -4,7 +4,7 @@ dnl and Jim Spath <jspath@mail.bcpl.lib.md.us>
 dnl and Philippe De Muyter <phdm@macqel.be>
 dnl
 dnl Created: 1997/1/28
-dnl Updated: 2000/4/18
+dnl Updated: 2000/5/20
 dnl
 dnl The autoconf used in Lynx development is GNU autoconf, patched
 dnl by Tom Dickey.  See your local GNU archives, and this URL:
@@ -93,7 +93,7 @@ strdup __argz_count __argz_stringify __argz_next])
      fi
    fi
 
-   dnl In the intl/makefile.in we have a special dependency which only
+   dnl In the intl/Makefile.in we have a special dependency which only
    dnl makes sense for gettext.  We comment this out for non-gettext
    dnl packages.
    if test "$PACKAGE" = "gettext"; then
@@ -119,12 +119,12 @@ strdup __argz_count __argz_stringify __argz_next])
    fi
    AC_SUBST(MKINSTALLDIRS)
 
-   dnl *** For now the libtool support in intl/makefile is not for real.
+   dnl *** For now the libtool support in intl/Makefile is not for real.
    l=
    AC_SUBST(l)
 
    dnl Generate list of files to be processed by xgettext which will
-   dnl be included in po/makefile.
+   dnl be included in po/Makefile.
    if test "x$srcdir" != "x."; then
      if test "x`echo $srcdir | sed 's@/.*@@'`" = "x"; then
        posrcprefix="$srcdir/"
@@ -244,7 +244,7 @@ AC_DEFUN(AM_WITH_NLS,
       AC_ARG_WITH(included-gettext,
         [  --with-included-gettext use the GNU gettext library included here],
         nls_cv_force_use_gnu_gettext=$withval,
-        nls_cv_force_use_gnu_gettext=yes)
+        nls_cv_force_use_gnu_gettext=no)
       AC_MSG_RESULT($nls_cv_force_use_gnu_gettext)
 
       nls_cv_use_gnu_gettext="$nls_cv_force_use_gnu_gettext"
@@ -264,11 +264,14 @@ AC_DEFUN(AM_WITH_NLS,
 
 	   if test "$gt_cv_func_gettext_libc" != "yes"; then
 	     AC_CHECK_LIB(intl, bindtextdomain,
-	       [AC_CACHE_CHECK([for gettext in libintl],
+	       [ gt_save_LIBS="$LIBS"
+		 LIBS="$gt_save_LIBS -lintl"
+	         AC_CACHE_CHECK([for gettext in libintl],
 		 gt_cv_func_gettext_libintl,
 		 [AC_TRY_LINK([], [return (int) gettext ("")],
 		 gt_cv_func_gettext_libintl=yes,
-		 gt_cv_func_gettext_libintl=no)])])
+		 gt_cv_func_gettext_libintl=no)])
+		 LIBS="$gt_save_LIBS"])
 	   fi
 
 	   if test "$gt_cv_func_gettext_libintl" = yes; then
@@ -388,9 +391,13 @@ AC_DEFUN(AM_WITH_NLS,
       AC_LINK_FILES($nls_cv_header_libgt, $nls_cv_header_intl)
     fi
 
-    AC_OUTPUT_COMMANDS( #(vi
-     [case "\$CONFIG_FILES" in *po/makefile.in*)
+    AC_OUTPUT_COMMANDS([ #(vi
+      case "\$CONFIG_FILES" in
+      *po/makefile.in*) #(vi
         sed -e "/POTFILES =/r po/POTFILES" po/makefile.in > po/makefile
+        ;;
+      *po/Makefile.in*)
+        sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile
       esac])
 
     dnl These rules are solely for the distribution goal.  While doing this
@@ -555,6 +562,80 @@ if test "$cf_cv_bool_defs" = no ; then
 fi
 ])dnl
 dnl ---------------------------------------------------------------------------
+dnl Top-level macro for configuring an application with a bundled copy of
+dnl the intl and po directories for gettext.
+dnl
+dnl $1 specifies either Makefile or makefile, defaulting to the former.
+AC_DEFUN([CF_BUNDLED_INTL],[
+cf_makefile=ifelse($1,,Makefile,$1)
+
+dnl Set of available languages (based on source distribution).  Note that
+dnl setting $LINGUAS overrides $ALL_LINGUAS.  Some environments set $LINGUAS
+dnl rather than $LC_ALL
+test -z "$ALL_LINGUAS" && ALL_LINGUAS=`test -d $srcdir/po && cd $srcdir/po && echo *.po|sed -e 's/\.po//g' -e 's/*//'`
+
+AM_GNU_GETTEXT
+
+INTLDIR_MAKE=
+MSG_DIR_MAKE=
+SUB_MAKEFILE=
+CF_OUR_MESSAGES
+if test "$USE_INCLUDED_LIBINTL" = yes ; then
+        if test "$nls_cv_force_use_gnu_gettext" = yes ; then
+		SUB_MAKEFILE="intl/$cf_makefile"
+	else
+		INTLDIR_MAKE="#"
+	fi
+	if test $use_our_messages = no ; then
+		MSG_DIR_MAKE="#"
+		SUB_MAKEFILE=
+	fi
+	if test "$use_our_messages" = yes ; then
+		SUB_MAKEFILE="$SUB_MAKEFILE po/$cf_makefile.in:po/$cf_makefile.inn"
+	else
+		MSG_DIR_MAKE="#"
+	fi
+elif test "$USE_NLS" = yes ; then
+	AC_CHECK_HEADERS(libintl.h)
+	INTLDIR_MAKE="#"
+	SUB_MAKEFILE="po/$cf_makefile.in:po/$cf_makefile.inn"
+else
+	INTLDIR_MAKE="#"
+	MSG_DIR_MAKE="#"
+fi
+
+dnl We might want to use a preinstalled message library rather than the one
+dnl which is bundled with this program.
+if test -z "$MSG_DIR_MAKE" ; then
+	if test $use_our_messages = no ; then
+		MSG_DIR_MAKE="#"
+		SUB_MAKEFILE=
+	fi
+fi
+
+if test -z "$INTLDIR_MAKE" ; then
+	CPPFLAGS="$CPPFLAGS -I../intl"
+fi
+
+AC_SUBST(INTLDIR_MAKE)
+AC_SUBST(MSG_DIR_MAKE)
+
+dnl FIXME:  the underlying AM_GNU_GETTEXT macro either needs some fixes or a
+dnl little documentation.  It doesn't define anything so that we can ifdef our
+dnl own code, except ENABLE_NLS, which is too vague to be of any use.
+
+if test "$USE_INCLUDED_LIBINTL" = yes ; then
+	if test "$nls_cv_force_use_gnu_gettext" = yes ; then
+		AC_DEFINE(HAVE_GETTEXT)
+	elif test "$nls_cv_use_gnu_gettext" = yes ; then
+		AC_DEFINE(HAVE_GETTEXT)
+	fi
+	if test -n "$nls_cv_header_intl" ; then
+		AC_DEFINE(HAVE_LIBINTL_H)
+	fi
+fi
+])dnl
+dnl ---------------------------------------------------------------------------
 dnl Check if we're accidentally using a cache from a different machine.
 dnl Derive the system name, as a check for reusing the autoconf cache.
 dnl
@@ -740,7 +821,7 @@ do
 #include <xcurses.h>
 char * XCursesProgramName = "test";
 #else
-#include <curses.h>
+#include <${cf_cv_ncurses_header-curses.h}>
 #ifdef HAVE_TERM_H
 #include <term.h>
 #endif
@@ -981,47 +1062,48 @@ dnl Look for a non-standard library, given parameters for AC_TRY_LINK.  We
 dnl prefer a standard location, and use -L options only if we do not find the
 dnl library in the standard library location(s).
 dnl	$1 = library name
-dnl	$2 = includes
-dnl	$3 = code fragment to compile/link
-dnl	$4 = corresponding function-name
+dnl	$2 = library class, usually the same as library name
+dnl	$3 = includes
+dnl	$4 = code fragment to compile/link
+dnl	$5 = corresponding function-name
+dnl	$6 = flag, nonnull if failure causes an error-exit
 dnl
 dnl Sets the variable "$cf_libdir" as a side-effect, so we can see if we had
 dnl to use a -L option.
 AC_DEFUN([CF_FIND_LIBRARY],
 [
-	cf_cv_have_lib_$1=no
+	eval 'cf_cv_have_lib_'$1'=no'
 	cf_libdir=""
-	AC_CHECK_FUNC($4,cf_cv_have_lib_$1=yes,[
+	AC_CHECK_FUNC($5,
+		eval 'cf_cv_have_lib_'$1'=yes',[
 		cf_save_LIBS="$LIBS"
-		AC_MSG_CHECKING(for $4 in -l$1)
+		AC_MSG_CHECKING(for $5 in -l$1)
 		LIBS="-l$1 $LIBS"
-		AC_TRY_LINK([$2],[$3],
+		AC_TRY_LINK([$3],[$4],
 			[AC_MSG_RESULT(yes)
-			 cf_cv_have_lib_$1=yes
+			 eval 'cf_cv_have_lib_'$1'=yes'
 			],
 			[AC_MSG_RESULT(no)
-			CF_LIBRARY_PATH(cf_search,$1)
+			CF_LIBRARY_PATH(cf_search,$2)
 			for cf_libdir in $cf_search
 			do
 				AC_MSG_CHECKING(for -l$1 in $cf_libdir)
 				LIBS="-L$cf_libdir -l$1 $cf_save_LIBS"
-				AC_TRY_LINK([$2],[$3],
+				AC_TRY_LINK([$3],[$4],
 					[AC_MSG_RESULT(yes)
-			 		 cf_cv_have_lib_$1=yes
+			 		 eval 'cf_cv_have_lib_'$1'=yes'
 					 break],
 					[AC_MSG_RESULT(no)
 					 LIBS="$cf_save_LIBS"])
 			done
 			])
 		])
-if test $cf_cv_have_lib_$1 = no ; then
+eval 'cf_found_library=[$]cf_cv_have_lib_'$1
+ifelse($6,,[
+if test $cf_found_library = no ; then
 	AC_ERROR(Cannot link $1 library)
 fi
-case $host_os in #(vi
-linux*) # Suse Linux does not follow /usr/lib convention
-	LIBS="$LIBS -L/lib"
-	;;
-esac
+])
 ])dnl
 dnl ---------------------------------------------------------------------------
 dnl Check for availability of fcntl versus ioctl(,FIONBIO,).  Lynx uses this
@@ -1288,18 +1370,31 @@ dnl ---------------------------------------------------------------------------
 dnl Construct a search-list for a nonstandard header-file
 AC_DEFUN([CF_HEADER_PATH],
 [$1=""
-if test -d "$includedir"  ; then
-test "$includedir" != NONE       && $1="[$]$1 $includedir $includedir/$2"
-fi
-if test -d "$oldincludedir"  ; then
-test "$oldincludedir" != NONE    && $1="[$]$1 $oldincludedir $oldincludedir/$2"
-fi
-if test -d "$prefix"; then
-test "$prefix" != NONE           && $1="[$]$1 $prefix/include $prefix/include/$2"
-fi
-test "$prefix" != /usr/local     && $1="[$]$1 /usr/local/include /usr/local/include/$2"
-test "$prefix" != /usr           && $1="[$]$1 /usr/include /usr/include/$2"
-test "$prefix" != /opt           && $1="[$]$1 /opt/include /opt/include/$2"
+
+test "$includedir" != NONE && \
+test -d "$includedir" && \
+$1="[$]$1 $includedir $includedir/$2"
+
+test "$oldincludedir" != NONE && \
+test -d "$oldincludedir" && \
+$1="[$]$1 $oldincludedir $oldincludedir/$2"
+
+test "$prefix" != NONE && \
+test -d "$prefix" && \
+$1="[$]$1 $prefix/include $prefix/include/$2 $prefix/$2/include"
+
+test "$prefix" != /usr/local && \
+test -d /usr/local && \
+$1="[$]$1 /usr/local/include /usr/local/include/$2 /usr/local/$2/include"
+
+test "$prefix" != /usr && \
+$1="[$]$1 /usr/include /usr/include/$2 /usr/$2/include"
+
+test "$prefix" != /opt && \
+test -d /opt && \
+$1="[$]$1 /opt/include /opt/include/$2 /opt/$2/include"
+
+$1="[$]$1 [$]HOME/lib [$]HOME/lib/$2 [$]HOME/$2/lib"
 ])dnl
 dnl ---------------------------------------------------------------------------
 dnl Insert text into the help-message, for readability, from AC_ARG_WITH.
@@ -1359,22 +1454,64 @@ else
 fi
 ])dnl
 dnl ---------------------------------------------------------------------------
+dnl Check for header defining _PATH_LASTLOG, or failing that, see if the lastlog
+dnl file exists.
+AC_DEFUN([CF_LASTLOG],
+[
+AC_CHECK_HEADERS(lastlog.h paths.h)
+AC_CACHE_CHECK(for lastlog path,cf_cv_path_lastlog,[
+AC_TRY_COMPILE([
+#include <sys/types.h>
+#ifdef HAVE_LASTLOG_H
+#include <lastlog.h>
+#else
+#ifdef HAVE_PATHS_H
+#include <paths.h>
+#endif
+#endif],[char *path = _PATH_LASTLOG],
+	[cf_cv_path_lastlog="_PATH_LASTLOG"],
+	[if test -f /usr/adm/lastlog ; then
+	 	cf_cv_path_lastlog=/usr/adm/lastlog
+	else
+		cf_cv_path_lastlog=no
+	fi])
+])
+test $cf_cv_path_lastlog != no && AC_DEFINE(USE_LASTLOG)
+]
+)dnl
+dnl ---------------------------------------------------------------------------
 dnl Construct a search-list for a nonstandard library-file
 AC_DEFUN([CF_LIBRARY_PATH],
 [$1=""
-if test -d "$libdir"  ; then
-test "$libdir" != NONE           && $1="[$]$1 $libdir $libdir/$2"
-fi
-if test -d "$exec_prefix"; then
-test "$exec_prefix" != NONE      && $1="[$]$1 $exec_prefix/lib $exec_prefix/lib/$2"
-fi
-if test -d "$prefix"; then
-test "$prefix" != NONE           && \
-test "$prefix" != "$exec_prefix" && $1="[$]$1 $prefix/lib $prefix/lib/$2"
-fi
-test "$prefix" != /usr/local     && $1="[$]$1 /usr/local/lib /usr/local/lib/$2"
-test "$prefix" != /usr           && $1="[$]$1 /usr/lib /usr/lib/$2"
-test "$prefix" != /opt           && $1="[$]$1 /opt/lib /opt/lib/$2"
+
+test "$libdir" != NONE && \
+test -d $libdir && \
+$1="[$]$1 $libdir $libdir/$2"
+
+test "$exec_prefix" != NONE && \
+test -d $exec_prefix && \
+$1="[$]$1 $exec_prefix/lib $exec_prefix/lib/$2"
+
+test "$prefix" != NONE && \
+test "$prefix" != "$exec_prefix" && \
+test -d $prefix && \
+$1="[$]$1 $prefix/lib $prefix/lib/$2 $prefix/$2/lib"
+
+test "$prefix" != /usr/local && \
+test -d /usr/local && \
+$1="[$]$1 /usr/local/lib /usr/local/lib/$2 /usr/local/$2/lib"
+
+test "$prefix" != /usr && \
+$1="[$]$1 /usr/lib /usr/lib/$2 /usr/$2/lib"
+
+test "$prefix" != / && \
+$1="[$]$1 /lib /lib/$2 /$2/lib"
+
+test "$prefix" != /opt && \
+test -d /opt && \
+$1="[$]$1 /opt/lib /opt/lib/$2 /opt/$2/lib"
+
+$1="[$]$1 [$]HOME/lib [$]HOME/lib/$2 [$]HOME/$2/lib"
 ])dnl
 dnl ---------------------------------------------------------------------------
 dnl Check if we've got setlocale() and its header, <locale.h>
@@ -1527,7 +1664,7 @@ freebsd*)
 esac
 
 LIBS="$cf_ncurses_LIBS $LIBS"
-CF_FIND_LIBRARY(ncurses,
+CF_FIND_LIBRARY(ncurses,ncurses,
 	[#include <${cf_cv_ncurses_header-curses.h}>],
 	[initscr()],
 	initscr)
@@ -1981,7 +2118,7 @@ cf_slang_LIBS1="$LIBS"
 CF_TERMCAP_LIBS
 cf_slang_LIBS2="$LIBS"
 AC_CHECK_FUNC(acos,,[CF_RECHECK_FUNC(acos,m,LIBS)])
-CF_FIND_LIBRARY(slang,
+CF_FIND_LIBRARY(slang,slang,
 	[#include <slang.h>],
 	[SLtt_get_screen_size()],
 	SLtt_get_screen_size)
@@ -2120,6 +2257,26 @@ AC_MSG_RESULT($cf_cv_system_mail_flags)
 AC_DEFINE_UNQUOTED(SYSTEM_MAIL_FLAGS, "$cf_cv_system_mail_flags")
 ])dnl
 dnl ---------------------------------------------------------------------------
+dnl Check if this is a SYSV flavor of UTMP
+AC_DEFUN([CF_SYSV_UTMP],
+[
+AC_REQUIRE([CF_UTMP])
+AC_CACHE_CHECK(if $cf_cv_have_utmp is SYSV flavor,cf_cv_sysv_utmp,[
+test "$cf_cv_have_utmp" = "utmp" && cf_prefix="ut" || cf_prefix="utx"
+AC_TRY_LINK([
+#include <sys/types.h>
+#include <${cf_cv_have_utmp}.h>],[
+struct $cf_cv_have_utmp x;
+	set${cf_prefix}ent ();
+	get${cf_prefix}id(&x);
+	put${cf_prefix}line(&x);
+	end${cf_prefix}ent();],
+	[cf_cv_sysv_utmp=yes],
+	[cf_cv_sysv_utmp=no])
+])
+test $cf_cv_sysv_utmp = yes && AC_DEFINE(USE_SYSV_UTMP)
+])dnl
+dnl ---------------------------------------------------------------------------
 dnl Check for declaration of sys_nerr and sys_errlist in one of stdio.h and
 dnl errno.h.  Declaration of sys_errlist on BSD4.4 interferes with our
 dnl declaration.  Reported by Keith Bostic.
@@ -2291,24 +2448,157 @@ $1=`echo $2 | tr '[a-z]' '[A-Z]'`
 changequote([,])dnl
 ])dnl
 dnl ---------------------------------------------------------------------------
+dnl Check for UTMP/UTMPX headers
 AC_DEFUN([CF_UTMP],
 [
-AC_MSG_CHECKING(if struct utmp is declared)
-AC_CACHE_VAL(cf_cv_have_utmp,[
+AC_REQUIRE([CF_LASTLOG])
+AC_CACHE_CHECK(for utmp implementation,cf_cv_have_utmp,[
+	cf_cv_have_utmp=no
+for cf_header in utmpx utmp ; do
 	AC_TRY_COMPILE([
 #include <sys/types.h>
-#include <utmp.h>],
-	[struct utmp x; char *y = &x.ut_host[0]],
-	[cf_cv_have_utmp=yes],
-	[AC_TRY_COMPILE([#include <utmpx.h>],
-		[struct utmpx x; char *y = &x.ut_host[0]],
-		[cf_cv_have_utmp=utmpx],
-		[cf_cv_have_utmp=no])
-		])
+#include <${cf_header}.h>
+#define getutent getutxent
+#ifdef USE_LASTLOG
+#include <lastlog.h>	/* may conflict with utmpx.h on Linux */
+#endif
+],
+	[struct $cf_header x;
+	 char *name = x.ut_name; /* utmp.h and compatible definitions */
+	],
+	[cf_cv_have_utmp=$cf_header
+	 break],
+	[
+	AC_TRY_COMPILE([
+#include <sys/types.h>
+#include <${cf_header}.h>
+#define getutent getutxent
+#ifdef USE_LASTLOG
+#include <lastlog.h>	/* may conflict with utmpx.h on Linux */
+#endif
+],
+	[struct $cf_header x;
+	 char *name = x.ut_user; /* utmpx.h must declare this */
+	],
+	[cf_cv_have_utmp=$cf_header
+	 AC_DEFINE(ut_name,ut_user)
+	 break
+	])])
+done
+])
+
+if test $cf_cv_have_utmp != no ; then
+	AC_DEFINE(HAVE_UTMP)
+	test $cf_cv_have_utmp = utmpx && AC_DEFINE(UTMPX_FOR_UTMP)
+	CF_UTMP_UT_HOST
+	CF_UTMP_UT_XSTATUS
+	CF_UTMP_UT_XTIME
+	CF_UTMP_UT_SESSION
+	CF_SYSV_UTMP
+fi
+])
+dnl ---------------------------------------------------------------------------
+dnl Check if UTMP/UTMPX struct defines ut_host member
+AC_DEFUN([CF_UTMP_UT_HOST],
+[
+AC_REQUIRE([CF_UTMP])
+if test $cf_cv_have_utmp != no ; then
+AC_MSG_CHECKING(if utmp.ut_host is declared)
+AC_CACHE_VAL(cf_cv_have_utmp_ut_host,[
+	AC_TRY_COMPILE([
+#include <sys/types.h>
+#include <${cf_cv_have_utmp}.h>],
+	[struct $cf_cv_have_utmp x; char *y = &x.ut_host[0]],
+	[cf_cv_have_utmp_ut_host=yes],
+	[cf_cv_have_utmp_ut_host=no])
+	])
+AC_MSG_RESULT($cf_cv_have_utmp_ut_host)
+test $cf_cv_have_utmp_ut_host != no && AC_DEFINE(HAVE_UTMP_UT_HOST)
+fi
+])
+dnl ---------------------------------------------------------------------------
+dnl Check if UTMP/UTMPX struct defines ut_session member
+AC_DEFUN([CF_UTMP_UT_SESSION],
+[
+AC_REQUIRE([CF_UTMP])
+if test $cf_cv_have_utmp != no ; then
+AC_CACHE_CHECK(if utmp.ut_session is declared, cf_cv_have_utmp_ut_session,[
+	AC_TRY_COMPILE([
+#include <sys/types.h>
+#include <${cf_cv_have_utmp}.h>],
+	[struct $cf_cv_have_utmp x; long y = x.ut_session],
+	[cf_cv_have_utmp_ut_session=yes],
+	[cf_cv_have_utmp_ut_session=no])
+])
+if test $cf_cv_have_utmp_ut_session != no ; then
+	AC_DEFINE(HAVE_UTMP_UT_SESSION)
+fi
+fi
+])
+dnl ---------------------------------------------------------------------------
+dnl Check for known variants on the UTMP/UTMPX struct's exit-status as reported
+dnl by various people:
+dnl
+dnl	ut_exit.__e_exit (HPUX 11 - David Ellement, also in glibc2)
+dnl	ut_exit.e_exit (SVR4)
+dnl	ut_exit.ut_e_exit (os390 - Greg Smith)
+dnl	ut_exit.ut_exit (Tru64 4.0f - Jeremie Petit, 4.0e - Tomas Vanhala)
+dnl
+dnl Note: utmp_xstatus is not a conventional compatibility definition in the
+dnl system header files.
+AC_DEFUN([CF_UTMP_UT_XSTATUS],
+[
+AC_REQUIRE([CF_UTMP])
+if test $cf_cv_have_utmp != no ; then
+AC_CACHE_CHECK(for exit-status in $cf_cv_have_utmp,cf_cv_have_utmp_ut_xstatus,[
+for cf_result in \
+	ut_exit.__e_exit \
+	ut_exit.e_exit \
+	ut_exit.ut_e_exit \
+	ut_exit.ut_exit
+do
+AC_TRY_COMPILE([
+#include <sys/types.h>
+#include <${cf_cv_have_utmp}.h>],
+	[struct $cf_cv_have_utmp x; long y = x.$cf_result = 0],
+	[cf_cv_have_utmp_ut_xstatus=$cf_result
+	 break],
+	[cf_cv_have_utmp_ut_xstatus=no])
+done
+])
+if test $cf_cv_have_utmp_ut_xstatus != no ; then
+	AC_DEFINE(HAVE_UTMP_UT_XSTATUS)
+	AC_DEFINE_UNQUOTED(ut_xstatus,$cf_cv_have_utmp_ut_xstatus)
+fi
+fi
+])dnl
+dnl ---------------------------------------------------------------------------
+dnl Check if UTMP/UTMPX struct defines ut_xtime member
+AC_DEFUN([CF_UTMP_UT_XTIME],
+[
+AC_REQUIRE([CF_UTMP])
+if test $cf_cv_have_utmp != no ; then
+AC_CACHE_CHECK(if utmp.ut_xtime is declared, cf_cv_have_utmp_ut_xtime,[
+	AC_TRY_COMPILE([
+#include <sys/types.h>
+#include <${cf_cv_have_utmp}.h>],
+	[struct $cf_cv_have_utmp x; long y = x.ut_xtime = 0],
+	[cf_cv_have_utmp_ut_xtime=yes],
+	[AC_TRY_COMPILE([
+#include <sys/types.h>
+#include <${cf_cv_have_utmp}.h>],
+	[struct $cf_cv_have_utmp x; long y = x.ut_tv.tv_sec],
+	[cf_cv_have_utmp_ut_xtime=define],
+	[cf_cv_have_utmp_ut_xtime=no])
 	])
-AC_MSG_RESULT($cf_cv_have_utmp)
-test $cf_cv_have_utmp != no && AC_DEFINE(HAVE_UTMP)
-test $cf_cv_have_utmp = utmpx && AC_DEFINE(UTMPX_FOR_UTMP)
+])
+if test $cf_cv_have_utmp_ut_xtime != no ; then
+	AC_DEFINE(HAVE_UTMP_UT_XTIME)
+	if test $cf_cv_have_utmp_ut_xtime = define ; then
+		AC_DEFINE(ut_xtime,ut_tv.tv_sec)
+	fi
+fi
+fi
 ])
 dnl ---------------------------------------------------------------------------
 dnl Check for ANSI stdarg.h vs varargs.h.  Note that some systems include
@@ -2393,13 +2683,13 @@ AC_DEFUN([CF_XOPEN_CURSES],
 AC_CACHE_CHECK(if we must define _XOPEN_SOURCE_EXTENDED,cf_cv_need_xopen_extension,[
 AC_TRY_LINK([
 #include <stdlib.h>
-#include <curses.h>],[
+#include <${cf_cv_ncurses_header-curses.h}>],[
 	long x = winnstr(stdscr, "", 0)],
 	[cf_cv_need_xopen_extension=no],
 	[AC_TRY_LINK([
 #define _XOPEN_SOURCE_EXTENDED
 #include <stdlib.h>
-#include <curses.h>],[
+#include <${cf_cv_ncurses_header-curses.h}>],[
 	long x = winnstr(stdscr, "", 0)],
 	[cf_cv_need_xopen_extension=yes],
 	[cf_cv_need_xopen_extension=no])])])
diff --git a/config.hin b/config.hin
index f3a91d8a..bf143d21 100644
--- a/config.hin
+++ b/config.hin
@@ -121,7 +121,11 @@
 #undef HAVE_UNISTD_H		/* have <unistd.h> */
 #undef HAVE_UNSETENV
 #undef HAVE_USE_DEFAULT_COLORS	/* ncurses extension */
-#undef HAVE_UTMP
+#undef HAVE_UTMP		/* CF_UTMP */
+#undef HAVE_UTMP_UT_HOST	/* CF_UTMP_UT_HOST */
+#undef HAVE_UTMP_UT_SESSION	/* CF_UTMP_UT_SESSION */
+#undef HAVE_UTMP_UT_XSTATUS	/* CF_UTMP_UT_XSTATUS */
+#undef HAVE_UTMP_UT_XTIME	/* CF_UTMP_UT_XTIME */
 #undef HAVE_VALUES_H		/* defined by AM_GNU_GETTEXT */
 #undef HAVE_VARARGS_H		/* CF_VARARGS */
 #undef HAVE_VASPRINTF
@@ -198,6 +202,7 @@
 #undef USE_SLANG		/* AC_ARG_WITH(screen=slang) */
 #undef USE_SOCKS4_PREFIX	/* CF_SOCKS5 */
 #undef USE_SOCKS5		/* CF_SOCKS5 */
+#undef USE_SYSV_UTMP		/* CF_UTMP */
 #undef USE_ZLIB			/* AC_ARG_WITH(zlib) */
 #undef UTMPX_FOR_UTMP		/* use <utmpx.h> since <utmp.h> not found */
 #undef UUDECODE_PATH		/* CF_PATH_PROG(uudecode) */
@@ -212,6 +217,9 @@
 #undef off_t			/* defined by AC_TYPE_OFF_T */
 #undef pid_t			/* defined by AC_TYPE_PID_T */
 #undef uid_t			/* defined by AC_TYPE_UID_T */
+#undef ut_name			/* CF_UTMP */
+#undef ut_xstatus		/* CF_UTMP_UT_XSTATUS */
+#undef ut_xtime			/* CF_UTMP_UT_XTIME */
 #undef vfork			/* defined by AC_FUNC_FORK */
 
 /* 'const' may be defined externally by the compiler-wrapper, as in 'unproto'
diff --git a/configure b/configure
index b8aa6ca3..c0a4a9d2 100755
--- a/configure
+++ b/configure
@@ -194,8 +194,8 @@ Basic Configuration Options:
   --enable-nls            use Native Language Support
   --with-included-gettext use the GNU gettext library included here
   --with-catgets          use catgets functions if available
-  --with-nls-datadir=DIR  NLS data, parent of locale (default: PREFIX/DATADIR)
   --enable-included-msgs  use included messages, for i18n support
+  --with-nls-datadir=DIR  NLS data, parent of locale (default: PREFIX/DATADIR)
   --disable-full-paths    control whether full utility pathnames are used
 EOF
 cat <<EOF
@@ -2279,23 +2279,28 @@ EOF
 
 fi
 
+
+cf_makefile=makefile
+
+test -z "$ALL_LINGUAS" && ALL_LINGUAS=`test -d $srcdir/po && cd $srcdir/po && echo *.po|sed -e 's/\.po//g' -e 's/*//'`
+
                               
    for ac_hdr in argz.h limits.h locale.h nl_types.h malloc.h string.h \
 unistd.h sys/param.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:2289: checking for $ac_hdr" >&5
+echo "configure:2294: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2294 "configure"
+#line 2299 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2299: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2304: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -2325,12 +2330,12 @@ done
 strdup __argz_count __argz_stringify __argz_next
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2329: checking for $ac_func" >&5
+echo "configure:2334: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2334 "configure"
+#line 2339 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -2353,7 +2358,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2357: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2362: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -2382,12 +2387,12 @@ done
      for ac_func in stpcpy
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2386: checking for $ac_func" >&5
+echo "configure:2391: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2391 "configure"
+#line 2396 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -2410,7 +2415,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2414: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2419: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -2444,19 +2449,19 @@ EOF
 
    if test $ac_cv_header_locale_h = yes; then
     echo $ac_n "checking for LC_MESSAGES""... $ac_c" 1>&6
-echo "configure:2448: checking for LC_MESSAGES" >&5
+echo "configure:2453: checking for LC_MESSAGES" >&5
 if eval "test \"`echo '$''{'am_cv_val_LC_MESSAGES'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2453 "configure"
+#line 2458 "configure"
 #include "confdefs.h"
 #include <locale.h>
 int main() {
 return LC_MESSAGES
 ; return 0; }
 EOF
-if { (eval echo configure:2460: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2465: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   am_cv_val_LC_MESSAGES=yes
 else
@@ -2477,7 +2482,7 @@ EOF
     fi
   fi
    echo $ac_n "checking whether NLS is requested""... $ac_c" 1>&6
-echo "configure:2481: checking whether NLS is requested" >&5
+echo "configure:2486: checking whether NLS is requested" >&5
         
 # Check whether --enable-nls or --disable-nls was given.
 if test "${enable_nls+set}" = set; then
@@ -2498,14 +2503,14 @@ fi
 EOF
 
       echo $ac_n "checking whether included gettext is requested""... $ac_c" 1>&6
-echo "configure:2502: checking whether included gettext is requested" >&5
+echo "configure:2507: checking whether included gettext is requested" >&5
       
 # Check whether --with-included-gettext or --without-included-gettext was given.
 if test "${with_included_gettext+set}" = set; then
   withval="$with_included_gettext"
   nls_cv_force_use_gnu_gettext=$withval
 else
-  nls_cv_force_use_gnu_gettext=yes
+  nls_cv_force_use_gnu_gettext=no
 fi
 
       echo "$ac_t""$nls_cv_force_use_gnu_gettext" 1>&6
@@ -2518,17 +2523,17 @@ fi
 
 	ac_safe=`echo "libintl.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for libintl.h""... $ac_c" 1>&6
-echo "configure:2522: checking for libintl.h" >&5
+echo "configure:2527: checking for libintl.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2527 "configure"
+#line 2532 "configure"
 #include "confdefs.h"
 #include <libintl.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2532: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2537: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -2545,19 +2550,19 @@ fi
 if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
   echo "$ac_t""yes" 1>&6
   echo $ac_n "checking for gettext in libc""... $ac_c" 1>&6
-echo "configure:2549: checking for gettext in libc" >&5
+echo "configure:2554: checking for gettext in libc" >&5
 if eval "test \"`echo '$''{'gt_cv_func_gettext_libc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2554 "configure"
+#line 2559 "configure"
 #include "confdefs.h"
 #include <libintl.h>
 int main() {
 return (int) gettext ("")
 ; return 0; }
 EOF
-if { (eval echo configure:2561: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2566: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   gt_cv_func_gettext_libc=yes
 else
@@ -2573,7 +2578,7 @@ echo "$ac_t""$gt_cv_func_gettext_libc" 1>&6
 
 	   if test "$gt_cv_func_gettext_libc" != "yes"; then
 	     echo $ac_n "checking for bindtextdomain in -lintl""... $ac_c" 1>&6
-echo "configure:2577: checking for bindtextdomain in -lintl" >&5
+echo "configure:2582: checking for bindtextdomain in -lintl" >&5
 ac_lib_var=`echo intl'_'bindtextdomain | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -2581,7 +2586,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lintl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 2585 "configure"
+#line 2590 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -2592,7 +2597,7 @@ int main() {
 bindtextdomain()
 ; return 0; }
 EOF
-if { (eval echo configure:2596: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2601: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -2607,20 +2612,22 @@ LIBS="$ac_save_LIBS"
 fi
 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
   echo "$ac_t""yes" 1>&6
-  echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
-echo "configure:2612: checking for gettext in libintl" >&5
+   gt_save_LIBS="$LIBS"
+		 LIBS="$gt_save_LIBS -lintl"
+	         echo $ac_n "checking for gettext in libintl""... $ac_c" 1>&6
+echo "configure:2619: checking for gettext in libintl" >&5
 if eval "test \"`echo '$''{'gt_cv_func_gettext_libintl'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2617 "configure"
+#line 2624 "configure"
 #include "confdefs.h"
 
 int main() {
 return (int) gettext ("")
 ; return 0; }
 EOF
-if { (eval echo configure:2624: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2631: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   gt_cv_func_gettext_libintl=yes
 else
@@ -2633,6 +2640,7 @@ rm -f conftest*
 fi
 
 echo "$ac_t""$gt_cv_func_gettext_libintl" 1>&6
+		 LIBS="$gt_save_LIBS"
 else
   echo "$ac_t""no" 1>&6
 fi
@@ -2652,7 +2660,7 @@ EOF
 	      # Extract the first word of "msgfmt", so it can be a program name with args.
 set dummy msgfmt; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2656: checking for $ac_word" >&5
+echo "configure:2664: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2686,12 +2694,12 @@ fi
 		for ac_func in dcgettext
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:2690: checking for $ac_func" >&5
+echo "configure:2698: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2695 "configure"
+#line 2703 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -2714,7 +2722,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2718: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2726: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -2741,7 +2749,7 @@ done
 		# Extract the first word of "gmsgfmt", so it can be a program name with args.
 set dummy gmsgfmt; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2745: checking for $ac_word" >&5
+echo "configure:2753: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2777,7 +2785,7 @@ fi
 		# Extract the first word of "xgettext", so it can be a program name with args.
 set dummy xgettext; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2781: checking for $ac_word" >&5
+echo "configure:2789: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2809,7 +2817,7 @@ else
 fi
 
 		cat > conftest.$ac_ext <<EOF
-#line 2813 "configure"
+#line 2821 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -2817,7 +2825,7 @@ extern int _nl_msg_cat_cntr;
 			       return _nl_msg_cat_cntr
 ; return 0; }
 EOF
-if { (eval echo configure:2821: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2829: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   CATOBJEXT=.gmo
 		   DATADIRNAME=share
@@ -2840,7 +2848,7 @@ fi
 
         if test "$CATOBJEXT" = "NONE"; then
 	  echo $ac_n "checking whether catgets can be used""... $ac_c" 1>&6
-echo "configure:2844: checking whether catgets can be used" >&5
+echo "configure:2852: checking whether catgets can be used" >&5
 	  
 # Check whether --with-catgets or --without-catgets was given.
 if test "${with_catgets+set}" = set; then
@@ -2854,7 +2862,7 @@ fi
 
 	  if test "$nls_cv_use_catgets" = "yes"; then
 	    	    echo $ac_n "checking for main in -li""... $ac_c" 1>&6
-echo "configure:2858: checking for main in -li" >&5
+echo "configure:2866: checking for main in -li" >&5
 ac_lib_var=`echo i'_'main | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -2862,14 +2870,14 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-li  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 2866 "configure"
+#line 2874 "configure"
 #include "confdefs.h"
 
 int main() {
 main()
 ; return 0; }
 EOF
-if { (eval echo configure:2873: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2881: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -2897,12 +2905,12 @@ else
 fi
 
 	    echo $ac_n "checking for catgets""... $ac_c" 1>&6
-echo "configure:2901: checking for catgets" >&5
+echo "configure:2909: checking for catgets" >&5
 if eval "test \"`echo '$''{'ac_cv_func_catgets'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 2906 "configure"
+#line 2914 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char catgets(); below.  */
@@ -2925,7 +2933,7 @@ catgets();
 
 ; return 0; }
 EOF
-if { (eval echo configure:2929: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:2937: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_catgets=yes"
 else
@@ -2947,7 +2955,7 @@ EOF
 	       # Extract the first word of "gencat", so it can be a program name with args.
 set dummy gencat; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2951: checking for $ac_word" >&5
+echo "configure:2959: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_GENCAT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -2983,7 +2991,7 @@ fi
 		 # Extract the first word of "gmsgfmt", so it can be a program name with args.
 set dummy gmsgfmt; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:2987: checking for $ac_word" >&5
+echo "configure:2995: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3020,7 +3028,7 @@ fi
 		   # Extract the first word of "msgfmt", so it can be a program name with args.
 set dummy msgfmt; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3024: checking for $ac_word" >&5
+echo "configure:3032: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3055,7 +3063,7 @@ fi
 		 # Extract the first word of "xgettext", so it can be a program name with args.
 set dummy xgettext; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3059: checking for $ac_word" >&5
+echo "configure:3067: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3113,7 +3121,7 @@ fi
         # Extract the first word of "msgfmt", so it can be a program name with args.
 set dummy msgfmt; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3117: checking for $ac_word" >&5
+echo "configure:3125: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_MSGFMT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3147,7 +3155,7 @@ fi
         # Extract the first word of "gmsgfmt", so it can be a program name with args.
 set dummy gmsgfmt; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3151: checking for $ac_word" >&5
+echo "configure:3159: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_GMSGFMT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3183,7 +3191,7 @@ fi
         # Extract the first word of "xgettext", so it can be a program name with args.
 set dummy xgettext; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3187: checking for $ac_word" >&5
+echo "configure:3195: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_XGETTEXT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3277,7 +3285,7 @@ fi
        LINGUAS=
      else
        echo $ac_n "checking for catalogs to be installed""... $ac_c" 1>&6
-echo "configure:3281: checking for catalogs to be installed" >&5
+echo "configure:3289: checking for catalogs to be installed" >&5
        NEW_LINGUAS=
        for lang in ${LINGUAS=$ALL_LINGUAS}; do
          case "$ALL_LINGUAS" in
@@ -3306,17 +3314,17 @@ echo "configure:3281: checking for catalogs to be installed" >&5
      if test "$CATOBJEXT" = ".cat"; then
        ac_safe=`echo "linux/version.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for linux/version.h""... $ac_c" 1>&6
-echo "configure:3310: checking for linux/version.h" >&5
+echo "configure:3318: checking for linux/version.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3315 "configure"
+#line 3323 "configure"
 #include "confdefs.h"
 #include <linux/version.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3320: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3328: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -3389,40 +3397,6 @@ fi
    fi
 
 
-
-# Check whether --with-nls-datadir or --without-nls-datadir was given.
-if test "${with_nls_datadir+set}" = set; then
-  withval="$with_nls_datadir"
-  :
-else
-  withval="${NLS_DATADIR-$prefix/$DATADIRNAME}"
-fi
-
-case ".$withval" in #(vi
-./*) #(vi
-  ;;
-.a-zA-Z:\\/*) #(vi OS/2 EMX
-  ;;
-.\${*prefix}*) #(vi
-  eval withval="$withval"
-  case ".$withval" in #(vi
-  .NONE/*)
-    withval=`echo $withval | sed -e s@NONE@$ac_default_prefix@`
-    ;;
-  esac
-  ;; #(vi
-.NONE/*)
-  withval=`echo $withval | sed -e s@NONE@$ac_default_prefix@`
-  ;;
-*)
-  { echo "configure: error: expected a pathname" 1>&2; exit 1; }
-  ;;
-esac
-
-eval NLS_DATADIR="$withval"
-
-
-INTLDIR_CPPFLAGS="#"
 INTLDIR_MAKE=
 MSG_DIR_MAKE=
 SUB_MAKEFILE=
@@ -3431,7 +3405,7 @@ use_our_messages=no
 if test "$USE_NLS" = yes ; then
 if test -d $srcdir/po ; then
 echo $ac_n "checking if we should use included message-library""... $ac_c" 1>&6
-echo "configure:3435: checking if we should use included message-library" >&5
+echo "configure:3409: checking if we should use included message-library" >&5
 	
 # Check whether --enable-included-msgs or --disable-included-msgs was given.
 if test "${enable_included_msgs+set}" = set; then
@@ -3449,8 +3423,7 @@ test $use_our_messages = yes && USE_OUR_MESSAGES=
 
 if test "$USE_INCLUDED_LIBINTL" = yes ; then
         if test "$nls_cv_force_use_gnu_gettext" = yes ; then
-		echo "configure: warning: Using included gettext anyway, since none was found" 1>&2
-		SUB_MAKEFILE="intl/makefile"
+		SUB_MAKEFILE="intl/$cf_makefile"
 	else
 		INTLDIR_MAKE="#"
 	fi
@@ -3459,7 +3432,7 @@ if test "$USE_INCLUDED_LIBINTL" = yes ; then
 		SUB_MAKEFILE=
 	fi
 	if test "$use_our_messages" = yes ; then
-		SUB_MAKEFILE="$SUB_MAKEFILE po/makefile.in:po/makefile.inn"
+		SUB_MAKEFILE="$SUB_MAKEFILE po/$cf_makefile.in:po/$cf_makefile.inn"
 	else
 		MSG_DIR_MAKE="#"
 	fi
@@ -3468,17 +3441,17 @@ elif test "$USE_NLS" = yes ; then
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3472: checking for $ac_hdr" >&5
+echo "configure:3445: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 3477 "configure"
+#line 3450 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3482: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3455: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -3505,7 +3478,7 @@ fi
 done
 
 	INTLDIR_MAKE="#"
-	SUB_MAKEFILE="po/makefile.in:po/makefile.inn"
+	SUB_MAKEFILE="po/$cf_makefile.in:po/$cf_makefile.inn"
 else
 	INTLDIR_MAKE="#"
 	MSG_DIR_MAKE="#"
@@ -3519,14 +3492,13 @@ if test -z "$MSG_DIR_MAKE" ; then
 fi
 
 if test -z "$INTLDIR_MAKE" ; then
-	INTLDIR_CPPFLAGS=
+	CPPFLAGS="$CPPFLAGS -I../intl"
 fi
 
 
 
 
 
-
 if test "$USE_INCLUDED_LIBINTL" = yes ; then
 	if test "$nls_cv_force_use_gnu_gettext" = yes ; then
 		cat >> confdefs.h <<\EOF
@@ -3547,8 +3519,49 @@ EOF
 	fi
 fi
 
+
+INTLDIR_CPPFLAGS="#"
+if test -z "$INTLDIR_MAKE" ; then
+	INTLDIR_CPPFLAGS=
+fi
+
+
+
+
+# Check whether --with-nls-datadir or --without-nls-datadir was given.
+if test "${with_nls_datadir+set}" = set; then
+  withval="$with_nls_datadir"
+  :
+else
+  withval="${NLS_DATADIR-$prefix/$DATADIRNAME}"
+fi
+
+case ".$withval" in #(vi
+./*) #(vi
+  ;;
+.a-zA-Z:\\/*) #(vi OS/2 EMX
+  ;;
+.\${*prefix}*) #(vi
+  eval withval="$withval"
+  case ".$withval" in #(vi
+  .NONE/*)
+    withval=`echo $withval | sed -e s@NONE@$ac_default_prefix@`
+    ;;
+  esac
+  ;; #(vi
+.NONE/*)
+  withval=`echo $withval | sed -e s@NONE@$ac_default_prefix@`
+  ;;
+*)
+  { echo "configure: error: expected a pathname" 1>&2; exit 1; }
+  ;;
+esac
+
+eval NLS_DATADIR="$withval"
+
+
 echo $ac_n "checking if you want full utility pathnames""... $ac_c" 1>&6
-echo "configure:3552: checking if you want full utility pathnames" >&5
+echo "configure:3565: checking if you want full utility pathnames" >&5
 
 # Check whether --enable-full-paths or --disable-full-paths was given.
 if test "${enable_full_paths+set}" = set; then
@@ -3573,7 +3586,7 @@ EOF
 
 
 echo $ac_n "checking for system mailer""... $ac_c" 1>&6
-echo "configure:3577: checking for system mailer" >&5
+echo "configure:3590: checking for system mailer" >&5
 if eval "test \"`echo '$''{'cf_cv_SYSTEM_MAIL'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3600,7 +3613,7 @@ EOF
 
 
 echo $ac_n "checking system mail flags""... $ac_c" 1>&6
-echo "configure:3604: checking system mail flags" >&5
+echo "configure:3617: checking system mail flags" >&5
 if eval "test \"`echo '$''{'cf_cv_system_mail_flags'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3628,7 +3641,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "chmod", so it can be a program name with args.
 set dummy chmod; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3632: checking for $ac_word" >&5
+echo "configure:3645: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_CHMOD'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3663,7 +3676,7 @@ fi
 
 else
 	echo $ac_n "checking for chmod""... $ac_c" 1>&6
-echo "configure:3667: checking for chmod" >&5
+echo "configure:3680: checking for chmod" >&5
 	echo "$ac_t""$CHMOD" 1>&6
 	eval 'ac_cv_path_'CHMOD'="'chmod'"'
 fi
@@ -3705,7 +3718,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "compress", so it can be a program name with args.
 set dummy compress; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3709: checking for $ac_word" >&5
+echo "configure:3722: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_COMPRESS'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3740,7 +3753,7 @@ fi
 
 else
 	echo $ac_n "checking for compress""... $ac_c" 1>&6
-echo "configure:3744: checking for compress" >&5
+echo "configure:3757: checking for compress" >&5
 	echo "$ac_t""$COMPRESS" 1>&6
 	eval 'ac_cv_path_'COMPRESS'="'compress'"'
 fi
@@ -3782,7 +3795,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "cp", so it can be a program name with args.
 set dummy cp; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3786: checking for $ac_word" >&5
+echo "configure:3799: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_COPY'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3817,7 +3830,7 @@ fi
 
 else
 	echo $ac_n "checking for cp""... $ac_c" 1>&6
-echo "configure:3821: checking for cp" >&5
+echo "configure:3834: checking for cp" >&5
 	echo "$ac_t""$COPY" 1>&6
 	eval 'ac_cv_path_'COPY'="'cp'"'
 fi
@@ -3859,7 +3872,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "gzip", so it can be a program name with args.
 set dummy gzip; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3863: checking for $ac_word" >&5
+echo "configure:3876: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_GZIP'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3894,7 +3907,7 @@ fi
 
 else
 	echo $ac_n "checking for gzip""... $ac_c" 1>&6
-echo "configure:3898: checking for gzip" >&5
+echo "configure:3911: checking for gzip" >&5
 	echo "$ac_t""$GZIP" 1>&6
 	eval 'ac_cv_path_'GZIP'="'gzip'"'
 fi
@@ -3936,7 +3949,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "mkdir", so it can be a program name with args.
 set dummy mkdir; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3940: checking for $ac_word" >&5
+echo "configure:3953: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_MKDIR'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -3971,7 +3984,7 @@ fi
 
 else
 	echo $ac_n "checking for mkdir""... $ac_c" 1>&6
-echo "configure:3975: checking for mkdir" >&5
+echo "configure:3988: checking for mkdir" >&5
 	echo "$ac_t""$MKDIR" 1>&6
 	eval 'ac_cv_path_'MKDIR'="'mkdir'"'
 fi
@@ -4013,7 +4026,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "mv", so it can be a program name with args.
 set dummy mv; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4017: checking for $ac_word" >&5
+echo "configure:4030: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_MV'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4048,7 +4061,7 @@ fi
 
 else
 	echo $ac_n "checking for mv""... $ac_c" 1>&6
-echo "configure:4052: checking for mv" >&5
+echo "configure:4065: checking for mv" >&5
 	echo "$ac_t""$MV" 1>&6
 	eval 'ac_cv_path_'MV'="'mv'"'
 fi
@@ -4090,7 +4103,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "rm", so it can be a program name with args.
 set dummy rm; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4094: checking for $ac_word" >&5
+echo "configure:4107: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_RM'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4125,7 +4138,7 @@ fi
 
 else
 	echo $ac_n "checking for rm""... $ac_c" 1>&6
-echo "configure:4129: checking for rm" >&5
+echo "configure:4142: checking for rm" >&5
 	echo "$ac_t""$RM" 1>&6
 	eval 'ac_cv_path_'RM'="'rm'"'
 fi
@@ -4167,7 +4180,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "tar", so it can be a program name with args.
 set dummy tar; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4171: checking for $ac_word" >&5
+echo "configure:4184: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_TAR'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4202,7 +4215,7 @@ fi
 
 else
 	echo $ac_n "checking for tar""... $ac_c" 1>&6
-echo "configure:4206: checking for tar" >&5
+echo "configure:4219: checking for tar" >&5
 	echo "$ac_t""$TAR" 1>&6
 	eval 'ac_cv_path_'TAR'="'tar'"'
 fi
@@ -4244,7 +4257,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "touch", so it can be a program name with args.
 set dummy touch; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4248: checking for $ac_word" >&5
+echo "configure:4261: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_TOUCH'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4279,7 +4292,7 @@ fi
 
 else
 	echo $ac_n "checking for touch""... $ac_c" 1>&6
-echo "configure:4283: checking for touch" >&5
+echo "configure:4296: checking for touch" >&5
 	echo "$ac_t""$TOUCH" 1>&6
 	eval 'ac_cv_path_'TOUCH'="'touch'"'
 fi
@@ -4321,7 +4334,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "gunzip", so it can be a program name with args.
 set dummy gunzip; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4325: checking for $ac_word" >&5
+echo "configure:4338: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_UNCOMPRESS'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4356,7 +4369,7 @@ fi
 
 else
 	echo $ac_n "checking for gunzip""... $ac_c" 1>&6
-echo "configure:4360: checking for gunzip" >&5
+echo "configure:4373: checking for gunzip" >&5
 	echo "$ac_t""$UNCOMPRESS" 1>&6
 	eval 'ac_cv_path_'UNCOMPRESS'="'gunzip'"'
 fi
@@ -4398,7 +4411,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "unzip", so it can be a program name with args.
 set dummy unzip; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4402: checking for $ac_word" >&5
+echo "configure:4415: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_UNZIP'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4433,7 +4446,7 @@ fi
 
 else
 	echo $ac_n "checking for unzip""... $ac_c" 1>&6
-echo "configure:4437: checking for unzip" >&5
+echo "configure:4450: checking for unzip" >&5
 	echo "$ac_t""$UNZIP" 1>&6
 	eval 'ac_cv_path_'UNZIP'="'unzip'"'
 fi
@@ -4475,7 +4488,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "bzip2", so it can be a program name with args.
 set dummy bzip2; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4479: checking for $ac_word" >&5
+echo "configure:4492: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_BZIP2'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4510,7 +4523,7 @@ fi
 
 else
 	echo $ac_n "checking for bzip2""... $ac_c" 1>&6
-echo "configure:4514: checking for bzip2" >&5
+echo "configure:4527: checking for bzip2" >&5
 	echo "$ac_t""$BZIP2" 1>&6
 	eval 'ac_cv_path_'BZIP2'="'bzip2'"'
 fi
@@ -4552,7 +4565,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "uudecode", so it can be a program name with args.
 set dummy uudecode; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4556: checking for $ac_word" >&5
+echo "configure:4569: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_UUDECODE'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4587,7 +4600,7 @@ fi
 
 else
 	echo $ac_n "checking for uudecode""... $ac_c" 1>&6
-echo "configure:4591: checking for uudecode" >&5
+echo "configure:4604: checking for uudecode" >&5
 	echo "$ac_t""$UUDECODE" 1>&6
 	eval 'ac_cv_path_'UUDECODE'="'uudecode'"'
 fi
@@ -4629,7 +4642,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "zcat", so it can be a program name with args.
 set dummy zcat; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4633: checking for $ac_word" >&5
+echo "configure:4646: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_ZCAT'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4664,7 +4677,7 @@ fi
 
 else
 	echo $ac_n "checking for zcat""... $ac_c" 1>&6
-echo "configure:4668: checking for zcat" >&5
+echo "configure:4681: checking for zcat" >&5
 	echo "$ac_t""$ZCAT" 1>&6
 	eval 'ac_cv_path_'ZCAT'="'zcat'"'
 fi
@@ -4706,7 +4719,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "zip", so it can be a program name with args.
 set dummy zip; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4710: checking for $ac_word" >&5
+echo "configure:4723: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_ZIP'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4741,7 +4754,7 @@ fi
 
 else
 	echo $ac_n "checking for zip""... $ac_c" 1>&6
-echo "configure:4745: checking for zip" >&5
+echo "configure:4758: checking for zip" >&5
 	echo "$ac_t""$ZIP" 1>&6
 	eval 'ac_cv_path_'ZIP'="'zip'"'
 fi
@@ -4783,7 +4796,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "telnet", so it can be a program name with args.
 set dummy telnet; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4787: checking for $ac_word" >&5
+echo "configure:4800: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_TELNET'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4818,7 +4831,7 @@ fi
 
 else
 	echo $ac_n "checking for telnet""... $ac_c" 1>&6
-echo "configure:4822: checking for telnet" >&5
+echo "configure:4835: checking for telnet" >&5
 	echo "$ac_t""$TELNET" 1>&6
 	eval 'ac_cv_path_'TELNET'="'telnet'"'
 fi
@@ -4860,7 +4873,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "tn3270", so it can be a program name with args.
 set dummy tn3270; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4864: checking for $ac_word" >&5
+echo "configure:4877: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_TN3270'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4895,7 +4908,7 @@ fi
 
 else
 	echo $ac_n "checking for tn3270""... $ac_c" 1>&6
-echo "configure:4899: checking for tn3270" >&5
+echo "configure:4912: checking for tn3270" >&5
 	echo "$ac_t""$TN3270" 1>&6
 	eval 'ac_cv_path_'TN3270'="'tn3270'"'
 fi
@@ -4937,7 +4950,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "rlogin", so it can be a program name with args.
 set dummy rlogin; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:4941: checking for $ac_word" >&5
+echo "configure:4954: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_RLOGIN'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -4972,7 +4985,7 @@ fi
 
 else
 	echo $ac_n "checking for rlogin""... $ac_c" 1>&6
-echo "configure:4976: checking for rlogin" >&5
+echo "configure:4989: checking for rlogin" >&5
 	echo "$ac_t""$RLOGIN" 1>&6
 	eval 'ac_cv_path_'RLOGIN'="'rlogin'"'
 fi
@@ -5024,7 +5037,7 @@ if test "$with_full_paths" = yes ; then
 	# Extract the first word of "install", so it can be a program name with args.
 set dummy install; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:5028: checking for $ac_word" >&5
+echo "configure:5041: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_path_INSTALL'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -5059,7 +5072,7 @@ fi
 
 else
 	echo $ac_n "checking for install""... $ac_c" 1>&6
-echo "configure:5063: checking for install" >&5
+echo "configure:5076: checking for install" >&5
 	echo "$ac_t""$INSTALL" 1>&6
 	eval 'ac_cv_path_'INSTALL'="'install'"'
 fi
@@ -5108,7 +5121,7 @@ EOF
 if test -z "$GCC" ; then
 	
 echo $ac_n "checking for ${CC-cc} option to accept ANSI C""... $ac_c" 1>&6
-echo "configure:5112: checking for ${CC-cc} option to accept ANSI C" >&5
+echo "configure:5125: checking for ${CC-cc} option to accept ANSI C" >&5
 if eval "test \"`echo '$''{'cf_cv_ansi_cc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -5132,7 +5145,7 @@ for cf_arg in "-DCC_HAS_PROTOS" \
 do
 	CFLAGS="$cf_save_CFLAGS $cf_arg"
 	cat > conftest.$ac_ext <<EOF
-#line 5136 "configure"
+#line 5149 "configure"
 #include "confdefs.h"
 
 #ifndef CC_HAS_PROTOS
@@ -5148,7 +5161,7 @@ int main() {
 	struct s2 {int (*f) (double a);};
 ; return 0; }
 EOF
-if { (eval echo configure:5152: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5165: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_ansi_cc="$cf_arg"; break
 else
@@ -5176,12 +5189,12 @@ fi
 
 fi
 echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:5180: checking for working const" >&5
+echo "configure:5193: checking for working const" >&5
 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5185 "configure"
+#line 5198 "configure"
 #include "confdefs.h"
 
 int main() {
@@ -5230,7 +5243,7 @@ ccp = (char const *const *) p;
 
 ; return 0; }
 EOF
-if { (eval echo configure:5234: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5247: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_c_const=yes
 else
@@ -5272,7 +5285,7 @@ clix*)
 	# contributed by Alex Matulich (matuli_a@marlin.navsea.navy.mil) also
 	# references -lmalloc and -lbsd.
 	echo $ac_n "checking for strcmp in -lc_s""... $ac_c" 1>&6
-echo "configure:5276: checking for strcmp in -lc_s" >&5
+echo "configure:5289: checking for strcmp in -lc_s" >&5
 ac_lib_var=`echo c_s'_'strcmp | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -5280,7 +5293,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lc_s  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 5284 "configure"
+#line 5297 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -5291,7 +5304,7 @@ int main() {
 strcmp()
 ; return 0; }
 EOF
-if { (eval echo configure:5295: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5308: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5385,7 +5398,7 @@ do
 # Extract the first word of "$ac_prog", so it can be a program name with args.
 set dummy $ac_prog; ac_word=$2
 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:5389: checking for $ac_word" >&5
+echo "configure:5402: checking for $ac_word" >&5
 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -5430,17 +5443,17 @@ sony-newsos*)
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:5434: checking for $ac_hdr" >&5
+echo "configure:5447: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5439 "configure"
+#line 5452 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:5444: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:5457: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -5484,17 +5497,17 @@ ultrix*)
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:5488: checking for $ac_hdr" >&5
+echo "configure:5501: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5493 "configure"
+#line 5506 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:5498: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:5511: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -5530,13 +5543,13 @@ esac
 
 
 echo $ac_n "checking if we must define _GNU_SOURCE""... $ac_c" 1>&6
-echo "configure:5534: checking if we must define _GNU_SOURCE" >&5
+echo "configure:5547: checking if we must define _GNU_SOURCE" >&5
 if eval "test \"`echo '$''{'cf_cv_gnu_source'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 5540 "configure"
+#line 5553 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 int main() {
@@ -5546,7 +5559,7 @@ make an error
 #endif
 ; return 0; }
 EOF
-if { (eval echo configure:5550: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5563: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_gnu_source=no
 else
@@ -5556,7 +5569,7 @@ else
   cf_save="$CFLAGS"
 	 CFLAGS="$CFLAGS -D_GNU_SOURCE"
 	 cat > conftest.$ac_ext <<EOF
-#line 5560 "configure"
+#line 5573 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 int main() {
@@ -5566,7 +5579,7 @@ make an error
 #endif
 ; return 0; }
 EOF
-if { (eval echo configure:5570: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5583: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_gnu_source=no
 else
@@ -5591,16 +5604,16 @@ if test -n "$TRY_CFLAGS" ; then
 	cf_save_CFLAGS="$CFLAGS"
 	CFLAGS="$CFLAGS $TRY_CFLAGS"
 	echo $ac_n "checking if we should use compile options $TRY_CFLAGS""... $ac_c" 1>&6
-echo "configure:5595: checking if we should use compile options $TRY_CFLAGS" >&5
+echo "configure:5608: checking if we should use compile options $TRY_CFLAGS" >&5
 	cat > conftest.$ac_ext <<EOF
-#line 5597 "configure"
+#line 5610 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main() {
 FILE *fp = stdin
 ; return 0; }
 EOF
-if { (eval echo configure:5604: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:5617: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_result=yes
 else
@@ -5618,7 +5631,7 @@ fi
 ### Look for network libraries first, since some functions (such as gethostname)
 ### are used in a lot of places.
 echo $ac_n "checking if you want socks library""... $ac_c" 1>&6
-echo "configure:5622: checking if you want socks library" >&5
+echo "configure:5635: checking if you want socks library" >&5
 if eval "test \"`echo '$''{'cf_cv_use_libsocks'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -5638,7 +5651,7 @@ fi
 echo "$ac_t""$cf_cv_use_libsocks" 1>&6
 
 echo $ac_n "checking if you want socks5 library""... $ac_c" 1>&6
-echo "configure:5642: checking if you want socks5 library" >&5
+echo "configure:5655: checking if you want socks5 library" >&5
 if eval "test \"`echo '$''{'cf_cv_use_libsocks5'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -5704,7 +5717,7 @@ cat >> confdefs.h <<\EOF
 EOF
 
 cat > conftest.$ac_ext <<EOF
-#line 5708 "configure"
+#line 5721 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -5713,7 +5726,7 @@ int main() {
 	accept((char *)0)
 ; return 0; }
 EOF
-if { (eval echo configure:5717: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5730: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   :
 else
   echo "configure: failed program was:" >&5
@@ -5743,9 +5756,9 @@ cat >> confdefs.h <<\EOF
 EOF
 
 echo $ac_n "checking if the socks library uses socks4 prefix""... $ac_c" 1>&6
-echo "configure:5747: checking if the socks library uses socks4 prefix" >&5
+echo "configure:5760: checking if the socks library uses socks4 prefix" >&5
 cat > conftest.$ac_ext <<EOF
-#line 5749 "configure"
+#line 5762 "configure"
 #include "confdefs.h"
 
 #include <socks.h>
@@ -5754,7 +5767,7 @@ int main() {
 	Rinit((char *)0)
 ; return 0; }
 EOF
-if { (eval echo configure:5758: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5771: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cat >> confdefs.h <<\EOF
 #define USE_SOCKS4_PREFIX 1
@@ -5766,14 +5779,14 @@ else
   cat conftest.$ac_ext >&5
   rm -rf conftest*
   cat > conftest.$ac_ext <<EOF
-#line 5770 "configure"
+#line 5783 "configure"
 #include "confdefs.h"
 #include <socks.h>
 int main() {
 SOCKSinit((char *)0)
 ; return 0; }
 EOF
-if { (eval echo configure:5777: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5790: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_use_socks4=no
 else
@@ -5842,7 +5855,7 @@ else
 	
 cf_test_netlibs=no
 echo $ac_n "checking for network libraries""... $ac_c" 1>&6
-echo "configure:5846: checking for network libraries" >&5
+echo "configure:5859: checking for network libraries" >&5
 if eval "test \"`echo '$''{'cf_cv_netlibs'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -5853,12 +5866,12 @@ cf_test_netlibs=yes
 for ac_func in gethostname
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:5857: checking for $ac_func" >&5
+echo "configure:5870: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 5862 "configure"
+#line 5875 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -5881,7 +5894,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:5885: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5898: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -5904,7 +5917,7 @@ else
   echo "$ac_t""no" 1>&6
 
 echo $ac_n "checking for gethostname in -lnsl""... $ac_c" 1>&6
-echo "configure:5908: checking for gethostname in -lnsl" >&5
+echo "configure:5921: checking for gethostname in -lnsl" >&5
 ac_lib_var=`echo nsl'_'gethostname | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -5912,7 +5925,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lnsl $cf_cv_netlibs $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 5916 "configure"
+#line 5929 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -5923,7 +5936,7 @@ int main() {
 gethostname()
 ; return 0; }
 EOF
-if { (eval echo configure:5927: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5940: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -5956,7 +5969,7 @@ else
 	
 		
 echo $ac_n "checking for gethostname in -lsocket""... $ac_c" 1>&6
-echo "configure:5960: checking for gethostname in -lsocket" >&5
+echo "configure:5973: checking for gethostname in -lsocket" >&5
 ac_lib_var=`echo socket'_'gethostname | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -5964,7 +5977,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket $cf_cv_netlibs $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 5968 "configure"
+#line 5981 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -5975,7 +5988,7 @@ int main() {
 gethostname()
 ; return 0; }
 EOF
-if { (eval echo configure:5979: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5992: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6020,7 +6033,7 @@ done
 # I don't know the entrypoints - 97/7/22 TD
 # AC_HAVE_LIBRARY(inet,cf_cv_netlibs="-linet $cf_cv_netlibs")
 echo $ac_n "checking for main in -linet""... $ac_c" 1>&6
-echo "configure:6024: checking for main in -linet" >&5
+echo "configure:6037: checking for main in -linet" >&5
 ac_lib_var=`echo inet'_'main | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -6028,14 +6041,14 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-linet  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 6032 "configure"
+#line 6045 "configure"
 #include "confdefs.h"
 
 int main() {
 main()
 ; return 0; }
 EOF
-if { (eval echo configure:6039: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6052: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6060,12 +6073,12 @@ if test "$ac_cv_func_lsocket" != no ; then
 for ac_func in socket
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:6064: checking for $ac_func" >&5
+echo "configure:6077: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 6069 "configure"
+#line 6082 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -6088,7 +6101,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:6092: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6105: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -6111,7 +6124,7 @@ else
   echo "$ac_t""no" 1>&6
 
 echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6
-echo "configure:6115: checking for socket in -lsocket" >&5
+echo "configure:6128: checking for socket in -lsocket" >&5
 ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -6119,7 +6132,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket $cf_cv_netlibs $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 6123 "configure"
+#line 6136 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -6130,7 +6143,7 @@ int main() {
 socket()
 ; return 0; }
 EOF
-if { (eval echo configure:6134: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6147: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6163,7 +6176,7 @@ else
 	
 		
 echo $ac_n "checking for socket in -lbsd""... $ac_c" 1>&6
-echo "configure:6167: checking for socket in -lbsd" >&5
+echo "configure:6180: checking for socket in -lbsd" >&5
 ac_lib_var=`echo bsd'_'socket | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -6171,7 +6184,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbsd $cf_cv_netlibs $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 6175 "configure"
+#line 6188 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -6182,7 +6195,7 @@ int main() {
 socket()
 ; return 0; }
 EOF
-if { (eval echo configure:6186: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6199: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6227,12 +6240,12 @@ fi
 for ac_func in gethostbyname
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:6231: checking for $ac_func" >&5
+echo "configure:6244: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 6236 "configure"
+#line 6249 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -6255,7 +6268,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:6259: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6272: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -6278,7 +6291,7 @@ else
   echo "$ac_t""no" 1>&6
 
 echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
-echo "configure:6282: checking for gethostbyname in -lnsl" >&5
+echo "configure:6295: checking for gethostbyname in -lnsl" >&5
 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -6286,7 +6299,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lnsl $cf_cv_netlibs $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 6290 "configure"
+#line 6303 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -6297,7 +6310,7 @@ int main() {
 gethostbyname()
 ; return 0; }
 EOF
-if { (eval echo configure:6301: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6314: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6338,12 +6351,12 @@ done
 for ac_func in strcasecmp
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:6342: checking for $ac_func" >&5
+echo "configure:6355: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 6347 "configure"
+#line 6360 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -6366,7 +6379,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:6370: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6383: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -6389,7 +6402,7 @@ else
   echo "$ac_t""no" 1>&6
 
 echo $ac_n "checking for strcasecmp in -lresolv""... $ac_c" 1>&6
-echo "configure:6393: checking for strcasecmp in -lresolv" >&5
+echo "configure:6406: checking for strcasecmp in -lresolv" >&5
 ac_lib_var=`echo resolv'_'strcasecmp | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -6397,7 +6410,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lresolv $cf_cv_netlibs $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 6401 "configure"
+#line 6414 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -6408,7 +6421,7 @@ int main() {
 strcasecmp()
 ; return 0; }
 EOF
-if { (eval echo configure:6412: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6425: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6454,13 +6467,13 @@ test $cf_test_netlibs = no && echo "$cf_cv_netlibs" >&6
 fi
 
 echo $ac_n "checking for inet_aton function""... $ac_c" 1>&6
-echo "configure:6458: checking for inet_aton function" >&5
+echo "configure:6471: checking for inet_aton function" >&5
 if eval "test \"`echo '$''{'cf_cv_have_inet_aton'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 6464 "configure"
+#line 6477 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/socket.h>
@@ -6471,7 +6484,7 @@ int main() {
 inet_aton(0, (struct in_addr *)0)
 ; return 0; }
 EOF
-if { (eval echo configure:6475: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6488: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_have_inet_aton=yes
 else
@@ -6491,13 +6504,13 @@ EOF
 
 else
     echo $ac_n "checking for inet_addr function""... $ac_c" 1>&6
-echo "configure:6495: checking for inet_addr function" >&5
+echo "configure:6508: checking for inet_addr function" >&5
 if eval "test \"`echo '$''{'cf_cv_have_inet_addr'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     cat > conftest.$ac_ext <<EOF
-#line 6501 "configure"
+#line 6514 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/socket.h>
@@ -6508,7 +6521,7 @@ int main() {
 inet_addr(0)
 ; return 0; }
 EOF
-if { (eval echo configure:6512: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6525: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_have_inet_addr=yes
 else
@@ -6523,7 +6536,7 @@ fi
 echo "$ac_t""$cf_cv_have_inet_addr" 1>&6
     if test "$cf_cv_have_inet_addr" = no ; then
 	echo $ac_n "checking for library with inet_addr""... $ac_c" 1>&6
-echo "configure:6527: checking for library with inet_addr" >&5
+echo "configure:6540: checking for library with inet_addr" >&5
 if eval "test \"`echo '$''{'cf_cv_lib_inet_addr'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -6533,7 +6546,7 @@ else
 	    do
 		LIBS="$cf_save_LIBS $cf_inetlib"
 		cat > conftest.$ac_ext <<EOF
-#line 6537 "configure"
+#line 6550 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/socket.h>
@@ -6544,7 +6557,7 @@ int main() {
 inet_addr(0)
 ; return 0; }
 EOF
-if { (eval echo configure:6548: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6561: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_lib_inet_addr=$cf_inetlib
 else
@@ -6571,7 +6584,7 @@ fi
 
 
 echo $ac_n "checking for screen type""... $ac_c" 1>&6
-echo "configure:6575: checking for screen type" >&5
+echo "configure:6588: checking for screen type" >&5
 if eval "test \"`echo '$''{'cf_cv_screen'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -6613,12 +6626,12 @@ case $cf_cv_screen in
 curses)
 	
 echo $ac_n "checking for initscr""... $ac_c" 1>&6
-echo "configure:6617: checking for initscr" >&5
+echo "configure:6630: checking for initscr" >&5
 if eval "test \"`echo '$''{'ac_cv_func_initscr'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 6622 "configure"
+#line 6635 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char initscr(); below.  */
@@ -6641,7 +6654,7 @@ initscr();
 
 ; return 0; }
 EOF
-if { (eval echo configure:6645: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6658: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_initscr=yes"
 else
@@ -6662,7 +6675,7 @@ else
 case $host_os in #(vi
 freebsd*) #(vi
 	echo $ac_n "checking for tgoto in -lmytinfo""... $ac_c" 1>&6
-echo "configure:6666: checking for tgoto in -lmytinfo" >&5
+echo "configure:6679: checking for tgoto in -lmytinfo" >&5
 ac_lib_var=`echo mytinfo'_'tgoto | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -6670,7 +6683,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lmytinfo  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 6674 "configure"
+#line 6687 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -6681,7 +6694,7 @@ int main() {
 tgoto()
 ; return 0; }
 EOF
-if { (eval echo configure:6685: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6698: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6704,7 +6717,7 @@ fi
 	;;
 hpux10.*|hpux11.*)
 	echo $ac_n "checking for initscr in -lcur_colr""... $ac_c" 1>&6
-echo "configure:6708: checking for initscr in -lcur_colr" >&5
+echo "configure:6721: checking for initscr in -lcur_colr" >&5
 ac_lib_var=`echo cur_colr'_'initscr | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -6712,7 +6725,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lcur_colr  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 6716 "configure"
+#line 6729 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -6723,7 +6736,7 @@ int main() {
 initscr()
 ; return 0; }
 EOF
-if { (eval echo configure:6727: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6740: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6747,7 +6760,7 @@ else
   echo "$ac_t""no" 1>&6
 
 	echo $ac_n "checking for initscr in -lHcurses""... $ac_c" 1>&6
-echo "configure:6751: checking for initscr in -lHcurses" >&5
+echo "configure:6764: checking for initscr in -lHcurses" >&5
 ac_lib_var=`echo Hcurses'_'initscr | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -6755,7 +6768,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lHcurses  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 6759 "configure"
+#line 6772 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -6766,7 +6779,7 @@ int main() {
 initscr()
 ; return 0; }
 EOF
-if { (eval echo configure:6770: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6783: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6815,12 +6828,12 @@ if test ".$ac_cv_func_initscr" != .yes ; then
 	# Check for library containing tgoto.  Do this before curses library
 	# because it may be needed to link the test-case for initscr.
 	echo $ac_n "checking for tgoto""... $ac_c" 1>&6
-echo "configure:6819: checking for tgoto" >&5
+echo "configure:6832: checking for tgoto" >&5
 if eval "test \"`echo '$''{'ac_cv_func_tgoto'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 6824 "configure"
+#line 6837 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char tgoto(); below.  */
@@ -6843,7 +6856,7 @@ tgoto();
 
 ; return 0; }
 EOF
-if { (eval echo configure:6847: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6860: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_tgoto=yes"
 else
@@ -6864,7 +6877,7 @@ else
 		for cf_term_lib in termcap termlib unknown
 		do
 			echo $ac_n "checking for tgoto in -l$cf_term_lib""... $ac_c" 1>&6
-echo "configure:6868: checking for tgoto in -l$cf_term_lib" >&5
+echo "configure:6881: checking for tgoto in -l$cf_term_lib" >&5
 ac_lib_var=`echo $cf_term_lib'_'tgoto | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -6872,7 +6885,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$cf_term_lib  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 6876 "configure"
+#line 6889 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -6883,7 +6896,7 @@ int main() {
 tgoto()
 ; return 0; }
 EOF
-if { (eval echo configure:6887: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6900: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6913,7 +6926,7 @@ fi
 	for cf_curs_lib in cursesX curses ncurses xcurses jcurses unknown
 	do
 		echo $ac_n "checking for initscr in -l$cf_curs_lib""... $ac_c" 1>&6
-echo "configure:6917: checking for initscr in -l$cf_curs_lib" >&5
+echo "configure:6930: checking for initscr in -l$cf_curs_lib" >&5
 ac_lib_var=`echo $cf_curs_lib'_'initscr | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -6921,7 +6934,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-l$cf_curs_lib  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 6925 "configure"
+#line 6938 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -6932,7 +6945,7 @@ int main() {
 initscr()
 ; return 0; }
 EOF
-if { (eval echo configure:6936: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6949: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -6958,16 +6971,16 @@ fi
 	LIBS="-l$cf_curs_lib $cf_save_LIBS"
 	if test "$cf_term_lib" = unknown ; then
 		echo $ac_n "checking if we can link with $cf_curs_lib library""... $ac_c" 1>&6
-echo "configure:6962: checking if we can link with $cf_curs_lib library" >&5
+echo "configure:6975: checking if we can link with $cf_curs_lib library" >&5
 		cat > conftest.$ac_ext <<EOF
-#line 6964 "configure"
+#line 6977 "configure"
 #include "confdefs.h"
 #include <${cf_cv_ncurses_header-curses.h}>
 int main() {
 initscr()
 ; return 0; }
 EOF
-if { (eval echo configure:6971: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6984: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_result=yes
 else
@@ -6981,16 +6994,16 @@ rm -f conftest*
 		test $cf_result = no && { echo "configure: error: Cannot link curses library" 1>&2; exit 1; }
 	elif test "$cf_term_lib" != predefined ; then
 		echo $ac_n "checking if we need both $cf_curs_lib and $cf_term_lib libraries""... $ac_c" 1>&6
-echo "configure:6985: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
+echo "configure:6998: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
 		cat > conftest.$ac_ext <<EOF
-#line 6987 "configure"
+#line 7000 "configure"
 #include "confdefs.h"
 #include <${cf_cv_ncurses_header-curses.h}>
 int main() {
 initscr(); tgoto((char *)0, 0, 0);
 ; return 0; }
 EOF
-if { (eval echo configure:6994: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7007: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_result=no
 else
@@ -7000,14 +7013,14 @@ else
   
 			LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
 			cat > conftest.$ac_ext <<EOF
-#line 7004 "configure"
+#line 7017 "configure"
 #include "confdefs.h"
 #include <${cf_cv_ncurses_header-curses.h}>
 int main() {
 initscr()
 ; return 0; }
 EOF
-if { (eval echo configure:7011: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7024: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_result=yes
 else
@@ -7029,14 +7042,14 @@ fi
 
 	
 echo $ac_n "checking for curses performance tradeoff""... $ac_c" 1>&6
-echo "configure:7033: checking for curses performance tradeoff" >&5
+echo "configure:7046: checking for curses performance tradeoff" >&5
 if eval "test \"`echo '$''{'cf_cv_curs_performance'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     cf_cv_curs_performance=no
     cat > conftest.$ac_ext <<EOF
-#line 7040 "configure"
+#line 7053 "configure"
 #include "confdefs.h"
 
 #include <${cf_cv_ncurses_header-curses.h}>
@@ -7050,11 +7063,11 @@ int main() {
 	
 ; return 0; }
 EOF
-if { (eval echo configure:7054: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:7067: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
 	cat > conftest.$ac_ext <<EOF
-#line 7058 "configure"
+#line 7071 "configure"
 #include "confdefs.h"
 
 #define CURS_PERFORMANCE
@@ -7069,7 +7082,7 @@ int main() {
 	
 ; return 0; }
 EOF
-if { (eval echo configure:7073: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:7086: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_curs_performance=yes
 else
@@ -7094,13 +7107,13 @@ EOF
 ncurses)
 	
 echo $ac_n "checking for ncurses header file""... $ac_c" 1>&6
-echo "configure:7098: checking for ncurses header file" >&5
+echo "configure:7111: checking for ncurses header file" >&5
 if eval "test \"`echo '$''{'cf_cv_ncurses_header'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 	cat > conftest.$ac_ext <<EOF
-#line 7104 "configure"
+#line 7117 "configure"
 #include "confdefs.h"
 #include <curses.h>
 int main() {
@@ -7117,7 +7130,7 @@ make an error
 	
 ; return 0; }
 EOF
-if { (eval echo configure:7121: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:7134: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_ncurses_header=predefined
 else
@@ -7126,18 +7139,31 @@ else
   rm -rf conftest*
   
 	cf_search=""
-if test -d "$includedir"  ; then
-test "$includedir" != NONE       && cf_search="$cf_search $includedir $includedir/ncurses"
-fi
-if test -d "$oldincludedir"  ; then
-test "$oldincludedir" != NONE    && cf_search="$cf_search $oldincludedir $oldincludedir/ncurses"
-fi
-if test -d "$prefix"; then
-test "$prefix" != NONE           && cf_search="$cf_search $prefix/include $prefix/include/ncurses"
-fi
-test "$prefix" != /usr/local     && cf_search="$cf_search /usr/local/include /usr/local/include/ncurses"
-test "$prefix" != /usr           && cf_search="$cf_search /usr/include /usr/include/ncurses"
-test "$prefix" != /opt           && cf_search="$cf_search /opt/include /opt/include/ncurses"
+
+test "$includedir" != NONE && \
+test -d "$includedir" && \
+cf_search="$cf_search $includedir $includedir/ncurses"
+
+test "$oldincludedir" != NONE && \
+test -d "$oldincludedir" && \
+cf_search="$cf_search $oldincludedir $oldincludedir/ncurses"
+
+test "$prefix" != NONE && \
+test -d "$prefix" && \
+cf_search="$cf_search $prefix/include $prefix/include/ncurses $prefix/ncurses/include"
+
+test "$prefix" != /usr/local && \
+test -d /usr/local && \
+cf_search="$cf_search /usr/local/include /usr/local/include/ncurses /usr/local/ncurses/include"
+
+test "$prefix" != /usr && \
+cf_search="$cf_search /usr/include /usr/include/ncurses /usr/ncurses/include"
+
+test "$prefix" != /opt && \
+test -d /opt && \
+cf_search="$cf_search /opt/include /opt/include/ncurses /opt/ncurses/include"
+
+cf_search="$cf_search $HOME/lib $HOME/lib/ncurses $HOME/ncurses/lib"
 
 	test -n "$verbose" && echo
 	for cf_incdir in $cf_search
@@ -7204,7 +7230,7 @@ done
 	;;
 esac
 echo $ac_n "checking for ncurses version""... $ac_c" 1>&6
-echo "configure:7208: checking for ncurses version" >&5
+echo "configure:7234: checking for ncurses version" >&5
 if eval "test \"`echo '$''{'cf_cv_ncurses_version'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -7229,7 +7255,7 @@ Autoconf "old"
 #endif
 EOF
 	cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
-	{ (eval echo configure:7233: \"$cf_try\") 1>&5; (eval $cf_try) 2>&5; }
+	{ (eval echo configure:7259: \"$cf_try\") 1>&5; (eval $cf_try) 2>&5; }
 	if test -f conftest.out ; then
 		cf_out=`cat conftest.out | sed -e 's@^Autoconf @@' -e 's@^[^"]*"@@' -e 's@".*@@'`
 		test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
@@ -7238,7 +7264,7 @@ EOF
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 7242 "configure"
+#line 7268 "configure"
 #include "confdefs.h"
 
 #include <${cf_cv_ncurses_header-curses.h}>
@@ -7261,7 +7287,7 @@ int main()
 	exit(0);
 }
 EOF
-if { (eval echo configure:7265: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:7291: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
 	cf_cv_ncurses_version=`cat $cf_tempfile`
@@ -7286,7 +7312,7 @@ echo "$ac_t""$cf_cv_ncurses_version" 1>&6
 cf_ncurses_LIBS=""
 cf_ncurses_SAVE="$LIBS"
 echo $ac_n "checking for Gpm_Open in -lgpm""... $ac_c" 1>&6
-echo "configure:7290: checking for Gpm_Open in -lgpm" >&5
+echo "configure:7316: checking for Gpm_Open in -lgpm" >&5
 ac_lib_var=`echo gpm'_'Gpm_Open | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -7294,7 +7320,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgpm  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 7298 "configure"
+#line 7324 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -7305,7 +7331,7 @@ int main() {
 Gpm_Open()
 ; return 0; }
 EOF
-if { (eval echo configure:7309: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7335: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7321,7 +7347,7 @@ fi
 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
   echo "$ac_t""yes" 1>&6
   echo $ac_n "checking for initscr in -lgpm""... $ac_c" 1>&6
-echo "configure:7325: checking for initscr in -lgpm" >&5
+echo "configure:7351: checking for initscr in -lgpm" >&5
 ac_lib_var=`echo gpm'_'initscr | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -7329,7 +7355,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lgpm  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 7333 "configure"
+#line 7359 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -7340,7 +7366,7 @@ int main() {
 initscr()
 ; return 0; }
 EOF
-if { (eval echo configure:7344: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7370: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7371,7 +7397,7 @@ freebsd*)
 	# This is only necessary if you are linking against an obsolete
 	# version of ncurses (but it should do no harm, since it's static).
 	echo $ac_n "checking for tgoto in -lmytinfo""... $ac_c" 1>&6
-echo "configure:7375: checking for tgoto in -lmytinfo" >&5
+echo "configure:7401: checking for tgoto in -lmytinfo" >&5
 ac_lib_var=`echo mytinfo'_'tgoto | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -7379,7 +7405,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lmytinfo  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 7383 "configure"
+#line 7409 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -7390,7 +7416,7 @@ int main() {
 tgoto()
 ; return 0; }
 EOF
-if { (eval echo configure:7394: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7420: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7415,15 +7441,15 @@ esac
 
 LIBS="$cf_ncurses_LIBS $LIBS"
 
-	cf_cv_have_lib_ncurses=no
+	eval 'cf_cv_have_lib_'ncurses'=no'
 	cf_libdir=""
 	echo $ac_n "checking for initscr""... $ac_c" 1>&6
-echo "configure:7422: checking for initscr" >&5
+echo "configure:7448: checking for initscr" >&5
 if eval "test \"`echo '$''{'ac_cv_func_initscr'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 7427 "configure"
+#line 7453 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char initscr(); below.  */
@@ -7446,7 +7472,7 @@ initscr();
 
 ; return 0; }
 EOF
-if { (eval echo configure:7450: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7476: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_initscr=yes"
 else
@@ -7460,26 +7486,26 @@ fi
 
 if eval "test \"`echo '$ac_cv_func_'initscr`\" = yes"; then
   echo "$ac_t""yes" 1>&6
-  cf_cv_have_lib_ncurses=yes
+  eval 'cf_cv_have_lib_'ncurses'=yes'
 else
   echo "$ac_t""no" 1>&6
 
 		cf_save_LIBS="$LIBS"
 		echo $ac_n "checking for initscr in -lncurses""... $ac_c" 1>&6
-echo "configure:7470: checking for initscr in -lncurses" >&5
+echo "configure:7496: checking for initscr in -lncurses" >&5
 		LIBS="-lncurses $LIBS"
 		cat > conftest.$ac_ext <<EOF
-#line 7473 "configure"
+#line 7499 "configure"
 #include "confdefs.h"
 #include <${cf_cv_ncurses_header-curses.h}>
 int main() {
 initscr()
 ; return 0; }
 EOF
-if { (eval echo configure:7480: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7506: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   echo "$ac_t""yes" 1>&6
-			 cf_cv_have_lib_ncurses=yes
+			 eval 'cf_cv_have_lib_'ncurses'=yes'
 			
 else
   echo "configure: failed program was:" >&5
@@ -7487,37 +7513,53 @@ else
   rm -rf conftest*
   echo "$ac_t""no" 1>&6
 			cf_search=""
-if test -d "$libdir"  ; then
-test "$libdir" != NONE           && cf_search="$cf_search $libdir $libdir/ncurses"
-fi
-if test -d "$exec_prefix"; then
-test "$exec_prefix" != NONE      && cf_search="$cf_search $exec_prefix/lib $exec_prefix/lib/ncurses"
-fi
-if test -d "$prefix"; then
-test "$prefix" != NONE           && \
-test "$prefix" != "$exec_prefix" && cf_search="$cf_search $prefix/lib $prefix/lib/ncurses"
-fi
-test "$prefix" != /usr/local     && cf_search="$cf_search /usr/local/lib /usr/local/lib/ncurses"
-test "$prefix" != /usr           && cf_search="$cf_search /usr/lib /usr/lib/ncurses"
-test "$prefix" != /opt           && cf_search="$cf_search /opt/lib /opt/lib/ncurses"
+
+test "$libdir" != NONE && \
+test -d $libdir && \
+cf_search="$cf_search $libdir $libdir/ncurses"
+
+test "$exec_prefix" != NONE && \
+test -d $exec_prefix && \
+cf_search="$cf_search $exec_prefix/lib $exec_prefix/lib/ncurses"
+
+test "$prefix" != NONE && \
+test "$prefix" != "$exec_prefix" && \
+test -d $prefix && \
+cf_search="$cf_search $prefix/lib $prefix/lib/ncurses $prefix/ncurses/lib"
+
+test "$prefix" != /usr/local && \
+test -d /usr/local && \
+cf_search="$cf_search /usr/local/lib /usr/local/lib/ncurses /usr/local/ncurses/lib"
+
+test "$prefix" != /usr && \
+cf_search="$cf_search /usr/lib /usr/lib/ncurses /usr/ncurses/lib"
+
+test "$prefix" != / && \
+cf_search="$cf_search /lib /lib/ncurses /ncurses/lib"
+
+test "$prefix" != /opt && \
+test -d /opt && \
+cf_search="$cf_search /opt/lib /opt/lib/ncurses /opt/ncurses/lib"
+
+cf_search="$cf_search $HOME/lib $HOME/lib/ncurses $HOME/ncurses/lib"
 
 			for cf_libdir in $cf_search
 			do
 				echo $ac_n "checking for -lncurses in $cf_libdir""... $ac_c" 1>&6
-echo "configure:7508: checking for -lncurses in $cf_libdir" >&5
+echo "configure:7550: checking for -lncurses in $cf_libdir" >&5
 				LIBS="-L$cf_libdir -lncurses $cf_save_LIBS"
 				cat > conftest.$ac_ext <<EOF
-#line 7511 "configure"
+#line 7553 "configure"
 #include "confdefs.h"
 #include <${cf_cv_ncurses_header-curses.h}>
 int main() {
 initscr()
 ; return 0; }
 EOF
-if { (eval echo configure:7518: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7560: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   echo "$ac_t""yes" 1>&6
-			 		 cf_cv_have_lib_ncurses=yes
+			 		 eval 'cf_cv_have_lib_'ncurses'=yes'
 					 break
 else
   echo "configure: failed program was:" >&5
@@ -7534,19 +7576,17 @@ rm -f conftest*
 		
 fi
 
-if test $cf_cv_have_lib_ncurses = no ; then
+eval 'cf_found_library=$cf_cv_have_lib_'ncurses
+
+if test $cf_found_library = no ; then
 	{ echo "configure: error: Cannot link ncurses library" 1>&2; exit 1; }
 fi
-case $host_os in #(vi
-linux*) # Suse Linux does not follow /usr/lib convention
-	LIBS="$LIBS -L/lib"
-	;;
-esac
+
 
 
 if test -n "$cf_ncurses_LIBS" ; then
 	echo $ac_n "checking if we can link ncurses without $cf_ncurses_LIBS""... $ac_c" 1>&6
-echo "configure:7550: checking if we can link ncurses without $cf_ncurses_LIBS" >&5
+echo "configure:7590: checking if we can link ncurses without $cf_ncurses_LIBS" >&5
 	cf_ncurses_SAVE="$LIBS"
 	for p in $cf_ncurses_LIBS ; do
 		q=`echo $LIBS | sed -e 's/'$p' //' -e 's/'$p'$//'`
@@ -7555,14 +7595,14 @@ echo "configure:7550: checking if we can link ncurses without $cf_ncurses_LIBS"
 		fi
 	done
 	cat > conftest.$ac_ext <<EOF
-#line 7559 "configure"
+#line 7599 "configure"
 #include "confdefs.h"
 #include <${cf_cv_ncurses_header-curses.h}>
 int main() {
 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
 ; return 0; }
 EOF
-if { (eval echo configure:7566: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7606: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   echo "$ac_t""yes" 1>&6
 else
@@ -7582,20 +7622,20 @@ pdcurses)
 slang)
 	
 echo $ac_n "checking for slang header file""... $ac_c" 1>&6
-echo "configure:7586: checking for slang header file" >&5
+echo "configure:7626: checking for slang header file" >&5
 if eval "test \"`echo '$''{'cf_cv_slang_header'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 	cat > conftest.$ac_ext <<EOF
-#line 7592 "configure"
+#line 7632 "configure"
 #include "confdefs.h"
 #include <slang.h>
 int main() {
 printf("%s\n", SLANG_VERSION)
 ; return 0; }
 EOF
-if { (eval echo configure:7599: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:7639: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_slang_header=predefined
 else
@@ -7604,18 +7644,31 @@ else
   rm -rf conftest*
   
 	cf_search=""
-if test -d "$includedir"  ; then
-test "$includedir" != NONE       && cf_search="$cf_search $includedir $includedir/slang"
-fi
-if test -d "$oldincludedir"  ; then
-test "$oldincludedir" != NONE    && cf_search="$cf_search $oldincludedir $oldincludedir/slang"
-fi
-if test -d "$prefix"; then
-test "$prefix" != NONE           && cf_search="$cf_search $prefix/include $prefix/include/slang"
-fi
-test "$prefix" != /usr/local     && cf_search="$cf_search /usr/local/include /usr/local/include/slang"
-test "$prefix" != /usr           && cf_search="$cf_search /usr/include /usr/include/slang"
-test "$prefix" != /opt           && cf_search="$cf_search /opt/include /opt/include/slang"
+
+test "$includedir" != NONE && \
+test -d "$includedir" && \
+cf_search="$cf_search $includedir $includedir/slang"
+
+test "$oldincludedir" != NONE && \
+test -d "$oldincludedir" && \
+cf_search="$cf_search $oldincludedir $oldincludedir/slang"
+
+test "$prefix" != NONE && \
+test -d "$prefix" && \
+cf_search="$cf_search $prefix/include $prefix/include/slang $prefix/slang/include"
+
+test "$prefix" != /usr/local && \
+test -d /usr/local && \
+cf_search="$cf_search /usr/local/include /usr/local/include/slang /usr/local/slang/include"
+
+test "$prefix" != /usr && \
+cf_search="$cf_search /usr/include /usr/include/slang /usr/slang/include"
+
+test "$prefix" != /opt && \
+test -d /opt && \
+cf_search="$cf_search /opt/include /opt/include/slang /opt/slang/include"
+
+cf_search="$cf_search $HOME/lib $HOME/lib/slang $HOME/slang/lib"
 
 	for cf_incdir in $cf_search
 	do
@@ -7678,24 +7731,24 @@ else
   
 cf_cv_termlib=none
 cat > conftest.$ac_ext <<EOF
-#line 7682 "configure"
+#line 7735 "configure"
 #include "confdefs.h"
 
 int main() {
 char *x=(char*)tgoto("",0,0)
 ; return 0; }
 EOF
-if { (eval echo configure:7689: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7742: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cat > conftest.$ac_ext <<EOF
-#line 7692 "configure"
+#line 7745 "configure"
 #include "confdefs.h"
 
 int main() {
 int x=tigetstr("")
 ; return 0; }
 EOF
-if { (eval echo configure:7699: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7752: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_termlib=terminfo
 else
@@ -7724,16 +7777,16 @@ if test "$cf_cv_termlib" = none; then
 	for cf_func in tigetstr tgetstr
 	do
 		echo $ac_n "checking for $cf_func in -l$cf_lib""... $ac_c" 1>&6
-echo "configure:7728: checking for $cf_func in -l$cf_lib" >&5
+echo "configure:7781: checking for $cf_func in -l$cf_lib" >&5
 		cat > conftest.$ac_ext <<EOF
-#line 7730 "configure"
+#line 7783 "configure"
 #include "confdefs.h"
 
 int main() {
 int x=$cf_func("")
 ; return 0; }
 EOF
-if { (eval echo configure:7737: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7790: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_result=yes
 else
@@ -7760,7 +7813,7 @@ fi
 if test "$cf_cv_termlib" = none; then
 	# allow curses library for broken AIX system.
 	echo $ac_n "checking for initscr in -lcurses""... $ac_c" 1>&6
-echo "configure:7764: checking for initscr in -lcurses" >&5
+echo "configure:7817: checking for initscr in -lcurses" >&5
 ac_lib_var=`echo curses'_'initscr | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -7768,7 +7821,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lcurses  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 7772 "configure"
+#line 7825 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -7779,7 +7832,7 @@ int main() {
 initscr()
 ; return 0; }
 EOF
-if { (eval echo configure:7783: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7836: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7800,7 +7853,7 @@ else
 fi
 
 	echo $ac_n "checking for tgoto in -ltermcap""... $ac_c" 1>&6
-echo "configure:7804: checking for tgoto in -ltermcap" >&5
+echo "configure:7857: checking for tgoto in -ltermcap" >&5
 ac_lib_var=`echo termcap'_'tgoto | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -7808,7 +7861,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ltermcap  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 7812 "configure"
+#line 7865 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -7819,7 +7872,7 @@ int main() {
 tgoto()
 ; return 0; }
 EOF
-if { (eval echo configure:7823: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7876: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7851,12 +7904,12 @@ fi
 
 cf_slang_LIBS2="$LIBS"
 echo $ac_n "checking for acos""... $ac_c" 1>&6
-echo "configure:7855: checking for acos" >&5
+echo "configure:7908: checking for acos" >&5
 if eval "test \"`echo '$''{'ac_cv_func_acos'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 7860 "configure"
+#line 7913 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char acos(); below.  */
@@ -7879,7 +7932,7 @@ acos();
 
 ; return 0; }
 EOF
-if { (eval echo configure:7883: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7936: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_acos=yes"
 else
@@ -7898,7 +7951,7 @@ else
   echo "$ac_t""no" 1>&6
 
 echo $ac_n "checking for acos in -lm""... $ac_c" 1>&6
-echo "configure:7902: checking for acos in -lm" >&5
+echo "configure:7955: checking for acos in -lm" >&5
 ac_lib_var=`echo m'_'acos | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -7906,7 +7959,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lm $LIBS $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 7910 "configure"
+#line 7963 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -7917,7 +7970,7 @@ int main() {
 acos()
 ; return 0; }
 EOF
-if { (eval echo configure:7921: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7974: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -7954,15 +8007,15 @@ fi
 fi
 
 
-	cf_cv_have_lib_slang=no
+	eval 'cf_cv_have_lib_'slang'=no'
 	cf_libdir=""
 	echo $ac_n "checking for SLtt_get_screen_size""... $ac_c" 1>&6
-echo "configure:7961: checking for SLtt_get_screen_size" >&5
+echo "configure:8014: checking for SLtt_get_screen_size" >&5
 if eval "test \"`echo '$''{'ac_cv_func_SLtt_get_screen_size'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 7966 "configure"
+#line 8019 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char SLtt_get_screen_size(); below.  */
@@ -7985,7 +8038,7 @@ SLtt_get_screen_size();
 
 ; return 0; }
 EOF
-if { (eval echo configure:7989: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8042: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_SLtt_get_screen_size=yes"
 else
@@ -7999,26 +8052,26 @@ fi
 
 if eval "test \"`echo '$ac_cv_func_'SLtt_get_screen_size`\" = yes"; then
   echo "$ac_t""yes" 1>&6
-  cf_cv_have_lib_slang=yes
+  eval 'cf_cv_have_lib_'slang'=yes'
 else
   echo "$ac_t""no" 1>&6
 
 		cf_save_LIBS="$LIBS"
 		echo $ac_n "checking for SLtt_get_screen_size in -lslang""... $ac_c" 1>&6
-echo "configure:8009: checking for SLtt_get_screen_size in -lslang" >&5
+echo "configure:8062: checking for SLtt_get_screen_size in -lslang" >&5
 		LIBS="-lslang $LIBS"
 		cat > conftest.$ac_ext <<EOF
-#line 8012 "configure"
+#line 8065 "configure"
 #include "confdefs.h"
 #include <slang.h>
 int main() {
 SLtt_get_screen_size()
 ; return 0; }
 EOF
-if { (eval echo configure:8019: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8072: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   echo "$ac_t""yes" 1>&6
-			 cf_cv_have_lib_slang=yes
+			 eval 'cf_cv_have_lib_'slang'=yes'
 			
 else
   echo "configure: failed program was:" >&5
@@ -8026,37 +8079,53 @@ else
   rm -rf conftest*
   echo "$ac_t""no" 1>&6
 			cf_search=""
-if test -d "$libdir"  ; then
-test "$libdir" != NONE           && cf_search="$cf_search $libdir $libdir/slang"
-fi
-if test -d "$exec_prefix"; then
-test "$exec_prefix" != NONE      && cf_search="$cf_search $exec_prefix/lib $exec_prefix/lib/slang"
-fi
-if test -d "$prefix"; then
-test "$prefix" != NONE           && \
-test "$prefix" != "$exec_prefix" && cf_search="$cf_search $prefix/lib $prefix/lib/slang"
-fi
-test "$prefix" != /usr/local     && cf_search="$cf_search /usr/local/lib /usr/local/lib/slang"
-test "$prefix" != /usr           && cf_search="$cf_search /usr/lib /usr/lib/slang"
-test "$prefix" != /opt           && cf_search="$cf_search /opt/lib /opt/lib/slang"
+
+test "$libdir" != NONE && \
+test -d $libdir && \
+cf_search="$cf_search $libdir $libdir/slang"
+
+test "$exec_prefix" != NONE && \
+test -d $exec_prefix && \
+cf_search="$cf_search $exec_prefix/lib $exec_prefix/lib/slang"
+
+test "$prefix" != NONE && \
+test "$prefix" != "$exec_prefix" && \
+test -d $prefix && \
+cf_search="$cf_search $prefix/lib $prefix/lib/slang $prefix/slang/lib"
+
+test "$prefix" != /usr/local && \
+test -d /usr/local && \
+cf_search="$cf_search /usr/local/lib /usr/local/lib/slang /usr/local/slang/lib"
+
+test "$prefix" != /usr && \
+cf_search="$cf_search /usr/lib /usr/lib/slang /usr/slang/lib"
+
+test "$prefix" != / && \
+cf_search="$cf_search /lib /lib/slang /slang/lib"
+
+test "$prefix" != /opt && \
+test -d /opt && \
+cf_search="$cf_search /opt/lib /opt/lib/slang /opt/slang/lib"
+
+cf_search="$cf_search $HOME/lib $HOME/lib/slang $HOME/slang/lib"
 
 			for cf_libdir in $cf_search
 			do
 				echo $ac_n "checking for -lslang in $cf_libdir""... $ac_c" 1>&6
-echo "configure:8047: checking for -lslang in $cf_libdir" >&5
+echo "configure:8116: checking for -lslang in $cf_libdir" >&5
 				LIBS="-L$cf_libdir -lslang $cf_save_LIBS"
 				cat > conftest.$ac_ext <<EOF
-#line 8050 "configure"
+#line 8119 "configure"
 #include "confdefs.h"
 #include <slang.h>
 int main() {
 SLtt_get_screen_size()
 ; return 0; }
 EOF
-if { (eval echo configure:8057: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8126: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   echo "$ac_t""yes" 1>&6
-			 		 cf_cv_have_lib_slang=yes
+			 		 eval 'cf_cv_have_lib_'slang'=yes'
 					 break
 else
   echo "configure: failed program was:" >&5
@@ -8073,18 +8142,16 @@ rm -f conftest*
 		
 fi
 
-if test $cf_cv_have_lib_slang = no ; then
+eval 'cf_found_library=$cf_cv_have_lib_'slang
+
+if test $cf_found_library = no ; then
 	{ echo "configure: error: Cannot link slang library" 1>&2; exit 1; }
 fi
-case $host_os in #(vi
-linux*) # Suse Linux does not follow /usr/lib convention
-	LIBS="$LIBS -L/lib"
-	;;
-esac
+
 
 cf_slang_LIBS3="$LIBS"
 echo $ac_n "checking if we can link slang without termcap""... $ac_c" 1>&6
-echo "configure:8088: checking if we can link slang without termcap" >&5
+echo "configure:8155: checking if we can link slang without termcap" >&5
 if test -n "`echo $cf_slang_LIBS1 | sed -e 's/ //g'`" ; then
 	cf_exclude=`echo ".$cf_slang_LIBS2" | sed -e "s@$cf_slang_LIBS1@@" -e 's@^.@@'`
 else
@@ -8092,14 +8159,14 @@ else
 fi
 LIBS=`echo ".$cf_slang_LIBS3" | sed -e "s@$cf_exclude@@" -e 's@^.@@'`
 cat > conftest.$ac_ext <<EOF
-#line 8096 "configure"
+#line 8163 "configure"
 #include "confdefs.h"
 #include <slang.h>
 int main() {
 SLtt_get_screen_size()
 ; return 0; }
 EOF
-if { (eval echo configure:8103: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8170: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_result=yes
 else
@@ -8116,13 +8183,13 @@ test $cf_result = no && LIBS="$cf_slang_LIBS3"
 
 
 echo $ac_n "checking if we must tell slang this is UNIX""... $ac_c" 1>&6
-echo "configure:8120: checking if we must tell slang this is UNIX" >&5
+echo "configure:8187: checking if we must tell slang this is UNIX" >&5
 if eval "test \"`echo '$''{'cf_cv_slang_unix'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 8126 "configure"
+#line 8193 "configure"
 #include "confdefs.h"
 #include <slang.h>
 int main() {
@@ -8136,7 +8203,7 @@ SLang_TT_Baud_Rate = 1
 
 ; return 0; }
 EOF
-if { (eval echo configure:8140: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8207: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_slang_unix=yes
 else
@@ -8162,7 +8229,7 @@ eval cf_libdir=$libdir
 cf_libdir=`echo $cf_libdir | sed -e s@'^NONE/'@$prefix/@ -e s@'^NONE/'@$ac_default_prefix/@`
 
 echo $ac_n "checking for location of config-file""... $ac_c" 1>&6
-echo "configure:8166: checking for location of config-file" >&5
+echo "configure:8233: checking for location of config-file" >&5
 LYNX_CFG_FILE=$cf_libdir/lynx.cfg
 cat >> confdefs.h <<EOF
 #define LYNX_CFG_FILE "$LYNX_CFG_FILE"
@@ -8174,7 +8241,7 @@ CHARSET_DEFS=
 
 
 echo $ac_n "checking if you want only a few charsets""... $ac_c" 1>&6
-echo "configure:8178: checking if you want only a few charsets" >&5
+echo "configure:8245: checking if you want only a few charsets" >&5
 
 # Check whether --with-charsets or --without-charsets was given.
 if test "${with_charsets+set}" = set; then
@@ -8235,12 +8302,12 @@ fi
 
 
 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:8239: checking for ANSI C header files" >&5
+echo "configure:8306: checking for ANSI C header files" >&5
 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 8244 "configure"
+#line 8311 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 #include <stdarg.h>
@@ -8248,7 +8315,7 @@ else
 #include <float.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8252: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8319: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -8265,7 +8332,7 @@ rm -f conftest*
 if test $ac_cv_header_stdc = yes; then
   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 8269 "configure"
+#line 8336 "configure"
 #include "confdefs.h"
 #include <string.h>
 EOF
@@ -8283,7 +8350,7 @@ fi
 if test $ac_cv_header_stdc = yes; then
   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
 cat > conftest.$ac_ext <<EOF
-#line 8287 "configure"
+#line 8354 "configure"
 #include "confdefs.h"
 #include <stdlib.h>
 EOF
@@ -8304,7 +8371,7 @@ if test "$cross_compiling" = yes; then
   :
 else
   cat > conftest.$ac_ext <<EOF
-#line 8308 "configure"
+#line 8375 "configure"
 #include "confdefs.h"
 #include <ctype.h>
 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
@@ -8315,7 +8382,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
 exit (0); }
 
 EOF
-if { (eval echo configure:8319: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:8386: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   :
 else
@@ -8339,12 +8406,12 @@ EOF
 fi
 
 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
-echo "configure:8343: checking whether time.h and sys/time.h may both be included" >&5
+echo "configure:8410: checking whether time.h and sys/time.h may both be included" >&5
 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 8348 "configure"
+#line 8415 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <sys/time.h>
@@ -8353,7 +8420,7 @@ int main() {
 struct tm *tp;
 ; return 0; }
 EOF
-if { (eval echo configure:8357: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:8424: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   ac_cv_header_time=yes
 else
@@ -8378,12 +8445,12 @@ for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
-echo "configure:8382: checking for $ac_hdr that defines DIR" >&5
+echo "configure:8449: checking for $ac_hdr that defines DIR" >&5
 if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 8387 "configure"
+#line 8454 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #include <$ac_hdr>
@@ -8391,7 +8458,7 @@ int main() {
 DIR *dirp = 0;
 ; return 0; }
 EOF
-if { (eval echo configure:8395: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:8462: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   eval "ac_cv_header_dirent_$ac_safe=yes"
 else
@@ -8416,7 +8483,7 @@ done
 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
 if test $ac_header_dirent = dirent.h; then
 echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
-echo "configure:8420: checking for opendir in -ldir" >&5
+echo "configure:8487: checking for opendir in -ldir" >&5
 ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -8424,7 +8491,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldir  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 8428 "configure"
+#line 8495 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -8435,7 +8502,7 @@ int main() {
 opendir()
 ; return 0; }
 EOF
-if { (eval echo configure:8439: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8506: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -8457,7 +8524,7 @@ fi
 
 else
 echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
-echo "configure:8461: checking for opendir in -lx" >&5
+echo "configure:8528: checking for opendir in -lx" >&5
 ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -8465,7 +8532,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lx  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 8469 "configure"
+#line 8536 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -8476,7 +8543,7 @@ int main() {
 opendir()
 ; return 0; }
 EOF
-if { (eval echo configure:8480: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8547: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -8517,17 +8584,17 @@ for ac_hdr in \
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:8521: checking for $ac_hdr" >&5
+echo "configure:8588: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 8526 "configure"
+#line 8593 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8531: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8598: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -8555,13 +8622,13 @@ done
 
 
 echo $ac_n "checking termio.h and termios.h""... $ac_c" 1>&6
-echo "configure:8559: checking termio.h and termios.h" >&5
+echo "configure:8626: checking termio.h and termios.h" >&5
 if eval "test \"`echo '$''{'cf_cv_termio_and_termios'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     cat > conftest.$ac_ext <<EOF
-#line 8565 "configure"
+#line 8632 "configure"
 #include "confdefs.h"
 
 #if HAVE_TERMIO_H
@@ -8574,7 +8641,7 @@ int main() {
 putchar (0x0a)
 ; return 0; }
 EOF
-if { (eval echo configure:8578: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:8645: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_termio_and_termios=yes
 else
@@ -8594,13 +8661,13 @@ EOF
 
 
 echo $ac_n "checking for sigaction and structs""... $ac_c" 1>&6
-echo "configure:8598: checking for sigaction and structs" >&5
+echo "configure:8665: checking for sigaction and structs" >&5
 if eval "test \"`echo '$''{'cf_cv_func_sigaction'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 8604 "configure"
+#line 8671 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -8615,7 +8682,7 @@ struct sigaction act;
 	
 ; return 0; }
 EOF
-if { (eval echo configure:8619: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8686: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_func_sigaction=yes
 else
@@ -8639,17 +8706,17 @@ for ac_hdr in sys/wait.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:8643: checking for $ac_hdr" >&5
+echo "configure:8710: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 8648 "configure"
+#line 8715 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8653: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8720: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -8686,17 +8753,17 @@ for ac_hdr in wait.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:8690: checking for $ac_hdr" >&5
+echo "configure:8757: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 8695 "configure"
+#line 8762 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8700: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8767: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -8726,17 +8793,17 @@ for ac_hdr in waitstatus.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:8730: checking for $ac_hdr" >&5
+echo "configure:8797: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 8735 "configure"
+#line 8802 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8740: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:8807: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -8777,13 +8844,13 @@ fi
 
 
 echo $ac_n "checking for union wait""... $ac_c" 1>&6
-echo "configure:8781: checking for union wait" >&5
+echo "configure:8848: checking for union wait" >&5
 if eval "test \"`echo '$''{'cf_cv_type_unionwait'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 	cat > conftest.$ac_ext <<EOF
-#line 8787 "configure"
+#line 8854 "configure"
 #include "confdefs.h"
 $cf_wait_headers
 int main() {
@@ -8794,7 +8861,7 @@ int x;
 	
 ; return 0; }
 EOF
-if { (eval echo configure:8798: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8865: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_type_unionwait=no
 	 echo compiles ok w/o union wait 1>&5
@@ -8805,7 +8872,7 @@ else
   rm -rf conftest*
   
 	cat > conftest.$ac_ext <<EOF
-#line 8809 "configure"
+#line 8876 "configure"
 #include "confdefs.h"
 $cf_wait_headers
 int main() {
@@ -8820,7 +8887,7 @@ union wait x;
 	
 ; return 0; }
 EOF
-if { (eval echo configure:8824: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:8891: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_type_unionwait=yes
 	 echo compiles ok with union wait and possibly macros too 1>&5
@@ -8847,20 +8914,20 @@ EOF
 if test $cf_cv_type_unionwait = yes; then
 
 	echo $ac_n "checking if union wait can be used as wait-arg""... $ac_c" 1>&6
-echo "configure:8851: checking if union wait can be used as wait-arg" >&5
+echo "configure:8918: checking if union wait can be used as wait-arg" >&5
 	if eval "test \"`echo '$''{'cf_cv_arg_union_wait'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 		cat > conftest.$ac_ext <<EOF
-#line 8857 "configure"
+#line 8924 "configure"
 #include "confdefs.h"
 $cf_wait_headers
 int main() {
 union wait x; wait(&x)
 ; return 0; }
 EOF
-if { (eval echo configure:8864: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:8931: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_arg_union_wait=yes
 else
@@ -8880,20 +8947,20 @@ EOF
 
 
 	echo $ac_n "checking if union wait can be used as waitpid-arg""... $ac_c" 1>&6
-echo "configure:8884: checking if union wait can be used as waitpid-arg" >&5
+echo "configure:8951: checking if union wait can be used as waitpid-arg" >&5
 	if eval "test \"`echo '$''{'cf_cv_arg_union_waitpid'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 		cat > conftest.$ac_ext <<EOF
-#line 8890 "configure"
+#line 8957 "configure"
 #include "confdefs.h"
 $cf_wait_headers
 int main() {
 union wait x; waitpid(0, &x, 0)
 ; return 0; }
 EOF
-if { (eval echo configure:8897: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:8964: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_arg_union_waitpid=yes
 else
@@ -8919,17 +8986,17 @@ for ac_hdr in stdarg.h varargs.h
 do
 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:8923: checking for $ac_hdr" >&5
+echo "configure:8990: checking for $ac_hdr" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 8928 "configure"
+#line 8995 "configure"
 #include "confdefs.h"
 #include <$ac_hdr>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:8933: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:9000: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -8956,13 +9023,13 @@ fi
 done
 
 echo $ac_n "checking for standard varargs""... $ac_c" 1>&6
-echo "configure:8960: checking for standard varargs" >&5
+echo "configure:9027: checking for standard varargs" >&5
 if eval "test \"`echo '$''{'cf_cv_ansi_varargs'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 	cat > conftest.$ac_ext <<EOF
-#line 8966 "configure"
+#line 9033 "configure"
 #include "confdefs.h"
 
 #if HAVE_STDARG_H
@@ -8977,7 +9044,7 @@ int main() {
 return 0;} int foo(char *fmt,...){va_list args;va_start(args,fmt);va_end(args)
 ; return 0; }
 EOF
-if { (eval echo configure:8981: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:9048: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_ansi_varargs=yes
 else
@@ -8997,12 +9064,12 @@ EOF
 
 
 echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
-echo "configure:9001: checking for uid_t in sys/types.h" >&5
+echo "configure:9068: checking for uid_t in sys/types.h" >&5
 if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 9006 "configure"
+#line 9073 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 EOF
@@ -9031,7 +9098,7 @@ EOF
 fi
 
 echo $ac_n "checking type of array argument to getgroups""... $ac_c" 1>&6
-echo "configure:9035: checking type of array argument to getgroups" >&5
+echo "configure:9102: checking type of array argument to getgroups" >&5
 if eval "test \"`echo '$''{'ac_cv_type_getgroups'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -9039,7 +9106,7 @@ else
   ac_cv_type_getgroups=cross
 else
   cat > conftest.$ac_ext <<EOF
-#line 9043 "configure"
+#line 9110 "configure"
 #include "confdefs.h"
 
 /* Thanks to Mike Rendell for this test.  */
@@ -9064,7 +9131,7 @@ main()
 }
 
 EOF
-if { (eval echo configure:9068: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:9135: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
     ac_cv_type_getgroups=gid_t
 else
@@ -9078,7 +9145,7 @@ fi
 
 if test $ac_cv_type_getgroups = cross; then
         cat > conftest.$ac_ext <<EOF
-#line 9082 "configure"
+#line 9149 "configure"
 #include "confdefs.h"
 #include <unistd.h>
 EOF
@@ -9102,12 +9169,12 @@ EOF
 
 
 echo $ac_n "checking for pid_t""... $ac_c" 1>&6
-echo "configure:9106: checking for pid_t" >&5
+echo "configure:9173: checking for pid_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 9111 "configure"
+#line 9178 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -9135,12 +9202,12 @@ EOF
 fi
 
 echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
-echo "configure:9139: checking for uid_t in sys/types.h" >&5
+echo "configure:9206: checking for uid_t in sys/types.h" >&5
 if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 9144 "configure"
+#line 9211 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 EOF
@@ -9169,12 +9236,12 @@ EOF
 fi
 
 echo $ac_n "checking for mode_t""... $ac_c" 1>&6
-echo "configure:9173: checking for mode_t" >&5
+echo "configure:9240: checking for mode_t" >&5
 if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 9178 "configure"
+#line 9245 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if STDC_HEADERS
@@ -9205,17 +9272,17 @@ fi
 
 ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'`
 echo $ac_n "checking for vfork.h""... $ac_c" 1>&6
-echo "configure:9209: checking for vfork.h" >&5
+echo "configure:9276: checking for vfork.h" >&5
 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 9214 "configure"
+#line 9281 "configure"
 #include "confdefs.h"
 #include <vfork.h>
 EOF
 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:9219: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:9286: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -9240,18 +9307,18 @@ else
 fi
 
 echo $ac_n "checking for working vfork""... $ac_c" 1>&6
-echo "configure:9244: checking for working vfork" >&5
+echo "configure:9311: checking for working vfork" >&5
 if eval "test \"`echo '$''{'ac_cv_func_vfork_works'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   if test "$cross_compiling" = yes; then
   echo $ac_n "checking for vfork""... $ac_c" 1>&6
-echo "configure:9250: checking for vfork" >&5
+echo "configure:9317: checking for vfork" >&5
 if eval "test \"`echo '$''{'ac_cv_func_vfork'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 9255 "configure"
+#line 9322 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char vfork(); below.  */
@@ -9274,7 +9341,7 @@ vfork();
 
 ; return 0; }
 EOF
-if { (eval echo configure:9278: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:9345: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_vfork=yes"
 else
@@ -9296,7 +9363,7 @@ fi
 ac_cv_func_vfork_works=$ac_cv_func_vfork
 else
   cat > conftest.$ac_ext <<EOF
-#line 9300 "configure"
+#line 9367 "configure"
 #include "confdefs.h"
 /* Thanks to Paul Eggert for this test.  */
 #include <stdio.h>
@@ -9391,7 +9458,7 @@ main() {
   }
 }
 EOF
-if { (eval echo configure:9395: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:9462: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   ac_cv_func_vfork_works=yes
 else
@@ -9415,13 +9482,13 @@ fi
 
 
 echo $ac_n "checking if we should use fcntl or ioctl""... $ac_c" 1>&6
-echo "configure:9419: checking if we should use fcntl or ioctl" >&5
+echo "configure:9486: checking if we should use fcntl or ioctl" >&5
 if eval "test \"`echo '$''{'cf_cv_fionbio'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 9425 "configure"
+#line 9492 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -9433,7 +9500,7 @@ int main() {
 	
 ; return 0; }
 EOF
-if { (eval echo configure:9437: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:9504: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_fionbio=ioctl
 else
@@ -9442,7 +9509,7 @@ else
   rm -rf conftest*
   
 cat > conftest.$ac_ext <<EOF
-#line 9446 "configure"
+#line 9513 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -9459,7 +9526,7 @@ int main() {
 	
 ; return 0; }
 EOF
-if { (eval echo configure:9463: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:9530: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_fionbio=fcntl
 else
@@ -9482,20 +9549,20 @@ EOF
 
 
 echo $ac_n "checking for broken/missing definition of remove""... $ac_c" 1>&6
-echo "configure:9486: checking for broken/missing definition of remove" >&5
+echo "configure:9553: checking for broken/missing definition of remove" >&5
 if eval "test \"`echo '$''{'cf_cv_baddef_remove'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 9492 "configure"
+#line 9559 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 int main() {
 remove("dummy")
 ; return 0; }
 EOF
-if { (eval echo configure:9499: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:9566: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_baddef_remove=no
 else
@@ -9503,7 +9570,7 @@ else
   cat conftest.$ac_ext >&5
   rm -rf conftest*
   cat > conftest.$ac_ext <<EOF
-#line 9507 "configure"
+#line 9574 "configure"
 #include "confdefs.h"
 #include <stdio.h>
 		int __unlink(name) { return unlink(name); } 
@@ -9511,7 +9578,7 @@ int main() {
 remove("dummy")
 ; return 0; }
 EOF
-if { (eval echo configure:9515: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:9582: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_baddef_remove=yes
 else
@@ -9535,13 +9602,13 @@ EOF
 
 
 echo $ac_n "checking for lstat""... $ac_c" 1>&6
-echo "configure:9539: checking for lstat" >&5
+echo "configure:9606: checking for lstat" >&5
 if eval "test \"`echo '$''{'ac_cv_func_lstat'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 9545 "configure"
+#line 9612 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
@@ -9550,7 +9617,7 @@ int main() {
 lstat(".", (struct stat *)0)
 ; return 0; }
 EOF
-if { (eval echo configure:9554: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:9621: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_cv_func_lstat=yes
 else
@@ -9593,12 +9660,12 @@ for ac_func in \
 
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:9597: checking for $ac_func" >&5
+echo "configure:9664: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 9602 "configure"
+#line 9669 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -9621,7 +9688,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:9625: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:9692: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -9651,12 +9718,12 @@ for ac_func in \
 
 do
 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:9655: checking for $ac_func" >&5
+echo "configure:9722: checking for $ac_func" >&5
 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 9660 "configure"
+#line 9727 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char $ac_func(); below.  */
@@ -9679,7 +9746,7 @@ $ac_func();
 
 ; return 0; }
 EOF
-if { (eval echo configure:9683: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:9750: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_$ac_func=yes"
 else
@@ -9710,12 +9777,12 @@ for ac_func in strstr
 do
 
 echo $ac_n "checking for $ac_func declaration""... $ac_c" 1>&6
-echo "configure:9714: checking for $ac_func declaration" >&5
+echo "configure:9781: checking for $ac_func declaration" >&5
 if eval "test \"`echo '$''{'ac_cv_func_decl_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 9719 "configure"
+#line 9786 "configure"
 #include "confdefs.h"
 #include <string.h>
 int main() {
@@ -9724,11 +9791,11 @@ extern	int	${ac_func}();
 #endif
 ; return 0; }
 EOF
-if { (eval echo configure:9728: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:9795: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
 cat > conftest.$ac_ext <<EOF
-#line 9732 "configure"
+#line 9799 "configure"
 #include "confdefs.h"
 #include <string.h>
 int main() {
@@ -9737,7 +9804,7 @@ int	(*p)() = ${ac_func};
 #endif
 ; return 0; }
 EOF
-if { (eval echo configure:9741: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:9808: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
 eval "ac_cv_func_decl_$ac_func=yes"
@@ -9779,12 +9846,12 @@ for ac_func in getgrgid getgrnam
 do
 
 echo $ac_n "checking for $ac_func declaration""... $ac_c" 1>&6
-echo "configure:9783: checking for $ac_func declaration" >&5
+echo "configure:9850: checking for $ac_func declaration" >&5
 if eval "test \"`echo '$''{'ac_cv_func_decl_$ac_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 9788 "configure"
+#line 9855 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -9795,11 +9862,11 @@ extern	int	${ac_func}();
 #endif
 ; return 0; }
 EOF
-if { (eval echo configure:9799: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:9866: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
 cat > conftest.$ac_ext <<EOF
-#line 9803 "configure"
+#line 9870 "configure"
 #include "confdefs.h"
 
 #include <stdio.h>
@@ -9810,7 +9877,7 @@ int	(*p)() = ${ac_func};
 #endif
 ; return 0; }
 EOF
-if { (eval echo configure:9814: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:9881: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   
 eval "ac_cv_func_decl_$ac_func=yes"
@@ -9852,13 +9919,13 @@ done
 
 
 echo $ac_n "checking if TRUE/FALSE are defined""... $ac_c" 1>&6
-echo "configure:9856: checking if TRUE/FALSE are defined" >&5
+echo "configure:9923: checking if TRUE/FALSE are defined" >&5
 if eval "test \"`echo '$''{'cf_cv_bool_defs'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 9862 "configure"
+#line 9929 "configure"
 #include "confdefs.h"
 
 #include <${cf_cv_ncurses_header-curses.h}>
@@ -9867,7 +9934,7 @@ int main() {
 int x = TRUE, y = FALSE
 ; return 0; }
 EOF
-if { (eval echo configure:9871: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:9938: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_bool_defs=yes
 else
@@ -9894,13 +9961,13 @@ fi
 
 
 echo $ac_n "checking if external errno is declared""... $ac_c" 1>&6
-echo "configure:9898: checking if external errno is declared" >&5
+echo "configure:9965: checking if external errno is declared" >&5
 if eval "test \"`echo '$''{'cf_cv_dcl_errno'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     cat > conftest.$ac_ext <<EOF
-#line 9904 "configure"
+#line 9971 "configure"
 #include "confdefs.h"
 
 #ifdef HAVE_STDLIB_H
@@ -9913,7 +9980,7 @@ int main() {
 long x = (long) errno
 ; return 0; }
 EOF
-if { (eval echo configure:9917: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:9984: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   eval 'cf_cv_dcl_'errno'=yes'
 else
@@ -9944,13 +10011,13 @@ fi
 # It's possible (for near-UNIX clones) that the data doesn't exist
 
 echo $ac_n "checking if external errno exists""... $ac_c" 1>&6
-echo "configure:9948: checking if external errno exists" >&5
+echo "configure:10015: checking if external errno exists" >&5
 if eval "test \"`echo '$''{'cf_cv_have_errno'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     cat > conftest.$ac_ext <<EOF
-#line 9954 "configure"
+#line 10021 "configure"
 #include "confdefs.h"
 
 #undef errno
@@ -9960,7 +10027,7 @@ int main() {
 errno = 2
 ; return 0; }
 EOF
-if { (eval echo configure:9964: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:10031: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval 'cf_cv_have_'errno'=yes'
 else
@@ -9992,21 +10059,21 @@ fi
 
 
 echo $ac_n "checking if we can set errno""... $ac_c" 1>&6
-echo "configure:9996: checking if we can set errno" >&5
+echo "configure:10063: checking if we can set errno" >&5
 if eval "test \"`echo '$''{'cf_cv_set_errno'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 if test "$cross_compiling" = yes; then
   cat > conftest.$ac_ext <<EOF
-#line 10003 "configure"
+#line 10070 "configure"
 #include "confdefs.h"
 #include <errno.h>
 int main() {
 errno = 255
 ; return 0; }
 EOF
-if { (eval echo configure:10010: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:10077: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_set_errno=maybe
 else
@@ -10018,7 +10085,7 @@ fi
 rm -f conftest*
 else
   cat > conftest.$ac_ext <<EOF
-#line 10022 "configure"
+#line 10089 "configure"
 #include "confdefs.h"
 
 #include <errno.h>
@@ -10028,7 +10095,7 @@ int main()
 	exit(errno != 255);
 }
 EOF
-if { (eval echo configure:10032: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:10099: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   cf_cv_set_errno=yes
 else
@@ -10051,20 +10118,20 @@ EOF
 
 
 echo $ac_n "checking for setlocale()""... $ac_c" 1>&6
-echo "configure:10055: checking for setlocale()" >&5
+echo "configure:10122: checking for setlocale()" >&5
 if eval "test \"`echo '$''{'cf_cv_locale'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 10061 "configure"
+#line 10128 "configure"
 #include "confdefs.h"
 #include <locale.h>
 int main() {
 setlocale(LC_ALL, "")
 ; return 0; }
 EOF
-if { (eval echo configure:10068: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:10135: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_locale=yes
 else
@@ -10085,13 +10152,13 @@ EOF
 
 
 echo $ac_n "checking if NGROUPS is defined""... $ac_c" 1>&6
-echo "configure:10089: checking if NGROUPS is defined" >&5
+echo "configure:10156: checking if NGROUPS is defined" >&5
 if eval "test \"`echo '$''{'cf_cv_ngroups'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 10095 "configure"
+#line 10162 "configure"
 #include "confdefs.h"
 
 #if HAVE_SYS_PARAM_H
@@ -10105,7 +10172,7 @@ int main() {
 int x = NGROUPS
 ; return 0; }
 EOF
-if { (eval echo configure:10109: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:10176: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_ngroups=yes
 else
@@ -10113,7 +10180,7 @@ else
   cat conftest.$ac_ext >&5
   rm -rf conftest*
   cat > conftest.$ac_ext <<EOF
-#line 10117 "configure"
+#line 10184 "configure"
 #include "confdefs.h"
 
 #if HAVE_SYS_PARAM_H
@@ -10127,7 +10194,7 @@ int main() {
 int x = NGROUPS_MAX
 ; return 0; }
 EOF
-if { (eval echo configure:10131: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:10198: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_ngroups=NGROUPS_MAX
 else
@@ -10161,13 +10228,13 @@ for cf_name in sys_nerr sys_errlist
 do
     
 echo $ac_n "checking if external $cf_name is declared""... $ac_c" 1>&6
-echo "configure:10165: checking if external $cf_name is declared" >&5
+echo "configure:10232: checking if external $cf_name is declared" >&5
 if eval "test \"`echo '$''{'cf_cv_dcl_$cf_name'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     cat > conftest.$ac_ext <<EOF
-#line 10171 "configure"
+#line 10238 "configure"
 #include "confdefs.h"
 
 #ifdef HAVE_STDLIB_H
@@ -10180,7 +10247,7 @@ int main() {
 long x = (long) $cf_name
 ; return 0; }
 EOF
-if { (eval echo configure:10184: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:10251: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   eval 'cf_cv_dcl_'$cf_name'=yes'
 else
@@ -10211,13 +10278,13 @@ fi
 # It's possible (for near-UNIX clones) that the data doesn't exist
 
 echo $ac_n "checking if external $cf_name exists""... $ac_c" 1>&6
-echo "configure:10215: checking if external $cf_name exists" >&5
+echo "configure:10282: checking if external $cf_name exists" >&5
 if eval "test \"`echo '$''{'cf_cv_have_$cf_name'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     cat > conftest.$ac_ext <<EOF
-#line 10221 "configure"
+#line 10288 "configure"
 #include "confdefs.h"
 
 #undef $cf_name
@@ -10227,7 +10294,7 @@ int main() {
 $cf_name = 2
 ; return 0; }
 EOF
-if { (eval echo configure:10231: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:10298: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval 'cf_cv_have_'$cf_name'=yes'
 else
@@ -10259,72 +10326,430 @@ fi
 done
 
 
-echo $ac_n "checking if struct utmp is declared""... $ac_c" 1>&6
-echo "configure:10264: checking if struct utmp is declared" >&5
+for ac_hdr in lastlog.h paths.h
+do
+ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
+echo "configure:10334: checking for $ac_hdr" >&5
+if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  cat > conftest.$ac_ext <<EOF
+#line 10339 "configure"
+#include "confdefs.h"
+#include <$ac_hdr>
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:10344: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
+if test -z "$ac_err"; then
+  rm -rf conftest*
+  eval "ac_cv_header_$ac_safe=yes"
+else
+  echo "$ac_err" >&5
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  eval "ac_cv_header_$ac_safe=no"
+fi
+rm -f conftest*
+fi
+if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
+  echo "$ac_t""yes" 1>&6
+    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
+  cat >> confdefs.h <<EOF
+#define $ac_tr_hdr 1
+EOF
+ 
+else
+  echo "$ac_t""no" 1>&6
+fi
+done
+
+echo $ac_n "checking for lastlog path""... $ac_c" 1>&6
+echo "configure:10371: checking for lastlog path" >&5
+if eval "test \"`echo '$''{'cf_cv_path_lastlog'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  
+cat > conftest.$ac_ext <<EOF
+#line 10377 "configure"
+#include "confdefs.h"
+
+#include <sys/types.h>
+#ifdef HAVE_LASTLOG_H
+#include <lastlog.h>
+#else
+#ifdef HAVE_PATHS_H
+#include <paths.h>
+#endif
+#endif
+int main() {
+char *path = _PATH_LASTLOG
+; return 0; }
+EOF
+if { (eval echo configure:10392: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  cf_cv_path_lastlog="_PATH_LASTLOG"
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  if test -f /usr/adm/lastlog ; then
+	 	cf_cv_path_lastlog=/usr/adm/lastlog
+	else
+		cf_cv_path_lastlog=no
+	fi
+fi
+rm -f conftest*
+
+fi
+
+echo "$ac_t""$cf_cv_path_lastlog" 1>&6
+test $cf_cv_path_lastlog != no && cat >> confdefs.h <<\EOF
+#define USE_LASTLOG 1
+EOF
+
+
+
+
+
+echo $ac_n "checking for utmp implementation""... $ac_c" 1>&6
+echo "configure:10419: checking for utmp implementation" >&5
 if eval "test \"`echo '$''{'cf_cv_have_utmp'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
+	cf_cv_have_utmp=no
+for cf_header in utmpx utmp ; do
 	cat > conftest.$ac_ext <<EOF
-#line 10270 "configure"
+#line 10427 "configure"
 #include "confdefs.h"
 
 #include <sys/types.h>
-#include <utmp.h>
+#include <${cf_header}.h>
+#define getutent getutxent
+#ifdef USE_LASTLOG
+#include <lastlog.h>	/* may conflict with utmpx.h on Linux */
+#endif
+
 int main() {
-struct utmp x; char *y = &x.ut_host[0]
+struct $cf_header x;
+	 char *name = x.ut_name; /* utmp.h and compatible definitions */
+	
 ; return 0; }
 EOF
-if { (eval echo configure:10279: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:10443: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
-  cf_cv_have_utmp=yes
+  cf_cv_have_utmp=$cf_header
+	 break
 else
   echo "configure: failed program was:" >&5
   cat conftest.$ac_ext >&5
   rm -rf conftest*
-  cat > conftest.$ac_ext <<EOF
-#line 10287 "configure"
+  
+	cat > conftest.$ac_ext <<EOF
+#line 10453 "configure"
 #include "confdefs.h"
-#include <utmpx.h>
+
+#include <sys/types.h>
+#include <${cf_header}.h>
+#define getutent getutxent
+#ifdef USE_LASTLOG
+#include <lastlog.h>	/* may conflict with utmpx.h on Linux */
+#endif
+
 int main() {
-struct utmpx x; char *y = &x.ut_host[0]
+struct $cf_header x;
+	 char *name = x.ut_user; /* utmpx.h must declare this */
+	
 ; return 0; }
 EOF
-if { (eval echo configure:10294: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:10469: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
-  cf_cv_have_utmp=utmpx
+  cf_cv_have_utmp=$cf_header
+	 cat >> confdefs.h <<\EOF
+#define ut_name ut_user
+EOF
+
+	 break
+	
 else
   echo "configure: failed program was:" >&5
   cat conftest.$ac_ext >&5
-  rm -rf conftest*
-  cf_cv_have_utmp=no
 fi
 rm -f conftest*
-		
 fi
 rm -f conftest*
-	
+done
+
 fi
 
 echo "$ac_t""$cf_cv_have_utmp" 1>&6
-test $cf_cv_have_utmp != no && cat >> confdefs.h <<\EOF
+
+if test $cf_cv_have_utmp != no ; then
+	cat >> confdefs.h <<\EOF
 #define HAVE_UTMP 1
 EOF
 
-test $cf_cv_have_utmp = utmpx && cat >> confdefs.h <<\EOF
+	test $cf_cv_have_utmp = utmpx && cat >> confdefs.h <<\EOF
 #define UTMPX_FOR_UTMP 1
 EOF
 
+	
+
+if test $cf_cv_have_utmp != no ; then
+echo $ac_n "checking if utmp.ut_host is declared""... $ac_c" 1>&6
+echo "configure:10504: checking if utmp.ut_host is declared" >&5
+if eval "test \"`echo '$''{'cf_cv_have_utmp_ut_host'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  
+	cat > conftest.$ac_ext <<EOF
+#line 10510 "configure"
+#include "confdefs.h"
+
+#include <sys/types.h>
+#include <${cf_cv_have_utmp}.h>
+int main() {
+struct $cf_cv_have_utmp x; char *y = &x.ut_host[0]
+; return 0; }
+EOF
+if { (eval echo configure:10519: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  cf_cv_have_utmp_ut_host=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  cf_cv_have_utmp_ut_host=no
+fi
+rm -f conftest*
+	
+fi
+
+echo "$ac_t""$cf_cv_have_utmp_ut_host" 1>&6
+test $cf_cv_have_utmp_ut_host != no && cat >> confdefs.h <<\EOF
+#define HAVE_UTMP_UT_HOST 1
+EOF
+
+fi
+
+	
+
+if test $cf_cv_have_utmp != no ; then
+echo $ac_n "checking for exit-status in $cf_cv_have_utmp""... $ac_c" 1>&6
+echo "configure:10543: checking for exit-status in $cf_cv_have_utmp" >&5
+if eval "test \"`echo '$''{'cf_cv_have_utmp_ut_xstatus'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  
+for cf_result in \
+	ut_exit.__e_exit \
+	ut_exit.e_exit \
+	ut_exit.ut_e_exit \
+	ut_exit.ut_exit
+do
+cat > conftest.$ac_ext <<EOF
+#line 10555 "configure"
+#include "confdefs.h"
+
+#include <sys/types.h>
+#include <${cf_cv_have_utmp}.h>
+int main() {
+struct $cf_cv_have_utmp x; long y = x.$cf_result = 0
+; return 0; }
+EOF
+if { (eval echo configure:10564: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  cf_cv_have_utmp_ut_xstatus=$cf_result
+	 break
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  cf_cv_have_utmp_ut_xstatus=no
+fi
+rm -f conftest*
+done
+
+fi
+
+echo "$ac_t""$cf_cv_have_utmp_ut_xstatus" 1>&6
+if test $cf_cv_have_utmp_ut_xstatus != no ; then
+	cat >> confdefs.h <<\EOF
+#define HAVE_UTMP_UT_XSTATUS 1
+EOF
+
+	cat >> confdefs.h <<EOF
+#define ut_xstatus $cf_cv_have_utmp_ut_xstatus
+EOF
+
+fi
+fi
+
+	
+
+if test $cf_cv_have_utmp != no ; then
+echo $ac_n "checking if utmp.ut_xtime is declared""... $ac_c" 1>&6
+echo "configure:10596: checking if utmp.ut_xtime is declared" >&5
+if eval "test \"`echo '$''{'cf_cv_have_utmp_ut_xtime'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  
+	cat > conftest.$ac_ext <<EOF
+#line 10602 "configure"
+#include "confdefs.h"
+
+#include <sys/types.h>
+#include <${cf_cv_have_utmp}.h>
+int main() {
+struct $cf_cv_have_utmp x; long y = x.ut_xtime = 0
+; return 0; }
+EOF
+if { (eval echo configure:10611: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  cf_cv_have_utmp_ut_xtime=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  cat > conftest.$ac_ext <<EOF
+#line 10619 "configure"
+#include "confdefs.h"
+
+#include <sys/types.h>
+#include <${cf_cv_have_utmp}.h>
+int main() {
+struct $cf_cv_have_utmp x; long y = x.ut_tv.tv_sec
+; return 0; }
+EOF
+if { (eval echo configure:10628: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  cf_cv_have_utmp_ut_xtime=define
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  cf_cv_have_utmp_ut_xtime=no
+fi
+rm -f conftest*
+	
+fi
+rm -f conftest*
+
+fi
+
+echo "$ac_t""$cf_cv_have_utmp_ut_xtime" 1>&6
+if test $cf_cv_have_utmp_ut_xtime != no ; then
+	cat >> confdefs.h <<\EOF
+#define HAVE_UTMP_UT_XTIME 1
+EOF
+
+	if test $cf_cv_have_utmp_ut_xtime = define ; then
+		cat >> confdefs.h <<\EOF
+#define ut_xtime ut_tv.tv_sec
+EOF
+
+	fi
+fi
+fi
+
+	
+
+if test $cf_cv_have_utmp != no ; then
+echo $ac_n "checking if utmp.ut_session is declared""... $ac_c" 1>&6
+echo "configure:10663: checking if utmp.ut_session is declared" >&5
+if eval "test \"`echo '$''{'cf_cv_have_utmp_ut_session'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  
+	cat > conftest.$ac_ext <<EOF
+#line 10669 "configure"
+#include "confdefs.h"
+
+#include <sys/types.h>
+#include <${cf_cv_have_utmp}.h>
+int main() {
+struct $cf_cv_have_utmp x; long y = x.ut_session
+; return 0; }
+EOF
+if { (eval echo configure:10678: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+  rm -rf conftest*
+  cf_cv_have_utmp_ut_session=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  cf_cv_have_utmp_ut_session=no
+fi
+rm -f conftest*
+
+fi
+
+echo "$ac_t""$cf_cv_have_utmp_ut_session" 1>&6
+if test $cf_cv_have_utmp_ut_session != no ; then
+	cat >> confdefs.h <<\EOF
+#define HAVE_UTMP_UT_SESSION 1
+EOF
+
+fi
+fi
+
+	
+
+echo $ac_n "checking if $cf_cv_have_utmp is SYSV flavor""... $ac_c" 1>&6
+echo "configure:10703: checking if $cf_cv_have_utmp is SYSV flavor" >&5
+if eval "test \"`echo '$''{'cf_cv_sysv_utmp'+set}'`\" = set"; then
+  echo $ac_n "(cached) $ac_c" 1>&6
+else
+  
+test "$cf_cv_have_utmp" = "utmp" && cf_prefix="ut" || cf_prefix="utx"
+cat > conftest.$ac_ext <<EOF
+#line 10710 "configure"
+#include "confdefs.h"
+
+#include <sys/types.h>
+#include <${cf_cv_have_utmp}.h>
+int main() {
+
+struct $cf_cv_have_utmp x;
+	set${cf_prefix}ent ();
+	get${cf_prefix}id(&x);
+	put${cf_prefix}line(&x);
+	end${cf_prefix}ent();
+; return 0; }
+EOF
+if { (eval echo configure:10724: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+  rm -rf conftest*
+  cf_cv_sysv_utmp=yes
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+  rm -rf conftest*
+  cf_cv_sysv_utmp=no
+fi
+rm -f conftest*
+
+fi
+
+echo "$ac_t""$cf_cv_sysv_utmp" 1>&6
+test $cf_cv_sysv_utmp = yes && cat >> confdefs.h <<\EOF
+#define USE_SYSV_UTMP 1
+EOF
+
+
+fi
 
 
 echo $ac_n "checking if external h_errno exists""... $ac_c" 1>&6
-echo "configure:10322: checking if external h_errno exists" >&5
+echo "configure:10747: checking if external h_errno exists" >&5
 if eval "test \"`echo '$''{'cf_cv_have_h_errno'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
     cat > conftest.$ac_ext <<EOF
-#line 10328 "configure"
+#line 10753 "configure"
 #include "confdefs.h"
 
 #undef h_errno
@@ -10334,7 +10759,7 @@ int main() {
 h_errno = 2
 ; return 0; }
 EOF
-if { (eval echo configure:10338: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:10763: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval 'cf_cv_have_'h_errno'=yes'
 else
@@ -10365,13 +10790,13 @@ fi
 
 
 echo $ac_n "checking if character set is EBCDIC""... $ac_c" 1>&6
-echo "configure:10369: checking if character set is EBCDIC" >&5
+echo "configure:10794: checking if character set is EBCDIC" >&5
 if eval "test \"`echo '$''{'cf_cv_ebcdic'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 	cat > conftest.$ac_ext <<EOF
-#line 10375 "configure"
+#line 10800 "configure"
 #include "confdefs.h"
  
 int main() {
@@ -10384,7 +10809,7 @@ make an error "Character set is not EBCDIC"
 #endif 
 ; return 0; }
 EOF
-if { (eval echo configure:10388: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:10813: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
    # TryCompile action if true
 cf_cv_ebcdic=yes 
@@ -10418,7 +10843,7 @@ esac
 if test $cf_cv_screen != slang ; then
 	
 echo $ac_n "checking if curses supports alternate-character set""... $ac_c" 1>&6
-echo "configure:10422: checking if curses supports alternate-character set" >&5
+echo "configure:10847: checking if curses supports alternate-character set" >&5
 if eval "test \"`echo '$''{'cf_cv_alt_char_set'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -10426,7 +10851,7 @@ else
 for mapname in acs_map _acs_map
 do
 	cat > conftest.$ac_ext <<EOF
-#line 10430 "configure"
+#line 10855 "configure"
 #include "confdefs.h"
 
 #include <${cf_cv_ncurses_header-curses.h}>
@@ -10435,7 +10860,7 @@ int main() {
 chtype x = $mapname['l']; $mapname['m'] = 0
 ; return 0; }
 EOF
-if { (eval echo configure:10439: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:10864: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_alt_char_set=$mapname
 	 break
@@ -10458,13 +10883,13 @@ EOF
 
 	
 echo $ac_n "checking if curses supports fancy attributes""... $ac_c" 1>&6
-echo "configure:10462: checking if curses supports fancy attributes" >&5
+echo "configure:10887: checking if curses supports fancy attributes" >&5
 if eval "test \"`echo '$''{'cf_cv_fancy_curses'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 	cat > conftest.$ac_ext <<EOF
-#line 10468 "configure"
+#line 10893 "configure"
 #include "confdefs.h"
 
 #include <${cf_cv_ncurses_header-curses.h}>
@@ -10477,7 +10902,7 @@ attrset(A_UNDERLINE|A_BOLD|A_REVERSE);
 	
 ; return 0; }
 EOF
-if { (eval echo configure:10481: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:10906: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_fancy_curses=yes
 else
@@ -10497,7 +10922,7 @@ EOF
 
 
 	echo $ac_n "checking for ncurses version""... $ac_c" 1>&6
-echo "configure:10501: checking for ncurses version" >&5
+echo "configure:10926: checking for ncurses version" >&5
 if eval "test \"`echo '$''{'cf_cv_ncurses_version'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -10522,7 +10947,7 @@ Autoconf "old"
 #endif
 EOF
 	cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
-	{ (eval echo configure:10526: \"$cf_try\") 1>&5; (eval $cf_try) 2>&5; }
+	{ (eval echo configure:10951: \"$cf_try\") 1>&5; (eval $cf_try) 2>&5; }
 	if test -f conftest.out ; then
 		cf_out=`cat conftest.out | sed -e 's@^Autoconf @@' -e 's@^[^"]*"@@' -e 's@".*@@'`
 		test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
@@ -10531,7 +10956,7 @@ EOF
 
 else
   cat > conftest.$ac_ext <<EOF
-#line 10535 "configure"
+#line 10960 "configure"
 #include "confdefs.h"
 
 #include <${cf_cv_ncurses_header-curses.h}>
@@ -10554,7 +10979,7 @@ int main()
 	exit(0);
 }
 EOF
-if { (eval echo configure:10558: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:10983: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
 then
   
 	cf_cv_ncurses_version=`cat $cf_tempfile`
@@ -10574,13 +10999,13 @@ echo "$ac_t""$cf_cv_ncurses_version" 1>&6
 
 if test "$cf_cv_ncurses_version" != no ; then
 echo $ac_n "checking for obsolete/broken version of ncurses""... $ac_c" 1>&6
-echo "configure:10578: checking for obsolete/broken version of ncurses" >&5
+echo "configure:11003: checking for obsolete/broken version of ncurses" >&5
 if eval "test \"`echo '$''{'cf_cv_ncurses_broken'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 10584 "configure"
+#line 11009 "configure"
 #include "confdefs.h"
 
 #include <${cf_cv_ncurses_header-curses.h}>
@@ -10594,7 +11019,7 @@ int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:10598: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:11023: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_ncurses_broken=no
 else
@@ -10619,13 +11044,13 @@ fi
 
 	
 echo $ac_n "checking if curses supports color attributes""... $ac_c" 1>&6
-echo "configure:10623: checking if curses supports color attributes" >&5
+echo "configure:11048: checking if curses supports color attributes" >&5
 if eval "test \"`echo '$''{'cf_cv_color_curses'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 	cat > conftest.$ac_ext <<EOF
-#line 10629 "configure"
+#line 11054 "configure"
 #include "confdefs.h"
 
 #include <${cf_cv_ncurses_header-curses.h}>
@@ -10640,7 +11065,7 @@ chtype x = COLOR_BLUE;
 	
 ; return 0; }
 EOF
-if { (eval echo configure:10644: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:11069: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_color_curses=yes
 else
@@ -10667,7 +11092,7 @@ fi
 
 	
 echo $ac_n "checking declaration of size-change""... $ac_c" 1>&6
-echo "configure:10671: checking declaration of size-change" >&5
+echo "configure:11096: checking declaration of size-change" >&5
 if eval "test \"`echo '$''{'cf_cv_sizechange'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -10681,7 +11106,7 @@ do
     CFLAGS="$cf_save_CFLAGS"
     test -n "$cf_opts" && CFLAGS="$CFLAGS -D$cf_opts"
     cat > conftest.$ac_ext <<EOF
-#line 10685 "configure"
+#line 11110 "configure"
 #include "confdefs.h"
 #include <sys/types.h>
 #if HAVE_TERMIOS_H
@@ -10720,7 +11145,7 @@ int main() {
 	
 ; return 0; }
 EOF
-if { (eval echo configure:10724: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:11149: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_sizechange=yes
 else
@@ -10752,20 +11177,20 @@ EOF
 
 	
 echo $ac_n "checking if ttytype is declared in curses library""... $ac_c" 1>&6
-echo "configure:10756: checking if ttytype is declared in curses library" >&5
+echo "configure:11181: checking if ttytype is declared in curses library" >&5
 if eval "test \"`echo '$''{'cf_cv_have_ttytype'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 	cat > conftest.$ac_ext <<EOF
-#line 10762 "configure"
+#line 11187 "configure"
 #include "confdefs.h"
 #include <${cf_cv_ncurses_header-curses.h}>
 int main() {
 char *x = &ttytype[1]; *x = 1
 ; return 0; }
 EOF
-if { (eval echo configure:10769: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:11194: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_have_ttytype=yes
 else
@@ -10786,23 +11211,23 @@ EOF
 
 	
 echo $ac_n "checking if we must define _XOPEN_SOURCE_EXTENDED""... $ac_c" 1>&6
-echo "configure:10790: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5
+echo "configure:11215: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5
 if eval "test \"`echo '$''{'cf_cv_need_xopen_extension'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 cat > conftest.$ac_ext <<EOF
-#line 10796 "configure"
+#line 11221 "configure"
 #include "confdefs.h"
 
 #include <stdlib.h>
-#include <curses.h>
+#include <${cf_cv_ncurses_header-curses.h}>
 int main() {
 
 	long x = winnstr(stdscr, "", 0)
 ; return 0; }
 EOF
-if { (eval echo configure:10806: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:11231: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_need_xopen_extension=no
 else
@@ -10810,18 +11235,18 @@ else
   cat conftest.$ac_ext >&5
   rm -rf conftest*
   cat > conftest.$ac_ext <<EOF
-#line 10814 "configure"
+#line 11239 "configure"
 #include "confdefs.h"
 
 #define _XOPEN_SOURCE_EXTENDED
 #include <stdlib.h>
-#include <curses.h>
+#include <${cf_cv_ncurses_header-curses.h}>
 int main() {
 
 	long x = winnstr(stdscr, "", 0)
 ; return 0; }
 EOF
-if { (eval echo configure:10825: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:11250: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_need_xopen_extension=yes
 else
@@ -10857,9 +11282,9 @@ do
 cf_tr_func=`echo $cf_func | tr '[a-z]' '[A-Z]'`
 
 	echo $ac_n "checking for ${cf_func}""... $ac_c" 1>&6
-echo "configure:10861: checking for ${cf_func}" >&5
+echo "configure:11286: checking for ${cf_func}" >&5
 	
-echo "(line 10863) testing ${cf_func} ..." 1>&5
+echo "(line 11288) testing ${cf_func} ..." 1>&5
 
 	if eval "test \"`echo '$''{'cf_cv_func_$cf_func'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -10868,14 +11293,14 @@ else
 		eval cf_result='$ac_cv_func_'$cf_func
 		if test ".$cf_result" != ".no"; then
 			cat > conftest.$ac_ext <<EOF
-#line 10872 "configure"
+#line 11297 "configure"
 #include "confdefs.h"
 
 #ifdef HAVE_XCURSES
 #include <xcurses.h>
 char * XCursesProgramName = "test";
 #else
-#include <curses.h>
+#include <${cf_cv_ncurses_header-curses.h}>
 #ifdef HAVE_TERM_H
 #include <term.h>
 #endif
@@ -10888,7 +11313,7 @@ long foo = (long)(&${cf_func});
 			
 ; return 0; }
 EOF
-if { (eval echo configure:10892: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:11317: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_result=yes
 else
@@ -10920,7 +11345,7 @@ fi
 
 
 echo $ac_n "checking if configuration info should be browsable""... $ac_c" 1>&6
-echo "configure:10924: checking if configuration info should be browsable" >&5
+echo "configure:11349: checking if configuration info should be browsable" >&5
 
 # Check whether --enable-config-info or --disable-config-info was given.
 if test "${enable_config_info+set}" = set; then
@@ -10944,7 +11369,7 @@ EOF
 
 
 echo $ac_n "checking if new-style forms-based options screen should be used""... $ac_c" 1>&6
-echo "configure:10948: checking if new-style forms-based options screen should be used" >&5
+echo "configure:11373: checking if new-style forms-based options screen should be used" >&5
 
 # Check whether --enable-forms-options or --disable-forms-options was given.
 if test "${enable_forms_options+set}" = set; then
@@ -10968,7 +11393,7 @@ EOF
 
 
 echo $ac_n "checking if old-style options menu should be used""... $ac_c" 1>&6
-echo "configure:10972: checking if old-style options menu should be used" >&5
+echo "configure:11397: checking if old-style options menu should be used" >&5
 
 # Check whether --enable-menu-options or --disable-menu-options was given.
 if test "${enable_menu_options+set}" = set; then
@@ -10992,7 +11417,7 @@ EOF
 
 
 echo $ac_n "checking if experimental address-list page should be used""... $ac_c" 1>&6
-echo "configure:10996: checking if experimental address-list page should be used" >&5
+echo "configure:11421: checking if experimental address-list page should be used" >&5
 
 # Check whether --enable-addrlist-page or --disable-addrlist-page was given.
 if test "${enable_addrlist_page+set}" = set; then
@@ -11016,7 +11441,7 @@ EOF
 
 
 echo $ac_n "checking if experimental charset-selection logic should be used""... $ac_c" 1>&6
-echo "configure:11020: checking if experimental charset-selection logic should be used" >&5
+echo "configure:11445: checking if experimental charset-selection logic should be used" >&5
 
 # Check whether --enable-charset-choice or --disable-charset-choice was given.
 if test "${enable_charset_choice+set}" = set; then
@@ -11040,7 +11465,7 @@ EOF
 
 
 echo $ac_n "checking if experimental CJK logic should be used""... $ac_c" 1>&6
-echo "configure:11044: checking if experimental CJK logic should be used" >&5
+echo "configure:11469: checking if experimental CJK logic should be used" >&5
 
 # Check whether --enable-cjk or --disable-cjk was given.
 if test "${enable_cjk+set}" = set; then
@@ -11064,7 +11489,7 @@ EOF
 
 
 echo $ac_n "checking if color-style code should be used""... $ac_c" 1>&6
-echo "configure:11068: checking if color-style code should be used" >&5
+echo "configure:11493: checking if color-style code should be used" >&5
 
 # Check whether --enable-color-style or --disable-color-style was given.
 if test "${enable_color_style+set}" = set; then
@@ -11112,7 +11537,7 @@ EOF
 	echo "$ac_t""yes" 1>&6
 
 	echo $ac_n "checking for location of style-sheet file""... $ac_c" 1>&6
-echo "configure:11116: checking for location of style-sheet file" >&5
+echo "configure:11541: checking for location of style-sheet file" >&5
 	LYNX_LSS_FILE=$cf_libdir/lynx.lss
 	cat >> confdefs.h <<EOF
 #define LYNX_LSS_FILE "$LYNX_LSS_FILE"
@@ -11130,7 +11555,7 @@ test ".$cf_cv_func_use_default_colors" = ".yes" && use_dft_colors=maybe
 
 if test "$use_dft_colors" != no ; then
 echo $ac_n "checking if you want to use default-colors""... $ac_c" 1>&6
-echo "configure:11134: checking if you want to use default-colors" >&5
+echo "configure:11559: checking if you want to use default-colors" >&5
 
 # Check whether --enable-default-colors or --disable-default-colors was given.
 if test "${enable_default_colors+set}" = set; then
@@ -11155,7 +11580,7 @@ EOF
 fi
 
 echo $ac_n "checking if experimental file-upload logic should be used""... $ac_c" 1>&6
-echo "configure:11159: checking if experimental file-upload logic should be used" >&5
+echo "configure:11584: checking if experimental file-upload logic should be used" >&5
 
 # Check whether --enable-file-upload or --disable-file-upload was given.
 if test "${enable_file_upload+set}" = set; then
@@ -11179,7 +11604,7 @@ EOF
 
 
 echo $ac_n "checking if experimental htmlized lynx.cfg should be built""... $ac_c" 1>&6
-echo "configure:11183: checking if experimental htmlized lynx.cfg should be built" >&5
+echo "configure:11608: checking if experimental htmlized lynx.cfg should be built" >&5
 
 # Check whether --enable-htmlized-cfg or --disable-htmlized-cfg was given.
 if test "${enable_htmlized_cfg+set}" = set; then
@@ -11208,7 +11633,7 @@ fi
 
 
 echo $ac_n "checking if experimental element-justification logic should be used""... $ac_c" 1>&6
-echo "configure:11212: checking if experimental element-justification logic should be used" >&5
+echo "configure:11637: checking if experimental element-justification logic should be used" >&5
 
 # Check whether --enable-justify-elts or --disable-justify-elts was given.
 if test "${enable_justify_elts+set}" = set; then
@@ -11232,7 +11657,7 @@ EOF
 
 
 echo $ac_n "checking if experimental keyboard-layout logic should be used""... $ac_c" 1>&6
-echo "configure:11236: checking if experimental keyboard-layout logic should be used" >&5
+echo "configure:11661: checking if experimental keyboard-layout logic should be used" >&5
 
 # Check whether --enable-kbd-layout or --disable-kbd-layout was given.
 if test "${enable_kbd_layout+set}" = set; then
@@ -11256,7 +11681,7 @@ EOF
 
 
 echo $ac_n "checking if experimental JavaScript support should be used""... $ac_c" 1>&6
-echo "configure:11260: checking if experimental JavaScript support should be used" >&5
+echo "configure:11685: checking if experimental JavaScript support should be used" >&5
 
 # Check whether --enable-libjs or --disable-libjs was given.
 if test "${enable_libjs+set}" = set; then
@@ -11280,7 +11705,7 @@ EOF
 
 
 echo $ac_n "checking if html source should be colorized""... $ac_c" 1>&6
-echo "configure:11284: checking if html source should be colorized" >&5
+echo "configure:11709: checking if html source should be colorized" >&5
 
 # Check whether --enable-prettysrc or --disable-prettysrc was given.
 if test "${enable_prettysrc+set}" = set; then
@@ -11304,7 +11729,7 @@ EOF
 
 
 echo $ac_n "checking if read-progress message should show ETA""... $ac_c" 1>&6
-echo "configure:11308: checking if read-progress message should show ETA" >&5
+echo "configure:11733: checking if read-progress message should show ETA" >&5
 
 # Check whether --enable-read-eta or --disable-read-eta was given.
 if test "${enable_read_eta+set}" = set; then
@@ -11328,7 +11753,7 @@ EOF
 
 
 echo $ac_n "checking if scrollbar code should be used""... $ac_c" 1>&6
-echo "configure:11332: checking if scrollbar code should be used" >&5
+echo "configure:11757: checking if scrollbar code should be used" >&5
 
 # Check whether --enable-scrollbar or --disable-scrollbar was given.
 if test "${enable_scrollbar+set}" = set; then
@@ -11359,7 +11784,7 @@ EOF
 fi
 
 echo $ac_n "checking if source caching should be used""... $ac_c" 1>&6
-echo "configure:11363: checking if source caching should be used" >&5
+echo "configure:11788: checking if source caching should be used" >&5
 
 # Check whether --enable-source-cache or --disable-source-cache was given.
 if test "${enable_source_cache+set}" = set; then
@@ -11386,7 +11811,7 @@ EOF
 
 
 echo $ac_n "checking if alternative line-edit bindings should be used""... $ac_c" 1>&6
-echo "configure:11390: checking if alternative line-edit bindings should be used" >&5
+echo "configure:11815: checking if alternative line-edit bindings should be used" >&5
 
 # Check whether --enable-alt-bindings or --disable-alt-bindings was given.
 if test "${enable_alt_bindings+set}" = set; then
@@ -11410,7 +11835,7 @@ EOF
 
 
 echo $ac_n "checking if you want to use extended HTML DTD logic""... $ac_c" 1>&6
-echo "configure:11414: checking if you want to use extended HTML DTD logic" >&5
+echo "configure:11839: checking if you want to use extended HTML DTD logic" >&5
 
 # Check whether --enable-extended-dtd or --disable-extended-dtd was given.
 if test "${enable_extended_dtd+set}" = set; then
@@ -11434,7 +11859,7 @@ EOF
 
 
 echo $ac_n "checking if partial-display should be used""... $ac_c" 1>&6
-echo "configure:11438: checking if partial-display should be used" >&5
+echo "configure:11863: checking if partial-display should be used" >&5
 
 # Check whether --enable-partial or --disable-partial was given.
 if test "${enable_partial+set}" = set; then
@@ -11458,7 +11883,7 @@ EOF
 
 
 echo $ac_n "checking if you want to use external commands""... $ac_c" 1>&6
-echo "configure:11462: checking if you want to use external commands" >&5
+echo "configure:11887: checking if you want to use external commands" >&5
 
 # Check whether --enable-externs or --disable-externs was given.
 if test "${enable_externs+set}" = set; then
@@ -11482,7 +11907,7 @@ EOF
 
 
 echo $ac_n "checking if you want to use setfont support""... $ac_c" 1>&6
-echo "configure:11486: checking if you want to use setfont support" >&5
+echo "configure:11911: checking if you want to use setfont support" >&5
 
 # Check whether --enable-font-switch or --disable-font-switch was given.
 if test "${enable_font_switch+set}" = set; then
@@ -11506,7 +11931,7 @@ EOF
 
 
 echo $ac_n "checking if you want cgi-link support""... $ac_c" 1>&6
-echo "configure:11510: checking if you want cgi-link support" >&5
+echo "configure:11935: checking if you want cgi-link support" >&5
 
 # Check whether --enable-cgi-links or --disable-cgi-links was given.
 if test "${enable_cgi_links+set}" = set; then
@@ -11525,7 +11950,7 @@ fi
 echo "$ac_t""$enableval" 1>&6
 
 echo $ac_n "checking if you want change-exec support""... $ac_c" 1>&6
-echo "configure:11529: checking if you want change-exec support" >&5
+echo "configure:11954: checking if you want change-exec support" >&5
 
 # Check whether --enable-change-exec or --disable-change-exec was given.
 if test "${enable_change_exec+set}" = set; then
@@ -11549,7 +11974,7 @@ EOF
 
 
 echo $ac_n "checking if you want exec-links support""... $ac_c" 1>&6
-echo "configure:11553: checking if you want exec-links support" >&5
+echo "configure:11978: checking if you want exec-links support" >&5
 
 # Check whether --enable-exec-links or --disable-exec-links was given.
 if test "${enable_exec_links+set}" = set; then
@@ -11573,7 +11998,7 @@ EOF
 
 
 echo $ac_n "checking if you want exec-scripts support""... $ac_c" 1>&6
-echo "configure:11577: checking if you want exec-scripts support" >&5
+echo "configure:12002: checking if you want exec-scripts support" >&5
 
 # Check whether --enable-exec-scripts or --disable-exec-scripts was given.
 if test "${enable_exec_scripts+set}" = set; then
@@ -11597,7 +12022,7 @@ EOF
 
 
 echo $ac_n "checking if you want internal-links feature""... $ac_c" 1>&6
-echo "configure:11601: checking if you want internal-links feature" >&5
+echo "configure:12026: checking if you want internal-links feature" >&5
 
 # Check whether --enable-internal-links or --disable-internal-links was given.
 if test "${enable_internal_links+set}" = set; then
@@ -11621,7 +12046,7 @@ EOF
 
 
 echo $ac_n "checking if you want to fork NSL requests""... $ac_c" 1>&6
-echo "configure:11625: checking if you want to fork NSL requests" >&5
+echo "configure:12050: checking if you want to fork NSL requests" >&5
 
 # Check whether --enable-nsl-fork or --disable-nsl-fork was given.
 if test "${enable_nsl_fork+set}" = set; then
@@ -11645,7 +12070,7 @@ EOF
 
 
 echo $ac_n "checking if you want to log URL requests via syslog""... $ac_c" 1>&6
-echo "configure:11649: checking if you want to log URL requests via syslog" >&5
+echo "configure:12074: checking if you want to log URL requests via syslog" >&5
 
 # Check whether --enable-syslog or --disable-syslog was given.
 if test "${enable_syslog+set}" = set; then
@@ -11669,7 +12094,7 @@ EOF
 
 
 echo $ac_n "checking if persistent-cookie logic should be used""... $ac_c" 1>&6
-echo "configure:11673: checking if persistent-cookie logic should be used" >&5
+echo "configure:12098: checking if persistent-cookie logic should be used" >&5
 
 # Check whether --enable-persistent-cookies or --disable-persistent-cookies was given.
 if test "${enable_persistent_cookies+set}" = set; then
@@ -11693,7 +12118,7 @@ EOF
 
 
 echo $ac_n "checking if you want to underline links""... $ac_c" 1>&6
-echo "configure:11697: checking if you want to underline links" >&5
+echo "configure:12122: checking if you want to underline links" >&5
 
 # Check whether --enable-underlines or --disable-underlines was given.
 if test "${enable_underlines+set}" = set; then
@@ -11717,7 +12142,7 @@ EOF
 
 
 echo $ac_n "checking if help files should be gzip'ed""... $ac_c" 1>&6
-echo "configure:11721: checking if help files should be gzip'ed" >&5
+echo "configure:12146: checking if help files should be gzip'ed" >&5
 
 # Check whether --enable-gzip-help or --disable-gzip-help was given.
 if test "${enable_gzip_help+set}" = set; then
@@ -11746,7 +12171,7 @@ fi
 
 
 echo $ac_n "checking if you want to use zlib for decompression of some gzip files""... $ac_c" 1>&6
-echo "configure:11750: checking if you want to use zlib for decompression of some gzip files" >&5
+echo "configure:12175: checking if you want to use zlib for decompression of some gzip files" >&5
 
 # Check whether --with-zlib or --without-zlib was given.
 if test "${with_zlib+set}" = set; then
@@ -11760,16 +12185,16 @@ echo "$ac_t""$use_zlib" 1>&6
 
 if test ".$use_zlib" != ".no" ; then
 	echo $ac_n "checking if we need to add -I option to get zlib.h""... $ac_c" 1>&6
-echo "configure:11764: checking if we need to add -I option to get zlib.h" >&5
+echo "configure:12189: checking if we need to add -I option to get zlib.h" >&5
 	cat > conftest.$ac_ext <<EOF
-#line 11766 "configure"
+#line 12191 "configure"
 #include "confdefs.h"
 #include <zlib.h>
 int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:11773: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:12198: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   echo "$ac_t""no" 1>&6
 else
@@ -11779,18 +12204,31 @@ else
   
 	echo "$ac_t""yes" 1>&6
 	cf_search=""
-if test -d "$includedir"  ; then
-test "$includedir" != NONE       && cf_search="$cf_search $includedir $includedir/zlib"
-fi
-if test -d "$oldincludedir"  ; then
-test "$oldincludedir" != NONE    && cf_search="$cf_search $oldincludedir $oldincludedir/zlib"
-fi
-if test -d "$prefix"; then
-test "$prefix" != NONE           && cf_search="$cf_search $prefix/include $prefix/include/zlib"
-fi
-test "$prefix" != /usr/local     && cf_search="$cf_search /usr/local/include /usr/local/include/zlib"
-test "$prefix" != /usr           && cf_search="$cf_search /usr/include /usr/include/zlib"
-test "$prefix" != /opt           && cf_search="$cf_search /opt/include /opt/include/zlib"
+
+test "$includedir" != NONE && \
+test -d "$includedir" && \
+cf_search="$cf_search $includedir $includedir/zlib"
+
+test "$oldincludedir" != NONE && \
+test -d "$oldincludedir" && \
+cf_search="$cf_search $oldincludedir $oldincludedir/zlib"
+
+test "$prefix" != NONE && \
+test -d "$prefix" && \
+cf_search="$cf_search $prefix/include $prefix/include/zlib $prefix/zlib/include"
+
+test "$prefix" != /usr/local && \
+test -d /usr/local && \
+cf_search="$cf_search /usr/local/include /usr/local/include/zlib /usr/local/zlib/include"
+
+test "$prefix" != /usr && \
+cf_search="$cf_search /usr/include /usr/include/zlib /usr/zlib/include"
+
+test "$prefix" != /opt && \
+test -d /opt && \
+cf_search="$cf_search /opt/include /opt/include/zlib /opt/zlib/include"
+
+cf_search="$cf_search $HOME/lib $HOME/lib/zlib $HOME/zlib/lib"
 
 	for cf_incdir in $cf_search
 	do
@@ -11807,15 +12245,15 @@ test "$prefix" != /opt           && cf_search="$cf_search /opt/include /opt/incl
 fi
 rm -f conftest*
 	
-	cf_cv_have_lib_z=no
+	eval 'cf_cv_have_lib_'z'=no'
 	cf_libdir=""
 	echo $ac_n "checking for gzopen""... $ac_c" 1>&6
-echo "configure:11814: checking for gzopen" >&5
+echo "configure:12252: checking for gzopen" >&5
 if eval "test \"`echo '$''{'ac_cv_func_gzopen'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 11819 "configure"
+#line 12257 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char gzopen(); below.  */
@@ -11838,7 +12276,7 @@ gzopen();
 
 ; return 0; }
 EOF
-if { (eval echo configure:11842: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:12280: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_gzopen=yes"
 else
@@ -11852,26 +12290,26 @@ fi
 
 if eval "test \"`echo '$ac_cv_func_'gzopen`\" = yes"; then
   echo "$ac_t""yes" 1>&6
-  cf_cv_have_lib_z=yes
+  eval 'cf_cv_have_lib_'z'=yes'
 else
   echo "$ac_t""no" 1>&6
 
 		cf_save_LIBS="$LIBS"
 		echo $ac_n "checking for gzopen in -lz""... $ac_c" 1>&6
-echo "configure:11862: checking for gzopen in -lz" >&5
+echo "configure:12300: checking for gzopen in -lz" >&5
 		LIBS="-lz $LIBS"
 		cat > conftest.$ac_ext <<EOF
-#line 11865 "configure"
+#line 12303 "configure"
 #include "confdefs.h"
 #include <zlib.h>
 int main() {
 gzopen("name","mode")
 ; return 0; }
 EOF
-if { (eval echo configure:11872: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:12310: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   echo "$ac_t""yes" 1>&6
-			 cf_cv_have_lib_z=yes
+			 eval 'cf_cv_have_lib_'z'=yes'
 			
 else
   echo "configure: failed program was:" >&5
@@ -11879,37 +12317,53 @@ else
   rm -rf conftest*
   echo "$ac_t""no" 1>&6
 			cf_search=""
-if test -d "$libdir"  ; then
-test "$libdir" != NONE           && cf_search="$cf_search $libdir $libdir/z"
-fi
-if test -d "$exec_prefix"; then
-test "$exec_prefix" != NONE      && cf_search="$cf_search $exec_prefix/lib $exec_prefix/lib/z"
-fi
-if test -d "$prefix"; then
-test "$prefix" != NONE           && \
-test "$prefix" != "$exec_prefix" && cf_search="$cf_search $prefix/lib $prefix/lib/z"
-fi
-test "$prefix" != /usr/local     && cf_search="$cf_search /usr/local/lib /usr/local/lib/z"
-test "$prefix" != /usr           && cf_search="$cf_search /usr/lib /usr/lib/z"
-test "$prefix" != /opt           && cf_search="$cf_search /opt/lib /opt/lib/z"
+
+test "$libdir" != NONE && \
+test -d $libdir && \
+cf_search="$cf_search $libdir $libdir/z"
+
+test "$exec_prefix" != NONE && \
+test -d $exec_prefix && \
+cf_search="$cf_search $exec_prefix/lib $exec_prefix/lib/z"
+
+test "$prefix" != NONE && \
+test "$prefix" != "$exec_prefix" && \
+test -d $prefix && \
+cf_search="$cf_search $prefix/lib $prefix/lib/z $prefix/z/lib"
+
+test "$prefix" != /usr/local && \
+test -d /usr/local && \
+cf_search="$cf_search /usr/local/lib /usr/local/lib/z /usr/local/z/lib"
+
+test "$prefix" != /usr && \
+cf_search="$cf_search /usr/lib /usr/lib/z /usr/z/lib"
+
+test "$prefix" != / && \
+cf_search="$cf_search /lib /lib/z /z/lib"
+
+test "$prefix" != /opt && \
+test -d /opt && \
+cf_search="$cf_search /opt/lib /opt/lib/z /opt/z/lib"
+
+cf_search="$cf_search $HOME/lib $HOME/lib/z $HOME/z/lib"
 
 			for cf_libdir in $cf_search
 			do
 				echo $ac_n "checking for -lz in $cf_libdir""... $ac_c" 1>&6
-echo "configure:11900: checking for -lz in $cf_libdir" >&5
+echo "configure:12354: checking for -lz in $cf_libdir" >&5
 				LIBS="-L$cf_libdir -lz $cf_save_LIBS"
 				cat > conftest.$ac_ext <<EOF
-#line 11903 "configure"
+#line 12357 "configure"
 #include "confdefs.h"
 #include <zlib.h>
 int main() {
 gzopen("name","mode")
 ; return 0; }
 EOF
-if { (eval echo configure:11910: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:12364: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   echo "$ac_t""yes" 1>&6
-			 		 cf_cv_have_lib_z=yes
+			 		 eval 'cf_cv_have_lib_'z'=yes'
 					 break
 else
   echo "configure: failed program was:" >&5
@@ -11926,14 +12380,12 @@ rm -f conftest*
 		
 fi
 
-if test $cf_cv_have_lib_z = no ; then
+eval 'cf_found_library=$cf_cv_have_lib_'z
+
+if test $cf_found_library = no ; then
 	{ echo "configure: error: Cannot link z library" 1>&2; exit 1; }
 fi
-case $host_os in #(vi
-linux*) # Suse Linux does not follow /usr/lib convention
-	LIBS="$LIBS -L/lib"
-	;;
-esac
+
 
 	cat >> confdefs.h <<\EOF
 #define USE_ZLIB 1
@@ -11942,7 +12394,7 @@ EOF
 fi
 
 echo $ac_n "checking if you want to exclude FINGER code""... $ac_c" 1>&6
-echo "configure:11946: checking if you want to exclude FINGER code" >&5
+echo "configure:12398: checking if you want to exclude FINGER code" >&5
 
 # Check whether --enable-finger or --disable-finger was given.
 if test "${enable_finger+set}" = set; then
@@ -11966,7 +12418,7 @@ EOF
 
 
 echo $ac_n "checking if you want to exclude GOPHER code""... $ac_c" 1>&6
-echo "configure:11970: checking if you want to exclude GOPHER code" >&5
+echo "configure:12422: checking if you want to exclude GOPHER code" >&5
 
 # Check whether --enable-gopher or --disable-gopher was given.
 if test "${enable_gopher+set}" = set; then
@@ -11990,7 +12442,7 @@ EOF
 
 
 echo $ac_n "checking if you want to exclude NEWS code""... $ac_c" 1>&6
-echo "configure:11994: checking if you want to exclude NEWS code" >&5
+echo "configure:12446: checking if you want to exclude NEWS code" >&5
 
 # Check whether --enable-news or --disable-news was given.
 if test "${enable_news+set}" = set; then
@@ -12014,7 +12466,7 @@ EOF
 
 
 echo $ac_n "checking if you want to exclude FTP code""... $ac_c" 1>&6
-echo "configure:12018: checking if you want to exclude FTP code" >&5
+echo "configure:12470: checking if you want to exclude FTP code" >&5
 
 # Check whether --enable-ftp or --disable-ftp was given.
 if test "${enable_ftp+set}" = set; then
@@ -12043,7 +12495,7 @@ EOF
 # All DirEd functions that were enabled on compilation can be disabled
 # or modified at run time via DIRED_MENU symbols in lynx.cfg.
 echo $ac_n "checking if directory-editor code should be used""... $ac_c" 1>&6
-echo "configure:12047: checking if directory-editor code should be used" >&5
+echo "configure:12499: checking if directory-editor code should be used" >&5
 
 # Check whether --enable-dired or --disable-dired was given.
 if test "${enable_dired+set}" = set; then
@@ -12069,7 +12521,7 @@ EOF
 
 
 	echo $ac_n "checking if you wish to allow extracting from archives via DirEd""... $ac_c" 1>&6
-echo "configure:12073: checking if you wish to allow extracting from archives via DirEd" >&5
+echo "configure:12525: checking if you wish to allow extracting from archives via DirEd" >&5
 	
 # Check whether --enable-dired-dearchive or --disable-dired-dearchive was given.
 if test "${enable_dired_dearchive+set}" = set; then
@@ -12088,7 +12540,7 @@ fi
 	echo "$ac_t""$enableval" 1>&6
 
 	echo $ac_n "checking if DirEd mode should override keys""... $ac_c" 1>&6
-echo "configure:12092: checking if DirEd mode should override keys" >&5
+echo "configure:12544: checking if DirEd mode should override keys" >&5
 	
 # Check whether --enable-dired-override or --disable-dired-override was given.
 if test "${enable_dired_override+set}" = set; then
@@ -12114,7 +12566,7 @@ fi
 	echo "$ac_t""$enableval" 1>&6
 
 	echo $ac_n "checking if you wish to allow permissions commands via DirEd""... $ac_c" 1>&6
-echo "configure:12118: checking if you wish to allow permissions commands via DirEd" >&5
+echo "configure:12570: checking if you wish to allow permissions commands via DirEd" >&5
 	
 # Check whether --enable-dired-permit or --disable-dired-permit was given.
 if test "${enable_dired_permit+set}" = set; then
@@ -12140,7 +12592,7 @@ fi
 	echo "$ac_t""$enableval" 1>&6
 
 	echo $ac_n "checking if you wish to allow executable-permission commands via DirEd""... $ac_c" 1>&6
-echo "configure:12144: checking if you wish to allow executable-permission commands via DirEd" >&5
+echo "configure:12596: checking if you wish to allow executable-permission commands via DirEd" >&5
 	
 # Check whether --enable-dired-xpermit or --disable-dired-xpermit was given.
 if test "${enable_dired_xpermit+set}" = set; then
@@ -12159,7 +12611,7 @@ fi
 	echo "$ac_t""$enableval" 1>&6
 
 	echo $ac_n "checking if you wish to allow "tar" commands from DirEd""... $ac_c" 1>&6
-echo "configure:12163: checking if you wish to allow "tar" commands from DirEd" >&5
+echo "configure:12615: checking if you wish to allow "tar" commands from DirEd" >&5
 	
 # Check whether --enable-dired-tar or --disable-dired-tar was given.
 if test "${enable_dired_tar+set}" = set; then
@@ -12185,7 +12637,7 @@ fi
 	echo "$ac_t""$enableval" 1>&6
 
 	echo $ac_n "checking if you wish to allow "uudecode" commands from DirEd""... $ac_c" 1>&6
-echo "configure:12189: checking if you wish to allow "uudecode" commands from DirEd" >&5
+echo "configure:12641: checking if you wish to allow "uudecode" commands from DirEd" >&5
 	
 # Check whether --enable-dired-uudecode or --disable-dired-uudecode was given.
 if test "${enable_dired_uudecode+set}" = set; then
@@ -12211,7 +12663,7 @@ fi
 	echo "$ac_t""$enableval" 1>&6
 
 	echo $ac_n "checking if you wish to allow "zip" and "unzip" commands from DirEd""... $ac_c" 1>&6
-echo "configure:12215: checking if you wish to allow "zip" and "unzip" commands from DirEd" >&5
+echo "configure:12667: checking if you wish to allow "zip" and "unzip" commands from DirEd" >&5
 	
 # Check whether --enable-dired-zip or --disable-dired-zip was given.
 if test "${enable_dired_zip+set}" = set; then
@@ -12237,7 +12689,7 @@ fi
 	echo "$ac_t""$enableval" 1>&6
 
 	echo $ac_n "checking if you wish to allow "gzip" and "gunzip" commands from DirEd""... $ac_c" 1>&6
-echo "configure:12241: checking if you wish to allow "gzip" and "gunzip" commands from DirEd" >&5
+echo "configure:12693: checking if you wish to allow "gzip" and "gunzip" commands from DirEd" >&5
 	
 # Check whether --enable-dired-gzip or --disable-dired-gzip was given.
 if test "${enable_dired_gzip+set}" = set; then
@@ -12264,7 +12716,7 @@ fi
 fi
 
 echo $ac_n "checking if you want long-directory listings""... $ac_c" 1>&6
-echo "configure:12268: checking if you want long-directory listings" >&5
+echo "configure:12720: checking if you want long-directory listings" >&5
 
 # Check whether --enable-long-list or --disable-long-list was given.
 if test "${enable_long_list+set}" = set; then
@@ -12290,7 +12742,7 @@ fi
 echo "$ac_t""$enableval" 1>&6
 
 echo $ac_n "checking if parent-directory references are permitted""... $ac_c" 1>&6
-echo "configure:12294: checking if parent-directory references are permitted" >&5
+echo "configure:12746: checking if parent-directory references are permitted" >&5
 
 # Check whether --enable-parent-dir-refs or --disable-parent-dir-refs was given.
 if test "${enable_parent_dir_refs+set}" = set; then
@@ -12315,7 +12767,7 @@ if test $cf_cv_screen = pdcurses ; then
 # 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:12319: checking for X" >&5
+echo "configure:12771: checking for X" >&5
 
 
 # Check whether --with-x or --without-x was given.
@@ -12378,12 +12830,12 @@ if test "$ac_x_includes" = NO; then
 
   # First, try using that file with no special directory specified.
 cat > conftest.$ac_ext <<EOF
-#line 12382 "configure"
+#line 12834 "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:12387: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:12839: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
 if test -z "$ac_err"; then
   rm -rf conftest*
@@ -12452,14 +12904,14 @@ if test "$ac_x_libraries" = NO; then
   ac_save_LIBS="$LIBS"
   LIBS="-l$x_direct_test_library $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 12456 "configure"
+#line 12908 "configure"
 #include "confdefs.h"
 
 int main() {
 ${x_direct_test_function}()
 ; return 0; }
 EOF
-if { (eval echo configure:12463: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:12915: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   LIBS="$ac_save_LIBS"
 # We can link X programs with no special library path.
@@ -12559,7 +13011,7 @@ clix*)
 	# FIXME: modify the library lookup in autoconf to
 	# allow _s.a suffix ahead of .a
 	echo $ac_n "checking for open in -lc_s""... $ac_c" 1>&6
-echo "configure:12563: checking for open in -lc_s" >&5
+echo "configure:13015: checking for open in -lc_s" >&5
 ac_lib_var=`echo c_s'_'open | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -12567,7 +13019,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lc_s  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 12571 "configure"
+#line 13023 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -12578,7 +13030,7 @@ int main() {
 open()
 ; return 0; }
 EOF
-if { (eval echo configure:12582: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13034: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -12595,7 +13047,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
   echo "$ac_t""yes" 1>&6
   LIBS="-lc_s $LIBS"
 	echo $ac_n "checking for gethostname in -lbsd""... $ac_c" 1>&6
-echo "configure:12599: checking for gethostname in -lbsd" >&5
+echo "configure:13051: checking for gethostname in -lbsd" >&5
 ac_lib_var=`echo bsd'_'gethostname | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -12603,7 +13055,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lbsd  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 12607 "configure"
+#line 13059 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -12614,7 +13066,7 @@ int main() {
 gethostname()
 ; return 0; }
 EOF
-if { (eval echo configure:12618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13070: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -12631,7 +13083,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
   echo "$ac_t""yes" 1>&6
   LIBS="-lbsd $LIBS"
 	echo $ac_n "checking for gethostname in -lnsl_s""... $ac_c" 1>&6
-echo "configure:12635: checking for gethostname in -lnsl_s" >&5
+echo "configure:13087: checking for gethostname in -lnsl_s" >&5
 ac_lib_var=`echo nsl_s'_'gethostname | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -12639,7 +13091,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lnsl_s  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 12643 "configure"
+#line 13095 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -12650,7 +13102,7 @@ int main() {
 gethostname()
 ; return 0; }
 EOF
-if { (eval echo configure:12654: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13106: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -12667,7 +13119,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
   echo "$ac_t""yes" 1>&6
   LIBS="-lnsl_s $LIBS"
 	echo $ac_n "checking for XOpenDisplay in -lX11_s""... $ac_c" 1>&6
-echo "configure:12671: checking for XOpenDisplay in -lX11_s" >&5
+echo "configure:13123: checking for XOpenDisplay in -lX11_s" >&5
 ac_lib_var=`echo X11_s'_'XOpenDisplay | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -12675,7 +13127,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lX11_s  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 12679 "configure"
+#line 13131 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -12686,7 +13138,7 @@ int main() {
 XOpenDisplay()
 ; return 0; }
 EOF
-if { (eval echo configure:12690: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13142: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -12703,7 +13155,7 @@ if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
   echo "$ac_t""yes" 1>&6
   LIBS="-lX11_s $LIBS"
 	echo $ac_n "checking for XtAppInitialize in -lXt_s""... $ac_c" 1>&6
-echo "configure:12707: checking for XtAppInitialize in -lXt_s" >&5
+echo "configure:13159: checking for XtAppInitialize in -lXt_s" >&5
 ac_lib_var=`echo Xt_s'_'XtAppInitialize | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -12711,7 +13163,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lXt_s  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 12715 "configure"
+#line 13167 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -12722,7 +13174,7 @@ int main() {
 XtAppInitialize()
 ; return 0; }
 EOF
-if { (eval echo configure:12726: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13178: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -12763,7 +13215,7 @@ fi
 	;;
 *)
 	echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6
-echo "configure:12767: checking for socket in -lsocket" >&5
+echo "configure:13219: checking for socket in -lsocket" >&5
 ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -12771,7 +13223,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 12775 "configure"
+#line 13227 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -12782,7 +13234,7 @@ int main() {
 socket()
 ; return 0; }
 EOF
-if { (eval echo configure:12786: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13238: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -12810,7 +13262,7 @@ else
 fi
 
 	echo $ac_n "checking for gethostname in -lnsl""... $ac_c" 1>&6
-echo "configure:12814: checking for gethostname in -lnsl" >&5
+echo "configure:13266: checking for gethostname in -lnsl" >&5
 ac_lib_var=`echo nsl'_'gethostname | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -12818,7 +13270,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lnsl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 12822 "configure"
+#line 13274 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -12829,7 +13281,7 @@ int main() {
 gethostname()
 ; return 0; }
 EOF
-if { (eval echo configure:12833: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13285: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -12880,17 +13332,17 @@ else
     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:12884: checking whether -R must be followed by a space" >&5
+echo "configure:13336: 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 12887 "configure"
+#line 13339 "configure"
 #include "confdefs.h"
 
 int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:12894: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13346: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_R_nospace=yes
 else
@@ -12906,14 +13358,14 @@ rm -f conftest*
       else
 	LIBS="$ac_xsave_LIBS -R $x_libraries"
 	cat > conftest.$ac_ext <<EOF
-#line 12910 "configure"
+#line 13362 "configure"
 #include "confdefs.h"
 
 int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:12917: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13369: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   ac_R_space=yes
 else
@@ -12945,7 +13397,7 @@ rm -f conftest*
     # libraries were built with DECnet support.  And karl@cs.umb.edu says
     # the Alpha needs dnet_stub (dnet does not exist).
     echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6
-echo "configure:12949: checking for dnet_ntoa in -ldnet" >&5
+echo "configure:13401: checking for dnet_ntoa in -ldnet" >&5
 ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -12953,7 +13405,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldnet  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 12957 "configure"
+#line 13409 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -12964,7 +13416,7 @@ int main() {
 dnet_ntoa()
 ; return 0; }
 EOF
-if { (eval echo configure:12968: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13420: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -12986,7 +13438,7 @@ fi
 
     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:12990: checking for dnet_ntoa in -ldnet_stub" >&5
+echo "configure:13442: checking for dnet_ntoa in -ldnet_stub" >&5
 ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -12994,7 +13446,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-ldnet_stub  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 12998 "configure"
+#line 13450 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13005,7 +13457,7 @@ int main() {
 dnet_ntoa()
 ; return 0; }
 EOF
-if { (eval echo configure:13009: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13461: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13034,12 +13486,12 @@ fi
     # 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:13038: checking for gethostbyname" >&5
+echo "configure:13490: checking for gethostbyname" >&5
 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 13043 "configure"
+#line 13495 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char gethostbyname(); below.  */
@@ -13062,7 +13514,7 @@ gethostbyname();
 
 ; return 0; }
 EOF
-if { (eval echo configure:13066: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13518: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_gethostbyname=yes"
 else
@@ -13083,7 +13535,7 @@ fi
 
     if test $ac_cv_func_gethostbyname = no; then
       echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
-echo "configure:13087: checking for gethostbyname in -lnsl" >&5
+echo "configure:13539: checking for gethostbyname in -lnsl" >&5
 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13091,7 +13543,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lnsl  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13095 "configure"
+#line 13547 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13102,7 +13554,7 @@ int main() {
 gethostbyname()
 ; return 0; }
 EOF
-if { (eval echo configure:13106: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13558: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13132,12 +13584,12 @@ fi
     # -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:13136: checking for connect" >&5
+echo "configure:13588: checking for connect" >&5
 if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 13141 "configure"
+#line 13593 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char connect(); below.  */
@@ -13160,7 +13612,7 @@ connect();
 
 ; return 0; }
 EOF
-if { (eval echo configure:13164: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13616: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_connect=yes"
 else
@@ -13181,7 +13633,7 @@ fi
 
     if test $ac_cv_func_connect = no; then
       echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
-echo "configure:13185: checking for connect in -lsocket" >&5
+echo "configure:13637: checking for connect in -lsocket" >&5
 ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13189,7 +13641,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13193 "configure"
+#line 13645 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13200,7 +13652,7 @@ int main() {
 connect()
 ; return 0; }
 EOF
-if { (eval echo configure:13204: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13656: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13224,12 +13676,12 @@ fi
 
     # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX.
     echo $ac_n "checking for remove""... $ac_c" 1>&6
-echo "configure:13228: checking for remove" >&5
+echo "configure:13680: checking for remove" >&5
 if eval "test \"`echo '$''{'ac_cv_func_remove'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 13233 "configure"
+#line 13685 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char remove(); below.  */
@@ -13252,7 +13704,7 @@ remove();
 
 ; return 0; }
 EOF
-if { (eval echo configure:13256: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13708: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_remove=yes"
 else
@@ -13273,7 +13725,7 @@ fi
 
     if test $ac_cv_func_remove = no; then
       echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6
-echo "configure:13277: checking for remove in -lposix" >&5
+echo "configure:13729: checking for remove in -lposix" >&5
 ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13281,7 +13733,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lposix  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13285 "configure"
+#line 13737 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13292,7 +13744,7 @@ int main() {
 remove()
 ; return 0; }
 EOF
-if { (eval echo configure:13296: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13748: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13316,12 +13768,12 @@ fi
 
     # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
     echo $ac_n "checking for shmat""... $ac_c" 1>&6
-echo "configure:13320: checking for shmat" >&5
+echo "configure:13772: checking for shmat" >&5
 if eval "test \"`echo '$''{'ac_cv_func_shmat'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   cat > conftest.$ac_ext <<EOF
-#line 13325 "configure"
+#line 13777 "configure"
 #include "confdefs.h"
 /* System header to define __stub macros and hopefully few prototypes,
     which can conflict with char shmat(); below.  */
@@ -13344,7 +13796,7 @@ shmat();
 
 ; return 0; }
 EOF
-if { (eval echo configure:13348: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13800: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_func_shmat=yes"
 else
@@ -13365,7 +13817,7 @@ fi
 
     if test $ac_cv_func_shmat = no; then
       echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6
-echo "configure:13369: checking for shmat in -lipc" >&5
+echo "configure:13821: checking for shmat in -lipc" >&5
 ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13373,7 +13825,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lipc  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13377 "configure"
+#line 13829 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13384,7 +13836,7 @@ int main() {
 shmat()
 ; return 0; }
 EOF
-if { (eval echo configure:13388: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13840: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13417,7 +13869,7 @@ fi
   # libraries we check for below, so use a different variable.
   #  --interran@uluru.Stanford.EDU, kb@cs.umb.edu.
   echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6
-echo "configure:13421: checking for IceConnectionNumber in -lICE" >&5
+echo "configure:13873: checking for IceConnectionNumber in -lICE" >&5
 ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13425,7 +13877,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13429 "configure"
+#line 13881 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13436,7 +13888,7 @@ int main() {
 IceConnectionNumber()
 ; return 0; }
 EOF
-if { (eval echo configure:13440: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13892: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13463,7 +13915,7 @@ fi
 	LDFLAGS="$LDFLAGS $X_LIBS"
 	CFLAGS="$CFLAGS $X_CFLAGS"
 	echo $ac_n "checking for XOpenDisplay in -lX11""... $ac_c" 1>&6
-echo "configure:13467: checking for XOpenDisplay in -lX11" >&5
+echo "configure:13919: checking for XOpenDisplay in -lX11" >&5
 ac_lib_var=`echo X11'_'XOpenDisplay | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13471,7 +13923,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13475 "configure"
+#line 13927 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13482,7 +13934,7 @@ int main() {
 XOpenDisplay()
 ; return 0; }
 EOF
-if { (eval echo configure:13486: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13938: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13503,7 +13955,7 @@ else
 fi
 
 	echo $ac_n "checking for XtAppInitialize in -lXt""... $ac_c" 1>&6
-echo "configure:13507: checking for XtAppInitialize in -lXt" >&5
+echo "configure:13959: checking for XtAppInitialize in -lXt" >&5
 ac_lib_var=`echo Xt'_'XtAppInitialize | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13511,7 +13963,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13515 "configure"
+#line 13967 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13522,7 +13974,7 @@ int main() {
 XtAppInitialize()
 ; return 0; }
 EOF
-if { (eval echo configure:13526: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:13978: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13579,7 +14031,7 @@ fi
 
 
 echo $ac_n "checking for XextCreateExtension in -lXext""... $ac_c" 1>&6
-echo "configure:13583: checking for XextCreateExtension in -lXext" >&5
+echo "configure:14035: checking for XextCreateExtension in -lXext" >&5
 ac_lib_var=`echo Xext'_'XextCreateExtension | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13587,7 +14039,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lXext  $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13591 "configure"
+#line 14043 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13598,7 +14050,7 @@ int main() {
 XextCreateExtension()
 ; return 0; }
 EOF
-if { (eval echo configure:13602: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14054: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13634,13 +14086,13 @@ do
 		if test $cf_path != default ; then
 			CFLAGS="-I$cf_path/include $cf_save"
 			echo $ac_n "checking for $cf_test in $cf_path""... $ac_c" 1>&6
-echo "configure:13638: checking for $cf_test in $cf_path" >&5
+echo "configure:14090: checking for $cf_test in $cf_path" >&5
 		else
 			echo $ac_n "checking for $cf_test""... $ac_c" 1>&6
-echo "configure:13641: checking for $cf_test" >&5
+echo "configure:14093: checking for $cf_test" >&5
 		fi
 		cat > conftest.$ac_ext <<EOF
-#line 13644 "configure"
+#line 14096 "configure"
 #include "confdefs.h"
 
 #include <X11/Intrinsic.h>
@@ -13649,7 +14101,7 @@ int main() {
 
 ; return 0; }
 EOF
-if { (eval echo configure:13653: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:14105: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_result=yes
 else
@@ -13675,21 +14127,21 @@ rm -f conftest*
 			if test $cf_path != default ; then
 				LIBS="-L$cf_path/lib $cf_lib $LIBS"
 				echo $ac_n "checking for $cf_lib in $cf_path""... $ac_c" 1>&6
-echo "configure:13679: checking for $cf_lib in $cf_path" >&5
+echo "configure:14131: checking for $cf_lib in $cf_path" >&5
 			else
 				LIBS="$cf_lib $LIBS"
 				echo $ac_n "checking for $cf_test in $cf_lib""... $ac_c" 1>&6
-echo "configure:13683: checking for $cf_test in $cf_lib" >&5
+echo "configure:14135: checking for $cf_test in $cf_lib" >&5
 			fi
 			cat > conftest.$ac_ext <<EOF
-#line 13686 "configure"
+#line 14138 "configure"
 #include "confdefs.h"
 
 int main() {
 $cf_test()
 ; return 0; }
 EOF
-if { (eval echo configure:13693: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14145: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_result=yes
 else
@@ -13730,7 +14182,7 @@ EOF
 LDFLAGS="$LDFLAGS $X_LIBS"
 CFLAGS="$CFLAGS $X_CFLAGS"
 echo $ac_n "checking for XOpenDisplay in -lX11""... $ac_c" 1>&6
-echo "configure:13734: checking for XOpenDisplay in -lX11" >&5
+echo "configure:14186: checking for XOpenDisplay in -lX11" >&5
 ac_lib_var=`echo X11'_'XOpenDisplay | sed 'y%./+-%__p_%'`
 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
@@ -13738,7 +14190,7 @@ else
   ac_save_LIBS="$LIBS"
 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13742 "configure"
+#line 14194 "configure"
 #include "confdefs.h"
 /* Override any gcc2 internal prototype to avoid an error.  */
 /* We use char because int might match the return type of a gcc2
@@ -13749,7 +14201,7 @@ int main() {
 XOpenDisplay()
 ; return 0; }
 EOF
-if { (eval echo configure:13753: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14205: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   eval "ac_cv_lib_$ac_lib_var=yes"
 else
@@ -13770,14 +14222,14 @@ else
 fi
 
 echo $ac_n "checking for XCurses library""... $ac_c" 1>&6
-echo "configure:13774: checking for XCurses library" >&5
+echo "configure:14226: checking for XCurses library" >&5
 if eval "test \"`echo '$''{'cf_cv_lib_XCurses'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
   
 LIBS="-lXCurses $LIBS"
 cat > conftest.$ac_ext <<EOF
-#line 13781 "configure"
+#line 14233 "configure"
 #include "confdefs.h"
 
 #include <xcurses.h>
@@ -13787,7 +14239,7 @@ int main() {
 XCursesExit();
 ; return 0; }
 EOF
-if { (eval echo configure:13791: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:14243: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   rm -rf conftest*
   cf_cv_lib_XCurses=yes
 else
@@ -13821,7 +14273,7 @@ fi
 else
 	
 echo $ac_n "checking if we can include termio.h with curses""... $ac_c" 1>&6
-echo "configure:13825: checking if we can include termio.h with curses" >&5
+echo "configure:14277: checking if we can include termio.h with curses" >&5
 if eval "test \"`echo '$''{'cf_cv_termio_and_curses'+set}'`\" = set"; then
   echo $ac_n "(cached) $ac_c" 1>&6
 else
@@ -13830,7 +14282,7 @@ else
     CFLAGS="$CFLAGS -DHAVE_CONFIG_H -I. -I${srcdir-.} -I${srcdir-.}/src -I${srcdir-.}/WWW/Library/Implementation"
     touch lynx_cfg.h
     cat > conftest.$ac_ext <<EOF
-#line 13834 "configure"
+#line 14286 "configure"
 #include "confdefs.h"
 
 #include <LYCurses.h>
@@ -13839,7 +14291,7 @@ int main() {
 putchar(0x0a)
 ; return 0; }
 EOF
-if { (eval echo configure:13843: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:14295: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
   rm -rf conftest*
   cf_cv_termio_and_curses=yes
 else
@@ -14059,11 +14511,11 @@ s%@GT_NO@%$GT_NO%g
 s%@GT_YES@%$GT_YES%g
 s%@MKINSTALLDIRS@%$MKINSTALLDIRS%g
 s%@l@%$l%g
-s%@NLS_DATADIR@%$NLS_DATADIR%g
 s%@USE_OUR_MESSAGES@%$USE_OUR_MESSAGES%g
-s%@INTLDIR_CPPFLAGS@%$INTLDIR_CPPFLAGS%g
 s%@INTLDIR_MAKE@%$INTLDIR_MAKE%g
 s%@MSG_DIR_MAKE@%$MSG_DIR_MAKE%g
+s%@INTLDIR_CPPFLAGS@%$INTLDIR_CPPFLAGS%g
+s%@NLS_DATADIR@%$NLS_DATADIR%g
 s%@CHMOD@%$CHMOD%g
 s%@COMPRESS@%$COMPRESS%g
 s%@COPY@%$COPY%g
@@ -14358,9 +14810,13 @@ while test -n "$ac_sources"; do
 done
 EOF
 cat >> $CONFIG_STATUS <<EOF
-#(vi
-     case "\$CONFIG_FILES" in *po/makefile.in*)
+ #(vi
+      case "\$CONFIG_FILES" in
+      *po/makefile.in*) #(vi
         sed -e "/POTFILES =/r po/POTFILES" po/makefile.in > po/makefile
+        ;;
+      *po/Makefile.in*)
+        sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile
       esac
 
 # Extra initialization commands, if any
diff --git a/configure.in b/configure.in
index f5cf900d..b4cee608 100644
--- a/configure.in
+++ b/configure.in
@@ -113,75 +113,20 @@ CF_HELP_MESSAGE(
 Basic Configuration Options:)
 
 dnl internationalization macros
-AM_GNU_GETTEXT
-
-CF_WITH_PATH(nls-datadir,
-[  --with-nls-datadir=DIR  NLS data, parent of locale],
-NLS_DATADIR,
-[PREFIX/DATADIR],
-[$prefix/$DATADIRNAME])
+CF_BUNDLED_INTL(makefile)
 
 INTLDIR_CPPFLAGS="#"
-INTLDIR_MAKE=
-MSG_DIR_MAKE=
-SUB_MAKEFILE=
-CF_OUR_MESSAGES
-if test "$USE_INCLUDED_LIBINTL" = yes ; then
-        if test "$nls_cv_force_use_gnu_gettext" = yes ; then
-		AC_MSG_WARN(Using included gettext anyway[,] since none was found)
-		SUB_MAKEFILE="intl/makefile"
-	else
-		INTLDIR_MAKE="#"
-	fi
-	if test $use_our_messages = no ; then
-		MSG_DIR_MAKE="#"
-		SUB_MAKEFILE=
-	fi
-	if test "$use_our_messages" = yes ; then
-		SUB_MAKEFILE="$SUB_MAKEFILE po/makefile.in:po/makefile.inn"
-	else
-		MSG_DIR_MAKE="#"
-	fi
-elif test "$USE_NLS" = yes ; then
-	AC_CHECK_HEADERS(libintl.h)
-	INTLDIR_MAKE="#"
-	SUB_MAKEFILE="po/makefile.in:po/makefile.inn"
-else
-	INTLDIR_MAKE="#"
-	MSG_DIR_MAKE="#"
-fi
-
-dnl We might want to use a preinstalled message library rather than the one
-dnl which is bundled with this program.
-if test -z "$MSG_DIR_MAKE" ; then
-	if test $use_our_messages = no ; then
-		MSG_DIR_MAKE="#"
-		SUB_MAKEFILE=
-	fi
-fi
-
 if test -z "$INTLDIR_MAKE" ; then
 	INTLDIR_CPPFLAGS=
 fi
 
 AC_SUBST(INTLDIR_CPPFLAGS)
-AC_SUBST(INTLDIR_MAKE)
-AC_SUBST(MSG_DIR_MAKE)
-
-dnl FIXME:  the underlying AM_GNU_GETTEXT macro either needs some fixes or a
-dnl little documentation.  It doesn't define anything so that we can ifdef our
-dnl own code, except ENABLE_NLS, which is too vague to be of any use.
-
-if test "$USE_INCLUDED_LIBINTL" = yes ; then
-	if test "$nls_cv_force_use_gnu_gettext" = yes ; then
-		AC_DEFINE(HAVE_GETTEXT)
-	elif test "$nls_cv_use_gnu_gettext" = yes ; then
-		AC_DEFINE(HAVE_GETTEXT)
-	fi
-	if test -n "$nls_cv_header_intl" ; then
-		AC_DEFINE(HAVE_LIBINTL_H)
-	fi
-fi
+
+CF_WITH_PATH(nls-datadir,
+[  --with-nls-datadir=DIR  NLS data, parent of locale],
+NLS_DATADIR,
+[PREFIX/DATADIR],
+[$prefix/$DATADIRNAME])
 
 AC_MSG_CHECKING(if you want full utility pathnames)
 CF_ARG_DISABLE(full-paths,
@@ -967,7 +912,7 @@ if test ".$use_zlib" != ".no" ; then
 		CF_VERBOSE(... tested $cf_incdir)
 	done
 	])
-	CF_FIND_LIBRARY(z,
+	CF_FIND_LIBRARY(z,z,
 		[#include <zlib.h>],
 		[gzopen("name","mode")],
 		gzopen)
diff --git a/intl/libintl.h b/intl/libintl.h
deleted file mode 100644
index 3d49ab51..00000000
--- a/intl/libintl.h
+++ /dev/null
@@ -1,182 +0,0 @@
-/* Message catalogs for internationalization.
-   Copyright (C) 1995, 1996, 1997 Free Software Foundation, Inc.
-
-   This program 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.
-
-   This program 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 this program; if not, write to the Free Software Foundation,
-   Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
-
-/* Because on some systems (e.g., Solaris) we sometimes have to include
-   the systems libintl.h as well as this file we have more complex
-   include protection above.  But the systems header might perhaps also
-   define _LIBINTL_H and therefore we have to protect the definition here.  */
-
-#if !defined (_LIBINTL_H) || !defined (_LIBGETTEXT_H)
-#if !defined (_LIBINTL_H)
-# define _LIBINTL_H	1
-#endif
-#define _LIBGETTEXT_H	1
-
-/* We define an additional symbol to signal that we use the GNU
-   implementation of gettext.  */
-#define __USE_GNU_GETTEXT 1
-
-#include <sys/types.h>
-
-#if HAVE_LOCALE_H
-# include <locale.h>
-#endif
-
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-/* @@ end of prolog @@ */
-
-#ifndef PARAMS
-# if __STDC__
-#  define PARAMS(args) args
-# else
-#  define PARAMS(args) ()
-# endif
-#endif
-
-#ifndef NULL
-# if !defined __cplusplus || defined __GNUC__
-#  define NULL ((void *) 0)
-# else
-#  define NULL (0)
-# endif
-#endif
-
-#if !HAVE_LC_MESSAGES
-/* This value determines the behaviour of the gettext() and dgettext()
-   function.  But some system does not have this defined.  Define it
-   to a default value.  */
-# define LC_MESSAGES (-1)
-#endif
-
-
-/* Declarations for gettext-using-catgets interface.  Derived from
-   Jim Meyering's libintl.h.  */
-struct _msg_ent
-{
-  const char *_msg;
-  int _msg_number;
-};
-
-
-#if HAVE_CATGETS
-/* These two variables are defined in the automatically by po-to-tbl.sed
-   generated file `cat-id-tbl.c'.  */
-extern const struct _msg_ent _msg_tbl[];
-extern int _msg_tbl_length;
-#endif
-
-
-/* For automatical extraction of messages sometimes no real
-   translation is needed.  Instead the string itself is the result.  */
-#define gettext_noop(Str) (Str)
-
-/* Look up MSGID in the current default message catalog for the current
-   LC_MESSAGES locale.  If not found, returns MSGID itself (the default
-   text).  */
-extern char *gettext PARAMS ((const char *__msgid));
-extern char *gettext__ PARAMS ((const char *__msgid));
-
-/* Look up MSGID in the DOMAINNAME message catalog for the current
-   LC_MESSAGES locale.  */
-extern char *dgettext PARAMS ((const char *__domainname, const char *__msgid));
-extern char *dgettext__ PARAMS ((const char *__domainname,
-				 const char *__msgid));
-
-/* Look up MSGID in the DOMAINNAME message catalog for the current CATEGORY
-   locale.  */
-extern char *dcgettext PARAMS ((const char *__domainname, const char *__msgid,
-				int __category));
-extern char *dcgettext__ PARAMS ((const char *__domainname,
-				  const char *__msgid, int __category));
-
-
-/* Set the current default message catalog to DOMAINNAME.
-   If DOMAINNAME is null, return the current default.
-   If DOMAINNAME is "", reset to the default of "messages".  */
-extern char *textdomain PARAMS ((const char *__domainname));
-extern char *textdomain__ PARAMS ((const char *__domainname));
-
-/* Specify that the DOMAINNAME message catalog will be found
-   in DIRNAME rather than in the system locale data base.  */
-extern char *bindtextdomain PARAMS ((const char *__domainname,
-				  const char *__dirname));
-extern char *bindtextdomain__ PARAMS ((const char *__domainname,
-				    const char *__dirname));
-
-#if ENABLE_NLS
-
-/* Solaris 2.3 has the gettext function but dcgettext is missing.
-   So we omit this optimization for Solaris 2.3.  BTW, Solaris 2.4
-   has dcgettext.  */
-# if !HAVE_CATGETS && (!HAVE_GETTEXT || HAVE_DCGETTEXT)
-
-#  define gettext(Msgid)						      \
-     dgettext (NULL, Msgid)
-
-#  define dgettext(Domainname, Msgid)					      \
-     dcgettext (Domainname, Msgid, LC_MESSAGES)
-
-#  if defined __GNUC__ && __GNUC__ == 2 && __GNUC_MINOR__ >= 7
-/* This global variable is defined in loadmsgcat.c.  We need a sign,
-   whether a new catalog was loaded, which can be associated with all
-   translations.  */
-extern int _nl_msg_cat_cntr;
-
-#   define dcgettext(Domainname, Msgid, Category)			      \
-  (__extension__							      \
-   ({									      \
-     char *__result;							      \
-     if (__builtin_constant_p (Msgid))					      \
-       {								      \
-	 static char *__translation__;					      \
-	 static int __catalog_counter__;				      \
-	 if (! __translation__ || __catalog_counter__ != _nl_msg_cat_cntr)    \
-	   {								      \
-	     __translation__ =						      \
-	       dcgettext__ (Domainname, Msgid, Category);		      \
-	     __catalog_counter__ = _nl_msg_cat_cntr;			      \
-	   }								      \
-	 __result = __translation__;					      \
-       }								      \
-     else								      \
-       __result = dcgettext__ (Domainname, Msgid, Category);		      \
-     __result;								      \
-    }))
-#  endif
-# endif
-
-#else
-
-# define gettext(Msgid) (Msgid)
-# define dgettext(Domainname, Msgid) (Msgid)
-# define dcgettext(Domainname, Msgid, Category) (Msgid)
-# define textdomain(Domainname) while (0) /* nothing */
-# define bindtextdomain(Domainname, Dirname) while (0) /* nothing */
-
-#endif
-
-/* @@ begin of epilog @@ */
-
-#ifdef __cplusplus
-}
-#endif
-
-#endif
diff --git a/lynx.cfg b/lynx.cfg
index 066e9c94..f632dd8b 100644
--- a/lynx.cfg
+++ b/lynx.cfg
@@ -167,13 +167,25 @@ DEFAULT_INDEX_FILE:http://www.ncsa.uiuc.edu/SDG/Software/Mosaic/MetaIndex.html
 #
 # On VMS, use Unix SHELL syntax (including a lead slash) to define it.
 #
-# Additional jumps files can be defined and mapped to keystrokes
-# in  lynx.cfg , but you should first define the default jumps file,
-# which is mapped by default to 'j' (or 'J' when VI keys are ON).
+# Alternate jumps files can be defined and mapped to keys here.  If the
+# keys have already been mapped, then those mappings will be replaced,
+# but you should leave at least one key mapped to the default jumps
+# file.  You optionally may include a statusline prompt string for the
+# mapping.  You must map upper and lowercase keys separately (beware of
+# mappings to keys which the user can further remap via the 'o'ptions
+# menu).  The format is:
+#
+#	JUMPFILE:path:key[:prompt]
+#
+# where path should begin with a '/' (i.e., not include file://localhost).
+# Any white space following a prompt string will be trimmed, and a single
+# space will be added by Lynx.
 #
 # In the following line, include the actual full local path to JUMPFILE,
 # but do not include 'file://localhost' in the line.
 #JUMPFILE:/FULL_LOCAL_PATH/jumps.html
+.ex
+#JUMPFILE:/Lynx_Dir/ips.html:i:IP or Interest group (? for list):
 
 
 .h2 JUMPBUFFER
@@ -2448,24 +2460,6 @@ MINIMAL_COMMENTS:TRUE
 #KEYMAP:^[::SETM2:3	# use escape key as modifier - works only sometimes
 
 
-.h2 JUMPFILE
-# Alternate jumps files can be defined and mapped to keys here.  If the
-# keys have already been mapped, then those mappings will be replaced,
-# but you should leave at least one key mapped to the default jumps
-# file.  You optionally may include a statusline prompt string for the
-# mapping.  You must map upper and lowercase keys separately (beware of
-# mappings to keys which the user can further remap via the 'o'ptions
-# menu).  The format is:
-#
-#	JUMPFILE:path:key[:prompt]
-#
-# where path should begin with a '/' (i.e., not include file://localhost).
-# Any white space following a prompt string will be trimmed, and a single
-# space will be added by Lynx.
-.ex
-#JUMPFILE:/Lynx_Dir/ips.html:i:IP or Interest group (? for list):
-
-
 .h1 External Programs
 # These settings control the ability of Lynx to invoke various programs for
 # the user.
diff --git a/lynx.hlp b/lynx.hlp
index ffad490d..7459e195 100644
--- a/lynx.hlp
+++ b/lynx.hlp
@@ -533,36 +533,38 @@
               allow  non-http   startfile   and   homepage   with
               -validate.
 
+       -stdin read the startfile from standard input (UNIX only).
+
        -tagsoup
-              initialize  parser,  using Tag Soup DTD rather than
+              initialize parser, using Tag Soup DTD  rather  than
               SortaSGML.
 
        -telnet
               disable recognition of telnet commands.
 
        -term=TERM
-              tell Lynx  what  terminal  type  to  assume  it  is
-              talking   to.   (This  may  be  useful  for  remote
-              execution, when, for example, Lynx  connects  to  a
-              remote  TCP/IP  port  that starts a script that, in
+              tell  Lynx  what  terminal  type  to  assume  it is
+              talking  to.   (This  may  be  useful  for   remote
+              execution,  when,  for  example, Lynx connects to a
+              remote TCP/IP port that starts a  script  that,  in
               turn, starts another Lynx process.)
 
        -timeout=N
-              For win32, sets the network read-timeout,  where  N
+              For  win32,  sets the network read-timeout, where N
               is given in seconds.
 
-       -tlog  toggles  between  using a Lynx Trace Log and stderr
+       -tlog  toggles between using a Lynx Trace Log  and  stderr
               for trace output from the session.
 
        -tna   turns on "Textfields Need Activation" mode.
 
-       -trace turns on Lynx trace  mode.   Destination  of  trace
+       -trace turns  on  Lynx  trace  mode.  Destination of trace
               output depends on -tlog.
 
        -traversal
-              traverse  all  http  links  derived from startfile.
-              When used with -crawl, each link that  begins  with
-              the  same  string as startfile is output to a file,
+              traverse all http  links  derived  from  startfile.
+              When  used  with -crawl, each link that begins with
+              the same string as startfile is output to  a  file,
               intended for indexing.  See CRAWL.announce for more
               information.
 
@@ -570,27 +572,27 @@
               toggles use of _underline_ format in dumps.
 
        -use_mouse
-              turn  on mouse support, if available.  Clicking the
+              turn on mouse support, if available.  Clicking  the
               left mouse button on a link traverses it.  Clicking
               the right mouse button pops back.  Click on the top
-              line to scroll up.  Click on  the  bottom  line  to
-              scroll  down.   The  first few positions in the top
-              and bottom line may  invoke  additional  functions.
-              Lynx  must  be  compiled  with  ncurses or slang to
+              line  to  scroll  up.   Click on the bottom line to
+              scroll down.  The first few positions  in  the  top
+              and  bottom  line  may invoke additional functions.
+              Lynx must be compiled  with  ncurses  or  slang  to
               support this feature.  If ncurses is used, clicking
-              the  middle  mouse  button  pops  up a simple menu.
-              Mouse clicks may only work reliably while  Lynx  is
+              the middle mouse button  pops  up  a  simple  menu.
+              Mouse  clicks  may only work reliably while Lynx is
               idle waiting for input.
 
        -useragent=Name
               set alternate Lynx User-Agent header.
 
        -validate
-              accept  only  http URLs (for validation).  Complete
+              accept only http URLs (for  validation).   Complete
               security restrictions also are implemented.
 
        -verbose
-              toggle [LINK], [IMAGE] and [INLINE]  comments  with
+              toggle  [LINK],  [IMAGE] and [INLINE] comments with
               filenames of these images.
 
        -version
@@ -600,220 +602,220 @@
               enable vi-like key movement.
 
        -wdebug
-              enable  Waterloo tcp/ip packet debug (print to watt
-              debugfile).  This  applies  only  to  DOS  versions
+              enable Waterloo tcp/ip packet debug (print to  watt
+              debugfile).   This  applies  only  to  DOS versions
               compiled with WATTCP or WATT-32.
 
        -width=NUMBER
-              number  of columns for formatting of dumps, default
+              number of columns for formatting of dumps,  default
               is 80.
 
        -with_backspaces
-              emit backspaces in output if -dumping or  -crawling
+              emit  backspaces in output if -dumping or -crawling
               (like 'man' does)
 
 2 COMMANDS
-       o  Use Up arrow and Down arrow to scroll through hypertext
+       o Use Up arrow and Down arrow to scroll through  hypertext
        links.
-       o  Right  arrow  or  Return  will  follow  a   highlighted
+       o   Right  arrow  or  Return  will  follow  a  highlighted
        hypertext link.
        o Left Arrow will retreat from a link.
        o Type "H" or "?" for online help and descriptions of key-
        stroke commands.
-       o Type "K" for a complete list of the  current  key-stroke
+       o  Type  "K" for a complete list of the current key-stroke
        command mappings.
 
 2 ENVIRONMENT
-       In  addition  to  various "standard" environment variables
-       such as HOME,  PATH,  USER,  DISPLAY,  TMPDIR,  etc,  Lynx
-       utilizes  several  Lynx-specific environment variables, if
+       In addition to various  "standard"  environment  variables
+       such  as  HOME,  PATH,  USER,  DISPLAY,  TMPDIR, etc, Lynx
+       utilizes several Lynx-specific environment  variables,  if
        they exist.
 
-       Others may be created or modified by Lynx to pass data  to
-       an  external  program,  or  for  other reasons.  These are
+       Others  may be created or modified by Lynx to pass data to
+       an external program, or  for  other  reasons.   These  are
        listed separately below.
 
-       See also the sections on SIMULATED CGI SUPPORT and  NATIVE
+       See  also the sections on SIMULATED CGI SUPPORT and NATIVE
        LANGUAGE SUPPORT, below.
 
        Note:  Not all environment variables apply to all types of
-       platforms supported by Lynx, though most do.  Feedback  on
+       platforms  supported by Lynx, though most do.  Feedback on
        platform dependencies is solicited.
 
        Environment Variables Used By Lynx:
 
-       COLORTERM           If   set,  color  capability  for  the
+       COLORTERM           If  set,  color  capability  for   the
                            terminal is forced on at startup time.
-                           The   actual  value  assigned  to  the
+                           The  actual  value  assigned  to   the
+
                            variable is ignored.  This variable is
                            only  meaningful  if  Lynx  was  built
-
-                           using   the   slang    screen-handling
+                           using    the   slang   screen-handling
                            library.
 
-       LYNX_CFG            This  variable,  if set, will override
-                           the default location and name  of  the
-                           global  configuration  file (normally,
+       LYNX_CFG            This variable, if set,  will  override
+                           the  default  location and name of the
+                           global configuration  file  (normally,
                            lynx.cfg)  that  was  defined  by  the
                            LYNX_CFG_FILE    constant    in    the
-                           userdefs.h file, during  installation.
-                           See   the  userdefs.h  file  for  more
+                           userdefs.h  file, during installation.
+                           See  the  userdefs.h  file  for   more
                            information.
 
-       LYNX_LSS            This variable, if set,  specifies  the
+       LYNX_LSS            This  variable,  if set, specifies the
                            location of the default Lynx character
                            style  sheet  file.   [Currently  only
-                           meaningful  if  Lynx  was  built using
+                           meaningful if  Lynx  was  built  using
                            experimental color style support.]
 
-       LYNX_SAVE_SPACE     This variable, if set,  will  override
+       LYNX_SAVE_SPACE     This  variable,  if set, will override
                            the  default  path  prefix  for  files
-                           saved to disk that is defined  in  the
-                           lynx.cfg  SAVE_SPACE:  statement.  See
+                           saved  to  disk that is defined in the
+                           lynx.cfg SAVE_SPACE:  statement.   See
                            the    lynx.cfg    file    for    more
                            information.
 
-       LYNX_TEMP_SPACE     This  variable,  if set, will override
-                           the default path prefix for  temporary
-                           files    that   was   defined   during
-                           installation, as  well  as  any  value
-                           that  may  be  assigned  to the TMPDIR
+       LYNX_TEMP_SPACE     This variable, if set,  will  override
+                           the  default path prefix for temporary
+                           files   that   was   defined    during
+                           installation,  as  well  as  any value
+                           that may be  assigned  to  the  TMPDIR
                            variable.
 
-       MAIL                This variable  specifies  the  default
+       MAIL                This  variable  specifies  the default
                            inbox Lynx will check for new mail, if
-                           such  checking  is  enabled   in   the
+                           such   checking   is  enabled  in  the
                            lynx.cfg file.
 
-       NEWS_ORGANIZATION   This  variable,  if  set, provides the
-                           string  used  in   the   Organization:
-                           header  of  USENET  news postings.  It
-                           will  override  the  setting  of   the
-                           ORGANIZATION  environment variable, if
-                           it is also  set  (and,  on  UNIX,  the
+       NEWS_ORGANIZATION   This variable, if  set,  provides  the
+                           string   used   in  the  Organization:
+                           header of USENET  news  postings.   It
+                           will   override  the  setting  of  the
+                           ORGANIZATION environment variable,  if
+                           it  is  also  set  (and,  on UNIX, the
                            contents of an /etc/organization file,
                            if present).
 
-       NNTPSERVER          If set, this  variable  specifies  the
-                           default  NNTP server that will be used
-                           for USENET news  reading  and  posting
+       NNTPSERVER          If  set,  this  variable specifies the
+                           default NNTP server that will be  used
+                           for  USENET  news  reading and posting
                            with Lynx, via news: URL's.
 
-       ORGANIZATION        This  variable,  if  set, provides the
-                           string  used  in   the   Organization:
-                           header  of  USENET  news postings.  On
+       ORGANIZATION        This variable, if  set,  provides  the
 
+                           string   used   in  the  Organization:
+                           header of USENET  news  postings.   On
                            UNIX, it will override the contents of
                            an /etc/organization file, if present.
 
        PROTOCOL_proxy      Lynx supports the use of proxy servers
-                           that  can act as firewall gateways and
-                           caching servers.  They are  preferable
+                           that can act as firewall gateways  and
+                           caching  servers.  They are preferable
                            to  the  older  gateway  servers  (see
-                           WWW_access_GATEWAY,   below).     Each
-                           protocol  used  by  Lynx,  (http, ftp,
+                           WWW_access_GATEWAY,    below).    Each
+                           protocol used  by  Lynx,  (http,  ftp,
                            gopher, etc), can be mapped separately
-                           by  setting  environment  variables of
+                           by setting  environment  variables  of
                            the  form  PROTOCOL_proxy  (literally:
                            http_proxy,  ftp_proxy,  gopher_proxy,
                            etc),                               to
                            "http://some.server.dom:port/".    See
-                           Lynx  Users   Guide   for   additional
+                           Lynx   Users   Guide   for  additional
                            details and examples.
 
-       WWW_access_GATEWAY  Lynx  still  supports  use  of gateway
-                           servers, with  the  servers  specified
+       WWW_access_GATEWAY  Lynx still  supports  use  of  gateway
+                           servers,  with  the  servers specified
                            via   "WWW_access_GATEWAY"   variables
-                           (where "access" is lower case and  can
+                           (where  "access" is lower case and can
                            be "http", "ftp", "gopher" or "wais"),
                            however most gateway servers have been
-                           discontinued.   Note  that  you do not
-                           include a terminal '/'  for  gateways,
-                           but   do   for  proxies  specified  by
-                           PROTOCOL_proxy environment  variables.
+                           discontinued.  Note that  you  do  not
+                           include  a  terminal '/' for gateways,
+                           but  do  for  proxies   specified   by
+                           PROTOCOL_proxy  environment variables.
                            See Lynx Users Guide for details.
 
-       WWW_HOME            This  variable,  if set, will override
-                           the default startup URL  specified  in
+       WWW_HOME            This variable, if set,  will  override
+                           the  default  startup URL specified in
                            any of the Lynx configuration files.
 
        Environment Variables Set or Modified By Lynx:
 
        LYNX_PRINT_DATE     This  variable  is  set  by  the  Lynx
-                           p(rint) function, to the Date:  string
-                           seen  in  the  document's "Information
-                           about" page (= cmd), if  any.   It  is
-                           created   for   use   by  an  external
+                           p(rint)  function, to the Date: string
+                           seen in  the  document's  "Information
+                           about"  page  (=  cmd), if any.  It is
+                           created  for  use   by   an   external
                            program,  as  defined  in  a  lynx.cfg
                            PRINTER: definition statement.  If the
                            field does not exist for the document,
-                           the  variable  is set to a null string
+                           the variable is set to a  null  string
                            under UNIX, or "No Date" under VMS.
 
        LYNX_PRINT_LASTMOD  This  variable  is  set  by  the  Lynx
-                           p(rint)  function,  to  the  Last Mod:
-                           string   seen   in   the    document's
-                           "Information  about"  page (= cmd), if
-                           any.  It is  created  for  use  by  an
+                           p(rint) function,  to  the  Last  Mod:
+                           string    seen   in   the   document's
+                           "Information about" page (=  cmd),  if
+                           any.   It  is  created  for  use by an
+
                            external  program,  as  defined  in  a
                            lynx.cfg      PRINTER:      definition
-
                            statement.   If  the  field  does  not
-                           exist for the document,  the  variable
+                           exist  for  the document, the variable
                            is set to a null string under UNIX, or
                            "No LastMod" under VMS.
 
        LYNX_PRINT_TITLE    This  variable  is  set  by  the  Lynx
                            p(rint)  function,  to  the  Linkname:
-                           string   seen   in   the    document's
-                           "Information  about"  page (= cmd), if
-                           any.  It is  created  for  use  by  an
+                           string    seen   in   the   document's
+                           "Information about" page (=  cmd),  if
+                           any.   It  is  created  for  use by an
                            external  program,  as  defined  in  a
                            lynx.cfg      PRINTER:      definition
                            statement.   If  the  field  does  not
-                           exist for the document,  the  variable
+                           exist  for  the document, the variable
                            is set to a null string under UNIX, or
                            "No Title" under VMS.
 
        LYNX_PRINT_URL      This  variable  is  set  by  the  Lynx
-                           p(rint)  function,  to the URL: string
-                           seen in  the  document's  "Information
-                           about"  page  (=  cmd), if any.  It is
-                           created  for  use   by   an   external
+                           p(rint) function, to the  URL:  string
+                           seen  in  the  document's "Information
+                           about" page (= cmd), if  any.   It  is
+                           created   for   use   by  an  external
                            program,  as  defined  in  a  lynx.cfg
                            PRINTER: definition statement.  If the
                            field does not exist for the document,
-                           the variable is set to a  null  string
+                           the  variable  is set to a null string
                            under UNIX, or "No URL" under VMS.
 
-       LYNX_VERSION        This  variable  is always set by Lynx,
+       LYNX_VERSION        This variable is always set  by  Lynx,
                            and may be used by an external program
-                           to  determine  if  it  was  invoked by
-                           Lynx.  See also the  comments  in  the
+                           to determine  if  it  was  invoked  by
+                           Lynx.   See  also  the comments in the
                            distribution's  sample  mailcap  file,
                            for notes on usage in such a file.
 
-       TERM                Normally, this  variable  is  used  by
-                           Lynx  to  determine  the terminal type
-                           being  used  to  invoke   Lynx.    If,
-                           however,  it  is unset at startup time
-                           (or has the value  "unknown"),  or  if
-                           the  -term command-line option is used
+       TERM                Normally,  this  variable  is  used by
+                           Lynx to determine  the  terminal  type
+                           being   used   to  invoke  Lynx.   If,
+                           however, it is unset at  startup  time
+                           (or  has  the  value "unknown"), or if
+                           the -term command-line option is  used
                            (see OPTIONS section above), Lynx will
-                           set  or  modify  its value to the user
-                           specified terminal type (for the  Lynx
-                           execution   environment).    Note:  If
-                           set/modified by Lynx,  the  values  of
-                           the  LINES  and/or COLUMNS environment
+                           set or modify its value  to  the  user
+                           specified  terminal type (for the Lynx
+                           execution  environment).    Note:   If
+                           set/modified  by  Lynx,  the values of
+                           the LINES and/or  COLUMNS  environment
                            variables may also be changed.
 
 2 SIMULATED CGI SUPPORT
-       If built with the cgi-links option  enabled,  Lynx  allows
-       access  to  a  cgi script directly without the need for an
+       If  built  with  the cgi-links option enabled, Lynx allows
+       access to a cgi script directly without the  need  for  an
        http daemon.
 
-       When executing such "lynxcgi scripts"  (if  enabled),  the
-       following  variables  may  be  set  for  simulating  a CGI
+       When  executing  such  "lynxcgi scripts" (if enabled), the
+       following variables  may  be  set  for  simulating  a  CGI
        environment:
 
        CONTENT_LENGTH
@@ -842,116 +844,115 @@
 
        SERVER_SOFTWARE
 
-       Other environment  variables  are  not  inherited  by  the
+       Other  environment  variables  are  not  inherited  by the
        script, unless they are provided via a LYNXCGI_ENVIRONMENT
-       statement in the configuration  file.   See  the  lynx.cfg
-       file,    and    the    (draft)   CGI   1.1   Specification
+       statement  in  the  configuration  file.  See the lynx.cfg
+       file,   and   the   (draft)    CGI    1.1    Specification
        <http://Web.Golux.Com/coar/cgi/draft-coar-cgi-v11-00.txt>
        for the definition and usage of these variables.
 
        The CGI Specification, and other associated documentation,
-       should be consulted for general information on CGI  script
+       should  be consulted for general information on CGI script
        programming.
 
 2 NATIVE LANGUAGE SUPPORT
-       If  configured and installed with Native Language Support,
-       Lynx will display status and other messages in your  local
-       language.    See   the   file   ABOUT_NLS  in  the  source
-       distribution,  or  at  your  local  GNU  site,  for   more
+       If configured and installed with Native Language  Support,
+       Lynx  will display status and other messages in your local
+       language.   See  the  file   ABOUT_NLS   in   the   source
+       distribution,   or  at  your  local  GNU  site,  for  more
        information about internationalization.
 
-       The  following  environment variables may be used to alter
+       The following environment variables may be used  to  alter
        default settings:
 
-       LANG                This variable, if set,  will  override
-                           the  default  message language.  It is
-                           an ISO 639 two-letter code identifying
+       LANG                This  variable,  if set, will override
 
-                           the  language.  Language codes are NOT
+                           the default message language.   It  is
+                           an ISO 639 two-letter code identifying
+                           the language.  Language codes are  NOT
                            the same as the country codes given in
                            ISO 3166.
 
-       LANGUAGE            This  variable,  if set, will override
+       LANGUAGE            This variable, if set,  will  override
                            the default message language.  This is
-                           a   GNU   extension  that  has  higher
-                           priority  for  setting   the   message
+                           a  GNU  extension  that   has   higher
+                           priority   for   setting  the  message
                            catalog than LANG or LC_ALL.
 
        LC_ALL              and
 
-       LC_MESSAGES         These  variables,  if set, specify the
-                           notion of native  language  formatting
+       LC_MESSAGES         These variables, if set,  specify  the
+                           notion  of  native language formatting
                            style.  They are POSIXly correct.
 
-       LINGUAS             This   variable,   if   set  prior  to
+       LINGUAS             This  variable,  if   set   prior   to
                            configuration,  limits  the  installed
                            languages to specific values.  It is a
-                           space-separated  list  of   two-letter
+                           space-separated   list  of  two-letter
                            codes.  Currently, it is hard-coded to
                            a wish list.
 
-       NLSPATH             This variable, if set, is used as  the
+       NLSPATH             This  variable, if set, is used as the
                            path prefix for message catalogs.
 
 2 NOTES
        This is the Lynx v2.8.3 Release
 
-       If  you  wish  to contribute to the further development of
-       Lynx, subscribe  to  our  mailing  list.   Send  email  to
-       <majordomo@sig.net>  with "subscribe lynx-dev" as the only
+       If you wish to contribute to the  further  development  of
+       Lynx,  subscribe  to  our  mailing  list.   Send  email to
+       <majordomo@sig.net> with "subscribe lynx-dev" as the  only
        line in the body of your message.
 
-       Send  bug  reports,  comments,   suggestions   to   <lynx-
+       Send   bug   reports,   comments,  suggestions  to  <lynx-
        dev@sig.net> after subscribing.
 
-       Unsubscribe  by  sending email to <majordomo@sig.net> with
-       "unsubscribe lynx-dev" as the only line  in  the  body  of
-       your  message.  Do not send the unsubscribe message to the
+       Unsubscribe by sending email to  <majordomo@sig.net>  with
+       "unsubscribe  lynx-dev"  as  the  only line in the body of
+       your message.  Do not send the unsubscribe message to  the
        lynx-dev list, itself.
 
 2 SEE ALSO
-       catgets(3),  curses(3),  environ(7),  execve(2),   ftp(1),
-       gettext(GNU),   localeconv(3),  ncurses(3),  setlocale(3),
+       catgets(3),   curses(3),  environ(7),  execve(2),  ftp(1),
+       gettext(GNU),  localeconv(3),  ncurses(3),   setlocale(3),
        slang(?), termcap(5), terminfo(5), wget(GNU)
 
-       Note that man page availability and section  numbering  is
-       somewhat  platform  dependent, and may vary from the above
+       Note  that  man page availability and section numbering is
+       somewhat platform dependent, and may vary from  the  above
        references.
 
-       A section shown as (GNU), is intended to denote  that  the
-       topic  may be available via an info page, instead of a man
-       page (i.e., try "info  subject",  rather  than  "man  sub
-       ject").
+       A  section  shown as (GNU), is intended to denote that the
+       topic may be available via an info page, instead of a  man
+       page  (i.e.,  try  "info  subject",  rather than "man subject").
 
-       A  section  shown as (?) denotes that documentation on the
+       A section shown as (?) denotes that documentation  on  the
        topic exists, but is not part of an established documentation
-       retrieval system (see the distribution files associated
-       with the topic, or contact your System  Administrator
+       retrieval system (see the distribution files  associated
+       with the topic, or contact your System Administrator
        for further information).
 
 2 ACKNOWLEDGMENTS
        Lynx has incorporated code from a variety of sources along
        the way.  The earliest versions of Lynx included code from
-       Earl  Fogel  of  Computing  Services  at the University of
-       Saskatchewan, who implemented HYPERREZ in the  Unix  envi-
-       ronment.    HYPERREZ  was  developed  by  Niel  Larson  of
-       Think.com and served as the model for the  early  versions
-       of  Lynx.  Those versions also incorporated libraries from
-       the Unix Gopher clients developed  at  the  University  of
-       Minnesota,  and the later versions of Lynx rely on the WWW
-       client library code developed by Tim Berners-Lee  and  the
-       WWW  community.   Also a special thanks to Foteos Macrides
-       who ported much of Lynx to VMS and did or  organized  most
-       of  its  development  since the departures of Lou Montulli
-       and Garrett Blythe from the University of  Kansas  in  the
-       summer  of  1994 through the release of v2.7.2, and to ev-
-       eryone on the net who has contributed to  Lynx's  develop-
+       Earl Fogel of Computing  Services  at  the  University  of
+       Saskatchewan,  who  implemented HYPERREZ in the Unix envi-
+       ronment.   HYPERREZ  was  developed  by  Niel  Larson   of
+       Think.com  and  served as the model for the early versions
+       of Lynx.  Those versions also incorporated libraries  from
+       the  Unix  Gopher  clients  developed at the University of
+       Minnesota, and the later versions of Lynx rely on the  WWW
+       client  library  code developed by Tim Berners-Lee and the
+       WWW community.  Also a special thanks to  Foteos  Macrides
+       who  ported  much of Lynx to VMS and did or organized most
+       of its development since the departures  of  Lou  Montulli
+       and  Garrett  Blythe  from the University of Kansas in the
+       summer of 1994 through the release of v2.7.2, and  to  ev-
+       eryone  on  the net who has contributed to Lynx's develop-
        ment either directly (through patches, comments or bug re-
-       ports) or indirectly (through inspiration and  development
+       ports)  or indirectly (through inspiration and development
        of other systems).
 
 2 AUTHORS
-       Lou  Montulli,  Garrett  Blythe,  Craig  Lavender, Michael
+       Lou Montulli,  Garrett  Blythe,  Craig  Lavender,  Michael
        Grobe, Charles Rezac
        Academic Computing Services
        University of Kansas
diff --git a/lynx.man b/lynx.man
index cc68df85..2b940938 100644
--- a/lynx.man
+++ b/lynx.man
@@ -567,6 +567,10 @@ disable SIGINT cleanup handler
 .B -startfile_ok
 allow non-http startfile and homepage with -validate.
 .TP
+.B -stdin
+read the startfile from standard input
+(UNIX only).
+.TP
 .B -tagsoup
 initialize parser, using Tag Soup DTD rather than SortaSGML.
 .TP
diff --git a/makefile.in b/makefile.in
index 6929b8d0..879757eb 100644
--- a/makefile.in
+++ b/makefile.in
@@ -230,7 +230,7 @@ clean:
 @INTLDIR_MAKE@	cd intl && $(MAKE) $@
 @MSG_DIR_MAKE@	cd po && $(MAKE) $@
 	rm -f *.b src/lynx$x *.leaks cfg_defs.h LYHelp.h lint.*
-@LYNXCFG_MAKE@	-rm -f alphatoc.html body.html cattoc.html
+@LYNXCFG_MAKE@	-rm -f alphatoc.html body.html cattoc.html tmp007
 	rm -f help_files.sed
 	rm -f core *.core
 
@@ -245,6 +245,7 @@ distclean: clean
 	-cd src && $(MAKE) $@
 	-cd src/chrtrans && $(MAKE) $@
 @INTLDIR_MAKE@	cd intl && $(MAKE) $@
+	-rm -f intl/libintl.h
 @MSG_DIR_MAKE@	-rmdir intl
 @MSG_DIR_MAKE@	cd po && $(MAKE) $@
 @MSG_DIR_MAKE@	-rmdir po
@@ -360,13 +361,17 @@ help_files.sed : makefile $(srcdir)/lynx_help/help_files.txt
 install-help : help_files.sed $(HELPDIR)
 	(cd $(HELPDIR) && WD=`pwd` && HEAD=`echo $$WD|sed -e 's@/lynx_help$$@@'` && test $$WD != $$HEAD && rm -rf *)
 @LYNXCFG_MAKE@	@echo 'Making htmlized lynx.cfg'
+@LYNXCFG_MAKE@	cd src && make LYReadCFG.i
 @LYNXCFG_MAKE@	@-rm -f alphatoc.html body.html cattoc.html
-@LYNXCFG_MAKE@	perl $(srcdir)/scripts/cfg2html.pl $(srcdir)/lynx.cfg
+@LYNXCFG_MAKE@	sed -n -e '/Config_Type  *Config_Table/,/{0, *0, *0}/ p' src/LYReadCFG.i | \
+@LYNXCFG_MAKE@	sed  -e 's/ *{ *"\([^"]*\)".*/\1/' | \
+@LYNXCFG_MAKE@	perl $(srcdir)/scripts/cfg2html.pl -ms $(srcdir)/lynx.cfg
 	@echo Translating/copying html files
 	@cat help_files.sed > $(HELPDIR)/help_files.sed
 @LYNXCFG_MAKE@	@$(SHELL) -c 'for f in alphatoc.html body.html cattoc.html ; do \
 @LYNXCFG_MAKE@		sed -f $(HELPDIR)/help_files.sed $$f > $(HELPDIR)/$$f ; \
 @LYNXCFG_MAKE@		done'
+@LYNXCFG_MAKE@	-rm -f src/LYReadCFG.i
 	@ECHO_CC@$(SHELL) -c 'cd $(srcdir)/lynx_help && ( \
 		dirs=keystrokes; \
 		(cd $(HELPDIR) && mkdir $$dirs 2>/dev/null ) ; \
diff --git a/scripts/cfg2html.pl b/scripts/cfg2html.pl
index be75e24c..9f5fb6d0 100755
--- a/scripts/cfg2html.pl
+++ b/scripts/cfg2html.pl
@@ -22,6 +22,35 @@
 
 require "getopts.pl";
 
+# Options:
+#	-a	show all options, not only those that are available.
+#	-m	mark unavailable options with an '*'.  Data for this is read
+#		from standard input.
+#	-s	sort entries in body.html
+&Getopts('ams');
+
+if ( defined $opt_m ) {
+	@settings_ = <STDIN>;
+	%settings_avail = ();
+	foreach $l (@settings_) {
+		chop $l;
+		if ($l =~ /^[a-zA-Z_][a-zA-Z_0-9]*$/) {
+			$settings_avail{uc $l} = 1;
+		}
+	}
+} else {
+	$opt_a = 1;
+}
+
+# This sub tells whether the support for the given setting was enabled at
+# compile time.
+sub ok {
+	local ($name) = @_;
+	local ($ret) = defined $opt_a || defined($settings_avail{uc $name})+0;
+	$ret;
+}
+
+
 if ( $#ARGV < 0 ) {
 	&doit("lynx.cfg");
 } else {
@@ -31,6 +60,7 @@ if ( $#ARGV < 0 ) {
 }
 exit (0);
 
+
 # process a Lynx configuration-file
 sub doit {
 	local ($name) = @_;
@@ -83,7 +113,7 @@ EOF
 		if ( $input[$n] =~ /^\.h2\s*[A-Z][A-Z0-9_]*$/ ) {
 			$minor[$m] = $input[$n];
 			$minor[$m] =~ s/^.h2\s*//;
-			$m++;
+			$m++ if (ok($minor[$m]) || defined $opt_a);
 		}
 	}
 	@minor = sort @minor;
@@ -104,14 +134,23 @@ EOF
 			printf FP "<h2><a name=%s>%s</a></h2>\n", $d, $d;
 			$c=$d;
 		}
-		printf FP "<a href=\"body.html#%s\">%s</a>&nbsp;&nbsp;\n", $minor[$n], $minor[$n];
+		local ($avail = ok($minor[$n]));
+		local ($mark = !$avail && defined $opt_m ? "*" : "");
+		if (defined $opt_a || $avail) {
+		    printf FP "<a href=\"body.html#%s\">%s</a>&nbsp;&nbsp;\n", $minor[$n], $minor[$n] . $mark;
+		};
 	}
-	print FP <<'EOF';
+	$str = <<'EOF'
 <p>
 <a href=cattoc.html>To list of settings by category</a>
+EOF
+. (defined $opt_a && defined $opt_m ?
+"<p>Support for all settings suffixed with '*' was disabled at compile time.\n" :
+ "") . <<'EOF'
 </body>
 </html>
 EOF
+	;print FP $str;
 	close(FP);
 }
 
@@ -148,6 +187,14 @@ EOF
 	$next = 0;
 	$left = 0;
 	undef %keys;
+
+	local (@optnames);
+	local (%optname_to_fname);#this maps optname to fname - will be used
+	    #for alphabetical output of the content
+	local ($curfilename = "tmp000");#will be incremented each time
+	local ($tmpdir = "./");#temp files will be created there
+	close(FP);
+
 	for $n (0..$#input) {
 		if ( $next ) {
 			$next--;
@@ -190,6 +237,14 @@ EOF
 		} elsif ( $c =~ /^$/ ) {
 			if ( $m > 1 ) {
 				for $j (1..$#h2) {
+					close(FP);++$curfilename;
+					push @optnames,$h2[$j];
+					open(FP,">$tmpdir/$curfilename") || do {
+						print STDERR "Can't open tmpfile: $!\n";
+						return;
+					};
+					$optname_to_fname{$h2[$j]} = $curfilename;
+
 					printf FP "<hr>\n";
 					printf FP "<h2><kbd><a name=\"%s\">%s</a></kbd>\n", $h2[$j], $h2[$j];
 					if ( $h1 ne "" ) {
@@ -205,6 +260,14 @@ EOF
 			$first = 1;
 		} elsif ( $c =~ /^[#A-Za-z]/ && $m != 0 ) {
 			if ( $first ) {
+				close(FP);++$curfilename;
+				push @optnames,$h2[0];
+				open(FP,">$tmpdir/$curfilename") || do {
+				    print STDERR "Can't open tmpfile: $!\n";
+				    return;
+				};
+				$optname_to_fname{$h2[0]} = $curfilename;
+
 				if ( $any ) {
 					printf FP "<hr>\n";
 				}
@@ -231,7 +294,8 @@ EOF
 			$c =~ s/&/&amp;/g;
 			$c =~ s/>/&gt;/g;
 			$c =~ s/</&lt;/g;
-			$c =~ s/'([^ ])'/`<strong>$1<\/strong>'/g;
+			#hvv - something wrong was with next statement
+			$c =~ s/'([^ ])'/"<strong>$1<\/strong>"/g;
 
 			# Do a line-break each time the margin changes.  We 
 			# could get fancier, but HTML doesn't really support
@@ -294,6 +358,43 @@ EOF
 			}
 		}
 	}
+	close(FP);
+	# Here we collect files with description of needed lynx.cfg
+	# options in the proper (natural or sorted) order.
+	open(FP,">>$output") || do {
+		print STDERR "Can't open $output: $!\n";
+		return;
+	};
+	{
+	    local (@ordered = (defined $opt_s ? (sort keys(%optname_to_fname)) : @optnames));
+	    if (defined $opt_s) {
+		print FP "Options are sorted by name.\n";
+	    } else {
+		print FP "Options are in the same order as lynx.cfg.\n";
+	    }
+	    foreach $l (@ordered) {
+		local ($fnm = $tmpdir . $optname_to_fname{$l});
+		open(FP1,"<$fnm") || do {
+		    print STDERR "Can't open $fnm: $!\n";
+		    return;
+		};
+		local ($avail = ok($l));
+		if (defined $opt_a || $avail) {
+		    local(@lines) = <FP1>;
+		    print FP @lines;
+		    if (!$avail && defined $opt_m) {
+			print FP <<'EOF';
+<p>Support for this setting was disabled at compile-time.
+EOF
+		    }
+		}
+		close(FP1);
+	    }
+	    foreach $l (values(%optname_to_fname)) {
+		unlink $l;
+	    }
+	}
+
 	print FP <<'EOF';
 </body>
 </html>
@@ -308,6 +409,7 @@ sub gen_cattoc {
 	local (@index);
 	local ($n, $m, $c, $d, $found, $h1);
 	local ($output="cattoc.html");
+
 	open(FP,">$output") || do {
 		print STDERR "Can't open $output: $!\n";
 		return;
@@ -358,7 +460,8 @@ EOF
 		if ( $m >= 0 && $input[$n] =~ /^\.h2\s/ ) {
 			$c = $input[$n];
 			$c =~ s/^.h2\s*//;
-			$index{$major[$m]} .= $c . "\n";
+			$index{$major[$m]} .= $c . "\n"
+			    if (defined $opt_a || ok($c));
 		}
 	}
 	@major = sort @major;
@@ -380,17 +483,24 @@ EOF
 			printf FP "<p>Here is a list of settings that belong to this category\n";
 			printf FP "<ul>\n";
 			for $m (0..$#c) {
-				printf FP "<li><a href=\"body.html#%s\">%s</a>\n", $c[$m], $c[$m];
+				local($avail = ok($c[$m]));
+				local($mark = !$avail && defined $opt_m ? "*" : "");
+				printf FP "<li><a href=\"body.html#%s\">%s</a>\n", $c[$m], $c[$m] . $mark;
 			}
 			printf FP "</ul>\n";
 		}
 	}
-	print FP <<'EOF';
+	$str = <<'EOF'
 <p>
 <a href=alphatoc.html>To list of settings by name</a>
+EOF
+. (defined $opt_a && defined $opt_m ?
+"<p>Support for all settings suffixed with '*' was disabled at compile time." :
+ "") . <<'EOF'
 </body>
 </html>
 EOF
+	;print FP $str;
 	close(FP);
 	return @cats;
 }
diff --git a/src/HTInit.c b/src/HTInit.c
index 151863b8..86b81af9 100644
--- a/src/HTInit.c
+++ b/src/HTInit.c
@@ -234,6 +234,7 @@ PRIVATE char *GetCommand ARGS2(
     char *s2;
     int quoted = 0;
 
+    s = LYSkipBlanks(s);
     /* marca -- added + 1 for error case -- oct 24, 1993. */
     s2 = malloc(strlen(s)*2 + 1); /* absolute max, if all % signs */
     if (!s2)
@@ -315,7 +316,7 @@ PRIVATE int ProcessMailcapEntry ARGS2(
 	FREE(rawentry);
 	return(0);
     }
-    s = strchr(rawentry, ';');
+    t = s = strchr(rawentry, ';');
     if (s == NULL) {
 	CTRACE((tfp, "ProcessMailcapEntry: Ignoring invalid mailcap entry: %s\n",
 		    rawentry));
@@ -323,8 +324,8 @@ PRIVATE int ProcessMailcapEntry ARGS2(
 	return(0);
     }
     *s++ = '\0';
-    if (!strncasecomp(rawentry, "text/html", 9) ||
-	!strncasecomp(rawentry, "text/plain", 10)) {
+    if (!strncasecomp(t, "text/html", 9) ||
+	!strncasecomp(t, "text/plain", 10)) {
 	--s;
 	*s = ';';
 	CTRACE((tfp, "ProcessMailcapEntry: Ignoring mailcap entry: %s\n",
@@ -358,6 +359,7 @@ PRIVATE int ProcessMailcapEntry ARGS2(
 	eq = strchr(arg, '=');
 	if (eq) {
 	    *eq++ = '\0';
+	    eq = LYSkipBlanks(eq);
 	}
 	if (arg && *arg) {
 	    arg = Cleanse(arg);
diff --git a/src/LYGlobalDefs.h b/src/LYGlobalDefs.h
index 64efc253..0ba58312 100644
--- a/src/LYGlobalDefs.h
+++ b/src/LYGlobalDefs.h
@@ -177,7 +177,6 @@ extern BOOLEAN is_www_index;
 extern BOOLEAN jump_buffer;     /* TRUE if offering default shortcut */
 extern BOOLEAN long_url_ok;
 extern BOOLEAN lynx_mode;
-extern BOOLEAN lynx_temp_subspace;
 extern BOOLEAN news_ok;
 extern BOOLEAN recent_sizechange;
 extern BOOLEAN rlogin_ok;
@@ -213,6 +212,7 @@ extern char *x_display;
 extern int display_lines;	/* number of lines in the display */
 extern int dump_output_width;
 extern int keypad_mode;		/* NUMBERS_AS_ARROWS or LINKS_ARE_NUMBERED */
+extern int lynx_temp_subspace;
 extern int more;		/* is there more document to display? */
 extern int user_mode;		/* novice or advanced */
 extern int www_search_result;
diff --git a/src/LYMain.c b/src/LYMain.c
index 8bcb1f19..b0dfcd8a 100644
--- a/src/LYMain.c
+++ b/src/LYMain.c
@@ -352,7 +352,7 @@ PUBLIC BOOLEAN traversal = FALSE;    /* Do traversals? */
 PUBLIC BOOLEAN check_realm = FALSE;  /* Restrict to the starting realm? */
 	       /* Links beyond a displayed page with no links? */
 PUBLIC BOOLEAN more_links = FALSE;
-PUBLIC BOOLEAN lynx_temp_subspace = FALSE; /* true if we made temp-directory */
+PUBLIC int lynx_temp_subspace = 0;	/* > 0 if we made temp-directory */
 PUBLIC int     ccount = 0; /* Starting number for lnk#.dat files in crawls */
 PUBLIC BOOLEAN LYCancelledFetch = FALSE; /* TRUE if cancelled binary fetch */
 	       /* Include mime headers with source dump */
@@ -397,6 +397,7 @@ PUBLIC BOOLEAN LYisConfiguredForX = FALSE;
 PUBLIC char *URLDomainPrefixes = NULL;
 PUBLIC char *URLDomainSuffixes = NULL;
 PUBLIC BOOLEAN startfile_ok = FALSE;
+PUBLIC BOOLEAN startfile_stdin = FALSE;
 PUBLIC BOOLEAN LYSelectPopups = USE_SELECT_POPUPS;
 PUBLIC BOOLEAN LYUseDefSelPop = TRUE;	/* Command line -popup toggle */
 PUBLIC BOOLEAN LYMultiBookmarks = MULTI_BOOKMARK_SUPPORT;
@@ -517,8 +518,7 @@ PRIVATE HTList *LYStdinArgs = NULL;
 PRIVATE BOOLEAN no_options_further=FALSE; /* set to TRUE after '--' argument */
 #endif
 
-
-PRIVATE void parse_arg PARAMS((char **arg, int *i));
+PRIVATE BOOL parse_arg PARAMS((char **arg, unsigned mask, int *i));
 PRIVATE void print_help_and_exit PARAMS((int exit_status));
 
 #ifndef VMS
@@ -528,7 +528,7 @@ PRIVATE void FatalProblem PARAMS((int sig));
 #endif /* !VMS */
 
 #if defined(USE_HASH)
-    char *lynx_lss_file=NULL;
+PUBLIC char *lynx_lss_file = NULL;
 #endif
 
 #ifdef __DJGPP__
@@ -719,7 +719,7 @@ unsigned char IBM1047[ 256 ] = /* ATOE OEMVS311 */
 0x8c,0x49,0xcd,0xce,0xcb,0xcf,0xcc,0xe1,0x70,0xdd,0xde,0xdb,0xdc,0x8d,0x8e,0xdf
 } ;
 
-static void FixCharacters(void)
+PRIVATE void FixCharacters(void)
 {
     int c;
     int work1[256],
@@ -737,26 +737,6 @@ static void FixCharacters(void)
 }
 #endif /* EBCDIC */
 
-/* these are used for matching commandline options. */
-PRIVATE int argcmp ARGS2(
-	char*,		str,
-	char*,		what)
-{
-    if (str[0] == '-' && str[1] == '-' ) ++str;
-#if !OPTNAME_ALLOW_DASHES
-    return strcmp(str, what);
-#else
-    ++str; ++what; /*skip leading dash in both strings*/
-    {
-	int l1 = strlen(str);
-	int l2 = strlen(what);
-	if (l1 != l2)
-	    return 1; /* this function simulates strcmp!*/
-	return !strn_dash_equ(str, what, l2);
-    }
-#endif
-}
-
 PRIVATE int argncmp ARGS2(
 	char*,		str,
 	char*,		what)
@@ -802,6 +782,17 @@ PRIVATE void tildeExpand ARGS2(
     }
 }
 
+PRIVATE BOOL GetStdin ARGS1(
+	char **,	buf)
+{
+    if (LYSafeGets(buf, stdin) != 0
+     && strncmp(*buf, "---", 3) != 0) {
+	LYTrimTrailing(*buf);
+	return TRUE;
+    }
+    return FALSE;
+}
+
 /*
  * Wow!  Someone wants to start up Lynx.
  */
@@ -920,7 +911,7 @@ PUBLIC int main ARGS2(
      */
     for (i = 1; i < argc; i++) {
 	if (argncmp(argv[i], "-help") == 0) {
-	    parse_arg(&argv[i], &i);
+	    parse_arg(&argv[i], 1, &i);
 	}
 #ifdef SH_EX
 	if (strncmp(argv[i], "-show_cfg", 9) == 0) {
@@ -1055,32 +1046,6 @@ PUBLIC int main ARGS2(
 	    FREE(temp);
 	}
     }
-    /*
-     * Verify if the given space looks secure enough.  Otherwise, make a
-     * secure subdirectory of that.  
-     */
-#if defined(UNIX) && defined(HAVE_MKTEMP)
-    {
-	struct stat sb;
-
-	if (lstat(lynx_temp_space, &sb) == 0
-	 && S_ISDIR(sb.st_mode)) {
-	    if (sb.st_uid != getuid()
-	     || (sb.st_mode & (S_IWOTH | S_IWGRP)) != 0)
-		lynx_temp_subspace = TRUE;
-	} else {
-	     lynx_temp_subspace = TRUE;
-	}
-	if (lynx_temp_subspace) {
-	    StrAllocCat(lynx_temp_space, "/XXXXXX");
-	    if (mktemp(lynx_temp_space) == 0
-	     || mkdir(lynx_temp_space, 0700) < 0) {
-		printf("%s: %s\n", lynx_temp_space, LYStrerror(errno));
-		exit(-1);
-	    }
-	}
-    }
-#endif
 #ifdef VMS
     LYLowerCase(lynx_temp_space);
     if (strchr(lynx_temp_space, '/') != NULL) {
@@ -1134,48 +1099,7 @@ PUBLIC int main ARGS2(
      *	the help menu, output that and exit. - FM
      */
     for (i = 1; i < argc; i++) {
-	if (argncmp(argv[i], "-trace") == 0) {
-	    WWW_TraceFlag = TRUE;
-	} else if (argncmp(argv[i], "-tlog") == 0) {
-	    if (LYUseTraceLog) {
-		LYUseTraceLog = FALSE;
-	    } else {
-		LYUseTraceLog = TRUE;
-	    }
-	} else if (argncmp(argv[i], "-anonymous") == 0) {
-	    if (!LYValidate)
-		parse_restrictions("default");
-	    LYRestricted = TRUE;
-	} else if (argcmp(argv[i], "-validate") == 0) {
-	    /*
-	     *	Follow only http URLs.
-	     */
-	    LYValidate = TRUE;
-#ifdef SOCKS
-	} else if (argncmp(argv[i], "-nosocks") == 0) {
-	    socks_flag = FALSE;
-#endif /* SOCKS */
-	} else if (argncmp(argv[i], "-cfg") == 0) {
-	    if (((cp = strchr(argv[i], '=')) != NULL)
-	     || ((cp = strchr(argv[i], ':')) != NULL))
-		StrAllocCopy(lynx_cfg_file, cp+1);
-	    else {
-		StrAllocCopy(lynx_cfg_file, argv[i+1]);
-		i++;
-	    }
-
-#if defined(USE_HASH)
-	} else if (argncmp(argv[i], "-lss") == 0) {
-	    if ((cp=strchr(argv[i], '=')) != NULL)
-		StrAllocCopy(lynx_lss_file, cp+1);
-	    else {
-		StrAllocCopy(lynx_lss_file, argv[i+1]);
-		i++;
-	    }
-	    CTRACE((tfp, "LYMain found -lss flag, lss file is %s\n",
-		    lynx_lss_file ? lynx_lss_file : "<NONE>"));
-#endif
-	}
+	parse_arg(&argv[i], 2, &i);
     }
 
     /*
@@ -1190,146 +1114,27 @@ PUBLIC int main ARGS2(
      *	arguments.  When interactive, the stdin input is terminated by
      *	by Control-D on Unix or Control-Z on VMS, and each argument
      *	is terminated by a RETURN.  When the argument is -get_data or
-     *	-post_data, the data are terminate by a "___" string, alone
+     *	-post_data, the data are terminated by a "---" string, alone
      *	on the line (also terminated by RETURN). - FM
      */
     for (i = 1; i < argc; i++) {
 	if (strcmp(argv[i], "-") == 0) {
 	    LYGetStdinArgs = TRUE;
+	    break;
 	}
     }
     if (LYGetStdinArgs == TRUE) {
 	char *buf = NULL;
 
 	while (LYSafeGets(&buf, stdin) != 0) {
-	    int j;
-
-	    for (j = strlen(buf) - 1; j > 0 &&
-		(buf[j] == CR || buf[j] == LF); j--) {
-		buf[j] = '\0';
-	    }
-
-	    if (argncmp(buf, "-trace") == 0) {
-		WWW_TraceFlag = TRUE;
-	    } else if (argncmp(buf, "-tlog") == 0) {
-		if (LYUseTraceLog) {
-		    LYUseTraceLog = FALSE;
-		} else {
-		    LYUseTraceLog = TRUE;
-		}
-	    } else if (argncmp(buf, "-anonymous") == 0) {
-		if (!LYValidate && !LYRestricted)
-		    parse_restrictions("default");
-		LYRestricted = TRUE;
-	    } else if (argcmp(buf, "-validate") == 0) {
-		/*
-		 *  Follow only http URLs.
-		 */
-		LYValidate = TRUE;
-#ifdef SOCKS
-	    } else if (argncmp(buf, "-nosocks") == 0) {
-		socks_flag = FALSE;
-#endif /* SOCKS */
-	    } else if (argncmp(buf, "-cfg") == 0) {
-		if ((cp = strchr(buf, '=')) != NULL) {
-		    StrAllocCopy(lynx_cfg_file, cp+1);
-		} else {
-		    cp = LYSkipNonBlanks(buf);
-		    cp = LYSkipBlanks(cp);
-		    if (*cp)
-			StrAllocCopy(lynx_cfg_file, cp);
-		}
-#if defined(USE_HASH)
-	    } else if (argncmp(buf, "-lss") == 0) {
-		if ((cp = strchr(buf, '=')) != NULL) {
-		    StrAllocCopy(lynx_lss_file, cp+1);
-		} else {
-		    cp = LYSkipNonBlanks(buf);
-		    cp = LYSkipBlanks(cp);
-		    if (*cp)
-			StrAllocCopy(lynx_lss_file, cp);
-		}
-		CTRACE((tfp, "LYMain found -lss flag, lss file is %s\n",
-			lynx_lss_file ? lynx_lss_file : "<NONE>"));
-#endif
-	    } else if (argcmp(buf, "-get_data") == 0) {
-		/*
-		 *  User data for GET form.
-		 */
-		char **get_data;
-
-		/*
-		 *  On Unix, conflicts with curses when interactive
-		 *  so let's force a dump.  - CL
-		 *
-		 *  On VMS, mods have been made in LYCurses.c to deal
-		 *  with potential conflicts, so don't force the dump
-		 *  here. - FM
-		 */
-#ifndef VMS
-		dump_output_immediately = TRUE;
-		LYcols = 80;
-#endif /* VMS */
+	    char *noargv[2];
 
-		StrAllocCopy(form_get_data, "?");   /* Prime the pump */
-		get_data = &form_get_data;
+	    noargv[0] = buf;
+	    noargv[1] = NULL;
+	    LYTrimTrailing(buf);
 
-		/*
-		 *  Build GET data for later.  Stop reading when we see
-		 *  a line with "---" as its first three characters.
-		 */
-		while (LYSafeGets(&buf, stdin) != 0 &&
-		       strncmp(buf, "---", 3) != 0) {
-		    int j2;
-
-		    /*
-		     *	Strip line terminators.
-		     */
-		    for (j2 = strlen(buf) - 1; j2 >= 0 &&
-			 (buf[j2] == CR || buf[j2] == LF); j2--) {
-			buf[j2] = '\0';
-		    }
-		    StrAllocCat(*get_data, buf);
-		}
-	    } else if (argcmp(buf, "-post_data") == 0) {
-		/*
-		 *  User data for POST form.
-		 */
-		char **post_data;
-
-		/*
-		 *  On Unix, conflicts with curses when interactive
-		 *  so let's force a dump.  - CL
-		 *
-		 *  On VMS, mods have been made in LYCurses.c to deal
-		 *  with potential conflicts, so don't force a dump
-		 *  here. - FM
-		 */
-#ifndef VMS
-		dump_output_immediately = TRUE;
-		LYcols = 80;
-#endif /* VMS */
-
-		post_data = &form_post_data;
-
-		/*
-		 *  Build post data for later.	Stop reading when we see
-		 *  a line with "---" as its first three characters.
-		 */
-		while (LYSafeGets(&buf, stdin) != 0 &&
-		       strncmp(buf, "---", 3) != 0) {
-		    int j2;
-
-		     /*
-		      *  Strip line terminators.
-		      */
-		    for (j2 = strlen(buf) - 1; j2 >= 0 &&
-			 (buf[j2] == CR || buf[j2] == LF); j2--) {
-			buf[j2] = '\0';
-		    }
-		    StrAllocCat(*post_data, buf);
-		}
-	    } else if (buf[0] != '\0') {
+	    if (parse_arg(&noargv[0], 2, (int *)0) == FALSE
+	     &&  buf[0] != '\0') {
 		char *argument = NULL;
 
 		if (LYStdinArgs == NULL) {
@@ -1583,7 +1388,7 @@ PUBLIC int main ARGS2(
      *  Process any command line arguments not already handled. - FM
      */
     for (i = 1; i < argc; i++) {
-	parse_arg(&argv[i], &i);
+	parse_arg(&argv[i], 4, &i);
     }
 
     /*
@@ -1596,11 +1401,41 @@ PUBLIC int main ARGS2(
 
 	my_args[1] = NULL;
 	while (NULL != (my_args[0] = (char *)HTList_nextObject(cur))) {
-	     parse_arg(my_args, (int *)0);
+	    parse_arg(my_args, 4, (int *)0);
 	}
 	LYStdinArgs_free();
     }
 
+#if defined (UNIX)
+    /*
+     *	If we are told to read the startfile from standard input, do it now,
+     *	after we have read all of the option data from standard input.
+     */
+    if (startfile_stdin) {
+	char result[LY_MAXPATH];
+	char *buf = NULL;
+# if HAVE_TTYNAME
+	char *tty = ttyname(fileno(stderr));
+# else
+	char *tty = "/dev/tty";
+# endif
+
+	if ((fp = LYOpenTemp (result, HTML_SUFFIX, "w")) != 0) {
+	    StrAllocCopy(startfile, result);
+	    while (GetStdin(&buf)) {
+		fputs(buf, fp);
+	    }
+	    FREE(buf);
+	    LYCloseTempFP(fp);
+	}
+	if ((freopen(tty, "r", stdin)) == 0
+	 || !isatty(fileno(stdin))) {
+	    fprintf(stderr, "cannot open a terminal (%s)\n", tty);
+	    exit(1);
+	}
+    }
+#endif
+
     /*
      *  Initialize other things based on the configuration read.
      */
@@ -2329,16 +2164,16 @@ typedef struct parse_args_type
 {
    CONST char *name;
    int type;
-#define IGNORE_ARG		0x000
-#define TOGGLE_ARG		0x001
-#define SET_ARG			0x002
-#define UNSET_ARG		0x003
-#define FUNCTION_ARG		0x004
-#define LYSTRING_ARG		0x005
-#define INT_ARG			0x006
-#define STRING_ARG		0x007
-#define ARG_TYPE_MASK		0x0FF
-#define NEED_NEXT_ARG		0x100
+
+#define TOGGLE_ARG		0x0010
+#define SET_ARG			0x0020
+#define UNSET_ARG		0x0030
+#define FUNCTION_ARG		0x0040
+#define LYSTRING_ARG		0x0050
+#define INT_ARG			0x0060
+#define STRING_ARG		0x0070
+#define ARG_TYPE_MASK		0x0FF0
+#define NEED_NEXT_ARG		0x1000
 
 #define NEED_INT_ARG		(NEED_NEXT_ARG | INT_ARG)
 #define NEED_LYSTRING_ARG	(NEED_NEXT_ARG | LYSTRING_ARG)
@@ -2355,7 +2190,7 @@ typedef struct parse_args_type
 Parse_Args_Type;
 
 /* -auth, -pauth */
-static int parse_authentication ARGS2(
+PRIVATE int parse_authentication ARGS2(
 	char *,			next_arg,
 	char **,		result)
 {
@@ -2387,32 +2222,17 @@ static int parse_authentication ARGS2(
 }
 
 /* -anonymous */
-static int anonymous_fun ARGS1(
+PRIVATE int anonymous_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
-   /*
-    *  Should already have been set, so we don't
-    *  override or replace any additional
-    *  restrictions from the command line. - FM
-    */
-    if (!LYRestricted) {
-	/* This should not happen unless the option parsing logic
-	   is broken. - kw */
-	fprintf(stderr, "Lynx: internal error parsing -anonymous!\n");
-#ifndef VMS
-	if (LYNoCore)		/* not worth a core dump, I think - kw */
-	    FatalProblem(0);
-	else
-	    exit(70);	/* EX_SOFTWARE in sysexits.h */
-#else
-	exit(-1);
-#endif
-    }
-   return 0;
+    if (!LYValidate && !LYRestricted)
+	parse_restrictions("default");
+    LYRestricted = TRUE;
+    return 0;
 }
 
 /* -assume_charset */
-static int assume_charset_fun ARGS1(
+PRIVATE int assume_charset_fun ARGS1(
 	char *,			next_arg)
 {
     UCLYhndl_for_unspec = safeUCGetLYhndl_byMIME(next_arg);
@@ -2426,7 +2246,7 @@ static int assume_charset_fun ARGS1(
 }
 
 /* -assume_local_charset */
-static int assume_local_charset_fun ARGS1(
+PRIVATE int assume_local_charset_fun ARGS1(
 	char *,			next_arg)
 {
     UCLYhndl_HTFile_for_unspec = safeUCGetLYhndl_byMIME(next_arg);
@@ -2434,7 +2254,7 @@ static int assume_local_charset_fun ARGS1(
 }
 
 /* -assume_unrec_charset */
-static int assume_unrec_charset_fun ARGS1(
+PRIVATE int assume_unrec_charset_fun ARGS1(
 	char *,			next_arg)
 {
     UCLYhndl_for_unrec = safeUCGetLYhndl_byMIME(next_arg);
@@ -2442,7 +2262,7 @@ static int assume_unrec_charset_fun ARGS1(
 }
 
 /* -auth */
-static int auth_fun ARGS1(
+PRIVATE int auth_fun ARGS1(
 	char *,			next_arg)
 {
     parse_authentication(next_arg, authentication_info);
@@ -2450,7 +2270,7 @@ static int auth_fun ARGS1(
 }
 
 /* -base */
-static int base_fun ARGS1(
+PRIVATE int base_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     /*
@@ -2470,7 +2290,7 @@ static int base_fun ARGS1(
 
 #ifdef USE_SLANG
 /* -blink */
-static int blink_fun ARGS1(
+PRIVATE int blink_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     Lynx_Color_Flags |= SL_LYNX_USE_BLINK;
@@ -2479,7 +2299,7 @@ static int blink_fun ARGS1(
 #endif
 
 /* -cache */
-static int cache_fun ARGS1(
+PRIVATE int cache_fun ARGS1(
 	char *,			next_arg)
 {
     if (next_arg != 0)
@@ -2493,7 +2313,7 @@ static int cache_fun ARGS1(
 }
 
 /* -child */
-static int child_fun ARGS1(
+PRIVATE int child_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     child_lynx = TRUE;
@@ -2503,7 +2323,7 @@ static int child_fun ARGS1(
 
 #ifdef USE_SLANG
 /* -color */
-static int color_fun ARGS1(
+PRIVATE int color_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     Lynx_Color_Flags |= SL_LYNX_USE_COLOR;
@@ -2517,7 +2337,7 @@ static int color_fun ARGS1(
 
 #ifdef MISC_EXP
 /* -convert_to */
-static int convert_to_fun ARGS1(
+PRIVATE int convert_to_fun ARGS1(
 	char *,			next_arg)
 {
     if (next_arg != 0) {
@@ -2560,7 +2380,7 @@ static int convert_to_fun ARGS1(
 #endif
 
 /* -crawl */
-static int crawl_fun ARGS1(
+PRIVATE int crawl_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     crawl = TRUE;
@@ -2569,7 +2389,7 @@ static int crawl_fun ARGS1(
 }
 
 /* -display */
-static int display_fun ARGS1(
+PRIVATE int display_fun ARGS1(
 	char *,			next_arg)
 {
     if (next_arg != 0) {
@@ -2584,7 +2404,7 @@ static int display_fun ARGS1(
 }
 
 /* -dump */
-static int dump_output_fun ARGS1(
+PRIVATE int dump_output_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     dump_output_immediately = TRUE;
@@ -2593,7 +2413,7 @@ static int dump_output_fun ARGS1(
 }
 
 /* -editor */
-static int editor_fun ARGS1(
+PRIVATE int editor_fun ARGS1(
 	char *,			next_arg)
 {
     if (next_arg != 0)
@@ -2603,7 +2423,7 @@ static int editor_fun ARGS1(
 }
 
 /* -error_file */
-static int error_file_fun ARGS1(
+PRIVATE int error_file_fun ARGS1(
 	char *,			next_arg)
 {
     /*
@@ -2617,7 +2437,7 @@ static int error_file_fun ARGS1(
 
 #if defined(EXEC_LINKS) || defined(EXEC_SCRIPTS)
 /* -exec */
-static int exec_fun ARGS1(
+PRIVATE int exec_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
 #ifndef NEVER_ALLOW_REMOTE_EXEC
@@ -2630,7 +2450,7 @@ static int exec_fun ARGS1(
 #endif
 
 /* -get_data */
-static int get_data_fun ARGS1(
+PRIVATE int get_data_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     /*
@@ -2658,14 +2478,7 @@ static int get_data_fun ARGS1(
      *  Build GET data for later.  Stop reading when we see a line
      *  with "---" as its first three characters.
      */
-    while (LYSafeGets(&buf, stdin) != 0 &&
-	  strncmp(buf, "---", 3) != 0) {
-	int j;
-
-	for (j = strlen(buf) - 1; j >= 0 && /* Strip line terminators */
-	    (buf[j] == CR || buf[j] == LF); j--)
-	    buf[j] = '\0';
-
+    while (GetStdin(&buf)) {
 	StrAllocCat(*get_data, buf);
     }
 
@@ -2673,7 +2486,7 @@ static int get_data_fun ARGS1(
 }
 
 /* -help */
-static int help_fun ARGS1(
+PRIVATE int help_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     print_help_and_exit (0);
@@ -2681,7 +2494,7 @@ static int help_fun ARGS1(
 }
 
 /* -hiddenlinks */
-static int hiddenlinks_fun ARGS1(
+PRIVATE int hiddenlinks_fun ARGS1(
 	char *,			next_arg)
 {
     if (next_arg != 0) {
@@ -2701,7 +2514,7 @@ static int hiddenlinks_fun ARGS1(
 }
 
 /* -homepage */
-static int homepage_fun ARGS1(
+PRIVATE int homepage_fun ARGS1(
 	char *,			next_arg)
 {
     if (next_arg != 0) {
@@ -2712,7 +2525,7 @@ static int homepage_fun ARGS1(
 }
 
 /* -mime_header */
-static int mime_header_fun ARGS1(
+PRIVATE int mime_header_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     /*
@@ -2728,7 +2541,7 @@ static int mime_header_fun ARGS1(
 
 #ifndef DISABLE_NEWS
 /* -newschunksize */
-static int newschunksize_fun ARGS1(
+PRIVATE int newschunksize_fun ARGS1(
 	char *,			next_arg)
 {
     if (next_arg != 0) {
@@ -2744,7 +2557,7 @@ static int newschunksize_fun ARGS1(
 }
 
 /* -newsmaxchunk */
-static int newsmaxchunk_fun ARGS1(
+PRIVATE int newsmaxchunk_fun ARGS1(
 	char *,			next_arg)
 {
     if (next_arg) {
@@ -2761,7 +2574,7 @@ static int newsmaxchunk_fun ARGS1(
 #endif /* not DISABLE_NEWS */
 
 /* -nobold */
-static int nobold_fun ARGS1(
+PRIVATE int nobold_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
    LYnoVideo(1);
@@ -2769,7 +2582,7 @@ static int nobold_fun ARGS1(
 }
 
 /* -nobrowse */
-static int nobrowse_fun ARGS1(
+PRIVATE int nobrowse_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
    HTDirAccess = HT_DIR_FORBID;
@@ -2777,7 +2590,7 @@ static int nobrowse_fun ARGS1(
 }
 
 /* -nocolor */
-static int nocolor_fun ARGS1(
+PRIVATE int nocolor_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     LYShowColor = SHOW_COLOR_NEVER;
@@ -2789,7 +2602,7 @@ static int nocolor_fun ARGS1(
 }
 
 /* -nopause */
-static int nopause_fun ARGS1(
+PRIVATE int nopause_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     InfoSecs = 0;
@@ -2799,7 +2612,7 @@ static int nopause_fun ARGS1(
 }
 
 /* -noreverse */
-static int noreverse_fun ARGS1(
+PRIVATE int noreverse_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
    LYnoVideo(2);
@@ -2807,7 +2620,7 @@ static int noreverse_fun ARGS1(
 }
 
 /* -nounderline */
-static int nounderline_fun ARGS1(
+PRIVATE int nounderline_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
    LYnoVideo(4);
@@ -2816,7 +2629,7 @@ static int nounderline_fun ARGS1(
 
 #ifdef MISC_EXP
 /* -nozap */
-static int nozap_fun ARGS1(
+PRIVATE int nozap_fun ARGS1(
 	char *,			next_arg)
 {
     LYNoZapKey = 1; /* everything but "initially" treated as "full" - kw */
@@ -2830,7 +2643,7 @@ static int nozap_fun ARGS1(
 #endif /* MISC_EXP */
 
 /* -pauth */
-static int pauth_fun ARGS1(
+PRIVATE int pauth_fun ARGS1(
 	char *,			next_arg)
 {
     parse_authentication(next_arg, proxyauth_info);
@@ -2838,7 +2651,7 @@ static int pauth_fun ARGS1(
 }
 
 /* -post_data */
-static int post_data_fun ARGS1(
+PRIVATE int post_data_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     /*
@@ -2865,21 +2678,14 @@ static int post_data_fun ARGS1(
      * Build post data for later.  Stop reading when we see a line with "---"
      * as its first three characters.
      */
-    while (LYSafeGets(&buf, stdin) != 0 &&
-	  strncmp(buf, "---", 3) != 0) {
-	int j;
-
-	for (j = strlen(buf) - 1; j >= 0 && /* Strip line terminators */
-	    (buf[j] == CR || buf[j] == LF); j--) {
-	    buf[j] = '\0';
-	}
+    while (GetStdin(&buf)) {
 	StrAllocCat(*post_data, buf);
     }
     return 0;
 }
 
 /* -restrictions */
-static int restrictions_fun ARGS1(
+PRIVATE int restrictions_fun ARGS1(
 	char *,			next_arg)
 {
     static CONST char *Usage[] = {
@@ -2990,7 +2796,7 @@ static int restrictions_fun ARGS1(
 }
 
 /* -selective */
-static int selective_fun ARGS1(
+PRIVATE int selective_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
    HTDirAccess = HT_DIR_SELECTIVE;
@@ -2998,7 +2804,7 @@ static int selective_fun ARGS1(
 }
 
 /* -source */
-static int source_fun ARGS1(
+PRIVATE int source_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     dump_output_immediately = TRUE;
@@ -3009,7 +2815,7 @@ static int source_fun ARGS1(
 }
 
 /* -traversal */
-static int traversal_fun ARGS1(
+PRIVATE int traversal_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     traversal = TRUE;
@@ -3023,7 +2829,7 @@ static int traversal_fun ARGS1(
 }
 
 /* -version */
-static int version_fun ARGS1(
+PRIVATE int version_fun ARGS1(
 	char *,			next_arg GCC_UNUSED)
 {
     SetOutputMode( O_TEXT );
@@ -3078,7 +2884,7 @@ static int version_fun ARGS1(
 }
 
 /* -width */
-static int width_fun ARGS1(
+PRIVATE int width_fun ARGS1(
 	char *,			next_arg)
 {
     if (next_arg != 0) {
@@ -3091,581 +2897,587 @@ static int width_fun ARGS1(
 }
 
 /* NOTE: This table is sorted by name to make the help message useful */
-static Parse_Args_Type Arg_Table [] =
+PRIVATE Parse_Args_Type Arg_Table [] =
 {
    PARSE_SET(
-      "accept_all_cookies", SET_ARG,		&LYAcceptAllCookies,
+      "accept_all_cookies", 4|SET_ARG,		&LYAcceptAllCookies,
       "\naccept cookies without prompting if Set-Cookie handling is on"
    ),
    PARSE_FUN(
-      "anonymous",	FUNCTION_ARG,	anonymous_fun,
+      "anonymous",	2|FUNCTION_ARG,		anonymous_fun,
       "apply restrictions for anonymous account,\nsee also -restrictions"
    ),
    PARSE_FUN(
-      "assume_charset", NEED_FUNCTION_ARG, assume_charset_fun,
+      "assume_charset", 4|NEED_FUNCTION_ARG,	assume_charset_fun,
       "=MIMEname\ncharset for documents that don't specify it"
    ),
    PARSE_FUN(
-      "assume_local_charset",	NEED_FUNCTION_ARG,assume_local_charset_fun,
+      "assume_local_charset",	4|NEED_FUNCTION_ARG,assume_local_charset_fun,
       "=MIMEname\ncharset assumed for local files"
    ),
    PARSE_FUN(
-      "assume_unrec_charset",	NEED_FUNCTION_ARG,assume_unrec_charset_fun,
+      "assume_unrec_charset",	4|NEED_FUNCTION_ARG,assume_unrec_charset_fun,
       "=MIMEname\nuse this instead of unrecognized charsets"
    ),
    PARSE_FUN(
-      "auth",		NEED_FUNCTION_ARG,	auth_fun,
+      "auth",		4|NEED_FUNCTION_ARG,	auth_fun,
       "=id:pw\nauthentication information for protected documents"
    ),
    PARSE_FUN(
-      "base",		FUNCTION_ARG,		base_fun,
+      "base",		4|FUNCTION_ARG,		base_fun,
       "prepend a request URL comment and BASE tag to text/html\noutputs for -source dumps"
    ),
 #ifdef USE_SLANG
    PARSE_FUN(
-      "blink",		FUNCTION_ARG,		blink_fun,
+      "blink",		4|FUNCTION_ARG,		blink_fun,
       "force high intensity bg colors in color mode"
    ),
 #endif
    PARSE_SET(
-      "book",		SET_ARG,		&bookmark_start,
+      "book",		4|SET_ARG,		&bookmark_start,
       "use the bookmark page as the startfile"
    ),
    PARSE_SET(
-      "buried_news",	TOGGLE_ARG,		&scan_for_buried_news_references,
+      "buried_news",	4|TOGGLE_ARG,		&scan_for_buried_news_references,
       "toggles scanning of news articles for buried references"
    ),
    PARSE_FUN(
-      "cache",		NEED_FUNCTION_ARG,	cache_fun,
+      "cache",		4|NEED_FUNCTION_ARG,	cache_fun,
       "=NUMBER\nNUMBER of documents cached in memory"
    ),
    PARSE_SET(
-      "case",		SET_ARG,		&case_sensitive,
+      "case",		4|SET_ARG,		&case_sensitive,
       "enable case sensitive user searching"
    ),
 #ifdef SH_EX
    PARSE_SET(
-      "center",		TOGGLE_ARG,	&no_table_center,
+      "center",		4|TOGGLE_ARG,		&no_table_center,
       "Toggle center alignment in HTML TABLE"
    ),
 #endif
    PARSE_STR(
-      "cfg",		IGNORE_ARG|NEED_NEXT_ARG,	0,
+      "cfg",		2|NEED_LYSTRING_ARG,	&lynx_cfg_file,
       "=FILENAME\nspecifies a lynx.cfg file other than the default"
    ),
    PARSE_FUN(
-      "child",		FUNCTION_ARG,		child_fun,
+      "child",		4|FUNCTION_ARG,		child_fun,
       "exit on left-arrow in startfile, and disable save to disk"
    ),
 #ifdef USE_SLANG
    PARSE_FUN(
-      "color",		FUNCTION_ARG,		color_fun,
+      "color",		4|FUNCTION_ARG,		color_fun,
       "force color mode on with standard bg colors"
    ),
 #endif
 #ifndef __DJGPP__
    PARSE_SET(
-      "connect_timeout", NEED_INT_ARG,		&connect_timeout,
+      "connect_timeout", 4|NEED_INT_ARG,	&connect_timeout,
       "=N\nset the N-second connection timeout"
    ),
 #endif
 #ifdef MISC_EXP
    PARSE_SET(
-      "convert_to",	FUNCTION_ARG,		convert_to_fun,
+      "convert_to",	4|FUNCTION_ARG,		convert_to_fun,
       "=FORMAT\nconvert input, FORMAT is in MIME type notation (experimental)"
    ),
 #endif
 #ifdef EXP_PERSISTENT_COOKIES
    PARSE_STR(
-      "cookie_file",	LYSTRING_ARG,		&LYCookieFile,
+      "cookie_file",	4|LYSTRING_ARG,		&LYCookieFile,
       "=FILENAME\nspecifies a file to use to read cookies"
    ),
    PARSE_STR(
-      "cookie_save_file",	LYSTRING_ARG,	&LYCookieSaveFile,
+      "cookie_save_file",	4|LYSTRING_ARG,	&LYCookieSaveFile,
       "=FILENAME\nspecifies a file to use to store cookies"
    ),
 #endif /* EXP_PERSISTENT_COOKIES */
    PARSE_SET(
-      "cookies",	TOGGLE_ARG,		&LYSetCookies,
+      "cookies",	4|TOGGLE_ARG,		&LYSetCookies,
       "toggles handling of Set-Cookie headers"
    ),
 #ifndef VMS
    PARSE_SET(
-      "core",		TOGGLE_ARG,		&LYNoCore,
+      "core",		4|TOGGLE_ARG,		&LYNoCore,
       "toggles forced core dumps on fatal errors"
    ),
 #endif
    PARSE_FUN(
-      "crawl",		FUNCTION_ARG,		crawl_fun,
+      "crawl",		4|FUNCTION_ARG,		crawl_fun,
       "with -traversal, output each page to a file\n\
 with -dump, format output as with -traversal, but to stdout"
    ),
 #ifdef DISP_PARTIAL
    PARSE_SET(
-      "debug_partial",	TOGGLE_ARG,		&debug_display_partial,
+      "debug_partial",	4|TOGGLE_ARG,		&debug_display_partial,
       "incremental display stages with MessageSecs delay"
    ),
 #endif
 #if defined(SH_EX) && defined(WIN_EX)
    PARSE_SET(
-      "delay",		NEED_INT_ARG,		&debug_delay,
+      "delay",		4|NEED_INT_ARG,		&debug_delay,
       "=NNN\nset the NNN msec delay at statusline message"
    ),
 #endif
    PARSE_FUN(
-      "display",	NEED_FUNCTION_ARG,	display_fun,
+      "display",	4|NEED_FUNCTION_ARG,	display_fun,
       "=DISPLAY\nset the display variable for X exec'ed programs"
    ),
    PARSE_SET(
-      "dont_wrap_pre",	SET_ARG,		&dont_wrap_pre,
+      "dont_wrap_pre",	4|SET_ARG,		&dont_wrap_pre,
       "inhibit wrapping of text in <pre> when -dump'ing and \n\
 -crawl'ing, mark wrapped lines in interactive session"
    ),
    PARSE_FUN(
-      "dump",		FUNCTION_ARG,		dump_output_fun,
+      "dump",		4|FUNCTION_ARG,		dump_output_fun,
       "dump the first file to stdout and exit"
    ),
    PARSE_FUN(
-      "editor",		NEED_FUNCTION_ARG,	editor_fun,
+      "editor",		4|NEED_FUNCTION_ARG,	editor_fun,
       "=EDITOR\nenable edit mode with specified editor"
    ),
    PARSE_SET(
-      "emacskeys",	SET_ARG,		&emacs_keys,
+      "emacskeys",	4|SET_ARG,		&emacs_keys,
       "enable emacs-like key movement"
    ),
    PARSE_SET(
-      "enable_scrollback", TOGGLE_ARG,		&enable_scrollback,
+      "enable_scrollback", 4|TOGGLE_ARG,	&enable_scrollback,
       "\ntoggles compatibility with comm programs' scrollback\n\
 keys (may be incompatible with some curses packages)"
    ),
    PARSE_FUN(
-      "error_file",	NEED_FUNCTION_ARG,	error_file_fun,
+      "error_file",	4|NEED_FUNCTION_ARG,	error_file_fun,
       "=FILE\nwrite the HTTP status code here"
    ),
 #if defined(EXEC_LINKS) || defined(EXEC_SCRIPTS)
 #ifndef NEVER_ALLOW_REMOTE_EXEC
    PARSE_FUN(
-      "exec",		FUNCTION_ARG,		exec_fun,
+      "exec",		4|FUNCTION_ARG,		exec_fun,
       "enable local program execution"
    ),
 #endif
 #endif /* EXEC_LINKS || EXEC_SCRIPTS */
 #ifdef VMS
    PARSE_SET(
-      "fileversions",	SET_ARG,		&HTVMSFileVersions,
+      "fileversions",	4|SET_ARG,		&HTVMSFileVersions,
       "include all versions of files in local VMS directory\nlistings"
    ),
 #endif
    PARSE_SET(
-      "force_empty_hrefless_a",	SET_ARG,	&force_empty_hrefless_a,
+      "force_empty_hrefless_a",	4|SET_ARG,	&force_empty_hrefless_a,
       "force HREF-less 'A' elements to be empty (close them as soon as they are seen)"
    ),
    PARSE_SET(
-      "force_html",	SET_ARG,		&LYforce_HTML_mode,
+      "force_html",	4|SET_ARG,		&LYforce_HTML_mode,
       "forces the first document to be interpreted as HTML"
    ),
    PARSE_SET(
-      "force_secure",	TOGGLE_ARG,		&LYForceSSLCookiesSecure,
+      "force_secure",	4|TOGGLE_ARG,		&LYForceSSLCookiesSecure,
       "toggles forcing of the secure flag for SSL cookies"
    ),
 #if !defined(NO_OPTION_FORMS) && !defined(NO_OPTION_MENU)
    PARSE_SET(
-      "forms_options",	TOGGLE_ARG,		&LYUseFormsOptions,
+      "forms_options",	4|TOGGLE_ARG,		&LYUseFormsOptions,
       "toggles forms-based vs old-style options menu"
    ),
 #endif
    PARSE_SET(
-      "from",		TOGGLE_ARG,		&LYNoFromHeader,
+      "from",		4|TOGGLE_ARG,		&LYNoFromHeader,
       "toggle transmission of From headers"
    ),
    PARSE_SET(
-      "ftp",		UNSET_ARG,		&ftp_ok,
+      "ftp",		4|UNSET_ARG,		&ftp_ok,
       "disable ftp access"
    ),
    PARSE_FUN(
-      "get_data",	FUNCTION_ARG,		get_data_fun,
+      "get_data",	6|FUNCTION_ARG,		get_data_fun,
       "user data for get forms, read from stdin,\nterminated by '---' on a line"
    ),
    PARSE_SET(
-      "head",		SET_ARG,		&HEAD_request,
+      "head",		4|SET_ARG,		&HEAD_request,
       "send a HEAD request"
    ),
    PARSE_FUN(
-      "help",		FUNCTION_ARG,		help_fun,
+      "help",		5|FUNCTION_ARG,		help_fun,
       "print this usage message"
    ),
    PARSE_FUN(
-      "hiddenlinks",	NEED_FUNCTION_ARG,	hiddenlinks_fun,
+      "hiddenlinks",	4|NEED_FUNCTION_ARG,	hiddenlinks_fun,
       "=[option]\nhidden links: options are merge, listonly, or ignore"
    ),
    PARSE_SET(
-      "historical",	TOGGLE_ARG,		&historical_comments,
+      "historical",	4|TOGGLE_ARG,		&historical_comments,
       "toggles use of '>' or '-->' as a terminator for comments"
    ),
    PARSE_FUN(
-      "homepage",	NEED_FUNCTION_ARG,	homepage_fun,
+      "homepage",	4|NEED_FUNCTION_ARG,	homepage_fun,
       "=URL\nset homepage separate from start page"
    ),
    PARSE_SET(
-      "image_links",	TOGGLE_ARG,		&clickable_images,
+      "image_links",	4|TOGGLE_ARG,		&clickable_images,
       "toggles inclusion of links for all images"
    ),
    PARSE_STR(
-      "index",		NEED_LYSTRING_ARG,	&indexfile,
+      "index",		4|NEED_LYSTRING_ARG,	&indexfile,
       "=URL\nset the default index file to URL"
    ),
    PARSE_SET(
-      "ismap",		TOGGLE_ARG,		&LYNoISMAPifUSEMAP,
+      "ismap",		4|TOGGLE_ARG,		&LYNoISMAPifUSEMAP,
       "toggles inclusion of ISMAP links when client-side\nMAPs are present"
    ),
 #ifdef EXP_JUSTIFY_ELTS
    PARSE_SET(
-      "justify",	SET_ARG,		&ok_justify,
+      "justify",	4|SET_ARG,		&ok_justify,
       "do justification of text"
    ),
 #endif
    PARSE_INT(
-      "link",		NEED_INT_ARG,		&ccount,
+      "link",		4|NEED_INT_ARG,		&ccount,
       "=NUMBER\nstarting count for lnk#.dat files produced by -crawl"
    ),
    PARSE_SET(
-      "localhost",	SET_ARG,		&local_host_only,
+      "localhost",	4|SET_ARG,		&local_host_only,
       "disable URLs that point to remote hosts"
    ),
 #if defined(EXEC_LINKS) || defined(EXEC_SCRIPTS)
    PARSE_SET(
-      "locexec",	SET_ARG,		&local_exec_on_local_files,
+      "locexec",	4|SET_ARG,		&local_exec_on_local_files,
       "enable local program execution from local files only"
    ),
 #endif /* EXEC_LINKS || EXEC_SCRIPTS */
 #if defined(USE_HASH)
    PARSE_STR(
-      "lss",		IGNORE_ARG|NEED_NEXT_ARG,	0,
+      "lss",		2|NEED_LYSTRING_ARG,	&lynx_lss_file,
       "=FILENAME\nspecifies a lynx.lss file other than the default"
    ),
 #endif
    PARSE_FUN(
-      "mime_header",	FUNCTION_ARG,		mime_header_fun,
+      "mime_header",	4|FUNCTION_ARG,		mime_header_fun,
       "include mime headers and force source dump"
    ),
    PARSE_SET(
-      "minimal",	TOGGLE_ARG,		&minimal_comments,
+      "minimal",	4|TOGGLE_ARG,		&minimal_comments,
       "toggles minimal versus valid comment parsing"
    ),
 #ifndef DISABLE_NEWS
 #endif
 #ifndef DISABLE_NEWS
    PARSE_FUN(
-      "newschunksize",	NEED_FUNCTION_ARG,	newschunksize_fun,
+      "newschunksize",	4|NEED_FUNCTION_ARG,	newschunksize_fun,
       "=NUMBER\nnumber of articles in chunked news listings"
    ),
    PARSE_FUN(
-      "newsmaxchunk",	NEED_FUNCTION_ARG,	newsmaxchunk_fun,
+      "newsmaxchunk",	4|NEED_FUNCTION_ARG,	newsmaxchunk_fun,
       "=NUMBER\nmaximum news articles in listings before chunking"
    ),
 #endif
 #if USE_BLAT_MAILER
    PARSE_SET(
-      "noblat",		TOGGLE_ARG,		&mail_is_blat,
+      "noblat",		4|TOGGLE_ARG,		&mail_is_blat,
       "select mail tool (`BLAT' ==> `sendmail')"
    ),
 #endif
    PARSE_FUN(
-      "nobold",		FUNCTION_ARG,		nobold_fun,
+      "nobold",		4|FUNCTION_ARG,		nobold_fun,
       "disable bold video-attribute"
    ),
    PARSE_FUN(
-      "nobrowse",	FUNCTION_ARG,		nobrowse_fun,
+      "nobrowse",	4|FUNCTION_ARG,		nobrowse_fun,
       "disable directory browsing"
    ),
    PARSE_SET(
-      "nocc",		SET_ARG,		&LYNoCc,
+      "nocc",		4|SET_ARG,		&LYNoCc,
       "disable Cc: prompts for self copies of mailings"
    ),
    PARSE_FUN(
-      "nocolor",	FUNCTION_ARG,		nocolor_fun,
+      "nocolor",	4|FUNCTION_ARG,		nocolor_fun,
       "turn off color support"
    ),
 #if defined(EXEC_LINKS) || defined(EXEC_SCRIPTS)
    PARSE_SET(
-      "noexec",		UNSET_ARG,		&local_exec,
+      "noexec",		4|UNSET_ARG,		&local_exec,
       "disable local program execution (DEFAULT)"
    ),
 #endif /* EXEC_LINKS || EXEC_SCRIPTS */
    PARSE_SET(
-      "nofilereferer",	SET_ARG,		&no_filereferer,
+      "nofilereferer",	4|SET_ARG,		&no_filereferer,
       "disable transmission of Referer headers for file URLs"
    ),
    PARSE_SET(
-      "nolist",		SET_ARG,		&nolist,
+      "nolist",		4|SET_ARG,		&nolist,
       "disable the link list feature in dumps"
    ),
    PARSE_SET(
-      "nolog",		UNSET_ARG,		&error_logging,
+      "nolog",		4|UNSET_ARG,		&error_logging,
       "disable mailing of error messages to document owners"
    ),
 #if HAVE_SIGACTION && defined(SIGWINCH)
    PARSE_SET(
-      "nonrestarting_sigwinch", SET_ARG,	&LYNonRestartingSIGWINCH,
+      "nonrestarting_sigwinch", 4|SET_ARG,	&LYNonRestartingSIGWINCH,
       "make window size change handler non-restarting"
    ),
 #endif /* HAVE_SIGACTION */
    PARSE_FUN(
-      "nopause",	FUNCTION_ARG,		nopause_fun,
+      "nopause",	4|FUNCTION_ARG,		nopause_fun,
       "disable forced pauses for statusline messages"
    ),
    PARSE_SET(
-      "noprint",	SET_ARG,		&no_print,
+      "noprint",	4|SET_ARG,		&no_print,
       "disable some print functions, like -restrictions=print"
    ),
    PARSE_SET(
-      "noredir",	SET_ARG,		&no_url_redirection,
+      "noredir",	4|SET_ARG,		&no_url_redirection,
       "don't follow Location: redirection"
    ),
    PARSE_SET(
-      "noreferer",	SET_ARG,		&LYNoRefererHeader,
+      "noreferer",	4|SET_ARG,		&LYNoRefererHeader,
       "disable transmission of Referer headers"
    ),
    PARSE_FUN(
-      "noreverse",	FUNCTION_ARG,		noreverse_fun,
+      "noreverse",	4|FUNCTION_ARG,		noreverse_fun,
       "disable reverse video-attribute"
    ),
 #ifdef SOCKS
    PARSE_SET(
-      "nosocks",	UNSET_ARG,		&socks_flag,
+      "nosocks",	6|UNSET_ARG,		&socks_flag,
       "don't use SOCKS proxy for this session"
    ),
 #endif
    PARSE_SET(
-      "nostatus",	SET_ARG,		&no_statusline,
+      "nostatus",	4|SET_ARG,		&no_statusline,
       "disable the miscellaneous information messages"
    ),
    PARSE_FUN(
-      "nounderline",	FUNCTION_ARG,		nounderline_fun,
+      "nounderline",	4|FUNCTION_ARG,		nounderline_fun,
       "disable underline video-attribute"
    ),
 #ifdef MISC_EXP
    PARSE_FUN(
-      "nozap",		FUNCTION_ARG,		nozap_fun,
+      "nozap",		4|FUNCTION_ARG,		nozap_fun,
       "=DURATION (\"initially\" or \"full\") disable checks for 'z' key"
    ),
 #endif
    PARSE_SET(
-      "number_fields",	SET_ARG,		&number_fields,
+      "number_fields",	4|SET_ARG,		&number_fields,
       "force numbering of links as well as form input fields"
    ),
    PARSE_SET(
-      "number_links",	SET_ARG,		&number_links,
+      "number_links",	4|SET_ARG,		&number_links,
       "force numbering of links"
    ),
 #ifdef DISP_PARTIAL
    PARSE_SET(
-      "partial",	TOGGLE_ARG,		&display_partial_flag,
+      "partial",	4|TOGGLE_ARG,		&display_partial_flag,
       "toggles display partial pages while downloading"
    ),
    PARSE_INT(
-      "partial_thres",	NEED_INT_ARG,		&partial_threshold,
+      "partial_thres",	4|NEED_INT_ARG,		&partial_threshold,
       "[=NUMBER]\nnumber of lines to render before repainting display\n\
 with partial-display logic"
    ),
 #endif
    PARSE_FUN(
-      "pauth",		NEED_FUNCTION_ARG,	pauth_fun,
+      "pauth",		4|NEED_FUNCTION_ARG,	pauth_fun,
       "=id:pw\nauthentication information for protected proxy server"
    ),
    PARSE_SET(
-      "popup",		UNSET_ARG,		&LYUseDefSelPop,
+      "popup",		4|UNSET_ARG,		&LYUseDefSelPop,
       "toggles handling of single-choice SELECT options via\npopup windows or as lists of radio buttons"
    ),
    PARSE_FUN(
-      "post_data",	FUNCTION_ARG,		post_data_fun,
+      "post_data",	6|FUNCTION_ARG,		post_data_fun,
       "user data for post forms, read from stdin,\nterminated by '---' on a line"
    ),
    PARSE_SET(
-      "preparsed",	SET_ARG,		&LYPreparsedSource,
+      "preparsed",	4|SET_ARG,		&LYPreparsedSource,
       "show parsed text/html with -source and in source view\n\
 to visualize how lynx behaves with invalid HTML"
    ),
 #ifdef USE_PRETTYSRC
    PARSE_SET(
-      "prettysrc",	SET_ARG,		&LYpsrc,
+      "prettysrc",	4|SET_ARG,		&LYpsrc,
       "do syntax highlighting and hyperlink handling in source view"
    ),
 #endif
    PARSE_SET(
-      "print",		UNSET_ARG,		&no_print,
+      "print",		4|UNSET_ARG,		&no_print,
       "enable print functions (DEFAULT), opposite of -noprint"
    ),
    PARSE_SET(
-      "pseudo_inlines", TOGGLE_ARG,		&pseudo_inline_alts,
+      "pseudo_inlines", 4|TOGGLE_ARG,		&pseudo_inline_alts,
       "toggles pseudo-ALTs for inlines with no ALT string"
    ),
    PARSE_SET(
-      "raw",		UNSET_ARG,		&LYUseDefaultRawMode,
+      "raw",		4|UNSET_ARG,		&LYUseDefaultRawMode,
       "toggles default setting of 8-bit character translations\n\
 or CJK mode for the startup character set"
    ),
    PARSE_SET(
-      "realm",		SET_ARG,		&check_realm,
+      "realm",		4|SET_ARG,		&check_realm,
       "restricts access to URLs in the starting realm"
    ),
    PARSE_SET(
-      "reload",		SET_ARG,		&reloading,
+      "reload",		4|SET_ARG,		&reloading,
       "flushes the cache on a proxy server\n(only the first document affected)"
    ),
    PARSE_FUN(
-      "restrictions",	FUNCTION_ARG,		restrictions_fun,
+      "restrictions",	4|FUNCTION_ARG,		restrictions_fun,
       "=[options]\nuse -restrictions to see list"
    ),
    PARSE_SET(
-      "resubmit_posts", TOGGLE_ARG,		&LYresubmit_posts,
+      "resubmit_posts", 4|TOGGLE_ARG,		&LYresubmit_posts,
       "toggles forced resubmissions (no-cache) of forms with\n\
 method POST when the documents they returned are sought\n\
 with the PREV_DOC command or from the History List"
    ),
    PARSE_SET(
-      "rlogin",		UNSET_ARG,		&rlogin_ok,
+      "rlogin",		4|UNSET_ARG,		&rlogin_ok,
       "disable rlogins"
    ),
 #ifdef USE_SCROLLBAR
    PARSE_SET(
-      "scrollbar",	TOGGLE_ARG,		&LYsb,
+      "scrollbar",	4|TOGGLE_ARG,		&LYsb,
       "toggles showing scrollbar (requires color styles)"
    ),
    PARSE_SET(
-      "scrollbar_arrow", TOGGLE_ARG,		&LYsb_arrow,
+      "scrollbar_arrow", 4|TOGGLE_ARG,		&LYsb_arrow,
       "toggles showing arrows at ends of the scrollbar"
    ),
 #endif
    PARSE_FUN(
-      "selective",	FUNCTION_ARG,		selective_fun,
+      "selective",	4|FUNCTION_ARG,		selective_fun,
       "require .www_browsable files to browse directories"
    ),
    PARSE_SET(
-      "short_url",	SET_ARG,		&long_url_ok,
+      "short_url",	4|SET_ARG,		&long_url_ok,
       "enables examination of beginning and end of long URL in status line"
    ),
 #ifdef SH_EX
    PARSE_SET(
-      "show_cfg",	SET_ARG,		&show_cfg,
+      "show_cfg",	4|SET_ARG,		&show_cfg,
       "Show `LYNX.CFG' setting"
    ),
 #endif
    PARSE_SET(
-      "show_cursor",	TOGGLE_ARG,		&LYUseDefShoCur,
+      "show_cursor",	4|TOGGLE_ARG,		&LYUseDefShoCur,
       "toggles hiding of the cursor in the lower right corner"
    ),
    PARSE_SET(
-      "soft_dquotes",	TOGGLE_ARG,		&soft_dquotes,
+      "soft_dquotes",	4|TOGGLE_ARG,		&soft_dquotes,
       "toggles emulation of the old Netscape and Mosaic bug which\n\
 treated '>' as a co-terminator for double-quotes and tags"
    ),
    PARSE_FUN(
-      "source",		FUNCTION_ARG,		source_fun,
+      "source",		4|FUNCTION_ARG,		source_fun,
       "dump the source of the first file to stdout and exit"
    ),
    PARSE_SET(
-      "stack_dump",	SET_ARG,		&stack_dump,
+      "stack_dump",	4|SET_ARG,		&stack_dump,
       "disable SIGINT cleanup handler"
    ),
    PARSE_SET(
-      "startfile_ok",	SET_ARG,		&startfile_ok,
+      "startfile_ok",	4|SET_ARG,		&startfile_ok,
       "allow non-http startfile and homepage with -validate"
    ),
+#if defined (UNIX)
+   PARSE_SET(
+      "stdin",		4|SET_ARG,		&startfile_stdin,
+      "read startfile from standard input"
+   ),
+#endif
 #ifndef VMS
 #ifdef SYSLOG_REQUESTED_URLS
    PARSE_STR(
-      "syslog",		NEED_LYSTRING_ARG,	&syslog_txt,
+      "syslog",		4|NEED_LYSTRING_ARG,	&syslog_txt,
       "=text\ninformation for syslog call"
    ),
 #endif
 #endif
    PARSE_SET(
-      "tagsoup",	SET_ARG,		&Old_DTD,
+      "tagsoup",	4|SET_ARG,		&Old_DTD,
       "use TagSoup rather than SortaSGML parser"
    ),
    PARSE_SET(
-      "telnet",		UNSET_ARG,		&telnet_ok,
+      "telnet",		4|UNSET_ARG,		&telnet_ok,
       "disable telnets"
    ),
    PARSE_STR(
-      "term",		NEED_STRING_ARG,	&terminal,
+      "term",		4|NEED_STRING_ARG,	&terminal,
       "=TERM\nset terminal type to TERM"
    ),
 #ifdef _WINDOWS
    PARSE_SET(
-      "timeout",	SET_ARG,		&lynx_timeout,
+      "timeout",	4|SET_ARG,		&lynx_timeout,
       "set TCP/IP timeout"
    ),
 #endif
    PARSE_SET(
-      "tlog",		IGNORE_ARG,		0,
+      "tlog",		2|TOGGLE_ARG,		&LYUseTraceLog,
       "toggles use of a Lynx Trace Log for the current session"
    ),
 #ifdef TEXTFIELDS_MAY_NEED_ACTIVATION
    PARSE_SET(
-      "tna",		SET_ARG,		&textfields_need_activation,
+      "tna",		4|SET_ARG,		&textfields_need_activation,
       "turn on \"Textfields Need Activation\" mode"
    ),
 #endif
    PARSE_SET(
-      "trace",		IGNORE_ARG,		0,
+      "trace",		2|SET_ARG,		&WWW_TraceFlag,
       "turns on Lynx trace mode"
    ),
    PARSE_FUN(
-      "traversal",	FUNCTION_ARG,		traversal_fun,
+      "traversal",	4|FUNCTION_ARG,		traversal_fun,
       "traverse all http links derived from startfile"
    ),
    PARSE_SET(
-      "underscore",	TOGGLE_ARG,		&use_underscore,
+      "underscore",	4|TOGGLE_ARG,		&use_underscore,
       "toggles use of _underline_ format in dumps"
    ),
 #if defined(USE_MOUSE)
    PARSE_SET(
-      "use_mouse",	SET_ARG,		&LYUseMouse,
+      "use_mouse",	4|SET_ARG,		&LYUseMouse,
       "turn on mouse support"
    ),
 #endif
    PARSE_STR(
-      "useragent",	NEED_LYSTRING_ARG,	&LYUserAgent,
+      "useragent",	4|NEED_LYSTRING_ARG,	&LYUserAgent,
       "=Name\nset alternate Lynx User-Agent header"
    ),
    PARSE_SET(
-      "validate",	IGNORE_ARG,		0,
+      "validate",	2|SET_ARG,		&LYValidate,
       "accept only http URLs (meant for validation)\nimplies more restrictions than -anonymous, but\ngoto is allowed for http and https"
    ),
    PARSE_SET(
-      "verbose",	TOGGLE_ARG,		&verbose_img,
+      "verbose",	4|TOGGLE_ARG,		&verbose_img,
       "toggles [LINK], [IMAGE] and [INLINE] comments \nwith filenames of these images"
    ),
    PARSE_FUN(
-      "version",	FUNCTION_ARG,		version_fun,
+      "version",	4|FUNCTION_ARG,		version_fun,
       "print Lynx version information"
    ),
    PARSE_SET(
-      "vikeys",		SET_ARG,		&vi_keys,
+      "vikeys",		4|SET_ARG,		&vi_keys,
       "enable vi-like key movement"
    ),
 #ifdef __DJGPP__
    PARSE_SET(
-      "wdebug",		TOGGLE_ARG,		&watt_debug,
+      "wdebug",		4|TOGGLE_ARG,		&watt_debug,
       "enables Waterloo tcp/ip packet debug. Prints to watt debugfile"
   ),
 #endif /* __DJGPP__ */
    PARSE_FUN(
-      "width",		NEED_FUNCTION_ARG,	width_fun,
+      "width",		4|NEED_FUNCTION_ARG,	width_fun,
       "=NUMBER\nscreen width for formatting of dumps (default is 80)"
    ),
 #ifndef NO_DUMP_WITH_BACKSPACES
    PARSE_SET(
-      "with_backspaces",	SET_ARG,		&with_backspaces,
+      "with_backspaces", 4|SET_ARG,		&with_backspaces,
       "emit backspaces in output if -dumping or -crawling (like 'man' does)"
    ),
 #endif
    {NULL, 0, 0, NULL}
 };
 
-static void print_help_strings ARGS3(
+PRIVATE void print_help_strings ARGS3(
 	CONST char *,	name,
 	CONST char *,	help,
 	CONST char *,	value)
@@ -3716,7 +3528,7 @@ static void print_help_strings ARGS3(
     fputc ('\n', stdout);
 }
 
-static void print_help_and_exit ARGS1(int, exit_status)
+PRIVATE void print_help_and_exit ARGS1(int, exit_status)
 {
     Parse_Args_Type *p;
 
@@ -3777,7 +3589,7 @@ in double-quotes (\"-\") on VMS)", NULL);
  * be pointed to that character.  (+/- added for toggle processing - BL.)
  * If a and b match, it returns 1.  Otherwise 0 is returned.
  */
-static int arg_eqs_parse ARGS3(
+PRIVATE int arg_eqs_parse ARGS3(
 	CONST char *,	a,
 	char *,		b,
 	char **,	c)
@@ -3817,8 +3629,9 @@ static int arg_eqs_parse ARGS3(
 #define is_true(s)  (*s == '1' || *s == '+' || !strcmp(s, "on"))
 #define is_false(s) (*s == '0' || *s == '-' || !strcmp(s, "off"))
 
-PRIVATE void parse_arg ARGS2(
+PRIVATE BOOL parse_arg ARGS3(
 	char **,	argv,
+	unsigned,	mask,
 	int *,		i)
 {
     Parse_Args_Type *p;
@@ -3858,12 +3671,12 @@ PRIVATE void parse_arg ARGS2(
 	    }
 	}
 #endif
-	return;
+	return TRUE;
     }
 #if EXTENDED_OPTION_LOGIC
     if (strcmp(arg_name,"--") == 0) {
 	no_options_further = TRUE;
-	return;
+	return TRUE;
     }
 #endif
 
@@ -3876,7 +3689,7 @@ PRIVATE void parse_arg ARGS2(
      *	special handling. - FM
      */
     if (*arg_name == 0)
-	return;
+	return TRUE;
 
     /* allow GNU-style options with -- prefix*/
     if (*arg_name == '-') ++arg_name;
@@ -3904,6 +3717,10 @@ PRIVATE void parse_arg ARGS2(
 		(*i)++;
 	}
 
+	/* ignore option if it's not our turn */
+	if ((p->type & mask) == 0)
+	    return FALSE;
+
 	switch (p->type & ARG_TYPE_MASK) {
 	case TOGGLE_ARG:	/* FALLTHRU */
 	case SET_ARG:		/* FALLTHRU */
@@ -3952,18 +3769,16 @@ PRIVATE void parse_arg ARGS2(
 	     if ((q->str_value != 0) && (next_arg != 0))
 		*(q->str_value) = next_arg;
 	     break;
-
-	case IGNORE_ARG:
-	     break;
 	}
 
-	return;
+	return TRUE;
     }
 
     if (pgm == 0) pgm = "LYNX";
 
     fprintf (stderr, gettext("%s: Invalid Option: %s\n"), pgm, argv[0]);
     print_help_and_exit (-1);
+    return FALSE;
 }
 
 #ifndef VMS
diff --git a/src/LYReadCFG.c b/src/LYReadCFG.c
index d905a32b..ddaec6cd 100644
--- a/src/LYReadCFG.c
+++ b/src/LYReadCFG.c
@@ -1567,9 +1567,9 @@ static Config_Type Config_Table [] =
      PARSE_SET("use_mouse", CONF_BOOL, &LYUseMouse),
 #endif
      PARSE_SET("use_select_popups", CONF_BOOL, &LYSelectPopups),
-     PARSE_FUN("viewer", CONF_FUN, viewer_fun),
      PARSE_SET("verbose_images", CONF_BOOL, &verbose_img),
      PARSE_SET("vi_keys_always_on", CONF_BOOL, &vi_keys),
+     PARSE_FUN("viewer", CONF_FUN, viewer_fun),
      PARSE_ENV("wais_proxy", CONF_ENV, 0 ),
      PARSE_STR("xloadimage_command", CONF_STR, &XLoadImageCommand),
 
diff --git a/src/LYUtils.c b/src/LYUtils.c
index 89767250..bf3287a3 100644
--- a/src/LYUtils.c
+++ b/src/LYUtils.c
@@ -52,13 +52,17 @@ extern int exec_command(char * cmd, int wait_flag); /* xsystem.c */
 #ifdef UTMPX_FOR_UTMP
 #include <utmpx.h>
 #define utmp utmpx
+#ifdef UTMPX_FILE
 #ifdef UTMP_FILE
 #undef UTMP_FILE
 #endif /* UTMP_FILE */
-#ifdef    UTMPX_FILE
 #define UTMP_FILE UTMPX_FILE
 #else
+#ifdef __UTMPX_FILE
 #define UTMP_FILE __UTMPX_FILE  /* at least in OS/390  S/390 -- gil -- 2100 */
+#else
+#define UTMP_FILE "/var/adm/utmpx" /* Digital Unix 4.0 */
+#endif
 #endif /* UTMPX_FILE */
 #else
 #include <utmp.h>
@@ -3168,42 +3172,42 @@ extern char *ttyname PARAMS((int fd));
  */
 PUBLIC BOOLEAN inlocaldomain NOARGS
 {
-#if ! HAVE_UTMP
-    CTRACE((tfp, "LYUtils: inlocaldomain() not support.\n"));
-    return(TRUE);
-#else
+#if HAVE_UTMP
     int n;
     FILE *fp;
     struct utmp me;
     char *cp, *mytty = NULL;
 
-    if ((cp=ttyname(0)))
+    if ((cp = ttyname(0)))
 	mytty = strrchr(cp, '/');
 
-    if (mytty && (fp=fopen(UTMP_FILE, "r")) != NULL) {
-	    mytty++;
-	    do {
-		n = fread((char *) &me, sizeof(struct utmp), 1, fp);
-	    } while (n>0 && !STREQ(me.ut_line,mytty));
-	    (void) fclose(fp);
-
-	    if (n > 0 &&
-		strlen(me.ut_host) > strlen(LYLocalDomain) &&
-		STREQ(LYLocalDomain,
-		  me.ut_host+strlen(me.ut_host)-strlen(LYLocalDomain)) )
-		return(TRUE);
+    if (mytty && (fp = fopen(UTMP_FILE, "r")) != NULL) {
+	mytty++;
+	do {
+	    n = fread((char *) &me, sizeof(struct utmp), 1, fp);
+	} while (n > 0 && !STREQ(me.ut_line, mytty));
+	(void) fclose(fp);
+
+	if (n > 0 &&
+	    strlen(me.ut_host) > strlen(LYLocalDomain) &&
+	    STREQ(LYLocalDomain,
+		  me.ut_host + strlen(me.ut_host) - strlen(LYLocalDomain)) )
+	    return(TRUE);
 #ifdef LINUX
 /* Linux fix to check for local user. J.Cullen 11Jul94		*/
-	    if ((n > 0) && (strlen(me.ut_host) == 0))
-		return(TRUE);
+	if ((n > 0) && (strlen(me.ut_host) == 0))
+	    return(TRUE);
 #endif /* LINUX */
 
     } else {
-	CTRACE((tfp,"Could not get ttyname or open UTMP file %s\n", UTMP_FILE));
+	CTRACE((tfp, "Could not get ttyname or open UTMP file %s\n", UTMP_FILE));
     }
 
     return(FALSE);
-#endif /* !HAVE_UTMP */
+#else
+    CTRACE((tfp, "LYUtils: inlocaldomain() not support.\n"));
+    return(TRUE);
+#endif /* HAVE_UTMP */
 }
 
 #if HAVE_SIGACTION
@@ -6455,6 +6459,46 @@ PUBLIC FILE *LYOpenTemp ARGS3(
 	}
     }
 
+    /*
+     * Verify if the given space looks secure enough.  Otherwise, make a
+     * secure subdirectory of that.
+     */
+#if defined(UNIX) && defined(HAVE_MKTEMP)
+    if (lynx_temp_subspace == 0)
+    {
+	BOOL make_it = FALSE;
+	struct stat sb;
+
+	if (lstat(lynx_temp_space, &sb) == 0
+	 && S_ISDIR(sb.st_mode)) {
+	    if (sb.st_uid != getuid()
+	     || (sb.st_mode & (S_IWOTH | S_IWGRP)) != 0) {
+		make_it = TRUE;
+		CTRACE((tfp, "lynx_temp_space is not our directory %s owner %d mode %03o\n",
+			     lynx_temp_space, sb.st_uid, sb.st_mode & 0777));
+	    }
+	} else {
+	    make_it = TRUE;
+	    CTRACE((tfp, "lynx_temp_space is not a directory %s\n", lynx_temp_space));
+	}
+	if (make_it) {
+	    int old_mask = umask(HIDE_UMASK);
+	    StrAllocCat(lynx_temp_space, "XXXXXX");
+	    if (mktemp(lynx_temp_space) == 0
+	     || mkdir(lynx_temp_space, 0700) < 0) {
+		printf("%s: %s\n", lynx_temp_space, LYStrerror(errno));
+		exit(-1);
+	    }
+	    umask(old_mask);
+	    lynx_temp_subspace = 1;
+	    StrAllocCat(lynx_temp_space, "/");
+	    CTRACE((tfp, "made subdirectory %s\n", lynx_temp_space));
+	} else {
+	    lynx_temp_subspace = -1;
+	}
+    }
+#endif
+
     do {
 	if (!fmt_tempname(result, lynx_temp_space, suffix))
 	    return 0;
@@ -6782,13 +6826,13 @@ PUBLIC void LYCleanupTemp NOARGS
 	LYRemoveTemp(ly_temp->name);
     }
 #ifdef UNIX
-    if (lynx_temp_subspace) {
+    if (lynx_temp_subspace > 0) {
 	char result[LY_MAXPATH];
 	LYstrncpy(result, lynx_temp_space, sizeof(result)-1);
 	LYTrimPathSep(result);
 	CTRACE((tfp, "LYCleanupTemp removing %s\n", result));
 	rmdir(result);
-	lynx_temp_subspace = FALSE;
+	lynx_temp_subspace = -1;
     }
 #endif
 }
diff --git a/src/makefile.in b/src/makefile.in
index d655a462..53ea0b33 100644
--- a/src/makefile.in
+++ b/src/makefile.in
@@ -105,7 +105,7 @@ lint:
 	$(LINT) $(LINTOPTS) $(CPP_OPTS) *.c  > $(top_builddir)/lint.lynx
 
 clean:
-	rm -f lynx$x core *.core *.leaks *.[ob] *.bak
+	rm -f lynx$x core *.core *.leaks *.[oi] *.bak
 	cd chrtrans && $(MAKE) clean
 
 distclean: clean
diff --git a/userdefs.h b/userdefs.h
index 5355b27b..cd533d67 100644
--- a/userdefs.h
+++ b/userdefs.h
@@ -1339,11 +1339,11 @@
  * the version definition with the Project Version on checkout.  Just
  * ignore it. - kw */
 /* $Format: "#define LYNX_VERSION \"$ProjectVersion$\""$ */
-#define LYNX_VERSION "2.8.4dev.1"
+#define LYNX_VERSION "2.8.4dev.2"
 #define LYNX_WWW_HOME "http://lynx.browser.org/"
 #define LYNX_WWW_DIST "http://lynx.isc.org/current/"
 /* $Format: "#define LYNX_DATE \"$ProjectDate$\""$ */
-#define LYNX_DATE "Fri, 05 May 2000 07:01:56 -0700"
+#define LYNX_DATE "Sun, 21 May 2000 20:04:05 -0700"
 #define LYNX_DATE_OFF 5		/* truncate the automatically-generated date */
 #define LYNX_DATE_LEN 11	/* truncate the automatically-generated date */