Changeset caed8e0 in clfs-sysroot


Ignore:
Timestamp:
Jul 9, 2009, 6:40:13 PM (15 years ago)
Author:
Joe Ciccone <jciccone@…>
Branches:
master
Children:
ceca635c
Parents:
cba3e93
Message:

Add patch.

File:
1 moved

Legend:

Unmodified
Added
Removed
  • patches/ncurses-5.7-branch_update-14.patch

    rcba3e93 rcaed8e0  
    11Submitted By: Jim Gifford (jim at cross-lfs dot org)
    2 Date: 02-28-2009
     2Date: 06-05-2009
    33Initial Package Version: 5.7
    44Origin: Upstream
    55Upstream Status: Applied
    66Description: This is a branch update for NCurses-5.7, and should be
    7              rechecked periodically. This patch covers up to 5.7-20090228.
     7             rechecked periodically. This patch covers up to 5.7-20090530.
    88
    99diff -Naur ncurses-5.7.orig/aclocal.m4 ncurses-5.7/aclocal.m4
    1010--- ncurses-5.7.orig/aclocal.m4 2008-10-25 15:15:32.000000000 -0700
    11 +++ ncurses-5.7/aclocal.m4      2009-02-28 20:38:54.327061041 -0800
     11+++ ncurses-5.7/aclocal.m4      2009-06-05 14:01:31.000000000 -0700
    1212@@ -1,5 +1,5 @@
    1313 dnl***************************************************************************
     
    2222 dnl
    2323-dnl $Id: aclocal.m4,v 1.470 2008/10/25 22:15:32 tom Exp $
    24 +dnl $Id: aclocal.m4,v 1.483 2009/02/07 19:12:17 tom Exp $
     24+dnl $Id: aclocal.m4,v 1.487 2009/04/04 22:32:42 tom Exp $
    2525 dnl Macros used in NCURSES auto-configuration script.
    2626 dnl
     
    189189 
    190190     cf_save_CPPFLAGS="$CPPFLAGS"
    191 @@ -1998,11 +2033,31 @@
     191@@ -1451,7 +1486,7 @@
     192 fi
     193 ])dnl
     194 dnl ---------------------------------------------------------------------------
     195-dnl CF_GCC_WARNINGS version: 23 updated: 2008/07/26 17:54:02
     196+dnl CF_GCC_WARNINGS version: 24 updated: 2009/02/01 15:21:00
     197 dnl ---------------
     198 dnl Check if the compiler supports useful warning options.  There's a few that
     199 dnl we don't use, simply because they're too noisy:
     200@@ -1484,7 +1519,6 @@
     201 then
     202 # The "-wdXXX" options suppress warnings:
     203 # remark #1419: external declaration in primary source file
     204-# remark #1682: implicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
     205 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
     206 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
     207 # remark #193: zero used for undefined preprocessing identifier
     208@@ -1492,19 +1526,18 @@
     209 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
     210 # remark #869: parameter "tw" was never referenced
     211 # remark #981: operands are evaluated in unspecified order
     212-# warning #269: invalid format string conversion
     213+# warning #279: controlling expression is constant
     214 
     215        AC_CHECKING([for $CC warning options])
     216        cf_save_CFLAGS="$CFLAGS"
     217        EXTRA_CFLAGS="-Wall"
     218        for cf_opt in \
     219                wd1419 \
     220-               wd1682 \
     221                wd1683 \
     222                wd1684 \
     223                wd193 \
     224-               wd279 \
     225                wd593 \
     226+               wd279 \
     227                wd810 \
     228                wd869 \
     229                wd981
     230@@ -1998,11 +2031,31 @@
    192231 ])
    193232 ])dnl
     
    224263 test "$includedir" != "/usr/include" && \
    225264 test -d "$includedir" && {
    226 @@ -2017,6 +2072,7 @@
     265@@ -2017,6 +2070,7 @@
    227266        test -d $oldincludedir/$2 && $1="[$]$1 $oldincludedir/$2"
    228267 }
     
    232271 dnl ---------------------------------------------------------------------------
    233272 dnl CF_HELP_MESSAGE version: 3 updated: 1998/01/14 10:56:23
    234 @@ -2026,7 +2082,7 @@
     273@@ -2026,7 +2080,7 @@
    235274 [AC_DIVERT_HELP([$1])dnl
    236275 ])dnl
     
    241280 dnl Construct the list of include-options according to whether we're building
    242281 dnl in the source directory or using '--srcdir=DIR' option.  If we're building
    243 @@ -2034,9 +2090,9 @@
     282@@ -2034,9 +2088,9 @@
    244283 dnl since that usually breaks gcc's shadow-includes.
    245284 AC_DEFUN([CF_INCLUDE_DIRS],
     
    253292 if test "$GCC" != yes; then
    254293        CPPFLAGS="$CPPFLAGS -I\${includedir}"
    255 @@ -2143,7 +2199,7 @@
     294@@ -2143,7 +2197,7 @@
    256295 ])
    257296 ])
    258297 dnl ---------------------------------------------------------------------------
    259298-dnl CF_LDFLAGS_STATIC version: 4 updated: 2008/10/18 17:58:20
    260 +dnl CF_LDFLAGS_STATIC version: 5 updated: 2008/12/27 12:30:03
     299+dnl CF_LDFLAGS_STATIC version: 7 updated: 2009/04/04 18:31:04
    261300 dnl -----------------
    262301 dnl Check for compiler/linker flags used to temporarily force usage of static
    263302 dnl libraries.  This depends on the compiler and platform.  Use this to help
    264 @@ -2153,7 +2209,7 @@
     303@@ -2153,7 +2207,7 @@
    265304 
    266305 if test "$GCC" = yes ; then
    267306        case $cf_cv_system_name in #(
    268307-       OS/2*|os2*|aix[[45]]*)  #( vi
    269 +       OS/2*|os2*|aix[[4]]*)   #( vi
     308+       OS/2*|os2*|aix[[4]]*|solaris2.1[[0-9]]|darwin*)         #( vi
    270309                LDFLAGS_STATIC=
    271310                LDFLAGS_SHARED=
    272311                ;;
    273 @@ -2164,7 +2220,7 @@
     312@@ -2164,7 +2218,7 @@
    274313     esac
    275314 else
     
    280319                LDFLAGS_SHARED=-bdynamic
    281320                ;;
    282 @@ -2179,7 +2235,7 @@
     321@@ -2179,7 +2233,7 @@
    283322                ;;
    284323        osf[[45]]*)     #( from ld manpage osf4.0d, osf5.1
     
    289328                ;;
    290329        solaris2*)
    291 @@ -2193,11 +2249,33 @@
     330@@ -2193,11 +2247,33 @@
    292331 AC_SUBST(LDFLAGS_SHARED)
    293332 ])
     
    326365 dnl CF_LIB_PREFIX version: 8 updated: 2008/09/13 11:34:16
    327366 dnl -------------
    328 @@ -2216,7 +2294,7 @@
     367@@ -2216,7 +2292,7 @@
    329368        AC_SUBST(LIB_PREFIX)
    330369 ])dnl
     
    335374 dnl Append definitions and rules for the given models to the subdirectory
    336375 dnl Makefiles, and the recursion rule for the top-level Makefile.  If the
    337 @@ -2504,18 +2582,28 @@
     376@@ -2504,18 +2580,28 @@
    338377 install.libs uninstall.libs \\
    339378 install.data uninstall.data ::
     
    364403 if test -f $srcdir/$tack.h; then
    365404 cat >> Makefile <<CF_EOF
    366 @@ -2526,6 +2614,7 @@
     405@@ -2526,6 +2612,7 @@
    367406 CF_EOF
    368407 fi
     
    372411 dnl If we're installing into a subdirectory of /usr/include, etc., we should
    373412 dnl prepend the subdirectory's name to the "#include" paths.  It won't hurt
    374 @@ -2679,7 +2768,7 @@
     413@@ -2679,7 +2766,7 @@
    375414 ])
    376415 ])
     
    381420 dnl Compute the library file-suffix from the given model name
    382421 dnl $1 = model name
    383 @@ -2689,40 +2778,44 @@
     422@@ -2689,40 +2776,44 @@
    384423 AC_DEFUN([CF_LIB_SUFFIX],
    385424 [
     
    437476                                $3=[$]$2
    438477                                ;;
    439 @@ -2755,7 +2848,7 @@
     478@@ -2755,7 +2846,7 @@
    440479        test -n "$LIB_SUFFIX" && $2="${LIB_SUFFIX}[$]{$2}"
    441480 ])dnl
     
    446485 dnl Some systems have a non-ANSI linker that doesn't pull in modules that have
    447486 dnl only data (i.e., no functions), for example NeXT.  On those systems we'll
    448 @@ -2772,7 +2865,7 @@
     487@@ -2772,7 +2863,7 @@
    449488 EOF
    450489        if AC_TRY_EVAL(ac_compile) ; then
     
    455494        rm -f conftest.$ac_ext data.o
    456495        cat >conftest.$ac_ext <<EOF
    457 @@ -2791,7 +2884,7 @@
     496@@ -2791,7 +2882,7 @@
    458497 EOF
    459498        if AC_TRY_EVAL(ac_compile); then
     
    464503        rm -f conftest.$ac_ext func.o
    465504        ( eval $RANLIB conftest.a ) 2>&AC_FD_CC >/dev/null
    466 @@ -2956,7 +3049,7 @@
     505@@ -2956,7 +3047,7 @@
    467506 AC_SUBST(MAKE_LOWER_TAGS)
    468507 ])dnl
     
    473512 dnl Option to allow user to override automatic configuration of manpage format.
    474513 dnl There are several special cases:
    475 @@ -2998,7 +3091,7 @@
     514@@ -2998,7 +3089,7 @@
    476515   cf_catonly=yes
    477516   cf_example=date
     
    482521     test -z "$cf_dir" && cf_dir=/usr/man
    483522     for cf_name in $cf_dir/man*/$cf_example.[[01]]* $cf_dir/cat*/$cf_example.[[01]]* $cf_dir/man*/$cf_example $cf_dir/cat*/$cf_example
    484 @@ -3687,17 +3780,17 @@
     523@@ -3687,17 +3778,17 @@
    485524        esac
    486525 ])dnl
     
    505544 dnl ---------------------------------------------------------------------------
    506545 dnl CF_PATH_SYNTAX version: 12 updated: 2008/03/23 14:45:59
    507 @@ -3737,6 +3830,38 @@
     546@@ -3737,6 +3828,38 @@
    508547 esac
    509548 ])dnl
     
    544583 dnl -----------------
    545584 dnl Define _POSIX_C_SOURCE to the given level, and _POSIX_SOURCE if needed.
    546 @@ -3872,6 +3997,13 @@
     585@@ -3872,6 +3995,13 @@
    547586 
    548587 ])dnl
     
    558597 dnl -----------
    559598 dnl Check for awk, ensure that the check found something.
    560 @@ -4003,7 +4135,7 @@
     599@@ -4003,7 +4133,7 @@
    561600 esac
    562601 ])dnl
     
    567606 dnl Check for ldconfig, needed to fixup shared libraries that would be built
    568607 dnl and then used in the install.
    569 @@ -4012,7 +4144,7 @@
     608@@ -4012,7 +4142,7 @@
    570609   LDCONFIG=:
    571610 else
     
    576615   ;;
    577616 *) LDPATH=$PATH:/sbin:/usr/sbin
    578 @@ -4147,7 +4279,7 @@
     617@@ -4147,7 +4277,7 @@
    579618 fi
    580619 ])dnl
     
    585624 dnl --------------
    586625 dnl Attempt to determine the appropriate CC/LD options for creating a shared
    587 @@ -4176,6 +4308,7 @@
     626@@ -4176,6 +4306,7 @@
    588627        AC_REQUIRE([CF_SUBST_NCURSES_VERSION])
    589628        LOCAL_LDFLAGS=
     
    593632        INSTALL_LIB="-m 644"
    594633 
    595 @@ -4219,6 +4352,12 @@
     634@@ -4219,6 +4350,12 @@
    596635        cf_cv_shlib_version_infix=no
    597636 
     
    606645                MK_SHARED_LIB='${CC} ${CFLAGS} -o $[@] -Xlinker -soname=`basename $[@]` -nostart -e 0'
    607646                ;;
    608 @@ -4239,7 +4378,7 @@
     647@@ -4239,7 +4376,7 @@
    609648 EOF
    610649                exec \[$]* -shared -Wl,--out-implib=../lib/\[$]{IMPORT_LIB} -Wl,--export-all-symbols -o ../lib/\[$]{SHARED_LIB}
     
    615654        darwin*)
    616655                EXTRA_CFLAGS="-no-cpp-precomp"
    617 @@ -4272,10 +4411,10 @@
     656@@ -4272,10 +4409,10 @@
    618657        irix*)
    619658                if test "$cf_cv_ld_rpath" = yes ; then
     
    628667                        fi
    629668                fi
    630 @@ -4294,7 +4433,7 @@
     669@@ -4294,7 +4431,7 @@
    631670                        LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
    632671                fi
     
    637676                fi
    638677                CF_SHARED_SONAME
    639 @@ -4306,12 +4445,12 @@
     678@@ -4306,12 +4443,12 @@
    640679                        LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
    641680                fi
     
    652691        nto-qnx*|openbsd*|freebsd[[12]].*)
    653692                CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
    654 @@ -4323,15 +4462,15 @@
     693@@ -4323,15 +4460,15 @@
    655694                if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_ld_rpath" = yes ; then
    656695                        LOCAL_LDFLAGS="-rpath \$(LOCAL_LIBDIR)"
     
    671710                        LOCAL_LDFLAGS="-Wl,-rpath,\$(LOCAL_LIBDIR)"
    672711                        LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
    673 @@ -4346,7 +4485,7 @@
     712@@ -4346,7 +4483,7 @@
    674713                        CF_SHARED_SONAME
    675714                        MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname' -o $[@]'
     
    680719                ;;
    681720        osf*|mls+*)
    682 @@ -4365,7 +4504,7 @@
     721@@ -4365,7 +4502,7 @@
    683722                        LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
    684723                fi
     
    689728                fi
    690729                cf_cv_rm_so_locs=yes
    691 @@ -4400,12 +4539,19 @@
     730@@ -4400,12 +4537,19 @@
    692731                        LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
    693732                fi
     
    711750                else
    712751                        MK_SHARED_LIB='${CC} -shared -dy -G -h '$cf_cv_shared_soname' -o $[@]'
    713 @@ -4438,18 +4584,19 @@
     752@@ -4438,18 +4582,19 @@
    714753                ;;
    715754        esac
     
    735774        AC_SUBST(MK_SHARED_LIB)
    736775        AC_SUBST(LINK_PROGS)
    737 @@ -4642,7 +4789,7 @@
     776@@ -4642,7 +4787,7 @@
    738777 fi
    739778 ])dnl
     
    744783 dnl For each parameter, test if the source-directory exists, and if it contains
    745784 dnl a 'modules' file.  If so, add to the list $cf_cv_src_modules which we'll
    746 @@ -4717,7 +4864,11 @@
     785@@ -4717,7 +4862,11 @@
    747786 AC_SUBST(TEST_ARG2)
    748787 AC_SUBST(TEST_DEP2)
     
    757796 do
    758797        SRC_SUBDIRS="$SRC_SUBDIRS $cf_dir"
    759 @@ -4728,8 +4879,8 @@
     798@@ -4728,8 +4877,8 @@
    760799 
    761800 ADA_SUBDIRS=
     
    768807 
    769808 SUB_MAKEFILES=
    770 @@ -4739,11 +4890,11 @@
     809@@ -4739,11 +4888,11 @@
    771810 done
    772811 
     
    785824 ])dnl
    786825 dnl ---------------------------------------------------------------------------
    787 @@ -5241,7 +5392,7 @@
     826@@ -5241,7 +5390,7 @@
    788827 fi
    789828 ])
    790829 dnl ---------------------------------------------------------------------------
    791830-dnl CF_WITH_LIBTOOL version: 19 updated: 2008/03/29 15:46:43
    792 +dnl CF_WITH_LIBTOOL version: 20 updated: 2008/12/27 12:31:39
     831+dnl CF_WITH_LIBTOOL version: 23 updated: 2009/03/28 14:26:27
    793832 dnl ---------------
    794833 dnl Provide a configure option to incorporate libtool.  Define several useful
    795834 dnl symbols for the makefile rules.
    796 @@ -5261,18 +5412,18 @@
     835@@ -5261,18 +5410,18 @@
    797836 dnl            echo cannot find libtool.m4 file
    798837 dnl            exit 1
     
    817856 dnl
    818857 AC_DEFUN([CF_WITH_LIBTOOL],
    819 @@ -5306,15 +5457,15 @@
     858@@ -5306,17 +5455,17 @@
    820859        AC_PROG_LIBTOOL
    821860        # missing_content_AC_PROG_LIBTOOL}}
     
    837876+       fi
    838877 ])dnl
    839         LIB_CREATE='${LIBTOOL} --mode=link ${CC} -rpath ${DESTDIR}${libdir} -version-info `cut -f1 ${srcdir}/VERSION` ${LIBTOOL_OPTS} -o'
     878-       LIB_CREATE='${LIBTOOL} --mode=link ${CC} -rpath ${DESTDIR}${libdir} -version-info `cut -f1 ${srcdir}/VERSION` ${LIBTOOL_OPTS} -o'
     879+       LIB_CREATE='${LIBTOOL} --mode=link ${CC} -rpath ${DESTDIR}${libdir} -version-info `cut -f1 ${srcdir}/VERSION` ${LIBTOOL_OPTS} ${LT_UNDEF} -o'
    840880        LIB_OBJECT='${OBJECTS:.o=.lo}'
    841 @@ -5393,7 +5544,7 @@
     881        LIB_SUFFIX=.la
     882        LIB_CLEAN='${LIBTOOL} --mode=clean'
     883@@ -5331,16 +5480,25 @@
     884 
     885        # Save the version in a cache variable - this is not entirely a good
     886        # thing, but the version string from libtool is very ugly, and for
     887-       # bug reports it might be useful to have the original string.
     888+       # bug reports it might be useful to have the original string. "("
     889        cf_cv_libtool_version=`$LIBTOOL --version 2>&1 | sed -e '/^$/d' |sed -e '2,$d' -e 's/([[^)]]*)//g' -e 's/^[[^1-9]]*//' -e 's/[[^0-9.]].*//'`
     890        AC_MSG_RESULT($cf_cv_libtool_version)
     891        if test -z "$cf_cv_libtool_version" ; then
     892                AC_MSG_ERROR(This is not GNU libtool)
     893        fi
     894 
     895+       # special hack to add -no-undefined (which libtool should do for itself)
     896+       LT_UNDEF=
     897+       case "$cf_cv_system_name" in #(vi
     898+       cygwin*|mingw32*|uwin*|aix[[456]]) #(vi
     899+               LT_UNDEF=-no-undefined
     900+               ;;
     901+       esac
     902+       AC_SUBST([LT_UNDEF])
     903+
     904        # special hack to add --tag option for C++ compiler
     905-       case $cf_cv_libtool_version in
     906-       1.[[5-9]]*|[[2-9]]*)
     907+       case $cf_cv_libtool_version in #(vi
     908+       1.[[5-9]]*|[[2-9]].[[0-9.a-z]]*) #(vi
     909                LIBTOOL_CXX="$LIBTOOL --tag=CXX"
     910                LIBTOOL="$LIBTOOL --tag=CC"
     911                ;;
     912@@ -5393,7 +5551,7 @@
    842913 AC_SUBST($3)dnl
    843914 ])dnl
     
    848919 dnl Process an option specifying a list of colon-separated paths.
    849920 dnl
    850 @@ -5409,7 +5560,7 @@
     921@@ -5409,7 +5567,7 @@
    851922 AC_ARG_WITH($1,[$2 ](default: ifelse($4,,empty,$4)),,
    852923 ifelse($4,,[withval=${$3}],[withval=${$3-ifelse($5,,$4,$5)}]))dnl
     
    857928 for cf_src_path in $withval
    858929 do
    859 @@ -5535,7 +5686,7 @@
     930@@ -5535,7 +5693,7 @@
    860931        [USE_VALGRIND])
    861932 ])dnl
     
    866937 dnl Try to get _XOPEN_SOURCE defined properly that we can use POSIX functions,
    867938 dnl or adapt to the vendor's definitions to get equivalent functionality,
    868 @@ -5552,7 +5703,7 @@
     939@@ -5552,7 +5710,7 @@
    869940 cf_POSIX_C_SOURCE=ifelse($2,,199506L,$2)
    870941 
     
    875946        ;;
    876947 freebsd*|dragonfly*) #(vi
    877 @@ -5569,7 +5720,7 @@
     948@@ -5569,7 +5727,7 @@
    878949 irix[[56]].*) #(vi
    879950        CPPFLAGS="$CPPFLAGS -D_SGI_SOURCE"
     
    886957diff -Naur ncurses-5.7.orig/Ada95/gen/adacurses-config.in ncurses-5.7/Ada95/gen/adacurses-config.in
    887958--- ncurses-5.7.orig/Ada95/gen/adacurses-config.in      2007-04-07 14:06:50.000000000 -0700
    888 +++ ncurses-5.7/Ada95/gen/adacurses-config.in   2009-02-28 20:38:50.310805699 -0800
     959+++ ncurses-5.7/Ada95/gen/adacurses-config.in   2009-06-05 14:01:07.000000000 -0700
    889960@@ -1,18 +1,47 @@
    890961 #! /bin/sh
     
    9581029         ;;
    9591030 esac
     1031diff -Naur ncurses-5.7.orig/Ada95/gen/gen.c ncurses-5.7/Ada95/gen/gen.c
     1032--- ncurses-5.7.orig/Ada95/gen/gen.c    2008-10-04 14:59:37.000000000 -0700
     1033+++ ncurses-5.7/Ada95/gen/gen.c 2009-06-05 14:01:24.000000000 -0700
     1034@@ -1,5 +1,5 @@
     1035 /****************************************************************************
     1036- * Copyright (c) 1998,2007,2008 Free Software Foundation, Inc.              *
     1037+ * Copyright (c) 1998,2008,2009 Free Software Foundation, Inc.              *
     1038  *                                                                          *
     1039  * Permission is hereby granted, free of charge, to any person obtaining a  *
     1040  * copy of this software and associated documentation files (the            *
     1041@@ -32,7 +32,7 @@
     1042 
     1043 /*
     1044     Version Control
     1045-    $Id: gen.c,v 1.49 2008/10/04 21:59:37 tom Exp $
     1046+    $Id: gen.c,v 1.50 2009/03/21 21:34:20 tom Exp $
     1047   --------------------------------------------------------------------------*/
     1048 /*
     1049   This program generates various record structures and constants from the
     1050@@ -778,7 +778,9 @@
     1051 #if USE_REENTRANT || BROKEN_LINKER
     1052   printf("   type C_ACS_Ptr is access C_ACS_Map;\n");
     1053   printf("   function ACS_Map return C_ACS_Ptr;\n");
     1054-  printf("   pragma Import (C, ACS_Map, \"_nc_acs_map\");\n");
     1055+  printf("   pragma Import (C, ACS_Map, \""
     1056+        NCURSES_WRAP_PREFIX
     1057+        "acs_map\");\n");
     1058 #else
     1059   printf("   ACS_Map : C_ACS_Map;\n");
     1060   printf("   pragma Import (C, ACS_Map, \"acs_map\");\n");
     1061@@ -1034,7 +1036,7 @@
     1062   printf("   function %s return %s\n", ada_func, ada_type);
     1063   printf("   is\n");
     1064   printf("      function Result return %s;\n", c_type);
     1065-  printf("      pragma Import (C, Result, \"_nc_%s\");\n", c_var);
     1066+  printf("      pragma Import (C, Result, \"" NCURSES_WRAP_PREFIX "%s\");\n", c_var);
     1067   printf("   begin\n");
     1068   if (strcmp(c_type, ada_type))
     1069     printf("      return %s (Result);\n", ada_type);
    9601070diff -Naur ncurses-5.7.orig/Ada95/gen/Makefile.in ncurses-5.7/Ada95/gen/Makefile.in
    9611071--- ncurses-5.7.orig/Ada95/gen/Makefile.in      2008-10-04 15:58:31.000000000 -0700
    962 +++ ncurses-5.7/Ada95/gen/Makefile.in   2009-02-28 20:38:50.306805140 -0800
     1072+++ ncurses-5.7/Ada95/gen/Makefile.in   2009-06-05 14:01:07.000000000 -0700
    9631073@@ -1,5 +1,5 @@
    9641074 ##############################################################################
     
    10161126diff -Naur ncurses-5.7.orig/Ada95/samples/Makefile.in ncurses-5.7/Ada95/samples/Makefile.in
    10171127--- ncurses-5.7.orig/Ada95/samples/Makefile.in  2006-12-17 08:45:02.000000000 -0800
    1018 +++ ncurses-5.7/Ada95/samples/Makefile.in       2009-02-28 20:38:50.310805699 -0800
     1128+++ ncurses-5.7/Ada95/samples/Makefile.in       2009-06-05 14:01:07.000000000 -0700
    10191129@@ -1,5 +1,5 @@
    10201130 ##############################################################################
     
    10551165diff -Naur ncurses-5.7.orig/Ada95/src/Makefile.in ncurses-5.7/Ada95/src/Makefile.in
    10561166--- ncurses-5.7.orig/Ada95/src/Makefile.in      2007-09-15 11:22:24.000000000 -0700
    1057 +++ ncurses-5.7/Ada95/src/Makefile.in   2009-02-28 20:38:50.310805699 -0800
     1167+++ ncurses-5.7/Ada95/src/Makefile.in   2009-06-05 14:01:07.000000000 -0700
    10581168@@ -1,5 +1,5 @@
    10591169 ##############################################################################
     
    11471257diff -Naur ncurses-5.7.orig/Ada95/src/terminal_interface-curses-mouse.adb ncurses-5.7/Ada95/src/terminal_interface-curses-mouse.adb
    11481258--- ncurses-5.7.orig/Ada95/src/terminal_interface-curses-mouse.adb      2008-07-26 11:51:11.000000000 -0700
    1149 +++ ncurses-5.7/Ada95/src/terminal_interface-curses-mouse.adb   2009-02-28 20:38:37.153962564 -0800
     1259+++ ncurses-5.7/Ada95/src/terminal_interface-curses-mouse.adb   2009-06-05 14:00:52.000000000 -0700
    11501260@@ -35,8 +35,8 @@
    11511261 ------------------------------------------------------------------------------
     
    11701280diff -Naur ncurses-5.7.orig/c++/cursesw.cc ncurses-5.7/c++/cursesw.cc
    11711281--- ncurses-5.7.orig/c++/cursesw.cc     2007-12-15 15:01:57.000000000 -0800
    1172 +++ ncurses-5.7/c++/cursesw.cc  2009-02-28 20:38:37.161961447 -0800
     1282+++ ncurses-5.7/c++/cursesw.cc  2009-06-05 14:01:30.000000000 -0700
    11731283@@ -1,6 +1,6 @@
    11741284 // * this is for making emacs happy: -*-Mode: C++;-*-
    11751285 /****************************************************************************
    11761286- * Copyright (c) 2007 Free Software Foundation, Inc.                        *
    1177 + * Copyright (c) 2007,2008 Free Software Foundation, Inc.                   *
     1287+ * Copyright (c) 2007-2008,2009 Free Software Foundation, Inc.              *
    11781288  *                                                                          *
    11791289  * Permission is hereby granted, free of charge, to any person obtaining a  *
     
    11841294 
    11851295-MODULE_ID("$Id: cursesw.cc,v 1.49 2007/12/15 23:01:57 tom Exp $")
    1186 +MODULE_ID("$Id: cursesw.cc,v 1.50 2008/11/23 00:17:31 juergen Exp $")
     1296+MODULE_ID("$Id: cursesw.cc,v 1.51 2009/03/28 21:31:37 tom Exp $")
    11871297 
    11881298 #define COLORS_NEED_INITIALIZATION  -1
     
    11961306 
    11971307 int _nc_xx_ripoff_init(WINDOW *w, int ncols)
    1198 @@ -464,7 +463,7 @@
     1308@@ -296,8 +295,7 @@
     1309 
     1310     RIPOFFINIT init = *prip++;
     1311     if (init) {
     1312-       NCursesWindow* W = new NCursesWindow(w,ncols);
     1313-       res = init(*W);
     1314+       res = init(*(new NCursesWindow(w,ncols)));
     1315     }
     1316     return res;
     1317 }
     1318@@ -464,7 +462,7 @@
    11991319 #if HAVE_HAS_KEY
    12001320 bool NCursesWindow::has_mouse() const
     
    12051325 }
    12061326 #endif
     1327diff -Naur ncurses-5.7.orig/c++/demo.cc ncurses-5.7/c++/demo.cc
     1328--- ncurses-5.7.orig/c++/demo.cc        2008-08-04 10:16:57.000000000 -0700
     1329+++ ncurses-5.7/c++/demo.cc     2009-06-05 14:01:49.000000000 -0700
     1330@@ -35,7 +35,7 @@
     1331  *   Demo code for NCursesMenu and NCursesForm written by
     1332  *   Juergen Pfeifer
     1333  *
     1334- * $Id: demo.cc,v 1.38 2008/08/04 17:16:57 tom Exp $
     1335+ * $Id: demo.cc,v 1.39 2008/12/07 02:07:34 juergen Exp $
     1336  */
     1337 
     1338 #include "internal.h"
     1339@@ -43,7 +43,13 @@
     1340 #include "cursesm.h"
     1341 #include "cursesf.h"
     1342 
     1343+#ifdef __MINGW32__
     1344+#undef KEY_EVENT
     1345+#endif
     1346+
     1347+#ifndef __MINGW32__
     1348 extern "C" unsigned int sleep(unsigned int);
     1349+#endif
     1350 
     1351 #undef index // needed for NeXT
     1352 
     1353diff -Naur ncurses-5.7.orig/c++/internal.h ncurses-5.7/c++/internal.h
     1354--- ncurses-5.7.orig/c++/internal.h     2008-10-25 14:35:44.000000000 -0700
     1355+++ ncurses-5.7/c++/internal.h  2009-06-05 14:01:49.000000000 -0700
     1356@@ -31,7 +31,7 @@
     1357  *   Author: Juergen Pfeifer, 1997                                          *
     1358  ****************************************************************************/
     1359 
     1360-// $Id: internal.h,v 1.16 2008/10/25 21:35:44 tom Exp $
     1361+// $Id: internal.h,v 1.17 2008/12/07 02:07:34 juergen Exp $
     1362 
     1363 #ifndef NCURSES_CPLUS_INTERNAL_H
     1364 #define NCURSES_CPLUS_INTERNAL_H 1
     1365@@ -44,6 +44,11 @@
     1366 #define MODULE_ID(id) /*nothing*/
     1367 #endif
     1368 
     1369+#ifdef __MINGW32__
     1370+#include <nc_mingw.h>
     1371+#undef KEY_EVENT
     1372+#endif
     1373+
     1374 #ifndef _QNX_SOURCE
     1375 #include <stdlib.h>
     1376 #include <string.h>
    12071377diff -Naur ncurses-5.7.orig/c++/Makefile.in ncurses-5.7/c++/Makefile.in
    12081378--- ncurses-5.7.orig/c++/Makefile.in    2007-04-28 08:29:12.000000000 -0700
    1209 +++ ncurses-5.7/c++/Makefile.in 2009-02-28 20:38:46.290546165 -0800
     1379+++ ncurses-5.7/c++/Makefile.in 2009-06-05 14:01:30.000000000 -0700
    12101380@@ -1,6 +1,6 @@
    12111381-# $Id: Makefile.in,v 1.84 2007/04/28 15:29:12 tom Exp $
    1212 +# $Id: Makefile.in,v 1.85 2009/01/03 19:10:40 tom Exp $
     1382+# $Id: Makefile.in,v 1.87 2009/03/28 18:22:39 Charles.Wilson Exp $
    12131383 ##############################################################################
    12141384-# Copyright (c) 1998-2006,2007 Free Software Foundation, Inc.                #
     
    12171387 # Permission is hereby granted, free of charge, to any person obtaining a    #
    12181388 # copy of this software and associated documentation files (the "Software"), #
    1219 @@ -61,10 +61,10 @@
     1389@@ -55,16 +55,17 @@
     1390 LIBTOOL_LINK   = @LIB_LINK@
     1391 LIBTOOL_INSTALL        = @LIB_INSTALL@
     1392 LIBTOOL_UNINSTALL = @LIB_UNINSTALL@
     1393+LT_UNDEF       = @LT_UNDEF@
     1394 
     1395 INSTALL                = @INSTALL@
     1396 INSTALL_LIB    = @INSTALL@ @INSTALL_LIB@
    12201397 INSTALL_DATA   = @INSTALL_DATA@
    12211398 
     
    12301407 
    12311408 CXX            = @CXX@
    1232 @@ -153,7 +153,7 @@
     1409@@ -95,7 +96,7 @@
     1410 
     1411 LINK           = @LINK_PROGS@ $(LIBTOOL_LINK) @CXXLDFLAGS@
     1412 SHLIB_DIRS     = -L../lib
     1413-SHLIB_LIST     = $(SHLIB_DIRS) -lncurses@LIB_SUFFIX@ @SHLIB_LIST@
     1414+SHLIB_LIST     = $(SHLIB_DIRS) -lform@LIB_SUFFIX@ -lmenu@LIB_SUFFIX@ -lpanel@LIB_SUFFIX@ -lncurses@LIB_SUFFIX@ @SHLIB_LIST@
     1415 
     1416 LIBROOT                = ncurses++
     1417 
     1418@@ -153,14 +154,14 @@
    12331419        $(MODEL)/cursesmain$o
    12341420 
     
    12391425 
    12401426 ../lib/$(LIBNAME_LIBTOOL) : $(LIB_OBJS)
     1427        cd ../lib && $(LIBTOOL_LINK) $(CXX) $(CXXFLAGS) \
     1428                -o $(LIBNAME) $(LIB_OBJS:$o=.lo) \
     1429                -rpath $(INSTALL_PREFIX)$(libdir) \
     1430-               -version-info $(NCURSES_MAJOR):$(NCURSES_MINOR) $(SHLIB_LIST)
     1431+               -version-info $(NCURSES_MAJOR):$(NCURSES_MINOR) $(LT_UNDEF) $(SHLIB_LIST)
     1432 
     1433 OBJS_DEMO = $(MODEL)/demo$o
     1434 
    12411435diff -Naur ncurses-5.7.orig/config.guess ncurses-5.7/config.guess
    12421436--- ncurses-5.7.orig/config.guess       2008-08-30 13:25:07.000000000 -0700
    1243 +++ ncurses-5.7/config.guess    2009-02-28 20:38:46.290546165 -0800
     1437+++ ncurses-5.7/config.guess    2009-06-05 14:01:03.000000000 -0700
    12441438@@ -4,7 +4,7 @@
    12451439 #   2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
     
    13111505diff -Naur ncurses-5.7.orig/config.sub ncurses-5.7/config.sub
    13121506--- ncurses-5.7.orig/config.sub 2008-08-30 13:25:02.000000000 -0700
    1313 +++ ncurses-5.7/config.sub      2009-02-28 20:38:46.290546165 -0800
     1507+++ ncurses-5.7/config.sub      2009-06-05 14:01:03.000000000 -0700
    13141508@@ -4,7 +4,7 @@
    13151509 #   2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008
     
    13951589diff -Naur ncurses-5.7.orig/configure ncurses-5.7/configure
    13961590--- ncurses-5.7.orig/configure  2008-10-25 17:04:38.000000000 -0700
    1397 +++ ncurses-5.7/configure       2009-02-28 20:38:57.039235088 -0800
     1591+++ ncurses-5.7/configure       2009-06-05 14:01:31.000000000 -0700
    13981592@@ -1,7 +1,7 @@
    13991593 #! /bin/sh
    14001594-# From configure.in Revision: 1.454 .
    1401 +# From configure.in Revision: 1.466 .
     1595+# From configure.in Revision: 1.470 .
    14021596 # Guess values for system-dependent variables and create Makefiles.
    14031597-# Generated by Autoconf 2.52.20080325.
     
    14261620   --enable-ext-colors     compile for 256-color support
    14271621   --enable-ext-mouse      compile for extended mouse-encoding
    1428 @@ -870,7 +874,7 @@
     1622@@ -780,6 +784,7 @@
     1623   --with-pthread          use POSIX thread library
     1624   --enable-weak-symbols   enable weak-symbols for pthreads
     1625   --enable-reentrant      compile with experimental reentrant code
     1626+  --with-wrap-prefix=XXX  override prefix used for public variables
     1627   --enable-safe-sprintf   compile with experimental safe-sprintf code
     1628   --disable-scroll-hints  compile without scroll-hints code
     1629   --enable-wgetch-events  compile with experimental wgetch-events code
     1630@@ -870,7 +875,7 @@
    14291631 running configure, to aid debugging if configure makes a mistake.
    14301632 
     
    14351637   $ $0 $@
    14361638 
    1437 @@ -994,7 +998,7 @@
     1639@@ -994,7 +999,7 @@
    14381640 fi
    14391641 for ac_site_file in $CONFIG_SITE; do
    14401642   if test -r "$ac_site_file"; then
    14411643-    { echo "$as_me:997: loading site script $ac_site_file" >&5
    1442 +    { echo "$as_me:1001: loading site script $ac_site_file" >&5
     1644+    { echo "$as_me:1002: loading site script $ac_site_file" >&5
    14431645 echo "$as_me: loading site script $ac_site_file" >&6;}
    14441646     cat "$ac_site_file" >&5
    14451647     . "$ac_site_file"
    1446 @@ -1005,7 +1009,7 @@
     1648@@ -1005,7 +1010,7 @@
    14471649   # Some versions of bash will fail to source /dev/null (special
    14481650   # files actually), so we avoid doing that.
    14491651   if test -f "$cache_file"; then
    14501652-    { echo "$as_me:1008: loading cache $cache_file" >&5
    1451 +    { echo "$as_me:1012: loading cache $cache_file" >&5
     1653+    { echo "$as_me:1013: loading cache $cache_file" >&5
    14521654 echo "$as_me: loading cache $cache_file" >&6;}
    14531655     case $cache_file in
    14541656       [\\/]* | ?:[\\/]* ) . $cache_file;;
    1455 @@ -1013,7 +1017,7 @@
     1657@@ -1013,7 +1018,7 @@
    14561658     esac
    14571659   fi
    14581660 else
    14591661-  { echo "$as_me:1016: creating cache $cache_file" >&5
    1460 +  { echo "$as_me:1020: creating cache $cache_file" >&5
     1662+  { echo "$as_me:1021: creating cache $cache_file" >&5
    14611663 echo "$as_me: creating cache $cache_file" >&6;}
    14621664   >$cache_file
    14631665 fi
    1464 @@ -1029,21 +1033,21 @@
     1666@@ -1029,21 +1034,21 @@
    14651667   eval ac_new_val="\$ac_env_${ac_var}_value"
    14661668   case $ac_old_set,$ac_new_set in
    14671669     set,)
    14681670-      { echo "$as_me:1032: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
    1469 +      { echo "$as_me:1036: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
     1671+      { echo "$as_me:1037: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
    14701672 echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
    14711673       ac_cache_corrupted=: ;;
    14721674     ,set)
    14731675-      { echo "$as_me:1036: error: \`$ac_var' was not set in the previous run" >&5
    1474 +      { echo "$as_me:1040: error: \`$ac_var' was not set in the previous run" >&5
     1676+      { echo "$as_me:1041: error: \`$ac_var' was not set in the previous run" >&5
    14751677 echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
    14761678       ac_cache_corrupted=: ;;
     
    14791681       if test "x$ac_old_val" != "x$ac_new_val"; then
    14801682-        { echo "$as_me:1042: error: \`$ac_var' has changed since the previous run:" >&5
    1481 +        { echo "$as_me:1046: error: \`$ac_var' has changed since the previous run:" >&5
     1683+        { echo "$as_me:1047: error: \`$ac_var' has changed since the previous run:" >&5
    14821684 echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
    14831685-        { echo "$as_me:1044:   former value:  $ac_old_val" >&5
    1484 +        { echo "$as_me:1048:   former value:  $ac_old_val" >&5
     1686+        { echo "$as_me:1049:   former value:  $ac_old_val" >&5
    14851687 echo "$as_me:   former value:  $ac_old_val" >&2;}
    14861688-        { echo "$as_me:1046:   current value: $ac_new_val" >&5
    1487 +        { echo "$as_me:1050:   current value: $ac_new_val" >&5
     1689+        { echo "$as_me:1051:   current value: $ac_new_val" >&5
    14881690 echo "$as_me:   current value: $ac_new_val" >&2;}
    14891691         ac_cache_corrupted=:
    14901692       fi;;
    1491 @@ -1062,9 +1066,9 @@
     1693@@ -1062,9 +1067,9 @@
    14921694   fi
    14931695 done
    14941696 if $ac_cache_corrupted; then
    14951697-  { echo "$as_me:1065: error: changes in the environment can compromise the build" >&5
    1496 +  { echo "$as_me:1069: error: changes in the environment can compromise the build" >&5
     1698+  { echo "$as_me:1070: error: changes in the environment can compromise the build" >&5
    14971699 echo "$as_me: error: changes in the environment can compromise the build" >&2;}
    14981700-  { { echo "$as_me:1067: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
    1499 +  { { echo "$as_me:1071: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
     1701+  { { echo "$as_me:1072: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
    15001702 echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
    15011703    { (exit 1); exit 1; }; }
    15021704 fi
    1503 @@ -1085,10 +1089,10 @@
     1705@@ -1085,10 +1090,10 @@
    15041706 echo "#! $SHELL" >conftest.sh
    15051707 echo  "exit 0"   >>conftest.sh
    15061708 chmod +x conftest.sh
    15071709-if { (echo "$as_me:1088: PATH=\".;.\"; conftest.sh") >&5
    1508 +if { (echo "$as_me:1092: PATH=\".;.\"; conftest.sh") >&5
     1710+if { (echo "$as_me:1093: PATH=\".;.\"; conftest.sh") >&5
    15091711   (PATH=".;."; conftest.sh) 2>&5
    15101712   ac_status=$?
    15111713-  echo "$as_me:1091: \$? = $ac_status" >&5
    1512 +  echo "$as_me:1095: \$? = $ac_status" >&5
     1714+  echo "$as_me:1096: \$? = $ac_status" >&5
    15131715   (exit $ac_status); }; then
    15141716   ac_path_separator=';'
    15151717 else
    1516 @@ -1101,7 +1105,7 @@
     1718@@ -1101,7 +1106,7 @@
    15171719 
    15181720 top_builddir=`pwd`
    15191721 
    15201722-echo "$as_me:1104: checking for egrep" >&5
    1521 +echo "$as_me:1108: checking for egrep" >&5
     1723+echo "$as_me:1109: checking for egrep" >&5
    15221724 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
    15231725 if test "${ac_cv_prog_egrep+set}" = set; then
    15241726   echo $ECHO_N "(cached) $ECHO_C" >&6
    1525 @@ -1111,11 +1115,11 @@
     1727@@ -1111,11 +1116,11 @@
    15261728     else ac_cv_prog_egrep='egrep'
    15271729     fi
    15281730 fi
    15291731-echo "$as_me:1114: result: $ac_cv_prog_egrep" >&5
    1530 +echo "$as_me:1118: result: $ac_cv_prog_egrep" >&5
     1732+echo "$as_me:1119: result: $ac_cv_prog_egrep" >&5
    15311733 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
    15321734  EGREP=$ac_cv_prog_egrep
    15331735 
    15341736-test -z "$EGREP" && { { echo "$as_me:1118: error: No egrep program found" >&5
    1535 +test -z "$EGREP" && { { echo "$as_me:1122: error: No egrep program found" >&5
     1737+test -z "$EGREP" && { { echo "$as_me:1123: error: No egrep program found" >&5
    15361738 echo "$as_me: error: No egrep program found" >&2;}
    15371739    { (exit 1); exit 1; }; }
    15381740 
    1539 @@ -1125,7 +1129,7 @@
     1741@@ -1125,7 +1130,7 @@
    15401742 cf_cv_abi_version=${NCURSES_MAJOR}
    15411743 cf_cv_rel_version=${NCURSES_MAJOR}.${NCURSES_MINOR}
    15421744 cf_cv_timestamp=`date`
    15431745-echo "$as_me:1128: result: Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&5
    1544 +echo "$as_me:1132: result: Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&5
     1746+echo "$as_me:1133: result: Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&5
    15451747 echo "${ECHO_T}Configuring NCURSES $cf_cv_rel_version ABI $cf_cv_abi_version ($cf_cv_timestamp)" >&6
    15461748 
    15471749 test -z "$cf_cv_rel_version" && cf_cv_rel_version=0.0
    1548 @@ -1133,7 +1137,7 @@
     1750@@ -1133,7 +1138,7 @@
    15491751 # Check whether --with-rel-version or --without-rel-version was given.
    15501752 if test "${with_rel_version+set}" = set; then
    15511753   withval="$with_rel_version"
    15521754-  { echo "$as_me:1136: WARNING: overriding release version $cf_cv_rel_version to $withval" >&5
    1553 +  { echo "$as_me:1140: WARNING: overriding release version $cf_cv_rel_version to $withval" >&5
     1755+  { echo "$as_me:1141: WARNING: overriding release version $cf_cv_rel_version to $withval" >&5
    15541756 echo "$as_me: WARNING: overriding release version $cf_cv_rel_version to $withval" >&2;}
    15551757  cf_cv_rel_version=$withval
    15561758 fi;
    1557 @@ -1146,13 +1150,13 @@
     1759@@ -1146,13 +1151,13 @@
    15581760   [0-9]*) #(vi
    15591761        ;;
    15601762   *)
    15611763-       { { echo "$as_me:1149: error: Release major-version is not a number: $NCURSES_MAJOR" >&5
    1562 +       { { echo "$as_me:1153: error: Release major-version is not a number: $NCURSES_MAJOR" >&5
     1764+       { { echo "$as_me:1154: error: Release major-version is not a number: $NCURSES_MAJOR" >&5
    15631765 echo "$as_me: error: Release major-version is not a number: $NCURSES_MAJOR" >&2;}
    15641766    { (exit 1); exit 1; }; }
     
    15671769 else
    15681770-  { { echo "$as_me:1155: error: Release major-version value is empty" >&5
    1569 +  { { echo "$as_me:1159: error: Release major-version value is empty" >&5
     1771+  { { echo "$as_me:1160: error: Release major-version value is empty" >&5
    15701772 echo "$as_me: error: Release major-version value is empty" >&2;}
    15711773    { (exit 1); exit 1; }; }
    15721774 fi
    1573 @@ -1162,13 +1166,13 @@
     1775@@ -1162,13 +1167,13 @@
    15741776   [0-9]*) #(vi
    15751777        ;;
    15761778   *)
    15771779-       { { echo "$as_me:1165: error: Release minor-version is not a number: $NCURSES_MINOR" >&5
    1578 +       { { echo "$as_me:1169: error: Release minor-version is not a number: $NCURSES_MINOR" >&5
     1780+       { { echo "$as_me:1170: error: Release minor-version is not a number: $NCURSES_MINOR" >&5
    15791781 echo "$as_me: error: Release minor-version is not a number: $NCURSES_MINOR" >&2;}
    15801782    { (exit 1); exit 1; }; }
     
    15831785 else
    15841786-  { { echo "$as_me:1171: error: Release minor-version value is empty" >&5
    1585 +  { { echo "$as_me:1175: error: Release minor-version value is empty" >&5
     1787+  { { echo "$as_me:1176: error: Release minor-version value is empty" >&5
    15861788 echo "$as_me: error: Release minor-version value is empty" >&2;}
    15871789    { (exit 1); exit 1; }; }
    15881790 fi
    1589 @@ -1178,7 +1182,7 @@
     1791@@ -1178,7 +1183,7 @@
    15901792 # Check whether --with-abi-version or --without-abi-version was given.
    15911793 if test "${with_abi_version+set}" = set; then
    15921794   withval="$with_abi_version"
    15931795-  { echo "$as_me:1181: WARNING: overriding ABI version $cf_cv_abi_version to $withval" >&5
    1594 +  { echo "$as_me:1185: WARNING: overriding ABI version $cf_cv_abi_version to $withval" >&5
     1796+  { echo "$as_me:1186: WARNING: overriding ABI version $cf_cv_abi_version to $withval" >&5
    15951797 echo "$as_me: WARNING: overriding ABI version $cf_cv_abi_version to $withval" >&2;}
    15961798  cf_cv_abi_version=$withval
    15971799 fi;
    1598 @@ -1188,13 +1192,13 @@
     1800@@ -1188,13 +1193,13 @@
    15991801   [0-9]*) #(vi
    16001802        ;;
    16011803   *)
    16021804-       { { echo "$as_me:1191: error: ABI version is not a number: $cf_cv_abi_version" >&5
    1603 +       { { echo "$as_me:1195: error: ABI version is not a number: $cf_cv_abi_version" >&5
     1805+       { { echo "$as_me:1196: error: ABI version is not a number: $cf_cv_abi_version" >&5
    16041806 echo "$as_me: error: ABI version is not a number: $cf_cv_abi_version" >&2;}
    16051807    { (exit 1); exit 1; }; }
     
    16081810 else
    16091811-  { { echo "$as_me:1197: error: ABI version value is empty" >&5
    1610 +  { { echo "$as_me:1201: error: ABI version value is empty" >&5
     1812+  { { echo "$as_me:1202: error: ABI version value is empty" >&5
    16111813 echo "$as_me: error: ABI version value is empty" >&2;}
    16121814    { (exit 1); exit 1; }; }
    16131815 fi
    1614 @@ -1216,7 +1220,7 @@
     1816@@ -1216,7 +1221,7 @@
    16151817   fi
    16161818 done
    16171819 if test -z "$ac_aux_dir"; then
    16181820-  { { echo "$as_me:1219: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
    1619 +  { { echo "$as_me:1223: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
     1821+  { { echo "$as_me:1224: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&5
    16201822 echo "$as_me: error: cannot find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." >&2;}
    16211823    { (exit 1); exit 1; }; }
    16221824 fi
    1623 @@ -1226,11 +1230,11 @@
     1825@@ -1226,11 +1231,11 @@
    16241826 
    16251827 # Make sure we can run config.sub.
    16261828 $ac_config_sub sun4 >/dev/null 2>&1 ||
    16271829-  { { echo "$as_me:1229: error: cannot run $ac_config_sub" >&5
    1628 +  { { echo "$as_me:1233: error: cannot run $ac_config_sub" >&5
     1830+  { { echo "$as_me:1234: error: cannot run $ac_config_sub" >&5
    16291831 echo "$as_me: error: cannot run $ac_config_sub" >&2;}
    16301832    { (exit 1); exit 1; }; }
    16311833 
    16321834-echo "$as_me:1233: checking build system type" >&5
    1633 +echo "$as_me:1237: checking build system type" >&5
     1835+echo "$as_me:1238: checking build system type" >&5
    16341836 echo $ECHO_N "checking build system type... $ECHO_C" >&6
    16351837 if test "${ac_cv_build+set}" = set; then
    16361838   echo $ECHO_N "(cached) $ECHO_C" >&6
    1637 @@ -1239,23 +1243,23 @@
     1839@@ -1239,23 +1244,23 @@
    16381840 test -z "$ac_cv_build_alias" &&
    16391841   ac_cv_build_alias=`$ac_config_guess`
    16401842 test -z "$ac_cv_build_alias" &&
    16411843-  { { echo "$as_me:1242: error: cannot guess build type; you must specify one" >&5
    1642 +  { { echo "$as_me:1246: error: cannot guess build type; you must specify one" >&5
     1844+  { { echo "$as_me:1247: error: cannot guess build type; you must specify one" >&5
    16431845 echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
    16441846    { (exit 1); exit 1; }; }
    16451847 ac_cv_build=`$ac_config_sub $ac_cv_build_alias` ||
    16461848-  { { echo "$as_me:1246: error: $ac_config_sub $ac_cv_build_alias failed." >&5
    1647 +  { { echo "$as_me:1250: error: $ac_config_sub $ac_cv_build_alias failed." >&5
     1849+  { { echo "$as_me:1251: error: $ac_config_sub $ac_cv_build_alias failed." >&5
    16481850 echo "$as_me: error: $ac_config_sub $ac_cv_build_alias failed." >&2;}
    16491851    { (exit 1); exit 1; }; }
     
    16511853 fi
    16521854-echo "$as_me:1251: result: $ac_cv_build" >&5
    1653 +echo "$as_me:1255: result: $ac_cv_build" >&5
     1855+echo "$as_me:1256: result: $ac_cv_build" >&5
    16541856 echo "${ECHO_T}$ac_cv_build" >&6
    16551857 build=$ac_cv_build
     
    16591861 
    16601862-echo "$as_me:1258: checking host system type" >&5
    1661 +echo "$as_me:1262: checking host system type" >&5
     1863+echo "$as_me:1263: checking host system type" >&5
    16621864 echo $ECHO_N "checking host system type... $ECHO_C" >&6
    16631865 if test "${ac_cv_host+set}" = set; then
    16641866   echo $ECHO_N "(cached) $ECHO_C" >&6
    1665 @@ -1264,12 +1268,12 @@
     1867@@ -1264,12 +1269,12 @@
    16661868 test -z "$ac_cv_host_alias" &&
    16671869   ac_cv_host_alias=$ac_cv_build_alias
    16681870 ac_cv_host=`$ac_config_sub $ac_cv_host_alias` ||
    16691871-  { { echo "$as_me:1267: error: $ac_config_sub $ac_cv_host_alias failed" >&5
    1670 +  { { echo "$as_me:1271: error: $ac_config_sub $ac_cv_host_alias failed" >&5
     1872+  { { echo "$as_me:1272: error: $ac_config_sub $ac_cv_host_alias failed" >&5
    16711873 echo "$as_me: error: $ac_config_sub $ac_cv_host_alias failed" >&2;}
    16721874    { (exit 1); exit 1; }; }
     
    16741876 fi
    16751877-echo "$as_me:1272: result: $ac_cv_host" >&5
    1676 +echo "$as_me:1276: result: $ac_cv_host" >&5
     1878+echo "$as_me:1277: result: $ac_cv_host" >&5
    16771879 echo "${ECHO_T}$ac_cv_host" >&6
    16781880 host=$ac_cv_host
    16791881 host_cpu=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
    1680 @@ -1277,7 +1281,7 @@
     1882@@ -1277,7 +1282,7 @@
    16811883 host_os=`echo $ac_cv_host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
    16821884 
    16831885 if test -f $srcdir/config.guess || test -f $ac_aux_dir/config.guess ; then
    16841886-       echo "$as_me:1280: checking target system type" >&5
    1685 +       echo "$as_me:1284: checking target system type" >&5
     1887+       echo "$as_me:1285: checking target system type" >&5
    16861888 echo $ECHO_N "checking target system type... $ECHO_C" >&6
    16871889 if test "${ac_cv_target+set}" = set; then
    16881890   echo $ECHO_N "(cached) $ECHO_C" >&6
    1689 @@ -1286,12 +1290,12 @@
     1891@@ -1286,12 +1291,12 @@
    16901892 test "x$ac_cv_target_alias" = "x" &&
    16911893   ac_cv_target_alias=$ac_cv_host_alias
    16921894 ac_cv_target=`$ac_config_sub $ac_cv_target_alias` ||
    16931895-  { { echo "$as_me:1289: error: $ac_config_sub $ac_cv_target_alias failed" >&5
    1694 +  { { echo "$as_me:1293: error: $ac_config_sub $ac_cv_target_alias failed" >&5
     1896+  { { echo "$as_me:1294: error: $ac_config_sub $ac_cv_target_alias failed" >&5
    16951897 echo "$as_me: error: $ac_config_sub $ac_cv_target_alias failed" >&2;}
    16961898    { (exit 1); exit 1; }; }
     
    16981900 fi
    16991901-echo "$as_me:1294: result: $ac_cv_target" >&5
    1700 +echo "$as_me:1298: result: $ac_cv_target" >&5
     1902+echo "$as_me:1299: result: $ac_cv_target" >&5
    17011903 echo "${ECHO_T}$ac_cv_target" >&6
    17021904 target=$ac_cv_target
    17031905 target_cpu=`echo $ac_cv_target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
    1704 @@ -1322,13 +1326,13 @@
     1906@@ -1322,13 +1327,13 @@
    17051907 fi
    17061908 
    17071909 test -z "$system_name" && system_name="$cf_cv_system_name"
    17081910-test -n "$cf_cv_system_name" && echo "$as_me:1325: result: Configuring for $cf_cv_system_name" >&5
    1709 +test -n "$cf_cv_system_name" && echo "$as_me:1329: result: Configuring for $cf_cv_system_name" >&5
     1911+test -n "$cf_cv_system_name" && echo "$as_me:1330: result: Configuring for $cf_cv_system_name" >&5
    17101912 echo "${ECHO_T}Configuring for $cf_cv_system_name" >&6
    17111913 
    17121914 if test ".$system_name" != ".$cf_cv_system_name" ; then
    17131915-       echo "$as_me:1329: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
    1714 +       echo "$as_me:1333: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
     1916+       echo "$as_me:1334: result: Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&5
    17151917 echo "${ECHO_T}Cached system name ($system_name) does not agree with actual ($cf_cv_system_name)" >&6
    17161918-       { { echo "$as_me:1331: error: \"Please remove config.cache and try again.\"" >&5
    1717 +       { { echo "$as_me:1335: error: \"Please remove config.cache and try again.\"" >&5
     1919+       { { echo "$as_me:1336: error: \"Please remove config.cache and try again.\"" >&5
    17181920 echo "$as_me: error: \"Please remove config.cache and try again.\"" >&2;}
    17191921    { (exit 1); exit 1; }; }
    17201922 fi
    1721 @@ -1336,7 +1340,7 @@
     1923@@ -1336,7 +1341,7 @@
    17221924 # Check whether --with-system-type or --without-system-type was given.
    17231925 if test "${with_system_type+set}" = set; then
    17241926   withval="$with_system_type"
    17251927-  { echo "$as_me:1339: WARNING: overriding system type to $withval" >&5
    1726 +  { echo "$as_me:1343: WARNING: overriding system type to $withval" >&5
     1928+  { echo "$as_me:1344: WARNING: overriding system type to $withval" >&5
    17271929 echo "$as_me: WARNING: overriding system type to $withval" >&2;}
    17281930  cf_cv_system_name=$withval
    17291931 fi;
    1730 @@ -1346,7 +1350,7 @@
     1932@@ -1346,7 +1351,7 @@
    17311933 
    17321934 ###    Default install-location
    17331935 
    17341936-echo "$as_me:1349: checking for prefix" >&5
    1735 +echo "$as_me:1353: checking for prefix" >&5
     1937+echo "$as_me:1354: checking for prefix" >&5
    17361938 echo $ECHO_N "checking for prefix... $ECHO_C" >&6
    17371939 if test "x$prefix" = "xNONE" ; then
    17381940        case "$cf_cv_system_name" in
    1739 @@ -1358,11 +1362,11 @@
     1941@@ -1358,11 +1363,11 @@
    17401942                ;;
    17411943        esac
    17421944 fi
    17431945-echo "$as_me:1361: result: $prefix" >&5
    1744 +echo "$as_me:1365: result: $prefix" >&5
     1946+echo "$as_me:1366: result: $prefix" >&5
    17451947 echo "${ECHO_T}$prefix" >&6
    17461948 
    17471949 if test "x$prefix" = "xNONE" ; then
    17481950-echo "$as_me:1365: checking for default include-directory" >&5
    1749 +echo "$as_me:1369: checking for default include-directory" >&5
     1951+echo "$as_me:1370: checking for default include-directory" >&5
    17501952 echo $ECHO_N "checking for default include-directory... $ECHO_C" >&6
    17511953 test -n "$verbose" && echo 1>&6
    17521954 for cf_symbol in \
    1753 @@ -1385,7 +1389,7 @@
     1955@@ -1385,7 +1390,7 @@
    17541956        fi
    17551957        test -n "$verbose"  && echo "   tested $cf_dir" 1>&6
    17561958 done
    17571959-echo "$as_me:1388: result: $includedir" >&5
    1758 +echo "$as_me:1392: result: $includedir" >&5
     1960+echo "$as_me:1393: result: $includedir" >&5
    17591961 echo "${ECHO_T}$includedir" >&6
    17601962 fi
    17611963 
    1762 @@ -1399,7 +1403,7 @@
     1964@@ -1399,7 +1404,7 @@
    17631965 if test -n "$ac_tool_prefix"; then
    17641966   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
    17651967 set dummy ${ac_tool_prefix}gcc; ac_word=$2
    17661968-echo "$as_me:1402: checking for $ac_word" >&5
    1767 +echo "$as_me:1406: checking for $ac_word" >&5
     1969+echo "$as_me:1407: checking for $ac_word" >&5
    17681970 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    17691971 if test "${ac_cv_prog_CC+set}" = set; then
    17701972   echo $ECHO_N "(cached) $ECHO_C" >&6
    1771 @@ -1414,7 +1418,7 @@
     1973@@ -1414,7 +1419,7 @@
    17721974   test -z "$ac_dir" && ac_dir=.
    17731975   $as_executable_p "$ac_dir/$ac_word" || continue
    17741976 ac_cv_prog_CC="${ac_tool_prefix}gcc"
    17751977-echo "$as_me:1417: found $ac_dir/$ac_word" >&5
    1776 +echo "$as_me:1421: found $ac_dir/$ac_word" >&5
     1978+echo "$as_me:1422: found $ac_dir/$ac_word" >&5
    17771979 break
    17781980 done
    17791981 
    1780 @@ -1422,10 +1426,10 @@
     1982@@ -1422,10 +1427,10 @@
    17811983 fi
    17821984 CC=$ac_cv_prog_CC
    17831985 if test -n "$CC"; then
    17841986-  echo "$as_me:1425: result: $CC" >&5
    1785 +  echo "$as_me:1429: result: $CC" >&5
     1987+  echo "$as_me:1430: result: $CC" >&5
    17861988 echo "${ECHO_T}$CC" >&6
    17871989 else
    17881990-  echo "$as_me:1428: result: no" >&5
    1789 +  echo "$as_me:1432: result: no" >&5
     1991+  echo "$as_me:1433: result: no" >&5
    17901992 echo "${ECHO_T}no" >&6
    17911993 fi
    17921994 
    1793 @@ -1434,7 +1438,7 @@
     1995@@ -1434,7 +1439,7 @@
    17941996   ac_ct_CC=$CC
    17951997   # Extract the first word of "gcc", so it can be a program name with args.
    17961998 set dummy gcc; ac_word=$2
    17971999-echo "$as_me:1437: checking for $ac_word" >&5
    1798 +echo "$as_me:1441: checking for $ac_word" >&5
     2000+echo "$as_me:1442: checking for $ac_word" >&5
    17992001 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    18002002 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
    18012003   echo $ECHO_N "(cached) $ECHO_C" >&6
    1802 @@ -1449,7 +1453,7 @@
     2004@@ -1449,7 +1454,7 @@
    18032005   test -z "$ac_dir" && ac_dir=.
    18042006   $as_executable_p "$ac_dir/$ac_word" || continue
    18052007 ac_cv_prog_ac_ct_CC="gcc"
    18062008-echo "$as_me:1452: found $ac_dir/$ac_word" >&5
    1807 +echo "$as_me:1456: found $ac_dir/$ac_word" >&5
     2009+echo "$as_me:1457: found $ac_dir/$ac_word" >&5
    18082010 break
    18092011 done
    18102012 
    1811 @@ -1457,10 +1461,10 @@
     2013@@ -1457,10 +1462,10 @@
    18122014 fi
    18132015 ac_ct_CC=$ac_cv_prog_ac_ct_CC
    18142016 if test -n "$ac_ct_CC"; then
    18152017-  echo "$as_me:1460: result: $ac_ct_CC" >&5
    1816 +  echo "$as_me:1464: result: $ac_ct_CC" >&5
     2018+  echo "$as_me:1465: result: $ac_ct_CC" >&5
    18172019 echo "${ECHO_T}$ac_ct_CC" >&6
    18182020 else
    18192021-  echo "$as_me:1463: result: no" >&5
    1820 +  echo "$as_me:1467: result: no" >&5
     2022+  echo "$as_me:1468: result: no" >&5
    18212023 echo "${ECHO_T}no" >&6
    18222024 fi
    18232025 
    1824 @@ -1473,7 +1477,7 @@
     2026@@ -1473,7 +1478,7 @@
    18252027   if test -n "$ac_tool_prefix"; then
    18262028   # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
    18272029 set dummy ${ac_tool_prefix}cc; ac_word=$2
    18282030-echo "$as_me:1476: checking for $ac_word" >&5
    1829 +echo "$as_me:1480: checking for $ac_word" >&5
     2031+echo "$as_me:1481: checking for $ac_word" >&5
    18302032 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    18312033 if test "${ac_cv_prog_CC+set}" = set; then
    18322034   echo $ECHO_N "(cached) $ECHO_C" >&6
    1833 @@ -1488,7 +1492,7 @@
     2035@@ -1488,7 +1493,7 @@
    18342036   test -z "$ac_dir" && ac_dir=.
    18352037   $as_executable_p "$ac_dir/$ac_word" || continue
    18362038 ac_cv_prog_CC="${ac_tool_prefix}cc"
    18372039-echo "$as_me:1491: found $ac_dir/$ac_word" >&5
    1838 +echo "$as_me:1495: found $ac_dir/$ac_word" >&5
     2040+echo "$as_me:1496: found $ac_dir/$ac_word" >&5
    18392041 break
    18402042 done
    18412043 
    1842 @@ -1496,10 +1500,10 @@
     2044@@ -1496,10 +1501,10 @@
    18432045 fi
    18442046 CC=$ac_cv_prog_CC
    18452047 if test -n "$CC"; then
    18462048-  echo "$as_me:1499: result: $CC" >&5
    1847 +  echo "$as_me:1503: result: $CC" >&5
     2049+  echo "$as_me:1504: result: $CC" >&5
    18482050 echo "${ECHO_T}$CC" >&6
    18492051 else
    18502052-  echo "$as_me:1502: result: no" >&5
    1851 +  echo "$as_me:1506: result: no" >&5
     2053+  echo "$as_me:1507: result: no" >&5
    18522054 echo "${ECHO_T}no" >&6
    18532055 fi
    18542056 
    1855 @@ -1508,7 +1512,7 @@
     2057@@ -1508,7 +1513,7 @@
    18562058   ac_ct_CC=$CC
    18572059   # Extract the first word of "cc", so it can be a program name with args.
    18582060 set dummy cc; ac_word=$2
    18592061-echo "$as_me:1511: checking for $ac_word" >&5
    1860 +echo "$as_me:1515: checking for $ac_word" >&5
     2062+echo "$as_me:1516: checking for $ac_word" >&5
    18612063 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    18622064 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
    18632065   echo $ECHO_N "(cached) $ECHO_C" >&6
    1864 @@ -1523,7 +1527,7 @@
     2066@@ -1523,7 +1528,7 @@
    18652067   test -z "$ac_dir" && ac_dir=.
    18662068   $as_executable_p "$ac_dir/$ac_word" || continue
    18672069 ac_cv_prog_ac_ct_CC="cc"
    18682070-echo "$as_me:1526: found $ac_dir/$ac_word" >&5
    1869 +echo "$as_me:1530: found $ac_dir/$ac_word" >&5
     2071+echo "$as_me:1531: found $ac_dir/$ac_word" >&5
    18702072 break
    18712073 done
    18722074 
    1873 @@ -1531,10 +1535,10 @@
     2075@@ -1531,10 +1536,10 @@
    18742076 fi
    18752077 ac_ct_CC=$ac_cv_prog_ac_ct_CC
    18762078 if test -n "$ac_ct_CC"; then
    18772079-  echo "$as_me:1534: result: $ac_ct_CC" >&5
    1878 +  echo "$as_me:1538: result: $ac_ct_CC" >&5
     2080+  echo "$as_me:1539: result: $ac_ct_CC" >&5
    18792081 echo "${ECHO_T}$ac_ct_CC" >&6
    18802082 else
    18812083-  echo "$as_me:1537: result: no" >&5
    1882 +  echo "$as_me:1541: result: no" >&5
     2084+  echo "$as_me:1542: result: no" >&5
    18832085 echo "${ECHO_T}no" >&6
    18842086 fi
    18852087 
    1886 @@ -1547,7 +1551,7 @@
     2088@@ -1547,7 +1552,7 @@
    18872089 if test -z "$CC"; then
    18882090   # Extract the first word of "cc", so it can be a program name with args.
    18892091 set dummy cc; ac_word=$2
    18902092-echo "$as_me:1550: checking for $ac_word" >&5
    1891 +echo "$as_me:1554: checking for $ac_word" >&5
     2093+echo "$as_me:1555: checking for $ac_word" >&5
    18922094 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    18932095 if test "${ac_cv_prog_CC+set}" = set; then
    18942096   echo $ECHO_N "(cached) $ECHO_C" >&6
    1895 @@ -1567,7 +1571,7 @@
     2097@@ -1567,7 +1572,7 @@
    18962098   continue
    18972099 fi
    18982100 ac_cv_prog_CC="cc"
    18992101-echo "$as_me:1570: found $ac_dir/$ac_word" >&5
    1900 +echo "$as_me:1574: found $ac_dir/$ac_word" >&5
     2102+echo "$as_me:1575: found $ac_dir/$ac_word" >&5
    19012103 break
    19022104 done
    19032105 
    1904 @@ -1589,10 +1593,10 @@
     2106@@ -1589,10 +1594,10 @@
    19052107 fi
    19062108 CC=$ac_cv_prog_CC
    19072109 if test -n "$CC"; then
    19082110-  echo "$as_me:1592: result: $CC" >&5
    1909 +  echo "$as_me:1596: result: $CC" >&5
     2111+  echo "$as_me:1597: result: $CC" >&5
    19102112 echo "${ECHO_T}$CC" >&6
    19112113 else
    19122114-  echo "$as_me:1595: result: no" >&5
    1913 +  echo "$as_me:1599: result: no" >&5
     2115+  echo "$as_me:1600: result: no" >&5
    19142116 echo "${ECHO_T}no" >&6
    19152117 fi
    19162118 
    1917 @@ -1603,7 +1607,7 @@
     2119@@ -1603,7 +1608,7 @@
    19182120   do
    19192121     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
    19202122 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
    19212123-echo "$as_me:1606: checking for $ac_word" >&5
    1922 +echo "$as_me:1610: checking for $ac_word" >&5
     2124+echo "$as_me:1611: checking for $ac_word" >&5
    19232125 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    19242126 if test "${ac_cv_prog_CC+set}" = set; then
    19252127   echo $ECHO_N "(cached) $ECHO_C" >&6
    1926 @@ -1618,7 +1622,7 @@
     2128@@ -1618,7 +1623,7 @@
    19272129   test -z "$ac_dir" && ac_dir=.
    19282130   $as_executable_p "$ac_dir/$ac_word" || continue
    19292131 ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
    19302132-echo "$as_me:1621: found $ac_dir/$ac_word" >&5
    1931 +echo "$as_me:1625: found $ac_dir/$ac_word" >&5
     2133+echo "$as_me:1626: found $ac_dir/$ac_word" >&5
    19322134 break
    19332135 done
    19342136 
    1935 @@ -1626,10 +1630,10 @@
     2137@@ -1626,10 +1631,10 @@
    19362138 fi
    19372139 CC=$ac_cv_prog_CC
    19382140 if test -n "$CC"; then
    19392141-  echo "$as_me:1629: result: $CC" >&5
    1940 +  echo "$as_me:1633: result: $CC" >&5
     2142+  echo "$as_me:1634: result: $CC" >&5
    19412143 echo "${ECHO_T}$CC" >&6
    19422144 else
    19432145-  echo "$as_me:1632: result: no" >&5
    1944 +  echo "$as_me:1636: result: no" >&5
     2146+  echo "$as_me:1637: result: no" >&5
    19452147 echo "${ECHO_T}no" >&6
    19462148 fi
    19472149 
    1948 @@ -1642,7 +1646,7 @@
     2150@@ -1642,7 +1647,7 @@
    19492151 do
    19502152   # Extract the first word of "$ac_prog", so it can be a program name with args.
    19512153 set dummy $ac_prog; ac_word=$2
    19522154-echo "$as_me:1645: checking for $ac_word" >&5
    1953 +echo "$as_me:1649: checking for $ac_word" >&5
     2155+echo "$as_me:1650: checking for $ac_word" >&5
    19542156 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    19552157 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
    19562158   echo $ECHO_N "(cached) $ECHO_C" >&6
    1957 @@ -1657,7 +1661,7 @@
     2159@@ -1657,7 +1662,7 @@
    19582160   test -z "$ac_dir" && ac_dir=.
    19592161   $as_executable_p "$ac_dir/$ac_word" || continue
    19602162 ac_cv_prog_ac_ct_CC="$ac_prog"
    19612163-echo "$as_me:1660: found $ac_dir/$ac_word" >&5
    1962 +echo "$as_me:1664: found $ac_dir/$ac_word" >&5
     2164+echo "$as_me:1665: found $ac_dir/$ac_word" >&5
    19632165 break
    19642166 done
    19652167 
    1966 @@ -1665,10 +1669,10 @@
     2168@@ -1665,10 +1670,10 @@
    19672169 fi
    19682170 ac_ct_CC=$ac_cv_prog_ac_ct_CC
    19692171 if test -n "$ac_ct_CC"; then
    19702172-  echo "$as_me:1668: result: $ac_ct_CC" >&5
    1971 +  echo "$as_me:1672: result: $ac_ct_CC" >&5
     2173+  echo "$as_me:1673: result: $ac_ct_CC" >&5
    19722174 echo "${ECHO_T}$ac_ct_CC" >&6
    19732175 else
    19742176-  echo "$as_me:1671: result: no" >&5
    1975 +  echo "$as_me:1675: result: no" >&5
     2177+  echo "$as_me:1676: result: no" >&5
    19762178 echo "${ECHO_T}no" >&6
    19772179 fi
    19782180 
    1979 @@ -1680,32 +1684,32 @@
     2181@@ -1680,32 +1685,32 @@
    19802182 
    19812183 fi
    19822184 
    19832185-test -z "$CC" && { { echo "$as_me:1683: error: no acceptable cc found in \$PATH" >&5
    1984 +test -z "$CC" && { { echo "$as_me:1687: error: no acceptable cc found in \$PATH" >&5
     2186+test -z "$CC" && { { echo "$as_me:1688: error: no acceptable cc found in \$PATH" >&5
    19852187 echo "$as_me: error: no acceptable cc found in \$PATH" >&2;}
    19862188    { (exit 1); exit 1; }; }
     
    19882190 # Provide some information about the compiler.
    19892191-echo "$as_me:1688:" \
    1990 +echo "$as_me:1692:" \
     2192+echo "$as_me:1693:" \
    19912193      "checking for C compiler version" >&5
    19922194 ac_compiler=`set X $ac_compile; echo $2`
    19932195-{ (eval echo "$as_me:1691: \"$ac_compiler --version </dev/null >&5\"") >&5
    1994 +{ (eval echo "$as_me:1695: \"$ac_compiler --version </dev/null >&5\"") >&5
     2196+{ (eval echo "$as_me:1696: \"$ac_compiler --version </dev/null >&5\"") >&5
    19952197   (eval $ac_compiler --version </dev/null >&5) 2>&5
    19962198   ac_status=$?
    19972199-  echo "$as_me:1694: \$? = $ac_status" >&5
    1998 +  echo "$as_me:1698: \$? = $ac_status" >&5
     2200+  echo "$as_me:1699: \$? = $ac_status" >&5
    19992201   (exit $ac_status); }
    20002202-{ (eval echo "$as_me:1696: \"$ac_compiler -v </dev/null >&5\"") >&5
    2001 +{ (eval echo "$as_me:1700: \"$ac_compiler -v </dev/null >&5\"") >&5
     2203+{ (eval echo "$as_me:1701: \"$ac_compiler -v </dev/null >&5\"") >&5
    20022204   (eval $ac_compiler -v </dev/null >&5) 2>&5
    20032205   ac_status=$?
    20042206-  echo "$as_me:1699: \$? = $ac_status" >&5
    2005 +  echo "$as_me:1703: \$? = $ac_status" >&5
     2207+  echo "$as_me:1704: \$? = $ac_status" >&5
    20062208   (exit $ac_status); }
    20072209-{ (eval echo "$as_me:1701: \"$ac_compiler -V </dev/null >&5\"") >&5
    2008 +{ (eval echo "$as_me:1705: \"$ac_compiler -V </dev/null >&5\"") >&5
     2210+{ (eval echo "$as_me:1706: \"$ac_compiler -V </dev/null >&5\"") >&5
    20092211   (eval $ac_compiler -V </dev/null >&5) 2>&5
    20102212   ac_status=$?
    20112213-  echo "$as_me:1704: \$? = $ac_status" >&5
    2012 +  echo "$as_me:1708: \$? = $ac_status" >&5
     2214+  echo "$as_me:1709: \$? = $ac_status" >&5
    20132215   (exit $ac_status); }
    20142216 
    20152217 cat >conftest.$ac_ext <<_ACEOF
    20162218-#line 1708 "configure"
    2017 +#line 1712 "configure"
     2219+#line 1713 "configure"
    20182220 #include "confdefs.h"
    20192221 
    20202222 int
    2021 @@ -1721,13 +1725,13 @@
     2223@@ -1721,13 +1726,13 @@
    20222224 # Try to create an executable without -o first, disregard a.out.
    20232225 # It will help us diagnose broken compilers, and finding out an intuition
    20242226 # of exeext.
    20252227-echo "$as_me:1724: checking for C compiler default output" >&5
    2026 +echo "$as_me:1728: checking for C compiler default output" >&5
     2228+echo "$as_me:1729: checking for C compiler default output" >&5
    20272229 echo $ECHO_N "checking for C compiler default output... $ECHO_C" >&6
    20282230 ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
    20292231-if { (eval echo "$as_me:1727: \"$ac_link_default\"") >&5
    2030 +if { (eval echo "$as_me:1731: \"$ac_link_default\"") >&5
     2232+if { (eval echo "$as_me:1732: \"$ac_link_default\"") >&5
    20312233   (eval $ac_link_default) 2>&5
    20322234   ac_status=$?
    20332235-  echo "$as_me:1730: \$? = $ac_status" >&5
    2034 +  echo "$as_me:1734: \$? = $ac_status" >&5
     2236+  echo "$as_me:1735: \$? = $ac_status" >&5
    20352237   (exit $ac_status); }; then
    20362238   # Find the output, starting from the most likely.  This scheme is
    20372239 # not robust to junk in `.', hence go to wildcards (a.*) only as a last
    2038 @@ -1736,7 +1740,7 @@
     2240@@ -1736,7 +1741,7 @@
    20392241                 ls a.out conftest 2>/dev/null;
    20402242                 ls a.* conftest.* 2>/dev/null`; do
     
    20452247             # certainly right.
    20462248             break;;
    2047 @@ -1750,34 +1754,34 @@
     2249@@ -1750,34 +1755,34 @@
    20482250 else
    20492251   echo "$as_me: failed program was:" >&5
    20502252 cat conftest.$ac_ext >&5
    20512253-{ { echo "$as_me:1753: error: C compiler cannot create executables" >&5
    2052 +{ { echo "$as_me:1757: error: C compiler cannot create executables" >&5
     2254+{ { echo "$as_me:1758: error: C compiler cannot create executables" >&5
    20532255 echo "$as_me: error: C compiler cannot create executables" >&2;}
    20542256    { (exit 77); exit 77; }; }
     
    20572259 ac_exeext=$ac_cv_exeext
    20582260-echo "$as_me:1759: result: $ac_file" >&5
    2059 +echo "$as_me:1763: result: $ac_file" >&5
     2261+echo "$as_me:1764: result: $ac_file" >&5
    20602262 echo "${ECHO_T}$ac_file" >&6
    20612263 
     
    20632265 # the compiler is broken, or we cross compile.
    20642266-echo "$as_me:1764: checking whether the C compiler works" >&5
    2065 +echo "$as_me:1768: checking whether the C compiler works" >&5
     2267+echo "$as_me:1769: checking whether the C compiler works" >&5
    20662268 echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6
    20672269 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
     
    20702272   if { ac_try='./$ac_file'
    20712273-  { (eval echo "$as_me:1770: \"$ac_try\"") >&5
    2072 +  { (eval echo "$as_me:1774: \"$ac_try\"") >&5
     2274+  { (eval echo "$as_me:1775: \"$ac_try\"") >&5
    20732275   (eval $ac_try) 2>&5
    20742276   ac_status=$?
    20752277-  echo "$as_me:1773: \$? = $ac_status" >&5
    2076 +  echo "$as_me:1777: \$? = $ac_status" >&5
     2278+  echo "$as_me:1778: \$? = $ac_status" >&5
    20772279   (exit $ac_status); }; }; then
    20782280     cross_compiling=no
     
    20822284     else
    20832285-       { { echo "$as_me:1780: error: cannot run C compiled programs.
    2084 +       { { echo "$as_me:1784: error: cannot run C compiled programs.
     2286+       { { echo "$as_me:1785: error: cannot run C compiled programs.
    20852287 If you meant to cross compile, use \`--host'." >&5
    20862288 echo "$as_me: error: cannot run C compiled programs.
    20872289 If you meant to cross compile, use \`--host'." >&2;}
    2088 @@ -1785,24 +1789,24 @@
     2290@@ -1785,24 +1790,24 @@
    20892291     fi
    20902292   fi
    20912293 fi
    20922294-echo "$as_me:1788: result: yes" >&5
    2093 +echo "$as_me:1792: result: yes" >&5
     2295+echo "$as_me:1793: result: yes" >&5
    20942296 echo "${ECHO_T}yes" >&6
    20952297 
     
    20992301 # the compiler is broken, or we cross compile.
    21002302-echo "$as_me:1795: checking whether we are cross compiling" >&5
    2101 +echo "$as_me:1799: checking whether we are cross compiling" >&5
     2303+echo "$as_me:1800: checking whether we are cross compiling" >&5
    21022304 echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6
    21032305-echo "$as_me:1797: result: $cross_compiling" >&5
    2104 +echo "$as_me:1801: result: $cross_compiling" >&5
     2306+echo "$as_me:1802: result: $cross_compiling" >&5
    21052307 echo "${ECHO_T}$cross_compiling" >&6
    21062308 
    21072309-echo "$as_me:1800: checking for executable suffix" >&5
    2108 +echo "$as_me:1804: checking for executable suffix" >&5
     2310+echo "$as_me:1805: checking for executable suffix" >&5
    21092311 echo $ECHO_N "checking for executable suffix... $ECHO_C" >&6
    21102312-if { (eval echo "$as_me:1802: \"$ac_link\"") >&5
    2111 +if { (eval echo "$as_me:1806: \"$ac_link\"") >&5
     2313+if { (eval echo "$as_me:1807: \"$ac_link\"") >&5
    21122314   (eval $ac_link) 2>&5
    21132315   ac_status=$?
    21142316-  echo "$as_me:1805: \$? = $ac_status" >&5
    2115 +  echo "$as_me:1809: \$? = $ac_status" >&5
     2317+  echo "$as_me:1810: \$? = $ac_status" >&5
    21162318   (exit $ac_status); }; then
    21172319   # If both `conftest.exe' and `conftest' are `present' (well, observable)
    21182320 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
    2119 @@ -1810,7 +1814,7 @@
     2321@@ -1810,7 +1815,7 @@
    21202322 # `rm'.
    21212323 for ac_file in `(ls conftest.exe; ls conftest; ls conftest.*) 2>/dev/null`; do
     
    21262328           export ac_cv_exeext
    21272329           break;;
    2128 @@ -1818,25 +1822,25 @@
     2330@@ -1818,25 +1823,25 @@
    21292331   esac
    21302332 done
    21312333 else
    21322334-  { { echo "$as_me:1821: error: cannot compute EXEEXT: cannot compile and link" >&5
    2133 +  { { echo "$as_me:1825: error: cannot compute EXEEXT: cannot compile and link" >&5
     2335+  { { echo "$as_me:1826: error: cannot compute EXEEXT: cannot compile and link" >&5
    21342336 echo "$as_me: error: cannot compute EXEEXT: cannot compile and link" >&2;}
    21352337    { (exit 1); exit 1; }; }
     
    21382340 rm -f conftest$ac_cv_exeext
    21392341-echo "$as_me:1827: result: $ac_cv_exeext" >&5
    2140 +echo "$as_me:1831: result: $ac_cv_exeext" >&5
     2342+echo "$as_me:1832: result: $ac_cv_exeext" >&5
    21412343 echo "${ECHO_T}$ac_cv_exeext" >&6
    21422344 
     
    21452347 ac_exeext=$EXEEXT
    21462348-echo "$as_me:1833: checking for object suffix" >&5
    2147 +echo "$as_me:1837: checking for object suffix" >&5
     2349+echo "$as_me:1838: checking for object suffix" >&5
    21482350 echo $ECHO_N "checking for object suffix... $ECHO_C" >&6
    21492351 if test "${ac_cv_objext+set}" = set; then
     
    21522354   cat >conftest.$ac_ext <<_ACEOF
    21532355-#line 1839 "configure"
    2154 +#line 1843 "configure"
     2356+#line 1844 "configure"
    21552357 #include "confdefs.h"
    21562358 
    21572359 int
    2158 @@ -1848,14 +1852,14 @@
     2360@@ -1848,14 +1853,14 @@
    21592361 }
    21602362 _ACEOF
    21612363 rm -f conftest.o conftest.obj
    21622364-if { (eval echo "$as_me:1851: \"$ac_compile\"") >&5
    2163 +if { (eval echo "$as_me:1855: \"$ac_compile\"") >&5
     2365+if { (eval echo "$as_me:1856: \"$ac_compile\"") >&5
    21642366   (eval $ac_compile) 2>&5
    21652367   ac_status=$?
    21662368-  echo "$as_me:1854: \$? = $ac_status" >&5
    2167 +  echo "$as_me:1858: \$? = $ac_status" >&5
     2369+  echo "$as_me:1859: \$? = $ac_status" >&5
    21682370   (exit $ac_status); }; then
    21692371   for ac_file in `(ls conftest.o conftest.obj; ls conftest.*) 2>/dev/null`; do
     
    21742376        break;;
    21752377   esac
    2176 @@ -1863,24 +1867,24 @@
     2378@@ -1863,24 +1868,24 @@
    21772379 else
    21782380   echo "$as_me: failed program was:" >&5
    21792381 cat conftest.$ac_ext >&5
    21802382-{ { echo "$as_me:1866: error: cannot compute OBJEXT: cannot compile" >&5
    2181 +{ { echo "$as_me:1870: error: cannot compute OBJEXT: cannot compile" >&5
     2383+{ { echo "$as_me:1871: error: cannot compute OBJEXT: cannot compile" >&5
    21822384 echo "$as_me: error: cannot compute OBJEXT: cannot compile" >&2;}
    21832385    { (exit 1); exit 1; }; }
     
    21872389 fi
    21882390-echo "$as_me:1873: result: $ac_cv_objext" >&5
    2189 +echo "$as_me:1877: result: $ac_cv_objext" >&5
     2391+echo "$as_me:1878: result: $ac_cv_objext" >&5
    21902392 echo "${ECHO_T}$ac_cv_objext" >&6
    21912393 OBJEXT=$ac_cv_objext
    21922394 ac_objext=$OBJEXT
    21932395-echo "$as_me:1877: checking whether we are using the GNU C compiler" >&5
    2194 +echo "$as_me:1881: checking whether we are using the GNU C compiler" >&5
     2396+echo "$as_me:1882: checking whether we are using the GNU C compiler" >&5
    21952397 echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6
    21962398 if test "${ac_cv_c_compiler_gnu+set}" = set; then
     
    21992401   cat >conftest.$ac_ext <<_ACEOF
    22002402-#line 1883 "configure"
    2201 +#line 1887 "configure"
     2403+#line 1888 "configure"
    22022404 #include "confdefs.h"
    22032405 
    22042406 int
    2205 @@ -1895,16 +1899,16 @@
     2407@@ -1895,16 +1900,16 @@
    22062408 }
    22072409 _ACEOF
    22082410 rm -f conftest.$ac_objext
    22092411-if { (eval echo "$as_me:1898: \"$ac_compile\"") >&5
    2210 +if { (eval echo "$as_me:1902: \"$ac_compile\"") >&5
     2412+if { (eval echo "$as_me:1903: \"$ac_compile\"") >&5
    22112413   (eval $ac_compile) 2>&5
    22122414   ac_status=$?
    22132415-  echo "$as_me:1901: \$? = $ac_status" >&5
    2214 +  echo "$as_me:1905: \$? = $ac_status" >&5
     2416+  echo "$as_me:1906: \$? = $ac_status" >&5
    22152417   (exit $ac_status); } &&
    22162418          { ac_try='test -s conftest.$ac_objext'
    22172419-  { (eval echo "$as_me:1904: \"$ac_try\"") >&5
    2218 +  { (eval echo "$as_me:1908: \"$ac_try\"") >&5
     2420+  { (eval echo "$as_me:1909: \"$ac_try\"") >&5
    22192421   (eval $ac_try) 2>&5
    22202422   ac_status=$?
    22212423-  echo "$as_me:1907: \$? = $ac_status" >&5
    2222 +  echo "$as_me:1911: \$? = $ac_status" >&5
     2424+  echo "$as_me:1912: \$? = $ac_status" >&5
    22232425   (exit $ac_status); }; }; then
    22242426   ac_compiler_gnu=yes
    22252427 else
    2226 @@ -1916,19 +1920,19 @@
     2428@@ -1916,19 +1921,19 @@
    22272429 ac_cv_c_compiler_gnu=$ac_compiler_gnu
    22282430 
    22292431 fi
    22302432-echo "$as_me:1919: result: $ac_cv_c_compiler_gnu" >&5
    2231 +echo "$as_me:1923: result: $ac_cv_c_compiler_gnu" >&5
     2433+echo "$as_me:1924: result: $ac_cv_c_compiler_gnu" >&5
    22322434 echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6
    22332435 GCC=`test $ac_compiler_gnu = yes && echo yes`
     
    22362438 CFLAGS="-g"
    22372439-echo "$as_me:1925: checking whether $CC accepts -g" >&5
    2238 +echo "$as_me:1929: checking whether $CC accepts -g" >&5
     2440+echo "$as_me:1930: checking whether $CC accepts -g" >&5
    22392441 echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6
    22402442 if test "${ac_cv_prog_cc_g+set}" = set; then
     
    22432445   cat >conftest.$ac_ext <<_ACEOF
    22442446-#line 1931 "configure"
    2245 +#line 1935 "configure"
     2447+#line 1936 "configure"
    22462448 #include "confdefs.h"
    22472449 
    22482450 int
    2249 @@ -1940,16 +1944,16 @@
     2451@@ -1940,16 +1945,16 @@
    22502452 }
    22512453 _ACEOF
    22522454 rm -f conftest.$ac_objext
    22532455-if { (eval echo "$as_me:1943: \"$ac_compile\"") >&5
    2254 +if { (eval echo "$as_me:1947: \"$ac_compile\"") >&5
     2456+if { (eval echo "$as_me:1948: \"$ac_compile\"") >&5
    22552457   (eval $ac_compile) 2>&5
    22562458   ac_status=$?
    22572459-  echo "$as_me:1946: \$? = $ac_status" >&5
    2258 +  echo "$as_me:1950: \$? = $ac_status" >&5
     2460+  echo "$as_me:1951: \$? = $ac_status" >&5
    22592461   (exit $ac_status); } &&
    22602462          { ac_try='test -s conftest.$ac_objext'
    22612463-  { (eval echo "$as_me:1949: \"$ac_try\"") >&5
    2262 +  { (eval echo "$as_me:1953: \"$ac_try\"") >&5
     2464+  { (eval echo "$as_me:1954: \"$ac_try\"") >&5
    22632465   (eval $ac_try) 2>&5
    22642466   ac_status=$?
    22652467-  echo "$as_me:1952: \$? = $ac_status" >&5
    2266 +  echo "$as_me:1956: \$? = $ac_status" >&5
     2468+  echo "$as_me:1957: \$? = $ac_status" >&5
    22672469   (exit $ac_status); }; }; then
    22682470   ac_cv_prog_cc_g=yes
    22692471 else
    2270 @@ -1959,7 +1963,7 @@
     2472@@ -1959,7 +1964,7 @@
    22712473 fi
    22722474 rm -f conftest.$ac_objext conftest.$ac_ext
    22732475 fi
    22742476-echo "$as_me:1962: result: $ac_cv_prog_cc_g" >&5
    2275 +echo "$as_me:1966: result: $ac_cv_prog_cc_g" >&5
     2477+echo "$as_me:1967: result: $ac_cv_prog_cc_g" >&5
    22762478 echo "${ECHO_T}$ac_cv_prog_cc_g" >&6
    22772479 if test "$ac_test_CFLAGS" = set; then
    22782480   CFLAGS=$ac_save_CFLAGS
    2279 @@ -1986,16 +1990,16 @@
     2481@@ -1986,16 +1991,16 @@
    22802482 #endif
    22812483 _ACEOF
    22822484 rm -f conftest.$ac_objext
    22832485-if { (eval echo "$as_me:1989: \"$ac_compile\"") >&5
    2284 +if { (eval echo "$as_me:1993: \"$ac_compile\"") >&5
     2486+if { (eval echo "$as_me:1994: \"$ac_compile\"") >&5
    22852487   (eval $ac_compile) 2>&5
    22862488   ac_status=$?
    22872489-  echo "$as_me:1992: \$? = $ac_status" >&5
    2288 +  echo "$as_me:1996: \$? = $ac_status" >&5
     2490+  echo "$as_me:1997: \$? = $ac_status" >&5
    22892491   (exit $ac_status); } &&
    22902492          { ac_try='test -s conftest.$ac_objext'
    22912493-  { (eval echo "$as_me:1995: \"$ac_try\"") >&5
    2292 +  { (eval echo "$as_me:1999: \"$ac_try\"") >&5
     2494+  { (eval echo "$as_me:2000: \"$ac_try\"") >&5
    22932495   (eval $ac_try) 2>&5
    22942496   ac_status=$?
    22952497-  echo "$as_me:1998: \$? = $ac_status" >&5
    2296 +  echo "$as_me:2002: \$? = $ac_status" >&5
     2498+  echo "$as_me:2003: \$? = $ac_status" >&5
    22972499   (exit $ac_status); }; }; then
    22982500   for ac_declaration in \
    22992501    ''\
    2300 @@ -2007,7 +2011,7 @@
     2502@@ -2007,7 +2012,7 @@
    23012503    'void exit (int);'
    23022504 do
    23032505   cat >conftest.$ac_ext <<_ACEOF
    23042506-#line 2010 "configure"
    2305 +#line 2014 "configure"
     2507+#line 2015 "configure"
    23062508 #include "confdefs.h"
    23072509 #include <stdlib.h>
    23082510 $ac_declaration
    2309 @@ -2020,16 +2024,16 @@
     2511@@ -2020,16 +2025,16 @@
    23102512 }
    23112513 _ACEOF
    23122514 rm -f conftest.$ac_objext
    23132515-if { (eval echo "$as_me:2023: \"$ac_compile\"") >&5
    2314 +if { (eval echo "$as_me:2027: \"$ac_compile\"") >&5
     2516+if { (eval echo "$as_me:2028: \"$ac_compile\"") >&5
    23152517   (eval $ac_compile) 2>&5
    23162518   ac_status=$?
    23172519-  echo "$as_me:2026: \$? = $ac_status" >&5
    2318 +  echo "$as_me:2030: \$? = $ac_status" >&5
     2520+  echo "$as_me:2031: \$? = $ac_status" >&5
    23192521   (exit $ac_status); } &&
    23202522          { ac_try='test -s conftest.$ac_objext'
    23212523-  { (eval echo "$as_me:2029: \"$ac_try\"") >&5
    2322 +  { (eval echo "$as_me:2033: \"$ac_try\"") >&5
     2524+  { (eval echo "$as_me:2034: \"$ac_try\"") >&5
    23232525   (eval $ac_try) 2>&5
    23242526   ac_status=$?
    23252527-  echo "$as_me:2032: \$? = $ac_status" >&5
    2326 +  echo "$as_me:2036: \$? = $ac_status" >&5
     2528+  echo "$as_me:2037: \$? = $ac_status" >&5
    23272529   (exit $ac_status); }; }; then
    23282530   :
    23292531 else
    2330 @@ -2039,7 +2043,7 @@
     2532@@ -2039,7 +2044,7 @@
    23312533 fi
    23322534 rm -f conftest.$ac_objext conftest.$ac_ext
    23332535   cat >conftest.$ac_ext <<_ACEOF
    23342536-#line 2042 "configure"
    2335 +#line 2046 "configure"
     2537+#line 2047 "configure"
    23362538 #include "confdefs.h"
    23372539 $ac_declaration
    23382540 int
    2339 @@ -2051,16 +2055,16 @@
     2541@@ -2051,16 +2056,16 @@
    23402542 }
    23412543 _ACEOF
    23422544 rm -f conftest.$ac_objext
    23432545-if { (eval echo "$as_me:2054: \"$ac_compile\"") >&5
    2344 +if { (eval echo "$as_me:2058: \"$ac_compile\"") >&5
     2546+if { (eval echo "$as_me:2059: \"$ac_compile\"") >&5
    23452547   (eval $ac_compile) 2>&5
    23462548   ac_status=$?
    23472549-  echo "$as_me:2057: \$? = $ac_status" >&5
    2348 +  echo "$as_me:2061: \$? = $ac_status" >&5
     2550+  echo "$as_me:2062: \$? = $ac_status" >&5
    23492551   (exit $ac_status); } &&
    23502552          { ac_try='test -s conftest.$ac_objext'
    23512553-  { (eval echo "$as_me:2060: \"$ac_try\"") >&5
    2352 +  { (eval echo "$as_me:2064: \"$ac_try\"") >&5
     2554+  { (eval echo "$as_me:2065: \"$ac_try\"") >&5
    23532555   (eval $ac_try) 2>&5
    23542556   ac_status=$?
    23552557-  echo "$as_me:2063: \$? = $ac_status" >&5
    2356 +  echo "$as_me:2067: \$? = $ac_status" >&5
     2558+  echo "$as_me:2068: \$? = $ac_status" >&5
    23572559   (exit $ac_status); }; }; then
    23582560   break
    23592561 else
    2360 @@ -2090,11 +2094,11 @@
     2562@@ -2090,11 +2095,11 @@
    23612563 
    23622564 GCC_VERSION=none
    23632565 if test "$GCC" = yes ; then
    23642566-       echo "$as_me:2093: checking version of $CC" >&5
    2365 +       echo "$as_me:2097: checking version of $CC" >&5
     2567+       echo "$as_me:2098: checking version of $CC" >&5
    23662568 echo $ECHO_N "checking version of $CC... $ECHO_C" >&6
    23672569        GCC_VERSION="`${CC} --version| sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
    23682570        test -z "$GCC_VERSION" && GCC_VERSION=unknown
    23692571-       echo "$as_me:2097: result: $GCC_VERSION" >&5
    2370 +       echo "$as_me:2101: result: $GCC_VERSION" >&5
     2572+       echo "$as_me:2102: result: $GCC_VERSION" >&5
    23712573 echo "${ECHO_T}$GCC_VERSION" >&6
    23722574 fi
    23732575 
    2374 @@ -2104,7 +2108,7 @@
     2576@@ -2104,7 +2109,7 @@
    23752577 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
    23762578 ac_compiler_gnu=$ac_cv_c_compiler_gnu
    23772579 ac_main_return=return
    23782580-echo "$as_me:2107: checking how to run the C preprocessor" >&5
    2379 +echo "$as_me:2111: checking how to run the C preprocessor" >&5
     2581+echo "$as_me:2112: checking how to run the C preprocessor" >&5
    23802582 echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6
    23812583 # On Suns, sometimes $CPP names a directory.
    23822584 if test -n "$CPP" && test -d "$CPP"; then
    2383 @@ -2125,18 +2129,18 @@
     2585@@ -2125,18 +2130,18 @@
    23842586   # On the NeXT, cc -E runs the code through the compiler's parser,
    23852587   # not just through cpp. "Syntax error" is here to catch this case.
    23862588   cat >conftest.$ac_ext <<_ACEOF
    23872589-#line 2128 "configure"
    2388 +#line 2132 "configure"
     2590+#line 2133 "configure"
    23892591 #include "confdefs.h"
    23902592 #include <assert.h>
     
    23922594 _ACEOF
    23932595-if { (eval echo "$as_me:2133: \"$ac_cpp conftest.$ac_ext\"") >&5
    2394 +if { (eval echo "$as_me:2137: \"$ac_cpp conftest.$ac_ext\"") >&5
     2596+if { (eval echo "$as_me:2138: \"$ac_cpp conftest.$ac_ext\"") >&5
    23952597   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    23962598   ac_status=$?
     
    23992601   cat conftest.err >&5
    24002602-  echo "$as_me:2139: \$? = $ac_status" >&5
    2401 +  echo "$as_me:2143: \$? = $ac_status" >&5
     2603+  echo "$as_me:2144: \$? = $ac_status" >&5
    24022604   (exit $ac_status); } >/dev/null; then
    24032605   if test -s conftest.err; then
    24042606     ac_cpp_err=$ac_c_preproc_warn_flag
    2405 @@ -2159,17 +2163,17 @@
     2607@@ -2159,17 +2164,17 @@
    24062608   # OK, works on sane cases.  Now check whether non-existent headers
    24072609   # can be detected and how.
    24082610   cat >conftest.$ac_ext <<_ACEOF
    24092611-#line 2162 "configure"
    2410 +#line 2166 "configure"
     2612+#line 2167 "configure"
    24112613 #include "confdefs.h"
    24122614 #include <ac_nonexistent.h>
    24132615 _ACEOF
    24142616-if { (eval echo "$as_me:2166: \"$ac_cpp conftest.$ac_ext\"") >&5
    2415 +if { (eval echo "$as_me:2170: \"$ac_cpp conftest.$ac_ext\"") >&5
     2617+if { (eval echo "$as_me:2171: \"$ac_cpp conftest.$ac_ext\"") >&5
    24162618   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    24172619   ac_status=$?
     
    24202622   cat conftest.err >&5
    24212623-  echo "$as_me:2172: \$? = $ac_status" >&5
    2422 +  echo "$as_me:2176: \$? = $ac_status" >&5
     2624+  echo "$as_me:2177: \$? = $ac_status" >&5
    24232625   (exit $ac_status); } >/dev/null; then
    24242626   if test -s conftest.err; then
    24252627     ac_cpp_err=$ac_c_preproc_warn_flag
    2426 @@ -2206,7 +2210,7 @@
     2628@@ -2206,7 +2211,7 @@
    24272629 else
    24282630   ac_cv_prog_CPP=$CPP
    24292631 fi
    24302632-echo "$as_me:2209: result: $CPP" >&5
    2431 +echo "$as_me:2213: result: $CPP" >&5
     2633+echo "$as_me:2214: result: $CPP" >&5
    24322634 echo "${ECHO_T}$CPP" >&6
    24332635 ac_preproc_ok=false
    24342636 for ac_c_preproc_warn_flag in '' yes
    2435 @@ -2216,18 +2220,18 @@
     2637@@ -2216,18 +2221,18 @@
    24362638   # On the NeXT, cc -E runs the code through the compiler's parser,
    24372639   # not just through cpp. "Syntax error" is here to catch this case.
    24382640   cat >conftest.$ac_ext <<_ACEOF
    24392641-#line 2219 "configure"
    2440 +#line 2223 "configure"
     2642+#line 2224 "configure"
    24412643 #include "confdefs.h"
    24422644 #include <assert.h>
     
    24442646 _ACEOF
    24452647-if { (eval echo "$as_me:2224: \"$ac_cpp conftest.$ac_ext\"") >&5
    2446 +if { (eval echo "$as_me:2228: \"$ac_cpp conftest.$ac_ext\"") >&5
     2648+if { (eval echo "$as_me:2229: \"$ac_cpp conftest.$ac_ext\"") >&5
    24472649   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    24482650   ac_status=$?
     
    24512653   cat conftest.err >&5
    24522654-  echo "$as_me:2230: \$? = $ac_status" >&5
    2453 +  echo "$as_me:2234: \$? = $ac_status" >&5
     2655+  echo "$as_me:2235: \$? = $ac_status" >&5
    24542656   (exit $ac_status); } >/dev/null; then
    24552657   if test -s conftest.err; then
    24562658     ac_cpp_err=$ac_c_preproc_warn_flag
    2457 @@ -2250,17 +2254,17 @@
     2659@@ -2250,17 +2255,17 @@
    24582660   # OK, works on sane cases.  Now check whether non-existent headers
    24592661   # can be detected and how.
    24602662   cat >conftest.$ac_ext <<_ACEOF
    24612663-#line 2253 "configure"
    2462 +#line 2257 "configure"
     2664+#line 2258 "configure"
    24632665 #include "confdefs.h"
    24642666 #include <ac_nonexistent.h>
    24652667 _ACEOF
    24662668-if { (eval echo "$as_me:2257: \"$ac_cpp conftest.$ac_ext\"") >&5
    2467 +if { (eval echo "$as_me:2261: \"$ac_cpp conftest.$ac_ext\"") >&5
     2669+if { (eval echo "$as_me:2262: \"$ac_cpp conftest.$ac_ext\"") >&5
    24682670   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    24692671   ac_status=$?
     
    24722674   cat conftest.err >&5
    24732675-  echo "$as_me:2263: \$? = $ac_status" >&5
    2474 +  echo "$as_me:2267: \$? = $ac_status" >&5
     2676+  echo "$as_me:2268: \$? = $ac_status" >&5
    24752677   (exit $ac_status); } >/dev/null; then
    24762678   if test -s conftest.err; then
    24772679     ac_cpp_err=$ac_c_preproc_warn_flag
    2478 @@ -2288,7 +2292,7 @@
     2680@@ -2288,7 +2293,7 @@
    24792681 if $ac_preproc_ok; then
    24802682   :
    24812683 else
    24822684-  { { echo "$as_me:2291: error: C preprocessor \"$CPP\" fails sanity check" >&5
    2483 +  { { echo "$as_me:2295: error: C preprocessor \"$CPP\" fails sanity check" >&5
     2685+  { { echo "$as_me:2296: error: C preprocessor \"$CPP\" fails sanity check" >&5
    24842686 echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check" >&2;}
    24852687    { (exit 1); exit 1; }; }
    24862688 fi
    2487 @@ -2301,14 +2305,14 @@
     2689@@ -2301,14 +2306,14 @@
    24882690 ac_main_return=return
    24892691 
    24902692 if test $ac_cv_c_compiler_gnu = yes; then
    24912693-    echo "$as_me:2304: checking whether $CC needs -traditional" >&5
    2492 +    echo "$as_me:2308: checking whether $CC needs -traditional" >&5
     2694+    echo "$as_me:2309: checking whether $CC needs -traditional" >&5
    24932695 echo $ECHO_N "checking whether $CC needs -traditional... $ECHO_C" >&6
    24942696 if test "${ac_cv_prog_gcc_traditional+set}" = set; then
     
    24982700   cat >conftest.$ac_ext <<_ACEOF
    24992701-#line 2311 "configure"
    2500 +#line 2315 "configure"
     2702+#line 2316 "configure"
    25012703 #include "confdefs.h"
    25022704 #include <sgtty.h>
    25032705 int Autoconf = TIOCGETP;
    2504 @@ -2323,7 +2327,7 @@
     2706@@ -2323,7 +2328,7 @@
    25052707 
    25062708   if test $ac_cv_prog_gcc_traditional = no; then
    25072709     cat >conftest.$ac_ext <<_ACEOF
    25082710-#line 2326 "configure"
    2509 +#line 2330 "configure"
     2711+#line 2331 "configure"
    25102712 #include "confdefs.h"
    25112713 #include <termio.h>
    25122714 int Autoconf = TCGETA;
    2513 @@ -2336,14 +2340,14 @@
     2715@@ -2336,14 +2341,14 @@
    25142716 
    25152717   fi
    25162718 fi
    25172719-echo "$as_me:2339: result: $ac_cv_prog_gcc_traditional" >&5
    2518 +echo "$as_me:2343: result: $ac_cv_prog_gcc_traditional" >&5
     2720+echo "$as_me:2344: result: $ac_cv_prog_gcc_traditional" >&5
    25192721 echo "${ECHO_T}$ac_cv_prog_gcc_traditional" >&6
    25202722   if test $ac_cv_prog_gcc_traditional = yes; then
     
    25242726 
    25252727-echo "$as_me:2346: checking whether $CC understands -c and -o together" >&5
    2526 +echo "$as_me:2350: checking whether $CC understands -c and -o together" >&5
     2728+echo "$as_me:2351: checking whether $CC understands -c and -o together" >&5
    25272729 echo $ECHO_N "checking whether $CC understands -c and -o together... $ECHO_C" >&6
    25282730 if test "${cf_cv_prog_CC_c_o+set}" = set; then
    25292731   echo $ECHO_N "(cached) $ECHO_C" >&6
    2530 @@ -2359,15 +2363,15 @@
     2732@@ -2359,15 +2364,15 @@
    25312733 # We do the test twice because some compilers refuse to overwrite an
    25322734 # existing .o file with -o, though they will create one.
    25332735 ac_try='$CC -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
    25342736-if { (eval echo "$as_me:2362: \"$ac_try\"") >&5
    2535 +if { (eval echo "$as_me:2366: \"$ac_try\"") >&5
     2737+if { (eval echo "$as_me:2367: \"$ac_try\"") >&5
    25362738   (eval $ac_try) 2>&5
    25372739   ac_status=$?
    25382740-  echo "$as_me:2365: \$? = $ac_status" >&5
    2539 +  echo "$as_me:2369: \$? = $ac_status" >&5
     2741+  echo "$as_me:2370: \$? = $ac_status" >&5
    25402742   (exit $ac_status); } &&
    25412743-  test -f conftest2.$ac_objext && { (eval echo "$as_me:2367: \"$ac_try\"") >&5
    2542 +  test -f conftest2.$ac_objext && { (eval echo "$as_me:2371: \"$ac_try\"") >&5
     2744+  test -f conftest2.$ac_objext && { (eval echo "$as_me:2372: \"$ac_try\"") >&5
    25432745   (eval $ac_try) 2>&5
    25442746   ac_status=$?
    25452747-  echo "$as_me:2370: \$? = $ac_status" >&5
    2546 +  echo "$as_me:2374: \$? = $ac_status" >&5
     2748+  echo "$as_me:2375: \$? = $ac_status" >&5
    25472749   (exit $ac_status); };
    25482750 then
    25492751   eval cf_cv_prog_CC_c_o=yes
    2550 @@ -2378,19 +2382,19 @@
     2752@@ -2378,19 +2383,19 @@
    25512753 
    25522754 fi
    25532755 if test $cf_cv_prog_CC_c_o = yes; then
    25542756-  echo "$as_me:2381: result: yes" >&5
    2555 +  echo "$as_me:2385: result: yes" >&5
     2757+  echo "$as_me:2386: result: yes" >&5
    25562758 echo "${ECHO_T}yes" >&6
    25572759 else
    25582760-  echo "$as_me:2384: result: no" >&5
    2559 +  echo "$as_me:2388: result: no" >&5
     2761+  echo "$as_me:2389: result: no" >&5
    25602762 echo "${ECHO_T}no" >&6
    25612763 fi
    25622764 
    25632765-echo "$as_me:2388: checking for POSIXized ISC" >&5
    2564 +echo "$as_me:2392: checking for POSIXized ISC" >&5
     2766+echo "$as_me:2393: checking for POSIXized ISC" >&5
    25652767 echo $ECHO_N "checking for POSIXized ISC... $ECHO_C" >&6
    25662768 if test -d /etc/conf/kconfig.d &&
     
    25682770 then
    25692771-  echo "$as_me:2393: result: yes" >&5
    2570 +  echo "$as_me:2397: result: yes" >&5
     2772+  echo "$as_me:2398: result: yes" >&5
    25712773 echo "${ECHO_T}yes" >&6
    25722774   ISC=yes # If later tests want to check for ISC.
    25732775 
    2574 @@ -2404,12 +2408,12 @@
     2776@@ -2404,12 +2409,12 @@
    25752777     CC="$CC -Xp"
    25762778   fi
    25772779 else
    25782780-  echo "$as_me:2407: result: no" >&5
    2579 +  echo "$as_me:2411: result: no" >&5
     2781+  echo "$as_me:2412: result: no" >&5
    25802782 echo "${ECHO_T}no" >&6
    25812783   ISC=
     
    25832785 
    25842786-echo "$as_me:2412: checking for ${CC-cc} option to accept ANSI C" >&5
    2585 +echo "$as_me:2416: checking for ${CC-cc} option to accept ANSI C" >&5
     2787+echo "$as_me:2417: checking for ${CC-cc} option to accept ANSI C" >&5
    25862788 echo $ECHO_N "checking for ${CC-cc} option to accept ANSI C... $ECHO_C" >&6
    25872789 if test "${cf_cv_ansi_cc+set}" = set; then
    25882790   echo $ECHO_N "(cached) $ECHO_C" >&6
    2589 @@ -2494,7 +2498,7 @@
     2791@@ -2494,7 +2499,7 @@
    25902792 
    25912793 if test -n "$cf_new_cppflags" ; then
     
    25962798 
    25972799 if test -n "$cf_new_extra_cppflags" ; then
    2598 @@ -2503,7 +2507,7 @@
     2800@@ -2503,7 +2508,7 @@
    25992801 fi
    26002802 
    26012803        cat >conftest.$ac_ext <<_ACEOF
    26022804-#line 2506 "configure"
    2603 +#line 2510 "configure"
     2805+#line 2511 "configure"
    26042806 #include "confdefs.h"
    26052807 
    26062808 #ifndef CC_HAS_PROTOS
    2607 @@ -2524,16 +2528,16 @@
     2809@@ -2524,16 +2529,16 @@
    26082810 }
    26092811 _ACEOF
    26102812 rm -f conftest.$ac_objext
    26112813-if { (eval echo "$as_me:2527: \"$ac_compile\"") >&5
    2612 +if { (eval echo "$as_me:2531: \"$ac_compile\"") >&5
     2814+if { (eval echo "$as_me:2532: \"$ac_compile\"") >&5
    26132815   (eval $ac_compile) 2>&5
    26142816   ac_status=$?
    26152817-  echo "$as_me:2530: \$? = $ac_status" >&5
    2616 +  echo "$as_me:2534: \$? = $ac_status" >&5
     2818+  echo "$as_me:2535: \$? = $ac_status" >&5
    26172819   (exit $ac_status); } &&
    26182820          { ac_try='test -s conftest.$ac_objext'
    26192821-  { (eval echo "$as_me:2533: \"$ac_try\"") >&5
    2620 +  { (eval echo "$as_me:2537: \"$ac_try\"") >&5
     2822+  { (eval echo "$as_me:2538: \"$ac_try\"") >&5
    26212823   (eval $ac_try) 2>&5
    26222824   ac_status=$?
    26232825-  echo "$as_me:2536: \$? = $ac_status" >&5
    2624 +  echo "$as_me:2540: \$? = $ac_status" >&5
     2826+  echo "$as_me:2541: \$? = $ac_status" >&5
    26252827   (exit $ac_status); }; }; then
    26262828   cf_cv_ansi_cc="$cf_arg"; break
    26272829 else
    2628 @@ -2546,7 +2550,7 @@
     2830@@ -2546,7 +2551,7 @@
    26292831 CPPFLAGS="$cf_save_CPPFLAGS"
    26302832 
    26312833 fi
    26322834-echo "$as_me:2549: result: $cf_cv_ansi_cc" >&5
    2633 +echo "$as_me:2553: result: $cf_cv_ansi_cc" >&5
     2835+echo "$as_me:2554: result: $cf_cv_ansi_cc" >&5
    26342836 echo "${ECHO_T}$cf_cv_ansi_cc" >&6
    26352837 
    26362838 if test "$cf_cv_ansi_cc" != "no"; then
    2637 @@ -2612,7 +2616,7 @@
     2839@@ -2612,7 +2617,7 @@
    26382840 
    26392841 if test -n "$cf_new_cppflags" ; then
     
    26442846 
    26452847 if test -n "$cf_new_extra_cppflags" ; then
    2646 @@ -2629,7 +2633,7 @@
     2848@@ -2629,7 +2634,7 @@
    26472849 fi
    26482850 
    26492851 if test "$cf_cv_ansi_cc" = "no"; then
    26502852-       { { echo "$as_me:2632: error: Your compiler does not appear to recognize prototypes.
    2651 +       { { echo "$as_me:2636: error: Your compiler does not appear to recognize prototypes.
     2853+       { { echo "$as_me:2637: error: Your compiler does not appear to recognize prototypes.
    26522854 You have the following choices:
    26532855        a. adjust your compiler options
    26542856        b. get an up-to-date compiler
    2655 @@ -2663,13 +2667,13 @@
     2857@@ -2663,13 +2668,13 @@
    26562858   LDCONFIG=:
    26572859 else
     
    26652867 set dummy ldconfig; ac_word=$2
    26662868-echo "$as_me:2672: checking for $ac_word" >&5
    2667 +echo "$as_me:2676: checking for $ac_word" >&5
     2869+echo "$as_me:2677: checking for $ac_word" >&5
    26682870 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    26692871 if test "${ac_cv_path_LDCONFIG+set}" = set; then
    26702872   echo $ECHO_N "(cached) $ECHO_C" >&6
    2671 @@ -2686,7 +2690,7 @@
     2873@@ -2686,7 +2691,7 @@
    26722874   test -z "$ac_dir" && ac_dir=.
    26732875   if $as_executable_p "$ac_dir/$ac_word"; then
    26742876    ac_cv_path_LDCONFIG="$ac_dir/$ac_word"
    26752877-   echo "$as_me:2689: found $ac_dir/$ac_word" >&5
    2676 +   echo "$as_me:2693: found $ac_dir/$ac_word" >&5
     2878+   echo "$as_me:2694: found $ac_dir/$ac_word" >&5
    26772879    break
    26782880 fi
    26792881 done
    2680 @@ -2697,10 +2701,10 @@
     2882@@ -2697,10 +2702,10 @@
    26812883 LDCONFIG=$ac_cv_path_LDCONFIG
    26822884 
    26832885 if test -n "$LDCONFIG"; then
    26842886-  echo "$as_me:2700: result: $LDCONFIG" >&5
    2685 +  echo "$as_me:2704: result: $LDCONFIG" >&5
     2887+  echo "$as_me:2705: result: $LDCONFIG" >&5
    26862888 echo "${ECHO_T}$LDCONFIG" >&6
    26872889 else
    26882890-  echo "$as_me:2703: result: no" >&5
    2689 +  echo "$as_me:2707: result: no" >&5
     2891+  echo "$as_me:2708: result: no" >&5
    26902892 echo "${ECHO_T}no" >&6
    26912893 fi
    26922894 
    2693 @@ -2708,7 +2712,7 @@
     2895@@ -2708,7 +2713,7 @@
    26942896 esac
    26952897 fi
    26962898 
    26972899-echo "$as_me:2711: checking if you want to ensure bool is consistent with C++" >&5
    2698 +echo "$as_me:2715: checking if you want to ensure bool is consistent with C++" >&5
     2900+echo "$as_me:2716: checking if you want to ensure bool is consistent with C++" >&5
    26992901 echo $ECHO_N "checking if you want to ensure bool is consistent with C++... $ECHO_C" >&6
    27002902 
    27012903 # Check whether --with-cxx or --without-cxx was given.
    2702 @@ -2718,7 +2722,7 @@
     2904@@ -2718,7 +2723,7 @@
    27032905 else
    27042906   cf_with_cxx=yes
    27052907 fi;
    27062908-echo "$as_me:2721: result: $cf_with_cxx" >&5
    2707 +echo "$as_me:2725: result: $cf_with_cxx" >&5
     2909+echo "$as_me:2726: result: $cf_with_cxx" >&5
    27082910 echo "${ECHO_T}$cf_with_cxx" >&6
    27092911 if test "X$cf_with_cxx" = Xno ; then
    27102912        CXX=""
    2711 @@ -2736,7 +2740,7 @@
     2913@@ -2736,7 +2741,7 @@
    27122914   do
    27132915     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
    27142916 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
    27152917-echo "$as_me:2739: checking for $ac_word" >&5
    2716 +echo "$as_me:2743: checking for $ac_word" >&5
     2918+echo "$as_me:2744: checking for $ac_word" >&5
    27172919 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    27182920 if test "${ac_cv_prog_CXX+set}" = set; then
    27192921   echo $ECHO_N "(cached) $ECHO_C" >&6
    2720 @@ -2751,7 +2755,7 @@
     2922@@ -2751,7 +2756,7 @@
    27212923   test -z "$ac_dir" && ac_dir=.
    27222924   $as_executable_p "$ac_dir/$ac_word" || continue
    27232925 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog"
    27242926-echo "$as_me:2754: found $ac_dir/$ac_word" >&5
    2725 +echo "$as_me:2758: found $ac_dir/$ac_word" >&5
     2927+echo "$as_me:2759: found $ac_dir/$ac_word" >&5
    27262928 break
    27272929 done
    27282930 
    2729 @@ -2759,10 +2763,10 @@
     2931@@ -2759,10 +2764,10 @@
    27302932 fi
    27312933 CXX=$ac_cv_prog_CXX
    27322934 if test -n "$CXX"; then
    27332935-  echo "$as_me:2762: result: $CXX" >&5
    2734 +  echo "$as_me:2766: result: $CXX" >&5
     2936+  echo "$as_me:2767: result: $CXX" >&5
    27352937 echo "${ECHO_T}$CXX" >&6
    27362938 else
    27372939-  echo "$as_me:2765: result: no" >&5
    2738 +  echo "$as_me:2769: result: no" >&5
     2940+  echo "$as_me:2770: result: no" >&5
    27392941 echo "${ECHO_T}no" >&6
    27402942 fi
    27412943 
    2742 @@ -2775,7 +2779,7 @@
     2944@@ -2775,7 +2780,7 @@
    27432945 do
    27442946   # Extract the first word of "$ac_prog", so it can be a program name with args.
    27452947 set dummy $ac_prog; ac_word=$2
    27462948-echo "$as_me:2778: checking for $ac_word" >&5
    2747 +echo "$as_me:2782: checking for $ac_word" >&5
     2949+echo "$as_me:2783: checking for $ac_word" >&5
    27482950 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    27492951 if test "${ac_cv_prog_ac_ct_CXX+set}" = set; then
    27502952   echo $ECHO_N "(cached) $ECHO_C" >&6
    2751 @@ -2790,7 +2794,7 @@
     2953@@ -2790,7 +2795,7 @@
    27522954   test -z "$ac_dir" && ac_dir=.
    27532955   $as_executable_p "$ac_dir/$ac_word" || continue
    27542956 ac_cv_prog_ac_ct_CXX="$ac_prog"
    27552957-echo "$as_me:2793: found $ac_dir/$ac_word" >&5
    2756 +echo "$as_me:2797: found $ac_dir/$ac_word" >&5
     2958+echo "$as_me:2798: found $ac_dir/$ac_word" >&5
    27572959 break
    27582960 done
    27592961 
    2760 @@ -2798,10 +2802,10 @@
     2962@@ -2798,10 +2803,10 @@
    27612963 fi
    27622964 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX
    27632965 if test -n "$ac_ct_CXX"; then
    27642966-  echo "$as_me:2801: result: $ac_ct_CXX" >&5
    2765 +  echo "$as_me:2805: result: $ac_ct_CXX" >&5
     2967+  echo "$as_me:2806: result: $ac_ct_CXX" >&5
    27662968 echo "${ECHO_T}$ac_ct_CXX" >&6
    27672969 else
    27682970-  echo "$as_me:2804: result: no" >&5
    2769 +  echo "$as_me:2808: result: no" >&5
     2971+  echo "$as_me:2809: result: no" >&5
    27702972 echo "${ECHO_T}no" >&6
    27712973 fi
    27722974 
    2773 @@ -2813,32 +2817,32 @@
     2975@@ -2813,32 +2818,32 @@
    27742976 fi
    27752977 
    27762978 # Provide some information about the compiler.
    27772979-echo "$as_me:2816:" \
    2778 +echo "$as_me:2820:" \
     2980+echo "$as_me:2821:" \
    27792981      "checking for C++ compiler version" >&5
    27802982 ac_compiler=`set X $ac_compile; echo $2`
    27812983-{ (eval echo "$as_me:2819: \"$ac_compiler --version </dev/null >&5\"") >&5
    2782 +{ (eval echo "$as_me:2823: \"$ac_compiler --version </dev/null >&5\"") >&5
     2984+{ (eval echo "$as_me:2824: \"$ac_compiler --version </dev/null >&5\"") >&5
    27832985   (eval $ac_compiler --version </dev/null >&5) 2>&5
    27842986   ac_status=$?
    27852987-  echo "$as_me:2822: \$? = $ac_status" >&5
    2786 +  echo "$as_me:2826: \$? = $ac_status" >&5
     2988+  echo "$as_me:2827: \$? = $ac_status" >&5
    27872989   (exit $ac_status); }
    27882990-{ (eval echo "$as_me:2824: \"$ac_compiler -v </dev/null >&5\"") >&5
    2789 +{ (eval echo "$as_me:2828: \"$ac_compiler -v </dev/null >&5\"") >&5
     2991+{ (eval echo "$as_me:2829: \"$ac_compiler -v </dev/null >&5\"") >&5
    27902992   (eval $ac_compiler -v </dev/null >&5) 2>&5
    27912993   ac_status=$?
    27922994-  echo "$as_me:2827: \$? = $ac_status" >&5
    2793 +  echo "$as_me:2831: \$? = $ac_status" >&5
     2995+  echo "$as_me:2832: \$? = $ac_status" >&5
    27942996   (exit $ac_status); }
    27952997-{ (eval echo "$as_me:2829: \"$ac_compiler -V </dev/null >&5\"") >&5
    2796 +{ (eval echo "$as_me:2833: \"$ac_compiler -V </dev/null >&5\"") >&5
     2998+{ (eval echo "$as_me:2834: \"$ac_compiler -V </dev/null >&5\"") >&5
    27972999   (eval $ac_compiler -V </dev/null >&5) 2>&5
    27983000   ac_status=$?
    27993001-  echo "$as_me:2832: \$? = $ac_status" >&5
    2800 +  echo "$as_me:2836: \$? = $ac_status" >&5
     3002+  echo "$as_me:2837: \$? = $ac_status" >&5
    28013003   (exit $ac_status); }
    28023004 
    28033005-echo "$as_me:2835: checking whether we are using the GNU C++ compiler" >&5
    2804 +echo "$as_me:2839: checking whether we are using the GNU C++ compiler" >&5
     3006+echo "$as_me:2840: checking whether we are using the GNU C++ compiler" >&5
    28053007 echo $ECHO_N "checking whether we are using the GNU C++ compiler... $ECHO_C" >&6
    28063008 if test "${ac_cv_cxx_compiler_gnu+set}" = set; then
     
    28093011   cat >conftest.$ac_ext <<_ACEOF
    28103012-#line 2841 "configure"
    2811 +#line 2845 "configure"
     3013+#line 2846 "configure"
    28123014 #include "confdefs.h"
    28133015 
    28143016 int
    2815 @@ -2853,16 +2857,16 @@
     3017@@ -2853,16 +2858,16 @@
    28163018 }
    28173019 _ACEOF
    28183020 rm -f conftest.$ac_objext
    28193021-if { (eval echo "$as_me:2856: \"$ac_compile\"") >&5
    2820 +if { (eval echo "$as_me:2860: \"$ac_compile\"") >&5
     3022+if { (eval echo "$as_me:2861: \"$ac_compile\"") >&5
    28213023   (eval $ac_compile) 2>&5
    28223024   ac_status=$?
    28233025-  echo "$as_me:2859: \$? = $ac_status" >&5
    2824 +  echo "$as_me:2863: \$? = $ac_status" >&5
     3026+  echo "$as_me:2864: \$? = $ac_status" >&5
    28253027   (exit $ac_status); } &&
    28263028          { ac_try='test -s conftest.$ac_objext'
    28273029-  { (eval echo "$as_me:2862: \"$ac_try\"") >&5
    2828 +  { (eval echo "$as_me:2866: \"$ac_try\"") >&5
     3030+  { (eval echo "$as_me:2867: \"$ac_try\"") >&5
    28293031   (eval $ac_try) 2>&5
    28303032   ac_status=$?
    28313033-  echo "$as_me:2865: \$? = $ac_status" >&5
    2832 +  echo "$as_me:2869: \$? = $ac_status" >&5
     3034+  echo "$as_me:2870: \$? = $ac_status" >&5
    28333035   (exit $ac_status); }; }; then
    28343036   ac_compiler_gnu=yes
    28353037 else
    2836 @@ -2874,19 +2878,19 @@
     3038@@ -2874,19 +2879,19 @@
    28373039 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu
    28383040 
    28393041 fi
    28403042-echo "$as_me:2877: result: $ac_cv_cxx_compiler_gnu" >&5
    2841 +echo "$as_me:2881: result: $ac_cv_cxx_compiler_gnu" >&5
     3043+echo "$as_me:2882: result: $ac_cv_cxx_compiler_gnu" >&5
    28423044 echo "${ECHO_T}$ac_cv_cxx_compiler_gnu" >&6
    28433045 GXX=`test $ac_compiler_gnu = yes && echo yes`
     
    28463048 CXXFLAGS="-g"
    28473049-echo "$as_me:2883: checking whether $CXX accepts -g" >&5
    2848 +echo "$as_me:2887: checking whether $CXX accepts -g" >&5
     3050+echo "$as_me:2888: checking whether $CXX accepts -g" >&5
    28493051 echo $ECHO_N "checking whether $CXX accepts -g... $ECHO_C" >&6
    28503052 if test "${ac_cv_prog_cxx_g+set}" = set; then
     
    28533055   cat >conftest.$ac_ext <<_ACEOF
    28543056-#line 2889 "configure"
    2855 +#line 2893 "configure"
     3057+#line 2894 "configure"
    28563058 #include "confdefs.h"
    28573059 
    28583060 int
    2859 @@ -2898,16 +2902,16 @@
     3061@@ -2898,16 +2903,16 @@
    28603062 }
    28613063 _ACEOF
    28623064 rm -f conftest.$ac_objext
    28633065-if { (eval echo "$as_me:2901: \"$ac_compile\"") >&5
    2864 +if { (eval echo "$as_me:2905: \"$ac_compile\"") >&5
     3066+if { (eval echo "$as_me:2906: \"$ac_compile\"") >&5
    28653067   (eval $ac_compile) 2>&5
    28663068   ac_status=$?
    28673069-  echo "$as_me:2904: \$? = $ac_status" >&5
    2868 +  echo "$as_me:2908: \$? = $ac_status" >&5
     3070+  echo "$as_me:2909: \$? = $ac_status" >&5
    28693071   (exit $ac_status); } &&
    28703072          { ac_try='test -s conftest.$ac_objext'
    28713073-  { (eval echo "$as_me:2907: \"$ac_try\"") >&5
    2872 +  { (eval echo "$as_me:2911: \"$ac_try\"") >&5
     3074+  { (eval echo "$as_me:2912: \"$ac_try\"") >&5
    28733075   (eval $ac_try) 2>&5
    28743076   ac_status=$?
    28753077-  echo "$as_me:2910: \$? = $ac_status" >&5
    2876 +  echo "$as_me:2914: \$? = $ac_status" >&5
     3078+  echo "$as_me:2915: \$? = $ac_status" >&5
    28773079   (exit $ac_status); }; }; then
    28783080   ac_cv_prog_cxx_g=yes
    28793081 else
    2880 @@ -2917,7 +2921,7 @@
     3082@@ -2917,7 +2922,7 @@
    28813083 fi
    28823084 rm -f conftest.$ac_objext conftest.$ac_ext
    28833085 fi
    28843086-echo "$as_me:2920: result: $ac_cv_prog_cxx_g" >&5
    2885 +echo "$as_me:2924: result: $ac_cv_prog_cxx_g" >&5
     3087+echo "$as_me:2925: result: $ac_cv_prog_cxx_g" >&5
    28863088 echo "${ECHO_T}$ac_cv_prog_cxx_g" >&6
    28873089 if test "$ac_test_CXXFLAGS" = set; then
    28883090   CXXFLAGS=$ac_save_CXXFLAGS
    2889 @@ -2944,7 +2948,7 @@
     3091@@ -2944,7 +2949,7 @@
    28903092    'void exit (int);'
    28913093 do
    28923094   cat >conftest.$ac_ext <<_ACEOF
    28933095-#line 2947 "configure"
    2894 +#line 2951 "configure"
     3096+#line 2952 "configure"
    28953097 #include "confdefs.h"
    28963098 #include <stdlib.h>
    28973099 $ac_declaration
    2898 @@ -2957,16 +2961,16 @@
     3100@@ -2957,16 +2962,16 @@
    28993101 }
    29003102 _ACEOF
    29013103 rm -f conftest.$ac_objext
    29023104-if { (eval echo "$as_me:2960: \"$ac_compile\"") >&5
    2903 +if { (eval echo "$as_me:2964: \"$ac_compile\"") >&5
     3105+if { (eval echo "$as_me:2965: \"$ac_compile\"") >&5
    29043106   (eval $ac_compile) 2>&5
    29053107   ac_status=$?
    29063108-  echo "$as_me:2963: \$? = $ac_status" >&5
    2907 +  echo "$as_me:2967: \$? = $ac_status" >&5
     3109+  echo "$as_me:2968: \$? = $ac_status" >&5
    29083110   (exit $ac_status); } &&
    29093111          { ac_try='test -s conftest.$ac_objext'
    29103112-  { (eval echo "$as_me:2966: \"$ac_try\"") >&5
    2911 +  { (eval echo "$as_me:2970: \"$ac_try\"") >&5
     3113+  { (eval echo "$as_me:2971: \"$ac_try\"") >&5
    29123114   (eval $ac_try) 2>&5
    29133115   ac_status=$?
    29143116-  echo "$as_me:2969: \$? = $ac_status" >&5
    2915 +  echo "$as_me:2973: \$? = $ac_status" >&5
     3117+  echo "$as_me:2974: \$? = $ac_status" >&5
    29163118   (exit $ac_status); }; }; then
    29173119   :
    29183120 else
    2919 @@ -2976,7 +2980,7 @@
     3121@@ -2976,7 +2981,7 @@
    29203122 fi
    29213123 rm -f conftest.$ac_objext conftest.$ac_ext
    29223124   cat >conftest.$ac_ext <<_ACEOF
    29233125-#line 2979 "configure"
    2924 +#line 2983 "configure"
     3126+#line 2984 "configure"
    29253127 #include "confdefs.h"
    29263128 $ac_declaration
    29273129 int
    2928 @@ -2988,16 +2992,16 @@
     3130@@ -2988,16 +2993,16 @@
    29293131 }
    29303132 _ACEOF
    29313133 rm -f conftest.$ac_objext
    29323134-if { (eval echo "$as_me:2991: \"$ac_compile\"") >&5
    2933 +if { (eval echo "$as_me:2995: \"$ac_compile\"") >&5
     3135+if { (eval echo "$as_me:2996: \"$ac_compile\"") >&5
    29343136   (eval $ac_compile) 2>&5
    29353137   ac_status=$?
    29363138-  echo "$as_me:2994: \$? = $ac_status" >&5
    2937 +  echo "$as_me:2998: \$? = $ac_status" >&5
     3139+  echo "$as_me:2999: \$? = $ac_status" >&5
    29383140   (exit $ac_status); } &&
    29393141          { ac_try='test -s conftest.$ac_objext'
    29403142-  { (eval echo "$as_me:2997: \"$ac_try\"") >&5
    2941 +  { (eval echo "$as_me:3001: \"$ac_try\"") >&5
     3143+  { (eval echo "$as_me:3002: \"$ac_try\"") >&5
    29423144   (eval $ac_try) 2>&5
    29433145   ac_status=$?
    29443146-  echo "$as_me:3000: \$? = $ac_status" >&5
    2945 +  echo "$as_me:3004: \$? = $ac_status" >&5
     3147+  echo "$as_me:3005: \$? = $ac_status" >&5
    29463148   (exit $ac_status); }; }; then
    29473149   break
    29483150 else
    2949 @@ -3024,7 +3028,7 @@
     3151@@ -3024,7 +3029,7 @@
    29503152        if test "$CXX" = "g++" ; then
    29513153                # Extract the first word of "g++", so it can be a program name with args.
    29523154 set dummy g++; ac_word=$2
    29533155-echo "$as_me:3027: checking for $ac_word" >&5
    2954 +echo "$as_me:3031: checking for $ac_word" >&5
     3156+echo "$as_me:3032: checking for $ac_word" >&5
    29553157 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    29563158 if test "${ac_cv_path_CXX+set}" = set; then
    29573159   echo $ECHO_N "(cached) $ECHO_C" >&6
    2958 @@ -3041,7 +3045,7 @@
     3160@@ -3041,7 +3046,7 @@
    29593161   test -z "$ac_dir" && ac_dir=.
    29603162   if $as_executable_p "$ac_dir/$ac_word"; then
    29613163    ac_cv_path_CXX="$ac_dir/$ac_word"
    29623164-   echo "$as_me:3044: found $ac_dir/$ac_word" >&5
    2963 +   echo "$as_me:3048: found $ac_dir/$ac_word" >&5
     3165+   echo "$as_me:3049: found $ac_dir/$ac_word" >&5
    29643166    break
    29653167 fi
    29663168 done
    2967 @@ -3052,16 +3056,16 @@
     3169@@ -3052,16 +3057,16 @@
    29683170 CXX=$ac_cv_path_CXX
    29693171 
    29703172 if test -n "$CXX"; then
    29713173-  echo "$as_me:3055: result: $CXX" >&5
    2972 +  echo "$as_me:3059: result: $CXX" >&5
     3174+  echo "$as_me:3060: result: $CXX" >&5
    29733175 echo "${ECHO_T}$CXX" >&6
    29743176 else
    29753177-  echo "$as_me:3058: result: no" >&5
    2976 +  echo "$as_me:3062: result: no" >&5
     3178+  echo "$as_me:3063: result: no" >&5
    29773179 echo "${ECHO_T}no" >&6
    29783180 fi
     
    29813183        if test "$CXX" = "g++" ; then
    29823184-               { echo "$as_me:3064: WARNING: ignoring hardcoded g++" >&5
    2983 +               { echo "$as_me:3068: WARNING: ignoring hardcoded g++" >&5
     3185+               { echo "$as_me:3069: WARNING: ignoring hardcoded g++" >&5
    29843186 echo "$as_me: WARNING: ignoring hardcoded g++" >&2;}
    29853187                cf_with_cxx=no; CXX=""; GXX="";
    29863188        fi
    2987 @@ -3069,11 +3073,11 @@
     3189@@ -3069,11 +3074,11 @@
    29883190 
    29893191 GXX_VERSION=none
    29903192 if test "$GXX" = yes; then
    29913193-       echo "$as_me:3072: checking version of g++" >&5
    2992 +       echo "$as_me:3076: checking version of g++" >&5
     3194+       echo "$as_me:3077: checking version of g++" >&5
    29933195 echo $ECHO_N "checking version of g++... $ECHO_C" >&6
    29943196        GXX_VERSION="`${CXX-g++} --version| sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
    29953197        test -z "$GXX_VERSION" && GXX_VERSION=unknown
    29963198-       echo "$as_me:3076: result: $GXX_VERSION" >&5
    2997 +       echo "$as_me:3080: result: $GXX_VERSION" >&5
     3199+       echo "$as_me:3081: result: $GXX_VERSION" >&5
    29983200 echo "${ECHO_T}$GXX_VERSION" >&6
    29993201 fi
    30003202 
    3001 @@ -3081,12 +3085,12 @@
     3203@@ -3081,12 +3086,12 @@
    30023204 1*|2.[0-6]*)
    30033205        # GXX=""; CXX=""; ac_cv_prog_gxx=no
    30043206        # cf_cxx_library=no
    30053207-       { echo "$as_me:3084: WARNING: templates do not work" >&5
    3006 +       { echo "$as_me:3088: WARNING: templates do not work" >&5
     3208+       { echo "$as_me:3089: WARNING: templates do not work" >&5
    30073209 echo "$as_me: WARNING: templates do not work" >&2;}
    30083210        ;;
     
    30103212 
    30113213-echo "$as_me:3089: checking if you want to build C++ binding and demo" >&5
    3012 +echo "$as_me:3093: checking if you want to build C++ binding and demo" >&5
     3214+echo "$as_me:3094: checking if you want to build C++ binding and demo" >&5
    30133215 echo $ECHO_N "checking if you want to build C++ binding and demo... $ECHO_C" >&6
    30143216 
    30153217 # Check whether --with-cxx-binding or --without-cxx-binding was given.
    3016 @@ -3096,10 +3100,10 @@
     3218@@ -3096,10 +3101,10 @@
    30173219 else
    30183220   cf_with_cxx_binding=$cf_with_cxx
    30193221 fi;
    30203222-echo "$as_me:3099: result: $cf_with_cxx_binding" >&5
    3021 +echo "$as_me:3103: result: $cf_with_cxx_binding" >&5
     3223+echo "$as_me:3104: result: $cf_with_cxx_binding" >&5
    30223224 echo "${ECHO_T}$cf_with_cxx_binding" >&6
    30233225 
    30243226-echo "$as_me:3102: checking if you want to build with Ada95" >&5
    3025 +echo "$as_me:3106: checking if you want to build with Ada95" >&5
     3227+echo "$as_me:3107: checking if you want to build with Ada95" >&5
    30263228 echo $ECHO_N "checking if you want to build with Ada95... $ECHO_C" >&6
    30273229 
    30283230 # Check whether --with-ada or --without-ada was given.
    3029 @@ -3109,10 +3113,23 @@
     3231@@ -3109,10 +3114,23 @@
    30303232 else
    30313233   cf_with_ada=yes
    30323234 fi;
    30333235-echo "$as_me:3112: result: $cf_with_ada" >&5
    3034 +echo "$as_me:3116: result: $cf_with_ada" >&5
     3236+echo "$as_me:3117: result: $cf_with_ada" >&5
    30353237 echo "${ECHO_T}$cf_with_ada" >&6
    30363238 
    30373239-echo "$as_me:3115: checking if you want to build programs such as tic" >&5
    3038 +echo "$as_me:3119: checking if you want to install manpages" >&5
     3240+echo "$as_me:3120: checking if you want to install manpages" >&5
    30393241+echo $ECHO_N "checking if you want to install manpages... $ECHO_C" >&6
    30403242+
     
    30463248+  cf_with_manpages=yes
    30473249+fi;
    3048 +echo "$as_me:3129: result: $cf_with_manpages" >&5
     3250+echo "$as_me:3130: result: $cf_with_manpages" >&5
    30493251+echo "${ECHO_T}$cf_with_manpages" >&6
    30503252+
    3051 +echo "$as_me:3132: checking if you want to build programs such as tic" >&5
     3253+echo "$as_me:3133: checking if you want to build programs such as tic" >&5
    30523254 echo $ECHO_N "checking if you want to build programs such as tic... $ECHO_C" >&6
    30533255 
    30543256 # Check whether --with-progs or --without-progs was given.
    3055 @@ -3122,10 +3139,10 @@
     3257@@ -3122,10 +3140,10 @@
    30563258 else
    30573259   cf_with_progs=yes
    30583260 fi;
    30593261-echo "$as_me:3125: result: $cf_with_progs" >&5
    3060 +echo "$as_me:3142: result: $cf_with_progs" >&5
     3262+echo "$as_me:3143: result: $cf_with_progs" >&5
    30613263 echo "${ECHO_T}$cf_with_progs" >&6
    30623264 
    30633265-echo "$as_me:3128: checking if you wish to install curses.h" >&5
    3064 +echo "$as_me:3145: checking if you wish to install curses.h" >&5
     3266+echo "$as_me:3146: checking if you wish to install curses.h" >&5
    30653267 echo $ECHO_N "checking if you wish to install curses.h... $ECHO_C" >&6
    30663268 
    30673269 # Check whether --with-curses-h or --without-curses-h was given.
    3068 @@ -3135,7 +3152,7 @@
     3270@@ -3135,7 +3153,7 @@
    30693271 else
    30703272   with_curses_h=yes
    30713273 fi;
    30723274-echo "$as_me:3138: result: $with_curses_h" >&5
    3073 +echo "$as_me:3155: result: $with_curses_h" >&5
     3275+echo "$as_me:3156: result: $with_curses_h" >&5
    30743276 echo "${ECHO_T}$with_curses_h" >&6
    30753277 
    30763278 modules_to_build="ncurses"
    3077 @@ -3161,7 +3178,7 @@
     3279@@ -3161,7 +3179,7 @@
    30783280 do
    30793281   # Extract the first word of "$ac_prog", so it can be a program name with args.
    30803282 set dummy $ac_prog; ac_word=$2
    30813283-echo "$as_me:3164: checking for $ac_word" >&5
    3082 +echo "$as_me:3181: checking for $ac_word" >&5
     3284+echo "$as_me:3182: checking for $ac_word" >&5
    30833285 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    30843286 if test "${ac_cv_prog_AWK+set}" = set; then
    30853287   echo $ECHO_N "(cached) $ECHO_C" >&6
    3086 @@ -3176,7 +3193,7 @@
     3288@@ -3176,7 +3194,7 @@
    30873289   test -z "$ac_dir" && ac_dir=.
    30883290   $as_executable_p "$ac_dir/$ac_word" || continue
    30893291 ac_cv_prog_AWK="$ac_prog"
    30903292-echo "$as_me:3179: found $ac_dir/$ac_word" >&5
    3091 +echo "$as_me:3196: found $ac_dir/$ac_word" >&5
     3293+echo "$as_me:3197: found $ac_dir/$ac_word" >&5
    30923294 break
    30933295 done
    30943296 
    3095 @@ -3184,21 +3201,21 @@
     3297@@ -3184,21 +3202,21 @@
    30963298 fi
    30973299 AWK=$ac_cv_prog_AWK
    30983300 if test -n "$AWK"; then
    30993301-  echo "$as_me:3187: result: $AWK" >&5
    3100 +  echo "$as_me:3204: result: $AWK" >&5
     3302+  echo "$as_me:3205: result: $AWK" >&5
    31013303 echo "${ECHO_T}$AWK" >&6
    31023304 else
    31033305-  echo "$as_me:3190: result: no" >&5
    3104 +  echo "$as_me:3207: result: no" >&5
     3306+  echo "$as_me:3208: result: no" >&5
    31053307 echo "${ECHO_T}no" >&6
    31063308 fi
     
    31103312 
    31113313-test -z "$AWK" && { { echo "$as_me:3197: error: No awk program found" >&5
    3112 +test -z "$AWK" && { { echo "$as_me:3214: error: No awk program found" >&5
     3314+test -z "$AWK" && { { echo "$as_me:3215: error: No awk program found" >&5
    31133315 echo "$as_me: error: No awk program found" >&2;}
    31143316    { (exit 1); exit 1; }; }
    31153317 
    31163318-echo "$as_me:3201: checking for egrep" >&5
    3117 +echo "$as_me:3218: checking for egrep" >&5
     3319+echo "$as_me:3219: checking for egrep" >&5
    31183320 echo $ECHO_N "checking for egrep... $ECHO_C" >&6
    31193321 if test "${ac_cv_prog_egrep+set}" = set; then
    31203322   echo $ECHO_N "(cached) $ECHO_C" >&6
    3121 @@ -3208,11 +3225,11 @@
     3323@@ -3208,11 +3226,11 @@
    31223324     else ac_cv_prog_egrep='egrep'
    31233325     fi
    31243326 fi
    31253327-echo "$as_me:3211: result: $ac_cv_prog_egrep" >&5
    3126 +echo "$as_me:3228: result: $ac_cv_prog_egrep" >&5
     3328+echo "$as_me:3229: result: $ac_cv_prog_egrep" >&5
    31273329 echo "${ECHO_T}$ac_cv_prog_egrep" >&6
    31283330  EGREP=$ac_cv_prog_egrep
    31293331 
    31303332-test -z "$EGREP" && { { echo "$as_me:3215: error: No egrep program found" >&5
    3131 +test -z "$EGREP" && { { echo "$as_me:3232: error: No egrep program found" >&5
     3333+test -z "$EGREP" && { { echo "$as_me:3233: error: No egrep program found" >&5
    31323334 echo "$as_me: error: No egrep program found" >&2;}
    31333335    { (exit 1); exit 1; }; }
    31343336 
    3135 @@ -3228,7 +3245,7 @@
     3337@@ -3228,7 +3246,7 @@
    31363338 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
    31373339 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
    31383340 # ./install, which can be erroneously created by make from ./install.sh.
    31393341-echo "$as_me:3231: checking for a BSD compatible install" >&5
    3140 +echo "$as_me:3248: checking for a BSD compatible install" >&5
     3342+echo "$as_me:3249: checking for a BSD compatible install" >&5
    31413343 echo $ECHO_N "checking for a BSD compatible install... $ECHO_C" >&6
    31423344 if test -z "$INSTALL"; then
    31433345 if test "${ac_cv_path_install+set}" = set; then
    3144 @@ -3277,7 +3294,7 @@
     3346@@ -3277,7 +3295,7 @@
    31453347     INSTALL=$ac_install_sh
    31463348   fi
    31473349 fi
    31483350-echo "$as_me:3280: result: $INSTALL" >&5
    3149 +echo "$as_me:3297: result: $INSTALL" >&5
     3351+echo "$as_me:3298: result: $INSTALL" >&5
    31503352 echo "${ECHO_T}$INSTALL" >&6
    31513353 
    31523354 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
    3153 @@ -3302,7 +3319,7 @@
     3355@@ -3302,7 +3320,7 @@
    31543356 do
    31553357   # Extract the first word of "$ac_prog", so it can be a program name with args.
    31563358 set dummy $ac_prog; ac_word=$2
    31573359-echo "$as_me:3305: checking for $ac_word" >&5
    3158 +echo "$as_me:3322: checking for $ac_word" >&5
     3360+echo "$as_me:3323: checking for $ac_word" >&5
    31593361 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    31603362 if test "${ac_cv_prog_LINT+set}" = set; then
    31613363   echo $ECHO_N "(cached) $ECHO_C" >&6
    3162 @@ -3317,7 +3334,7 @@
     3364@@ -3317,7 +3335,7 @@
    31633365   test -z "$ac_dir" && ac_dir=.
    31643366   $as_executable_p "$ac_dir/$ac_word" || continue
    31653367 ac_cv_prog_LINT="$ac_prog"
    31663368-echo "$as_me:3320: found $ac_dir/$ac_word" >&5
    3167 +echo "$as_me:3337: found $ac_dir/$ac_word" >&5
     3369+echo "$as_me:3338: found $ac_dir/$ac_word" >&5
    31683370 break
    31693371 done
    31703372 
    3171 @@ -3325,28 +3342,28 @@
     3373@@ -3325,28 +3343,28 @@
    31723374 fi
    31733375 LINT=$ac_cv_prog_LINT
    31743376 if test -n "$LINT"; then
    31753377-  echo "$as_me:3328: result: $LINT" >&5
    3176 +  echo "$as_me:3345: result: $LINT" >&5
     3378+  echo "$as_me:3346: result: $LINT" >&5
    31773379 echo "${ECHO_T}$LINT" >&6
    31783380 else
    31793381-  echo "$as_me:3331: result: no" >&5
    3180 +  echo "$as_me:3348: result: no" >&5
     3382+  echo "$as_me:3349: result: no" >&5
    31813383 echo "${ECHO_T}no" >&6
    31823384 fi
     
    31863388 
    31873389-echo "$as_me:3338: checking whether ln -s works" >&5
    3188 +echo "$as_me:3355: checking whether ln -s works" >&5
     3390+echo "$as_me:3356: checking whether ln -s works" >&5
    31893391 echo $ECHO_N "checking whether ln -s works... $ECHO_C" >&6
    31903392 LN_S=$as_ln_s
    31913393 if test "$LN_S" = "ln -s"; then
    31923394-  echo "$as_me:3342: result: yes" >&5
    3193 +  echo "$as_me:3359: result: yes" >&5
     3395+  echo "$as_me:3360: result: yes" >&5
    31943396 echo "${ECHO_T}yes" >&6
    31953397 else
    31963398-  echo "$as_me:3345: result: no, using $LN_S" >&5
    3197 +  echo "$as_me:3362: result: no, using $LN_S" >&5
     3399+  echo "$as_me:3363: result: no, using $LN_S" >&5
    31983400 echo "${ECHO_T}no, using $LN_S" >&6
    31993401 fi
    32003402 
    32013403-echo "$as_me:3349: checking for long file names" >&5
    3202 +echo "$as_me:3366: checking for long file names" >&5
     3404+echo "$as_me:3367: checking for long file names" >&5
    32033405 echo $ECHO_N "checking for long file names... $ECHO_C" >&6
    32043406 if test "${ac_cv_sys_long_file_names+set}" = set; then
    32053407   echo $ECHO_N "(cached) $ECHO_C" >&6
    3206 @@ -3385,7 +3402,7 @@
     3408@@ -3385,7 +3403,7 @@
    32073409   rm -rf $ac_xdir 2>/dev/null
    32083410 done
    32093411 fi
    32103412-echo "$as_me:3388: result: $ac_cv_sys_long_file_names" >&5
    3211 +echo "$as_me:3405: result: $ac_cv_sys_long_file_names" >&5
     3413+echo "$as_me:3406: result: $ac_cv_sys_long_file_names" >&5
    32123414 echo "${ECHO_T}$ac_cv_sys_long_file_names" >&6
    32133415 if test $ac_cv_sys_long_file_names = yes; then
    32143416 
    3215 @@ -3395,7 +3412,136 @@
     3417@@ -3395,7 +3413,136 @@
    32163418 
    32173419 fi
     
    32203422+# if we find pkg-config, check if we should install the ".pc" files.
    32213423+
    3222 +echo "$as_me:3417: checking if you want to use pkg-config" >&5
     3424+echo "$as_me:3418: checking if you want to use pkg-config" >&5
    32233425+echo $ECHO_N "checking if you want to use pkg-config... $ECHO_C" >&6
    32243426+
     
    32303432+  cf_pkg_config=yes
    32313433+fi;
    3232 +echo "$as_me:3427: result: $cf_pkg_config" >&5
     3434+echo "$as_me:3428: result: $cf_pkg_config" >&5
    32333435+echo "${ECHO_T}$cf_pkg_config" >&6
    32343436+
     
    32403442+       # Extract the first word of "pkg-config", so it can be a program name with args.
    32413443+set dummy pkg-config; ac_word=$2
    3242 +echo "$as_me:3437: checking for $ac_word" >&5
     3444+echo "$as_me:3438: checking for $ac_word" >&5
    32433445+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    32443446+if test "${ac_cv_path_PKG_CONFIG+set}" = set; then
     
    32573459+  if $as_executable_p "$ac_dir/$ac_word"; then
    32583460+   ac_cv_path_PKG_CONFIG="$ac_dir/$ac_word"
    3259 +   echo "$as_me:3454: found $ac_dir/$ac_word" >&5
     3461+   echo "$as_me:3455: found $ac_dir/$ac_word" >&5
    32603462+   break
    32613463+fi
     
    32693471+
    32703472+if test -n "$PKG_CONFIG"; then
    3271 +  echo "$as_me:3466: result: $PKG_CONFIG" >&5
     3473+  echo "$as_me:3467: result: $PKG_CONFIG" >&5
    32723474+echo "${ECHO_T}$PKG_CONFIG" >&6
    32733475+else
    3274 +  echo "$as_me:3469: result: no" >&5
     3476+  echo "$as_me:3470: result: no" >&5
    32753477+echo "${ECHO_T}no" >&6
    32763478+fi
     
    33103512+  ;;
    33113513+*)
    3312 +  { { echo "$as_me:3507: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
     3514+  { { echo "$as_me:3508: error: expected a pathname, not \"$PKG_CONFIG\"" >&5
    33133515+echo "$as_me: error: expected a pathname, not \"$PKG_CONFIG\"" >&2;}
    33143516+   { (exit 1); exit 1; }; }
     
    33193521+
    33203522+if test "$PKG_CONFIG" != no ; then
    3321 +       echo "$as_me:3516: checking if we should install .pc files for $PKG_CONFIG" >&5
     3523+       echo "$as_me:3517: checking if we should install .pc files for $PKG_CONFIG" >&5
    33223524+echo $ECHO_N "checking if we should install .pc files for $PKG_CONFIG... $ECHO_C" >&6
    33233525+
     
    33363538+  enable_pc_files=no
    33373539+fi;
    3338 +               echo "$as_me:3533: result: $enable_pc_files" >&5
     3540+               echo "$as_me:3534: result: $enable_pc_files" >&5
    33393541+echo "${ECHO_T}$enable_pc_files" >&6
    33403542+       else
    3341 +               echo "$as_me:3536: result: no" >&5
     3543+               echo "$as_me:3537: result: no" >&5
    33423544+echo "${ECHO_T}no" >&6
    3343 +               { echo "$as_me:3538: WARNING: did not find library $PKG_CONFIG_LIBDIR" >&5
     3545+               { echo "$as_me:3539: WARNING: did not find library $PKG_CONFIG_LIBDIR" >&5
    33443546+echo "$as_me: WARNING: did not find library $PKG_CONFIG_LIBDIR" >&2;}
    33453547+               enable_pc_files=no
     
    33473549+fi
    33483550+
    3349 +echo "$as_me:3544: checking if we should assume mixed-case filenames" >&5
     3551+echo "$as_me:3545: checking if we should assume mixed-case filenames" >&5
    33503552 echo $ECHO_N "checking if we should assume mixed-case filenames... $ECHO_C" >&6
    33513553 
    33523554 # Check whether --enable-mixed-case or --disable-mixed-case was given.
    3353 @@ -3405,11 +3551,11 @@
     3555@@ -3405,11 +3552,11 @@
    33543556 else
    33553557   enable_mixedcase=auto
    33563558 fi;
    33573559-echo "$as_me:3408: result: $enable_mixedcase" >&5
    3358 +echo "$as_me:3554: result: $enable_mixedcase" >&5
     3560+echo "$as_me:3555: result: $enable_mixedcase" >&5
    33593561 echo "${ECHO_T}$enable_mixedcase" >&6
    33603562 if test "$enable_mixedcase" = "auto" ; then
    33613563 
    33623564-echo "$as_me:3412: checking if filesystem supports mixed-case filenames" >&5
    3363 +echo "$as_me:3558: checking if filesystem supports mixed-case filenames" >&5
     3565+echo "$as_me:3559: checking if filesystem supports mixed-case filenames" >&5
    33643566 echo $ECHO_N "checking if filesystem supports mixed-case filenames... $ECHO_C" >&6
    33653567 if test "${cf_cv_mixedcase+set}" = set; then
    33663568   echo $ECHO_N "(cached) $ECHO_C" >&6
    3367 @@ -3436,7 +3582,7 @@
     3569@@ -3436,7 +3583,7 @@
    33683570 fi
    33693571 
    33703572 fi
    33713573-echo "$as_me:3439: result: $cf_cv_mixedcase" >&5
    3372 +echo "$as_me:3585: result: $cf_cv_mixedcase" >&5
     3574+echo "$as_me:3586: result: $cf_cv_mixedcase" >&5
    33733575 echo "${ECHO_T}$cf_cv_mixedcase" >&6
    33743576 test "$cf_cv_mixedcase" = yes && cat >>confdefs.h <<\EOF
    33753577 #define MIXEDCASE_FILENAMES 1
    3376 @@ -3453,7 +3599,7 @@
     3578@@ -3453,7 +3600,7 @@
    33773579 fi
    33783580 
    33793581 # do this after mixed-case option (tags/TAGS is not as important as tic).
    33803582-echo "$as_me:3456: checking whether ${MAKE-make} sets \${MAKE}" >&5
    3381 +echo "$as_me:3602: checking whether ${MAKE-make} sets \${MAKE}" >&5
     3583+echo "$as_me:3603: checking whether ${MAKE-make} sets \${MAKE}" >&5
    33823584 echo $ECHO_N "checking whether ${MAKE-make} sets \${MAKE}... $ECHO_C" >&6
    33833585 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y,./+-,__p_,'`
    33843586 if eval "test \"\${ac_cv_prog_make_${ac_make}_set+set}\" = set"; then
    3385 @@ -3473,18 +3619,18 @@
     3587@@ -3473,18 +3620,18 @@
    33863588 rm -f conftest.make
    33873589 fi
    33883590 if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
    33893591-  echo "$as_me:3476: result: yes" >&5
    3390 +  echo "$as_me:3622: result: yes" >&5
     3592+  echo "$as_me:3623: result: yes" >&5
    33913593 echo "${ECHO_T}yes" >&6
    33923594   SET_MAKE=
    33933595 else
    33943596-  echo "$as_me:3480: result: no" >&5
    3395 +  echo "$as_me:3626: result: no" >&5
     3597+  echo "$as_me:3627: result: no" >&5
    33963598 echo "${ECHO_T}no" >&6
    33973599   SET_MAKE="MAKE=${MAKE-make}"
     
    34013603 set dummy ctags; ac_word=$2
    34023604-echo "$as_me:3487: checking for $ac_word" >&5
    3403 +echo "$as_me:3633: checking for $ac_word" >&5
     3605+echo "$as_me:3634: checking for $ac_word" >&5
    34043606 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    34053607 if test "${ac_cv_prog_MAKE_LOWER_TAGS+set}" = set; then
    34063608   echo $ECHO_N "(cached) $ECHO_C" >&6
    3407 @@ -3499,7 +3645,7 @@
     3609@@ -3499,7 +3646,7 @@
    34083610   test -z "$ac_dir" && ac_dir=.
    34093611   $as_executable_p "$ac_dir/$ac_word" || continue
    34103612 ac_cv_prog_MAKE_LOWER_TAGS="yes"
    34113613-echo "$as_me:3502: found $ac_dir/$ac_word" >&5
    3412 +echo "$as_me:3648: found $ac_dir/$ac_word" >&5
     3614+echo "$as_me:3649: found $ac_dir/$ac_word" >&5
    34133615 break
    34143616 done
    34153617 
    3416 @@ -3508,17 +3654,17 @@
     3618@@ -3508,17 +3655,17 @@
    34173619 fi
    34183620 MAKE_LOWER_TAGS=$ac_cv_prog_MAKE_LOWER_TAGS
    34193621 if test -n "$MAKE_LOWER_TAGS"; then
    34203622-  echo "$as_me:3511: result: $MAKE_LOWER_TAGS" >&5
    3421 +  echo "$as_me:3657: result: $MAKE_LOWER_TAGS" >&5
     3623+  echo "$as_me:3658: result: $MAKE_LOWER_TAGS" >&5
    34223624 echo "${ECHO_T}$MAKE_LOWER_TAGS" >&6
    34233625 else
    34243626-  echo "$as_me:3514: result: no" >&5
    3425 +  echo "$as_me:3660: result: no" >&5
     3627+  echo "$as_me:3661: result: no" >&5
    34263628 echo "${ECHO_T}no" >&6
    34273629 fi
     
    34313633 set dummy etags; ac_word=$2
    34323634-echo "$as_me:3521: checking for $ac_word" >&5
    3433 +echo "$as_me:3667: checking for $ac_word" >&5
     3635+echo "$as_me:3668: checking for $ac_word" >&5
    34343636 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    34353637 if test "${ac_cv_prog_MAKE_UPPER_TAGS+set}" = set; then
    34363638   echo $ECHO_N "(cached) $ECHO_C" >&6
    3437 @@ -3533,7 +3679,7 @@
     3639@@ -3533,7 +3680,7 @@
    34383640   test -z "$ac_dir" && ac_dir=.
    34393641   $as_executable_p "$ac_dir/$ac_word" || continue
    34403642 ac_cv_prog_MAKE_UPPER_TAGS="yes"
    34413643-echo "$as_me:3536: found $ac_dir/$ac_word" >&5
    3442 +echo "$as_me:3682: found $ac_dir/$ac_word" >&5
     3644+echo "$as_me:3683: found $ac_dir/$ac_word" >&5
    34433645 break
    34443646 done
    34453647 
    3446 @@ -3542,10 +3688,10 @@
     3648@@ -3542,10 +3689,10 @@
    34473649 fi
    34483650 MAKE_UPPER_TAGS=$ac_cv_prog_MAKE_UPPER_TAGS
    34493651 if test -n "$MAKE_UPPER_TAGS"; then
    34503652-  echo "$as_me:3545: result: $MAKE_UPPER_TAGS" >&5
    3451 +  echo "$as_me:3691: result: $MAKE_UPPER_TAGS" >&5
     3653+  echo "$as_me:3692: result: $MAKE_UPPER_TAGS" >&5
    34523654 echo "${ECHO_T}$MAKE_UPPER_TAGS" >&6
    34533655 else
    34543656-  echo "$as_me:3548: result: no" >&5
    3455 +  echo "$as_me:3694: result: no" >&5
     3657+  echo "$as_me:3695: result: no" >&5
    34563658 echo "${ECHO_T}no" >&6
    34573659 fi
    34583660 
    3459 @@ -3565,7 +3711,7 @@
     3661@@ -3565,7 +3712,7 @@
    34603662        MAKE_LOWER_TAGS="#"
    34613663 fi
    34623664 
    34633665-echo "$as_me:3568: checking for makeflags variable" >&5
    3464 +echo "$as_me:3714: checking for makeflags variable" >&5
     3666+echo "$as_me:3715: checking for makeflags variable" >&5
    34653667 echo $ECHO_N "checking for makeflags variable... $ECHO_C" >&6
    34663668 if test "${cf_cv_makeflags+set}" = set; then
    34673669   echo $ECHO_N "(cached) $ECHO_C" >&6
    3468 @@ -3599,13 +3745,13 @@
     3670@@ -3599,13 +3746,13 @@
    34693671        rm -f cf_makeflags.tmp
    34703672 
    34713673 fi
    34723674-echo "$as_me:3602: result: $cf_cv_makeflags" >&5
    3473 +echo "$as_me:3748: result: $cf_cv_makeflags" >&5
     3675+echo "$as_me:3749: result: $cf_cv_makeflags" >&5
    34743676 echo "${ECHO_T}$cf_cv_makeflags" >&6
    34753677 
     
    34783680 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
    34793681-echo "$as_me:3608: checking for $ac_word" >&5
    3480 +echo "$as_me:3754: checking for $ac_word" >&5
     3682+echo "$as_me:3755: checking for $ac_word" >&5
    34813683 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    34823684 if test "${ac_cv_prog_RANLIB+set}" = set; then
    34833685   echo $ECHO_N "(cached) $ECHO_C" >&6
    3484 @@ -3620,7 +3766,7 @@
     3686@@ -3620,7 +3767,7 @@
    34853687   test -z "$ac_dir" && ac_dir=.
    34863688   $as_executable_p "$ac_dir/$ac_word" || continue
    34873689 ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
    34883690-echo "$as_me:3623: found $ac_dir/$ac_word" >&5
    3489 +echo "$as_me:3769: found $ac_dir/$ac_word" >&5
     3691+echo "$as_me:3770: found $ac_dir/$ac_word" >&5
    34903692 break
    34913693 done
    34923694 
    3493 @@ -3628,10 +3774,10 @@
     3695@@ -3628,10 +3775,10 @@
    34943696 fi
    34953697 RANLIB=$ac_cv_prog_RANLIB
    34963698 if test -n "$RANLIB"; then
    34973699-  echo "$as_me:3631: result: $RANLIB" >&5
    3498 +  echo "$as_me:3777: result: $RANLIB" >&5
     3700+  echo "$as_me:3778: result: $RANLIB" >&5
    34993701 echo "${ECHO_T}$RANLIB" >&6
    35003702 else
    35013703-  echo "$as_me:3634: result: no" >&5
    3502 +  echo "$as_me:3780: result: no" >&5
     3704+  echo "$as_me:3781: result: no" >&5
    35033705 echo "${ECHO_T}no" >&6
    35043706 fi
    35053707 
    3506 @@ -3640,7 +3786,7 @@
     3708@@ -3640,7 +3787,7 @@
    35073709   ac_ct_RANLIB=$RANLIB
    35083710   # Extract the first word of "ranlib", so it can be a program name with args.
    35093711 set dummy ranlib; ac_word=$2
    35103712-echo "$as_me:3643: checking for $ac_word" >&5
    3511 +echo "$as_me:3789: checking for $ac_word" >&5
     3713+echo "$as_me:3790: checking for $ac_word" >&5
    35123714 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    35133715 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
    35143716   echo $ECHO_N "(cached) $ECHO_C" >&6
    3515 @@ -3655,7 +3801,7 @@
     3717@@ -3655,7 +3802,7 @@
    35163718   test -z "$ac_dir" && ac_dir=.
    35173719   $as_executable_p "$ac_dir/$ac_word" || continue
    35183720 ac_cv_prog_ac_ct_RANLIB="ranlib"
    35193721-echo "$as_me:3658: found $ac_dir/$ac_word" >&5
    3520 +echo "$as_me:3804: found $ac_dir/$ac_word" >&5
     3722+echo "$as_me:3805: found $ac_dir/$ac_word" >&5
    35213723 break
    35223724 done
    35233725 
    3524 @@ -3664,10 +3810,10 @@
     3726@@ -3664,10 +3811,10 @@
    35253727 fi
    35263728 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
    35273729 if test -n "$ac_ct_RANLIB"; then
    35283730-  echo "$as_me:3667: result: $ac_ct_RANLIB" >&5
    3529 +  echo "$as_me:3813: result: $ac_ct_RANLIB" >&5
     3731+  echo "$as_me:3814: result: $ac_ct_RANLIB" >&5
    35303732 echo "${ECHO_T}$ac_ct_RANLIB" >&6
    35313733 else
    35323734-  echo "$as_me:3670: result: no" >&5
    3533 +  echo "$as_me:3816: result: no" >&5
     3735+  echo "$as_me:3817: result: no" >&5
    35343736 echo "${ECHO_T}no" >&6
    35353737 fi
    35363738 
    3537 @@ -3679,7 +3825,7 @@
     3739@@ -3679,7 +3826,7 @@
    35383740 if test -n "$ac_tool_prefix"; then
    35393741   # Extract the first word of "${ac_tool_prefix}ld", so it can be a program name with args.
    35403742 set dummy ${ac_tool_prefix}ld; ac_word=$2
    35413743-echo "$as_me:3682: checking for $ac_word" >&5
    3542 +echo "$as_me:3828: checking for $ac_word" >&5
     3744+echo "$as_me:3829: checking for $ac_word" >&5
    35433745 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    35443746 if test "${ac_cv_prog_LD+set}" = set; then
    35453747   echo $ECHO_N "(cached) $ECHO_C" >&6
    3546 @@ -3694,7 +3840,7 @@
     3748@@ -3694,7 +3841,7 @@
    35473749   test -z "$ac_dir" && ac_dir=.
    35483750   $as_executable_p "$ac_dir/$ac_word" || continue
    35493751 ac_cv_prog_LD="${ac_tool_prefix}ld"
    35503752-echo "$as_me:3697: found $ac_dir/$ac_word" >&5
    3551 +echo "$as_me:3843: found $ac_dir/$ac_word" >&5
     3753+echo "$as_me:3844: found $ac_dir/$ac_word" >&5
    35523754 break
    35533755 done
    35543756 
    3555 @@ -3702,10 +3848,10 @@
     3757@@ -3702,10 +3849,10 @@
    35563758 fi
    35573759 LD=$ac_cv_prog_LD
    35583760 if test -n "$LD"; then
    35593761-  echo "$as_me:3705: result: $LD" >&5
    3560 +  echo "$as_me:3851: result: $LD" >&5
     3762+  echo "$as_me:3852: result: $LD" >&5
    35613763 echo "${ECHO_T}$LD" >&6
    35623764 else
    35633765-  echo "$as_me:3708: result: no" >&5
    3564 +  echo "$as_me:3854: result: no" >&5
     3766+  echo "$as_me:3855: result: no" >&5
    35653767 echo "${ECHO_T}no" >&6
    35663768 fi
    35673769 
    3568 @@ -3714,7 +3860,7 @@
     3770@@ -3714,7 +3861,7 @@
    35693771   ac_ct_LD=$LD
    35703772   # Extract the first word of "ld", so it can be a program name with args.
    35713773 set dummy ld; ac_word=$2
    35723774-echo "$as_me:3717: checking for $ac_word" >&5
    3573 +echo "$as_me:3863: checking for $ac_word" >&5
     3775+echo "$as_me:3864: checking for $ac_word" >&5
    35743776 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    35753777 if test "${ac_cv_prog_ac_ct_LD+set}" = set; then
    35763778   echo $ECHO_N "(cached) $ECHO_C" >&6
    3577 @@ -3729,7 +3875,7 @@
     3779@@ -3729,7 +3876,7 @@
    35783780   test -z "$ac_dir" && ac_dir=.
    35793781   $as_executable_p "$ac_dir/$ac_word" || continue
    35803782 ac_cv_prog_ac_ct_LD="ld"
    35813783-echo "$as_me:3732: found $ac_dir/$ac_word" >&5
    3582 +echo "$as_me:3878: found $ac_dir/$ac_word" >&5
     3784+echo "$as_me:3879: found $ac_dir/$ac_word" >&5
    35833785 break
    35843786 done
    35853787 
    3586 @@ -3738,10 +3884,10 @@
     3788@@ -3738,10 +3885,10 @@
    35873789 fi
    35883790 ac_ct_LD=$ac_cv_prog_ac_ct_LD
    35893791 if test -n "$ac_ct_LD"; then
    35903792-  echo "$as_me:3741: result: $ac_ct_LD" >&5
    3591 +  echo "$as_me:3887: result: $ac_ct_LD" >&5
     3793+  echo "$as_me:3888: result: $ac_ct_LD" >&5
    35923794 echo "${ECHO_T}$ac_ct_LD" >&6
    35933795 else
    35943796-  echo "$as_me:3744: result: no" >&5
    3595 +  echo "$as_me:3890: result: no" >&5
     3797+  echo "$as_me:3891: result: no" >&5
    35963798 echo "${ECHO_T}no" >&6
    35973799 fi
    35983800 
    3599 @@ -3753,7 +3899,7 @@
     3801@@ -3753,7 +3900,7 @@
    36003802 if test -n "$ac_tool_prefix"; then
    36013803   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
    36023804 set dummy ${ac_tool_prefix}ar; ac_word=$2
    36033805-echo "$as_me:3756: checking for $ac_word" >&5
    3604 +echo "$as_me:3902: checking for $ac_word" >&5
     3806+echo "$as_me:3903: checking for $ac_word" >&5
    36053807 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    36063808 if test "${ac_cv_prog_AR+set}" = set; then
    36073809   echo $ECHO_N "(cached) $ECHO_C" >&6
    3608 @@ -3768,7 +3914,7 @@
     3810@@ -3768,7 +3915,7 @@
    36093811   test -z "$ac_dir" && ac_dir=.
    36103812   $as_executable_p "$ac_dir/$ac_word" || continue
    36113813 ac_cv_prog_AR="${ac_tool_prefix}ar"
    36123814-echo "$as_me:3771: found $ac_dir/$ac_word" >&5
    3613 +echo "$as_me:3917: found $ac_dir/$ac_word" >&5
     3815+echo "$as_me:3918: found $ac_dir/$ac_word" >&5
    36143816 break
    36153817 done
    36163818 
    3617 @@ -3776,10 +3922,10 @@
     3819@@ -3776,10 +3923,10 @@
    36183820 fi
    36193821 AR=$ac_cv_prog_AR
    36203822 if test -n "$AR"; then
    36213823-  echo "$as_me:3779: result: $AR" >&5
    3622 +  echo "$as_me:3925: result: $AR" >&5
     3824+  echo "$as_me:3926: result: $AR" >&5
    36233825 echo "${ECHO_T}$AR" >&6
    36243826 else
    36253827-  echo "$as_me:3782: result: no" >&5
    3626 +  echo "$as_me:3928: result: no" >&5
     3828+  echo "$as_me:3929: result: no" >&5
    36273829 echo "${ECHO_T}no" >&6
    36283830 fi
    36293831 
    3630 @@ -3788,7 +3934,7 @@
     3832@@ -3788,7 +3935,7 @@
    36313833   ac_ct_AR=$AR
    36323834   # Extract the first word of "ar", so it can be a program name with args.
    36333835 set dummy ar; ac_word=$2
    36343836-echo "$as_me:3791: checking for $ac_word" >&5
    3635 +echo "$as_me:3937: checking for $ac_word" >&5
     3837+echo "$as_me:3938: checking for $ac_word" >&5
    36363838 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    36373839 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
    36383840   echo $ECHO_N "(cached) $ECHO_C" >&6
    3639 @@ -3803,7 +3949,7 @@
     3841@@ -3803,7 +3950,7 @@
    36403842   test -z "$ac_dir" && ac_dir=.
    36413843   $as_executable_p "$ac_dir/$ac_word" || continue
    36423844 ac_cv_prog_ac_ct_AR="ar"
    36433845-echo "$as_me:3806: found $ac_dir/$ac_word" >&5
    3644 +echo "$as_me:3952: found $ac_dir/$ac_word" >&5
     3846+echo "$as_me:3953: found $ac_dir/$ac_word" >&5
    36453847 break
    36463848 done
    36473849 
    3648 @@ -3812,10 +3958,10 @@
     3850@@ -3812,10 +3959,10 @@
    36493851 fi
    36503852 ac_ct_AR=$ac_cv_prog_ac_ct_AR
    36513853 if test -n "$ac_ct_AR"; then
    36523854-  echo "$as_me:3815: result: $ac_ct_AR" >&5
    3653 +  echo "$as_me:3961: result: $ac_ct_AR" >&5
     3855+  echo "$as_me:3962: result: $ac_ct_AR" >&5
    36543856 echo "${ECHO_T}$ac_ct_AR" >&6
    36553857 else
    36563858-  echo "$as_me:3818: result: no" >&5
    3657 +  echo "$as_me:3964: result: no" >&5
     3859+  echo "$as_me:3965: result: no" >&5
    36583860 echo "${ECHO_T}no" >&6
    36593861 fi
    36603862 
    3661 @@ -3824,25 +3970,123 @@
     3863@@ -3824,25 +3971,123 @@
    36623864   AR="$ac_cv_prog_AR"
    36633865 fi
     
    36673869+  # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
    36683870+set dummy ${ac_tool_prefix}ar; ac_word=$2
    3669 +echo "$as_me:3976: checking for $ac_word" >&5
     3871+echo "$as_me:3977: checking for $ac_word" >&5
    36703872+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    36713873+if test "${ac_cv_prog_AR+set}" = set; then
     
    36823884+  $as_executable_p "$ac_dir/$ac_word" || continue
    36833885+ac_cv_prog_AR="${ac_tool_prefix}ar"
    3684 +echo "$as_me:3991: found $ac_dir/$ac_word" >&5
     3886+echo "$as_me:3992: found $ac_dir/$ac_word" >&5
    36853887+break
    36863888+done
     
    36923894+AR=$ac_cv_prog_AR
    36933895+if test -n "$AR"; then
    3694 +  echo "$as_me:3999: result: $AR" >&5
     3896+  echo "$as_me:4000: result: $AR" >&5
    36953897+echo "${ECHO_T}$AR" >&6
    36963898+else
    3697 +  echo "$as_me:4002: result: no" >&5
     3899+  echo "$as_me:4003: result: no" >&5
    36983900+echo "${ECHO_T}no" >&6
    36993901+fi
     
    37063908+  # Extract the first word of "ar", so it can be a program name with args.
    37073909+set dummy ar; ac_word=$2
    3708 +echo "$as_me:4011: checking for $ac_word" >&5
     3910+echo "$as_me:4012: checking for $ac_word" >&5
    37093911+echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    37103912+if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
     
    37213923+  $as_executable_p "$ac_dir/$ac_word" || continue
    37223924+ac_cv_prog_ac_ct_AR="ar"
    3723 +echo "$as_me:4026: found $ac_dir/$ac_word" >&5
     3925+echo "$as_me:4027: found $ac_dir/$ac_word" >&5
    37243926+break
    37253927+done
     
    37303932+ac_ct_AR=$ac_cv_prog_ac_ct_AR
    37313933+if test -n "$ac_ct_AR"; then
    3732 +  echo "$as_me:4035: result: $ac_ct_AR" >&5
     3934+  echo "$as_me:4036: result: $ac_ct_AR" >&5
    37333935+echo "${ECHO_T}$ac_ct_AR" >&6
    37343936+else
    3735 +  echo "$as_me:4038: result: no" >&5
     3937+  echo "$as_me:4039: result: no" >&5
    37363938+echo "${ECHO_T}no" >&6
    37373939+fi
     
    37423944+fi
    37433945+
    3744 +echo "$as_me:4047: checking for options to update archives" >&5
     3946+echo "$as_me:4048: checking for options to update archives" >&5
    37453947+echo $ECHO_N "checking for options to update archives... $ECHO_C" >&6
    37463948+if test "${cf_cv_ar_flags+set}" = set; then
    37473949+  echo $ECHO_N "(cached) $ECHO_C" >&6
    37483950+else
    3749  
    3750 -cf_cv_subst_AR_OPTS=$AR_OPTS
    3751 -echo "$as_me:3840: result: $AR_OPTS" >&5
    3752 -echo "${ECHO_T}$AR_OPTS" >&6
     3951+
    37533952+       cf_cv_ar_flags=unknown
    37543953+       for cf_ar_flags in -curv curv -crv crv -cqv cqv -rv rv
     
    37563955+               rm -f conftest.$ac_cv_objext
    37573956+               rm -f conftest.a
    3758 +
     3957 
     3958-cf_cv_subst_AR_OPTS=$AR_OPTS
     3959-echo "$as_me:3840: result: $AR_OPTS" >&5
     3960-echo "${ECHO_T}$AR_OPTS" >&6
    37593961+               cat >conftest.$ac_ext <<EOF
    3760 +#line 4060 "configure"
     3962+#line 4061 "configure"
    37613963+int    testdata[3] = { 123, 456, 789 };
    37623964+EOF
    3763 +               if { (eval echo "$as_me:4063: \"$ac_compile\"") >&5
     3965+               if { (eval echo "$as_me:4064: \"$ac_compile\"") >&5
    37643966+  (eval $ac_compile) 2>&5
    37653967+  ac_status=$?
    3766 +  echo "$as_me:4066: \$? = $ac_status" >&5
     3968+  echo "$as_me:4067: \$? = $ac_status" >&5
    37673969+  (exit $ac_status); } ; then
    37683970+                       $AR $cf_ar_flags conftest.a conftest.$ac_cv_objext 2>&5 1>/dev/null
     
    37743976+                       test -n "$verbose" && echo "    cannot compile test-program" 1>&6
    37753977+
    3776 +echo "${as_me-configure}:4076: testing cannot compile test-program ..." 1>&5
     3978+echo "${as_me-configure}:4077: testing cannot compile test-program ..." 1>&5
    37773979+
    37783980+                       break
     
    37823984 
    37833985 fi
    3784 +echo "$as_me:4084: result: $cf_cv_ar_flags" >&5
     3986+echo "$as_me:4085: result: $cf_cv_ar_flags" >&5
    37853987+echo "${ECHO_T}$cf_cv_ar_flags" >&6
    37863988+test -z "$ARFLAGS" && ARFLAGS=$cf_cv_ar_flags
     
    37883990 
    37893991-echo "$as_me:3845: checking if you have specified an install-prefix" >&5
    3790 +echo "$as_me:4089: checking if you have specified an install-prefix" >&5
     3992+echo "$as_me:4090: checking if you have specified an install-prefix" >&5
    37913993 echo $ECHO_N "checking if you have specified an install-prefix... $ECHO_C" >&6
    37923994 
    37933995 # Check whether --with-install-prefix or --without-install-prefix was given.
    3794 @@ -3855,7 +4099,7 @@
     3996@@ -3855,7 +4100,7 @@
    37953997                ;;
    37963998        esac
    37973999 fi;
    37984000-echo "$as_me:3858: result: $DESTDIR" >&5
    3799 +echo "$as_me:4102: result: $DESTDIR" >&5
     4001+echo "$as_me:4103: result: $DESTDIR" >&5
    38004002 echo "${ECHO_T}$DESTDIR" >&6
    38014003 
    38024004 ###############################################################################
    3803 @@ -3883,7 +4127,7 @@
     4005@@ -3883,7 +4128,7 @@
    38044006 do
    38054007   # Extract the first word of "$ac_prog", so it can be a program name with args.
    38064008 set dummy $ac_prog; ac_word=$2
    38074009-echo "$as_me:3886: checking for $ac_word" >&5
    3808 +echo "$as_me:4130: checking for $ac_word" >&5
     4010+echo "$as_me:4131: checking for $ac_word" >&5
    38094011 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    38104012 if test "${ac_cv_prog_BUILD_CC+set}" = set; then
    38114013   echo $ECHO_N "(cached) $ECHO_C" >&6
    3812 @@ -3898,7 +4142,7 @@
     4014@@ -3898,7 +4143,7 @@
    38134015   test -z "$ac_dir" && ac_dir=.
    38144016   $as_executable_p "$ac_dir/$ac_word" || continue
    38154017 ac_cv_prog_BUILD_CC="$ac_prog"
    38164018-echo "$as_me:3901: found $ac_dir/$ac_word" >&5
    3817 +echo "$as_me:4145: found $ac_dir/$ac_word" >&5
     4019+echo "$as_me:4146: found $ac_dir/$ac_word" >&5
    38184020 break
    38194021 done
    38204022 
    3821 @@ -3906,10 +4150,10 @@
     4023@@ -3906,10 +4151,10 @@
    38224024 fi
    38234025 BUILD_CC=$ac_cv_prog_BUILD_CC
    38244026 if test -n "$BUILD_CC"; then
    38254027-  echo "$as_me:3909: result: $BUILD_CC" >&5
    3826 +  echo "$as_me:4153: result: $BUILD_CC" >&5
     4028+  echo "$as_me:4154: result: $BUILD_CC" >&5
    38274029 echo "${ECHO_T}$BUILD_CC" >&6
    38284030 else
    38294031-  echo "$as_me:3912: result: no" >&5
    3830 +  echo "$as_me:4156: result: no" >&5
     4032+  echo "$as_me:4157: result: no" >&5
    38314033 echo "${ECHO_T}no" >&6
    38324034 fi
    38334035 
    3834 @@ -3917,12 +4161,12 @@
     4036@@ -3917,12 +4162,12 @@
    38354037 done
    38364038 
    38374039 fi;
    38384040-       echo "$as_me:3920: checking for native build C compiler" >&5
    3839 +       echo "$as_me:4164: checking for native build C compiler" >&5
     4041+       echo "$as_me:4165: checking for native build C compiler" >&5
    38404042 echo $ECHO_N "checking for native build C compiler... $ECHO_C" >&6
    38414043-       echo "$as_me:3922: result: $BUILD_CC" >&5
    3842 +       echo "$as_me:4166: result: $BUILD_CC" >&5
     4044+       echo "$as_me:4167: result: $BUILD_CC" >&5
    38434045 echo "${ECHO_T}$BUILD_CC" >&6
    38444046 
    38454047-       echo "$as_me:3925: checking for native build C preprocessor" >&5
    3846 +       echo "$as_me:4169: checking for native build C preprocessor" >&5
     4048+       echo "$as_me:4170: checking for native build C preprocessor" >&5
    38474049 echo $ECHO_N "checking for native build C preprocessor... $ECHO_C" >&6
    38484050 
    38494051 # Check whether --with-build-cpp or --without-build-cpp was given.
    3850 @@ -3932,10 +4176,10 @@
     4052@@ -3932,10 +4177,10 @@
    38514053 else
    38524054   BUILD_CPP='${BUILD_CC} -E'
    38534055 fi;
    38544056-       echo "$as_me:3935: result: $BUILD_CPP" >&5
    3855 +       echo "$as_me:4179: result: $BUILD_CPP" >&5
     4057+       echo "$as_me:4180: result: $BUILD_CPP" >&5
    38564058 echo "${ECHO_T}$BUILD_CPP" >&6
    38574059 
    38584060-       echo "$as_me:3938: checking for native build C flags" >&5
    3859 +       echo "$as_me:4182: checking for native build C flags" >&5
     4061+       echo "$as_me:4183: checking for native build C flags" >&5
    38604062 echo $ECHO_N "checking for native build C flags... $ECHO_C" >&6
    38614063 
    38624064 # Check whether --with-build-cflags or --without-build-cflags was given.
    3863 @@ -3943,10 +4187,10 @@
     4065@@ -3943,10 +4188,10 @@
    38644066   withval="$with_build_cflags"
    38654067   BUILD_CFLAGS="$withval"
    38664068 fi;
    38674069-       echo "$as_me:3946: result: $BUILD_CFLAGS" >&5
    3868 +       echo "$as_me:4190: result: $BUILD_CFLAGS" >&5
     4070+       echo "$as_me:4191: result: $BUILD_CFLAGS" >&5
    38694071 echo "${ECHO_T}$BUILD_CFLAGS" >&6
    38704072 
    38714073-       echo "$as_me:3949: checking for native build C preprocessor-flags" >&5
    3872 +       echo "$as_me:4193: checking for native build C preprocessor-flags" >&5
     4074+       echo "$as_me:4194: checking for native build C preprocessor-flags" >&5
    38734075 echo $ECHO_N "checking for native build C preprocessor-flags... $ECHO_C" >&6
    38744076 
    38754077 # Check whether --with-build-cppflags or --without-build-cppflags was given.
    3876 @@ -3954,10 +4198,10 @@
     4078@@ -3954,10 +4199,10 @@
    38774079   withval="$with_build_cppflags"
    38784080   BUILD_CPPFLAGS="$withval"
    38794081 fi;
    38804082-       echo "$as_me:3957: result: $BUILD_CPPFLAGS" >&5
    3881 +       echo "$as_me:4201: result: $BUILD_CPPFLAGS" >&5
     4083+       echo "$as_me:4202: result: $BUILD_CPPFLAGS" >&5
    38824084 echo "${ECHO_T}$BUILD_CPPFLAGS" >&6
    38834085 
    38844086-       echo "$as_me:3960: checking for native build linker-flags" >&5
    3885 +       echo "$as_me:4204: checking for native build linker-flags" >&5
     4087+       echo "$as_me:4205: checking for native build linker-flags" >&5
    38864088 echo $ECHO_N "checking for native build linker-flags... $ECHO_C" >&6
    38874089 
    38884090 # Check whether --with-build-ldflags or --without-build-ldflags was given.
    3889 @@ -3965,10 +4209,10 @@
     4091@@ -3965,10 +4210,10 @@
    38904092   withval="$with_build_ldflags"
    38914093   BUILD_LDFLAGS="$withval"
    38924094 fi;
    38934095-       echo "$as_me:3968: result: $BUILD_LDFLAGS" >&5
    3894 +       echo "$as_me:4212: result: $BUILD_LDFLAGS" >&5
     4096+       echo "$as_me:4213: result: $BUILD_LDFLAGS" >&5
    38954097 echo "${ECHO_T}$BUILD_LDFLAGS" >&6
    38964098 
    38974099-       echo "$as_me:3971: checking for native build linker-libraries" >&5
    3898 +       echo "$as_me:4215: checking for native build linker-libraries" >&5
     4100+       echo "$as_me:4216: checking for native build linker-libraries" >&5
    38994101 echo $ECHO_N "checking for native build linker-libraries... $ECHO_C" >&6
    39004102 
    39014103 # Check whether --with-build-libs or --without-build-libs was given.
    3902 @@ -3976,7 +4220,7 @@
     4104@@ -3976,7 +4221,7 @@
    39034105   withval="$with_build_libs"
    39044106   BUILD_LIBS="$withval"
    39054107 fi;
    39064108-       echo "$as_me:3979: result: $BUILD_LIBS" >&5
    3907 +       echo "$as_me:4223: result: $BUILD_LIBS" >&5
     4109+       echo "$as_me:4224: result: $BUILD_LIBS" >&5
    39084110 echo "${ECHO_T}$BUILD_LIBS" >&6
    39094111 
    39104112        # this assumes we're on Unix.
    3911 @@ -3986,7 +4230,7 @@
     4113@@ -3986,7 +4231,7 @@
    39124114        : ${BUILD_CC:='${CC}'}
    39134115 
    39144116        if ( test "$BUILD_CC" = "$CC" || test "$BUILD_CC" = '${CC}' ) ; then
    39154117-               { { echo "$as_me:3989: error: Cross-build requires two compilers.
    3916 +               { { echo "$as_me:4233: error: Cross-build requires two compilers.
     4118+               { { echo "$as_me:4234: error: Cross-build requires two compilers.
    39174119 Use --with-build-cc to specify the native compiler." >&5
    39184120 echo "$as_me: error: Cross-build requires two compilers.
    39194121 Use --with-build-cc to specify the native compiler." >&2;}
    3920 @@ -4027,7 +4271,7 @@
     4122@@ -4027,7 +4272,7 @@
    39214123 LIB_INSTALL=
    39224124 LIB_UNINSTALL=
    39234125 
    39244126-echo "$as_me:4030: checking if you want to build libraries with libtool" >&5
    3925 +echo "$as_me:4274: checking if you want to build libraries with libtool" >&5
     4127+echo "$as_me:4275: checking if you want to build libraries with libtool" >&5
    39264128 echo $ECHO_N "checking if you want to build libraries with libtool... $ECHO_C" >&6
    39274129 
    39284130 # Check whether --with-libtool or --without-libtool was given.
    3929 @@ -4037,11 +4281,11 @@
     4131@@ -4037,11 +4282,11 @@
    39304132 else
    39314133   with_libtool=no
    39324134 fi;
    39334135-echo "$as_me:4040: result: $with_libtool" >&5
    3934 +echo "$as_me:4284: result: $with_libtool" >&5
     4136+echo "$as_me:4285: result: $with_libtool" >&5
    39354137 echo "${ECHO_T}$with_libtool" >&6
    39364138 if test "$with_libtool" != "no"; then
     
    39414143 if test "x$prefix" != xNONE; then
    39424144   cf_path_syntax="$prefix"
    3943 @@ -4068,7 +4312,7 @@
     4145@@ -4068,7 +4313,7 @@
    39444146   with_libtool=`echo $with_libtool | sed -e s%NONE%$cf_path_syntax%`
    39454147   ;;
    39464148 *)
    39474149-  { { echo "$as_me:4071: error: expected a pathname, not \"$with_libtool\"" >&5
    3948 +  { { echo "$as_me:4315: error: expected a pathname, not \"$with_libtool\"" >&5
     4150+  { { echo "$as_me:4316: error: expected a pathname, not \"$with_libtool\"" >&5
    39494151 echo "$as_me: error: expected a pathname, not \"$with_libtool\"" >&2;}
    39504152    { (exit 1); exit 1; }; }
    39514153   ;;
    3952 @@ -4076,9 +4320,9 @@
     4154@@ -4076,9 +4321,9 @@
    39534155 
    39544156                LIBTOOL=$with_libtool
     
    39584160 set dummy libtool; ac_word=$2
    39594161-echo "$as_me:4081: checking for $ac_word" >&5
    3960 +echo "$as_me:4325: checking for $ac_word" >&5
     4162+echo "$as_me:4326: checking for $ac_word" >&5
    39614163 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    39624164 if test "${ac_cv_path_LIBTOOL+set}" = set; then
    39634165   echo $ECHO_N "(cached) $ECHO_C" >&6
    3964 @@ -4095,7 +4339,7 @@
     4166@@ -4095,7 +4340,7 @@
    39654167   test -z "$ac_dir" && ac_dir=.
    39664168   if $as_executable_p "$ac_dir/$ac_word"; then
    39674169    ac_cv_path_LIBTOOL="$ac_dir/$ac_word"
    39684170-   echo "$as_me:4098: found $ac_dir/$ac_word" >&5
    3969 +   echo "$as_me:4342: found $ac_dir/$ac_word" >&5
     4171+   echo "$as_me:4343: found $ac_dir/$ac_word" >&5
    39704172    break
    39714173 fi
    39724174 done
    3973 @@ -4106,19 +4350,19 @@
     4175@@ -4106,20 +4351,20 @@
    39744176 LIBTOOL=$ac_cv_path_LIBTOOL
    39754177 
    39764178 if test -n "$LIBTOOL"; then
    39774179-  echo "$as_me:4109: result: $LIBTOOL" >&5
    3978 +  echo "$as_me:4353: result: $LIBTOOL" >&5
     4180+  echo "$as_me:4354: result: $LIBTOOL" >&5
    39794181 echo "${ECHO_T}$LIBTOOL" >&6
    39804182 else
    39814183-  echo "$as_me:4112: result: no" >&5
    3982 +  echo "$as_me:4356: result: no" >&5
     4184+  echo "$as_me:4357: result: no" >&5
    39834185 echo "${ECHO_T}no" >&6
    39844186 fi
     
    39894191+       fi
    39904192+       if test -z "$LIBTOOL" ; then
    3991 +               { { echo "$as_me:4362: error: Cannot find libtool" >&5
     4193+               { { echo "$as_me:4363: error: Cannot find libtool" >&5
    39924194 echo "$as_me: error: Cannot find libtool" >&2;}
    39934195    { (exit 1); exit 1; }; }
    39944196-       fi
     4197-       LIB_CREATE='${LIBTOOL} --mode=link ${CC} -rpath ${DESTDIR}${libdir} -version-info `cut -f1 ${srcdir}/VERSION` ${LIBTOOL_OPTS} -o'
    39954198+       fi
    3996         LIB_CREATE='${LIBTOOL} --mode=link ${CC} -rpath ${DESTDIR}${libdir} -version-info `cut -f1 ${srcdir}/VERSION` ${LIBTOOL_OPTS} -o'
     4199+       LIB_CREATE='${LIBTOOL} --mode=link ${CC} -rpath ${DESTDIR}${libdir} -version-info `cut -f1 ${srcdir}/VERSION` ${LIBTOOL_OPTS} ${LT_UNDEF} -o'
    39974200        LIB_OBJECT='${OBJECTS:.o=.lo}'
    39984201        LIB_SUFFIX=.la
    3999 @@ -4130,17 +4374,17 @@
     4202        LIB_CLEAN='${LIBTOOL} --mode=clean'
     4203@@ -4130,24 +4375,32 @@
    40004204        LIB_PREP=:
    40014205 
    40024206        # Show the version of libtool
    40034207-       echo "$as_me:4133: checking version of libtool" >&5
    4004 +       echo "$as_me:4377: checking version of libtool" >&5
     4208+       echo "$as_me:4378: checking version of libtool" >&5
    40054209 echo $ECHO_N "checking version of libtool... $ECHO_C" >&6
    40064210 
    40074211        # Save the version in a cache variable - this is not entirely a good
    40084212        # thing, but the version string from libtool is very ugly, and for
    4009         # bug reports it might be useful to have the original string.
     4213-       # bug reports it might be useful to have the original string.
     4214+       # bug reports it might be useful to have the original string. "("
    40104215        cf_cv_libtool_version=`$LIBTOOL --version 2>&1 | sed -e '/^$/d' |sed -e '2,$d' -e 's/([^)]*)//g' -e 's/^[^1-9]*//' -e 's/[^0-9.].*//'`
    40114216-       echo "$as_me:4140: result: $cf_cv_libtool_version" >&5
    4012 +       echo "$as_me:4384: result: $cf_cv_libtool_version" >&5
     4217+       echo "$as_me:4385: result: $cf_cv_libtool_version" >&5
    40134218 echo "${ECHO_T}$cf_cv_libtool_version" >&6
    40144219        if test -z "$cf_cv_libtool_version" ; then
    40154220-               { { echo "$as_me:4143: error: This is not GNU libtool" >&5
    4016 +               { { echo "$as_me:4387: error: This is not GNU libtool" >&5
     4221+               { { echo "$as_me:4388: error: This is not GNU libtool" >&5
    40174222 echo "$as_me: error: This is not GNU libtool" >&2;}
    40184223    { (exit 1); exit 1; }; }
    40194224        fi
    4020 @@ -4168,7 +4412,7 @@
     4225 
     4226+       # special hack to add -no-undefined (which libtool should do for itself)
     4227+       LT_UNDEF=
     4228+       case "$cf_cv_system_name" in #(vi
     4229+       cygwin*|mingw32*|uwin*|aix[456]) #(vi
     4230+               LT_UNDEF=-no-undefined
     4231+               ;;
     4232+       esac
     4233+
     4234        # special hack to add --tag option for C++ compiler
     4235-       case $cf_cv_libtool_version in
     4236-       1.[5-9]*|[2-9]*)
     4237+       case $cf_cv_libtool_version in #(vi
     4238+       1.[5-9]*|[2-9].[0-9.a-z]*) #(vi
     4239                LIBTOOL_CXX="$LIBTOOL --tag=CXX"
     4240                LIBTOOL="$LIBTOOL --tag=CC"
     4241                ;;
     4242@@ -4168,7 +4421,7 @@
    40214243 
    40224244 else
    40234245 
    40244246-echo "$as_me:4171: checking if you want to build shared libraries" >&5
    4025 +echo "$as_me:4415: checking if you want to build shared libraries" >&5
     4247+echo "$as_me:4424: checking if you want to build shared libraries" >&5
    40264248 echo $ECHO_N "checking if you want to build shared libraries... $ECHO_C" >&6
    40274249 
    40284250 # Check whether --with-shared or --without-shared was given.
    4029 @@ -4178,11 +4422,11 @@
     4251@@ -4178,11 +4431,11 @@
    40304252 else
    40314253   with_shared=no
    40324254 fi;
    40334255-echo "$as_me:4181: result: $with_shared" >&5
    4034 +echo "$as_me:4425: result: $with_shared" >&5
     4256+echo "$as_me:4434: result: $with_shared" >&5
    40354257 echo "${ECHO_T}$with_shared" >&6
    40364258 test "$with_shared" = "yes" && cf_list_models="$cf_list_models shared"
    40374259 
    40384260-echo "$as_me:4185: checking if you want to build static libraries" >&5
    4039 +echo "$as_me:4429: checking if you want to build static libraries" >&5
     4261+echo "$as_me:4438: checking if you want to build static libraries" >&5
    40404262 echo $ECHO_N "checking if you want to build static libraries... $ECHO_C" >&6
    40414263 
    40424264 # Check whether --with-normal or --without-normal was given.
    4043 @@ -4192,11 +4436,11 @@
     4265@@ -4192,11 +4445,11 @@
    40444266 else
    40454267   with_normal=yes
    40464268 fi;
    40474269-echo "$as_me:4195: result: $with_normal" >&5
    4048 +echo "$as_me:4439: result: $with_normal" >&5
     4270+echo "$as_me:4448: result: $with_normal" >&5
    40494271 echo "${ECHO_T}$with_normal" >&6
    40504272 test "$with_normal" = "yes" && cf_list_models="$cf_list_models normal"
    40514273 
    40524274-echo "$as_me:4199: checking if you want to build debug libraries" >&5
    4053 +echo "$as_me:4443: checking if you want to build debug libraries" >&5
     4275+echo "$as_me:4452: checking if you want to build debug libraries" >&5
    40544276 echo $ECHO_N "checking if you want to build debug libraries... $ECHO_C" >&6
    40554277 
    40564278 # Check whether --with-debug or --without-debug was given.
    4057 @@ -4206,11 +4450,11 @@
     4279@@ -4206,11 +4459,11 @@
    40584280 else
    40594281   with_debug=yes
    40604282 fi;
    40614283-echo "$as_me:4209: result: $with_debug" >&5
    4062 +echo "$as_me:4453: result: $with_debug" >&5
     4284+echo "$as_me:4462: result: $with_debug" >&5
    40634285 echo "${ECHO_T}$with_debug" >&6
    40644286 test "$with_debug" = "yes" && cf_list_models="$cf_list_models debug"
    40654287 
    40664288-echo "$as_me:4213: checking if you want to build profiling libraries" >&5
    4067 +echo "$as_me:4457: checking if you want to build profiling libraries" >&5
     4289+echo "$as_me:4466: checking if you want to build profiling libraries" >&5
    40684290 echo $ECHO_N "checking if you want to build profiling libraries... $ECHO_C" >&6
    40694291 
    40704292 # Check whether --with-profile or --without-profile was given.
    4071 @@ -4220,7 +4464,7 @@
     4293@@ -4220,7 +4473,7 @@
    40724294 else
    40734295   with_profile=no
    40744296 fi;
    40754297-echo "$as_me:4223: result: $with_profile" >&5
    4076 +echo "$as_me:4467: result: $with_profile" >&5
     4298+echo "$as_me:4476: result: $with_profile" >&5
    40774299 echo "${ECHO_T}$with_profile" >&6
    40784300 test "$with_profile" = "yes" && cf_list_models="$cf_list_models profile"
    40794301 
    4080 @@ -4228,19 +4472,19 @@
     4302@@ -4228,19 +4481,19 @@
    40814303 
    40824304 ###############################################################################
    40834305 
    40844306-echo "$as_me:4231: checking for specified models" >&5
    4085 +echo "$as_me:4475: checking for specified models" >&5
     4307+echo "$as_me:4484: checking for specified models" >&5
    40864308 echo $ECHO_N "checking for specified models... $ECHO_C" >&6
    40874309 test -z "$cf_list_models" && cf_list_models=normal
    40884310 test "$with_libtool" != "no" && cf_list_models=libtool
    40894311-echo "$as_me:4235: result: $cf_list_models" >&5
    4090 +echo "$as_me:4479: result: $cf_list_models" >&5
     4312+echo "$as_me:4488: result: $cf_list_models" >&5
    40914313 echo "${ECHO_T}$cf_list_models" >&6
    40924314 
     
    40944316 ### up test-applications.
    40954317-echo "$as_me:4240: checking for default model" >&5
    4096 +echo "$as_me:4484: checking for default model" >&5
     4318+echo "$as_me:4493: checking for default model" >&5
    40974319 echo $ECHO_N "checking for default model... $ECHO_C" >&6
    40984320 DFT_LWR_MODEL=`echo "$cf_list_models" | $AWK '{print $1}'`
    40994321-echo "$as_me:4243: result: $DFT_LWR_MODEL" >&5
    4100 +echo "$as_me:4487: result: $DFT_LWR_MODEL" >&5
     4322+echo "$as_me:4496: result: $DFT_LWR_MODEL" >&5
    41014323 echo "${ECHO_T}$DFT_LWR_MODEL" >&6
    41024324 
    41034325 DFT_UPR_MODEL=`echo "$DFT_LWR_MODEL" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
    4104 @@ -4269,7 +4513,7 @@
     4326@@ -4269,7 +4522,7 @@
    41054327 
    41064328 ###############################################################################
    41074329 
    41084330-echo "$as_me:4272: checking if you want to build a separate terminfo library" >&5
    4109 +echo "$as_me:4516: checking if you want to build a separate terminfo library" >&5
     4331+echo "$as_me:4525: checking if you want to build a separate terminfo library" >&5
    41104332 echo $ECHO_N "checking if you want to build a separate terminfo library... $ECHO_C" >&6
    41114333 
    41124334 # Check whether --with-termlib or --without-termlib was given.
    4113 @@ -4279,10 +4523,10 @@
     4335@@ -4279,10 +4532,10 @@
    41144336 else
    41154337   with_termlib=no
    41164338 fi;
    41174339-echo "$as_me:4282: result: $with_termlib" >&5
    4118 +echo "$as_me:4526: result: $with_termlib" >&5
     4340+echo "$as_me:4535: result: $with_termlib" >&5
    41194341 echo "${ECHO_T}$with_termlib" >&6
    41204342 
    41214343-echo "$as_me:4285: checking if you want to build a separate tic library" >&5
    4122 +echo "$as_me:4529: checking if you want to build a separate tic library" >&5
     4344+echo "$as_me:4538: checking if you want to build a separate tic library" >&5
    41234345 echo $ECHO_N "checking if you want to build a separate tic library... $ECHO_C" >&6
    41244346 
    41254347 # Check whether --with-ticlib or --without-ticlib was given.
    4126 @@ -4292,13 +4536,13 @@
     4348@@ -4292,13 +4545,13 @@
    41274349 else
    41284350   with_ticlib=no
    41294351 fi;
    41304352-echo "$as_me:4295: result: $with_ticlib" >&5
    4131 +echo "$as_me:4539: result: $with_ticlib" >&5
     4353+echo "$as_me:4548: result: $with_ticlib" >&5
    41324354 echo "${ECHO_T}$with_ticlib" >&6
    41334355 
     
    41364358 
    41374359-echo "$as_me:4301: checking if you want to link with the GPM mouse library" >&5
    4138 +echo "$as_me:4545: checking if you want to link with the GPM mouse library" >&5
     4360+echo "$as_me:4554: checking if you want to link with the GPM mouse library" >&5
    41394361 echo $ECHO_N "checking if you want to link with the GPM mouse library... $ECHO_C" >&6
    41404362 
    41414363 # Check whether --with-gpm or --without-gpm was given.
    4142 @@ -4308,27 +4552,27 @@
     4364@@ -4308,27 +4561,27 @@
    41434365 else
    41444366   with_gpm=maybe
    41454367 fi;
    41464368-echo "$as_me:4311: result: $with_gpm" >&5
    4147 +echo "$as_me:4555: result: $with_gpm" >&5
     4369+echo "$as_me:4564: result: $with_gpm" >&5
    41484370 echo "${ECHO_T}$with_gpm" >&6
    41494371 
    41504372 if test "$with_gpm" != no ; then
    41514373-       echo "$as_me:4315: checking for gpm.h" >&5
    4152 +       echo "$as_me:4559: checking for gpm.h" >&5
     4374+       echo "$as_me:4568: checking for gpm.h" >&5
    41534375 echo $ECHO_N "checking for gpm.h... $ECHO_C" >&6
    41544376 if test "${ac_cv_header_gpm_h+set}" = set; then
     
    41574379   cat >conftest.$ac_ext <<_ACEOF
    41584380-#line 4321 "configure"
    4159 +#line 4565 "configure"
     4381+#line 4574 "configure"
    41604382 #include "confdefs.h"
    41614383 #include <gpm.h>
    41624384 _ACEOF
    41634385-if { (eval echo "$as_me:4325: \"$ac_cpp conftest.$ac_ext\"") >&5
    4164 +if { (eval echo "$as_me:4569: \"$ac_cpp conftest.$ac_ext\"") >&5
     4386+if { (eval echo "$as_me:4578: \"$ac_cpp conftest.$ac_ext\"") >&5
    41654387   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    41664388   ac_status=$?
     
    41694391   cat conftest.err >&5
    41704392-  echo "$as_me:4331: \$? = $ac_status" >&5
    4171 +  echo "$as_me:4575: \$? = $ac_status" >&5
     4393+  echo "$as_me:4584: \$? = $ac_status" >&5
    41724394   (exit $ac_status); } >/dev/null; then
    41734395   if test -s conftest.err; then
    41744396     ac_cpp_err=$ac_c_preproc_warn_flag
    4175 @@ -4347,7 +4591,7 @@
     4397@@ -4347,7 +4600,7 @@
    41764398 fi
    41774399 rm -f conftest.err conftest.$ac_ext
    41784400 fi
    41794401-echo "$as_me:4350: result: $ac_cv_header_gpm_h" >&5
    4180 +echo "$as_me:4594: result: $ac_cv_header_gpm_h" >&5
     4402+echo "$as_me:4603: result: $ac_cv_header_gpm_h" >&5
    41814403 echo "${ECHO_T}$ac_cv_header_gpm_h" >&6
    41824404 if test $ac_cv_header_gpm_h = yes; then
    41834405 
    4184 @@ -4358,14 +4602,14 @@
     4406@@ -4358,14 +4611,14 @@
    41854407                if test "$with_gpm" != yes && test "$with_gpm" != maybe ; then
    41864408                        test -n "$verbose" && echo "    assuming we really have GPM library" 1>&6
    41874409 
    41884410-echo "${as_me-configure}:4361: testing assuming we really have GPM library ..." 1>&5
    4189 +echo "${as_me-configure}:4605: testing assuming we really have GPM library ..." 1>&5
     4411+echo "${as_me-configure}:4614: testing assuming we really have GPM library ..." 1>&5
    41904412 
    41914413                        cat >>confdefs.h <<\EOF
     
    41954417                else
    41964418-                       echo "$as_me:4368: checking for Gpm_Open in -lgpm" >&5
    4197 +                       echo "$as_me:4612: checking for Gpm_Open in -lgpm" >&5
     4419+                       echo "$as_me:4621: checking for Gpm_Open in -lgpm" >&5
    41984420 echo $ECHO_N "checking for Gpm_Open in -lgpm... $ECHO_C" >&6
    41994421 if test "${ac_cv_lib_gpm_Gpm_Open+set}" = set; then
    42004422   echo $ECHO_N "(cached) $ECHO_C" >&6
    4201 @@ -4373,7 +4617,7 @@
     4423@@ -4373,7 +4626,7 @@
    42024424   ac_check_lib_save_LIBS=$LIBS
    42034425 LIBS="-lgpm  $LIBS"
    42044426 cat >conftest.$ac_ext <<_ACEOF
    42054427-#line 4376 "configure"
    4206 +#line 4620 "configure"
     4428+#line 4629 "configure"
    42074429 #include "confdefs.h"
    42084430 
    42094431 /* Override any gcc2 internal prototype to avoid an error.  */
    4210 @@ -4392,16 +4636,16 @@
     4432@@ -4392,16 +4645,16 @@
    42114433 }
    42124434 _ACEOF
    42134435 rm -f conftest.$ac_objext conftest$ac_exeext
    42144436-if { (eval echo "$as_me:4395: \"$ac_link\"") >&5
    4215 +if { (eval echo "$as_me:4639: \"$ac_link\"") >&5
     4437+if { (eval echo "$as_me:4648: \"$ac_link\"") >&5
    42164438   (eval $ac_link) 2>&5
    42174439   ac_status=$?
    42184440-  echo "$as_me:4398: \$? = $ac_status" >&5
    4219 +  echo "$as_me:4642: \$? = $ac_status" >&5
     4441+  echo "$as_me:4651: \$? = $ac_status" >&5
    42204442   (exit $ac_status); } &&
    42214443          { ac_try='test -s conftest$ac_exeext'
    42224444-  { (eval echo "$as_me:4401: \"$ac_try\"") >&5
    4223 +  { (eval echo "$as_me:4645: \"$ac_try\"") >&5
     4445+  { (eval echo "$as_me:4654: \"$ac_try\"") >&5
    42244446   (eval $ac_try) 2>&5
    42254447   ac_status=$?
    42264448-  echo "$as_me:4404: \$? = $ac_status" >&5
    4227 +  echo "$as_me:4648: \$? = $ac_status" >&5
     4449+  echo "$as_me:4657: \$? = $ac_status" >&5
    42284450   (exit $ac_status); }; }; then
    42294451   ac_cv_lib_gpm_Gpm_Open=yes
    42304452 else
    4231 @@ -4412,13 +4656,13 @@
     4453@@ -4412,13 +4665,13 @@
    42324454 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    42334455 LIBS=$ac_check_lib_save_LIBS
    42344456 fi
    42354457-echo "$as_me:4415: result: $ac_cv_lib_gpm_Gpm_Open" >&5
    4236 +echo "$as_me:4659: result: $ac_cv_lib_gpm_Gpm_Open" >&5
     4458+echo "$as_me:4668: result: $ac_cv_lib_gpm_Gpm_Open" >&5
    42374459 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Open" >&6
    42384460 if test $ac_cv_lib_gpm_Gpm_Open = yes; then
     
    42414463 
    42424464-                               { { echo "$as_me:4421: error: Cannot link with GPM library" >&5
    4243 +                               { { echo "$as_me:4665: error: Cannot link with GPM library" >&5
     4465+                               { { echo "$as_me:4674: error: Cannot link with GPM library" >&5
    42444466 echo "$as_me: error: Cannot link with GPM library" >&2;}
    42454467    { (exit 1); exit 1; }; }
    42464468                fi
    4247 @@ -4428,7 +4672,7 @@
     4469@@ -4428,7 +4681,7 @@
    42484470 
    42494471 else
    42504472 
    42514473-               test "$with_gpm" != maybe && { echo "$as_me:4431: WARNING: Cannot find GPM header" >&5
    4252 +               test "$with_gpm" != maybe && { echo "$as_me:4675: WARNING: Cannot find GPM header" >&5
     4474+               test "$with_gpm" != maybe && { echo "$as_me:4684: WARNING: Cannot find GPM header" >&5
    42534475 echo "$as_me: WARNING: Cannot find GPM header" >&2;}
    42544476                with_gpm=no
    42554477 
    4256 @@ -4437,7 +4681,7 @@
     4478@@ -4437,7 +4690,7 @@
    42574479 fi
    42584480 
    42594481 if test "$with_gpm" != no ; then
    42604482-       echo "$as_me:4440: checking if you want to load GPM dynamically" >&5
    4261 +       echo "$as_me:4684: checking if you want to load GPM dynamically" >&5
     4483+       echo "$as_me:4693: checking if you want to load GPM dynamically" >&5
    42624484 echo $ECHO_N "checking if you want to load GPM dynamically... $ECHO_C" >&6
    42634485 
    42644486 # Check whether --with-dlsym or --without-dlsym was given.
    4265 @@ -4447,18 +4691,18 @@
     4487@@ -4447,18 +4700,18 @@
    42664488 else
    42674489   with_dlsym=yes
    42684490 fi;
    42694491-       echo "$as_me:4450: result: $with_dlsym" >&5
    4270 +       echo "$as_me:4694: result: $with_dlsym" >&5
     4492+       echo "$as_me:4703: result: $with_dlsym" >&5
    42714493 echo "${ECHO_T}$with_dlsym" >&6
    42724494        if test "$with_dlsym" = yes ; then
     
    42744496 cf_have_dlsym=no
    42754497-echo "$as_me:4455: checking for dlsym" >&5
    4276 +echo "$as_me:4699: checking for dlsym" >&5
     4498+echo "$as_me:4708: checking for dlsym" >&5
    42774499 echo $ECHO_N "checking for dlsym... $ECHO_C" >&6
    42784500 if test "${ac_cv_func_dlsym+set}" = set; then
     
    42814503   cat >conftest.$ac_ext <<_ACEOF
    42824504-#line 4461 "configure"
    4283 +#line 4705 "configure"
     4505+#line 4714 "configure"
    42844506 #include "confdefs.h"
    42854507 /* System header to define __stub macros and hopefully few prototypes,
    42864508     which can conflict with char dlsym (); below.  */
    4287 @@ -4489,16 +4733,16 @@
     4509@@ -4489,16 +4742,16 @@
    42884510 }
    42894511 _ACEOF
    42904512 rm -f conftest.$ac_objext conftest$ac_exeext
    42914513-if { (eval echo "$as_me:4492: \"$ac_link\"") >&5
    4292 +if { (eval echo "$as_me:4736: \"$ac_link\"") >&5
     4514+if { (eval echo "$as_me:4745: \"$ac_link\"") >&5
    42934515   (eval $ac_link) 2>&5
    42944516   ac_status=$?
    42954517-  echo "$as_me:4495: \$? = $ac_status" >&5
    4296 +  echo "$as_me:4739: \$? = $ac_status" >&5
     4518+  echo "$as_me:4748: \$? = $ac_status" >&5
    42974519   (exit $ac_status); } &&
    42984520          { ac_try='test -s conftest$ac_exeext'
    42994521-  { (eval echo "$as_me:4498: \"$ac_try\"") >&5
    4300 +  { (eval echo "$as_me:4742: \"$ac_try\"") >&5
     4522+  { (eval echo "$as_me:4751: \"$ac_try\"") >&5
    43014523   (eval $ac_try) 2>&5
    43024524   ac_status=$?
    43034525-  echo "$as_me:4501: \$? = $ac_status" >&5
    4304 +  echo "$as_me:4745: \$? = $ac_status" >&5
     4526+  echo "$as_me:4754: \$? = $ac_status" >&5
    43054527   (exit $ac_status); }; }; then
    43064528   ac_cv_func_dlsym=yes
    43074529 else
    4308 @@ -4508,14 +4752,14 @@
     4530@@ -4508,14 +4761,14 @@
    43094531 fi
    43104532 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    43114533 fi
    43124534-echo "$as_me:4511: result: $ac_cv_func_dlsym" >&5
    4313 +echo "$as_me:4755: result: $ac_cv_func_dlsym" >&5
     4535+echo "$as_me:4764: result: $ac_cv_func_dlsym" >&5
    43144536 echo "${ECHO_T}$ac_cv_func_dlsym" >&6
    43154537 if test $ac_cv_func_dlsym = yes; then
     
    43194541 cf_have_libdl=no
    43204542-echo "$as_me:4518: checking for dlsym in -ldl" >&5
    4321 +echo "$as_me:4762: checking for dlsym in -ldl" >&5
     4543+echo "$as_me:4771: checking for dlsym in -ldl" >&5
    43224544 echo $ECHO_N "checking for dlsym in -ldl... $ECHO_C" >&6
    43234545 if test "${ac_cv_lib_dl_dlsym+set}" = set; then
    43244546   echo $ECHO_N "(cached) $ECHO_C" >&6
    4325 @@ -4523,7 +4767,7 @@
     4547@@ -4523,7 +4776,7 @@
    43264548   ac_check_lib_save_LIBS=$LIBS
    43274549 LIBS="-ldl  $LIBS"
    43284550 cat >conftest.$ac_ext <<_ACEOF
    43294551-#line 4526 "configure"
    4330 +#line 4770 "configure"
     4552+#line 4779 "configure"
    43314553 #include "confdefs.h"
    43324554 
    43334555 /* Override any gcc2 internal prototype to avoid an error.  */
    4334 @@ -4542,16 +4786,16 @@
     4556@@ -4542,16 +4795,16 @@
    43354557 }
    43364558 _ACEOF
    43374559 rm -f conftest.$ac_objext conftest$ac_exeext
    43384560-if { (eval echo "$as_me:4545: \"$ac_link\"") >&5
    4339 +if { (eval echo "$as_me:4789: \"$ac_link\"") >&5
     4561+if { (eval echo "$as_me:4798: \"$ac_link\"") >&5
    43404562   (eval $ac_link) 2>&5
    43414563   ac_status=$?
    43424564-  echo "$as_me:4548: \$? = $ac_status" >&5
    4343 +  echo "$as_me:4792: \$? = $ac_status" >&5
     4565+  echo "$as_me:4801: \$? = $ac_status" >&5
    43444566   (exit $ac_status); } &&
    43454567          { ac_try='test -s conftest$ac_exeext'
    43464568-  { (eval echo "$as_me:4551: \"$ac_try\"") >&5
    4347 +  { (eval echo "$as_me:4795: \"$ac_try\"") >&5
     4569+  { (eval echo "$as_me:4804: \"$ac_try\"") >&5
    43484570   (eval $ac_try) 2>&5
    43494571   ac_status=$?
    43504572-  echo "$as_me:4554: \$? = $ac_status" >&5
    4351 +  echo "$as_me:4798: \$? = $ac_status" >&5
     4573+  echo "$as_me:4807: \$? = $ac_status" >&5
    43524574   (exit $ac_status); }; }; then
    43534575   ac_cv_lib_dl_dlsym=yes
    43544576 else
    4355 @@ -4562,7 +4806,7 @@
     4577@@ -4562,7 +4815,7 @@
    43564578 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    43574579 LIBS=$ac_check_lib_save_LIBS
    43584580 fi
    43594581-echo "$as_me:4565: result: $ac_cv_lib_dl_dlsym" >&5
    4360 +echo "$as_me:4809: result: $ac_cv_lib_dl_dlsym" >&5
     4582+echo "$as_me:4818: result: $ac_cv_lib_dl_dlsym" >&5
    43614583 echo "${ECHO_T}$ac_cv_lib_dl_dlsym" >&6
    43624584 if test $ac_cv_lib_dl_dlsym = yes; then
    43634585 
    4364 @@ -4575,10 +4819,10 @@
     4586@@ -4575,10 +4828,10 @@
    43654587 if test "$cf_have_dlsym" = yes ; then
    43664588        test "$cf_have_libdl" = yes && LIBS="-ldl $LIBS"
    43674589 
    43684590-       echo "$as_me:4578: checking whether able to link to dl*() functions" >&5
    4369 +       echo "$as_me:4822: checking whether able to link to dl*() functions" >&5
     4591+       echo "$as_me:4831: checking whether able to link to dl*() functions" >&5
    43704592 echo $ECHO_N "checking whether able to link to dl*() functions... $ECHO_C" >&6
    43714593        cat >conftest.$ac_ext <<_ACEOF
    43724594-#line 4581 "configure"
    4373 +#line 4825 "configure"
     4595+#line 4834 "configure"
    43744596 #include "confdefs.h"
    43754597 #include <dlfcn.h>
    43764598 int
    4377 @@ -4596,16 +4840,16 @@
     4599@@ -4596,16 +4849,16 @@
    43784600 }
    43794601 _ACEOF
    43804602 rm -f conftest.$ac_objext conftest$ac_exeext
    43814603-if { (eval echo "$as_me:4599: \"$ac_link\"") >&5
    4382 +if { (eval echo "$as_me:4843: \"$ac_link\"") >&5
     4604+if { (eval echo "$as_me:4852: \"$ac_link\"") >&5
    43834605   (eval $ac_link) 2>&5
    43844606   ac_status=$?
    43854607-  echo "$as_me:4602: \$? = $ac_status" >&5
    4386 +  echo "$as_me:4846: \$? = $ac_status" >&5
     4608+  echo "$as_me:4855: \$? = $ac_status" >&5
    43874609   (exit $ac_status); } &&
    43884610          { ac_try='test -s conftest$ac_exeext'
    43894611-  { (eval echo "$as_me:4605: \"$ac_try\"") >&5
    4390 +  { (eval echo "$as_me:4849: \"$ac_try\"") >&5
     4612+  { (eval echo "$as_me:4858: \"$ac_try\"") >&5
    43914613   (eval $ac_try) 2>&5
    43924614   ac_status=$?
    43934615-  echo "$as_me:4608: \$? = $ac_status" >&5
    4394 +  echo "$as_me:4852: \$? = $ac_status" >&5
     4616+  echo "$as_me:4861: \$? = $ac_status" >&5
    43954617   (exit $ac_status); }; }; then
    43964618 
    43974619                cat >>confdefs.h <<\EOF
    4398 @@ -4616,15 +4860,15 @@
     4620@@ -4616,15 +4869,15 @@
    43994621   echo "$as_me: failed program was:" >&5
    44004622 cat conftest.$ac_ext >&5
    44014623 
    44024624-               { { echo "$as_me:4619: error: Cannot link test program for libdl" >&5
    4403 +               { { echo "$as_me:4863: error: Cannot link test program for libdl" >&5
     4625+               { { echo "$as_me:4872: error: Cannot link test program for libdl" >&5
    44044626 echo "$as_me: error: Cannot link test program for libdl" >&2;}
    44054627    { (exit 1); exit 1; }; }
     
    44074629 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    44084630-       echo "$as_me:4624: result: ok" >&5
    4409 +       echo "$as_me:4868: result: ok" >&5
     4631+       echo "$as_me:4877: result: ok" >&5
    44104632 echo "${ECHO_T}ok" >&6
    44114633 else
    44124634-       { { echo "$as_me:4627: error: Cannot find dlsym function" >&5
    4413 +       { { echo "$as_me:4871: error: Cannot find dlsym function" >&5
     4635+       { { echo "$as_me:4880: error: Cannot find dlsym function" >&5
    44144636 echo "$as_me: error: Cannot find dlsym function" >&2;}
    44154637    { (exit 1); exit 1; }; }
    44164638 fi
    4417 @@ -4632,12 +4876,12 @@
     4639@@ -4632,12 +4885,12 @@
    44184640                if test "$with_gpm" != yes ; then
    44194641                        test -n "$verbose" && echo "    assuming soname for gpm is $with_gpm" 1>&6
    44204642 
    44214643-echo "${as_me-configure}:4635: testing assuming soname for gpm is $with_gpm ..." 1>&5
    4422 +echo "${as_me-configure}:4879: testing assuming soname for gpm is $with_gpm ..." 1>&5
     4644+echo "${as_me-configure}:4888: testing assuming soname for gpm is $with_gpm ..." 1>&5
    44234645 
    44244646                        cf_cv_gpm_soname="$with_gpm"
     
    44264648 
    44274649-echo "$as_me:4640: checking for soname of gpm library" >&5
    4428 +echo "$as_me:4884: checking for soname of gpm library" >&5
     4650+echo "$as_me:4893: checking for soname of gpm library" >&5
    44294651 echo $ECHO_N "checking for soname of gpm library... $ECHO_C" >&6
    44304652 if test "${cf_cv_gpm_soname+set}" = set; then
    44314653   echo $ECHO_N "(cached) $ECHO_C" >&6
    4432 @@ -4655,15 +4899,15 @@
     4654@@ -4655,15 +4908,15 @@
    44334655 CF_EOF
    44344656 cf_save_LIBS="$LIBS"
    44354657        LIBS="-lgpm $LIBS"
    44364658-       if { (eval echo "$as_me:4658: \"$ac_compile\"") >&5
    4437 +       if { (eval echo "$as_me:4902: \"$ac_compile\"") >&5
     4659+       if { (eval echo "$as_me:4911: \"$ac_compile\"") >&5
    44384660   (eval $ac_compile) 2>&5
    44394661   ac_status=$?
    44404662-  echo "$as_me:4661: \$? = $ac_status" >&5
    4441 +  echo "$as_me:4905: \$? = $ac_status" >&5
     4663+  echo "$as_me:4914: \$? = $ac_status" >&5
    44424664   (exit $ac_status); } ; then
    44434665-               if { (eval echo "$as_me:4663: \"$ac_link\"") >&5
    4444 +               if { (eval echo "$as_me:4907: \"$ac_link\"") >&5
     4666+               if { (eval echo "$as_me:4916: \"$ac_link\"") >&5
    44454667   (eval $ac_link) 2>&5
    44464668   ac_status=$?
    44474669-  echo "$as_me:4666: \$? = $ac_status" >&5
    4448 +  echo "$as_me:4910: \$? = $ac_status" >&5
     4670+  echo "$as_me:4919: \$? = $ac_status" >&5
    44494671   (exit $ac_status); } ; then
    44504672                        cf_cv_gpm_soname=`ldd conftest$ac_exeext 2>/dev/null | sed -e 's,^.*/,,' -e 's, .*$,,' | fgrep libgpm.`
    44514673                        test -z "$cf_cv_gpm_soname" && cf_cv_gpm_soname=unknown
    4452 @@ -4674,7 +4918,7 @@
     4674@@ -4674,7 +4927,7 @@
    44534675 fi
    44544676 
    44554677 fi
    44564678-echo "$as_me:4677: result: $cf_cv_gpm_soname" >&5
    4457 +echo "$as_me:4921: result: $cf_cv_gpm_soname" >&5
     4679+echo "$as_me:4930: result: $cf_cv_gpm_soname" >&5
    44584680 echo "${ECHO_T}$cf_cv_gpm_soname" >&6
    44594681 
    44604682                fi
    4461 @@ -4690,7 +4934,7 @@
     4683@@ -4690,7 +4943,7 @@
    44624684 #define HAVE_LIBGPM 1
    44634685 EOF
    44644686 
    44654687-echo "$as_me:4693: checking for Gpm_Wgetch in -lgpm" >&5
    4466 +echo "$as_me:4937: checking for Gpm_Wgetch in -lgpm" >&5
     4688+echo "$as_me:4946: checking for Gpm_Wgetch in -lgpm" >&5
    44674689 echo $ECHO_N "checking for Gpm_Wgetch in -lgpm... $ECHO_C" >&6
    44684690 if test "${ac_cv_lib_gpm_Gpm_Wgetch+set}" = set; then
    44694691   echo $ECHO_N "(cached) $ECHO_C" >&6
    4470 @@ -4698,7 +4942,7 @@
     4692@@ -4698,7 +4951,7 @@
    44714693   ac_check_lib_save_LIBS=$LIBS
    44724694 LIBS="-lgpm  $LIBS"
    44734695 cat >conftest.$ac_ext <<_ACEOF
    44744696-#line 4701 "configure"
    4475 +#line 4945 "configure"
     4697+#line 4954 "configure"
    44764698 #include "confdefs.h"
    44774699 
    44784700 /* Override any gcc2 internal prototype to avoid an error.  */
    4479 @@ -4717,16 +4961,16 @@
     4701@@ -4717,16 +4970,16 @@
    44804702 }
    44814703 _ACEOF
    44824704 rm -f conftest.$ac_objext conftest$ac_exeext
    44834705-if { (eval echo "$as_me:4720: \"$ac_link\"") >&5
    4484 +if { (eval echo "$as_me:4964: \"$ac_link\"") >&5
     4706+if { (eval echo "$as_me:4973: \"$ac_link\"") >&5
    44854707   (eval $ac_link) 2>&5
    44864708   ac_status=$?
    44874709-  echo "$as_me:4723: \$? = $ac_status" >&5
    4488 +  echo "$as_me:4967: \$? = $ac_status" >&5
     4710+  echo "$as_me:4976: \$? = $ac_status" >&5
    44894711   (exit $ac_status); } &&
    44904712          { ac_try='test -s conftest$ac_exeext'
    44914713-  { (eval echo "$as_me:4726: \"$ac_try\"") >&5
    4492 +  { (eval echo "$as_me:4970: \"$ac_try\"") >&5
     4714+  { (eval echo "$as_me:4979: \"$ac_try\"") >&5
    44934715   (eval $ac_try) 2>&5
    44944716   ac_status=$?
    44954717-  echo "$as_me:4729: \$? = $ac_status" >&5
    4496 +  echo "$as_me:4973: \$? = $ac_status" >&5
     4718+  echo "$as_me:4982: \$? = $ac_status" >&5
    44974719   (exit $ac_status); }; }; then
    44984720   ac_cv_lib_gpm_Gpm_Wgetch=yes
    44994721 else
    4500 @@ -4737,11 +4981,11 @@
     4722@@ -4737,11 +4990,11 @@
    45014723 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    45024724 LIBS=$ac_check_lib_save_LIBS
    45034725 fi
    45044726-echo "$as_me:4740: result: $ac_cv_lib_gpm_Gpm_Wgetch" >&5
    4505 +echo "$as_me:4984: result: $ac_cv_lib_gpm_Gpm_Wgetch" >&5
     4727+echo "$as_me:4993: result: $ac_cv_lib_gpm_Gpm_Wgetch" >&5
    45064728 echo "${ECHO_T}$ac_cv_lib_gpm_Gpm_Wgetch" >&6
    45074729 if test $ac_cv_lib_gpm_Gpm_Wgetch = yes; then
    45084730 
    45094731-echo "$as_me:4744: checking if GPM is weakly bound to curses library" >&5
    4510 +echo "$as_me:4988: checking if GPM is weakly bound to curses library" >&5
     4732+echo "$as_me:4997: checking if GPM is weakly bound to curses library" >&5
    45114733 echo $ECHO_N "checking if GPM is weakly bound to curses library... $ECHO_C" >&6
    45124734 if test "${cf_cv_check_gpm_wgetch+set}" = set; then
    45134735   echo $ECHO_N "(cached) $ECHO_C" >&6
    4514 @@ -4765,15 +5009,15 @@
     4736@@ -4765,15 +5018,15 @@
    45154737        # to rely on the static library, noting that some packagers may not
    45164738        # include it.
    45174739        LIBS="-static -lgpm -dynamic $LIBS"
    45184740-       if { (eval echo "$as_me:4768: \"$ac_compile\"") >&5
    4519 +       if { (eval echo "$as_me:5012: \"$ac_compile\"") >&5
     4741+       if { (eval echo "$as_me:5021: \"$ac_compile\"") >&5
    45204742   (eval $ac_compile) 2>&5
    45214743   ac_status=$?
    45224744-  echo "$as_me:4771: \$? = $ac_status" >&5
    4523 +  echo "$as_me:5015: \$? = $ac_status" >&5
     4745+  echo "$as_me:5024: \$? = $ac_status" >&5
    45244746   (exit $ac_status); } ; then
    45254747-               if { (eval echo "$as_me:4773: \"$ac_link\"") >&5
    4526 +               if { (eval echo "$as_me:5017: \"$ac_link\"") >&5
     4748+               if { (eval echo "$as_me:5026: \"$ac_link\"") >&5
    45274749   (eval $ac_link) 2>&5
    45284750   ac_status=$?
    45294751-  echo "$as_me:4776: \$? = $ac_status" >&5
    4530 +  echo "$as_me:5020: \$? = $ac_status" >&5
     4752+  echo "$as_me:5029: \$? = $ac_status" >&5
    45314753   (exit $ac_status); } ; then
    45324754                        cf_cv_check_gpm_wgetch=`nm conftest$ac_exeext | egrep '\<wgetch\>' | egrep '\<[vVwW]\>'`
    45334755                        test -n "$cf_cv_check_gpm_wgetch" && cf_cv_check_gpm_wgetch=yes
    4534 @@ -4785,11 +5029,11 @@
     4756@@ -4785,11 +5038,11 @@
    45354757 fi
    45364758 
    45374759 fi
    45384760-echo "$as_me:4788: result: $cf_cv_check_gpm_wgetch" >&5
    4539 +echo "$as_me:5032: result: $cf_cv_check_gpm_wgetch" >&5
     4761+echo "$as_me:5041: result: $cf_cv_check_gpm_wgetch" >&5
    45404762 echo "${ECHO_T}$cf_cv_check_gpm_wgetch" >&6
    45414763 
    45424764 if test "$cf_cv_check_gpm_wgetch" != yes ; then
    45434765-       { echo "$as_me:4792: WARNING: GPM library is already linked with curses - read the FAQ" >&5
    4544 +       { echo "$as_me:5036: WARNING: GPM library is already linked with curses - read the FAQ" >&5
     4766+       { echo "$as_me:5045: WARNING: GPM library is already linked with curses - read the FAQ" >&5
    45454767 echo "$as_me: WARNING: GPM library is already linked with curses - read the FAQ" >&2;}
    45464768 fi
    45474769 
    4548 @@ -4799,7 +5043,7 @@
     4770@@ -4799,7 +5052,7 @@
    45494771 
    45504772 # not everyone has "test -c"
    45514773 if test -c /dev/sysmouse 2>/dev/null ; then
    45524774-echo "$as_me:4802: checking if you want to use sysmouse" >&5
    4553 +echo "$as_me:5046: checking if you want to use sysmouse" >&5
     4775+echo "$as_me:5055: checking if you want to use sysmouse" >&5
    45544776 echo $ECHO_N "checking if you want to use sysmouse... $ECHO_C" >&6
    45554777 
    45564778 # Check whether --with-sysmouse or --without-sysmouse was given.
    4557 @@ -4811,7 +5055,7 @@
     4779@@ -4811,7 +5064,7 @@
    45584780 fi;
    45594781        if test "$cf_with_sysmouse" != no ; then
    45604782        cat >conftest.$ac_ext <<_ACEOF
    45614783-#line 4814 "configure"
    4562 +#line 5058 "configure"
     4784+#line 5067 "configure"
    45634785 #include "confdefs.h"
    45644786 
    45654787 #include <osreldate.h>
    4566 @@ -4834,16 +5078,16 @@
     4788@@ -4834,16 +5087,16 @@
    45674789 }
    45684790 _ACEOF
    45694791 rm -f conftest.$ac_objext
    45704792-if { (eval echo "$as_me:4837: \"$ac_compile\"") >&5
    4571 +if { (eval echo "$as_me:5081: \"$ac_compile\"") >&5
     4793+if { (eval echo "$as_me:5090: \"$ac_compile\"") >&5
    45724794   (eval $ac_compile) 2>&5
    45734795   ac_status=$?
    45744796-  echo "$as_me:4840: \$? = $ac_status" >&5
    4575 +  echo "$as_me:5084: \$? = $ac_status" >&5
     4797+  echo "$as_me:5093: \$? = $ac_status" >&5
    45764798   (exit $ac_status); } &&
    45774799          { ac_try='test -s conftest.$ac_objext'
    45784800-  { (eval echo "$as_me:4843: \"$ac_try\"") >&5
    4579 +  { (eval echo "$as_me:5087: \"$ac_try\"") >&5
     4801+  { (eval echo "$as_me:5096: \"$ac_try\"") >&5
    45804802   (eval $ac_try) 2>&5
    45814803   ac_status=$?
    45824804-  echo "$as_me:4846: \$? = $ac_status" >&5
    4583 +  echo "$as_me:5090: \$? = $ac_status" >&5
     4805+  echo "$as_me:5099: \$? = $ac_status" >&5
    45844806   (exit $ac_status); }; }; then
    45854807   cf_with_sysmouse=yes
    45864808 else
    4587 @@ -4853,7 +5097,7 @@
     4809@@ -4853,7 +5106,7 @@
    45884810 fi
    45894811 rm -f conftest.$ac_objext conftest.$ac_ext
    45904812        fi
    45914813-echo "$as_me:4856: result: $cf_with_sysmouse" >&5
    4592 +echo "$as_me:5100: result: $cf_with_sysmouse" >&5
     4814+echo "$as_me:5109: result: $cf_with_sysmouse" >&5
    45934815 echo "${ECHO_T}$cf_with_sysmouse" >&6
    45944816 test "$cf_with_sysmouse" = yes && cat >>confdefs.h <<\EOF
    45954817 #define USE_SYSMOUSE 1
    4596 @@ -4871,7 +5115,7 @@
     4818@@ -4871,7 +5124,7 @@
    45974819        test -n "$GXX" && test "${ac_cv_prog_cxx_g}" != yes && CXX_G_OPT=''
    45984820 fi
    45994821 
    46004822-echo "$as_me:4874: checking for default loader flags" >&5
    4601 +echo "$as_me:5118: checking for default loader flags" >&5
     4823+echo "$as_me:5127: checking for default loader flags" >&5
    46024824 echo $ECHO_N "checking for default loader flags... $ECHO_C" >&6
    46034825 case $DFT_LWR_MODEL in
    46044826 libtool) LD_MODEL=''   ;;
    4605 @@ -4880,13 +5124,13 @@
     4827@@ -4880,13 +5133,13 @@
    46064828 profile) LD_MODEL='-pg';;
    46074829 shared)  LD_MODEL=''   ;;
    46084830 esac
    46094831-echo "$as_me:4883: result: $LD_MODEL" >&5
    4610 +echo "$as_me:5127: result: $LD_MODEL" >&5
     4832+echo "$as_me:5136: result: $LD_MODEL" >&5
    46114833 echo "${ECHO_T}$LD_MODEL" >&6
    46124834 
     
    46154837 
    46164838-echo "$as_me:4889: checking if rpath option should be used" >&5
    4617 +echo "$as_me:5133: checking if rpath option should be used" >&5
     4839+echo "$as_me:5142: checking if rpath option should be used" >&5
    46184840 echo $ECHO_N "checking if rpath option should be used... $ECHO_C" >&6
    46194841 
    46204842 # Check whether --enable-rpath or --disable-rpath was given.
    4621 @@ -4896,10 +5140,10 @@
     4843@@ -4896,10 +5149,10 @@
    46224844 else
    46234845   cf_cv_ld_rpath=no
    46244846 fi;
    46254847-echo "$as_me:4899: result: $cf_cv_ld_rpath" >&5
    4626 +echo "$as_me:5143: result: $cf_cv_ld_rpath" >&5
     4848+echo "$as_me:5152: result: $cf_cv_ld_rpath" >&5
    46274849 echo "${ECHO_T}$cf_cv_ld_rpath" >&6
    46284850 
    46294851-echo "$as_me:4902: checking if shared libraries should be relinked during install" >&5
    4630 +echo "$as_me:5146: checking if shared libraries should be relinked during install" >&5
     4852+echo "$as_me:5155: checking if shared libraries should be relinked during install" >&5
    46314853 echo $ECHO_N "checking if shared libraries should be relinked during install... $ECHO_C" >&6
    46324854 
    46334855 # Check whether --enable-relink or --disable-relink was given.
    4634 @@ -4909,19 +5153,20 @@
     4856@@ -4909,19 +5162,20 @@
    46354857 else
    46364858   cf_cv_do_relink=yes
    46374859 fi;
    46384860-echo "$as_me:4912: result: $cf_cv_do_relink" >&5
    4639 +echo "$as_me:5156: result: $cf_cv_do_relink" >&5
     4861+echo "$as_me:5165: result: $cf_cv_do_relink" >&5
    46404862 echo "${ECHO_T}$cf_cv_do_relink" >&6
    46414863        ;;
     
    46514873 
    46524874-       echo "$as_me:4924: checking if release/abi version should be used for shared libs" >&5
    4653 +       echo "$as_me:5169: checking if release/abi version should be used for shared libs" >&5
     4875+       echo "$as_me:5178: checking if release/abi version should be used for shared libs" >&5
    46544876 echo $ECHO_N "checking if release/abi version should be used for shared libs... $ECHO_C" >&6
    46554877 
    46564878 # Check whether --with-shlib-version or --without-shlib-version was given.
    4657 @@ -4936,7 +5181,7 @@
     4879@@ -4936,7 +5190,7 @@
    46584880                cf_cv_shlib_version=$withval
    46594881                ;;
    46604882        *)
    46614883-               { { echo "$as_me:4939: error: option value must be one of: rel, abi, auto or no" >&5
    4662 +               { { echo "$as_me:5184: error: option value must be one of: rel, abi, auto or no" >&5
     4884+               { { echo "$as_me:5193: error: option value must be one of: rel, abi, auto or no" >&5
    46634885 echo "$as_me: error: option value must be one of: rel, abi, auto or no" >&2;}
    46644886    { (exit 1); exit 1; }; }
    46654887                ;;
    4666 @@ -4945,7 +5190,7 @@
     4888@@ -4945,7 +5199,7 @@
    46674889 else
    46684890   cf_cv_shlib_version=auto
    46694891 fi;
    46704892-       echo "$as_me:4948: result: $cf_cv_shlib_version" >&5
    4671 +       echo "$as_me:5193: result: $cf_cv_shlib_version" >&5
     4893+       echo "$as_me:5202: result: $cf_cv_shlib_version" >&5
    46724894 echo "${ECHO_T}$cf_cv_shlib_version" >&6
    46734895 
    46744896        cf_cv_rm_so_locs=no
    4675 @@ -4954,14 +5199,14 @@
     4897@@ -4954,14 +5208,14 @@
    46764898        CC_SHARED_OPTS=
    46774899        if test "$GCC" = yes
    46784900        then
    46794901-               echo "$as_me:4957: checking which $CC option to use" >&5
    4680 +               echo "$as_me:5202: checking which $CC option to use" >&5
     4902+               echo "$as_me:5211: checking which $CC option to use" >&5
    46814903 echo $ECHO_N "checking which $CC option to use... $ECHO_C" >&6
    46824904                cf_save_CFLAGS="$CFLAGS"
     
    46864908                        cat >conftest.$ac_ext <<_ACEOF
    46874909-#line 4964 "configure"
    4688 +#line 5209 "configure"
     4910+#line 5218 "configure"
    46894911 #include "confdefs.h"
    46904912 #include <stdio.h>
    46914913 int
    4692 @@ -4973,16 +5218,16 @@
     4914@@ -4973,16 +5227,16 @@
    46934915 }
    46944916 _ACEOF
    46954917 rm -f conftest.$ac_objext
    46964918-if { (eval echo "$as_me:4976: \"$ac_compile\"") >&5
    4697 +if { (eval echo "$as_me:5221: \"$ac_compile\"") >&5
     4919+if { (eval echo "$as_me:5230: \"$ac_compile\"") >&5
    46984920   (eval $ac_compile) 2>&5
    46994921   ac_status=$?
    47004922-  echo "$as_me:4979: \$? = $ac_status" >&5
    4701 +  echo "$as_me:5224: \$? = $ac_status" >&5
     4923+  echo "$as_me:5233: \$? = $ac_status" >&5
    47024924   (exit $ac_status); } &&
    47034925          { ac_try='test -s conftest.$ac_objext'
    47044926-  { (eval echo "$as_me:4982: \"$ac_try\"") >&5
    4705 +  { (eval echo "$as_me:5227: \"$ac_try\"") >&5
     4927+  { (eval echo "$as_me:5236: \"$ac_try\"") >&5
    47064928   (eval $ac_try) 2>&5
    47074929   ac_status=$?
    47084930-  echo "$as_me:4985: \$? = $ac_status" >&5
    4709 +  echo "$as_me:5230: \$? = $ac_status" >&5
     4931+  echo "$as_me:5239: \$? = $ac_status" >&5
    47104932   (exit $ac_status); }; }; then
    47114933   break
    47124934 else
    4713 @@ -4991,7 +5236,7 @@
     4935@@ -4991,7 +5245,7 @@
    47144936 fi
    47154937 rm -f conftest.$ac_objext conftest.$ac_ext
    47164938                done
    47174939-               echo "$as_me:4994: result: $CC_SHARED_OPTS" >&5
    4718 +               echo "$as_me:5239: result: $CC_SHARED_OPTS" >&5
     4940+               echo "$as_me:5248: result: $CC_SHARED_OPTS" >&5
    47194941 echo "${ECHO_T}$CC_SHARED_OPTS" >&6
    47204942                CFLAGS="$cf_save_CFLAGS"
    47214943        fi
    4722 @@ -4999,6 +5244,12 @@
     4944@@ -4999,6 +5253,12 @@
    47234945        cf_cv_shlib_version_infix=no
    47244946 
     
    47334955                MK_SHARED_LIB='${CC} ${CFLAGS} -o $@ -Xlinker -soname=`basename $@` -nostart -e 0'
    47344956                ;;
    4735 @@ -5027,7 +5278,7 @@
     4957@@ -5027,7 +5287,7 @@
    47364958                MK_SHARED_LIB='${CC} ${CFLAGS} -dynamiclib -install_name ${libdir}/`basename $@` -compatibility_version ${ABI_VERSION} -current_version ${ABI_VERSION} -o $@'
    47374959                test "$cf_cv_shlib_version" = auto && cf_cv_shlib_version=abi
    47384960                cf_cv_shlib_version_infix=yes
    47394961-               echo "$as_me:5030: checking if ld -search_paths_first works" >&5
    4740 +               echo "$as_me:5281: checking if ld -search_paths_first works" >&5
     4962+               echo "$as_me:5290: checking if ld -search_paths_first works" >&5
    47414963 echo $ECHO_N "checking if ld -search_paths_first works... $ECHO_C" >&6
    47424964 if test "${cf_cv_ldflags_search_paths_first+set}" = set; then
    47434965   echo $ECHO_N "(cached) $ECHO_C" >&6
    4744 @@ -5036,7 +5287,7 @@
     4966@@ -5036,7 +5296,7 @@
    47454967                        cf_save_LDFLAGS=$LDFLAGS
    47464968                        LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
    47474969                        cat >conftest.$ac_ext <<_ACEOF
    47484970-#line 5039 "configure"
    4749 +#line 5290 "configure"
     4971+#line 5299 "configure"
    47504972 #include "confdefs.h"
    47514973 
    47524974 int
    4753 @@ -5048,16 +5299,16 @@
     4975@@ -5048,16 +5308,16 @@
    47544976 }
    47554977 _ACEOF
    47564978 rm -f conftest.$ac_objext conftest$ac_exeext
    47574979-if { (eval echo "$as_me:5051: \"$ac_link\"") >&5
    4758 +if { (eval echo "$as_me:5302: \"$ac_link\"") >&5
     4980+if { (eval echo "$as_me:5311: \"$ac_link\"") >&5
    47594981   (eval $ac_link) 2>&5
    47604982   ac_status=$?
    47614983-  echo "$as_me:5054: \$? = $ac_status" >&5
    4762 +  echo "$as_me:5305: \$? = $ac_status" >&5
     4984+  echo "$as_me:5314: \$? = $ac_status" >&5
    47634985   (exit $ac_status); } &&
    47644986          { ac_try='test -s conftest$ac_exeext'
    47654987-  { (eval echo "$as_me:5057: \"$ac_try\"") >&5
    4766 +  { (eval echo "$as_me:5308: \"$ac_try\"") >&5
     4988+  { (eval echo "$as_me:5317: \"$ac_try\"") >&5
    47674989   (eval $ac_try) 2>&5
    47684990   ac_status=$?
    47694991-  echo "$as_me:5060: \$? = $ac_status" >&5
    4770 +  echo "$as_me:5311: \$? = $ac_status" >&5
     4992+  echo "$as_me:5320: \$? = $ac_status" >&5
    47714993   (exit $ac_status); }; }; then
    47724994   cf_cv_ldflags_search_paths_first=yes
    47734995 else
    4774 @@ -5068,7 +5319,7 @@
     4996@@ -5068,7 +5328,7 @@
    47754997 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    47764998                                LDFLAGS=$cf_save_LDFLAGS
    47774999 fi
    47785000-echo "$as_me:5071: result: $cf_cv_ldflags_search_paths_first" >&5
    4779 +echo "$as_me:5322: result: $cf_cv_ldflags_search_paths_first" >&5
     5001+echo "$as_me:5331: result: $cf_cv_ldflags_search_paths_first" >&5
    47805002 echo "${ECHO_T}$cf_cv_ldflags_search_paths_first" >&6
    47815003                if test $cf_cv_ldflags_search_paths_first = yes; then
    47825004                        LDFLAGS="$LDFLAGS -Wl,-search_paths_first"
    4783 @@ -5090,10 +5341,10 @@
     5005@@ -5090,10 +5350,10 @@
    47845006        irix*)
    47855007                if test "$cf_cv_ld_rpath" = yes ; then
     
    47945016                        fi
    47955017                fi
    4796 @@ -5112,7 +5363,7 @@
     5018@@ -5112,7 +5372,7 @@
    47975019                        LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
    47985020                fi
     
    48035025                fi
    48045026 
    4805 @@ -5131,7 +5382,7 @@
     5027@@ -5131,7 +5391,7 @@
    48065028                        LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
    48075029                fi
     
    48125034                fi
    48135035                CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
    4814 @@ -5143,7 +5394,7 @@
     5036@@ -5143,7 +5403,7 @@
    48155037                cf_cv_shared_soname='`basename $@`'
    48165038        fi
     
    48215043        nto-qnx*|openbsd*|freebsd[12].*)
    48225044                CC_SHARED_OPTS="$CC_SHARED_OPTS -DPIC"
    4823 @@ -5155,7 +5406,7 @@
     5045@@ -5155,7 +5415,7 @@
    48245046                if test "$DFT_LWR_MODEL" = "shared" && test "$cf_cv_ld_rpath" = yes ; then
    48255047                        LOCAL_LDFLAGS="-rpath \$(LOCAL_LIBDIR)"
     
    48305052                fi
    48315053 
    4832 @@ -5166,11 +5417,11 @@
     5054@@ -5166,11 +5426,11 @@
    48335055                cf_cv_shared_soname='`basename $@`'
    48345056        fi
     
    48445066                        LOCAL_LDFLAGS="-Wl,-rpath,\$(LOCAL_LIBDIR)"
    48455067                        LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
    4846 @@ -5192,7 +5443,7 @@
     5068@@ -5192,7 +5452,7 @@
    48475069 
    48485070                        MK_SHARED_LIB='${CC} ${CFLAGS} -shared -Wl,-soname,'$cf_cv_shared_soname' -o $@'
     
    48535075                ;;
    48545076        osf*|mls+*)
    4855 @@ -5211,7 +5462,7 @@
     5077@@ -5211,7 +5471,7 @@
    48565078                        LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
    48575079                fi
     
    48625084                fi
    48635085                cf_cv_rm_so_locs=yes
    4864 @@ -5246,7 +5497,7 @@
     5086@@ -5246,7 +5506,7 @@
    48655087                        LOCAL_LDFLAGS2="$LOCAL_LDFLAGS"
    48665088                fi
     
    48715093                fi
    48725094 
    4873 @@ -5258,7 +5509,43 @@
     5095@@ -5258,7 +5518,43 @@
    48745096        fi
    48755097 
     
    48815103+                               CFLAGS="$cf_shared_opts $cf_save_CFLAGS"
    48825104+                               cat >conftest.$ac_ext <<_ACEOF
    4883 +#line 5517 "configure"
     5105+#line 5526 "configure"
    48845106+#include "confdefs.h"
    48855107+#include <stdio.h>
     
    48935115+_ACEOF
    48945116+rm -f conftest.$ac_objext
    4895 +if { (eval echo "$as_me:5529: \"$ac_compile\"") >&5
     5117+if { (eval echo "$as_me:5538: \"$ac_compile\"") >&5
    48965118+  (eval $ac_compile) 2>&5
    48975119+  ac_status=$?
    4898 +  echo "$as_me:5532: \$? = $ac_status" >&5
     5120+  echo "$as_me:5541: \$? = $ac_status" >&5
    48995121+  (exit $ac_status); } &&
    49005122+         { ac_try='test -s conftest.$ac_objext'
    4901 +  { (eval echo "$as_me:5535: \"$ac_try\"") >&5
     5123+  { (eval echo "$as_me:5544: \"$ac_try\"") >&5
    49025124+  (eval $ac_try) 2>&5
    49035125+  ac_status=$?
    4904 +  echo "$as_me:5538: \$? = $ac_status" >&5
     5126+  echo "$as_me:5547: \$? = $ac_status" >&5
    49055127+  (exit $ac_status); }; }; then
    49065128+  break
     
    49165138                else
    49175139                        MK_SHARED_LIB='${CC} -shared -dy -G -h '$cf_cv_shared_soname' -o $@'
    4918 @@ -5285,20 +5572,20 @@
     5140@@ -5285,20 +5581,20 @@
    49195141                        test "$cf_cv_do_symlinks" = no && cf_cv_do_symlinks=yes
    49205142                        ;;
    49215143                *)
    49225144-                       { echo "$as_me:5288: WARNING: ignored --with-shlib-version" >&5
    4923 +                       { echo "$as_me:5575: WARNING: ignored --with-shlib-version" >&5
     5145+                       { echo "$as_me:5584: WARNING: ignored --with-shlib-version" >&5
    49245146 echo "$as_me: WARNING: ignored --with-shlib-version" >&2;}
    49255147                        ;;
     
    49315153-               echo "$as_me:5296: checking if we need a space after rpath option" >&5
    49325154+       if test -n "$LD_RPATH_OPT" ; then
    4933 +               echo "$as_me:5583: checking if we need a space after rpath option" >&5
     5155+               echo "$as_me:5592: checking if we need a space after rpath option" >&5
    49345156 echo $ECHO_N "checking if we need a space after rpath option... $ECHO_C" >&6
    49355157                cf_save_LIBS="$LIBS"
     
    49385160                cat >conftest.$ac_ext <<_ACEOF
    49395161-#line 5301 "configure"
    4940 +#line 5588 "configure"
     5162+#line 5597 "configure"
    49415163 #include "confdefs.h"
    49425164 
    49435165 int
    4944 @@ -5310,16 +5597,16 @@
     5166@@ -5310,16 +5606,16 @@
    49455167 }
    49465168 _ACEOF
    49475169 rm -f conftest.$ac_objext conftest$ac_exeext
    49485170-if { (eval echo "$as_me:5313: \"$ac_link\"") >&5
    4949 +if { (eval echo "$as_me:5600: \"$ac_link\"") >&5
     5171+if { (eval echo "$as_me:5609: \"$ac_link\"") >&5
    49505172   (eval $ac_link) 2>&5
    49515173   ac_status=$?
    49525174-  echo "$as_me:5316: \$? = $ac_status" >&5
    4953 +  echo "$as_me:5603: \$? = $ac_status" >&5
     5175+  echo "$as_me:5612: \$? = $ac_status" >&5
    49545176   (exit $ac_status); } &&
    49555177          { ac_try='test -s conftest$ac_exeext'
    49565178-  { (eval echo "$as_me:5319: \"$ac_try\"") >&5
    4957 +  { (eval echo "$as_me:5606: \"$ac_try\"") >&5
     5179+  { (eval echo "$as_me:5615: \"$ac_try\"") >&5
    49585180   (eval $ac_try) 2>&5
    49595181   ac_status=$?
    49605182-  echo "$as_me:5322: \$? = $ac_status" >&5
    4961 +  echo "$as_me:5609: \$? = $ac_status" >&5
     5183+  echo "$as_me:5618: \$? = $ac_status" >&5
    49625184   (exit $ac_status); }; }; then
    49635185   cf_rpath_space=no
    49645186 else
    4965 @@ -5329,16 +5616,16 @@
     5187@@ -5329,16 +5625,16 @@
    49665188 fi
    49675189 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    49685190                LIBS="$cf_save_LIBS"
    49695191-               echo "$as_me:5332: result: $cf_rpath_space" >&5
    4970 +               echo "$as_me:5619: result: $cf_rpath_space" >&5
     5192+               echo "$as_me:5628: result: $cf_rpath_space" >&5
    49715193 echo "${ECHO_T}$cf_rpath_space" >&6
    49725194-               test "$cf_rpath_space" = yes && cf_ld_rpath_opt="$cf_ld_rpath_opt "
     
    49805202                if test "$model" = "shared"; then
    49815203-                       { { echo "$as_me:5341: error: Shared libraries are not supported in this version" >&5
    4982 +                       { { echo "$as_me:5628: error: Shared libraries are not supported in this version" >&5
     5204+                       { { echo "$as_me:5637: error: Shared libraries are not supported in this version" >&5
    49835205 echo "$as_me: error: Shared libraries are not supported in this version" >&2;}
    49845206    { (exit 1); exit 1; }; }
    49855207                fi
    4986 @@ -5348,7 +5635,7 @@
     5208@@ -5348,7 +5644,7 @@
    49875209 ###############################################################################
    49885210 
    49895211 ###    use option --disable-overwrite to leave out the link to -lcurses
    49905212-echo "$as_me:5351: checking if you wish to install ncurses overwriting curses" >&5
    4991 +echo "$as_me:5638: checking if you wish to install ncurses overwriting curses" >&5
     5213+echo "$as_me:5647: checking if you wish to install ncurses overwriting curses" >&5
    49925214 echo $ECHO_N "checking if you wish to install ncurses overwriting curses... $ECHO_C" >&6
    49935215 
    49945216 # Check whether --enable-overwrite or --disable-overwrite was given.
    4995 @@ -5358,10 +5645,10 @@
     5217@@ -5358,10 +5654,10 @@
    49965218 else
    49975219   if test "$prefix" = "/usr" ; then with_overwrite=yes; else with_overwrite=no; fi
    49985220 fi;
    49995221-echo "$as_me:5361: result: $with_overwrite" >&5
    5000 +echo "$as_me:5648: result: $with_overwrite" >&5
     5222+echo "$as_me:5657: result: $with_overwrite" >&5
    50015223 echo "${ECHO_T}$with_overwrite" >&6
    50025224 
    50035225-echo "$as_me:5364: checking if external terminfo-database is used" >&5
    5004 +echo "$as_me:5651: checking if external terminfo-database is used" >&5
     5226+echo "$as_me:5660: checking if external terminfo-database is used" >&5
    50055227 echo $ECHO_N "checking if external terminfo-database is used... $ECHO_C" >&6
    50065228 
    50075229 # Check whether --enable-database or --disable-database was given.
    5008 @@ -5371,7 +5658,7 @@
     5230@@ -5371,7 +5667,7 @@
    50095231 else
    50105232   use_database=yes
    50115233 fi;
    50125234-echo "$as_me:5374: result: $use_database" >&5
    5013 +echo "$as_me:5661: result: $use_database" >&5
     5235+echo "$as_me:5670: result: $use_database" >&5
    50145236 echo "${ECHO_T}$use_database" >&6
    50155237 
    50165238 case $host_os in #(vi
    5017 @@ -5384,8 +5671,8 @@
     5239@@ -5384,8 +5680,8 @@
    50185240 esac
    50195241 
     
    50265248 
    50275249 if test "$use_database" != no ; then
    5028 @@ -5393,7 +5680,7 @@
     5250@@ -5393,7 +5689,7 @@
    50295251 #define USE_DATABASE 1
    50305252 EOF
    50315253 
    50325254-       echo "$as_me:5396: checking which terminfo source-file will be installed" >&5
    5033 +       echo "$as_me:5683: checking which terminfo source-file will be installed" >&5
     5255+       echo "$as_me:5692: checking which terminfo source-file will be installed" >&5
    50345256 echo $ECHO_N "checking which terminfo source-file will be installed... $ECHO_C" >&6
    50355257 
    50365258 # Check whether --enable-database or --disable-database was given.
    5037 @@ -5401,10 +5688,10 @@
     5259@@ -5401,10 +5697,10 @@
    50385260   enableval="$enable_database"
    50395261   TERMINFO_SRC=$withval
    50405262 fi;
    50415263-       echo "$as_me:5404: result: $TERMINFO_SRC" >&5
    5042 +       echo "$as_me:5691: result: $TERMINFO_SRC" >&5
     5264+       echo "$as_me:5700: result: $TERMINFO_SRC" >&5
    50435265 echo "${ECHO_T}$TERMINFO_SRC" >&6
    50445266 
    50455267-       echo "$as_me:5407: checking whether to use hashed database instead of directory/tree" >&5
    5046 +       echo "$as_me:5694: checking whether to use hashed database instead of directory/tree" >&5
     5268+       echo "$as_me:5703: checking whether to use hashed database instead of directory/tree" >&5
    50475269 echo $ECHO_N "checking whether to use hashed database instead of directory/tree... $ECHO_C" >&6
    50485270 
    50495271 # Check whether --with-hashed-db or --without-hashed-db was given.
    5050 @@ -5414,13 +5701,13 @@
     5272@@ -5414,13 +5710,13 @@
    50515273 else
    50525274   with_hashed_db=no
    50535275 fi;
    50545276-       echo "$as_me:5417: result: $with_hashed_db" >&5
    5055 +       echo "$as_me:5704: result: $with_hashed_db" >&5
     5277+       echo "$as_me:5713: result: $with_hashed_db" >&5
    50565278 echo "${ECHO_T}$with_hashed_db" >&6
    50575279 else
     
    50605282 
    50615283-echo "$as_me:5423: checking for list of fallback descriptions" >&5
    5062 +echo "$as_me:5710: checking for list of fallback descriptions" >&5
     5284+echo "$as_me:5719: checking for list of fallback descriptions" >&5
    50635285 echo $ECHO_N "checking for list of fallback descriptions... $ECHO_C" >&6
    50645286 
    50655287 # Check whether --with-fallbacks or --without-fallbacks was given.
    5066 @@ -5430,11 +5717,11 @@
     5288@@ -5430,11 +5726,11 @@
    50675289 else
    50685290   with_fallback=
    50695291 fi;
    50705292-echo "$as_me:5433: result: $with_fallback" >&5
    5071 +echo "$as_me:5720: result: $with_fallback" >&5
     5293+echo "$as_me:5729: result: $with_fallback" >&5
    50725294 echo "${ECHO_T}$with_fallback" >&6
    50735295 FALLBACK_LIST=`echo "$with_fallback" | sed -e 's/,/ /g'`
    50745296 
    50755297-echo "$as_me:5437: checking if you want modern xterm or antique" >&5
    5076 +echo "$as_me:5724: checking if you want modern xterm or antique" >&5
     5298+echo "$as_me:5733: checking if you want modern xterm or antique" >&5
    50775299 echo $ECHO_N "checking if you want modern xterm or antique... $ECHO_C" >&6
    50785300 
    50795301 # Check whether --with-xterm-new or --without-xterm-new was given.
    5080 @@ -5448,7 +5735,7 @@
     5302@@ -5448,7 +5744,7 @@
    50815303 no)    with_xterm_new=xterm-old;;
    50825304 *)     with_xterm_new=xterm-new;;
    50835305 esac
    50845306-echo "$as_me:5451: result: $with_xterm_new" >&5
    5085 +echo "$as_me:5738: result: $with_xterm_new" >&5
     5307+echo "$as_me:5747: result: $with_xterm_new" >&5
    50865308 echo "${ECHO_T}$with_xterm_new" >&6
    50875309 WHICH_XTERM=$with_xterm_new
    50885310 
    5089 @@ -5458,7 +5745,7 @@
     5311@@ -5458,7 +5754,7 @@
    50905312        MAKE_TERMINFO="#"
    50915313 else
    50925314 
    50935315-echo "$as_me:5461: checking for list of terminfo directories" >&5
    5094 +echo "$as_me:5748: checking for list of terminfo directories" >&5
     5316+echo "$as_me:5757: checking for list of terminfo directories" >&5
    50955317 echo $ECHO_N "checking for list of terminfo directories... $ECHO_C" >&6
    50965318 
    50975319 # Check whether --with-terminfo-dirs or --without-terminfo-dirs was given.
    5098 @@ -5468,7 +5755,7 @@
     5320@@ -5468,7 +5764,7 @@
    50995321 else
    51005322   withval=${TERMINFO_DIRS-${datadir}/terminfo}
     
    51055327 for cf_src_path in $withval
    51065328 do
    5107 @@ -5498,7 +5785,7 @@
     5329@@ -5498,7 +5794,7 @@
    51085330   cf_src_path=`echo $cf_src_path | sed -e s%NONE%$cf_path_syntax%`
    51095331   ;;
    51105332 *)
    51115333-  { { echo "$as_me:5501: error: expected a pathname, not \"$cf_src_path\"" >&5
    5112 +  { { echo "$as_me:5788: error: expected a pathname, not \"$cf_src_path\"" >&5
     5334+  { { echo "$as_me:5797: error: expected a pathname, not \"$cf_src_path\"" >&5
    51135335 echo "$as_me: error: expected a pathname, not \"$cf_src_path\"" >&2;}
    51145336    { (exit 1); exit 1; }; }
    51155337   ;;
    5116 @@ -5511,13 +5798,13 @@
     5338@@ -5511,13 +5807,13 @@
    51175339 
    51185340 eval 'TERMINFO_DIRS="$cf_dst_path"'
    51195341 
    51205342-echo "$as_me:5514: result: $TERMINFO_DIRS" >&5
    5121 +echo "$as_me:5801: result: $TERMINFO_DIRS" >&5
     5343+echo "$as_me:5810: result: $TERMINFO_DIRS" >&5
    51225344 echo "${ECHO_T}$TERMINFO_DIRS" >&6
    51235345 test -n "$TERMINFO_DIRS" && cat >>confdefs.h <<EOF
     
    51265348 
    51275349-echo "$as_me:5520: checking for default terminfo directory" >&5
    5128 +echo "$as_me:5807: checking for default terminfo directory" >&5
     5350+echo "$as_me:5816: checking for default terminfo directory" >&5
    51295351 echo $ECHO_N "checking for default terminfo directory... $ECHO_C" >&6
    51305352 
    51315353 # Check whether --with-default-terminfo-dir or --without-default-terminfo-dir was given.
    5132 @@ -5553,7 +5840,7 @@
     5354@@ -5553,7 +5849,7 @@
    51335355   withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
    51345356   ;;
    51355357 *)
    51365358-  { { echo "$as_me:5556: error: expected a pathname, not \"$withval\"" >&5
    5137 +  { { echo "$as_me:5843: error: expected a pathname, not \"$withval\"" >&5
     5359+  { { echo "$as_me:5852: error: expected a pathname, not \"$withval\"" >&5
    51385360 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
    51395361    { (exit 1); exit 1; }; }
    51405362   ;;
    5141 @@ -5562,7 +5849,7 @@
     5363@@ -5562,7 +5858,7 @@
    51425364 fi
    51435365 TERMINFO="$withval"
    51445366 
    51455367-echo "$as_me:5565: result: $TERMINFO" >&5
    5146 +echo "$as_me:5852: result: $TERMINFO" >&5
     5368+echo "$as_me:5861: result: $TERMINFO" >&5
    51475369 echo "${ECHO_T}$TERMINFO" >&6
    51485370 cat >>confdefs.h <<EOF
    51495371 #define TERMINFO "$TERMINFO"
    5150 @@ -5572,7 +5859,7 @@
     5372@@ -5572,7 +5868,7 @@
    51515373 
    51525374 ###    use option --disable-big-core to make tic run on small machines
    51535375 ###    We need 4Mb, check if we can allocate 50% more than that.
    51545376-echo "$as_me:5575: checking if big-core option selected" >&5
    5155 +echo "$as_me:5862: checking if big-core option selected" >&5
     5377+echo "$as_me:5871: checking if big-core option selected" >&5
    51565378 echo $ECHO_N "checking if big-core option selected... $ECHO_C" >&6
    51575379 
    51585380 # Check whether --enable-big-core or --disable-big-core was given.
    5159 @@ -5584,7 +5871,7 @@
     5381@@ -5584,7 +5880,7 @@
    51605382   with_big_core=no
    51615383 else
    51625384   cat >conftest.$ac_ext <<_ACEOF
    51635385-#line 5587 "configure"
    5164 +#line 5874 "configure"
     5386+#line 5883 "configure"
    51655387 #include "confdefs.h"
    51665388 
    51675389 #include <stdlib.h>
    5168 @@ -5598,15 +5885,15 @@
     5390@@ -5598,15 +5894,15 @@
    51695391 }
    51705392 _ACEOF
    51715393 rm -f conftest$ac_exeext
    51725394-if { (eval echo "$as_me:5601: \"$ac_link\"") >&5
    5173 +if { (eval echo "$as_me:5888: \"$ac_link\"") >&5
     5395+if { (eval echo "$as_me:5897: \"$ac_link\"") >&5
    51745396   (eval $ac_link) 2>&5
    51755397   ac_status=$?
    51765398-  echo "$as_me:5604: \$? = $ac_status" >&5
    5177 +  echo "$as_me:5891: \$? = $ac_status" >&5
     5399+  echo "$as_me:5900: \$? = $ac_status" >&5
    51785400   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    51795401-  { (eval echo "$as_me:5606: \"$ac_try\"") >&5
    5180 +  { (eval echo "$as_me:5893: \"$ac_try\"") >&5
     5402+  { (eval echo "$as_me:5902: \"$ac_try\"") >&5
    51815403   (eval $ac_try) 2>&5
    51825404   ac_status=$?
    51835405-  echo "$as_me:5609: \$? = $ac_status" >&5
    5184 +  echo "$as_me:5896: \$? = $ac_status" >&5
     5406+  echo "$as_me:5905: \$? = $ac_status" >&5
    51855407   (exit $ac_status); }; }; then
    51865408   with_big_core=yes
    51875409 else
    5188 @@ -5618,7 +5905,7 @@
     5410@@ -5618,7 +5914,7 @@
    51895411 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
    51905412 fi
    51915413 fi;
    51925414-echo "$as_me:5621: result: $with_big_core" >&5
    5193 +echo "$as_me:5908: result: $with_big_core" >&5
     5415+echo "$as_me:5917: result: $with_big_core" >&5
    51945416 echo "${ECHO_T}$with_big_core" >&6
    51955417 test "$with_big_core" = "yes" && cat >>confdefs.h <<\EOF
    51965418 #define HAVE_BIG_CORE 1
    5197 @@ -5627,7 +5914,7 @@
     5419@@ -5627,7 +5923,7 @@
    51985420 ### ISO C only guarantees 512-char strings, we have tables which load faster
    51995421 ### when constructed using "big" strings.  More than the C compiler, the awk
    52005422 ### program is a limit on most vendor UNIX systems.  Check that we can build.
    52015423-echo "$as_me:5630: checking if big-strings option selected" >&5
    5202 +echo "$as_me:5917: checking if big-strings option selected" >&5
     5424+echo "$as_me:5926: checking if big-strings option selected" >&5
    52035425 echo $ECHO_N "checking if big-strings option selected... $ECHO_C" >&6
    52045426 
    52055427 # Check whether --enable-big-strings or --disable-big-strings was given.
    5206 @@ -5636,29 +5923,29 @@
     5428@@ -5636,29 +5932,29 @@
    52075429   with_big_strings=$enableval
    52085430 else
     
    52375459 fi;
    52385460-echo "$as_me:5654: result: $with_big_strings" >&5
    5239 +echo "$as_me:5941: result: $with_big_strings" >&5
     5461+echo "$as_me:5950: result: $with_big_strings" >&5
    52405462 echo "${ECHO_T}$with_big_strings" >&6
    52415463 
     
    52455467 ###    use option --enable-termcap to compile in the termcap fallback support
    52465468-echo "$as_me:5661: checking if you want termcap-fallback support" >&5
    5247 +echo "$as_me:5948: checking if you want termcap-fallback support" >&5
     5469+echo "$as_me:5957: checking if you want termcap-fallback support" >&5
    52485470 echo $ECHO_N "checking if you want termcap-fallback support... $ECHO_C" >&6
    52495471 
    52505472 # Check whether --enable-termcap or --disable-termcap was given.
    5251 @@ -5668,13 +5955,13 @@
     5473@@ -5668,13 +5964,13 @@
    52525474 else
    52535475   with_termcap=no
    52545476 fi;
    52555477-echo "$as_me:5671: result: $with_termcap" >&5
    5256 +echo "$as_me:5958: result: $with_termcap" >&5
     5478+echo "$as_me:5967: result: $with_termcap" >&5
    52575479 echo "${ECHO_T}$with_termcap" >&6
    52585480 
     
    52615483                if test -z "$with_fallback" ; then
    52625484-                       { { echo "$as_me:5677: error: You have disabled the database w/o specifying fallbacks" >&5
    5263 +                       { { echo "$as_me:5964: error: You have disabled the database w/o specifying fallbacks" >&5
     5485+                       { { echo "$as_me:5973: error: You have disabled the database w/o specifying fallbacks" >&5
    52645486 echo "$as_me: error: You have disabled the database w/o specifying fallbacks" >&2;}
    52655487    { (exit 1); exit 1; }; }
    52665488                fi
    5267 @@ -5686,7 +5973,7 @@
     5489@@ -5686,7 +5982,7 @@
    52685490 else
    52695491 
    52705492 if test "$with_ticlib" != no ; then
    52715493-       { { echo "$as_me:5689: error: Options --with-ticlib and --enable-termcap cannot be combined" >&5
    5272 +       { { echo "$as_me:5976: error: Options --with-ticlib and --enable-termcap cannot be combined" >&5
     5494+       { { echo "$as_me:5985: error: Options --with-ticlib and --enable-termcap cannot be combined" >&5
    52735495 echo "$as_me: error: Options --with-ticlib and --enable-termcap cannot be combined" >&2;}
    52745496    { (exit 1); exit 1; }; }
    52755497 fi
    5276 @@ -5695,7 +5982,7 @@
     5498@@ -5695,7 +5991,7 @@
    52775499 #define USE_TERMCAP 1
    52785500 EOF
    52795501 
    52805502-echo "$as_me:5698: checking for list of termcap files" >&5
    5281 +echo "$as_me:5985: checking for list of termcap files" >&5
     5503+echo "$as_me:5994: checking for list of termcap files" >&5
    52825504 echo $ECHO_N "checking for list of termcap files... $ECHO_C" >&6
    52835505 
    52845506 # Check whether --with-termpath or --without-termpath was given.
    5285 @@ -5705,7 +5992,7 @@
     5507@@ -5705,7 +6001,7 @@
    52865508 else
    52875509   withval=${TERMPATH-/etc/termcap:/usr/share/misc/termcap}
     
    52925514 for cf_src_path in $withval
    52935515 do
    5294 @@ -5735,7 +6022,7 @@
     5516@@ -5735,7 +6031,7 @@
    52955517   cf_src_path=`echo $cf_src_path | sed -e s%NONE%$cf_path_syntax%`
    52965518   ;;
    52975519 *)
    52985520-  { { echo "$as_me:5738: error: expected a pathname, not \"$cf_src_path\"" >&5
    5299 +  { { echo "$as_me:6025: error: expected a pathname, not \"$cf_src_path\"" >&5
     5521+  { { echo "$as_me:6034: error: expected a pathname, not \"$cf_src_path\"" >&5
    53005522 echo "$as_me: error: expected a pathname, not \"$cf_src_path\"" >&2;}
    53015523    { (exit 1); exit 1; }; }
    53025524   ;;
    5303 @@ -5748,14 +6035,14 @@
     5525@@ -5748,14 +6044,14 @@
    53045526 
    53055527 eval 'TERMPATH="$cf_dst_path"'
    53065528 
    53075529-echo "$as_me:5751: result: $TERMPATH" >&5
    5308 +echo "$as_me:6038: result: $TERMPATH" >&5
     5530+echo "$as_me:6047: result: $TERMPATH" >&5
    53095531 echo "${ECHO_T}$TERMPATH" >&6
    53105532 test -n "$TERMPATH" && cat >>confdefs.h <<EOF
     
    53145536 ###    use option --enable-getcap to use a hacked getcap for reading termcaps
    53155537-echo "$as_me:5758: checking if fast termcap-loader is needed" >&5
    5316 +echo "$as_me:6045: checking if fast termcap-loader is needed" >&5
     5538+echo "$as_me:6054: checking if fast termcap-loader is needed" >&5
    53175539 echo $ECHO_N "checking if fast termcap-loader is needed... $ECHO_C" >&6
    53185540 
    53195541 # Check whether --enable-getcap or --disable-getcap was given.
    5320 @@ -5765,13 +6052,13 @@
     5542@@ -5765,13 +6061,13 @@
    53215543 else
    53225544   with_getcap=no
    53235545 fi;
    53245546-echo "$as_me:5768: result: $with_getcap" >&5
    5325 +echo "$as_me:6055: result: $with_getcap" >&5
     5547+echo "$as_me:6064: result: $with_getcap" >&5
    53265548 echo "${ECHO_T}$with_getcap" >&6
    53275549 test "$with_getcap" = "yes" && cat >>confdefs.h <<\EOF
     
    53305552 
    53315553-echo "$as_me:5774: checking if translated termcaps will be cached in ~/.terminfo" >&5
    5332 +echo "$as_me:6061: checking if translated termcaps will be cached in ~/.terminfo" >&5
     5554+echo "$as_me:6070: checking if translated termcaps will be cached in ~/.terminfo" >&5
    53335555 echo $ECHO_N "checking if translated termcaps will be cached in ~/.terminfo... $ECHO_C" >&6
    53345556 
    53355557 # Check whether --enable-getcap-cache or --disable-getcap-cache was given.
    5336 @@ -5781,7 +6068,7 @@
     5558@@ -5781,7 +6077,7 @@
    53375559 else
    53385560   with_getcap_cache=no
    53395561 fi;
    53405562-echo "$as_me:5784: result: $with_getcap_cache" >&5
    5341 +echo "$as_me:6071: result: $with_getcap_cache" >&5
     5563+echo "$as_me:6080: result: $with_getcap_cache" >&5
    53425564 echo "${ECHO_T}$with_getcap_cache" >&6
    53435565 test "$with_getcap_cache" = "yes" && cat >>confdefs.h <<\EOF
    53445566 #define USE_GETCAP_CACHE 1
    5345 @@ -5790,7 +6077,7 @@
     5567@@ -5790,7 +6086,7 @@
    53465568 fi
    53475569 
    53485570 ###   Use option --disable-home-terminfo to completely remove ~/.terminfo
    53495571-echo "$as_me:5793: checking if ~/.terminfo is wanted" >&5
    5350 +echo "$as_me:6080: checking if ~/.terminfo is wanted" >&5
     5572+echo "$as_me:6089: checking if ~/.terminfo is wanted" >&5
    53515573 echo $ECHO_N "checking if ~/.terminfo is wanted... $ECHO_C" >&6
    53525574 
    53535575 # Check whether --enable-home-terminfo or --disable-home-terminfo was given.
    5354 @@ -5800,13 +6087,13 @@
     5576@@ -5800,13 +6096,13 @@
    53555577 else
    53565578   with_home_terminfo=yes
    53575579 fi;
    53585580-echo "$as_me:5803: result: $with_home_terminfo" >&5
    5359 +echo "$as_me:6090: result: $with_home_terminfo" >&5
     5581+echo "$as_me:6099: result: $with_home_terminfo" >&5
    53605582 echo "${ECHO_T}$with_home_terminfo" >&6
    53615583 test "$with_home_terminfo" = "yes" && cat >>confdefs.h <<\EOF
     
    53645586 
    53655587-echo "$as_me:5809: checking if you want to use restricted environment when running as root" >&5
    5366 +echo "$as_me:6096: checking if you want to use restricted environment when running as root" >&5
     5588+echo "$as_me:6105: checking if you want to use restricted environment when running as root" >&5
    53675589 echo $ECHO_N "checking if you want to use restricted environment when running as root... $ECHO_C" >&6
    53685590 
    53695591 # Check whether --enable-root-environ or --disable-root-environ was given.
    5370 @@ -5816,7 +6103,7 @@
     5592@@ -5816,7 +6112,7 @@
    53715593 else
    53725594   with_root_environ=yes
    53735595 fi;
    53745596-echo "$as_me:5819: result: $with_root_environ" >&5
    5375 +echo "$as_me:6106: result: $with_root_environ" >&5
     5597+echo "$as_me:6115: result: $with_root_environ" >&5
    53765598 echo "${ECHO_T}$with_root_environ" >&6
    53775599 test "$with_root_environ" = yes && cat >>confdefs.h <<\EOF
    53785600 #define USE_ROOT_ENVIRON 1
    5379 @@ -5830,13 +6117,13 @@
     5601@@ -5830,13 +6126,13 @@
    53805602        unlink
    53815603 do
    53825604 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
    53835605-echo "$as_me:5833: checking for $ac_func" >&5
    5384 +echo "$as_me:6120: checking for $ac_func" >&5
     5606+echo "$as_me:6129: checking for $ac_func" >&5
    53855607 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
    53865608 if eval "test \"\${$as_ac_var+set}\" = set"; then
     
    53895611   cat >conftest.$ac_ext <<_ACEOF
    53905612-#line 5839 "configure"
    5391 +#line 6126 "configure"
     5613+#line 6135 "configure"
    53925614 #include "confdefs.h"
    53935615 /* System header to define __stub macros and hopefully few prototypes,
    53945616     which can conflict with char $ac_func (); below.  */
    5395 @@ -5867,16 +6154,16 @@
     5617@@ -5867,16 +6163,16 @@
    53965618 }
    53975619 _ACEOF
    53985620 rm -f conftest.$ac_objext conftest$ac_exeext
    53995621-if { (eval echo "$as_me:5870: \"$ac_link\"") >&5
    5400 +if { (eval echo "$as_me:6157: \"$ac_link\"") >&5
     5622+if { (eval echo "$as_me:6166: \"$ac_link\"") >&5
    54015623   (eval $ac_link) 2>&5
    54025624   ac_status=$?
    54035625-  echo "$as_me:5873: \$? = $ac_status" >&5
    5404 +  echo "$as_me:6160: \$? = $ac_status" >&5
     5626+  echo "$as_me:6169: \$? = $ac_status" >&5
    54055627   (exit $ac_status); } &&
    54065628          { ac_try='test -s conftest$ac_exeext'
    54075629-  { (eval echo "$as_me:5876: \"$ac_try\"") >&5
    5408 +  { (eval echo "$as_me:6163: \"$ac_try\"") >&5
     5630+  { (eval echo "$as_me:6172: \"$ac_try\"") >&5
    54095631   (eval $ac_try) 2>&5
    54105632   ac_status=$?
    54115633-  echo "$as_me:5879: \$? = $ac_status" >&5
    5412 +  echo "$as_me:6166: \$? = $ac_status" >&5
     5634+  echo "$as_me:6175: \$? = $ac_status" >&5
    54135635   (exit $ac_status); }; }; then
    54145636   eval "$as_ac_var=yes"
    54155637 else
    5416 @@ -5886,7 +6173,7 @@
     5638@@ -5886,7 +6182,7 @@
    54175639 fi
    54185640 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    54195641 fi
    54205642-echo "$as_me:5889: result: `eval echo '${'$as_ac_var'}'`" >&5
    5421 +echo "$as_me:6176: result: `eval echo '${'$as_ac_var'}'`" >&5
     5643+echo "$as_me:6185: result: `eval echo '${'$as_ac_var'}'`" >&5
    54225644 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
    54235645 if test `eval echo '${'$as_ac_var'}'` = yes; then
    54245646   cat >>confdefs.h <<EOF
    5425 @@ -5903,13 +6190,13 @@
     5647@@ -5903,13 +6199,13 @@
    54265648                symlink
    54275649 do
    54285650 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
    54295651-echo "$as_me:5906: checking for $ac_func" >&5
    5430 +echo "$as_me:6193: checking for $ac_func" >&5
     5652+echo "$as_me:6202: checking for $ac_func" >&5
    54315653 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
    54325654 if eval "test \"\${$as_ac_var+set}\" = set"; then
     
    54355657   cat >conftest.$ac_ext <<_ACEOF
    54365658-#line 5912 "configure"
    5437 +#line 6199 "configure"
     5659+#line 6208 "configure"
    54385660 #include "confdefs.h"
    54395661 /* System header to define __stub macros and hopefully few prototypes,
    54405662     which can conflict with char $ac_func (); below.  */
    5441 @@ -5940,16 +6227,16 @@
     5663@@ -5940,16 +6236,16 @@
    54425664 }
    54435665 _ACEOF
    54445666 rm -f conftest.$ac_objext conftest$ac_exeext
    54455667-if { (eval echo "$as_me:5943: \"$ac_link\"") >&5
    5446 +if { (eval echo "$as_me:6230: \"$ac_link\"") >&5
     5668+if { (eval echo "$as_me:6239: \"$ac_link\"") >&5
    54475669   (eval $ac_link) 2>&5
    54485670   ac_status=$?
    54495671-  echo "$as_me:5946: \$? = $ac_status" >&5
    5450 +  echo "$as_me:6233: \$? = $ac_status" >&5
     5672+  echo "$as_me:6242: \$? = $ac_status" >&5
    54515673   (exit $ac_status); } &&
    54525674          { ac_try='test -s conftest$ac_exeext'
    54535675-  { (eval echo "$as_me:5949: \"$ac_try\"") >&5
    5454 +  { (eval echo "$as_me:6236: \"$ac_try\"") >&5
     5676+  { (eval echo "$as_me:6245: \"$ac_try\"") >&5
    54555677   (eval $ac_try) 2>&5
    54565678   ac_status=$?
    54575679-  echo "$as_me:5952: \$? = $ac_status" >&5
    5458 +  echo "$as_me:6239: \$? = $ac_status" >&5
     5680+  echo "$as_me:6248: \$? = $ac_status" >&5
    54595681   (exit $ac_status); }; }; then
    54605682   eval "$as_ac_var=yes"
    54615683 else
    5462 @@ -5959,7 +6246,7 @@
     5684@@ -5959,7 +6255,7 @@
    54635685 fi
    54645686 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    54655687 fi
    54665688-echo "$as_me:5962: result: `eval echo '${'$as_ac_var'}'`" >&5
    5467 +echo "$as_me:6249: result: `eval echo '${'$as_ac_var'}'`" >&5
     5689+echo "$as_me:6258: result: `eval echo '${'$as_ac_var'}'`" >&5
    54685690 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
    54695691 if test `eval echo '${'$as_ac_var'}'` = yes; then
    54705692   cat >>confdefs.h <<EOF
    5471 @@ -5970,7 +6257,7 @@
     5693@@ -5970,7 +6266,7 @@
    54725694 done
    54735695 
    54745696 else
    54755697-       echo "$as_me:5973: checking if link/symlink functions work" >&5
    5476 +       echo "$as_me:6260: checking if link/symlink functions work" >&5
     5698+       echo "$as_me:6269: checking if link/symlink functions work" >&5
    54775699 echo $ECHO_N "checking if link/symlink functions work... $ECHO_C" >&6
    54785700 if test "${cf_cv_link_funcs+set}" = set; then
    54795701   echo $ECHO_N "(cached) $ECHO_C" >&6
    5480 @@ -5983,7 +6270,7 @@
     5702@@ -5983,7 +6279,7 @@
    54815703                        eval 'ac_cv_func_'$cf_func'=error'
    54825704 else
    54835705   cat >conftest.$ac_ext <<_ACEOF
    54845706-#line 5986 "configure"
    5485 +#line 6273 "configure"
     5707+#line 6282 "configure"
    54865708 #include "confdefs.h"
    54875709 
    54885710 #include <sys/types.h>
    5489 @@ -6013,15 +6300,15 @@
     5711@@ -6013,15 +6309,15 @@
    54905712 
    54915713 _ACEOF
    54925714 rm -f conftest$ac_exeext
    54935715-if { (eval echo "$as_me:6016: \"$ac_link\"") >&5
    5494 +if { (eval echo "$as_me:6303: \"$ac_link\"") >&5
     5716+if { (eval echo "$as_me:6312: \"$ac_link\"") >&5
    54955717   (eval $ac_link) 2>&5
    54965718   ac_status=$?
    54975719-  echo "$as_me:6019: \$? = $ac_status" >&5
    5498 +  echo "$as_me:6306: \$? = $ac_status" >&5
     5720+  echo "$as_me:6315: \$? = $ac_status" >&5
    54995721   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    55005722-  { (eval echo "$as_me:6021: \"$ac_try\"") >&5
    5501 +  { (eval echo "$as_me:6308: \"$ac_try\"") >&5
     5723+  { (eval echo "$as_me:6317: \"$ac_try\"") >&5
    55025724   (eval $ac_try) 2>&5
    55035725   ac_status=$?
    55045726-  echo "$as_me:6024: \$? = $ac_status" >&5
    5505 +  echo "$as_me:6311: \$? = $ac_status" >&5
     5727+  echo "$as_me:6320: \$? = $ac_status" >&5
    55065728   (exit $ac_status); }; }; then
    55075729 
    55085730                        cf_cv_link_funcs="$cf_cv_link_funcs $cf_func"
    5509 @@ -6039,7 +6326,7 @@
     5731@@ -6039,7 +6335,7 @@
    55105732                test -z "$cf_cv_link_funcs" && cf_cv_link_funcs=no
    55115733 
    55125734 fi
    55135735-echo "$as_me:6042: result: $cf_cv_link_funcs" >&5
    5514 +echo "$as_me:6329: result: $cf_cv_link_funcs" >&5
     5736+echo "$as_me:6338: result: $cf_cv_link_funcs" >&5
    55155737 echo "${ECHO_T}$cf_cv_link_funcs" >&6
    55165738        test "$ac_cv_func_link"    = yes && cat >>confdefs.h <<\EOF
    55175739 #define HAVE_LINK 1
    5518 @@ -6057,7 +6344,7 @@
     5740@@ -6057,7 +6353,7 @@
    55195741 # soft links (symbolic links) are useful for some systems where hard links do
    55205742 # not work, or to make it simpler to copy terminfo trees around.
    55215743 if test "$ac_cv_func_symlink" = yes ; then
    55225744-    echo "$as_me:6060: checking if tic should use symbolic links" >&5
    5523 +    echo "$as_me:6347: checking if tic should use symbolic links" >&5
     5745+    echo "$as_me:6356: checking if tic should use symbolic links" >&5
    55245746 echo $ECHO_N "checking if tic should use symbolic links... $ECHO_C" >&6
    55255747 
    55265748 # Check whether --enable-symlinks or --disable-symlinks was given.
    5527 @@ -6067,21 +6354,21 @@
     5749@@ -6067,21 +6363,21 @@
    55285750 else
    55295751   with_symlinks=no
    55305752 fi;
    55315753-    echo "$as_me:6070: result: $with_symlinks" >&5
    5532 +    echo "$as_me:6357: result: $with_symlinks" >&5
     5754+    echo "$as_me:6366: result: $with_symlinks" >&5
    55335755 echo "${ECHO_T}$with_symlinks" >&6
    55345756 fi
     
    55385760 if test "$with_symlinks" = no ; then
    55395761-    echo "$as_me:6077: checking if tic should use hard links" >&5
    5540 +    echo "$as_me:6364: checking if tic should use hard links" >&5
     5762+    echo "$as_me:6373: checking if tic should use hard links" >&5
    55415763 echo $ECHO_N "checking if tic should use hard links... $ECHO_C" >&6
    55425764     if test "$ac_cv_func_link" = yes ; then
     
    55465768     fi
    55475769-    echo "$as_me:6084: result: $with_links" >&5
    5548 +    echo "$as_me:6371: result: $with_links" >&5
     5770+    echo "$as_me:6380: result: $with_links" >&5
    55495771 echo "${ECHO_T}$with_links" >&6
    55505772 fi
    55515773 
    5552 @@ -6094,7 +6381,7 @@
     5774@@ -6094,7 +6390,7 @@
    55535775 EOF
    55545776 
    55555777 ###   use option --enable-broken-linker to force on use of broken-linker support
    55565778-echo "$as_me:6097: checking if you want broken-linker support code" >&5
    5557 +echo "$as_me:6384: checking if you want broken-linker support code" >&5
     5779+echo "$as_me:6393: checking if you want broken-linker support code" >&5
    55585780 echo $ECHO_N "checking if you want broken-linker support code... $ECHO_C" >&6
    55595781 
    55605782 # Check whether --enable-broken_linker or --disable-broken_linker was given.
    5561 @@ -6104,7 +6391,7 @@
     5783@@ -6104,7 +6400,7 @@
    55625784 else
    55635785   with_broken_linker=${BROKEN_LINKER-no}
    55645786 fi;
    55655787-echo "$as_me:6107: result: $with_broken_linker" >&5
    5566 +echo "$as_me:6394: result: $with_broken_linker" >&5
     5788+echo "$as_me:6403: result: $with_broken_linker" >&5
    55675789 echo "${ECHO_T}$with_broken_linker" >&6
    55685790 
    55695791 BROKEN_LINKER=0
    5570 @@ -6124,14 +6411,14 @@
     5792@@ -6124,14 +6420,14 @@
    55715793                BROKEN_LINKER=1
    55725794                test -n "$verbose" && echo "    cygwin linker is broken anyway" 1>&6
    55735795 
    55745796-echo "${as_me-configure}:6127: testing cygwin linker is broken anyway ..." 1>&5
    5575 +echo "${as_me-configure}:6414: testing cygwin linker is broken anyway ..." 1>&5
     5797+echo "${as_me-configure}:6423: testing cygwin linker is broken anyway ..." 1>&5
    55765798 
    55775799                ;;
     
    55815803 ###   use option --enable-bsdpad to have tputs process BSD-style prefix padding
    55825804-echo "$as_me:6134: checking if tputs should process BSD-style prefix padding" >&5
    5583 +echo "$as_me:6421: checking if tputs should process BSD-style prefix padding" >&5
     5805+echo "$as_me:6430: checking if tputs should process BSD-style prefix padding" >&5
    55845806 echo $ECHO_N "checking if tputs should process BSD-style prefix padding... $ECHO_C" >&6
    55855807 
    55865808 # Check whether --enable-bsdpad or --disable-bsdpad was given.
    5587 @@ -6141,7 +6428,7 @@
     5809@@ -6141,7 +6437,7 @@
    55885810 else
    55895811   with_bsdpad=no
    55905812 fi;
    55915813-echo "$as_me:6144: result: $with_bsdpad" >&5
    5592 +echo "$as_me:6431: result: $with_bsdpad" >&5
     5814+echo "$as_me:6440: result: $with_bsdpad" >&5
    55935815 echo "${ECHO_T}$with_bsdpad" >&6
    55945816 test "$with_bsdpad" = yes && cat >>confdefs.h <<\EOF
    55955817 #define BSD_TPUTS 1
    5596 @@ -6158,7 +6445,7 @@
     5818@@ -6158,7 +6454,7 @@
    55975819 
    55985820 # Check to define _XOPEN_SOURCE "automatically"
    55995821 
    56005822-echo "$as_me:6161: checking if $CC -U and -D options work together" >&5
    5601 +echo "$as_me:6448: checking if $CC -U and -D options work together" >&5
     5823+echo "$as_me:6457: checking if $CC -U and -D options work together" >&5
    56025824 echo $ECHO_N "checking if $CC -U and -D options work together... $ECHO_C" >&6
    56035825 if test "${cf_cv_cc_u_d_options+set}" = set; then
    56045826   echo $ECHO_N "(cached) $ECHO_C" >&6
    5605 @@ -6167,7 +6454,7 @@
     5827@@ -6167,7 +6463,7 @@
    56065828        cf_save_CPPFLAGS="$CPPFLAGS"
    56075829        CPPFLAGS="-UU_D_OPTIONS -DU_D_OPTIONS -DD_U_OPTIONS -UD_U_OPTIONS"
    56085830        cat >conftest.$ac_ext <<_ACEOF
    56095831-#line 6170 "configure"
    5610 +#line 6457 "configure"
     5832+#line 6466 "configure"
    56115833 #include "confdefs.h"
    56125834 
    56135835 int
    5614 @@ -6186,16 +6473,16 @@
     5836@@ -6186,16 +6482,16 @@
    56155837 }
    56165838 _ACEOF
    56175839 rm -f conftest.$ac_objext
    56185840-if { (eval echo "$as_me:6189: \"$ac_compile\"") >&5
    5619 +if { (eval echo "$as_me:6476: \"$ac_compile\"") >&5
     5841+if { (eval echo "$as_me:6485: \"$ac_compile\"") >&5
    56205842   (eval $ac_compile) 2>&5
    56215843   ac_status=$?
    56225844-  echo "$as_me:6192: \$? = $ac_status" >&5
    5623 +  echo "$as_me:6479: \$? = $ac_status" >&5
     5845+  echo "$as_me:6488: \$? = $ac_status" >&5
    56245846   (exit $ac_status); } &&
    56255847          { ac_try='test -s conftest.$ac_objext'
    56265848-  { (eval echo "$as_me:6195: \"$ac_try\"") >&5
    5627 +  { (eval echo "$as_me:6482: \"$ac_try\"") >&5
     5849+  { (eval echo "$as_me:6491: \"$ac_try\"") >&5
    56285850   (eval $ac_try) 2>&5
    56295851   ac_status=$?
    56305852-  echo "$as_me:6198: \$? = $ac_status" >&5
    5631 +  echo "$as_me:6485: \$? = $ac_status" >&5
     5853+  echo "$as_me:6494: \$? = $ac_status" >&5
    56325854   (exit $ac_status); }; }; then
    56335855 
    56345856        cf_cv_cc_u_d_options=yes
    5635 @@ -6209,14 +6496,14 @@
     5857@@ -6209,14 +6505,14 @@
    56365858        CPPFLAGS="$cf_save_CPPFLAGS"
    56375859 
    56385860 fi
    56395861-echo "$as_me:6212: result: $cf_cv_cc_u_d_options" >&5
    5640 +echo "$as_me:6499: result: $cf_cv_cc_u_d_options" >&5
     5862+echo "$as_me:6508: result: $cf_cv_cc_u_d_options" >&5
    56415863 echo "${ECHO_T}$cf_cv_cc_u_d_options" >&6
    56425864 
     
    56505872        ;;
    56515873 freebsd*|dragonfly*) #(vi
    5652 @@ -6233,16 +6520,16 @@
     5874@@ -6233,16 +6529,16 @@
    56535875 irix[56].*) #(vi
    56545876        CPPFLAGS="$CPPFLAGS -D_SGI_SOURCE"
     
    56585880 
    56595881-echo "$as_me:6238: checking if we must define _GNU_SOURCE" >&5
    5660 +echo "$as_me:6525: checking if we must define _GNU_SOURCE" >&5
     5882+echo "$as_me:6534: checking if we must define _GNU_SOURCE" >&5
    56615883 echo $ECHO_N "checking if we must define _GNU_SOURCE... $ECHO_C" >&6
    56625884 if test "${cf_cv_gnu_source+set}" = set; then
     
    56665888 cat >conftest.$ac_ext <<_ACEOF
    56675889-#line 6245 "configure"
    5668 +#line 6532 "configure"
     5890+#line 6541 "configure"
    56695891 #include "confdefs.h"
    56705892 #include <sys/types.h>
    56715893 int
    5672 @@ -6257,16 +6544,16 @@
     5894@@ -6257,16 +6553,16 @@
    56735895 }
    56745896 _ACEOF
    56755897 rm -f conftest.$ac_objext
    56765898-if { (eval echo "$as_me:6260: \"$ac_compile\"") >&5
    5677 +if { (eval echo "$as_me:6547: \"$ac_compile\"") >&5
     5899+if { (eval echo "$as_me:6556: \"$ac_compile\"") >&5
    56785900   (eval $ac_compile) 2>&5
    56795901   ac_status=$?
    56805902-  echo "$as_me:6263: \$? = $ac_status" >&5
    5681 +  echo "$as_me:6550: \$? = $ac_status" >&5
     5903+  echo "$as_me:6559: \$? = $ac_status" >&5
    56825904   (exit $ac_status); } &&
    56835905          { ac_try='test -s conftest.$ac_objext'
    56845906-  { (eval echo "$as_me:6266: \"$ac_try\"") >&5
    5685 +  { (eval echo "$as_me:6553: \"$ac_try\"") >&5
     5907+  { (eval echo "$as_me:6562: \"$ac_try\"") >&5
    56865908   (eval $ac_try) 2>&5
    56875909   ac_status=$?
    56885910-  echo "$as_me:6269: \$? = $ac_status" >&5
    5689 +  echo "$as_me:6556: \$? = $ac_status" >&5
     5911+  echo "$as_me:6565: \$? = $ac_status" >&5
    56905912   (exit $ac_status); }; }; then
    56915913   cf_cv_gnu_source=no
    56925914 else
    5693 @@ -6275,7 +6562,7 @@
     5915@@ -6275,7 +6571,7 @@
    56945916 cf_save="$CPPFLAGS"
    56955917         CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
    56965918         cat >conftest.$ac_ext <<_ACEOF
    56975919-#line 6278 "configure"
    5698 +#line 6565 "configure"
     5920+#line 6574 "configure"
    56995921 #include "confdefs.h"
    57005922 #include <sys/types.h>
    57015923 int
    5702 @@ -6290,16 +6577,16 @@
     5924@@ -6290,16 +6586,16 @@
    57035925 }
    57045926 _ACEOF
    57055927 rm -f conftest.$ac_objext
    57065928-if { (eval echo "$as_me:6293: \"$ac_compile\"") >&5
    5707 +if { (eval echo "$as_me:6580: \"$ac_compile\"") >&5
     5929+if { (eval echo "$as_me:6589: \"$ac_compile\"") >&5
    57085930   (eval $ac_compile) 2>&5
    57095931   ac_status=$?
    57105932-  echo "$as_me:6296: \$? = $ac_status" >&5
    5711 +  echo "$as_me:6583: \$? = $ac_status" >&5
     5933+  echo "$as_me:6592: \$? = $ac_status" >&5
    57125934   (exit $ac_status); } &&
    57135935          { ac_try='test -s conftest.$ac_objext'
    57145936-  { (eval echo "$as_me:6299: \"$ac_try\"") >&5
    5715 +  { (eval echo "$as_me:6586: \"$ac_try\"") >&5
     5937+  { (eval echo "$as_me:6595: \"$ac_try\"") >&5
    57165938   (eval $ac_try) 2>&5
    57175939   ac_status=$?
    57185940-  echo "$as_me:6302: \$? = $ac_status" >&5
    5719 +  echo "$as_me:6589: \$? = $ac_status" >&5
     5941+  echo "$as_me:6598: \$? = $ac_status" >&5
    57205942   (exit $ac_status); }; }; then
    57215943   cf_cv_gnu_source=no
    57225944 else
    5723 @@ -6314,7 +6601,7 @@
     5945@@ -6314,7 +6610,7 @@
    57245946 rm -f conftest.$ac_objext conftest.$ac_ext
    57255947 
    57265948 fi
    57275949-echo "$as_me:6317: result: $cf_cv_gnu_source" >&5
    5728 +echo "$as_me:6604: result: $cf_cv_gnu_source" >&5
     5950+echo "$as_me:6613: result: $cf_cv_gnu_source" >&5
    57295951 echo "${ECHO_T}$cf_cv_gnu_source" >&6
    57305952 test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
    57315953 
    5732 @@ -6341,14 +6628,14 @@
     5954@@ -6341,14 +6637,14 @@
    57335955        CPPFLAGS="$CPPFLAGS -D__EXTENSIONS__"
    57345956        ;;
    57355957 *)
    57365958-       echo "$as_me:6344: checking if we should define _XOPEN_SOURCE" >&5
    5737 +       echo "$as_me:6631: checking if we should define _XOPEN_SOURCE" >&5
     5959+       echo "$as_me:6640: checking if we should define _XOPEN_SOURCE" >&5
    57385960 echo $ECHO_N "checking if we should define _XOPEN_SOURCE... $ECHO_C" >&6
    57395961 if test "${cf_cv_xopen_source+set}" = set; then
     
    57435965        cat >conftest.$ac_ext <<_ACEOF
    57445966-#line 6351 "configure"
    5745 +#line 6638 "configure"
     5967+#line 6647 "configure"
    57465968 #include "confdefs.h"
    57475969 #include <sys/types.h>
    57485970 int
    5749 @@ -6363,16 +6650,16 @@
     5971@@ -6363,16 +6659,16 @@
    57505972 }
    57515973 _ACEOF
    57525974 rm -f conftest.$ac_objext
    57535975-if { (eval echo "$as_me:6366: \"$ac_compile\"") >&5
    5754 +if { (eval echo "$as_me:6653: \"$ac_compile\"") >&5
     5976+if { (eval echo "$as_me:6662: \"$ac_compile\"") >&5
    57555977   (eval $ac_compile) 2>&5
    57565978   ac_status=$?
    57575979-  echo "$as_me:6369: \$? = $ac_status" >&5
    5758 +  echo "$as_me:6656: \$? = $ac_status" >&5
     5980+  echo "$as_me:6665: \$? = $ac_status" >&5
    57595981   (exit $ac_status); } &&
    57605982          { ac_try='test -s conftest.$ac_objext'
    57615983-  { (eval echo "$as_me:6372: \"$ac_try\"") >&5
    5762 +  { (eval echo "$as_me:6659: \"$ac_try\"") >&5
     5984+  { (eval echo "$as_me:6668: \"$ac_try\"") >&5
    57635985   (eval $ac_try) 2>&5
    57645986   ac_status=$?
    57655987-  echo "$as_me:6375: \$? = $ac_status" >&5
    5766 +  echo "$as_me:6662: \$? = $ac_status" >&5
     5988+  echo "$as_me:6671: \$? = $ac_status" >&5
    57675989   (exit $ac_status); }; }; then
    57685990   cf_cv_xopen_source=no
    57695991 else
    5770 @@ -6381,7 +6668,7 @@
     5992@@ -6381,7 +6677,7 @@
    57715993 cf_save="$CPPFLAGS"
    57725994         CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
    57735995         cat >conftest.$ac_ext <<_ACEOF
    57745996-#line 6384 "configure"
    5775 +#line 6671 "configure"
     5997+#line 6680 "configure"
    57765998 #include "confdefs.h"
    57775999 #include <sys/types.h>
    57786000 int
    5779 @@ -6396,16 +6683,16 @@
     6001@@ -6396,16 +6692,16 @@
    57806002 }
    57816003 _ACEOF
    57826004 rm -f conftest.$ac_objext
    57836005-if { (eval echo "$as_me:6399: \"$ac_compile\"") >&5
    5784 +if { (eval echo "$as_me:6686: \"$ac_compile\"") >&5
     6006+if { (eval echo "$as_me:6695: \"$ac_compile\"") >&5
    57856007   (eval $ac_compile) 2>&5
    57866008   ac_status=$?
    57876009-  echo "$as_me:6402: \$? = $ac_status" >&5
    5788 +  echo "$as_me:6689: \$? = $ac_status" >&5
     6010+  echo "$as_me:6698: \$? = $ac_status" >&5
    57896011   (exit $ac_status); } &&
    57906012          { ac_try='test -s conftest.$ac_objext'
    57916013-  { (eval echo "$as_me:6405: \"$ac_try\"") >&5
    5792 +  { (eval echo "$as_me:6692: \"$ac_try\"") >&5
     6014+  { (eval echo "$as_me:6701: \"$ac_try\"") >&5
    57936015   (eval $ac_try) 2>&5
    57946016   ac_status=$?
    57956017-  echo "$as_me:6408: \$? = $ac_status" >&5
    5796 +  echo "$as_me:6695: \$? = $ac_status" >&5
     6018+  echo "$as_me:6704: \$? = $ac_status" >&5
    57976019   (exit $ac_status); }; }; then
    57986020   cf_cv_xopen_source=no
    57996021 else
    5800 @@ -6420,7 +6707,7 @@
     6022@@ -6420,7 +6716,7 @@
    58016023 rm -f conftest.$ac_objext conftest.$ac_ext
    58026024 
    58036025 fi
    58046026-echo "$as_me:6423: result: $cf_cv_xopen_source" >&5
    5805 +echo "$as_me:6710: result: $cf_cv_xopen_source" >&5
     6027+echo "$as_me:6719: result: $cf_cv_xopen_source" >&5
    58066028 echo "${ECHO_T}$cf_cv_xopen_source" >&6
    58076029        if test "$cf_cv_xopen_source" != no ; then
    58086030 
    5809 @@ -6454,16 +6741,16 @@
     6031@@ -6454,16 +6750,16 @@
    58106032        sed     -e 's/-[UD]_POSIX_C_SOURCE\(=[^         ]*\)\?[         ]/ /g' \
    58116033                -e 's/-[UD]_POSIX_C_SOURCE\(=[^         ]*\)\?$//g'`
    58126034 
    58136035-echo "$as_me:6457: checking if we should define _POSIX_C_SOURCE" >&5
    5814 +echo "$as_me:6744: checking if we should define _POSIX_C_SOURCE" >&5
     6036+echo "$as_me:6753: checking if we should define _POSIX_C_SOURCE" >&5
    58156037 echo $ECHO_N "checking if we should define _POSIX_C_SOURCE... $ECHO_C" >&6
    58166038 if test "${cf_cv_posix_c_source+set}" = set; then
     
    58196041 
    58206042-echo "${as_me-configure}:6463: testing if the symbol is already defined go no further ..." 1>&5
    5821 +echo "${as_me-configure}:6750: testing if the symbol is already defined go no further ..." 1>&5
     6043+echo "${as_me-configure}:6759: testing if the symbol is already defined go no further ..." 1>&5
    58226044 
    58236045        cat >conftest.$ac_ext <<_ACEOF
    58246046-#line 6466 "configure"
    5825 +#line 6753 "configure"
     6047+#line 6762 "configure"
    58266048 #include "confdefs.h"
    58276049 #include <sys/types.h>
    58286050 int
    5829 @@ -6478,16 +6765,16 @@
     6051@@ -6478,16 +6774,16 @@
    58306052 }
    58316053 _ACEOF
    58326054 rm -f conftest.$ac_objext
    58336055-if { (eval echo "$as_me:6481: \"$ac_compile\"") >&5
    5834 +if { (eval echo "$as_me:6768: \"$ac_compile\"") >&5
     6056+if { (eval echo "$as_me:6777: \"$ac_compile\"") >&5
    58356057   (eval $ac_compile) 2>&5
    58366058   ac_status=$?
    58376059-  echo "$as_me:6484: \$? = $ac_status" >&5
    5838 +  echo "$as_me:6771: \$? = $ac_status" >&5
     6060+  echo "$as_me:6780: \$? = $ac_status" >&5
    58396061   (exit $ac_status); } &&
    58406062          { ac_try='test -s conftest.$ac_objext'
    58416063-  { (eval echo "$as_me:6487: \"$ac_try\"") >&5
    5842 +  { (eval echo "$as_me:6774: \"$ac_try\"") >&5
     6064+  { (eval echo "$as_me:6783: \"$ac_try\"") >&5
    58436065   (eval $ac_try) 2>&5
    58446066   ac_status=$?
    58456067-  echo "$as_me:6490: \$? = $ac_status" >&5
    5846 +  echo "$as_me:6777: \$? = $ac_status" >&5
     6068+  echo "$as_me:6786: \$? = $ac_status" >&5
    58476069   (exit $ac_status); }; }; then
    58486070   cf_cv_posix_c_source=no
    58496071 else
    5850 @@ -6508,7 +6795,7 @@
     6072@@ -6508,7 +6804,7 @@
    58516073         esac
    58526074         if test "$cf_want_posix_source" = yes ; then
    58536075                cat >conftest.$ac_ext <<_ACEOF
    58546076-#line 6511 "configure"
    5855 +#line 6798 "configure"
     6077+#line 6807 "configure"
    58566078 #include "confdefs.h"
    58576079 #include <sys/types.h>
    58586080 int
    5859 @@ -6523,16 +6810,16 @@
     6081@@ -6523,16 +6819,16 @@
    58606082 }
    58616083 _ACEOF
    58626084 rm -f conftest.$ac_objext
    58636085-if { (eval echo "$as_me:6526: \"$ac_compile\"") >&5
    5864 +if { (eval echo "$as_me:6813: \"$ac_compile\"") >&5
     6086+if { (eval echo "$as_me:6822: \"$ac_compile\"") >&5
    58656087   (eval $ac_compile) 2>&5
    58666088   ac_status=$?
    58676089-  echo "$as_me:6529: \$? = $ac_status" >&5
    5868 +  echo "$as_me:6816: \$? = $ac_status" >&5
     6090+  echo "$as_me:6825: \$? = $ac_status" >&5
    58696091   (exit $ac_status); } &&
    58706092          { ac_try='test -s conftest.$ac_objext'
    58716093-  { (eval echo "$as_me:6532: \"$ac_try\"") >&5
    5872 +  { (eval echo "$as_me:6819: \"$ac_try\"") >&5
     6094+  { (eval echo "$as_me:6828: \"$ac_try\"") >&5
    58736095   (eval $ac_try) 2>&5
    58746096   ac_status=$?
    58756097-  echo "$as_me:6535: \$? = $ac_status" >&5
    5876 +  echo "$as_me:6822: \$? = $ac_status" >&5
     6098+  echo "$as_me:6831: \$? = $ac_status" >&5
    58776099   (exit $ac_status); }; }; then
    58786100   :
    58796101 else
    5880 @@ -6543,15 +6830,15 @@
     6102@@ -6543,15 +6839,15 @@
    58816103 rm -f conftest.$ac_objext conftest.$ac_ext
    58826104         fi
    58836105 
    58846106-echo "${as_me-configure}:6546: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
    5885 +echo "${as_me-configure}:6833: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
     6107+echo "${as_me-configure}:6842: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
    58866108 
    58876109         CFLAGS="$cf_trim_CFLAGS"
     
    58896111 
    58906112-echo "${as_me-configure}:6551: testing if the second compile does not leave our definition intact error ..." 1>&5
    5891 +echo "${as_me-configure}:6838: testing if the second compile does not leave our definition intact error ..." 1>&5
     6113+echo "${as_me-configure}:6847: testing if the second compile does not leave our definition intact error ..." 1>&5
    58926114 
    58936115         cat >conftest.$ac_ext <<_ACEOF
    58946116-#line 6554 "configure"
    5895 +#line 6841 "configure"
     6117+#line 6850 "configure"
    58966118 #include "confdefs.h"
    58976119 #include <sys/types.h>
    58986120 int
    5899 @@ -6566,16 +6853,16 @@
     6121@@ -6566,16 +6862,16 @@
    59006122 }
    59016123 _ACEOF
    59026124 rm -f conftest.$ac_objext
    59036125-if { (eval echo "$as_me:6569: \"$ac_compile\"") >&5
    5904 +if { (eval echo "$as_me:6856: \"$ac_compile\"") >&5
     6126+if { (eval echo "$as_me:6865: \"$ac_compile\"") >&5
    59056127   (eval $ac_compile) 2>&5
    59066128   ac_status=$?
    59076129-  echo "$as_me:6572: \$? = $ac_status" >&5
    5908 +  echo "$as_me:6859: \$? = $ac_status" >&5
     6130+  echo "$as_me:6868: \$? = $ac_status" >&5
    59096131   (exit $ac_status); } &&
    59106132          { ac_try='test -s conftest.$ac_objext'
    59116133-  { (eval echo "$as_me:6575: \"$ac_try\"") >&5
    5912 +  { (eval echo "$as_me:6862: \"$ac_try\"") >&5
     6134+  { (eval echo "$as_me:6871: \"$ac_try\"") >&5
    59136135   (eval $ac_try) 2>&5
    59146136   ac_status=$?
    59156137-  echo "$as_me:6578: \$? = $ac_status" >&5
    5916 +  echo "$as_me:6865: \$? = $ac_status" >&5
     6138+  echo "$as_me:6874: \$? = $ac_status" >&5
    59176139   (exit $ac_status); }; }; then
    59186140   :
    59196141 else
    5920 @@ -6591,7 +6878,7 @@
     6142@@ -6591,7 +6887,7 @@
    59216143 rm -f conftest.$ac_objext conftest.$ac_ext
    59226144 
    59236145 fi
    59246146-echo "$as_me:6594: result: $cf_cv_posix_c_source" >&5
    5925 +echo "$as_me:6881: result: $cf_cv_posix_c_source" >&5
     6147+echo "$as_me:6890: result: $cf_cv_posix_c_source" >&5
    59266148 echo "${ECHO_T}$cf_cv_posix_c_source" >&6
    59276149 
    59286150 if test "$cf_cv_posix_c_source" != no ; then
    5929 @@ -6610,14 +6897,14 @@
     6151@@ -6610,14 +6906,14 @@
    59306152 
    59316153 # Work around breakage on OS X
    59326154 
    59336155-echo "$as_me:6613: checking if SIGWINCH is defined" >&5
    5934 +echo "$as_me:6900: checking if SIGWINCH is defined" >&5
     6156+echo "$as_me:6909: checking if SIGWINCH is defined" >&5
    59356157 echo $ECHO_N "checking if SIGWINCH is defined... $ECHO_C" >&6
    59366158 if test "${cf_cv_define_sigwinch+set}" = set; then
     
    59406162        cat >conftest.$ac_ext <<_ACEOF
    59416163-#line 6620 "configure"
    5942 +#line 6907 "configure"
     6164+#line 6916 "configure"
    59436165 #include "confdefs.h"
    59446166 
    59456167 #include <sys/types.h>
    5946 @@ -6632,23 +6919,23 @@
     6168@@ -6632,23 +6928,23 @@
    59476169 }
    59486170 _ACEOF
    59496171 rm -f conftest.$ac_objext
    59506172-if { (eval echo "$as_me:6635: \"$ac_compile\"") >&5
    5951 +if { (eval echo "$as_me:6922: \"$ac_compile\"") >&5
     6173+if { (eval echo "$as_me:6931: \"$ac_compile\"") >&5
    59526174   (eval $ac_compile) 2>&5
    59536175   ac_status=$?
    59546176-  echo "$as_me:6638: \$? = $ac_status" >&5
    5955 +  echo "$as_me:6925: \$? = $ac_status" >&5
     6177+  echo "$as_me:6934: \$? = $ac_status" >&5
    59566178   (exit $ac_status); } &&
    59576179          { ac_try='test -s conftest.$ac_objext'
    59586180-  { (eval echo "$as_me:6641: \"$ac_try\"") >&5
    5959 +  { (eval echo "$as_me:6928: \"$ac_try\"") >&5
     6181+  { (eval echo "$as_me:6937: \"$ac_try\"") >&5
    59606182   (eval $ac_try) 2>&5
    59616183   ac_status=$?
    59626184-  echo "$as_me:6644: \$? = $ac_status" >&5
    5963 +  echo "$as_me:6931: \$? = $ac_status" >&5
     6185+  echo "$as_me:6940: \$? = $ac_status" >&5
    59646186   (exit $ac_status); }; }; then
    59656187   cf_cv_define_sigwinch=yes
     
    59696191 cat >conftest.$ac_ext <<_ACEOF
    59706192-#line 6651 "configure"
    5971 +#line 6938 "configure"
     6193+#line 6947 "configure"
    59726194 #include "confdefs.h"
    59736195 
    59746196 #undef _XOPEN_SOURCE
    5975 @@ -6666,16 +6953,16 @@
     6197@@ -6666,16 +6962,16 @@
    59766198 }
    59776199 _ACEOF
    59786200 rm -f conftest.$ac_objext
    59796201-if { (eval echo "$as_me:6669: \"$ac_compile\"") >&5
    5980 +if { (eval echo "$as_me:6956: \"$ac_compile\"") >&5
     6202+if { (eval echo "$as_me:6965: \"$ac_compile\"") >&5
    59816203   (eval $ac_compile) 2>&5
    59826204   ac_status=$?
    59836205-  echo "$as_me:6672: \$? = $ac_status" >&5
    5984 +  echo "$as_me:6959: \$? = $ac_status" >&5
     6206+  echo "$as_me:6968: \$? = $ac_status" >&5
    59856207   (exit $ac_status); } &&
    59866208          { ac_try='test -s conftest.$ac_objext'
    59876209-  { (eval echo "$as_me:6675: \"$ac_try\"") >&5
    5988 +  { (eval echo "$as_me:6962: \"$ac_try\"") >&5
     6210+  { (eval echo "$as_me:6971: \"$ac_try\"") >&5
    59896211   (eval $ac_try) 2>&5
    59906212   ac_status=$?
    59916213-  echo "$as_me:6678: \$? = $ac_status" >&5
    5992 +  echo "$as_me:6965: \$? = $ac_status" >&5
     6214+  echo "$as_me:6974: \$? = $ac_status" >&5
    59936215   (exit $ac_status); }; }; then
    59946216   cf_cv_define_sigwinch=maybe
    59956217 else
    5996 @@ -6689,11 +6976,11 @@
     6218@@ -6689,11 +6985,11 @@
    59976219 rm -f conftest.$ac_objext conftest.$ac_ext
    59986220 
    59996221 fi
    60006222-echo "$as_me:6692: result: $cf_cv_define_sigwinch" >&5
    6001 +echo "$as_me:6979: result: $cf_cv_define_sigwinch" >&5
     6223+echo "$as_me:6988: result: $cf_cv_define_sigwinch" >&5
    60026224 echo "${ECHO_T}$cf_cv_define_sigwinch" >&6
    60036225 
    60046226 if test "$cf_cv_define_sigwinch" = maybe ; then
    60056227-echo "$as_me:6696: checking for actual SIGWINCH definition" >&5
    6006 +echo "$as_me:6983: checking for actual SIGWINCH definition" >&5
     6228+echo "$as_me:6992: checking for actual SIGWINCH definition" >&5
    60076229 echo $ECHO_N "checking for actual SIGWINCH definition... $ECHO_C" >&6
    60086230 if test "${cf_cv_fixup_sigwinch+set}" = set; then
    60096231   echo $ECHO_N "(cached) $ECHO_C" >&6
    6010 @@ -6704,7 +6991,7 @@
     6232@@ -6704,7 +7000,7 @@
    60116233 while test $cf_sigwinch != 1
    60126234 do
    60136235        cat >conftest.$ac_ext <<_ACEOF
    60146236-#line 6707 "configure"
    6015 +#line 6994 "configure"
     6237+#line 7003 "configure"
    60166238 #include "confdefs.h"
    60176239 
    60186240 #undef _XOPEN_SOURCE
    6019 @@ -6726,16 +7013,16 @@
     6241@@ -6726,16 +7022,16 @@
    60206242 }
    60216243 _ACEOF
    60226244 rm -f conftest.$ac_objext
    60236245-if { (eval echo "$as_me:6729: \"$ac_compile\"") >&5
    6024 +if { (eval echo "$as_me:7016: \"$ac_compile\"") >&5
     6246+if { (eval echo "$as_me:7025: \"$ac_compile\"") >&5
    60256247   (eval $ac_compile) 2>&5
    60266248   ac_status=$?
    60276249-  echo "$as_me:6732: \$? = $ac_status" >&5
    6028 +  echo "$as_me:7019: \$? = $ac_status" >&5
     6250+  echo "$as_me:7028: \$? = $ac_status" >&5
    60296251   (exit $ac_status); } &&
    60306252          { ac_try='test -s conftest.$ac_objext'
    60316253-  { (eval echo "$as_me:6735: \"$ac_try\"") >&5
    6032 +  { (eval echo "$as_me:7022: \"$ac_try\"") >&5
     6254+  { (eval echo "$as_me:7031: \"$ac_try\"") >&5
    60336255   (eval $ac_try) 2>&5
    60346256   ac_status=$?
    60356257-  echo "$as_me:6738: \$? = $ac_status" >&5
    6036 +  echo "$as_me:7025: \$? = $ac_status" >&5
     6258+  echo "$as_me:7034: \$? = $ac_status" >&5
    60376259   (exit $ac_status); }; }; then
    60386260   cf_cv_fixup_sigwinch=$cf_sigwinch
    60396261         break
    6040 @@ -6749,7 +7036,7 @@
     6262@@ -6749,7 +7045,7 @@
    60416263 done
    60426264 
    60436265 fi
    60446266-echo "$as_me:6752: result: $cf_cv_fixup_sigwinch" >&5
    6045 +echo "$as_me:7039: result: $cf_cv_fixup_sigwinch" >&5
     6267+echo "$as_me:7048: result: $cf_cv_fixup_sigwinch" >&5
    60466268 echo "${ECHO_T}$cf_cv_fixup_sigwinch" >&6
    60476269 
    60486270        if test "$cf_cv_fixup_sigwinch" != unknown ; then
    6049 @@ -6759,13 +7046,13 @@
     6271@@ -6759,13 +7055,13 @@
    60506272 
    60516273 # Checks for CODESET support.
    60526274 
    60536275-  echo "$as_me:6762: checking for nl_langinfo and CODESET" >&5
    6054 +  echo "$as_me:7049: checking for nl_langinfo and CODESET" >&5
     6276+  echo "$as_me:7058: checking for nl_langinfo and CODESET" >&5
    60556277 echo $ECHO_N "checking for nl_langinfo and CODESET... $ECHO_C" >&6
    60566278 if test "${am_cv_langinfo_codeset+set}" = set; then
     
    60596281   cat >conftest.$ac_ext <<_ACEOF
    60606282-#line 6768 "configure"
    6061 +#line 7055 "configure"
     6283+#line 7064 "configure"
    60626284 #include "confdefs.h"
    60636285 #include <langinfo.h>
    60646286 int
    6065 @@ -6777,16 +7064,16 @@
     6287@@ -6777,16 +7073,16 @@
    60666288 }
    60676289 _ACEOF
    60686290 rm -f conftest.$ac_objext conftest$ac_exeext
    60696291-if { (eval echo "$as_me:6780: \"$ac_link\"") >&5
    6070 +if { (eval echo "$as_me:7067: \"$ac_link\"") >&5
     6292+if { (eval echo "$as_me:7076: \"$ac_link\"") >&5
    60716293   (eval $ac_link) 2>&5
    60726294   ac_status=$?
    60736295-  echo "$as_me:6783: \$? = $ac_status" >&5
    6074 +  echo "$as_me:7070: \$? = $ac_status" >&5
     6296+  echo "$as_me:7079: \$? = $ac_status" >&5
    60756297   (exit $ac_status); } &&
    60766298          { ac_try='test -s conftest$ac_exeext'
    60776299-  { (eval echo "$as_me:6786: \"$ac_try\"") >&5
    6078 +  { (eval echo "$as_me:7073: \"$ac_try\"") >&5
     6300+  { (eval echo "$as_me:7082: \"$ac_try\"") >&5
    60796301   (eval $ac_try) 2>&5
    60806302   ac_status=$?
    60816303-  echo "$as_me:6789: \$? = $ac_status" >&5
    6082 +  echo "$as_me:7076: \$? = $ac_status" >&5
     6304+  echo "$as_me:7085: \$? = $ac_status" >&5
    60836305   (exit $ac_status); }; }; then
    60846306   am_cv_langinfo_codeset=yes
    60856307 else
    6086 @@ -6797,7 +7084,7 @@
     6308@@ -6797,7 +7093,7 @@
    60876309 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    60886310 
    60896311 fi
    60906312-echo "$as_me:6800: result: $am_cv_langinfo_codeset" >&5
    6091 +echo "$as_me:7087: result: $am_cv_langinfo_codeset" >&5
     6313+echo "$as_me:7096: result: $am_cv_langinfo_codeset" >&5
    60926314 echo "${ECHO_T}$am_cv_langinfo_codeset" >&6
    60936315   if test $am_cv_langinfo_codeset = yes; then
    60946316 
    6095 @@ -6811,7 +7098,7 @@
     6317@@ -6811,7 +7107,7 @@
    60966318 NCURSES_OK_WCHAR_T=
    60976319 NCURSES_OK_WINT_T=
    60986320 
    60996321-echo "$as_me:6814: checking if you want wide-character code" >&5
    6100 +echo "$as_me:7101: checking if you want wide-character code" >&5
     6322+echo "$as_me:7110: checking if you want wide-character code" >&5
    61016323 echo $ECHO_N "checking if you want wide-character code... $ECHO_C" >&6
    61026324 
    61036325 # Check whether --enable-widec or --disable-widec was given.
    6104 @@ -6821,7 +7108,7 @@
     6326@@ -6821,7 +7117,7 @@
    61056327 else
    61066328   with_widec=no
    61076329 fi;
    61086330-echo "$as_me:6824: result: $with_widec" >&5
    6109 +echo "$as_me:7111: result: $with_widec" >&5
     6331+echo "$as_me:7120: result: $with_widec" >&5
    61106332 echo "${ECHO_T}$with_widec" >&6
    61116333 if test "$with_widec" = yes ; then
    61126334        LIB_SUFFIX="w${LIB_SUFFIX}"
    6113 @@ -6829,10 +7116,10 @@
     6335@@ -6829,10 +7125,10 @@
    61146336 #define USE_WIDEC_SUPPORT 1
    61156337 EOF
    61166338 
    61176339-echo "$as_me:6832: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5
    6118 +echo "$as_me:7119: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5
     6340+echo "$as_me:7128: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5
    61196341 echo $ECHO_N "checking if we must define _XOPEN_SOURCE_EXTENDED... $ECHO_C" >&6
    61206342 cat >conftest.$ac_ext <<_ACEOF
    61216343-#line 6835 "configure"
    6122 +#line 7122 "configure"
     6344+#line 7131 "configure"
    61236345 #include "confdefs.h"
    61246346 #include <sys/types.h>
    61256347 
    6126 @@ -6848,16 +7135,16 @@
     6348@@ -6848,16 +7144,16 @@
    61276349 }
    61286350 _ACEOF
    61296351 rm -f conftest.$ac_objext
    61306352-if { (eval echo "$as_me:6851: \"$ac_compile\"") >&5
    6131 +if { (eval echo "$as_me:7138: \"$ac_compile\"") >&5
     6353+if { (eval echo "$as_me:7147: \"$ac_compile\"") >&5
    61326354   (eval $ac_compile) 2>&5
    61336355   ac_status=$?
    61346356-  echo "$as_me:6854: \$? = $ac_status" >&5
    6135 +  echo "$as_me:7141: \$? = $ac_status" >&5
     6357+  echo "$as_me:7150: \$? = $ac_status" >&5
    61366358   (exit $ac_status); } &&
    61376359          { ac_try='test -s conftest.$ac_objext'
    61386360-  { (eval echo "$as_me:6857: \"$ac_try\"") >&5
    6139 +  { (eval echo "$as_me:7144: \"$ac_try\"") >&5
     6361+  { (eval echo "$as_me:7153: \"$ac_try\"") >&5
    61406362   (eval $ac_try) 2>&5
    61416363   ac_status=$?
    61426364-  echo "$as_me:6860: \$? = $ac_status" >&5
    6143 +  echo "$as_me:7147: \$? = $ac_status" >&5
     6365+  echo "$as_me:7156: \$? = $ac_status" >&5
    61446366   (exit $ac_status); }; }; then
    61456367   cf_result=no
    61466368 else
    6147 @@ -6866,16 +7153,16 @@
     6369@@ -6866,16 +7162,16 @@
    61486370 cf_result=yes
    61496371 fi
    61506372 rm -f conftest.$ac_objext conftest.$ac_ext
    61516373-echo "$as_me:6869: result: $cf_result" >&5
    6152 +echo "$as_me:7156: result: $cf_result" >&5
     6374+echo "$as_me:7165: result: $cf_result" >&5
    61536375 echo "${ECHO_T}$cf_result" >&6
    61546376 
     
    61576379 elif test "x" != "x" ; then
    61586380-       echo "$as_me:6875: checking checking for compatible value versus " >&5
    6159 +       echo "$as_me:7162: checking checking for compatible value versus " >&5
     6381+       echo "$as_me:7171: checking checking for compatible value versus " >&5
    61606382 echo $ECHO_N "checking checking for compatible value versus ... $ECHO_C" >&6
    61616383        cat >conftest.$ac_ext <<_ACEOF
    61626384-#line 6878 "configure"
    6163 +#line 7165 "configure"
     6385+#line 7174 "configure"
    61646386 #include "confdefs.h"
    61656387 #include <sys/types.h>
    61666388 
    6167 @@ -6891,16 +7178,16 @@
     6389@@ -6891,16 +7187,16 @@
    61686390 }
    61696391 _ACEOF
    61706392 rm -f conftest.$ac_objext
    61716393-if { (eval echo "$as_me:6894: \"$ac_compile\"") >&5
    6172 +if { (eval echo "$as_me:7181: \"$ac_compile\"") >&5
     6394+if { (eval echo "$as_me:7190: \"$ac_compile\"") >&5
    61736395   (eval $ac_compile) 2>&5
    61746396   ac_status=$?
    61756397-  echo "$as_me:6897: \$? = $ac_status" >&5
    6176 +  echo "$as_me:7184: \$? = $ac_status" >&5
     6398+  echo "$as_me:7193: \$? = $ac_status" >&5
    61776399   (exit $ac_status); } &&
    61786400          { ac_try='test -s conftest.$ac_objext'
    61796401-  { (eval echo "$as_me:6900: \"$ac_try\"") >&5
    6180 +  { (eval echo "$as_me:7187: \"$ac_try\"") >&5
     6402+  { (eval echo "$as_me:7196: \"$ac_try\"") >&5
    61816403   (eval $ac_try) 2>&5
    61826404   ac_status=$?
    61836405-  echo "$as_me:6903: \$? = $ac_status" >&5
    6184 +  echo "$as_me:7190: \$? = $ac_status" >&5
     6406+  echo "$as_me:7199: \$? = $ac_status" >&5
    61856407   (exit $ac_status); }; }; then
    61866408   cf_result=yes
    61876409 else
    6188 @@ -6909,7 +7196,7 @@
     6410@@ -6909,7 +7205,7 @@
    61896411 cf_result=no
    61906412 fi
    61916413 rm -f conftest.$ac_objext conftest.$ac_ext
    61926414-       echo "$as_me:6912: result: $cf_result" >&5
    6193 +       echo "$as_me:7199: result: $cf_result" >&5
     6415+       echo "$as_me:7208: result: $cf_result" >&5
    61946416 echo "${ECHO_T}$cf_result" >&6
    61956417        if test "$cf_result" = no ; then
    61966418                # perhaps we can override it - try...
    6197 @@ -6923,13 +7210,13 @@
     6419@@ -6923,13 +7219,13 @@
    61986420 for ac_func in putwc btowc wctob mbtowc wctomb mblen mbrlen mbrtowc wcsrtombs mbsrtowcs wcstombs mbstowcs
    61996421 do
    62006422 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
    62016423-echo "$as_me:6926: checking for $ac_func" >&5
    6202 +echo "$as_me:7213: checking for $ac_func" >&5
     6424+echo "$as_me:7222: checking for $ac_func" >&5
    62036425 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
    62046426 if eval "test \"\${$as_ac_var+set}\" = set"; then
     
    62076429   cat >conftest.$ac_ext <<_ACEOF
    62086430-#line 6932 "configure"
    6209 +#line 7219 "configure"
     6431+#line 7228 "configure"
    62106432 #include "confdefs.h"
    62116433 /* System header to define __stub macros and hopefully few prototypes,
    62126434     which can conflict with char $ac_func (); below.  */
    6213 @@ -6960,16 +7247,16 @@
     6435@@ -6960,16 +7256,16 @@
    62146436 }
    62156437 _ACEOF
    62166438 rm -f conftest.$ac_objext conftest$ac_exeext
    62176439-if { (eval echo "$as_me:6963: \"$ac_link\"") >&5
    6218 +if { (eval echo "$as_me:7250: \"$ac_link\"") >&5
     6440+if { (eval echo "$as_me:7259: \"$ac_link\"") >&5
    62196441   (eval $ac_link) 2>&5
    62206442   ac_status=$?
    62216443-  echo "$as_me:6966: \$? = $ac_status" >&5
    6222 +  echo "$as_me:7253: \$? = $ac_status" >&5
     6444+  echo "$as_me:7262: \$? = $ac_status" >&5
    62236445   (exit $ac_status); } &&
    62246446          { ac_try='test -s conftest$ac_exeext'
    62256447-  { (eval echo "$as_me:6969: \"$ac_try\"") >&5
    6226 +  { (eval echo "$as_me:7256: \"$ac_try\"") >&5
     6448+  { (eval echo "$as_me:7265: \"$ac_try\"") >&5
    62276449   (eval $ac_try) 2>&5
    62286450   ac_status=$?
    62296451-  echo "$as_me:6972: \$? = $ac_status" >&5
    6230 +  echo "$as_me:7259: \$? = $ac_status" >&5
     6452+  echo "$as_me:7268: \$? = $ac_status" >&5
    62316453   (exit $ac_status); }; }; then
    62326454   eval "$as_ac_var=yes"
    62336455 else
    6234 @@ -6979,7 +7266,7 @@
     6456@@ -6979,7 +7275,7 @@
    62356457 fi
    62366458 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    62376459 fi
    62386460-echo "$as_me:6982: result: `eval echo '${'$as_ac_var'}'`" >&5
    6239 +echo "$as_me:7269: result: `eval echo '${'$as_ac_var'}'`" >&5
     6461+echo "$as_me:7278: result: `eval echo '${'$as_ac_var'}'`" >&5
    62406462 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
    62416463 if test `eval echo '${'$as_ac_var'}'` = yes; then
    62426464   cat >>confdefs.h <<EOF
    6243 @@ -6991,7 +7278,7 @@
     6465@@ -6991,7 +7287,7 @@
    62446466 
    62456467        if test "$ac_cv_func_putwc" != yes ; then
    62466468 
    62476469-echo "$as_me:6994: checking for multibyte character support" >&5
    6248 +echo "$as_me:7281: checking for multibyte character support" >&5
     6470+echo "$as_me:7290: checking for multibyte character support" >&5
    62496471 echo $ECHO_N "checking for multibyte character support... $ECHO_C" >&6
    62506472 if test "${cf_cv_utf8_lib+set}" = set; then
    62516473   echo $ECHO_N "(cached) $ECHO_C" >&6
    6252 @@ -6999,7 +7286,7 @@
     6474@@ -6999,7 +7295,7 @@
    62536475 
    62546476        cf_save_LIBS="$LIBS"
    62556477        cat >conftest.$ac_ext <<_ACEOF
    62566478-#line 7002 "configure"
    6257 +#line 7289 "configure"
     6479+#line 7298 "configure"
    62586480 #include "confdefs.h"
    62596481 
    62606482 #include <stdlib.h>
    6261 @@ -7012,16 +7299,16 @@
     6483@@ -7012,16 +7308,16 @@
    62626484 }
    62636485 _ACEOF
    62646486 rm -f conftest.$ac_objext conftest$ac_exeext
    62656487-if { (eval echo "$as_me:7015: \"$ac_link\"") >&5
    6266 +if { (eval echo "$as_me:7302: \"$ac_link\"") >&5
     6488+if { (eval echo "$as_me:7311: \"$ac_link\"") >&5
    62676489   (eval $ac_link) 2>&5
    62686490   ac_status=$?
    62696491-  echo "$as_me:7018: \$? = $ac_status" >&5
    6270 +  echo "$as_me:7305: \$? = $ac_status" >&5
     6492+  echo "$as_me:7314: \$? = $ac_status" >&5
    62716493   (exit $ac_status); } &&
    62726494          { ac_try='test -s conftest$ac_exeext'
    62736495-  { (eval echo "$as_me:7021: \"$ac_try\"") >&5
    6274 +  { (eval echo "$as_me:7308: \"$ac_try\"") >&5
     6496+  { (eval echo "$as_me:7317: \"$ac_try\"") >&5
    62756497   (eval $ac_try) 2>&5
    62766498   ac_status=$?
    62776499-  echo "$as_me:7024: \$? = $ac_status" >&5
    6278 +  echo "$as_me:7311: \$? = $ac_status" >&5
     6500+  echo "$as_me:7320: \$? = $ac_status" >&5
    62796501   (exit $ac_status); }; }; then
    62806502   cf_cv_utf8_lib=yes
    62816503 else
    6282 @@ -7033,10 +7320,10 @@
     6504@@ -7033,10 +7329,10 @@
    62836505 cf_cv_header_path_utf8=
    62846506 cf_cv_library_path_utf8=
    62856507 
    62866508-echo "${as_me-configure}:7036: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
    6287 +echo "${as_me-configure}:7323: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
     6509+echo "${as_me-configure}:7332: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
    62886510 
    62896511 cat >conftest.$ac_ext <<_ACEOF
    62906512-#line 7039 "configure"
    6291 +#line 7326 "configure"
     6513+#line 7335 "configure"
    62926514 #include "confdefs.h"
    62936515 
    62946516 #include <libutf8.h>
    6295 @@ -7049,16 +7336,16 @@
     6517@@ -7049,16 +7345,16 @@
    62966518 }
    62976519 _ACEOF
    62986520 rm -f conftest.$ac_objext conftest$ac_exeext
    62996521-if { (eval echo "$as_me:7052: \"$ac_link\"") >&5
    6300 +if { (eval echo "$as_me:7339: \"$ac_link\"") >&5
     6522+if { (eval echo "$as_me:7348: \"$ac_link\"") >&5
    63016523   (eval $ac_link) 2>&5
    63026524   ac_status=$?
    63036525-  echo "$as_me:7055: \$? = $ac_status" >&5
    6304 +  echo "$as_me:7342: \$? = $ac_status" >&5
     6526+  echo "$as_me:7351: \$? = $ac_status" >&5
    63056527   (exit $ac_status); } &&
    63066528          { ac_try='test -s conftest$ac_exeext'
    63076529-  { (eval echo "$as_me:7058: \"$ac_try\"") >&5
    6308 +  { (eval echo "$as_me:7345: \"$ac_try\"") >&5
     6530+  { (eval echo "$as_me:7354: \"$ac_try\"") >&5
    63096531   (eval $ac_try) 2>&5
    63106532   ac_status=$?
    63116533-  echo "$as_me:7061: \$? = $ac_status" >&5
    6312 +  echo "$as_me:7348: \$? = $ac_status" >&5
     6534+  echo "$as_me:7357: \$? = $ac_status" >&5
    63136535   (exit $ac_status); }; }; then
    63146536   cf_cv_find_linkage_utf8=yes
    63156537 else
    6316 @@ -7067,12 +7354,41 @@
     6538@@ -7067,12 +7363,41 @@
    63176539 
    63186540     cf_cv_find_linkage_utf8=no
     
    63216543+    test -n "$verbose" && echo "       find linkage for utf8 library" 1>&6
    63226544+
    6323 +echo "${as_me-configure}:7359: testing find linkage for utf8 library ..." 1>&5
    6324 +
    6325 +echo "${as_me-configure}:7361: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
     6545+echo "${as_me-configure}:7368: testing find linkage for utf8 library ..." 1>&5
     6546+
     6547+echo "${as_me-configure}:7370: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
    63266548 
    63276549     cf_save_CPPFLAGS="$CPPFLAGS"
     
    63586580 test "/usr" != "$prefix" && \
    63596581 test -d "/usr" && \
    6360 @@ -7143,16 +7459,18 @@
     6582@@ -7143,16 +7468,18 @@
    63616583        test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
    63626584 }
     
    63706592 
    63716593-echo "${as_me-configure}:7151: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
    6372 +echo "${as_me-configure}:7469: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
     6594+echo "${as_me-configure}:7478: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
    63736595 
    63746596         CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8"
    63756597         cat >conftest.$ac_ext <<_ACEOF
    63766598-#line 7155 "configure"
    6377 +#line 7473 "configure"
     6599+#line 7482 "configure"
    63786600 #include "confdefs.h"
    63796601 
    63806602 #include <libutf8.h>
    6381 @@ -7165,21 +7483,21 @@
     6603@@ -7165,21 +7492,21 @@
    63826604 }
    63836605 _ACEOF
    63846606 rm -f conftest.$ac_objext
    63856607-if { (eval echo "$as_me:7168: \"$ac_compile\"") >&5
    6386 +if { (eval echo "$as_me:7486: \"$ac_compile\"") >&5
     6608+if { (eval echo "$as_me:7495: \"$ac_compile\"") >&5
    63876609   (eval $ac_compile) 2>&5
    63886610   ac_status=$?
    63896611-  echo "$as_me:7171: \$? = $ac_status" >&5
    6390 +  echo "$as_me:7489: \$? = $ac_status" >&5
     6612+  echo "$as_me:7498: \$? = $ac_status" >&5
    63916613   (exit $ac_status); } &&
    63926614          { ac_try='test -s conftest.$ac_objext'
    63936615-  { (eval echo "$as_me:7174: \"$ac_try\"") >&5
    6394 +  { (eval echo "$as_me:7492: \"$ac_try\"") >&5
     6616+  { (eval echo "$as_me:7501: \"$ac_try\"") >&5
    63956617   (eval $ac_try) 2>&5
    63966618   ac_status=$?
    63976619-  echo "$as_me:7177: \$? = $ac_status" >&5
    6398 +  echo "$as_me:7495: \$? = $ac_status" >&5
     6620+  echo "$as_me:7504: \$? = $ac_status" >&5
    63996621   (exit $ac_status); }; }; then
    64006622 
     
    64026624 
    64036625-echo "${as_me-configure}:7182: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
    6404 +echo "${as_me-configure}:7500: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
     6626+echo "${as_me-configure}:7509: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
    64056627 
    64066628             cf_cv_find_linkage_utf8=maybe
    64076629             cf_test_CPPFLAGS="$CPPFLAGS"
    6408 @@ -7197,13 +7515,39 @@
     6630@@ -7197,13 +7524,39 @@
    64096631 
    64106632     if test "$cf_cv_find_linkage_utf8" = maybe ; then
    64116633 
    64126634-echo "${as_me-configure}:7200: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
    6413 +echo "${as_me-configure}:7518: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
     6635+echo "${as_me-configure}:7527: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
    64146636 
    64156637       cf_save_LIBS="$LIBS"
     
    64486670 test "/usr" != "$prefix" && \
    64496671 test -d "/usr" && \
    6450 @@ -7260,18 +7604,20 @@
     6672@@ -7260,18 +7613,20 @@
    64516673        test -d $HOME/utf8/lib/utf8 &&    cf_search="$cf_search $HOME/utf8/lib/utf8"
    64526674 }
     
    64606682 
    64616683-echo "${as_me-configure}:7268: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
    6462 +echo "${as_me-configure}:7614: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
     6684+echo "${as_me-configure}:7623: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
    64636685 
    64646686             CPPFLAGS="$cf_test_CPPFLAGS"
     
    64676689             cat >conftest.$ac_ext <<_ACEOF
    64686690-#line 7274 "configure"
    6469 +#line 7620 "configure"
     6691+#line 7629 "configure"
    64706692 #include "confdefs.h"
    64716693 
    64726694 #include <libutf8.h>
    6473 @@ -7284,21 +7630,21 @@
     6695@@ -7284,21 +7639,21 @@
    64746696 }
    64756697 _ACEOF
    64766698 rm -f conftest.$ac_objext conftest$ac_exeext
    64776699-if { (eval echo "$as_me:7287: \"$ac_link\"") >&5
    6478 +if { (eval echo "$as_me:7633: \"$ac_link\"") >&5
     6700+if { (eval echo "$as_me:7642: \"$ac_link\"") >&5
    64796701   (eval $ac_link) 2>&5
    64806702   ac_status=$?
    64816703-  echo "$as_me:7290: \$? = $ac_status" >&5
    6482 +  echo "$as_me:7636: \$? = $ac_status" >&5
     6704+  echo "$as_me:7645: \$? = $ac_status" >&5
    64836705   (exit $ac_status); } &&
    64846706          { ac_try='test -s conftest$ac_exeext'
    64856707-  { (eval echo "$as_me:7293: \"$ac_try\"") >&5
    6486 +  { (eval echo "$as_me:7639: \"$ac_try\"") >&5
     6708+  { (eval echo "$as_me:7648: \"$ac_try\"") >&5
    64876709   (eval $ac_try) 2>&5
    64886710   ac_status=$?
    64896711-  echo "$as_me:7296: \$? = $ac_status" >&5
    6490 +  echo "$as_me:7642: \$? = $ac_status" >&5
     6712+  echo "$as_me:7651: \$? = $ac_status" >&5
    64916713   (exit $ac_status); }; }; then
    64926714 
     
    64946716 
    64956717-echo "${as_me-configure}:7301: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
    6496 +echo "${as_me-configure}:7647: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
     6718+echo "${as_me-configure}:7656: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
    64976719 
    64986720                 cf_cv_find_linkage_utf8=yes
    64996721                 cf_cv_library_file_utf8="-lutf8"
    6500 @@ -7336,7 +7682,7 @@
     6722@@ -7336,7 +7691,7 @@
    65016723 fi
    65026724 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    65036725 fi
    65046726-echo "$as_me:7339: result: $cf_cv_utf8_lib" >&5
    6505 +echo "$as_me:7685: result: $cf_cv_utf8_lib" >&5
     6727+echo "$as_me:7694: result: $cf_cv_utf8_lib" >&5
    65066728 echo "${ECHO_T}$cf_cv_utf8_lib" >&6
    65076729 
    65086730 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
    6509 @@ -7364,13 +7710,13 @@
     6731@@ -7364,13 +7719,13 @@
    65106732                fi
    65116733 
     
    65196741                          cat >conftest.$ac_ext <<_ACEOF
    65206742-#line 7373 "configure"
    6521 +#line 7719 "configure"
     6743+#line 7728 "configure"
    65226744 #include "confdefs.h"
    65236745 #include <stdio.h>
    65246746 int
    6525 @@ -7382,16 +7728,16 @@
     6747@@ -7382,16 +7737,16 @@
    65266748 }
    65276749 _ACEOF
    65286750 rm -f conftest.$ac_objext
    65296751-if { (eval echo "$as_me:7385: \"$ac_compile\"") >&5
    6530 +if { (eval echo "$as_me:7731: \"$ac_compile\"") >&5
     6752+if { (eval echo "$as_me:7740: \"$ac_compile\"") >&5
    65316753   (eval $ac_compile) 2>&5
    65326754   ac_status=$?
    65336755-  echo "$as_me:7388: \$? = $ac_status" >&5
    6534 +  echo "$as_me:7734: \$? = $ac_status" >&5
     6756+  echo "$as_me:7743: \$? = $ac_status" >&5
    65356757   (exit $ac_status); } &&
    65366758          { ac_try='test -s conftest.$ac_objext'
    65376759-  { (eval echo "$as_me:7391: \"$ac_try\"") >&5
    6538 +  { (eval echo "$as_me:7737: \"$ac_try\"") >&5
     6760+  { (eval echo "$as_me:7746: \"$ac_try\"") >&5
    65396761   (eval $ac_try) 2>&5
    65406762   ac_status=$?
    65416763-  echo "$as_me:7394: \$? = $ac_status" >&5
    6542 +  echo "$as_me:7740: \$? = $ac_status" >&5
     6764+  echo "$as_me:7749: \$? = $ac_status" >&5
    65436765   (exit $ac_status); }; }; then
    65446766   :
    65456767 else
    6546 @@ -7408,13 +7754,13 @@
     6768@@ -7408,13 +7763,13 @@
    65476769                if test "$cf_have_incdir" = no ; then
    65486770                  test -n "$verbose" && echo "  adding $cf_add_incdir to include-path" 1>&6
    65496771 
    65506772-echo "${as_me-configure}:7411: testing adding $cf_add_incdir to include-path ..." 1>&5
    6551 +echo "${as_me-configure}:7757: testing adding $cf_add_incdir to include-path ..." 1>&5
     6773+echo "${as_me-configure}:7766: testing adding $cf_add_incdir to include-path ..." 1>&5
    65526774 
    65536775-                 CPPFLAGS="-I$cf_add_incdir $CPPFLAGS"
     
    65636785                  break
    65646786                fi
    6565 @@ -7442,7 +7788,7 @@
     6787@@ -7442,7 +7797,7 @@
    65666788       if test "$cf_have_libdir" = no ; then
    65676789         test -n "$verbose" && echo "   adding $cf_add_libdir to library-path" 1>&6
    65686790 
    65696791-echo "${as_me-configure}:7445: testing adding $cf_add_libdir to library-path ..." 1>&5
    6570 +echo "${as_me-configure}:7791: testing adding $cf_add_libdir to library-path ..." 1>&5
     6792+echo "${as_me-configure}:7800: testing adding $cf_add_libdir to library-path ..." 1>&5
    65716793 
    65726794         LDFLAGS="-L$cf_add_libdir $LDFLAGS"
    65736795       fi
    6574 @@ -7459,14 +7805,14 @@
     6796@@ -7459,14 +7814,14 @@
    65756797        fi
    65766798 
    65776799 # This is needed on Tru64 5.0 to declare mbstate_t
    65786800-echo "$as_me:7462: checking if we must include wchar.h to declare mbstate_t" >&5
    6579 +echo "$as_me:7808: checking if we must include wchar.h to declare mbstate_t" >&5
     6801+echo "$as_me:7817: checking if we must include wchar.h to declare mbstate_t" >&5
    65806802 echo $ECHO_N "checking if we must include wchar.h to declare mbstate_t... $ECHO_C" >&6
    65816803 if test "${cf_cv_mbstate_t+set}" = set; then
     
    65856807 cat >conftest.$ac_ext <<_ACEOF
    65866808-#line 7469 "configure"
    6587 +#line 7815 "configure"
     6809+#line 7824 "configure"
    65886810 #include "confdefs.h"
    65896811 
    65906812 #include <stdlib.h>
    6591 @@ -7484,23 +7830,23 @@
     6813@@ -7484,23 +7839,23 @@
    65926814 }
    65936815 _ACEOF
    65946816 rm -f conftest.$ac_objext
    65956817-if { (eval echo "$as_me:7487: \"$ac_compile\"") >&5
    6596 +if { (eval echo "$as_me:7833: \"$ac_compile\"") >&5
     6818+if { (eval echo "$as_me:7842: \"$ac_compile\"") >&5
    65976819   (eval $ac_compile) 2>&5
    65986820   ac_status=$?
    65996821-  echo "$as_me:7490: \$? = $ac_status" >&5
    6600 +  echo "$as_me:7836: \$? = $ac_status" >&5
     6822+  echo "$as_me:7845: \$? = $ac_status" >&5
    66016823   (exit $ac_status); } &&
    66026824          { ac_try='test -s conftest.$ac_objext'
    66036825-  { (eval echo "$as_me:7493: \"$ac_try\"") >&5
    6604 +  { (eval echo "$as_me:7839: \"$ac_try\"") >&5
     6826+  { (eval echo "$as_me:7848: \"$ac_try\"") >&5
    66056827   (eval $ac_try) 2>&5
    66066828   ac_status=$?
    66076829-  echo "$as_me:7496: \$? = $ac_status" >&5
    6608 +  echo "$as_me:7842: \$? = $ac_status" >&5
     6830+  echo "$as_me:7851: \$? = $ac_status" >&5
    66096831   (exit $ac_status); }; }; then
    66106832   cf_cv_mbstate_t=no
     
    66146836 cat >conftest.$ac_ext <<_ACEOF
    66156837-#line 7503 "configure"
    6616 +#line 7849 "configure"
     6838+#line 7858 "configure"
    66176839 #include "confdefs.h"
    66186840 
    66196841 #include <stdlib.h>
    6620 @@ -7519,16 +7865,16 @@
     6842@@ -7519,16 +7874,16 @@
    66216843 }
    66226844 _ACEOF
    66236845 rm -f conftest.$ac_objext
    66246846-if { (eval echo "$as_me:7522: \"$ac_compile\"") >&5
    6625 +if { (eval echo "$as_me:7868: \"$ac_compile\"") >&5
     6847+if { (eval echo "$as_me:7877: \"$ac_compile\"") >&5
    66266848   (eval $ac_compile) 2>&5
    66276849   ac_status=$?
    66286850-  echo "$as_me:7525: \$? = $ac_status" >&5
    6629 +  echo "$as_me:7871: \$? = $ac_status" >&5
     6851+  echo "$as_me:7880: \$? = $ac_status" >&5
    66306852   (exit $ac_status); } &&
    66316853          { ac_try='test -s conftest.$ac_objext'
    66326854-  { (eval echo "$as_me:7528: \"$ac_try\"") >&5
    6633 +  { (eval echo "$as_me:7874: \"$ac_try\"") >&5
     6855+  { (eval echo "$as_me:7883: \"$ac_try\"") >&5
    66346856   (eval $ac_try) 2>&5
    66356857   ac_status=$?
    66366858-  echo "$as_me:7531: \$? = $ac_status" >&5
    6637 +  echo "$as_me:7877: \$? = $ac_status" >&5
     6859+  echo "$as_me:7886: \$? = $ac_status" >&5
    66386860   (exit $ac_status); }; }; then
    66396861   cf_cv_mbstate_t=yes
    66406862 else
    6641 @@ -7540,7 +7886,7 @@
     6863@@ -7540,7 +7895,7 @@
    66426864 fi
    66436865 rm -f conftest.$ac_objext conftest.$ac_ext
    66446866 fi
    66456867-echo "$as_me:7543: result: $cf_cv_mbstate_t" >&5
    6646 +echo "$as_me:7889: result: $cf_cv_mbstate_t" >&5
     6868+echo "$as_me:7898: result: $cf_cv_mbstate_t" >&5
    66476869 echo "${ECHO_T}$cf_cv_mbstate_t" >&6
    66486870 
    66496871 if test "$cf_cv_mbstate_t" = yes ; then
    6650 @@ -7557,14 +7903,14 @@
     6872@@ -7557,14 +7912,14 @@
    66516873 fi
    66526874 
    66536875 # This is needed on Tru64 5.0 to declare wchar_t
    66546876-echo "$as_me:7560: checking if we must include wchar.h to declare wchar_t" >&5
    6655 +echo "$as_me:7906: checking if we must include wchar.h to declare wchar_t" >&5
     6877+echo "$as_me:7915: checking if we must include wchar.h to declare wchar_t" >&5
    66566878 echo $ECHO_N "checking if we must include wchar.h to declare wchar_t... $ECHO_C" >&6
    66576879 if test "${cf_cv_wchar_t+set}" = set; then
     
    66616883 cat >conftest.$ac_ext <<_ACEOF
    66626884-#line 7567 "configure"
    6663 +#line 7913 "configure"
     6885+#line 7922 "configure"
    66646886 #include "confdefs.h"
    66656887 
    66666888 #include <stdlib.h>
    6667 @@ -7582,23 +7928,23 @@
     6889@@ -7582,23 +7937,23 @@
    66686890 }
    66696891 _ACEOF
    66706892 rm -f conftest.$ac_objext
    66716893-if { (eval echo "$as_me:7585: \"$ac_compile\"") >&5
    6672 +if { (eval echo "$as_me:7931: \"$ac_compile\"") >&5
     6894+if { (eval echo "$as_me:7940: \"$ac_compile\"") >&5
    66736895   (eval $ac_compile) 2>&5
    66746896   ac_status=$?
    66756897-  echo "$as_me:7588: \$? = $ac_status" >&5
    6676 +  echo "$as_me:7934: \$? = $ac_status" >&5
     6898+  echo "$as_me:7943: \$? = $ac_status" >&5
    66776899   (exit $ac_status); } &&
    66786900          { ac_try='test -s conftest.$ac_objext'
    66796901-  { (eval echo "$as_me:7591: \"$ac_try\"") >&5
    6680 +  { (eval echo "$as_me:7937: \"$ac_try\"") >&5
     6902+  { (eval echo "$as_me:7946: \"$ac_try\"") >&5
    66816903   (eval $ac_try) 2>&5
    66826904   ac_status=$?
    66836905-  echo "$as_me:7594: \$? = $ac_status" >&5
    6684 +  echo "$as_me:7940: \$? = $ac_status" >&5
     6906+  echo "$as_me:7949: \$? = $ac_status" >&5
    66856907   (exit $ac_status); }; }; then
    66866908   cf_cv_wchar_t=no
     
    66906912 cat >conftest.$ac_ext <<_ACEOF
    66916913-#line 7601 "configure"
    6692 +#line 7947 "configure"
     6914+#line 7956 "configure"
    66936915 #include "confdefs.h"
    66946916 
    66956917 #include <stdlib.h>
    6696 @@ -7617,16 +7963,16 @@
     6918@@ -7617,16 +7972,16 @@
    66976919 }
    66986920 _ACEOF
    66996921 rm -f conftest.$ac_objext
    67006922-if { (eval echo "$as_me:7620: \"$ac_compile\"") >&5
    6701 +if { (eval echo "$as_me:7966: \"$ac_compile\"") >&5
     6923+if { (eval echo "$as_me:7975: \"$ac_compile\"") >&5
    67026924   (eval $ac_compile) 2>&5
    67036925   ac_status=$?
    67046926-  echo "$as_me:7623: \$? = $ac_status" >&5
    6705 +  echo "$as_me:7969: \$? = $ac_status" >&5
     6927+  echo "$as_me:7978: \$? = $ac_status" >&5
    67066928   (exit $ac_status); } &&
    67076929          { ac_try='test -s conftest.$ac_objext'
    67086930-  { (eval echo "$as_me:7626: \"$ac_try\"") >&5
    6709 +  { (eval echo "$as_me:7972: \"$ac_try\"") >&5
     6931+  { (eval echo "$as_me:7981: \"$ac_try\"") >&5
    67106932   (eval $ac_try) 2>&5
    67116933   ac_status=$?
    67126934-  echo "$as_me:7629: \$? = $ac_status" >&5
    6713 +  echo "$as_me:7975: \$? = $ac_status" >&5
     6935+  echo "$as_me:7984: \$? = $ac_status" >&5
    67146936   (exit $ac_status); }; }; then
    67156937   cf_cv_wchar_t=yes
    67166938 else
    6717 @@ -7638,7 +7984,7 @@
     6939@@ -7638,7 +7993,7 @@
    67186940 fi
    67196941 rm -f conftest.$ac_objext conftest.$ac_ext
    67206942 fi
    67216943-echo "$as_me:7641: result: $cf_cv_wchar_t" >&5
    6722 +echo "$as_me:7987: result: $cf_cv_wchar_t" >&5
     6944+echo "$as_me:7996: result: $cf_cv_wchar_t" >&5
    67236945 echo "${ECHO_T}$cf_cv_wchar_t" >&6
    67246946 
    67256947 if test "$cf_cv_wchar_t" = yes ; then
    6726 @@ -7660,14 +8006,14 @@
     6948@@ -7660,14 +8015,14 @@
    67276949 fi
    67286950 
    67296951 # This is needed on Tru64 5.0 to declare wint_t
    67306952-echo "$as_me:7663: checking if we must include wchar.h to declare wint_t" >&5
    6731 +echo "$as_me:8009: checking if we must include wchar.h to declare wint_t" >&5
     6953+echo "$as_me:8018: checking if we must include wchar.h to declare wint_t" >&5
    67326954 echo $ECHO_N "checking if we must include wchar.h to declare wint_t... $ECHO_C" >&6
    67336955 if test "${cf_cv_wint_t+set}" = set; then
     
    67376959 cat >conftest.$ac_ext <<_ACEOF
    67386960-#line 7670 "configure"
    6739 +#line 8016 "configure"
     6961+#line 8025 "configure"
    67406962 #include "confdefs.h"
    67416963 
    67426964 #include <stdlib.h>
    6743 @@ -7685,23 +8031,23 @@
     6965@@ -7685,23 +8040,23 @@
    67446966 }
    67456967 _ACEOF
    67466968 rm -f conftest.$ac_objext
    67476969-if { (eval echo "$as_me:7688: \"$ac_compile\"") >&5
    6748 +if { (eval echo "$as_me:8034: \"$ac_compile\"") >&5
     6970+if { (eval echo "$as_me:8043: \"$ac_compile\"") >&5
    67496971   (eval $ac_compile) 2>&5
    67506972   ac_status=$?
    67516973-  echo "$as_me:7691: \$? = $ac_status" >&5
    6752 +  echo "$as_me:8037: \$? = $ac_status" >&5
     6974+  echo "$as_me:8046: \$? = $ac_status" >&5
    67536975   (exit $ac_status); } &&
    67546976          { ac_try='test -s conftest.$ac_objext'
    67556977-  { (eval echo "$as_me:7694: \"$ac_try\"") >&5
    6756 +  { (eval echo "$as_me:8040: \"$ac_try\"") >&5
     6978+  { (eval echo "$as_me:8049: \"$ac_try\"") >&5
    67576979   (eval $ac_try) 2>&5
    67586980   ac_status=$?
    67596981-  echo "$as_me:7697: \$? = $ac_status" >&5
    6760 +  echo "$as_me:8043: \$? = $ac_status" >&5
     6982+  echo "$as_me:8052: \$? = $ac_status" >&5
    67616983   (exit $ac_status); }; }; then
    67626984   cf_cv_wint_t=no
     
    67666988 cat >conftest.$ac_ext <<_ACEOF
    67676989-#line 7704 "configure"
    6768 +#line 8050 "configure"
     6990+#line 8059 "configure"
    67696991 #include "confdefs.h"
    67706992 
    67716993 #include <stdlib.h>
    6772 @@ -7720,16 +8066,16 @@
     6994@@ -7720,16 +8075,16 @@
    67736995 }
    67746996 _ACEOF
    67756997 rm -f conftest.$ac_objext
    67766998-if { (eval echo "$as_me:7723: \"$ac_compile\"") >&5
    6777 +if { (eval echo "$as_me:8069: \"$ac_compile\"") >&5
     6999+if { (eval echo "$as_me:8078: \"$ac_compile\"") >&5
    67787000   (eval $ac_compile) 2>&5
    67797001   ac_status=$?
    67807002-  echo "$as_me:7726: \$? = $ac_status" >&5
    6781 +  echo "$as_me:8072: \$? = $ac_status" >&5
     7003+  echo "$as_me:8081: \$? = $ac_status" >&5
    67827004   (exit $ac_status); } &&
    67837005          { ac_try='test -s conftest.$ac_objext'
    67847006-  { (eval echo "$as_me:7729: \"$ac_try\"") >&5
    6785 +  { (eval echo "$as_me:8075: \"$ac_try\"") >&5
     7007+  { (eval echo "$as_me:8084: \"$ac_try\"") >&5
    67867008   (eval $ac_try) 2>&5
    67877009   ac_status=$?
    67887010-  echo "$as_me:7732: \$? = $ac_status" >&5
    6789 +  echo "$as_me:8078: \$? = $ac_status" >&5
     7011+  echo "$as_me:8087: \$? = $ac_status" >&5
    67907012   (exit $ac_status); }; }; then
    67917013   cf_cv_wint_t=yes
    67927014 else
    6793 @@ -7741,7 +8087,7 @@
     7015@@ -7741,7 +8096,7 @@
    67947016 fi
    67957017 rm -f conftest.$ac_objext conftest.$ac_ext
    67967018 fi
    67977019-echo "$as_me:7744: result: $cf_cv_wint_t" >&5
    6798 +echo "$as_me:8090: result: $cf_cv_wint_t" >&5
     7020+echo "$as_me:8099: result: $cf_cv_wint_t" >&5
    67997021 echo "${ECHO_T}$cf_cv_wint_t" >&6
    68007022 
    68017023 if test "$cf_cv_wint_t" = yes ; then
    6802 @@ -7780,7 +8126,7 @@
     7024@@ -7780,7 +8135,7 @@
    68037025        ;;
    68047026 esac
    68057027 
    68067028-echo "$as_me:7783: checking whether to enable _LP64 definition in curses.h" >&5
    6807 +echo "$as_me:8129: checking whether to enable _LP64 definition in curses.h" >&5
     7029+echo "$as_me:8138: checking whether to enable _LP64 definition in curses.h" >&5
    68087030 echo $ECHO_N "checking whether to enable _LP64 definition in curses.h... $ECHO_C" >&6
    68097031 
    68107032 # Check whether --enable-lp64 or --disable-lp64 was given.
    6811 @@ -7790,7 +8136,7 @@
     7033@@ -7790,7 +8145,7 @@
    68127034 else
    68137035   with_lp64=$default_with_lp64
    68147036 fi;
    68157037-echo "$as_me:7793: result: $with_lp64" >&5
    6816 +echo "$as_me:8139: result: $with_lp64" >&5
     7038+echo "$as_me:8148: result: $with_lp64" >&5
    68177039 echo "${ECHO_T}$with_lp64" >&6
    68187040 
    68197041 if test "$with_lp64" = yes ; then
    6820 @@ -7806,7 +8152,7 @@
     7042@@ -7806,7 +8161,7 @@
    68217043 fi;
    68227044 if test "$enable_largefile" != no; then
    68237045 
    68247046-  echo "$as_me:7809: checking for special C compiler options needed for large files" >&5
    6825 +  echo "$as_me:8155: checking for special C compiler options needed for large files" >&5
     7047+  echo "$as_me:8164: checking for special C compiler options needed for large files" >&5
    68267048 echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6
    68277049 if test "${ac_cv_sys_largefile_CC+set}" = set; then
    68287050   echo $ECHO_N "(cached) $ECHO_C" >&6
    6829 @@ -7818,7 +8164,7 @@
     7051@@ -7818,7 +8173,7 @@
    68307052         # IRIX 6.2 and later do not support large files by default,
    68317053         # so use the C compiler's -n32 option if that helps.
    68327054          cat >conftest.$ac_ext <<_ACEOF
    68337055-#line 7821 "configure"
    6834 +#line 8167 "configure"
     7056+#line 8176 "configure"
    68357057 #include "confdefs.h"
    68367058 #include <sys/types.h>
    68377059  /* Check that off_t can represent 2**63 - 1 correctly.
    6838 @@ -7838,16 +8184,16 @@
     7060@@ -7838,16 +8193,16 @@
    68397061 }
    68407062 _ACEOF
    68417063         rm -f conftest.$ac_objext
    68427064-if { (eval echo "$as_me:7841: \"$ac_compile\"") >&5
    6843 +if { (eval echo "$as_me:8187: \"$ac_compile\"") >&5
     7065+if { (eval echo "$as_me:8196: \"$ac_compile\"") >&5
    68447066   (eval $ac_compile) 2>&5
    68457067   ac_status=$?
    68467068-  echo "$as_me:7844: \$? = $ac_status" >&5
    6847 +  echo "$as_me:8190: \$? = $ac_status" >&5
     7069+  echo "$as_me:8199: \$? = $ac_status" >&5
    68487070   (exit $ac_status); } &&
    68497071          { ac_try='test -s conftest.$ac_objext'
    68507072-  { (eval echo "$as_me:7847: \"$ac_try\"") >&5
    6851 +  { (eval echo "$as_me:8193: \"$ac_try\"") >&5
     7073+  { (eval echo "$as_me:8202: \"$ac_try\"") >&5
    68527074   (eval $ac_try) 2>&5
    68537075   ac_status=$?
    68547076-  echo "$as_me:7850: \$? = $ac_status" >&5
    6855 +  echo "$as_me:8196: \$? = $ac_status" >&5
     7077+  echo "$as_me:8205: \$? = $ac_status" >&5
    68567078   (exit $ac_status); }; }; then
    68577079   break
    68587080 else
    6859 @@ -7857,16 +8203,16 @@
     7081@@ -7857,16 +8212,16 @@
    68607082 rm -f conftest.$ac_objext
    68617083         CC="$CC -n32"
    68627084         rm -f conftest.$ac_objext
    68637085-if { (eval echo "$as_me:7860: \"$ac_compile\"") >&5
    6864 +if { (eval echo "$as_me:8206: \"$ac_compile\"") >&5
     7086+if { (eval echo "$as_me:8215: \"$ac_compile\"") >&5
    68657087   (eval $ac_compile) 2>&5
    68667088   ac_status=$?
    68677089-  echo "$as_me:7863: \$? = $ac_status" >&5
    6868 +  echo "$as_me:8209: \$? = $ac_status" >&5
     7090+  echo "$as_me:8218: \$? = $ac_status" >&5
    68697091   (exit $ac_status); } &&
    68707092          { ac_try='test -s conftest.$ac_objext'
    68717093-  { (eval echo "$as_me:7866: \"$ac_try\"") >&5
    6872 +  { (eval echo "$as_me:8212: \"$ac_try\"") >&5
     7094+  { (eval echo "$as_me:8221: \"$ac_try\"") >&5
    68737095   (eval $ac_try) 2>&5
    68747096   ac_status=$?
    68757097-  echo "$as_me:7869: \$? = $ac_status" >&5
    6876 +  echo "$as_me:8215: \$? = $ac_status" >&5
     7098+  echo "$as_me:8224: \$? = $ac_status" >&5
    68777099   (exit $ac_status); }; }; then
    68787100   ac_cv_sys_largefile_CC=' -n32'; break
    68797101 else
    6880 @@ -7880,13 +8226,13 @@
     7102@@ -7880,13 +8235,13 @@
    68817103        rm -f conftest.$ac_ext
    68827104     fi
    68837105 fi
    68847106-echo "$as_me:7883: result: $ac_cv_sys_largefile_CC" >&5
    6885 +echo "$as_me:8229: result: $ac_cv_sys_largefile_CC" >&5
     7107+echo "$as_me:8238: result: $ac_cv_sys_largefile_CC" >&5
    68867108 echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6
    68877109   if test "$ac_cv_sys_largefile_CC" != no; then
     
    68907112 
    68917113-  echo "$as_me:7889: checking for _FILE_OFFSET_BITS value needed for large files" >&5
    6892 +  echo "$as_me:8235: checking for _FILE_OFFSET_BITS value needed for large files" >&5
     7114+  echo "$as_me:8244: checking for _FILE_OFFSET_BITS value needed for large files" >&5
    68937115 echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6
    68947116 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
    68957117   echo $ECHO_N "(cached) $ECHO_C" >&6
    6896 @@ -7894,7 +8240,7 @@
     7118@@ -7894,7 +8249,7 @@
    68977119   while :; do
    68987120   ac_cv_sys_file_offset_bits=no
    68997121   cat >conftest.$ac_ext <<_ACEOF
    69007122-#line 7897 "configure"
    6901 +#line 8243 "configure"
     7123+#line 8252 "configure"
    69027124 #include "confdefs.h"
    69037125 #include <sys/types.h>
    69047126  /* Check that off_t can represent 2**63 - 1 correctly.
    6905 @@ -7914,16 +8260,16 @@
     7127@@ -7914,16 +8269,16 @@
    69067128 }
    69077129 _ACEOF
    69087130 rm -f conftest.$ac_objext
    69097131-if { (eval echo "$as_me:7917: \"$ac_compile\"") >&5
    6910 +if { (eval echo "$as_me:8263: \"$ac_compile\"") >&5
     7132+if { (eval echo "$as_me:8272: \"$ac_compile\"") >&5
    69117133   (eval $ac_compile) 2>&5
    69127134   ac_status=$?
    69137135-  echo "$as_me:7920: \$? = $ac_status" >&5
    6914 +  echo "$as_me:8266: \$? = $ac_status" >&5
     7136+  echo "$as_me:8275: \$? = $ac_status" >&5
    69157137   (exit $ac_status); } &&
    69167138          { ac_try='test -s conftest.$ac_objext'
    69177139-  { (eval echo "$as_me:7923: \"$ac_try\"") >&5
    6918 +  { (eval echo "$as_me:8269: \"$ac_try\"") >&5
     7140+  { (eval echo "$as_me:8278: \"$ac_try\"") >&5
    69197141   (eval $ac_try) 2>&5
    69207142   ac_status=$?
    69217143-  echo "$as_me:7926: \$? = $ac_status" >&5
    6922 +  echo "$as_me:8272: \$? = $ac_status" >&5
     7144+  echo "$as_me:8281: \$? = $ac_status" >&5
    69237145   (exit $ac_status); }; }; then
    69247146   break
    69257147 else
    6926 @@ -7932,7 +8278,7 @@
     7148@@ -7932,7 +8287,7 @@
    69277149 fi
    69287150 rm -f conftest.$ac_objext conftest.$ac_ext
    69297151   cat >conftest.$ac_ext <<_ACEOF
    69307152-#line 7935 "configure"
    6931 +#line 8281 "configure"
     7153+#line 8290 "configure"
    69327154 #include "confdefs.h"
    69337155 #define _FILE_OFFSET_BITS 64
    69347156 #include <sys/types.h>
    6935 @@ -7953,16 +8299,16 @@
     7157@@ -7953,16 +8308,16 @@
    69367158 }
    69377159 _ACEOF
    69387160 rm -f conftest.$ac_objext
    69397161-if { (eval echo "$as_me:7956: \"$ac_compile\"") >&5
    6940 +if { (eval echo "$as_me:8302: \"$ac_compile\"") >&5
     7162+if { (eval echo "$as_me:8311: \"$ac_compile\"") >&5
    69417163   (eval $ac_compile) 2>&5
    69427164   ac_status=$?
    69437165-  echo "$as_me:7959: \$? = $ac_status" >&5
    6944 +  echo "$as_me:8305: \$? = $ac_status" >&5
     7166+  echo "$as_me:8314: \$? = $ac_status" >&5
    69457167   (exit $ac_status); } &&
    69467168          { ac_try='test -s conftest.$ac_objext'
    69477169-  { (eval echo "$as_me:7962: \"$ac_try\"") >&5
    6948 +  { (eval echo "$as_me:8308: \"$ac_try\"") >&5
     7170+  { (eval echo "$as_me:8317: \"$ac_try\"") >&5
    69497171   (eval $ac_try) 2>&5
    69507172   ac_status=$?
    69517173-  echo "$as_me:7965: \$? = $ac_status" >&5
    6952 +  echo "$as_me:8311: \$? = $ac_status" >&5
     7174+  echo "$as_me:8320: \$? = $ac_status" >&5
    69537175   (exit $ac_status); }; }; then
    69547176   ac_cv_sys_file_offset_bits=64; break
    69557177 else
    6956 @@ -7973,7 +8319,7 @@
     7178@@ -7973,7 +8328,7 @@
    69577179   break
    69587180 done
    69597181 fi
    69607182-echo "$as_me:7976: result: $ac_cv_sys_file_offset_bits" >&5
    6961 +echo "$as_me:8322: result: $ac_cv_sys_file_offset_bits" >&5
     7183+echo "$as_me:8331: result: $ac_cv_sys_file_offset_bits" >&5
    69627184 echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6
    69637185 if test "$ac_cv_sys_file_offset_bits" != no; then
    69647186 
    6965 @@ -7983,7 +8329,7 @@
     7187@@ -7983,7 +8338,7 @@
    69667188 
    69677189 fi
    69687190 rm -f conftest*
    69697191-  echo "$as_me:7986: checking for _LARGE_FILES value needed for large files" >&5
    6970 +  echo "$as_me:8332: checking for _LARGE_FILES value needed for large files" >&5
     7192+  echo "$as_me:8341: checking for _LARGE_FILES value needed for large files" >&5
    69717193 echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6
    69727194 if test "${ac_cv_sys_large_files+set}" = set; then
    69737195   echo $ECHO_N "(cached) $ECHO_C" >&6
    6974 @@ -7991,7 +8337,7 @@
     7196@@ -7991,7 +8346,7 @@
    69757197   while :; do
    69767198   ac_cv_sys_large_files=no
    69777199   cat >conftest.$ac_ext <<_ACEOF
    69787200-#line 7994 "configure"
    6979 +#line 8340 "configure"
     7201+#line 8349 "configure"
    69807202 #include "confdefs.h"
    69817203 #include <sys/types.h>
    69827204  /* Check that off_t can represent 2**63 - 1 correctly.
    6983 @@ -8011,16 +8357,16 @@
     7205@@ -8011,16 +8366,16 @@
    69847206 }
    69857207 _ACEOF
    69867208 rm -f conftest.$ac_objext
    69877209-if { (eval echo "$as_me:8014: \"$ac_compile\"") >&5
    6988 +if { (eval echo "$as_me:8360: \"$ac_compile\"") >&5
     7210+if { (eval echo "$as_me:8369: \"$ac_compile\"") >&5
    69897211   (eval $ac_compile) 2>&5
    69907212   ac_status=$?
    69917213-  echo "$as_me:8017: \$? = $ac_status" >&5
    6992 +  echo "$as_me:8363: \$? = $ac_status" >&5
     7214+  echo "$as_me:8372: \$? = $ac_status" >&5
    69937215   (exit $ac_status); } &&
    69947216          { ac_try='test -s conftest.$ac_objext'
    69957217-  { (eval echo "$as_me:8020: \"$ac_try\"") >&5
    6996 +  { (eval echo "$as_me:8366: \"$ac_try\"") >&5
     7218+  { (eval echo "$as_me:8375: \"$ac_try\"") >&5
    69977219   (eval $ac_try) 2>&5
    69987220   ac_status=$?
    69997221-  echo "$as_me:8023: \$? = $ac_status" >&5
    7000 +  echo "$as_me:8369: \$? = $ac_status" >&5
     7222+  echo "$as_me:8378: \$? = $ac_status" >&5
    70017223   (exit $ac_status); }; }; then
    70027224   break
    70037225 else
    7004 @@ -8029,7 +8375,7 @@
     7226@@ -8029,7 +8384,7 @@
    70057227 fi
    70067228 rm -f conftest.$ac_objext conftest.$ac_ext
    70077229   cat >conftest.$ac_ext <<_ACEOF
    70087230-#line 8032 "configure"
    7009 +#line 8378 "configure"
     7231+#line 8387 "configure"
    70107232 #include "confdefs.h"
    70117233 #define _LARGE_FILES 1
    70127234 #include <sys/types.h>
    7013 @@ -8050,16 +8396,16 @@
     7235@@ -8050,16 +8405,16 @@
    70147236 }
    70157237 _ACEOF
    70167238 rm -f conftest.$ac_objext
    70177239-if { (eval echo "$as_me:8053: \"$ac_compile\"") >&5
    7018 +if { (eval echo "$as_me:8399: \"$ac_compile\"") >&5
     7240+if { (eval echo "$as_me:8408: \"$ac_compile\"") >&5
    70197241   (eval $ac_compile) 2>&5
    70207242   ac_status=$?
    70217243-  echo "$as_me:8056: \$? = $ac_status" >&5
    7022 +  echo "$as_me:8402: \$? = $ac_status" >&5
     7244+  echo "$as_me:8411: \$? = $ac_status" >&5
    70237245   (exit $ac_status); } &&
    70247246          { ac_try='test -s conftest.$ac_objext'
    70257247-  { (eval echo "$as_me:8059: \"$ac_try\"") >&5
    7026 +  { (eval echo "$as_me:8405: \"$ac_try\"") >&5
     7248+  { (eval echo "$as_me:8414: \"$ac_try\"") >&5
    70277249   (eval $ac_try) 2>&5
    70287250   ac_status=$?
    70297251-  echo "$as_me:8062: \$? = $ac_status" >&5
    7030 +  echo "$as_me:8408: \$? = $ac_status" >&5
     7252+  echo "$as_me:8417: \$? = $ac_status" >&5
    70317253   (exit $ac_status); }; }; then
    70327254   ac_cv_sys_large_files=1; break
    70337255 else
    7034 @@ -8070,7 +8416,7 @@
     7256@@ -8070,7 +8425,7 @@
    70357257   break
    70367258 done
    70377259 fi
    70387260-echo "$as_me:8073: result: $ac_cv_sys_large_files" >&5
    7039 +echo "$as_me:8419: result: $ac_cv_sys_large_files" >&5
     7261+echo "$as_me:8428: result: $ac_cv_sys_large_files" >&5
    70407262 echo "${ECHO_T}$ac_cv_sys_large_files" >&6
    70417263 if test "$ac_cv_sys_large_files" != no; then
    70427264 
    7043 @@ -8083,7 +8429,7 @@
     7265@@ -8083,7 +8438,7 @@
    70447266 fi
    70457267 
    70467268     if test "$enable_largefile" != no ; then
    70477269-       echo "$as_me:8086: checking for _LARGEFILE_SOURCE value needed for large files" >&5
    7048 +       echo "$as_me:8432: checking for _LARGEFILE_SOURCE value needed for large files" >&5
     7270+       echo "$as_me:8441: checking for _LARGEFILE_SOURCE value needed for large files" >&5
    70497271 echo $ECHO_N "checking for _LARGEFILE_SOURCE value needed for large files... $ECHO_C" >&6
    70507272 if test "${ac_cv_sys_largefile_source+set}" = set; then
    70517273   echo $ECHO_N "(cached) $ECHO_C" >&6
    7052 @@ -8091,7 +8437,7 @@
     7274@@ -8091,7 +8446,7 @@
    70537275   while :; do
    70547276   ac_cv_sys_largefile_source=no
    70557277   cat >conftest.$ac_ext <<_ACEOF
    70567278-#line 8094 "configure"
    7057 +#line 8440 "configure"
     7279+#line 8449 "configure"
    70587280 #include "confdefs.h"
    70597281 #include <stdio.h>
    70607282 int
    7061 @@ -8103,16 +8449,16 @@
     7283@@ -8103,16 +8458,16 @@
    70627284 }
    70637285 _ACEOF
    70647286 rm -f conftest.$ac_objext
    70657287-if { (eval echo "$as_me:8106: \"$ac_compile\"") >&5
    7066 +if { (eval echo "$as_me:8452: \"$ac_compile\"") >&5
     7288+if { (eval echo "$as_me:8461: \"$ac_compile\"") >&5
    70677289   (eval $ac_compile) 2>&5
    70687290   ac_status=$?
    70697291-  echo "$as_me:8109: \$? = $ac_status" >&5
    7070 +  echo "$as_me:8455: \$? = $ac_status" >&5
     7292+  echo "$as_me:8464: \$? = $ac_status" >&5
    70717293   (exit $ac_status); } &&
    70727294          { ac_try='test -s conftest.$ac_objext'
    70737295-  { (eval echo "$as_me:8112: \"$ac_try\"") >&5
    7074 +  { (eval echo "$as_me:8458: \"$ac_try\"") >&5
     7296+  { (eval echo "$as_me:8467: \"$ac_try\"") >&5
    70757297   (eval $ac_try) 2>&5
    70767298   ac_status=$?
    70777299-  echo "$as_me:8115: \$? = $ac_status" >&5
    7078 +  echo "$as_me:8461: \$? = $ac_status" >&5
     7300+  echo "$as_me:8470: \$? = $ac_status" >&5
    70797301   (exit $ac_status); }; }; then
    70807302   break
    70817303 else
    7082 @@ -8121,7 +8467,7 @@
     7304@@ -8121,7 +8476,7 @@
    70837305 fi
    70847306 rm -f conftest.$ac_objext conftest.$ac_ext
    70857307   cat >conftest.$ac_ext <<_ACEOF
    70867308-#line 8124 "configure"
    7087 +#line 8470 "configure"
     7309+#line 8479 "configure"
    70887310 #include "confdefs.h"
    70897311 #define _LARGEFILE_SOURCE 1
    70907312 #include <stdio.h>
    7091 @@ -8134,16 +8480,16 @@
     7313@@ -8134,16 +8489,16 @@
    70927314 }
    70937315 _ACEOF
    70947316 rm -f conftest.$ac_objext
    70957317-if { (eval echo "$as_me:8137: \"$ac_compile\"") >&5
    7096 +if { (eval echo "$as_me:8483: \"$ac_compile\"") >&5
     7318+if { (eval echo "$as_me:8492: \"$ac_compile\"") >&5
    70977319   (eval $ac_compile) 2>&5
    70987320   ac_status=$?
    70997321-  echo "$as_me:8140: \$? = $ac_status" >&5
    7100 +  echo "$as_me:8486: \$? = $ac_status" >&5
     7322+  echo "$as_me:8495: \$? = $ac_status" >&5
    71017323   (exit $ac_status); } &&
    71027324          { ac_try='test -s conftest.$ac_objext'
    71037325-  { (eval echo "$as_me:8143: \"$ac_try\"") >&5
    7104 +  { (eval echo "$as_me:8489: \"$ac_try\"") >&5
     7326+  { (eval echo "$as_me:8498: \"$ac_try\"") >&5
    71057327   (eval $ac_try) 2>&5
    71067328   ac_status=$?
    71077329-  echo "$as_me:8146: \$? = $ac_status" >&5
    7108 +  echo "$as_me:8492: \$? = $ac_status" >&5
     7330+  echo "$as_me:8501: \$? = $ac_status" >&5
    71097331   (exit $ac_status); }; }; then
    71107332   ac_cv_sys_largefile_source=1; break
    71117333 else
    7112 @@ -8154,7 +8500,7 @@
     7334@@ -8154,7 +8509,7 @@
    71137335   break
    71147336 done
    71157337 fi
    71167338-echo "$as_me:8157: result: $ac_cv_sys_largefile_source" >&5
    7117 +echo "$as_me:8503: result: $ac_cv_sys_largefile_source" >&5
     7339+echo "$as_me:8512: result: $ac_cv_sys_largefile_source" >&5
    71187340 echo "${ECHO_T}$ac_cv_sys_largefile_source" >&6
    71197341 if test "$ac_cv_sys_largefile_source" != no; then
    71207342 
    7121 @@ -8168,13 +8514,13 @@
     7343@@ -8168,13 +8523,13 @@
    71227344 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
    71237345 # in glibc 2.1.3, but that breaks too many other things.
    71247346 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
    71257347-echo "$as_me:8171: checking for fseeko" >&5
    7126 +echo "$as_me:8517: checking for fseeko" >&5
     7348+echo "$as_me:8526: checking for fseeko" >&5
    71277349 echo $ECHO_N "checking for fseeko... $ECHO_C" >&6
    71287350 if test "${ac_cv_func_fseeko+set}" = set; then
     
    71317353   cat >conftest.$ac_ext <<_ACEOF
    71327354-#line 8177 "configure"
    7133 +#line 8523 "configure"
     7355+#line 8532 "configure"
    71347356 #include "confdefs.h"
    71357357 #include <stdio.h>
    71367358 int
    7137 @@ -8186,16 +8532,16 @@
     7359@@ -8186,16 +8541,16 @@
    71387360 }
    71397361 _ACEOF
    71407362 rm -f conftest.$ac_objext conftest$ac_exeext
    71417363-if { (eval echo "$as_me:8189: \"$ac_link\"") >&5
    7142 +if { (eval echo "$as_me:8535: \"$ac_link\"") >&5
     7364+if { (eval echo "$as_me:8544: \"$ac_link\"") >&5
    71437365   (eval $ac_link) 2>&5
    71447366   ac_status=$?
    71457367-  echo "$as_me:8192: \$? = $ac_status" >&5
    7146 +  echo "$as_me:8538: \$? = $ac_status" >&5
     7368+  echo "$as_me:8547: \$? = $ac_status" >&5
    71477369   (exit $ac_status); } &&
    71487370          { ac_try='test -s conftest$ac_exeext'
    71497371-  { (eval echo "$as_me:8195: \"$ac_try\"") >&5
    7150 +  { (eval echo "$as_me:8541: \"$ac_try\"") >&5
     7372+  { (eval echo "$as_me:8550: \"$ac_try\"") >&5
    71517373   (eval $ac_try) 2>&5
    71527374   ac_status=$?
    71537375-  echo "$as_me:8198: \$? = $ac_status" >&5
    7154 +  echo "$as_me:8544: \$? = $ac_status" >&5
     7376+  echo "$as_me:8553: \$? = $ac_status" >&5
    71557377   (exit $ac_status); }; }; then
    71567378   ac_cv_func_fseeko=yes
    71577379 else
    7158 @@ -8205,7 +8551,7 @@
     7380@@ -8205,7 +8560,7 @@
    71597381 fi
    71607382 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    71617383 fi
    71627384-echo "$as_me:8208: result: $ac_cv_func_fseeko" >&5
    7163 +echo "$as_me:8554: result: $ac_cv_func_fseeko" >&5
     7385+echo "$as_me:8563: result: $ac_cv_func_fseeko" >&5
    71647386 echo "${ECHO_T}$ac_cv_func_fseeko" >&6
    71657387 if test $ac_cv_func_fseeko = yes; then
    71667388 
    7167 @@ -8226,14 +8572,14 @@
     7389@@ -8226,14 +8581,14 @@
    71687390        test "$ac_cv_sys_largefile_source" != no && CPPFLAGS="$CPPFLAGS -D_LARGEFILE_SOURCE "
    71697391        test "$ac_cv_sys_file_offset_bits" != no && CPPFLAGS="$CPPFLAGS -D_FILE_OFFSET_BITS=$ac_cv_sys_file_offset_bits "
    71707392 
    71717393-       echo "$as_me:8229: checking whether to use struct dirent64" >&5
    7172 +       echo "$as_me:8575: checking whether to use struct dirent64" >&5
     7394+       echo "$as_me:8584: checking whether to use struct dirent64" >&5
    71737395 echo $ECHO_N "checking whether to use struct dirent64... $ECHO_C" >&6
    71747396 if test "${cf_cv_struct_dirent64+set}" = set; then
     
    71787400                cat >conftest.$ac_ext <<_ACEOF
    71797401-#line 8236 "configure"
    7180 +#line 8582 "configure"
     7402+#line 8591 "configure"
    71817403 #include "confdefs.h"
    71827404 
    71837405 #include <sys/types.h>
    7184 @@ -8254,16 +8600,16 @@
     7406@@ -8254,16 +8609,16 @@
    71857407 }
    71867408 _ACEOF
    71877409 rm -f conftest.$ac_objext
    71887410-if { (eval echo "$as_me:8257: \"$ac_compile\"") >&5
    7189 +if { (eval echo "$as_me:8603: \"$ac_compile\"") >&5
     7411+if { (eval echo "$as_me:8612: \"$ac_compile\"") >&5
    71907412   (eval $ac_compile) 2>&5
    71917413   ac_status=$?
    71927414-  echo "$as_me:8260: \$? = $ac_status" >&5
    7193 +  echo "$as_me:8606: \$? = $ac_status" >&5
     7415+  echo "$as_me:8615: \$? = $ac_status" >&5
    71947416   (exit $ac_status); } &&
    71957417          { ac_try='test -s conftest.$ac_objext'
    71967418-  { (eval echo "$as_me:8263: \"$ac_try\"") >&5
    7197 +  { (eval echo "$as_me:8609: \"$ac_try\"") >&5
     7419+  { (eval echo "$as_me:8618: \"$ac_try\"") >&5
    71987420   (eval $ac_try) 2>&5
    71997421   ac_status=$?
    72007422-  echo "$as_me:8266: \$? = $ac_status" >&5
    7201 +  echo "$as_me:8612: \$? = $ac_status" >&5
     7423+  echo "$as_me:8621: \$? = $ac_status" >&5
    72027424   (exit $ac_status); }; }; then
    72037425   cf_cv_struct_dirent64=yes
    72047426 else
    7205 @@ -8274,7 +8620,7 @@
     7427@@ -8274,7 +8629,7 @@
    72067428 rm -f conftest.$ac_objext conftest.$ac_ext
    72077429 
    72087430 fi
    72097431-echo "$as_me:8277: result: $cf_cv_struct_dirent64" >&5
    7210 +echo "$as_me:8623: result: $cf_cv_struct_dirent64" >&5
     7432+echo "$as_me:8632: result: $cf_cv_struct_dirent64" >&5
    72117433 echo "${ECHO_T}$cf_cv_struct_dirent64" >&6
    72127434        test "$cf_cv_struct_dirent64" = yes && cat >>confdefs.h <<\EOF
    72137435 #define HAVE_STRUCT_DIRENT64 1
    7214 @@ -8283,7 +8629,7 @@
     7436@@ -8283,7 +8638,7 @@
    72157437     fi
    72167438 
    72177439 ###   use option --disable-tparm-varargs to make tparm() conform to X/Open
    72187440-echo "$as_me:8286: checking if you want tparm not to use X/Open fixed-parameter list" >&5
    7219 +echo "$as_me:8632: checking if you want tparm not to use X/Open fixed-parameter list" >&5
     7441+echo "$as_me:8641: checking if you want tparm not to use X/Open fixed-parameter list" >&5
    72207442 echo $ECHO_N "checking if you want tparm not to use X/Open fixed-parameter list... $ECHO_C" >&6
    72217443 
    72227444 # Check whether --enable-tparm-varargs or --disable-tparm-varargs was given.
    7223 @@ -8293,14 +8639,14 @@
     7445@@ -8293,14 +8648,14 @@
    72247446 else
    72257447   with_tparm_varargs=yes
    72267448 fi;
    72277449-echo "$as_me:8296: result: $with_tparm_varargs" >&5
    7228 +echo "$as_me:8642: result: $with_tparm_varargs" >&5
     7450+echo "$as_me:8651: result: $with_tparm_varargs" >&5
    72297451 echo "${ECHO_T}$with_tparm_varargs" >&6
    72307452 NCURSES_TPARM_VARARGS=0
     
    72347456 if test "$with_ticlib" != no ; then
    72357457-echo "$as_me:8303: checking if you want tic library to use explicit dependency on ncurses$LIB_SUFFIX library" >&5
    7236 +echo "$as_me:8649: checking if you want tic library to use explicit dependency on ncurses$LIB_SUFFIX library" >&5
     7458+echo "$as_me:8658: checking if you want tic library to use explicit dependency on ncurses$LIB_SUFFIX library" >&5
    72377459 echo $ECHO_N "checking if you want tic library to use explicit dependency on ncurses$LIB_SUFFIX library... $ECHO_C" >&6
    72387460 
    72397461 # Check whether --enable-tic-depends or --disable-tic-depends was given.
    7240 @@ -8310,14 +8656,14 @@
     7462@@ -8310,14 +8665,14 @@
    72417463 else
    72427464   with_tic_depends=yes
    72437465 fi;
    72447466-echo "$as_me:8313: result: $with_tic_depends" >&5
    7245 +echo "$as_me:8659: result: $with_tic_depends" >&5
     7467+echo "$as_me:8668: result: $with_tic_depends" >&5
    72467468 echo "${ECHO_T}$with_tic_depends" >&6
    72477469 else
     
    72517473 ###   use option --with-bool to override bool's type
    72527474-echo "$as_me:8320: checking for type of bool" >&5
    7253 +echo "$as_me:8666: checking for type of bool" >&5
     7475+echo "$as_me:8675: checking for type of bool" >&5
    72547476 echo $ECHO_N "checking for type of bool... $ECHO_C" >&6
    72557477 
    72567478 # Check whether --with-bool or --without-bool was given.
    7257 @@ -8327,10 +8673,10 @@
     7479@@ -8327,10 +8682,10 @@
    72587480 else
    72597481   NCURSES_BOOL=auto
    72607482 fi;
    72617483-echo "$as_me:8330: result: $NCURSES_BOOL" >&5
    7262 +echo "$as_me:8676: result: $NCURSES_BOOL" >&5
     7484+echo "$as_me:8685: result: $NCURSES_BOOL" >&5
    72637485 echo "${ECHO_T}$NCURSES_BOOL" >&6
    72647486 
    72657487-echo "$as_me:8333: checking for alternate terminal capabilities file" >&5
    7266 +echo "$as_me:8679: checking for alternate terminal capabilities file" >&5
     7488+echo "$as_me:8688: checking for alternate terminal capabilities file" >&5
    72677489 echo $ECHO_N "checking for alternate terminal capabilities file... $ECHO_C" >&6
    72687490 
    72697491 # Check whether --with-caps or --without-caps was given.
    7270 @@ -8341,11 +8687,11 @@
     7492@@ -8341,11 +8696,11 @@
    72717493   TERMINFO_CAPS=Caps
    72727494 fi;
    72737495 test -f "${srcdir}/include/${TERMINFO_CAPS}" || TERMINFO_CAPS=Caps
    72747496-echo "$as_me:8344: result: $TERMINFO_CAPS" >&5
    7275 +echo "$as_me:8690: result: $TERMINFO_CAPS" >&5
     7497+echo "$as_me:8699: result: $TERMINFO_CAPS" >&5
    72767498 echo "${ECHO_T}$TERMINFO_CAPS" >&6
    72777499 
    72787500 ###   use option --with-chtype to override chtype's type
    72797501-echo "$as_me:8348: checking for type of chtype" >&5
    7280 +echo "$as_me:8694: checking for type of chtype" >&5
     7502+echo "$as_me:8703: checking for type of chtype" >&5
    72817503 echo $ECHO_N "checking for type of chtype... $ECHO_C" >&6
    72827504 
    72837505 # Check whether --with-chtype or --without-chtype was given.
    7284 @@ -8355,11 +8701,11 @@
     7506@@ -8355,11 +8710,11 @@
    72857507 else
    72867508   NCURSES_CHTYPE=auto
    72877509 fi;
    72887510-echo "$as_me:8358: result: $NCURSES_CHTYPE" >&5
    7289 +echo "$as_me:8704: result: $NCURSES_CHTYPE" >&5
     7511+echo "$as_me:8713: result: $NCURSES_CHTYPE" >&5
    72907512 echo "${ECHO_T}$NCURSES_CHTYPE" >&6
    72917513 
    72927514 ###   use option --with-ospeed to override ospeed's type
    72937515-echo "$as_me:8362: checking for type of ospeed" >&5
    7294 +echo "$as_me:8708: checking for type of ospeed" >&5
     7516+echo "$as_me:8717: checking for type of ospeed" >&5
    72957517 echo $ECHO_N "checking for type of ospeed... $ECHO_C" >&6
    72967518 
    72977519 # Check whether --with-ospeed or --without-ospeed was given.
    7298 @@ -8369,11 +8715,11 @@
     7520@@ -8369,11 +8724,11 @@
    72997521 else
    73007522   NCURSES_OSPEED=short
    73017523 fi;
    73027524-echo "$as_me:8372: result: $NCURSES_OSPEED" >&5
    7303 +echo "$as_me:8718: result: $NCURSES_OSPEED" >&5
     7525+echo "$as_me:8727: result: $NCURSES_OSPEED" >&5
    73047526 echo "${ECHO_T}$NCURSES_OSPEED" >&6
    73057527 
    73067528 ###   use option --with-mmask-t to override mmask_t's type
    73077529-echo "$as_me:8376: checking for type of mmask_t" >&5
    7308 +echo "$as_me:8722: checking for type of mmask_t" >&5
     7530+echo "$as_me:8731: checking for type of mmask_t" >&5
    73097531 echo $ECHO_N "checking for type of mmask_t... $ECHO_C" >&6
    73107532 
    73117533 # Check whether --with-mmask-t or --without-mmask-t was given.
    7312 @@ -8383,11 +8729,11 @@
     7534@@ -8383,11 +8738,11 @@
    73137535 else
    73147536   NCURSES_MMASK_T=auto
    73157537 fi;
    73167538-echo "$as_me:8386: result: $NCURSES_MMASK_T" >&5
    7317 +echo "$as_me:8732: result: $NCURSES_MMASK_T" >&5
     7539+echo "$as_me:8741: result: $NCURSES_MMASK_T" >&5
    73187540 echo "${ECHO_T}$NCURSES_MMASK_T" >&6
    73197541 
    73207542 ### Enable compiling-in rcs id's
    73217543-echo "$as_me:8390: checking if RCS identifiers should be compiled-in" >&5
    7322 +echo "$as_me:8736: checking if RCS identifiers should be compiled-in" >&5
     7544+echo "$as_me:8745: checking if RCS identifiers should be compiled-in" >&5
    73237545 echo $ECHO_N "checking if RCS identifiers should be compiled-in... $ECHO_C" >&6
    73247546 
    73257547 # Check whether --with-rcs-ids or --without-rcs-ids was given.
    7326 @@ -8397,7 +8743,7 @@
     7548@@ -8397,7 +8752,7 @@
    73277549 else
    73287550   with_rcs_ids=no
    73297551 fi;
    73307552-echo "$as_me:8400: result: $with_rcs_ids" >&5
    7331 +echo "$as_me:8746: result: $with_rcs_ids" >&5
     7553+echo "$as_me:8755: result: $with_rcs_ids" >&5
    73327554 echo "${ECHO_T}$with_rcs_ids" >&6
    73337555 test "$with_rcs_ids" = yes && cat >>confdefs.h <<\EOF
    73347556 #define USE_RCS_IDS 1
    7335 @@ -8405,7 +8751,7 @@
     7557@@ -8405,7 +8760,7 @@
    73367558 
    73377559 ###############################################################################
    73387560 
    73397561-echo "$as_me:8408: checking format of man-pages" >&5
    7340 +echo "$as_me:8754: checking format of man-pages" >&5
     7562+echo "$as_me:8763: checking format of man-pages" >&5
    73417563 echo $ECHO_N "checking format of man-pages... $ECHO_C" >&6
    73427564 
    73437565 # Check whether --with-manpage-format or --without-manpage-format was given.
    7344 @@ -8433,7 +8779,7 @@
     7566@@ -8433,7 +8788,7 @@
    73457567   cf_catonly=yes
    73467568   cf_example=date
     
    73517573     test -z "$cf_dir" && cf_dir=/usr/man
    73527574     for cf_name in $cf_dir/man*/$cf_example.[01]* $cf_dir/cat*/$cf_example.[01]* $cf_dir/man*/$cf_example $cf_dir/cat*/$cf_example
    7353 @@ -8494,14 +8840,14 @@
     7575@@ -8494,14 +8849,14 @@
    73547576   ;;
    73557577 esac
    73567578 
    73577579-echo "$as_me:8497: result: $MANPAGE_FORMAT" >&5
    7358 +echo "$as_me:8843: result: $MANPAGE_FORMAT" >&5
     7580+echo "$as_me:8852: result: $MANPAGE_FORMAT" >&5
    73597581 echo "${ECHO_T}$MANPAGE_FORMAT" >&6
    73607582 if test -n "$cf_unknown" ; then
    73617583-  { echo "$as_me:8500: WARNING: Unexpected manpage-format $cf_unknown" >&5
    7362 +  { echo "$as_me:8846: WARNING: Unexpected manpage-format $cf_unknown" >&5
     7584+  { echo "$as_me:8855: WARNING: Unexpected manpage-format $cf_unknown" >&5
    73637585 echo "$as_me: WARNING: Unexpected manpage-format $cf_unknown" >&2;}
    73647586 fi
    73657587 
    73667588-echo "$as_me:8504: checking for manpage renaming" >&5
    7367 +echo "$as_me:8850: checking for manpage renaming" >&5
     7589+echo "$as_me:8859: checking for manpage renaming" >&5
    73687590 echo $ECHO_N "checking for manpage renaming... $ECHO_C" >&6
    73697591 
    73707592 # Check whether --with-manpage-renames or --without-manpage-renames was given.
    7371 @@ -8529,7 +8875,7 @@
     7593@@ -8529,7 +8884,7 @@
    73727594   if test -f $srcdir/man/$MANPAGE_RENAMES ; then
    73737595     MANPAGE_RENAMES=`cd $srcdir/man && pwd`/$MANPAGE_RENAMES
    73747596   elif test ! -f $MANPAGE_RENAMES ; then
    73757597-    { { echo "$as_me:8532: error: not a filename: $MANPAGE_RENAMES" >&5
    7376 +    { { echo "$as_me:8878: error: not a filename: $MANPAGE_RENAMES" >&5
     7598+    { { echo "$as_me:8887: error: not a filename: $MANPAGE_RENAMES" >&5
    73777599 echo "$as_me: error: not a filename: $MANPAGE_RENAMES" >&2;}
    73787600    { (exit 1); exit 1; }; }
    73797601   fi
    7380 @@ -8543,10 +8889,10 @@
     7602@@ -8543,10 +8898,10 @@
    73817603   fi
    73827604 fi
    73837605 
    73847606-echo "$as_me:8546: result: $MANPAGE_RENAMES" >&5
    7385 +echo "$as_me:8892: result: $MANPAGE_RENAMES" >&5
     7607+echo "$as_me:8901: result: $MANPAGE_RENAMES" >&5
    73867608 echo "${ECHO_T}$MANPAGE_RENAMES" >&6
    73877609 
    73887610-echo "$as_me:8549: checking if manpage aliases will be installed" >&5
    7389 +echo "$as_me:8895: checking if manpage aliases will be installed" >&5
     7611+echo "$as_me:8904: checking if manpage aliases will be installed" >&5
    73907612 echo $ECHO_N "checking if manpage aliases will be installed... $ECHO_C" >&6
    73917613 
    73927614 # Check whether --with-manpage-aliases or --without-manpage-aliases was given.
    7393 @@ -8557,7 +8903,7 @@
     7615@@ -8557,7 +8912,7 @@
    73947616   MANPAGE_ALIASES=yes
    73957617 fi;
    73967618 
    73977619-echo "$as_me:8560: result: $MANPAGE_ALIASES" >&5
    7398 +echo "$as_me:8906: result: $MANPAGE_ALIASES" >&5
     7620+echo "$as_me:8915: result: $MANPAGE_ALIASES" >&5
    73997621 echo "${ECHO_T}$MANPAGE_ALIASES" >&6
    74007622 
    74017623 if test "$LN_S" = "ln -s"; then
    7402 @@ -8568,7 +8914,7 @@
     7624@@ -8568,7 +8923,7 @@
    74037625 
    74047626 MANPAGE_SYMLINKS=no
    74057627 if test "$MANPAGE_ALIASES" = yes ; then
    74067628-echo "$as_me:8571: checking if manpage symlinks should be used" >&5
    7407 +echo "$as_me:8917: checking if manpage symlinks should be used" >&5
     7629+echo "$as_me:8926: checking if manpage symlinks should be used" >&5
    74087630 echo $ECHO_N "checking if manpage symlinks should be used... $ECHO_C" >&6
    74097631 
    74107632 # Check whether --with-manpage-symlinks or --without-manpage-symlinks was given.
    7411 @@ -8581,17 +8927,17 @@
     7633@@ -8581,17 +8936,17 @@
    74127634 
    74137635 if test "$$cf_use_symlinks" = no; then
    74147636 if test "$MANPAGE_SYMLINKS" = yes ; then
    74157637-       { echo "$as_me:8584: WARNING: cannot make symlinks" >&5
    7416 +       { echo "$as_me:8930: WARNING: cannot make symlinks" >&5
     7638+       { echo "$as_me:8939: WARNING: cannot make symlinks" >&5
    74177639 echo "$as_me: WARNING: cannot make symlinks" >&2;}
    74187640        MANPAGE_SYMLINKS=no
     
    74217643 
    74227644-echo "$as_me:8590: result: $MANPAGE_SYMLINKS" >&5
    7423 +echo "$as_me:8936: result: $MANPAGE_SYMLINKS" >&5
     7645+echo "$as_me:8945: result: $MANPAGE_SYMLINKS" >&5
    74247646 echo "${ECHO_T}$MANPAGE_SYMLINKS" >&6
    74257647 fi
    74267648 
    74277649-echo "$as_me:8594: checking for manpage tbl" >&5
    7428 +echo "$as_me:8940: checking for manpage tbl" >&5
     7650+echo "$as_me:8949: checking for manpage tbl" >&5
    74297651 echo $ECHO_N "checking for manpage tbl... $ECHO_C" >&6
    74307652 
    74317653 # Check whether --with-manpage-tbl or --without-manpage-tbl was given.
    7432 @@ -8602,7 +8948,7 @@
     7654@@ -8602,7 +8957,7 @@
    74337655   MANPAGE_TBL=no
    74347656 fi;
    74357657 
    74367658-echo "$as_me:8605: result: $MANPAGE_TBL" >&5
    7437 +echo "$as_me:8951: result: $MANPAGE_TBL" >&5
     7659+echo "$as_me:8960: result: $MANPAGE_TBL" >&5
    74387660 echo "${ECHO_T}$MANPAGE_TBL" >&6
    74397661 
    74407662   if test "$prefix" = "NONE" ; then
    7441 @@ -8718,7 +9064,7 @@
     7663@@ -8718,7 +9073,7 @@
    74427664                s,@NCURSES_OSPEED@,\$NCURSES_OSPEED,g
    74437665 CF_EOF
     
    74487670                cf_NAME=`echo "$cf_name" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
    74497671                cf_name=`echo $cf_name|sed "$program_transform_name"`
    7450 @@ -8913,7 +9259,7 @@
     7672@@ -8913,7 +9268,7 @@
    74517673 ###############################################################################
    74527674 
    74537675 ### Note that some functions (such as const) are normally disabled anyway.
    74547676-echo "$as_me:8916: checking if you want to build with function extensions" >&5
    7455 +echo "$as_me:9262: checking if you want to build with function extensions" >&5
     7677+echo "$as_me:9271: checking if you want to build with function extensions" >&5
    74567678 echo $ECHO_N "checking if you want to build with function extensions... $ECHO_C" >&6
    74577679 
    74587680 # Check whether --enable-ext-funcs or --disable-ext-funcs was given.
    7459 @@ -8923,7 +9269,7 @@
     7681@@ -8923,7 +9278,7 @@
    74607682 else
    74617683   with_ext_funcs=yes
    74627684 fi;
    74637685-echo "$as_me:8926: result: $with_ext_funcs" >&5
    7464 +echo "$as_me:9272: result: $with_ext_funcs" >&5
     7686+echo "$as_me:9281: result: $with_ext_funcs" >&5
    74657687 echo "${ECHO_T}$with_ext_funcs" >&6
    74667688 if test "$with_ext_funcs" = yes ; then
    74677689        NCURSES_EXT_FUNCS=1
    7468 @@ -8955,12 +9301,38 @@
     7690@@ -8955,12 +9310,38 @@
    74697691 #define NCURSES_EXT_FUNCS 1
    74707692 EOF
     
    74767698+fi
    74777699+
    7478 +echo "$as_me:9310: checking if you want to build with experimental SCREEN extensions" >&5
     7700+echo "$as_me:9319: checking if you want to build with experimental SCREEN extensions" >&5
    74797701+echo $ECHO_N "checking if you want to build with experimental SCREEN extensions... $ECHO_C" >&6
    74807702+
     
    74867708+  with_sp_funcs=no
    74877709+fi;
    7488 +echo "$as_me:9320: result: $with_sp_funcs" >&5
     7710+echo "$as_me:9329: result: $with_sp_funcs" >&5
    74897711+echo "${ECHO_T}$with_sp_funcs" >&6
    74907712+if test "$with_sp_funcs" = yes ; then
     
    75027724 ###   use option --enable-const to turn on use of const beyond that in XSI.
    75037725-echo "$as_me:8963: checking for extended use of const keyword" >&5
    7504 +echo "$as_me:9335: checking for extended use of const keyword" >&5
     7726+echo "$as_me:9344: checking for extended use of const keyword" >&5
    75057727 echo $ECHO_N "checking for extended use of const keyword... $ECHO_C" >&6
    75067728 
    75077729 # Check whether --enable-const or --disable-const was given.
    7508 @@ -8970,7 +9342,7 @@
     7730@@ -8970,7 +9351,7 @@
    75097731 else
    75107732   with_ext_const=no
    75117733 fi;
    75127734-echo "$as_me:8973: result: $with_ext_const" >&5
    7513 +echo "$as_me:9345: result: $with_ext_const" >&5
     7735+echo "$as_me:9354: result: $with_ext_const" >&5
    75147736 echo "${ECHO_T}$with_ext_const" >&6
    75157737 NCURSES_CONST='/*nothing*/'
    75167738 if test "$with_ext_const" = yes ; then
    7517 @@ -8978,7 +9350,7 @@
     7739@@ -8978,7 +9359,7 @@
    75187740 fi
    75197741 
    75207742 ###   use option --enable-ext-colors to turn on use of colors beyond 16.
    75217743-echo "$as_me:8981: checking if you want to use extended colors" >&5
    7522 +echo "$as_me:9353: checking if you want to use extended colors" >&5
     7744+echo "$as_me:9362: checking if you want to use extended colors" >&5
    75237745 echo $ECHO_N "checking if you want to use extended colors... $ECHO_C" >&6
    75247746 
    75257747 # Check whether --enable-ext-colors or --disable-ext-colors was given.
    7526 @@ -8988,12 +9360,12 @@
     7748@@ -8988,12 +9369,12 @@
    75277749 else
    75287750   with_ext_colors=no
    75297751 fi;
    75307752-echo "$as_me:8991: result: $with_ext_colors" >&5
    7531 +echo "$as_me:9363: result: $with_ext_colors" >&5
     7753+echo "$as_me:9372: result: $with_ext_colors" >&5
    75327754 echo "${ECHO_T}$with_ext_colors" >&6
    75337755 NCURSES_EXT_COLORS=0
     
    75357757        if test "$with_widec" != yes ; then
    75367758-               { { echo "$as_me:8996: error: This option applies only to wide-character library" >&5
    7537 +               { { echo "$as_me:9368: error: This option applies only to wide-character library" >&5
     7759+               { { echo "$as_me:9377: error: This option applies only to wide-character library" >&5
    75387760 echo "$as_me: error: This option applies only to wide-character library" >&2;}
    75397761    { (exit 1); exit 1; }; }
    75407762        else
    7541 @@ -9004,7 +9376,7 @@
     7763@@ -9004,7 +9385,7 @@
    75427764        5.*)
    75437765                cf_cv_rel_version=6.0
    75447766                cf_cv_abi_version=6
    75457767-               { echo "$as_me:9007: WARNING: Overriding ABI version to $cf_cv_abi_version" >&5
    7546 +               { echo "$as_me:9379: WARNING: Overriding ABI version to $cf_cv_abi_version" >&5
     7768+               { echo "$as_me:9388: WARNING: Overriding ABI version to $cf_cv_abi_version" >&5
    75477769 echo "$as_me: WARNING: Overriding ABI version to $cf_cv_abi_version" >&2;}
    75487770                ;;
    75497771        esac
    7550 @@ -9019,7 +9391,7 @@
     7772@@ -9019,7 +9400,7 @@
    75517773 fi
    75527774 
    75537775 ###   use option --enable-ext-mouse to modify coding to support 5-button mice
    75547776-echo "$as_me:9022: checking if you want to use extended mouse encoding" >&5
    7555 +echo "$as_me:9394: checking if you want to use extended mouse encoding" >&5
     7777+echo "$as_me:9403: checking if you want to use extended mouse encoding" >&5
    75567778 echo $ECHO_N "checking if you want to use extended mouse encoding... $ECHO_C" >&6
    75577779 
    75587780 # Check whether --enable-ext-mouse or --disable-ext-mouse was given.
    7559 @@ -9029,7 +9401,7 @@
     7781@@ -9029,7 +9410,7 @@
    75607782 else
    75617783   with_ext_mouse=no
    75627784 fi;
    75637785-echo "$as_me:9032: result: $with_ext_mouse" >&5
    7564 +echo "$as_me:9404: result: $with_ext_mouse" >&5
     7786+echo "$as_me:9413: result: $with_ext_mouse" >&5
    75657787 echo "${ECHO_T}$with_ext_mouse" >&6
    75667788 NCURSES_MOUSE_VERSION=1
    75677789 if test "$with_ext_mouse" = yes ; then
    7568 @@ -9040,7 +9412,7 @@
     7790@@ -9040,7 +9421,7 @@
    75697791        5.*)
    75707792                cf_cv_rel_version=6.0
    75717793                cf_cv_abi_version=6
    75727794-               { echo "$as_me:9043: WARNING: Overriding ABI version to $cf_cv_abi_version" >&5
    7573 +               { echo "$as_me:9415: WARNING: Overriding ABI version to $cf_cv_abi_version" >&5
     7795+               { echo "$as_me:9424: WARNING: Overriding ABI version to $cf_cv_abi_version" >&5
    75747796 echo "$as_me: WARNING: Overriding ABI version to $cf_cv_abi_version" >&2;}
    75757797                ;;
    75767798        esac
    7577 @@ -9048,7 +9420,7 @@
     7799@@ -9048,7 +9429,7 @@
    75787800 
    75797801 fi
    75807802 
    75817803-echo "$as_me:9051: checking if you want \$NCURSES_NO_PADDING code" >&5
    7582 +echo "$as_me:9423: checking if you want \$NCURSES_NO_PADDING code" >&5
     7804+echo "$as_me:9432: checking if you want \$NCURSES_NO_PADDING code" >&5
    75837805 echo $ECHO_N "checking if you want \$NCURSES_NO_PADDING code... $ECHO_C" >&6
    75847806 
    75857807 # Check whether --enable-no-padding or --disable-no-padding was given.
    7586 @@ -9058,19 +9430,19 @@
     7808@@ -9058,19 +9439,19 @@
    75877809 else
    75887810   with_no_padding=$with_ext_funcs
    75897811 fi;
    75907812-echo "$as_me:9061: result: $with_no_padding" >&5
    7591 +echo "$as_me:9433: result: $with_no_padding" >&5
     7813+echo "$as_me:9442: result: $with_no_padding" >&5
    75927814 echo "${ECHO_T}$with_no_padding" >&6
    75937815 test "$with_no_padding" = yes && cat >>confdefs.h <<\EOF
     
    75967818 
    75977819-echo "$as_me:9067: checking for ANSI C header files" >&5
    7598 +echo "$as_me:9439: checking for ANSI C header files" >&5
     7820+echo "$as_me:9448: checking for ANSI C header files" >&5
    75997821 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
    76007822 if test "${ac_cv_header_stdc+set}" = set; then
     
    76037825   cat >conftest.$ac_ext <<_ACEOF
    76047826-#line 9073 "configure"
    7605 +#line 9445 "configure"
     7827+#line 9454 "configure"
    76067828 #include "confdefs.h"
    76077829 #include <stdlib.h>
    76087830 #include <stdarg.h>
    7609 @@ -9078,13 +9450,13 @@
     7831@@ -9078,13 +9459,13 @@
    76107832 #include <float.h>
    76117833 
    76127834 _ACEOF
    76137835-if { (eval echo "$as_me:9081: \"$ac_cpp conftest.$ac_ext\"") >&5
    7614 +if { (eval echo "$as_me:9453: \"$ac_cpp conftest.$ac_ext\"") >&5
     7836+if { (eval echo "$as_me:9462: \"$ac_cpp conftest.$ac_ext\"") >&5
    76157837   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    76167838   ac_status=$?
     
    76197841   cat conftest.err >&5
    76207842-  echo "$as_me:9087: \$? = $ac_status" >&5
    7621 +  echo "$as_me:9459: \$? = $ac_status" >&5
     7843+  echo "$as_me:9468: \$? = $ac_status" >&5
    76227844   (exit $ac_status); } >/dev/null; then
    76237845   if test -s conftest.err; then
    76247846     ac_cpp_err=$ac_c_preproc_warn_flag
    7625 @@ -9106,7 +9478,7 @@
     7847@@ -9106,7 +9487,7 @@
    76267848 if test $ac_cv_header_stdc = yes; then
    76277849   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
    76287850   cat >conftest.$ac_ext <<_ACEOF
    76297851-#line 9109 "configure"
    7630 +#line 9481 "configure"
     7852+#line 9490 "configure"
    76317853 #include "confdefs.h"
    76327854 #include <string.h>
    76337855 
    7634 @@ -9124,7 +9496,7 @@
     7856@@ -9124,7 +9505,7 @@
    76357857 if test $ac_cv_header_stdc = yes; then
    76367858   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
    76377859   cat >conftest.$ac_ext <<_ACEOF
    76387860-#line 9127 "configure"
    7639 +#line 9499 "configure"
     7861+#line 9508 "configure"
    76407862 #include "confdefs.h"
    76417863 #include <stdlib.h>
    76427864 
    7643 @@ -9145,7 +9517,7 @@
     7865@@ -9145,7 +9526,7 @@
    76447866   :
    76457867 else
    76467868   cat >conftest.$ac_ext <<_ACEOF
    76477869-#line 9148 "configure"
    7648 +#line 9520 "configure"
     7870+#line 9529 "configure"
    76497871 #include "confdefs.h"
    76507872 #include <ctype.h>
    76517873 #if ((' ' & 0x0FF) == 0x020)
    7652 @@ -9171,15 +9543,15 @@
     7874@@ -9171,15 +9552,15 @@
    76537875 }
    76547876 _ACEOF
    76557877 rm -f conftest$ac_exeext
    76567878-if { (eval echo "$as_me:9174: \"$ac_link\"") >&5
    7657 +if { (eval echo "$as_me:9546: \"$ac_link\"") >&5
     7879+if { (eval echo "$as_me:9555: \"$ac_link\"") >&5
    76587880   (eval $ac_link) 2>&5
    76597881   ac_status=$?
    76607882-  echo "$as_me:9177: \$? = $ac_status" >&5
    7661 +  echo "$as_me:9549: \$? = $ac_status" >&5
     7883+  echo "$as_me:9558: \$? = $ac_status" >&5
    76627884   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    76637885-  { (eval echo "$as_me:9179: \"$ac_try\"") >&5
    7664 +  { (eval echo "$as_me:9551: \"$ac_try\"") >&5
     7886+  { (eval echo "$as_me:9560: \"$ac_try\"") >&5
    76657887   (eval $ac_try) 2>&5
    76667888   ac_status=$?
    76677889-  echo "$as_me:9182: \$? = $ac_status" >&5
    7668 +  echo "$as_me:9554: \$? = $ac_status" >&5
     7890+  echo "$as_me:9563: \$? = $ac_status" >&5
    76697891   (exit $ac_status); }; }; then
    76707892   :
    76717893 else
    7672 @@ -9192,7 +9564,7 @@
     7894@@ -9192,7 +9573,7 @@
    76737895 fi
    76747896 fi
    76757897 fi
    76767898-echo "$as_me:9195: result: $ac_cv_header_stdc" >&5
    7677 +echo "$as_me:9567: result: $ac_cv_header_stdc" >&5
     7899+echo "$as_me:9576: result: $ac_cv_header_stdc" >&5
    76787900 echo "${ECHO_T}$ac_cv_header_stdc" >&6
    76797901 if test $ac_cv_header_stdc = yes; then
    76807902 
    7681 @@ -9208,28 +9580,28 @@
     7903@@ -9208,28 +9589,28 @@
    76827904                   inttypes.h stdint.h unistd.h
    76837905 do
    76847906 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
    76857907-echo "$as_me:9211: checking for $ac_header" >&5
    7686 +echo "$as_me:9583: checking for $ac_header" >&5
     7908+echo "$as_me:9592: checking for $ac_header" >&5
    76877909 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
    76887910 if eval "test \"\${$as_ac_Header+set}\" = set"; then
     
    76917913   cat >conftest.$ac_ext <<_ACEOF
    76927914-#line 9217 "configure"
    7693 +#line 9589 "configure"
     7915+#line 9598 "configure"
    76947916 #include "confdefs.h"
    76957917 $ac_includes_default
     
    76987920 rm -f conftest.$ac_objext
    76997921-if { (eval echo "$as_me:9223: \"$ac_compile\"") >&5
    7700 +if { (eval echo "$as_me:9595: \"$ac_compile\"") >&5
     7922+if { (eval echo "$as_me:9604: \"$ac_compile\"") >&5
    77017923   (eval $ac_compile) 2>&5
    77027924   ac_status=$?
    77037925-  echo "$as_me:9226: \$? = $ac_status" >&5
    7704 +  echo "$as_me:9598: \$? = $ac_status" >&5
     7926+  echo "$as_me:9607: \$? = $ac_status" >&5
    77057927   (exit $ac_status); } &&
    77067928          { ac_try='test -s conftest.$ac_objext'
    77077929-  { (eval echo "$as_me:9229: \"$ac_try\"") >&5
    7708 +  { (eval echo "$as_me:9601: \"$ac_try\"") >&5
     7930+  { (eval echo "$as_me:9610: \"$ac_try\"") >&5
    77097931   (eval $ac_try) 2>&5
    77107932   ac_status=$?
    77117933-  echo "$as_me:9232: \$? = $ac_status" >&5
    7712 +  echo "$as_me:9604: \$? = $ac_status" >&5
     7934+  echo "$as_me:9613: \$? = $ac_status" >&5
    77137935   (exit $ac_status); }; }; then
    77147936   eval "$as_ac_Header=yes"
    77157937 else
    7716 @@ -9239,7 +9611,7 @@
     7938@@ -9239,7 +9620,7 @@
    77177939 fi
    77187940 rm -f conftest.$ac_objext conftest.$ac_ext
    77197941 fi
    77207942-echo "$as_me:9242: result: `eval echo '${'$as_ac_Header'}'`" >&5
    7721 +echo "$as_me:9614: result: `eval echo '${'$as_ac_Header'}'`" >&5
     7943+echo "$as_me:9623: result: `eval echo '${'$as_ac_Header'}'`" >&5
    77227944 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
    77237945 if test `eval echo '${'$as_ac_Header'}'` = yes; then
    77247946   cat >>confdefs.h <<EOF
    7725 @@ -9249,13 +9621,13 @@
     7947@@ -9249,13 +9630,13 @@
    77267948 fi
    77277949 done
    77287950 
    77297951-echo "$as_me:9252: checking for signed char" >&5
    7730 +echo "$as_me:9624: checking for signed char" >&5
     7952+echo "$as_me:9633: checking for signed char" >&5
    77317953 echo $ECHO_N "checking for signed char... $ECHO_C" >&6
    77327954 if test "${ac_cv_type_signed_char+set}" = set; then
     
    77357957   cat >conftest.$ac_ext <<_ACEOF
    77367958-#line 9258 "configure"
    7737 +#line 9630 "configure"
     7959+#line 9639 "configure"
    77387960 #include "confdefs.h"
    77397961 $ac_includes_default
    77407962 int
    7741 @@ -9270,16 +9642,16 @@
     7963@@ -9270,16 +9651,16 @@
    77427964 }
    77437965 _ACEOF
    77447966 rm -f conftest.$ac_objext
    77457967-if { (eval echo "$as_me:9273: \"$ac_compile\"") >&5
    7746 +if { (eval echo "$as_me:9645: \"$ac_compile\"") >&5
     7968+if { (eval echo "$as_me:9654: \"$ac_compile\"") >&5
    77477969   (eval $ac_compile) 2>&5
    77487970   ac_status=$?
    77497971-  echo "$as_me:9276: \$? = $ac_status" >&5
    7750 +  echo "$as_me:9648: \$? = $ac_status" >&5
     7972+  echo "$as_me:9657: \$? = $ac_status" >&5
    77517973   (exit $ac_status); } &&
    77527974          { ac_try='test -s conftest.$ac_objext'
    77537975-  { (eval echo "$as_me:9279: \"$ac_try\"") >&5
    7754 +  { (eval echo "$as_me:9651: \"$ac_try\"") >&5
     7976+  { (eval echo "$as_me:9660: \"$ac_try\"") >&5
    77557977   (eval $ac_try) 2>&5
    77567978   ac_status=$?
    77577979-  echo "$as_me:9282: \$? = $ac_status" >&5
    7758 +  echo "$as_me:9654: \$? = $ac_status" >&5
     7980+  echo "$as_me:9663: \$? = $ac_status" >&5
    77597981   (exit $ac_status); }; }; then
    77607982   ac_cv_type_signed_char=yes
    77617983 else
    7762 @@ -9289,10 +9661,10 @@
     7984@@ -9289,10 +9670,10 @@
    77637985 fi
    77647986 rm -f conftest.$ac_objext conftest.$ac_ext
    77657987 fi
    77667988-echo "$as_me:9292: result: $ac_cv_type_signed_char" >&5
    7767 +echo "$as_me:9664: result: $ac_cv_type_signed_char" >&5
     7989+echo "$as_me:9673: result: $ac_cv_type_signed_char" >&5
    77687990 echo "${ECHO_T}$ac_cv_type_signed_char" >&6
    77697991 
    77707992-echo "$as_me:9295: checking size of signed char" >&5
    7771 +echo "$as_me:9667: checking size of signed char" >&5
     7993+echo "$as_me:9676: checking size of signed char" >&5
    77727994 echo $ECHO_N "checking size of signed char... $ECHO_C" >&6
    77737995 if test "${ac_cv_sizeof_signed_char+set}" = set; then
    77747996   echo $ECHO_N "(cached) $ECHO_C" >&6
    7775 @@ -9301,7 +9673,7 @@
     7997@@ -9301,7 +9682,7 @@
    77767998   if test "$cross_compiling" = yes; then
    77777999   # Depending upon the size, compute the lo and hi bounds.
    77788000 cat >conftest.$ac_ext <<_ACEOF
    77798001-#line 9304 "configure"
    7780 +#line 9676 "configure"
     8002+#line 9685 "configure"
    77818003 #include "confdefs.h"
    77828004 $ac_includes_default
    77838005 int
    7784 @@ -9313,21 +9685,21 @@
     8006@@ -9313,21 +9694,21 @@
    77858007 }
    77868008 _ACEOF
    77878009 rm -f conftest.$ac_objext
    77888010-if { (eval echo "$as_me:9316: \"$ac_compile\"") >&5
    7789 +if { (eval echo "$as_me:9688: \"$ac_compile\"") >&5
     8011+if { (eval echo "$as_me:9697: \"$ac_compile\"") >&5
    77908012   (eval $ac_compile) 2>&5
    77918013   ac_status=$?
    77928014-  echo "$as_me:9319: \$? = $ac_status" >&5
    7793 +  echo "$as_me:9691: \$? = $ac_status" >&5
     8015+  echo "$as_me:9700: \$? = $ac_status" >&5
    77948016   (exit $ac_status); } &&
    77958017          { ac_try='test -s conftest.$ac_objext'
    77968018-  { (eval echo "$as_me:9322: \"$ac_try\"") >&5
    7797 +  { (eval echo "$as_me:9694: \"$ac_try\"") >&5
     8019+  { (eval echo "$as_me:9703: \"$ac_try\"") >&5
    77988020   (eval $ac_try) 2>&5
    77998021   ac_status=$?
    78008022-  echo "$as_me:9325: \$? = $ac_status" >&5
    7801 +  echo "$as_me:9697: \$? = $ac_status" >&5
     8023+  echo "$as_me:9706: \$? = $ac_status" >&5
    78028024   (exit $ac_status); }; }; then
    78038025   ac_lo=0 ac_mid=0
     
    78058027     cat >conftest.$ac_ext <<_ACEOF
    78068028-#line 9330 "configure"
    7807 +#line 9702 "configure"
     8029+#line 9711 "configure"
    78088030 #include "confdefs.h"
    78098031 $ac_includes_default
    78108032 int
    7811 @@ -9339,16 +9711,16 @@
     8033@@ -9339,16 +9720,16 @@
    78128034 }
    78138035 _ACEOF
    78148036 rm -f conftest.$ac_objext
    78158037-if { (eval echo "$as_me:9342: \"$ac_compile\"") >&5
    7816 +if { (eval echo "$as_me:9714: \"$ac_compile\"") >&5
     8038+if { (eval echo "$as_me:9723: \"$ac_compile\"") >&5
    78178039   (eval $ac_compile) 2>&5
    78188040   ac_status=$?
    78198041-  echo "$as_me:9345: \$? = $ac_status" >&5
    7820 +  echo "$as_me:9717: \$? = $ac_status" >&5
     8042+  echo "$as_me:9726: \$? = $ac_status" >&5
    78218043   (exit $ac_status); } &&
    78228044          { ac_try='test -s conftest.$ac_objext'
    78238045-  { (eval echo "$as_me:9348: \"$ac_try\"") >&5
    7824 +  { (eval echo "$as_me:9720: \"$ac_try\"") >&5
     8046+  { (eval echo "$as_me:9729: \"$ac_try\"") >&5
    78258047   (eval $ac_try) 2>&5
    78268048   ac_status=$?
    78278049-  echo "$as_me:9351: \$? = $ac_status" >&5
    7828 +  echo "$as_me:9723: \$? = $ac_status" >&5
     8050+  echo "$as_me:9732: \$? = $ac_status" >&5
    78298051   (exit $ac_status); }; }; then
    78308052   ac_hi=$ac_mid; break
    78318053 else
    7832 @@ -9364,7 +9736,7 @@
     8054@@ -9364,7 +9745,7 @@
    78338055 ac_hi=-1 ac_mid=-1
    78348056   while :; do
    78358057     cat >conftest.$ac_ext <<_ACEOF
    78368058-#line 9367 "configure"
    7837 +#line 9739 "configure"
     8059+#line 9748 "configure"
    78388060 #include "confdefs.h"
    78398061 $ac_includes_default
    78408062 int
    7841 @@ -9376,16 +9748,16 @@
     8063@@ -9376,16 +9757,16 @@
    78428064 }
    78438065 _ACEOF
    78448066 rm -f conftest.$ac_objext
    78458067-if { (eval echo "$as_me:9379: \"$ac_compile\"") >&5
    7846 +if { (eval echo "$as_me:9751: \"$ac_compile\"") >&5
     8068+if { (eval echo "$as_me:9760: \"$ac_compile\"") >&5
    78478069   (eval $ac_compile) 2>&5
    78488070   ac_status=$?
    78498071-  echo "$as_me:9382: \$? = $ac_status" >&5
    7850 +  echo "$as_me:9754: \$? = $ac_status" >&5
     8072+  echo "$as_me:9763: \$? = $ac_status" >&5
    78518073   (exit $ac_status); } &&
    78528074          { ac_try='test -s conftest.$ac_objext'
    78538075-  { (eval echo "$as_me:9385: \"$ac_try\"") >&5
    7854 +  { (eval echo "$as_me:9757: \"$ac_try\"") >&5
     8076+  { (eval echo "$as_me:9766: \"$ac_try\"") >&5
    78558077   (eval $ac_try) 2>&5
    78568078   ac_status=$?
    78578079-  echo "$as_me:9388: \$? = $ac_status" >&5
    7858 +  echo "$as_me:9760: \$? = $ac_status" >&5
     8080+  echo "$as_me:9769: \$? = $ac_status" >&5
    78598081   (exit $ac_status); }; }; then
    78608082   ac_lo=$ac_mid; break
    78618083 else
    7862 @@ -9401,7 +9773,7 @@
     8084@@ -9401,7 +9782,7 @@
    78638085 while test "x$ac_lo" != "x$ac_hi"; do
    78648086   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
    78658087   cat >conftest.$ac_ext <<_ACEOF
    78668088-#line 9404 "configure"
    7867 +#line 9776 "configure"
     8089+#line 9785 "configure"
    78688090 #include "confdefs.h"
    78698091 $ac_includes_default
    78708092 int
    7871 @@ -9413,16 +9785,16 @@
     8093@@ -9413,16 +9794,16 @@
    78728094 }
    78738095 _ACEOF
    78748096 rm -f conftest.$ac_objext
    78758097-if { (eval echo "$as_me:9416: \"$ac_compile\"") >&5
    7876 +if { (eval echo "$as_me:9788: \"$ac_compile\"") >&5
     8098+if { (eval echo "$as_me:9797: \"$ac_compile\"") >&5
    78778099   (eval $ac_compile) 2>&5
    78788100   ac_status=$?
    78798101-  echo "$as_me:9419: \$? = $ac_status" >&5
    7880 +  echo "$as_me:9791: \$? = $ac_status" >&5
     8102+  echo "$as_me:9800: \$? = $ac_status" >&5
    78818103   (exit $ac_status); } &&
    78828104          { ac_try='test -s conftest.$ac_objext'
    78838105-  { (eval echo "$as_me:9422: \"$ac_try\"") >&5
    7884 +  { (eval echo "$as_me:9794: \"$ac_try\"") >&5
     8106+  { (eval echo "$as_me:9803: \"$ac_try\"") >&5
    78858107   (eval $ac_try) 2>&5
    78868108   ac_status=$?
    78878109-  echo "$as_me:9425: \$? = $ac_status" >&5
    7888 +  echo "$as_me:9797: \$? = $ac_status" >&5
     8110+  echo "$as_me:9806: \$? = $ac_status" >&5
    78898111   (exit $ac_status); }; }; then
    78908112   ac_hi=$ac_mid
    78918113 else
    7892 @@ -9435,12 +9807,12 @@
     8114@@ -9435,12 +9816,12 @@
    78938115 ac_cv_sizeof_signed_char=$ac_lo
    78948116 else
    78958117   if test "$cross_compiling" = yes; then
    78968118-  { { echo "$as_me:9438: error: cannot run test program while cross compiling" >&5
    7897 +  { { echo "$as_me:9810: error: cannot run test program while cross compiling" >&5
     8119+  { { echo "$as_me:9819: error: cannot run test program while cross compiling" >&5
    78988120 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
    78998121    { (exit 1); exit 1; }; }
     
    79018123   cat >conftest.$ac_ext <<_ACEOF
    79028124-#line 9443 "configure"
    7903 +#line 9815 "configure"
     8125+#line 9824 "configure"
    79048126 #include "confdefs.h"
    79058127 $ac_includes_default
    79068128 int
    7907 @@ -9456,15 +9828,15 @@
     8129@@ -9456,15 +9837,15 @@
    79088130 }
    79098131 _ACEOF
    79108132 rm -f conftest$ac_exeext
    79118133-if { (eval echo "$as_me:9459: \"$ac_link\"") >&5
    7912 +if { (eval echo "$as_me:9831: \"$ac_link\"") >&5
     8134+if { (eval echo "$as_me:9840: \"$ac_link\"") >&5
    79138135   (eval $ac_link) 2>&5
    79148136   ac_status=$?
    79158137-  echo "$as_me:9462: \$? = $ac_status" >&5
    7916 +  echo "$as_me:9834: \$? = $ac_status" >&5
     8138+  echo "$as_me:9843: \$? = $ac_status" >&5
    79178139   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    79188140-  { (eval echo "$as_me:9464: \"$ac_try\"") >&5
    7919 +  { (eval echo "$as_me:9836: \"$ac_try\"") >&5
     8141+  { (eval echo "$as_me:9845: \"$ac_try\"") >&5
    79208142   (eval $ac_try) 2>&5
    79218143   ac_status=$?
    79228144-  echo "$as_me:9467: \$? = $ac_status" >&5
    7923 +  echo "$as_me:9839: \$? = $ac_status" >&5
     8145+  echo "$as_me:9848: \$? = $ac_status" >&5
    79248146   (exit $ac_status); }; }; then
    79258147   ac_cv_sizeof_signed_char=`cat conftest.val`
    79268148 else
    7927 @@ -9480,7 +9852,7 @@
     8149@@ -9480,7 +9861,7 @@
    79288150   ac_cv_sizeof_signed_char=0
    79298151 fi
    79308152 fi
    79318153-echo "$as_me:9483: result: $ac_cv_sizeof_signed_char" >&5
    7932 +echo "$as_me:9855: result: $ac_cv_sizeof_signed_char" >&5
     8154+echo "$as_me:9864: result: $ac_cv_sizeof_signed_char" >&5
    79338155 echo "${ECHO_T}$ac_cv_sizeof_signed_char" >&6
    79348156 cat >>confdefs.h <<EOF
    79358157 #define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char
    7936 @@ -9491,7 +9863,7 @@
     8158@@ -9491,7 +9872,7 @@
    79378159 else
    79388160        NCURSES_SBOOL="char"
    79398161 fi
    79408162-echo "$as_me:9494: checking if you want to use signed Boolean array in term.h" >&5
    7941 +echo "$as_me:9866: checking if you want to use signed Boolean array in term.h" >&5
     8163+echo "$as_me:9875: checking if you want to use signed Boolean array in term.h" >&5
    79428164 echo $ECHO_N "checking if you want to use signed Boolean array in term.h... $ECHO_C" >&6
    79438165 
    79448166 # Check whether --enable-signed-char or --disable-signed-char was given.
    7945 @@ -9501,12 +9873,12 @@
     8167@@ -9501,12 +9882,12 @@
    79468168 else
    79478169   with_signed_char=no
    79488170 fi;
    79498171-echo "$as_me:9504: result: $with_signed_char" >&5
    7950 +echo "$as_me:9876: result: $with_signed_char" >&5
     8172+echo "$as_me:9885: result: $with_signed_char" >&5
    79518173 echo "${ECHO_T}$with_signed_char" >&6
    79528174 test "$with_signed_char" != yes && NCURSES_SBOOL="char"
     
    79548176 ###   use option --enable-sigwinch to turn on use of SIGWINCH logic
    79558177-echo "$as_me:9509: checking if you want SIGWINCH handler" >&5
    7956 +echo "$as_me:9881: checking if you want SIGWINCH handler" >&5
     8178+echo "$as_me:9890: checking if you want SIGWINCH handler" >&5
    79578179 echo $ECHO_N "checking if you want SIGWINCH handler... $ECHO_C" >&6
    79588180 
    79598181 # Check whether --enable-sigwinch or --disable-sigwinch was given.
    7960 @@ -9516,14 +9888,14 @@
     8182@@ -9516,14 +9897,14 @@
    79618183 else
    79628184   with_sigwinch=$with_ext_funcs
    79638185 fi;
    79648186-echo "$as_me:9519: result: $with_sigwinch" >&5
    7965 +echo "$as_me:9891: result: $with_sigwinch" >&5
     8187+echo "$as_me:9900: result: $with_sigwinch" >&5
    79668188 echo "${ECHO_T}$with_sigwinch" >&6
    79678189 test "$with_sigwinch" = yes && cat >>confdefs.h <<\EOF
     
    79718193 ###   use option --enable-tcap-names to allow user to define new capabilities
    79728194-echo "$as_me:9526: checking if you want user-definable terminal capabilities like termcap" >&5
    7973 +echo "$as_me:9898: checking if you want user-definable terminal capabilities like termcap" >&5
     8195+echo "$as_me:9907: checking if you want user-definable terminal capabilities like termcap" >&5
    79748196 echo $ECHO_N "checking if you want user-definable terminal capabilities like termcap... $ECHO_C" >&6
    79758197 
    79768198 # Check whether --enable-tcap-names or --disable-tcap-names was given.
    7977 @@ -9533,7 +9905,7 @@
     8199@@ -9533,7 +9914,7 @@
    79788200 else
    79798201   with_tcap_names=$with_ext_funcs
    79808202 fi;
    79818203-echo "$as_me:9536: result: $with_tcap_names" >&5
    7982 +echo "$as_me:9908: result: $with_tcap_names" >&5
     8204+echo "$as_me:9917: result: $with_tcap_names" >&5
    79838205 echo "${ECHO_T}$with_tcap_names" >&6
    79848206 NCURSES_XNAMES=0
    79858207 test "$with_tcap_names" = yes && NCURSES_XNAMES=1
    7986 @@ -9541,7 +9913,7 @@
     8208@@ -9541,7 +9922,7 @@
    79878209 ###############################################################################
    79888210 # These options are relatively safe to experiment with.
    79898211 
    79908212-echo "$as_me:9544: checking if you want all development code" >&5
    7991 +echo "$as_me:9916: checking if you want all development code" >&5
     8213+echo "$as_me:9925: checking if you want all development code" >&5
    79928214 echo $ECHO_N "checking if you want all development code... $ECHO_C" >&6
    79938215 
    79948216 # Check whether --with-develop or --without-develop was given.
    7995 @@ -9551,11 +9923,11 @@
     8217@@ -9551,11 +9932,11 @@
    79968218 else
    79978219   with_develop=no
    79988220 fi;
    79998221-echo "$as_me:9554: result: $with_develop" >&5
    8000 +echo "$as_me:9926: result: $with_develop" >&5
     8222+echo "$as_me:9935: result: $with_develop" >&5
    80018223 echo "${ECHO_T}$with_develop" >&6
    80028224 
    80038225 ###   use option --enable-hard-tabs to turn on use of hard-tabs optimize
    80048226-echo "$as_me:9558: checking if you want hard-tabs code" >&5
    8005 +echo "$as_me:9930: checking if you want hard-tabs code" >&5
     8227+echo "$as_me:9939: checking if you want hard-tabs code" >&5
    80068228 echo $ECHO_N "checking if you want hard-tabs code... $ECHO_C" >&6
    80078229 
    80088230 # Check whether --enable-hard-tabs or --disable-hard-tabs was given.
    8009 @@ -9565,14 +9937,14 @@
     8231@@ -9565,14 +9946,14 @@
    80108232 else
    80118233   enable_hard_tabs=$with_develop
    80128234 fi;
    80138235-echo "$as_me:9568: result: $enable_hard_tabs" >&5
    8014 +echo "$as_me:9940: result: $enable_hard_tabs" >&5
     8236+echo "$as_me:9949: result: $enable_hard_tabs" >&5
    80158237 echo "${ECHO_T}$enable_hard_tabs" >&6
    80168238 test "$enable_hard_tabs" = yes && cat >>confdefs.h <<\EOF
     
    80208242 ###   use option --enable-xmc-glitch to turn on use of magic-cookie optimize
    80218243-echo "$as_me:9575: checking if you want limited support for xmc" >&5
    8022 +echo "$as_me:9947: checking if you want limited support for xmc" >&5
     8244+echo "$as_me:9956: checking if you want limited support for xmc" >&5
    80238245 echo $ECHO_N "checking if you want limited support for xmc... $ECHO_C" >&6
    80248246 
    80258247 # Check whether --enable-xmc-glitch or --disable-xmc-glitch was given.
    8026 @@ -9582,7 +9954,7 @@
     8248@@ -9582,7 +9963,7 @@
    80278249 else
    80288250   enable_xmc_glitch=$with_develop
    80298251 fi;
    80308252-echo "$as_me:9585: result: $enable_xmc_glitch" >&5
    8031 +echo "$as_me:9957: result: $enable_xmc_glitch" >&5
     8253+echo "$as_me:9966: result: $enable_xmc_glitch" >&5
    80328254 echo "${ECHO_T}$enable_xmc_glitch" >&6
    80338255 test "$enable_xmc_glitch" = yes && cat >>confdefs.h <<\EOF
    80348256 #define USE_XMC_SUPPORT 1
    8035 @@ -9591,7 +9963,7 @@
     8257@@ -9591,7 +9972,7 @@
    80368258 ###############################################################################
    80378259 # These are just experimental, probably should not be in a package:
    80388260 
    80398261-echo "$as_me:9594: checking if you do not want to assume colors are white-on-black" >&5
    8040 +echo "$as_me:9966: checking if you do not want to assume colors are white-on-black" >&5
     8262+echo "$as_me:9975: checking if you do not want to assume colors are white-on-black" >&5
    80418263 echo $ECHO_N "checking if you do not want to assume colors are white-on-black... $ECHO_C" >&6
    80428264 
    80438265 # Check whether --enable-assumed-color or --disable-assumed-color was given.
    8044 @@ -9601,14 +9973,14 @@
     8266@@ -9601,14 +9982,14 @@
    80458267 else
    80468268   with_assumed_color=yes
    80478269 fi;
    80488270-echo "$as_me:9604: result: $with_assumed_color" >&5
    8049 +echo "$as_me:9976: result: $with_assumed_color" >&5
     8271+echo "$as_me:9985: result: $with_assumed_color" >&5
    80508272 echo "${ECHO_T}$with_assumed_color" >&6
    80518273 test "$with_assumed_color" = yes && cat >>confdefs.h <<\EOF
     
    80558277 ###   use option --enable-hashmap to turn on use of hashmap scrolling logic
    80568278-echo "$as_me:9611: checking if you want hashmap scrolling-optimization code" >&5
    8057 +echo "$as_me:9983: checking if you want hashmap scrolling-optimization code" >&5
     8279+echo "$as_me:9992: checking if you want hashmap scrolling-optimization code" >&5
    80588280 echo $ECHO_N "checking if you want hashmap scrolling-optimization code... $ECHO_C" >&6
    80598281 
    80608282 # Check whether --enable-hashmap or --disable-hashmap was given.
    8061 @@ -9618,14 +9990,14 @@
     8283@@ -9618,14 +9999,14 @@
    80628284 else
    80638285   with_hashmap=yes
    80648286 fi;
    80658287-echo "$as_me:9621: result: $with_hashmap" >&5
    8066 +echo "$as_me:9993: result: $with_hashmap" >&5
     8288+echo "$as_me:10002: result: $with_hashmap" >&5
    80678289 echo "${ECHO_T}$with_hashmap" >&6
    80688290 test "$with_hashmap" = yes && cat >>confdefs.h <<\EOF
     
    80728294 ###   use option --enable-colorfgbg to turn on use of $COLORFGBG environment
    80738295-echo "$as_me:9628: checking if you want colorfgbg code" >&5
    8074 +echo "$as_me:10000: checking if you want colorfgbg code" >&5
     8296+echo "$as_me:10009: checking if you want colorfgbg code" >&5
    80758297 echo $ECHO_N "checking if you want colorfgbg code... $ECHO_C" >&6
    80768298 
    80778299 # Check whether --enable-colorfgbg or --disable-colorfgbg was given.
    8078 @@ -9635,7 +10007,7 @@
     8300@@ -9635,7 +10016,7 @@
    80798301 else
    80808302   with_colorfgbg=no
    80818303 fi;
    80828304-echo "$as_me:9638: result: $with_colorfgbg" >&5
    8083 +echo "$as_me:10010: result: $with_colorfgbg" >&5
     8305+echo "$as_me:10019: result: $with_colorfgbg" >&5
    80848306 echo "${ECHO_T}$with_colorfgbg" >&6
    80858307 test "$with_colorfgbg" = yes && cat >>confdefs.h <<\EOF
    80868308 #define USE_COLORFGBG 1
    8087 @@ -9644,7 +10016,7 @@
     8309@@ -9644,7 +10025,7 @@
    80888310 # This is still experimental (20080329), but should ultimately be moved to
    80898311 # the script-block --with-normal, etc.
    80908312 
    80918313-echo "$as_me:9647: checking if you want to link with the pthread library" >&5
    8092 +echo "$as_me:10019: checking if you want to link with the pthread library" >&5
     8314+echo "$as_me:10028: checking if you want to link with the pthread library" >&5
    80938315 echo $ECHO_N "checking if you want to link with the pthread library... $ECHO_C" >&6
    80948316 
    80958317 # Check whether --with-pthread or --without-pthread was given.
    8096 @@ -9654,27 +10026,27 @@
     8318@@ -9654,27 +10035,27 @@
    80978319 else
    80988320   with_pthread=no
    80998321 fi;
    81008322-echo "$as_me:9657: result: $with_pthread" >&5
    8101 +echo "$as_me:10029: result: $with_pthread" >&5
     8323+echo "$as_me:10038: result: $with_pthread" >&5
    81028324 echo "${ECHO_T}$with_pthread" >&6
    81038325 
    81048326 if test "$with_pthread" != no ; then
    81058327-    echo "$as_me:9661: checking for pthread.h" >&5
    8106 +    echo "$as_me:10033: checking for pthread.h" >&5
     8328+    echo "$as_me:10042: checking for pthread.h" >&5
    81078329 echo $ECHO_N "checking for pthread.h... $ECHO_C" >&6
    81088330 if test "${ac_cv_header_pthread_h+set}" = set; then
     
    81118333   cat >conftest.$ac_ext <<_ACEOF
    81128334-#line 9667 "configure"
    8113 +#line 10039 "configure"
     8335+#line 10048 "configure"
    81148336 #include "confdefs.h"
    81158337 #include <pthread.h>
    81168338 _ACEOF
    81178339-if { (eval echo "$as_me:9671: \"$ac_cpp conftest.$ac_ext\"") >&5
    8118 +if { (eval echo "$as_me:10043: \"$ac_cpp conftest.$ac_ext\"") >&5
     8340+if { (eval echo "$as_me:10052: \"$ac_cpp conftest.$ac_ext\"") >&5
    81198341   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    81208342   ac_status=$?
     
    81238345   cat conftest.err >&5
    81248346-  echo "$as_me:9677: \$? = $ac_status" >&5
    8125 +  echo "$as_me:10049: \$? = $ac_status" >&5
     8347+  echo "$as_me:10058: \$? = $ac_status" >&5
    81268348   (exit $ac_status); } >/dev/null; then
    81278349   if test -s conftest.err; then
    81288350     ac_cpp_err=$ac_c_preproc_warn_flag
    8129 @@ -9693,7 +10065,7 @@
     8351@@ -9693,7 +10074,7 @@
    81308352 fi
    81318353 rm -f conftest.err conftest.$ac_ext
    81328354 fi
    81338355-echo "$as_me:9696: result: $ac_cv_header_pthread_h" >&5
    8134 +echo "$as_me:10068: result: $ac_cv_header_pthread_h" >&5
     8356+echo "$as_me:10077: result: $ac_cv_header_pthread_h" >&5
    81358357 echo "${ECHO_T}$ac_cv_header_pthread_h" >&6
    81368358 if test $ac_cv_header_pthread_h = yes; then
    81378359 
    8138 @@ -9701,12 +10073,12 @@
     8360@@ -9701,12 +10082,12 @@
    81398361 #define HAVE_PTHREADS_H 1
    81408362 EOF
    81418363 
    81428364-        echo "$as_me:9704: checking if we can link with the pthread library" >&5
    8143 +        echo "$as_me:10076: checking if we can link with the pthread library" >&5
     8365+        echo "$as_me:10085: checking if we can link with the pthread library" >&5
    81448366 echo $ECHO_N "checking if we can link with the pthread library... $ECHO_C" >&6
    81458367         cf_save_LIBS="$LIBS"
     
    81478369         cat >conftest.$ac_ext <<_ACEOF
    81488370-#line 9709 "configure"
    8149 +#line 10081 "configure"
     8371+#line 10090 "configure"
    81508372 #include "confdefs.h"
    81518373 
    81528374 #include <pthread.h>
    8153 @@ -9722,16 +10094,16 @@
     8375@@ -9722,16 +10103,16 @@
    81548376 }
    81558377 _ACEOF
    81568378 rm -f conftest.$ac_objext conftest$ac_exeext
    81578379-if { (eval echo "$as_me:9725: \"$ac_link\"") >&5
    8158 +if { (eval echo "$as_me:10097: \"$ac_link\"") >&5
     8380+if { (eval echo "$as_me:10106: \"$ac_link\"") >&5
    81598381   (eval $ac_link) 2>&5
    81608382   ac_status=$?
    81618383-  echo "$as_me:9728: \$? = $ac_status" >&5
    8162 +  echo "$as_me:10100: \$? = $ac_status" >&5
     8384+  echo "$as_me:10109: \$? = $ac_status" >&5
    81638385   (exit $ac_status); } &&
    81648386          { ac_try='test -s conftest$ac_exeext'
    81658387-  { (eval echo "$as_me:9731: \"$ac_try\"") >&5
    8166 +  { (eval echo "$as_me:10103: \"$ac_try\"") >&5
     8388+  { (eval echo "$as_me:10112: \"$ac_try\"") >&5
    81678389   (eval $ac_try) 2>&5
    81688390   ac_status=$?
    81698391-  echo "$as_me:9734: \$? = $ac_status" >&5
    8170 +  echo "$as_me:10106: \$? = $ac_status" >&5
     8392+  echo "$as_me:10115: \$? = $ac_status" >&5
    81718393   (exit $ac_status); }; }; then
    81728394   with_pthread=yes
    81738395 else
    8174 @@ -9741,7 +10113,7 @@
     8396@@ -9741,7 +10122,7 @@
    81758397 fi
    81768398 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    81778399         LIBS="$cf_save_LIBS"
    81788400-        echo "$as_me:9744: result: $with_pthread" >&5
    8179 +        echo "$as_me:10116: result: $with_pthread" >&5
     8401+        echo "$as_me:10125: result: $with_pthread" >&5
    81808402 echo "${ECHO_T}$with_pthread" >&6
    81818403 
    81828404         if test "$with_pthread" = yes ; then
    8183 @@ -9751,7 +10123,7 @@
     8405@@ -9751,7 +10132,7 @@
    81848406 EOF
    81858407 
    81868408         else
    81878409-            { { echo "$as_me:9754: error: Cannot link with pthread library" >&5
    8188 +            { { echo "$as_me:10126: error: Cannot link with pthread library" >&5
     8410+            { { echo "$as_me:10135: error: Cannot link with pthread library" >&5
    81898411 echo "$as_me: error: Cannot link with pthread library" >&2;}
    81908412    { (exit 1); exit 1; }; }
    81918413         fi
    8192 @@ -9760,7 +10132,7 @@
     8414@@ -9760,7 +10141,7 @@
    81938415 
    81948416 fi
    81958417 
    81968418-echo "$as_me:9763: checking if you want to use weak-symbols for pthreads" >&5
    8197 +echo "$as_me:10135: checking if you want to use weak-symbols for pthreads" >&5
     8419+echo "$as_me:10144: checking if you want to use weak-symbols for pthreads" >&5
    81988420 echo $ECHO_N "checking if you want to use weak-symbols for pthreads... $ECHO_C" >&6
    81998421 
    82008422 # Check whether --enable-weak-symbols or --disable-weak-symbols was given.
    8201 @@ -9770,18 +10142,18 @@
     8423@@ -9770,18 +10151,18 @@
    82028424 else
    82038425   use_weak_symbols=no
    82048426 fi;
    82058427-echo "$as_me:9773: result: $use_weak_symbols" >&5
    8206 +echo "$as_me:10145: result: $use_weak_symbols" >&5
     8428+echo "$as_me:10154: result: $use_weak_symbols" >&5
    82078429 echo "${ECHO_T}$use_weak_symbols" >&6
    82088430 if test "$use_weak_symbols" = yes ; then
    82098431 
    82108432-echo "$as_me:9777: checking if $CC supports weak symbols" >&5
    8211 +echo "$as_me:10149: checking if $CC supports weak symbols" >&5
     8433+echo "$as_me:10158: checking if $CC supports weak symbols" >&5
    82128434 echo $ECHO_N "checking if $CC supports weak symbols... $ECHO_C" >&6
    82138435 if test "${cf_cv_weak_symbols+set}" = set; then
     
    82178439 cat >conftest.$ac_ext <<_ACEOF
    82188440-#line 9784 "configure"
    8219 +#line 10156 "configure"
     8441+#line 10165 "configure"
    82208442 #include "confdefs.h"
    82218443 
    82228444 #include <stdio.h>
    8223 @@ -9807,16 +10179,16 @@
     8445@@ -9807,16 +10188,16 @@
    82248446 }
    82258447 _ACEOF
    82268448 rm -f conftest.$ac_objext
    82278449-if { (eval echo "$as_me:9810: \"$ac_compile\"") >&5
    8228 +if { (eval echo "$as_me:10182: \"$ac_compile\"") >&5
     8450+if { (eval echo "$as_me:10191: \"$ac_compile\"") >&5
    82298451   (eval $ac_compile) 2>&5
    82308452   ac_status=$?
    82318453-  echo "$as_me:9813: \$? = $ac_status" >&5
    8232 +  echo "$as_me:10185: \$? = $ac_status" >&5
     8454+  echo "$as_me:10194: \$? = $ac_status" >&5
    82338455   (exit $ac_status); } &&
    82348456          { ac_try='test -s conftest.$ac_objext'
    82358457-  { (eval echo "$as_me:9816: \"$ac_try\"") >&5
    8236 +  { (eval echo "$as_me:10188: \"$ac_try\"") >&5
     8458+  { (eval echo "$as_me:10197: \"$ac_try\"") >&5
    82378459   (eval $ac_try) 2>&5
    82388460   ac_status=$?
    82398461-  echo "$as_me:9819: \$? = $ac_status" >&5
    8240 +  echo "$as_me:10191: \$? = $ac_status" >&5
     8462+  echo "$as_me:10200: \$? = $ac_status" >&5
    82418463   (exit $ac_status); }; }; then
    82428464   cf_cv_weak_symbols=yes
    82438465 else
    8244 @@ -9827,7 +10199,7 @@
     8466@@ -9827,7 +10208,7 @@
    82458467 rm -f conftest.$ac_objext conftest.$ac_ext
    82468468 
    82478469 fi
    82488470-echo "$as_me:9830: result: $cf_cv_weak_symbols" >&5
    8249 +echo "$as_me:10202: result: $cf_cv_weak_symbols" >&5
     8471+echo "$as_me:10211: result: $cf_cv_weak_symbols" >&5
    82508472 echo "${ECHO_T}$cf_cv_weak_symbols" >&6
    82518473 
    82528474 else
    8253 @@ -9857,7 +10229,7 @@
     8475@@ -9857,7 +10238,7 @@
    82548476 # opaque outside of that, so there is no --enable-opaque option.  We can use
    82558477 # this option without --with-pthreads, but this will be always set for
    82568478 # pthreads.
    82578479-echo "$as_me:9860: checking if you want experimental reentrant code" >&5
    8258 +echo "$as_me:10232: checking if you want experimental reentrant code" >&5
     8480+echo "$as_me:10241: checking if you want experimental reentrant code" >&5
    82598481 echo $ECHO_N "checking if you want experimental reentrant code... $ECHO_C" >&6
    82608482 
    82618483 # Check whether --enable-reentrant or --disable-reentrant was given.
    8262 @@ -9867,7 +10239,7 @@
     8484@@ -9867,21 +10248,21 @@
    82638485 else
    82648486   with_reentrant=no
    82658487 fi;
    82668488-echo "$as_me:9870: result: $with_reentrant" >&5
    8267 +echo "$as_me:10242: result: $with_reentrant" >&5
     8489+echo "$as_me:10251: result: $with_reentrant" >&5
    82688490 echo "${ECHO_T}$with_reentrant" >&6
    82698491 if test "$with_reentrant" = yes ; then
    82708492        cf_cv_enable_reentrant=1
    8271 @@ -9891,7 +10263,7 @@
     8493        cf_cv_enable_opaque="NCURSES_INTERNALS"
     8494        NCURSES_OPAQUE=1
     8495        NCURSES_SIZE_T=int
     8496-    if test $cf_cv_weak_symbols = yes ; then
     8497+       if test $cf_cv_weak_symbols = yes ; then
     8498 
     8499 # remove pthread library from $LIBS
     8500 LIBS=`echo "$LIBS" | sed -e 's/-lpthread[      ]//g' -e 's/-lpthread$//'`
     8501 
     8502-    else
     8503-        LIB_SUFFIX="t${LIB_SUFFIX}"
     8504-    fi
     8505+       else
     8506+               LIB_SUFFIX="t${LIB_SUFFIX}"
     8507+       fi
     8508        cat >>confdefs.h <<\EOF
     8509 #define USE_REENTRANT 1
     8510 EOF
     8511@@ -9891,7 +10272,7 @@
    82728512        5.*)
    82738513                cf_cv_rel_version=6.0
    82748514                cf_cv_abi_version=6
    82758515-               { echo "$as_me:9894: WARNING: Overriding ABI version to $cf_cv_abi_version" >&5
    8276 +               { echo "$as_me:10266: WARNING: Overriding ABI version to $cf_cv_abi_version" >&5
     8516+               { echo "$as_me:10275: WARNING: Overriding ABI version to $cf_cv_abi_version" >&5
    82778517 echo "$as_me: WARNING: Overriding ABI version to $cf_cv_abi_version" >&2;}
    82788518                ;;
    82798519        esac
    8280 @@ -9904,7 +10276,7 @@
     8520@@ -9904,7 +10285,29 @@
    82818521        NCURSES_SIZE_T=short
    82828522 fi
    82838523 
    82848524-echo "$as_me:9907: checking if you want experimental safe-sprintf code" >&5
    8285 +echo "$as_me:10279: checking if you want experimental safe-sprintf code" >&5
     8525+### Allow using a different wrap-prefix
     8526+if test "$cf_cv_enable_reentrant" != 0 || test "$BROKEN_LINKER" = 1 ; then
     8527+       echo "$as_me:10290: checking for prefix used to wrap public variables" >&5
     8528+echo $ECHO_N "checking for prefix used to wrap public variables... $ECHO_C" >&6
     8529+
     8530+# Check whether --with-wrap-prefix or --without-wrap-prefix was given.
     8531+if test "${with_wrap_prefix+set}" = set; then
     8532+  withval="$with_wrap_prefix"
     8533+  NCURSES_WRAP_PREFIX=$withval
     8534+else
     8535+  NCURSES_WRAP_PREFIX=_nc_
     8536+fi;
     8537+       echo "$as_me:10300: result: $NCURSES_WRAP_PREFIX" >&5
     8538+echo "${ECHO_T}$NCURSES_WRAP_PREFIX" >&6
     8539+else
     8540+       NCURSES_WRAP_PREFIX=_nc_
     8541+fi
     8542+
     8543+cat >>confdefs.h <<EOF
     8544+#define NCURSES_WRAP_PREFIX "$NCURSES_WRAP_PREFIX"
     8545+EOF
     8546+
     8547+echo "$as_me:10310: checking if you want experimental safe-sprintf code" >&5
    82868548 echo $ECHO_N "checking if you want experimental safe-sprintf code... $ECHO_C" >&6
    82878549 
    82888550 # Check whether --enable-safe-sprintf or --disable-safe-sprintf was given.
    8289 @@ -9914,7 +10286,7 @@
     8551@@ -9914,7 +10317,7 @@
    82908552 else
    82918553   with_safe_sprintf=no
    82928554 fi;
    82938555-echo "$as_me:9917: result: $with_safe_sprintf" >&5
    8294 +echo "$as_me:10289: result: $with_safe_sprintf" >&5
     8556+echo "$as_me:10320: result: $with_safe_sprintf" >&5
    82958557 echo "${ECHO_T}$with_safe_sprintf" >&6
    82968558 test "$with_safe_sprintf" = yes && cat >>confdefs.h <<\EOF
    82978559 #define USE_SAFE_SPRINTF 1
    8298 @@ -9923,7 +10295,7 @@
     8560@@ -9923,7 +10326,7 @@
    82998561 ###   use option --disable-scroll-hints to turn off use of scroll-hints scrolling logic
    83008562 # when hashmap is used scroll hints are useless
    83018563 if test "$with_hashmap" = no ; then
    83028564-echo "$as_me:9926: checking if you want to experiment without scrolling-hints code" >&5
    8303 +echo "$as_me:10298: checking if you want to experiment without scrolling-hints code" >&5
     8565+echo "$as_me:10329: checking if you want to experiment without scrolling-hints code" >&5
    83048566 echo $ECHO_N "checking if you want to experiment without scrolling-hints code... $ECHO_C" >&6
    83058567 
    83068568 # Check whether --enable-scroll-hints or --disable-scroll-hints was given.
    8307 @@ -9933,7 +10305,7 @@
     8569@@ -9933,7 +10336,7 @@
    83088570 else
    83098571   with_scroll_hints=yes
    83108572 fi;
    83118573-echo "$as_me:9936: result: $with_scroll_hints" >&5
    8312 +echo "$as_me:10308: result: $with_scroll_hints" >&5
     8574+echo "$as_me:10339: result: $with_scroll_hints" >&5
    83138575 echo "${ECHO_T}$with_scroll_hints" >&6
    83148576 test "$with_scroll_hints" = yes && cat >>confdefs.h <<\EOF
    83158577 #define USE_SCROLL_HINTS 1
    8316 @@ -9941,7 +10313,7 @@
     8578@@ -9941,7 +10344,7 @@
    83178579 
    83188580 fi
    83198581 
    83208582-echo "$as_me:9944: checking if you want experimental wgetch-events code" >&5
    8321 +echo "$as_me:10316: checking if you want experimental wgetch-events code" >&5
     8583+echo "$as_me:10347: checking if you want experimental wgetch-events code" >&5
    83228584 echo $ECHO_N "checking if you want experimental wgetch-events code... $ECHO_C" >&6
    83238585 
    83248586 # Check whether --enable-wgetch-events or --disable-wgetch-events was given.
    8325 @@ -9951,7 +10323,7 @@
     8587@@ -9951,7 +10354,7 @@
    83268588 else
    83278589   with_wgetch_events=no
    83288590 fi;
    83298591-echo "$as_me:9954: result: $with_wgetch_events" >&5
    8330 +echo "$as_me:10326: result: $with_wgetch_events" >&5
     8592+echo "$as_me:10357: result: $with_wgetch_events" >&5
    83318593 echo "${ECHO_T}$with_wgetch_events" >&6
    83328594 test "$with_wgetch_events" = yes && cat >>confdefs.h <<\EOF
    83338595 #define NCURSES_WGETCH_EVENTS 1
    8334 @@ -9960,7 +10332,7 @@
     8596@@ -9960,7 +10363,7 @@
    83358597 ###############################################################################
    83368598 
    83378599 ###    use option --disable-echo to suppress full display compiling commands
    83388600-echo "$as_me:9963: checking if you want to display full commands during build" >&5
    8339 +echo "$as_me:10335: checking if you want to display full commands during build" >&5
     8601+echo "$as_me:10366: checking if you want to display full commands during build" >&5
    83408602 echo $ECHO_N "checking if you want to display full commands during build... $ECHO_C" >&6
    83418603 
    83428604 # Check whether --enable-echo or --disable-echo was given.
    8343 @@ -9977,11 +10349,11 @@
     8605@@ -9977,11 +10380,11 @@
    83448606        test -n "$LIBTOOL" && LIBTOOL="$LIBTOOL --silent"
    83458607        test -n "$LIBTOOL_CXX" && LIBTOOL_CXX="$LIBTOOL_CXX --silent"
    83468608 fi
    83478609-echo "$as_me:9980: result: $with_echo" >&5
    8348 +echo "$as_me:10352: result: $with_echo" >&5
     8610+echo "$as_me:10383: result: $with_echo" >&5
    83498611 echo "${ECHO_T}$with_echo" >&6
    83508612 
    83518613 ###    use option --enable-warnings to turn on all gcc warnings
    83528614-echo "$as_me:9984: checking if you want to see compiler warnings" >&5
    8353 +echo "$as_me:10356: checking if you want to see compiler warnings" >&5
     8615+echo "$as_me:10387: checking if you want to see compiler warnings" >&5
    83548616 echo $ECHO_N "checking if you want to see compiler warnings... $ECHO_C" >&6
    83558617 
    83568618 # Check whether --enable-warnings or --disable-warnings was given.
    8357 @@ -9989,7 +10361,7 @@
     8619@@ -9989,7 +10392,7 @@
    83588620   enableval="$enable_warnings"
    83598621   with_warnings=$enableval
    83608622 fi;
    83618623-echo "$as_me:9992: result: $with_warnings" >&5
    8362 +echo "$as_me:10364: result: $with_warnings" >&5
     8624+echo "$as_me:10395: result: $with_warnings" >&5
    83638625 echo "${ECHO_T}$with_warnings" >&6
    83648626 
    83658627 if test "x$with_warnings" = "xyes"; then
    8366 @@ -10000,12 +10372,12 @@
     8628@@ -10000,12 +10403,12 @@
    83678629 if test "$GCC" = yes ; then
    83688630        case $host_os in
    83698631        linux*|gnu*)
    83708632-               echo "$as_me:10003: checking if this is really Intel C compiler" >&5
    8371 +               echo "$as_me:10375: checking if this is really Intel C compiler" >&5
     8633+               echo "$as_me:10406: checking if this is really Intel C compiler" >&5
    83728634 echo $ECHO_N "checking if this is really Intel C compiler... $ECHO_C" >&6
    83738635                cf_save_CFLAGS="$CFLAGS"
     
    83758637                cat >conftest.$ac_ext <<_ACEOF
    83768638-#line 10008 "configure"
    8377 +#line 10380 "configure"
     8639+#line 10411 "configure"
    83788640 #include "confdefs.h"
    83798641 
    83808642 int
    8381 @@ -10022,16 +10394,16 @@
     8643@@ -10022,16 +10425,16 @@
    83828644 }
    83838645 _ACEOF
    83848646 rm -f conftest.$ac_objext
    83858647-if { (eval echo "$as_me:10025: \"$ac_compile\"") >&5
    8386 +if { (eval echo "$as_me:10397: \"$ac_compile\"") >&5
     8648+if { (eval echo "$as_me:10428: \"$ac_compile\"") >&5
    83878649   (eval $ac_compile) 2>&5
    83888650   ac_status=$?
    83898651-  echo "$as_me:10028: \$? = $ac_status" >&5
    8390 +  echo "$as_me:10400: \$? = $ac_status" >&5
     8652+  echo "$as_me:10431: \$? = $ac_status" >&5
    83918653   (exit $ac_status); } &&
    83928654          { ac_try='test -s conftest.$ac_objext'
    83938655-  { (eval echo "$as_me:10031: \"$ac_try\"") >&5
    8394 +  { (eval echo "$as_me:10403: \"$ac_try\"") >&5
     8656+  { (eval echo "$as_me:10434: \"$ac_try\"") >&5
    83958657   (eval $ac_try) 2>&5
    83968658   ac_status=$?
    83978659-  echo "$as_me:10034: \$? = $ac_status" >&5
    8398 +  echo "$as_me:10406: \$? = $ac_status" >&5
     8660+  echo "$as_me:10437: \$? = $ac_status" >&5
    83998661   (exit $ac_status); }; }; then
    84008662   INTEL_COMPILER=yes
    84018663 cf_save_CFLAGS="$cf_save_CFLAGS -we147 -no-gcc"
    8402 @@ -10042,14 +10414,14 @@
     8664@@ -10042,14 +10445,14 @@
    84038665 fi
    84048666 rm -f conftest.$ac_objext conftest.$ac_ext
    84058667                CFLAGS="$cf_save_CFLAGS"
    84068668-               echo "$as_me:10045: result: $INTEL_COMPILER" >&5
    8407 +               echo "$as_me:10417: result: $INTEL_COMPILER" >&5
     8669+               echo "$as_me:10448: result: $INTEL_COMPILER" >&5
    84088670 echo "${ECHO_T}$INTEL_COMPILER" >&6
    84098671                ;;
     
    84138675 cat > conftest.$ac_ext <<EOF
    84148676-#line 10052 "${as_me-configure}"
    8415 +#line 10424 "${as_me-configure}"
     8677+#line 10455 "${as_me-configure}"
    84168678 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
    84178679 EOF
    84188680 
    8419 @@ -10067,7 +10439,7 @@
     8681@@ -10057,7 +10460,6 @@
     8682 then
     8683 # The "-wdXXX" options suppress warnings:
     8684 # remark #1419: external declaration in primary source file
     8685-# remark #1682: implicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
     8686 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
     8687 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
     8688 # remark #193: zero used for undefined preprocessing identifier
     8689@@ -10065,31 +10467,30 @@
     8690 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
     8691 # remark #869: parameter "tw" was never referenced
    84208692 # remark #981: operands are evaluated in unspecified order
    8421  # warning #269: invalid format string conversion
     8693-# warning #269: invalid format string conversion
     8694+# warning #279: controlling expression is constant
    84228695 
    84238696-       { echo "$as_me:10070: checking for $CC warning options..." >&5
    8424 +       { echo "$as_me:10442: checking for $CC warning options..." >&5
     8697+       { echo "$as_me:10472: checking for $CC warning options..." >&5
    84258698 echo "$as_me: checking for $CC warning options..." >&6;}
    84268699        cf_save_CFLAGS="$CFLAGS"
    84278700        EXTRA_CFLAGS="-Wall"
    8428 @@ -10084,12 +10456,12 @@
     8701        for cf_opt in \
     8702                wd1419 \
     8703-               wd1682 \
     8704                wd1683 \
     8705                wd1684 \
     8706                wd193 \
     8707-               wd279 \
     8708                wd593 \
     8709+               wd279 \
     8710                wd810 \
     8711                wd869 \
    84298712                wd981
    84308713        do
    84318714                CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
    84328715-               if { (eval echo "$as_me:10087: \"$ac_compile\"") >&5
    8433 +               if { (eval echo "$as_me:10459: \"$ac_compile\"") >&5
     8716+               if { (eval echo "$as_me:10488: \"$ac_compile\"") >&5
    84348717   (eval $ac_compile) 2>&5
    84358718   ac_status=$?
    84368719-  echo "$as_me:10090: \$? = $ac_status" >&5
    8437 +  echo "$as_me:10462: \$? = $ac_status" >&5
     8720+  echo "$as_me:10491: \$? = $ac_status" >&5
    84388721   (exit $ac_status); }; then
    84398722-                       test -n "$verbose" && echo "$as_me:10092: result: ... -$cf_opt" >&5
    8440 +                       test -n "$verbose" && echo "$as_me:10464: result: ... -$cf_opt" >&5
     8723+                       test -n "$verbose" && echo "$as_me:10493: result: ... -$cf_opt" >&5
    84418724 echo "${ECHO_T}... -$cf_opt" >&6
    84428725                        EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
    84438726                fi
    8444 @@ -10098,7 +10470,7 @@
     8727@@ -10098,7 +10499,7 @@
    84458728 
    84468729 elif test "$GCC" = yes
    84478730 then
    84488731-       { echo "$as_me:10101: checking for $CC warning options..." >&5
    8449 +       { echo "$as_me:10473: checking for $CC warning options..." >&5
     8732+       { echo "$as_me:10502: checking for $CC warning options..." >&5
    84508733 echo "$as_me: checking for $CC warning options..." >&6;}
    84518734        cf_save_CFLAGS="$CFLAGS"
    84528735        EXTRA_CFLAGS="-W -Wall"
    8453 @@ -10118,12 +10490,12 @@
     8736@@ -10118,12 +10519,12 @@
    84548737                Wundef $cf_warn_CONST Wdeclaration-after-statement Wextra Wno-unknown-pragmas Wswitch-enum
    84558738        do
    84568739                CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
    84578740-               if { (eval echo "$as_me:10121: \"$ac_compile\"") >&5
    8458 +               if { (eval echo "$as_me:10493: \"$ac_compile\"") >&5
     8741+               if { (eval echo "$as_me:10522: \"$ac_compile\"") >&5
    84598742   (eval $ac_compile) 2>&5
    84608743   ac_status=$?
    84618744-  echo "$as_me:10124: \$? = $ac_status" >&5
    8462 +  echo "$as_me:10496: \$? = $ac_status" >&5
     8745+  echo "$as_me:10525: \$? = $ac_status" >&5
    84638746   (exit $ac_status); }; then
    84648747-                       test -n "$verbose" && echo "$as_me:10126: result: ... -$cf_opt" >&5
    8465 +                       test -n "$verbose" && echo "$as_me:10498: result: ... -$cf_opt" >&5
     8748+                       test -n "$verbose" && echo "$as_me:10527: result: ... -$cf_opt" >&5
    84668749 echo "${ECHO_T}... -$cf_opt" >&6
    84678750                        case $cf_opt in #(vi
    84688751                        Wcast-qual) #(vi
    8469 @@ -10134,7 +10506,7 @@
     8752@@ -10134,7 +10535,7 @@
    84708753                                [34].*)
    84718754                                        test -n "$verbose" && echo "    feature is broken in gcc $GCC_VERSION" 1>&6
    84728755 
    84738756-echo "${as_me-configure}:10137: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
    8474 +echo "${as_me-configure}:10509: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
     8757+echo "${as_me-configure}:10538: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
    84758758 
    84768759                                        continue;;
    84778760                                esac
    8478 @@ -10154,12 +10526,12 @@
     8761@@ -10154,12 +10555,12 @@
    84798762 if test "$GCC" = yes ; then
    84808763        case $host_os in
    84818764        linux*|gnu*)
    84828765-               echo "$as_me:10157: checking if this is really Intel C++ compiler" >&5
    8483 +               echo "$as_me:10529: checking if this is really Intel C++ compiler" >&5
     8766+               echo "$as_me:10558: checking if this is really Intel C++ compiler" >&5
    84848767 echo $ECHO_N "checking if this is really Intel C++ compiler... $ECHO_C" >&6
    84858768                cf_save_CFLAGS="$CXXFLAGS"
     
    84878770                cat >conftest.$ac_ext <<_ACEOF
    84888771-#line 10162 "configure"
    8489 +#line 10534 "configure"
     8772+#line 10563 "configure"
    84908773 #include "confdefs.h"
    84918774 
    84928775 int
    8493 @@ -10176,16 +10548,16 @@
     8776@@ -10176,16 +10577,16 @@
    84948777 }
    84958778 _ACEOF
    84968779 rm -f conftest.$ac_objext
    84978780-if { (eval echo "$as_me:10179: \"$ac_compile\"") >&5
    8498 +if { (eval echo "$as_me:10551: \"$ac_compile\"") >&5
     8781+if { (eval echo "$as_me:10580: \"$ac_compile\"") >&5
    84998782   (eval $ac_compile) 2>&5
    85008783   ac_status=$?
    85018784-  echo "$as_me:10182: \$? = $ac_status" >&5
    8502 +  echo "$as_me:10554: \$? = $ac_status" >&5
     8785+  echo "$as_me:10583: \$? = $ac_status" >&5
    85038786   (exit $ac_status); } &&
    85048787          { ac_try='test -s conftest.$ac_objext'
    85058788-  { (eval echo "$as_me:10185: \"$ac_try\"") >&5
    8506 +  { (eval echo "$as_me:10557: \"$ac_try\"") >&5
     8789+  { (eval echo "$as_me:10586: \"$ac_try\"") >&5
    85078790   (eval $ac_try) 2>&5
    85088791   ac_status=$?
    85098792-  echo "$as_me:10188: \$? = $ac_status" >&5
    8510 +  echo "$as_me:10560: \$? = $ac_status" >&5
     8793+  echo "$as_me:10589: \$? = $ac_status" >&5
    85118794   (exit $ac_status); }; }; then
    85128795   INTEL_CPLUSPLUS=yes
    85138796 cf_save_CFLAGS="$cf_save_CFLAGS -we147 -no-gcc"
    8514 @@ -10196,7 +10568,7 @@
     8797@@ -10196,7 +10597,7 @@
    85158798 fi
    85168799 rm -f conftest.$ac_objext conftest.$ac_ext
    85178800                CXXFLAGS="$cf_save_CFLAGS"
    85188801-               echo "$as_me:10199: result: $INTEL_CPLUSPLUS" >&5
    8519 +               echo "$as_me:10571: result: $INTEL_CPLUSPLUS" >&5
     8802+               echo "$as_me:10600: result: $INTEL_CPLUSPLUS" >&5
    85208803 echo "${ECHO_T}$INTEL_CPLUSPLUS" >&6
    85218804                ;;
    85228805        esac
    8523 @@ -10210,7 +10582,7 @@
     8806@@ -10210,7 +10611,7 @@
    85248807 ac_main_return=return
    85258808 
    85268809 cat > conftest.$ac_ext <<EOF
    85278810-#line 10213 "configure"
    8528 +#line 10585 "configure"
     8811+#line 10614 "configure"
    85298812 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
    85308813 EOF
    85318814 
    8532 @@ -10228,7 +10600,7 @@
     8815@@ -10228,7 +10629,7 @@
    85338816 # remark #981: operands are evaluated in unspecified order
    85348817 # warning #269: invalid format string conversion
    85358818 
    85368819-       { echo "$as_me:10231: checking for $CC warning options..." >&5
    8537 +       { echo "$as_me:10603: checking for $CC warning options..." >&5
     8820+       { echo "$as_me:10632: checking for $CC warning options..." >&5
    85388821 echo "$as_me: checking for $CC warning options..." >&6;}
    85398822        cf_save_CXXFLAGS="$CXXFLAGS"
    85408823        EXTRA_CXXFLAGS="-Wall"
    8541 @@ -10245,12 +10617,12 @@
     8824@@ -10245,12 +10646,12 @@
    85428825                wd981
    85438826        do
    85448827                CXXFLAGS="$cf_save_CXXFLAGS $EXTRA_CXXFLAGS -$cf_opt"
    85458828-               if { (eval echo "$as_me:10248: \"$ac_compile\"") >&5
    8546 +               if { (eval echo "$as_me:10620: \"$ac_compile\"") >&5
     8829+               if { (eval echo "$as_me:10649: \"$ac_compile\"") >&5
    85478830   (eval $ac_compile) 2>&5
    85488831   ac_status=$?
    85498832-  echo "$as_me:10251: \$? = $ac_status" >&5
    8550 +  echo "$as_me:10623: \$? = $ac_status" >&5
     8833+  echo "$as_me:10652: \$? = $ac_status" >&5
    85518834   (exit $ac_status); }; then
    85528835-                       test -n "$verbose" && echo "$as_me:10253: result: ... -$cf_opt" >&5
    8553 +                       test -n "$verbose" && echo "$as_me:10625: result: ... -$cf_opt" >&5
     8836+                       test -n "$verbose" && echo "$as_me:10654: result: ... -$cf_opt" >&5
    85548837 echo "${ECHO_T}... -$cf_opt" >&6
    85558838                        EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS -$cf_opt"
    85568839                fi
    8557 @@ -10259,7 +10631,7 @@
     8840@@ -10259,7 +10660,7 @@
    85588841 
    85598842 elif test "$GXX" = yes
    85608843 then
    85618844-       { echo "$as_me:10262: checking for $CXX warning options..." >&5
    8562 +       { echo "$as_me:10634: checking for $CXX warning options..." >&5
     8845+       { echo "$as_me:10663: checking for $CXX warning options..." >&5
    85638846 echo "$as_me: checking for $CXX warning options..." >&6;}
    85648847        cf_save_CXXFLAGS="$CXXFLAGS"
    85658848        EXTRA_CXXFLAGS="-W -Wall"
    8566 @@ -10288,16 +10660,16 @@
     8849@@ -10288,16 +10689,16 @@
    85678850                Wundef $cf_gxx_extra_warnings Wno-unused
    85688851        do
    85698852                CXXFLAGS="$cf_save_CXXFLAGS $EXTRA_CXXFLAGS -Werror -$cf_opt"
    85708853-               if { (eval echo "$as_me:10291: \"$ac_compile\"") >&5
    8571 +               if { (eval echo "$as_me:10663: \"$ac_compile\"") >&5
     8854+               if { (eval echo "$as_me:10692: \"$ac_compile\"") >&5
    85728855   (eval $ac_compile) 2>&5
    85738856   ac_status=$?
    85748857-  echo "$as_me:10294: \$? = $ac_status" >&5
    8575 +  echo "$as_me:10666: \$? = $ac_status" >&5
     8858+  echo "$as_me:10695: \$? = $ac_status" >&5
    85768859   (exit $ac_status); }; then
    85778860-                       test -n "$verbose" && echo "$as_me:10296: result: ... -$cf_opt" >&5
    8578 +                       test -n "$verbose" && echo "$as_me:10668: result: ... -$cf_opt" >&5
     8861+                       test -n "$verbose" && echo "$as_me:10697: result: ... -$cf_opt" >&5
    85798862 echo "${ECHO_T}... -$cf_opt" >&6
    85808863                        EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS -$cf_opt"
    85818864                else
    85828865-                       test -n "$verbose" && echo "$as_me:10300: result: ... no -$cf_opt" >&5
    8583 +                       test -n "$verbose" && echo "$as_me:10672: result: ... no -$cf_opt" >&5
     8866+                       test -n "$verbose" && echo "$as_me:10701: result: ... no -$cf_opt" >&5
    85848867 echo "${ECHO_T}... no -$cf_opt" >&6
    85858868                fi
    85868869        done
    8587 @@ -10333,10 +10705,10 @@
     8870@@ -10333,10 +10734,10 @@
    85888871 EOF
    85898872 if test "$GCC" = yes
    85908873 then
    85918874-       { echo "$as_me:10336: checking for $CC __attribute__ directives..." >&5
    8592 +       { echo "$as_me:10708: checking for $CC __attribute__ directives..." >&5
     8875+       { echo "$as_me:10737: checking for $CC __attribute__ directives..." >&5
    85938876 echo "$as_me: checking for $CC __attribute__ directives..." >&6;}
    85948877 cat > conftest.$ac_ext <<EOF
    85958878-#line 10339 "${as_me-configure}"
    8596 +#line 10711 "${as_me-configure}"
     8879+#line 10740 "${as_me-configure}"
    85978880 #include "confdefs.h"
    85988881 #include "conftest.h"
    85998882 #include "conftest.i"
    8600 @@ -10374,12 +10746,12 @@
     8883@@ -10374,12 +10775,12 @@
    86018884 EOF
    86028885                        ;;
    86038886                esac
    86048887-               if { (eval echo "$as_me:10377: \"$ac_compile\"") >&5
    8605 +               if { (eval echo "$as_me:10749: \"$ac_compile\"") >&5
     8888+               if { (eval echo "$as_me:10778: \"$ac_compile\"") >&5
    86068889   (eval $ac_compile) 2>&5
    86078890   ac_status=$?
    86088891-  echo "$as_me:10380: \$? = $ac_status" >&5
    8609 +  echo "$as_me:10752: \$? = $ac_status" >&5
     8892+  echo "$as_me:10781: \$? = $ac_status" >&5
    86108893   (exit $ac_status); }; then
    86118894-                       test -n "$verbose" && echo "$as_me:10382: result: ... $cf_attribute" >&5
    8612 +                       test -n "$verbose" && echo "$as_me:10754: result: ... $cf_attribute" >&5
     8895+                       test -n "$verbose" && echo "$as_me:10783: result: ... $cf_attribute" >&5
    86138896 echo "${ECHO_T}... $cf_attribute" >&6
    86148897                        cat conftest.h >>confdefs.h
    86158898                fi
    8616 @@ -10391,7 +10763,7 @@
     8899@@ -10391,7 +10792,7 @@
    86178900 fi
    86188901 
    86198902 ###    use option --enable-assertions to turn on generation of assertion code
    86208903-echo "$as_me:10394: checking if you want to enable runtime assertions" >&5
    8621 +echo "$as_me:10766: checking if you want to enable runtime assertions" >&5
     8904+echo "$as_me:10795: checking if you want to enable runtime assertions" >&5
    86228905 echo $ECHO_N "checking if you want to enable runtime assertions... $ECHO_C" >&6
    86238906 
    86248907 # Check whether --enable-assertions or --disable-assertions was given.
    8625 @@ -10401,7 +10773,7 @@
     8908@@ -10401,7 +10802,7 @@
    86268909 else
    86278910   with_assertions=no
    86288911 fi;
    86298912-echo "$as_me:10404: result: $with_assertions" >&5
    8630 +echo "$as_me:10776: result: $with_assertions" >&5
     8913+echo "$as_me:10805: result: $with_assertions" >&5
    86318914 echo "${ECHO_T}$with_assertions" >&6
    86328915 if test -n "$GCC"
    86338916 then
    8634 @@ -10419,7 +10791,7 @@
     8917@@ -10419,7 +10820,7 @@
    86358918 
    86368919 ###    use option --disable-leaks to suppress "permanent" leaks, for testing
    86378920 
    86388921-echo "$as_me:10422: checking if you want to use dmalloc for testing" >&5
    8639 +echo "$as_me:10794: checking if you want to use dmalloc for testing" >&5
     8922+echo "$as_me:10823: checking if you want to use dmalloc for testing" >&5
    86408923 echo $ECHO_N "checking if you want to use dmalloc for testing... $ECHO_C" >&6
    86418924 
    86428925 # Check whether --with-dmalloc or --without-dmalloc was given.
    8643 @@ -10435,7 +10807,7 @@
     8926@@ -10435,7 +10836,7 @@
    86448927 else
    86458928   with_dmalloc=
    86468929 fi;
    86478930-echo "$as_me:10438: result: ${with_dmalloc:-no}" >&5
    8648 +echo "$as_me:10810: result: ${with_dmalloc:-no}" >&5
     8931+echo "$as_me:10839: result: ${with_dmalloc:-no}" >&5
    86498932 echo "${ECHO_T}${with_dmalloc:-no}" >&6
    86508933 
    86518934 case .$with_cflags in #(vi
    8652 @@ -10505,7 +10877,7 @@
     8935@@ -10505,7 +10906,7 @@
    86538936 
    86548937 if test -n "$cf_new_cppflags" ; then
     
    86598942 
    86608943 if test -n "$cf_new_extra_cppflags" ; then
    8661 @@ -10519,23 +10891,23 @@
     8944@@ -10519,23 +10920,23 @@
    86628945 esac
    86638946 
    86648947 if test "$with_dmalloc" = yes ; then
    86658948-       echo "$as_me:10522: checking for dmalloc.h" >&5
    8666 +       echo "$as_me:10894: checking for dmalloc.h" >&5
     8949+       echo "$as_me:10923: checking for dmalloc.h" >&5
    86678950 echo $ECHO_N "checking for dmalloc.h... $ECHO_C" >&6
    86688951 if test "${ac_cv_header_dmalloc_h+set}" = set; then
     
    86718954   cat >conftest.$ac_ext <<_ACEOF
    86728955-#line 10528 "configure"
    8673 +#line 10900 "configure"
     8956+#line 10929 "configure"
    86748957 #include "confdefs.h"
    86758958 #include <dmalloc.h>
    86768959 _ACEOF
    86778960-if { (eval echo "$as_me:10532: \"$ac_cpp conftest.$ac_ext\"") >&5
    8678 +if { (eval echo "$as_me:10904: \"$ac_cpp conftest.$ac_ext\"") >&5
     8961+if { (eval echo "$as_me:10933: \"$ac_cpp conftest.$ac_ext\"") >&5
    86798962   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    86808963   ac_status=$?
     
    86838966   cat conftest.err >&5
    86848967-  echo "$as_me:10538: \$? = $ac_status" >&5
    8685 +  echo "$as_me:10910: \$? = $ac_status" >&5
     8968+  echo "$as_me:10939: \$? = $ac_status" >&5
    86868969   (exit $ac_status); } >/dev/null; then
    86878970   if test -s conftest.err; then
    86888971     ac_cpp_err=$ac_c_preproc_warn_flag
    8689 @@ -10554,11 +10926,11 @@
     8972@@ -10554,11 +10955,11 @@
    86908973 fi
    86918974 rm -f conftest.err conftest.$ac_ext
    86928975 fi
    86938976-echo "$as_me:10557: result: $ac_cv_header_dmalloc_h" >&5
    8694 +echo "$as_me:10929: result: $ac_cv_header_dmalloc_h" >&5
     8977+echo "$as_me:10958: result: $ac_cv_header_dmalloc_h" >&5
    86958978 echo "${ECHO_T}$ac_cv_header_dmalloc_h" >&6
    86968979 if test $ac_cv_header_dmalloc_h = yes; then
    86978980 
    86988981-echo "$as_me:10561: checking for dmalloc_debug in -ldmalloc" >&5
    8699 +echo "$as_me:10933: checking for dmalloc_debug in -ldmalloc" >&5
     8982+echo "$as_me:10962: checking for dmalloc_debug in -ldmalloc" >&5
    87008983 echo $ECHO_N "checking for dmalloc_debug in -ldmalloc... $ECHO_C" >&6
    87018984 if test "${ac_cv_lib_dmalloc_dmalloc_debug+set}" = set; then
    87028985   echo $ECHO_N "(cached) $ECHO_C" >&6
    8703 @@ -10566,7 +10938,7 @@
     8986@@ -10566,7 +10967,7 @@
    87048987   ac_check_lib_save_LIBS=$LIBS
    87058988 LIBS="-ldmalloc  $LIBS"
    87068989 cat >conftest.$ac_ext <<_ACEOF
    87078990-#line 10569 "configure"
    8708 +#line 10941 "configure"
     8991+#line 10970 "configure"
    87098992 #include "confdefs.h"
    87108993 
    87118994 /* Override any gcc2 internal prototype to avoid an error.  */
    8712 @@ -10585,16 +10957,16 @@
     8995@@ -10585,16 +10986,16 @@
    87138996 }
    87148997 _ACEOF
    87158998 rm -f conftest.$ac_objext conftest$ac_exeext
    87168999-if { (eval echo "$as_me:10588: \"$ac_link\"") >&5
    8717 +if { (eval echo "$as_me:10960: \"$ac_link\"") >&5
     9000+if { (eval echo "$as_me:10989: \"$ac_link\"") >&5
    87189001   (eval $ac_link) 2>&5
    87199002   ac_status=$?
    87209003-  echo "$as_me:10591: \$? = $ac_status" >&5
    8721 +  echo "$as_me:10963: \$? = $ac_status" >&5
     9004+  echo "$as_me:10992: \$? = $ac_status" >&5
    87229005   (exit $ac_status); } &&
    87239006          { ac_try='test -s conftest$ac_exeext'
    87249007-  { (eval echo "$as_me:10594: \"$ac_try\"") >&5
    8725 +  { (eval echo "$as_me:10966: \"$ac_try\"") >&5
     9008+  { (eval echo "$as_me:10995: \"$ac_try\"") >&5
    87269009   (eval $ac_try) 2>&5
    87279010   ac_status=$?
    87289011-  echo "$as_me:10597: \$? = $ac_status" >&5
    8729 +  echo "$as_me:10969: \$? = $ac_status" >&5
     9012+  echo "$as_me:10998: \$? = $ac_status" >&5
    87309013   (exit $ac_status); }; }; then
    87319014   ac_cv_lib_dmalloc_dmalloc_debug=yes
    87329015 else
    8733 @@ -10605,7 +10977,7 @@
     9016@@ -10605,7 +11006,7 @@
    87349017 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    87359018 LIBS=$ac_check_lib_save_LIBS
    87369019 fi
    87379020-echo "$as_me:10608: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
    8738 +echo "$as_me:10980: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
     9021+echo "$as_me:11009: result: $ac_cv_lib_dmalloc_dmalloc_debug" >&5
    87399022 echo "${ECHO_T}$ac_cv_lib_dmalloc_dmalloc_debug" >&6
    87409023 if test $ac_cv_lib_dmalloc_dmalloc_debug = yes; then
    87419024   cat >>confdefs.h <<EOF
    8742 @@ -10620,7 +10992,7 @@
     9025@@ -10620,7 +11021,7 @@
    87439026 
    87449027 fi
    87459028 
    87469029-echo "$as_me:10623: checking if you want to use dbmalloc for testing" >&5
    8747 +echo "$as_me:10995: checking if you want to use dbmalloc for testing" >&5
     9030+echo "$as_me:11024: checking if you want to use dbmalloc for testing" >&5
    87489031 echo $ECHO_N "checking if you want to use dbmalloc for testing... $ECHO_C" >&6
    87499032 
    87509033 # Check whether --with-dbmalloc or --without-dbmalloc was given.
    8751 @@ -10636,7 +11008,7 @@
     9034@@ -10636,7 +11037,7 @@
    87529035 else
    87539036   with_dbmalloc=
    87549037 fi;
    87559038-echo "$as_me:10639: result: ${with_dbmalloc:-no}" >&5
    8756 +echo "$as_me:11011: result: ${with_dbmalloc:-no}" >&5
     9039+echo "$as_me:11040: result: ${with_dbmalloc:-no}" >&5
    87579040 echo "${ECHO_T}${with_dbmalloc:-no}" >&6
    87589041 
    87599042 case .$with_cflags in #(vi
    8760 @@ -10706,7 +11078,7 @@
     9043@@ -10706,7 +11107,7 @@
    87619044 
    87629045 if test -n "$cf_new_cppflags" ; then
     
    87679050 
    87689051 if test -n "$cf_new_extra_cppflags" ; then
    8769 @@ -10720,23 +11092,23 @@
     9052@@ -10720,23 +11121,23 @@
    87709053 esac
    87719054 
    87729055 if test "$with_dbmalloc" = yes ; then
    87739056-       echo "$as_me:10723: checking for dbmalloc.h" >&5
    8774 +       echo "$as_me:11095: checking for dbmalloc.h" >&5
     9057+       echo "$as_me:11124: checking for dbmalloc.h" >&5
    87759058 echo $ECHO_N "checking for dbmalloc.h... $ECHO_C" >&6
    87769059 if test "${ac_cv_header_dbmalloc_h+set}" = set; then
     
    87799062   cat >conftest.$ac_ext <<_ACEOF
    87809063-#line 10729 "configure"
    8781 +#line 11101 "configure"
     9064+#line 11130 "configure"
    87829065 #include "confdefs.h"
    87839066 #include <dbmalloc.h>
    87849067 _ACEOF
    87859068-if { (eval echo "$as_me:10733: \"$ac_cpp conftest.$ac_ext\"") >&5
    8786 +if { (eval echo "$as_me:11105: \"$ac_cpp conftest.$ac_ext\"") >&5
     9069+if { (eval echo "$as_me:11134: \"$ac_cpp conftest.$ac_ext\"") >&5
    87879070   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    87889071   ac_status=$?
     
    87919074   cat conftest.err >&5
    87929075-  echo "$as_me:10739: \$? = $ac_status" >&5
    8793 +  echo "$as_me:11111: \$? = $ac_status" >&5
     9076+  echo "$as_me:11140: \$? = $ac_status" >&5
    87949077   (exit $ac_status); } >/dev/null; then
    87959078   if test -s conftest.err; then
    87969079     ac_cpp_err=$ac_c_preproc_warn_flag
    8797 @@ -10755,11 +11127,11 @@
     9080@@ -10755,11 +11156,11 @@
    87989081 fi
    87999082 rm -f conftest.err conftest.$ac_ext
    88009083 fi
    88019084-echo "$as_me:10758: result: $ac_cv_header_dbmalloc_h" >&5
    8802 +echo "$as_me:11130: result: $ac_cv_header_dbmalloc_h" >&5
     9085+echo "$as_me:11159: result: $ac_cv_header_dbmalloc_h" >&5
    88039086 echo "${ECHO_T}$ac_cv_header_dbmalloc_h" >&6
    88049087 if test $ac_cv_header_dbmalloc_h = yes; then
    88059088 
    88069089-echo "$as_me:10762: checking for debug_malloc in -ldbmalloc" >&5
    8807 +echo "$as_me:11134: checking for debug_malloc in -ldbmalloc" >&5
     9090+echo "$as_me:11163: checking for debug_malloc in -ldbmalloc" >&5
    88089091 echo $ECHO_N "checking for debug_malloc in -ldbmalloc... $ECHO_C" >&6
    88099092 if test "${ac_cv_lib_dbmalloc_debug_malloc+set}" = set; then
    88109093   echo $ECHO_N "(cached) $ECHO_C" >&6
    8811 @@ -10767,7 +11139,7 @@
     9094@@ -10767,7 +11168,7 @@
    88129095   ac_check_lib_save_LIBS=$LIBS
    88139096 LIBS="-ldbmalloc  $LIBS"
    88149097 cat >conftest.$ac_ext <<_ACEOF
    88159098-#line 10770 "configure"
    8816 +#line 11142 "configure"
     9099+#line 11171 "configure"
    88179100 #include "confdefs.h"
    88189101 
    88199102 /* Override any gcc2 internal prototype to avoid an error.  */
    8820 @@ -10786,16 +11158,16 @@
     9103@@ -10786,16 +11187,16 @@
    88219104 }
    88229105 _ACEOF
    88239106 rm -f conftest.$ac_objext conftest$ac_exeext
    88249107-if { (eval echo "$as_me:10789: \"$ac_link\"") >&5
    8825 +if { (eval echo "$as_me:11161: \"$ac_link\"") >&5
     9108+if { (eval echo "$as_me:11190: \"$ac_link\"") >&5
    88269109   (eval $ac_link) 2>&5
    88279110   ac_status=$?
    88289111-  echo "$as_me:10792: \$? = $ac_status" >&5
    8829 +  echo "$as_me:11164: \$? = $ac_status" >&5
     9112+  echo "$as_me:11193: \$? = $ac_status" >&5
    88309113   (exit $ac_status); } &&
    88319114          { ac_try='test -s conftest$ac_exeext'
    88329115-  { (eval echo "$as_me:10795: \"$ac_try\"") >&5
    8833 +  { (eval echo "$as_me:11167: \"$ac_try\"") >&5
     9116+  { (eval echo "$as_me:11196: \"$ac_try\"") >&5
    88349117   (eval $ac_try) 2>&5
    88359118   ac_status=$?
    88369119-  echo "$as_me:10798: \$? = $ac_status" >&5
    8837 +  echo "$as_me:11170: \$? = $ac_status" >&5
     9120+  echo "$as_me:11199: \$? = $ac_status" >&5
    88389121   (exit $ac_status); }; }; then
    88399122   ac_cv_lib_dbmalloc_debug_malloc=yes
    88409123 else
    8841 @@ -10806,7 +11178,7 @@
     9124@@ -10806,7 +11207,7 @@
    88429125 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    88439126 LIBS=$ac_check_lib_save_LIBS
    88449127 fi
    88459128-echo "$as_me:10809: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
    8846 +echo "$as_me:11181: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
     9129+echo "$as_me:11210: result: $ac_cv_lib_dbmalloc_debug_malloc" >&5
    88479130 echo "${ECHO_T}$ac_cv_lib_dbmalloc_debug_malloc" >&6
    88489131 if test $ac_cv_lib_dbmalloc_debug_malloc = yes; then
    88499132   cat >>confdefs.h <<EOF
    8850 @@ -10821,7 +11193,7 @@
     9133@@ -10821,7 +11222,7 @@
    88519134 
    88529135 fi
    88539136 
    88549137-echo "$as_me:10824: checking if you want to use valgrind for testing" >&5
    8855 +echo "$as_me:11196: checking if you want to use valgrind for testing" >&5
     9138+echo "$as_me:11225: checking if you want to use valgrind for testing" >&5
    88569139 echo $ECHO_N "checking if you want to use valgrind for testing... $ECHO_C" >&6
    88579140 
    88589141 # Check whether --with-valgrind or --without-valgrind was given.
    8859 @@ -10837,7 +11209,7 @@
     9142@@ -10837,7 +11238,7 @@
    88609143 else
    88619144   with_valgrind=
    88629145 fi;
    88639146-echo "$as_me:10840: result: ${with_valgrind:-no}" >&5
    8864 +echo "$as_me:11212: result: ${with_valgrind:-no}" >&5
     9147+echo "$as_me:11241: result: ${with_valgrind:-no}" >&5
    88659148 echo "${ECHO_T}${with_valgrind:-no}" >&6
    88669149 
    88679150 case .$with_cflags in #(vi
    8868 @@ -10907,7 +11279,7 @@
     9151@@ -10907,7 +11308,7 @@
    88699152 
    88709153 if test -n "$cf_new_cppflags" ; then
     
    88759158 
    88769159 if test -n "$cf_new_extra_cppflags" ; then
    8877 @@ -10920,7 +11292,7 @@
     9160@@ -10920,7 +11321,7 @@
    88789161        ;;
    88799162 esac
    88809163 
    88819164-echo "$as_me:10923: checking if you want to perform memory-leak testing" >&5
    8882 +echo "$as_me:11295: checking if you want to perform memory-leak testing" >&5
     9165+echo "$as_me:11324: checking if you want to perform memory-leak testing" >&5
    88839166 echo $ECHO_N "checking if you want to perform memory-leak testing... $ECHO_C" >&6
    88849167 
    88859168 # Check whether --enable-leaks or --disable-leaks was given.
    8886 @@ -10930,7 +11302,7 @@
     9169@@ -10930,7 +11331,7 @@
    88879170 else
    88889171   : ${with_no_leaks:=no}
    88899172 fi;
    88909173-echo "$as_me:10933: result: $with_no_leaks" >&5
    8891 +echo "$as_me:11305: result: $with_no_leaks" >&5
     9174+echo "$as_me:11334: result: $with_no_leaks" >&5
    88929175 echo "${ECHO_T}$with_no_leaks" >&6
    88939176 
    88949177 if test "$with_no_leaks" = yes ; then
    8895 @@ -10975,7 +11347,7 @@
     9178@@ -10975,7 +11376,7 @@
    88969179        ;;
    88979180 esac
    88989181 
    88999182-echo "$as_me:10978: checking whether to add trace feature to all models" >&5
    8900 +echo "$as_me:11350: checking whether to add trace feature to all models" >&5
     9183+echo "$as_me:11379: checking whether to add trace feature to all models" >&5
    89019184 echo $ECHO_N "checking whether to add trace feature to all models... $ECHO_C" >&6
    89029185 
    89039186 # Check whether --with-trace or --without-trace was given.
    8904 @@ -10985,7 +11357,7 @@
     9187@@ -10985,7 +11386,7 @@
    89059188 else
    89069189   cf_with_trace=$cf_all_traces
    89079190 fi;
    89089191-echo "$as_me:10988: result: $cf_with_trace" >&5
    8909 +echo "$as_me:11360: result: $cf_with_trace" >&5
     9192+echo "$as_me:11389: result: $cf_with_trace" >&5
    89109193 echo "${ECHO_T}$cf_with_trace" >&6
    89119194 
    89129195 if test "$cf_with_trace" = yes ; then
    8913 @@ -11052,7 +11424,7 @@
     9196@@ -11052,7 +11453,7 @@
    89149197 
    89159198 if test -n "$cf_new_cppflags" ; then
     
    89209203 
    89219204 if test -n "$cf_new_extra_cppflags" ; then
    8922 @@ -11066,13 +11438,17 @@
     9205@@ -11066,13 +11467,17 @@
    89239206 fi
    89249207 
     
    89299212+       ;;
    89309213+*)
    8931 +echo "$as_me:11445: checking for gettimeofday" >&5
     9214+echo "$as_me:11474: checking for gettimeofday" >&5
    89329215 echo $ECHO_N "checking for gettimeofday... $ECHO_C" >&6
    89339216 if test "${ac_cv_func_gettimeofday+set}" = set; then
     
    89369219   cat >conftest.$ac_ext <<_ACEOF
    89379220-#line 11075 "configure"
    8938 +#line 11451 "configure"
     9221+#line 11480 "configure"
    89399222 #include "confdefs.h"
    89409223 /* System header to define __stub macros and hopefully few prototypes,
    89419224     which can conflict with char gettimeofday (); below.  */
    8942 @@ -11103,16 +11479,16 @@
     9225@@ -11103,16 +11508,16 @@
    89439226 }
    89449227 _ACEOF
    89459228 rm -f conftest.$ac_objext conftest$ac_exeext
    89469229-if { (eval echo "$as_me:11106: \"$ac_link\"") >&5
    8947 +if { (eval echo "$as_me:11482: \"$ac_link\"") >&5
     9230+if { (eval echo "$as_me:11511: \"$ac_link\"") >&5
    89489231   (eval $ac_link) 2>&5
    89499232   ac_status=$?
    89509233-  echo "$as_me:11109: \$? = $ac_status" >&5
    8951 +  echo "$as_me:11485: \$? = $ac_status" >&5
     9234+  echo "$as_me:11514: \$? = $ac_status" >&5
    89529235   (exit $ac_status); } &&
    89539236          { ac_try='test -s conftest$ac_exeext'
    89549237-  { (eval echo "$as_me:11112: \"$ac_try\"") >&5
    8955 +  { (eval echo "$as_me:11488: \"$ac_try\"") >&5
     9238+  { (eval echo "$as_me:11517: \"$ac_try\"") >&5
    89569239   (eval $ac_try) 2>&5
    89579240   ac_status=$?
    89589241-  echo "$as_me:11115: \$? = $ac_status" >&5
    8959 +  echo "$as_me:11491: \$? = $ac_status" >&5
     9242+  echo "$as_me:11520: \$? = $ac_status" >&5
    89609243   (exit $ac_status); }; }; then
    89619244   ac_cv_func_gettimeofday=yes
    89629245 else
    8963 @@ -11122,7 +11498,7 @@
     9246@@ -11122,7 +11527,7 @@
    89649247 fi
    89659248 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    89669249 fi
    89679250-echo "$as_me:11125: result: $ac_cv_func_gettimeofday" >&5
    8968 +echo "$as_me:11501: result: $ac_cv_func_gettimeofday" >&5
     9251+echo "$as_me:11530: result: $ac_cv_func_gettimeofday" >&5
    89699252 echo "${ECHO_T}$ac_cv_func_gettimeofday" >&6
    89709253 if test $ac_cv_func_gettimeofday = yes; then
    89719254   cat >>confdefs.h <<\EOF
    8972 @@ -11131,7 +11507,7 @@
     9255@@ -11131,7 +11536,7 @@
    89739256 
    89749257 else
    89759258 
    89769259-echo "$as_me:11134: checking for gettimeofday in -lbsd" >&5
    8977 +echo "$as_me:11510: checking for gettimeofday in -lbsd" >&5
     9260+echo "$as_me:11539: checking for gettimeofday in -lbsd" >&5
    89789261 echo $ECHO_N "checking for gettimeofday in -lbsd... $ECHO_C" >&6
    89799262 if test "${ac_cv_lib_bsd_gettimeofday+set}" = set; then
    89809263   echo $ECHO_N "(cached) $ECHO_C" >&6
    8981 @@ -11139,7 +11515,7 @@
     9264@@ -11139,7 +11544,7 @@
    89829265   ac_check_lib_save_LIBS=$LIBS
    89839266 LIBS="-lbsd  $LIBS"
    89849267 cat >conftest.$ac_ext <<_ACEOF
    89859268-#line 11142 "configure"
    8986 +#line 11518 "configure"
     9269+#line 11547 "configure"
    89879270 #include "confdefs.h"
    89889271 
    89899272 /* Override any gcc2 internal prototype to avoid an error.  */
    8990 @@ -11158,16 +11534,16 @@
     9273@@ -11158,16 +11563,16 @@
    89919274 }
    89929275 _ACEOF
    89939276 rm -f conftest.$ac_objext conftest$ac_exeext
    89949277-if { (eval echo "$as_me:11161: \"$ac_link\"") >&5
    8995 +if { (eval echo "$as_me:11537: \"$ac_link\"") >&5
     9278+if { (eval echo "$as_me:11566: \"$ac_link\"") >&5
    89969279   (eval $ac_link) 2>&5
    89979280   ac_status=$?
    89989281-  echo "$as_me:11164: \$? = $ac_status" >&5
    8999 +  echo "$as_me:11540: \$? = $ac_status" >&5
     9282+  echo "$as_me:11569: \$? = $ac_status" >&5
    90009283   (exit $ac_status); } &&
    90019284          { ac_try='test -s conftest$ac_exeext'
    90029285-  { (eval echo "$as_me:11167: \"$ac_try\"") >&5
    9003 +  { (eval echo "$as_me:11543: \"$ac_try\"") >&5
     9286+  { (eval echo "$as_me:11572: \"$ac_try\"") >&5
    90049287   (eval $ac_try) 2>&5
    90059288   ac_status=$?
    90069289-  echo "$as_me:11170: \$? = $ac_status" >&5
    9007 +  echo "$as_me:11546: \$? = $ac_status" >&5
     9290+  echo "$as_me:11575: \$? = $ac_status" >&5
    90089291   (exit $ac_status); }; }; then
    90099292   ac_cv_lib_bsd_gettimeofday=yes
    90109293 else
    9011 @@ -11178,7 +11554,7 @@
     9294@@ -11178,7 +11583,7 @@
    90129295 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    90139296 LIBS=$ac_check_lib_save_LIBS
    90149297 fi
    90159298-echo "$as_me:11181: result: $ac_cv_lib_bsd_gettimeofday" >&5
    9016 +echo "$as_me:11557: result: $ac_cv_lib_bsd_gettimeofday" >&5
     9299+echo "$as_me:11586: result: $ac_cv_lib_bsd_gettimeofday" >&5
    90179300 echo "${ECHO_T}$ac_cv_lib_bsd_gettimeofday" >&6
    90189301 if test $ac_cv_lib_bsd_gettimeofday = yes; then
    90199302   cat >>confdefs.h <<\EOF
    9020 @@ -11189,15 +11565,17 @@
     9303@@ -11189,15 +11594,17 @@
    90219304 fi
    90229305 
     
    90269309 
    90279310-echo "$as_me:11193: checking if -lm needed for math functions" >&5
    9028 +echo "$as_me:11571: checking if -lm needed for math functions" >&5
     9311+echo "$as_me:11600: checking if -lm needed for math functions" >&5
    90299312 echo $ECHO_N "checking if -lm needed for math functions... $ECHO_C" >&6
    90309313 if test "${cf_cv_need_libm+set}" = set; then
     
    90349317        cat >conftest.$ac_ext <<_ACEOF
    90359318-#line 11200 "configure"
    9036 +#line 11578 "configure"
     9319+#line 11607 "configure"
    90379320 #include "confdefs.h"
    90389321 
    90399322        #include <stdio.h>
    9040 @@ -11212,16 +11590,16 @@
     9323@@ -11212,16 +11619,16 @@
    90419324 }
    90429325 _ACEOF
    90439326 rm -f conftest.$ac_objext conftest$ac_exeext
    90449327-if { (eval echo "$as_me:11215: \"$ac_link\"") >&5
    9045 +if { (eval echo "$as_me:11593: \"$ac_link\"") >&5
     9328+if { (eval echo "$as_me:11622: \"$ac_link\"") >&5
    90469329   (eval $ac_link) 2>&5
    90479330   ac_status=$?
    90489331-  echo "$as_me:11218: \$? = $ac_status" >&5
    9049 +  echo "$as_me:11596: \$? = $ac_status" >&5
     9332+  echo "$as_me:11625: \$? = $ac_status" >&5
    90509333   (exit $ac_status); } &&
    90519334          { ac_try='test -s conftest$ac_exeext'
    90529335-  { (eval echo "$as_me:11221: \"$ac_try\"") >&5
    9053 +  { (eval echo "$as_me:11599: \"$ac_try\"") >&5
     9336+  { (eval echo "$as_me:11628: \"$ac_try\"") >&5
    90549337   (eval $ac_try) 2>&5
    90559338   ac_status=$?
    90569339-  echo "$as_me:11224: \$? = $ac_status" >&5
    9057 +  echo "$as_me:11602: \$? = $ac_status" >&5
     9340+  echo "$as_me:11631: \$? = $ac_status" >&5
    90589341   (exit $ac_status); }; }; then
    90599342   cf_cv_need_libm=no
    90609343 else
    9061 @@ -11231,7 +11609,7 @@
     9344@@ -11231,7 +11638,7 @@
    90629345 fi
    90639346 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    90649347 fi
    90659348-echo "$as_me:11234: result: $cf_cv_need_libm" >&5
    9066 +echo "$as_me:11612: result: $cf_cv_need_libm" >&5
     9349+echo "$as_me:11641: result: $cf_cv_need_libm" >&5
    90679350 echo "${ECHO_T}$cf_cv_need_libm" >&6
    90689351 if test "$cf_cv_need_libm" = yes
    90699352 then
    9070 @@ -11239,13 +11617,13 @@
     9353@@ -11239,13 +11646,13 @@
    90719354 fi
    90729355 
    90739356 ###    Checks for header files.
    90749357-echo "$as_me:11242: checking for ANSI C header files" >&5
    9075 +echo "$as_me:11620: checking for ANSI C header files" >&5
     9358+echo "$as_me:11649: checking for ANSI C header files" >&5
    90769359 echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6
    90779360 if test "${ac_cv_header_stdc+set}" = set; then
     
    90809363   cat >conftest.$ac_ext <<_ACEOF
    90819364-#line 11248 "configure"
    9082 +#line 11626 "configure"
     9365+#line 11655 "configure"
    90839366 #include "confdefs.h"
    90849367 #include <stdlib.h>
    90859368 #include <stdarg.h>
    9086 @@ -11253,13 +11631,13 @@
     9369@@ -11253,13 +11660,13 @@
    90879370 #include <float.h>
    90889371 
    90899372 _ACEOF
    90909373-if { (eval echo "$as_me:11256: \"$ac_cpp conftest.$ac_ext\"") >&5
    9091 +if { (eval echo "$as_me:11634: \"$ac_cpp conftest.$ac_ext\"") >&5
     9374+if { (eval echo "$as_me:11663: \"$ac_cpp conftest.$ac_ext\"") >&5
    90929375   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    90939376   ac_status=$?
     
    90969379   cat conftest.err >&5
    90979380-  echo "$as_me:11262: \$? = $ac_status" >&5
    9098 +  echo "$as_me:11640: \$? = $ac_status" >&5
     9381+  echo "$as_me:11669: \$? = $ac_status" >&5
    90999382   (exit $ac_status); } >/dev/null; then
    91009383   if test -s conftest.err; then
    91019384     ac_cpp_err=$ac_c_preproc_warn_flag
    9102 @@ -11281,7 +11659,7 @@
     9385@@ -11281,7 +11688,7 @@
    91039386 if test $ac_cv_header_stdc = yes; then
    91049387   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
    91059388   cat >conftest.$ac_ext <<_ACEOF
    91069389-#line 11284 "configure"
    9107 +#line 11662 "configure"
     9390+#line 11691 "configure"
    91089391 #include "confdefs.h"
    91099392 #include <string.h>
    91109393 
    9111 @@ -11299,7 +11677,7 @@
     9394@@ -11299,7 +11706,7 @@
    91129395 if test $ac_cv_header_stdc = yes; then
    91139396   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
    91149397   cat >conftest.$ac_ext <<_ACEOF
    91159398-#line 11302 "configure"
    9116 +#line 11680 "configure"
     9399+#line 11709 "configure"
    91179400 #include "confdefs.h"
    91189401 #include <stdlib.h>
    91199402 
    9120 @@ -11320,7 +11698,7 @@
     9403@@ -11320,7 +11727,7 @@
    91219404   :
    91229405 else
    91239406   cat >conftest.$ac_ext <<_ACEOF
    91249407-#line 11323 "configure"
    9125 +#line 11701 "configure"
     9408+#line 11730 "configure"
    91269409 #include "confdefs.h"
    91279410 #include <ctype.h>
    91289411 #if ((' ' & 0x0FF) == 0x020)
    9129 @@ -11346,15 +11724,15 @@
     9412@@ -11346,15 +11753,15 @@
    91309413 }
    91319414 _ACEOF
    91329415 rm -f conftest$ac_exeext
    91339416-if { (eval echo "$as_me:11349: \"$ac_link\"") >&5
    9134 +if { (eval echo "$as_me:11727: \"$ac_link\"") >&5
     9417+if { (eval echo "$as_me:11756: \"$ac_link\"") >&5
    91359418   (eval $ac_link) 2>&5
    91369419   ac_status=$?
    91379420-  echo "$as_me:11352: \$? = $ac_status" >&5
    9138 +  echo "$as_me:11730: \$? = $ac_status" >&5
     9421+  echo "$as_me:11759: \$? = $ac_status" >&5
    91399422   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    91409423-  { (eval echo "$as_me:11354: \"$ac_try\"") >&5
    9141 +  { (eval echo "$as_me:11732: \"$ac_try\"") >&5
     9424+  { (eval echo "$as_me:11761: \"$ac_try\"") >&5
    91429425   (eval $ac_try) 2>&5
    91439426   ac_status=$?
    91449427-  echo "$as_me:11357: \$? = $ac_status" >&5
    9145 +  echo "$as_me:11735: \$? = $ac_status" >&5
     9428+  echo "$as_me:11764: \$? = $ac_status" >&5
    91469429   (exit $ac_status); }; }; then
    91479430   :
    91489431 else
    9149 @@ -11367,7 +11745,7 @@
     9432@@ -11367,7 +11774,7 @@
    91509433 fi
    91519434 fi
    91529435 fi
    91539436-echo "$as_me:11370: result: $ac_cv_header_stdc" >&5
    9154 +echo "$as_me:11748: result: $ac_cv_header_stdc" >&5
     9437+echo "$as_me:11777: result: $ac_cv_header_stdc" >&5
    91559438 echo "${ECHO_T}$ac_cv_header_stdc" >&6
    91569439 if test $ac_cv_header_stdc = yes; then
    91579440 
    9158 @@ -11380,13 +11758,13 @@
     9441@@ -11380,13 +11787,13 @@
    91599442 ac_header_dirent=no
    91609443 for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h; do
    91619444   as_ac_Header=`echo "ac_cv_header_dirent_$ac_hdr" | $as_tr_sh`
    91629445-echo "$as_me:11383: checking for $ac_hdr that defines DIR" >&5
    9163 +echo "$as_me:11761: checking for $ac_hdr that defines DIR" >&5
     9446+echo "$as_me:11790: checking for $ac_hdr that defines DIR" >&5
    91649447 echo $ECHO_N "checking for $ac_hdr that defines DIR... $ECHO_C" >&6
    91659448 if eval "test \"\${$as_ac_Header+set}\" = set"; then
     
    91689451   cat >conftest.$ac_ext <<_ACEOF
    91699452-#line 11389 "configure"
    9170 +#line 11767 "configure"
     9453+#line 11796 "configure"
    91719454 #include "confdefs.h"
    91729455 #include <sys/types.h>
    91739456 #include <$ac_hdr>
    9174 @@ -11401,16 +11779,16 @@
     9457@@ -11401,16 +11808,16 @@
    91759458 }
    91769459 _ACEOF
    91779460 rm -f conftest.$ac_objext
    91789461-if { (eval echo "$as_me:11404: \"$ac_compile\"") >&5
    9179 +if { (eval echo "$as_me:11782: \"$ac_compile\"") >&5
     9462+if { (eval echo "$as_me:11811: \"$ac_compile\"") >&5
    91809463   (eval $ac_compile) 2>&5
    91819464   ac_status=$?
    91829465-  echo "$as_me:11407: \$? = $ac_status" >&5
    9183 +  echo "$as_me:11785: \$? = $ac_status" >&5
     9466+  echo "$as_me:11814: \$? = $ac_status" >&5
    91849467   (exit $ac_status); } &&
    91859468          { ac_try='test -s conftest.$ac_objext'
    91869469-  { (eval echo "$as_me:11410: \"$ac_try\"") >&5
    9187 +  { (eval echo "$as_me:11788: \"$ac_try\"") >&5
     9470+  { (eval echo "$as_me:11817: \"$ac_try\"") >&5
    91889471   (eval $ac_try) 2>&5
    91899472   ac_status=$?
    91909473-  echo "$as_me:11413: \$? = $ac_status" >&5
    9191 +  echo "$as_me:11791: \$? = $ac_status" >&5
     9474+  echo "$as_me:11820: \$? = $ac_status" >&5
    91929475   (exit $ac_status); }; }; then
    91939476   eval "$as_ac_Header=yes"
    91949477 else
    9195 @@ -11420,7 +11798,7 @@
     9478@@ -11420,7 +11827,7 @@
    91969479 fi
    91979480 rm -f conftest.$ac_objext conftest.$ac_ext
    91989481 fi
    91999482-echo "$as_me:11423: result: `eval echo '${'$as_ac_Header'}'`" >&5
    9200 +echo "$as_me:11801: result: `eval echo '${'$as_ac_Header'}'`" >&5
     9483+echo "$as_me:11830: result: `eval echo '${'$as_ac_Header'}'`" >&5
    92019484 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
    92029485 if test `eval echo '${'$as_ac_Header'}'` = yes; then
    92039486   cat >>confdefs.h <<EOF
    9204 @@ -11433,7 +11811,7 @@
     9487@@ -11433,7 +11840,7 @@
    92059488 done
    92069489 # Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
    92079490 if test $ac_header_dirent = dirent.h; then
    92089491-  echo "$as_me:11436: checking for opendir in -ldir" >&5
    9209 +  echo "$as_me:11814: checking for opendir in -ldir" >&5
     9492+  echo "$as_me:11843: checking for opendir in -ldir" >&5
    92109493 echo $ECHO_N "checking for opendir in -ldir... $ECHO_C" >&6
    92119494 if test "${ac_cv_lib_dir_opendir+set}" = set; then
    92129495   echo $ECHO_N "(cached) $ECHO_C" >&6
    9213 @@ -11441,7 +11819,7 @@
     9496@@ -11441,7 +11848,7 @@
    92149497   ac_check_lib_save_LIBS=$LIBS
    92159498 LIBS="-ldir  $LIBS"
    92169499 cat >conftest.$ac_ext <<_ACEOF
    92179500-#line 11444 "configure"
    9218 +#line 11822 "configure"
     9501+#line 11851 "configure"
    92199502 #include "confdefs.h"
    92209503 
    92219504 /* Override any gcc2 internal prototype to avoid an error.  */
    9222 @@ -11460,16 +11838,16 @@
     9505@@ -11460,16 +11867,16 @@
    92239506 }
    92249507 _ACEOF
    92259508 rm -f conftest.$ac_objext conftest$ac_exeext
    92269509-if { (eval echo "$as_me:11463: \"$ac_link\"") >&5
    9227 +if { (eval echo "$as_me:11841: \"$ac_link\"") >&5
     9510+if { (eval echo "$as_me:11870: \"$ac_link\"") >&5
    92289511   (eval $ac_link) 2>&5
    92299512   ac_status=$?
    92309513-  echo "$as_me:11466: \$? = $ac_status" >&5
    9231 +  echo "$as_me:11844: \$? = $ac_status" >&5
     9514+  echo "$as_me:11873: \$? = $ac_status" >&5
    92329515   (exit $ac_status); } &&
    92339516          { ac_try='test -s conftest$ac_exeext'
    92349517-  { (eval echo "$as_me:11469: \"$ac_try\"") >&5
    9235 +  { (eval echo "$as_me:11847: \"$ac_try\"") >&5
     9518+  { (eval echo "$as_me:11876: \"$ac_try\"") >&5
    92369519   (eval $ac_try) 2>&5
    92379520   ac_status=$?
    92389521-  echo "$as_me:11472: \$? = $ac_status" >&5
    9239 +  echo "$as_me:11850: \$? = $ac_status" >&5
     9522+  echo "$as_me:11879: \$? = $ac_status" >&5
    92409523   (exit $ac_status); }; }; then
    92419524   ac_cv_lib_dir_opendir=yes
    92429525 else
    9243 @@ -11480,14 +11858,14 @@
     9526@@ -11480,14 +11887,14 @@
    92449527 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    92459528 LIBS=$ac_check_lib_save_LIBS
    92469529 fi
    92479530-echo "$as_me:11483: result: $ac_cv_lib_dir_opendir" >&5
    9248 +echo "$as_me:11861: result: $ac_cv_lib_dir_opendir" >&5
     9531+echo "$as_me:11890: result: $ac_cv_lib_dir_opendir" >&5
    92499532 echo "${ECHO_T}$ac_cv_lib_dir_opendir" >&6
    92509533 if test $ac_cv_lib_dir_opendir = yes; then
     
    92549537 else
    92559538-  echo "$as_me:11490: checking for opendir in -lx" >&5
    9256 +  echo "$as_me:11868: checking for opendir in -lx" >&5
     9539+  echo "$as_me:11897: checking for opendir in -lx" >&5
    92579540 echo $ECHO_N "checking for opendir in -lx... $ECHO_C" >&6
    92589541 if test "${ac_cv_lib_x_opendir+set}" = set; then
    92599542   echo $ECHO_N "(cached) $ECHO_C" >&6
    9260 @@ -11495,7 +11873,7 @@
     9543@@ -11495,7 +11902,7 @@
    92619544   ac_check_lib_save_LIBS=$LIBS
    92629545 LIBS="-lx  $LIBS"
    92639546 cat >conftest.$ac_ext <<_ACEOF
    92649547-#line 11498 "configure"
    9265 +#line 11876 "configure"
     9548+#line 11905 "configure"
    92669549 #include "confdefs.h"
    92679550 
    92689551 /* Override any gcc2 internal prototype to avoid an error.  */
    9269 @@ -11514,16 +11892,16 @@
     9552@@ -11514,16 +11921,16 @@
    92709553 }
    92719554 _ACEOF
    92729555 rm -f conftest.$ac_objext conftest$ac_exeext
    92739556-if { (eval echo "$as_me:11517: \"$ac_link\"") >&5
    9274 +if { (eval echo "$as_me:11895: \"$ac_link\"") >&5
     9557+if { (eval echo "$as_me:11924: \"$ac_link\"") >&5
    92759558   (eval $ac_link) 2>&5
    92769559   ac_status=$?
    92779560-  echo "$as_me:11520: \$? = $ac_status" >&5
    9278 +  echo "$as_me:11898: \$? = $ac_status" >&5
     9561+  echo "$as_me:11927: \$? = $ac_status" >&5
    92799562   (exit $ac_status); } &&
    92809563          { ac_try='test -s conftest$ac_exeext'
    92819564-  { (eval echo "$as_me:11523: \"$ac_try\"") >&5
    9282 +  { (eval echo "$as_me:11901: \"$ac_try\"") >&5
     9565+  { (eval echo "$as_me:11930: \"$ac_try\"") >&5
    92839566   (eval $ac_try) 2>&5
    92849567   ac_status=$?
    92859568-  echo "$as_me:11526: \$? = $ac_status" >&5
    9286 +  echo "$as_me:11904: \$? = $ac_status" >&5
     9569+  echo "$as_me:11933: \$? = $ac_status" >&5
    92879570   (exit $ac_status); }; }; then
    92889571   ac_cv_lib_x_opendir=yes
    92899572 else
    9290 @@ -11534,7 +11912,7 @@
     9573@@ -11534,7 +11941,7 @@
    92919574 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    92929575 LIBS=$ac_check_lib_save_LIBS
    92939576 fi
    92949577-echo "$as_me:11537: result: $ac_cv_lib_x_opendir" >&5
    9295 +echo "$as_me:11915: result: $ac_cv_lib_x_opendir" >&5
     9578+echo "$as_me:11944: result: $ac_cv_lib_x_opendir" >&5
    92969579 echo "${ECHO_T}$ac_cv_lib_x_opendir" >&6
    92979580 if test $ac_cv_lib_x_opendir = yes; then
    92989581   LIBS="$LIBS -lx"
    9299 @@ -11542,13 +11920,13 @@
     9582@@ -11542,13 +11949,13 @@
    93009583 
    93019584 fi
    93029585 
    93039586-echo "$as_me:11545: checking whether time.h and sys/time.h may both be included" >&5
    9304 +echo "$as_me:11923: checking whether time.h and sys/time.h may both be included" >&5
     9587+echo "$as_me:11952: checking whether time.h and sys/time.h may both be included" >&5
    93059588 echo $ECHO_N "checking whether time.h and sys/time.h may both be included... $ECHO_C" >&6
    93069589 if test "${ac_cv_header_time+set}" = set; then
     
    93099592   cat >conftest.$ac_ext <<_ACEOF
    93109593-#line 11551 "configure"
    9311 +#line 11929 "configure"
     9594+#line 11958 "configure"
    93129595 #include "confdefs.h"
    93139596 #include <sys/types.h>
    93149597 #include <sys/time.h>
    9315 @@ -11564,16 +11942,16 @@
     9598@@ -11564,16 +11971,16 @@
    93169599 }
    93179600 _ACEOF
    93189601 rm -f conftest.$ac_objext
    93199602-if { (eval echo "$as_me:11567: \"$ac_compile\"") >&5
    9320 +if { (eval echo "$as_me:11945: \"$ac_compile\"") >&5
     9603+if { (eval echo "$as_me:11974: \"$ac_compile\"") >&5
    93219604   (eval $ac_compile) 2>&5
    93229605   ac_status=$?
    93239606-  echo "$as_me:11570: \$? = $ac_status" >&5
    9324 +  echo "$as_me:11948: \$? = $ac_status" >&5
     9607+  echo "$as_me:11977: \$? = $ac_status" >&5
    93259608   (exit $ac_status); } &&
    93269609          { ac_try='test -s conftest.$ac_objext'
    93279610-  { (eval echo "$as_me:11573: \"$ac_try\"") >&5
    9328 +  { (eval echo "$as_me:11951: \"$ac_try\"") >&5
     9611+  { (eval echo "$as_me:11980: \"$ac_try\"") >&5
    93299612   (eval $ac_try) 2>&5
    93309613   ac_status=$?
    93319614-  echo "$as_me:11576: \$? = $ac_status" >&5
    9332 +  echo "$as_me:11954: \$? = $ac_status" >&5
     9615+  echo "$as_me:11983: \$? = $ac_status" >&5
    93339616   (exit $ac_status); }; }; then
    93349617   ac_cv_header_time=yes
    93359618 else
    9336 @@ -11583,7 +11961,7 @@
     9619@@ -11583,7 +11990,7 @@
    93379620 fi
    93389621 rm -f conftest.$ac_objext conftest.$ac_ext
    93399622 fi
    93409623-echo "$as_me:11586: result: $ac_cv_header_time" >&5
    9341 +echo "$as_me:11964: result: $ac_cv_header_time" >&5
     9624+echo "$as_me:11993: result: $ac_cv_header_time" >&5
    93429625 echo "${ECHO_T}$ac_cv_header_time" >&6
    93439626 if test $ac_cv_header_time = yes; then
    93449627 
    9345 @@ -11593,14 +11971,14 @@
     9628@@ -11593,14 +12000,14 @@
    93469629 
    93479630 fi
    93489631 
    93499632-echo "$as_me:11596: checking for regular-expression headers" >&5
    9350 +echo "$as_me:11974: checking for regular-expression headers" >&5
     9633+echo "$as_me:12003: checking for regular-expression headers" >&5
    93519634 echo $ECHO_N "checking for regular-expression headers... $ECHO_C" >&6
    93529635 if test "${cf_cv_regex+set}" = set; then
     
    93569639 cat >conftest.$ac_ext <<_ACEOF
    93579640-#line 11603 "configure"
    9358 +#line 11981 "configure"
     9641+#line 12010 "configure"
    93599642 #include "confdefs.h"
    93609643 #include <sys/types.h>
    93619644 #include <regex.h>
    9362 @@ -11618,16 +11996,16 @@
     9645@@ -11618,16 +12025,16 @@
    93639646 }
    93649647 _ACEOF
    93659648 rm -f conftest.$ac_objext conftest$ac_exeext
    93669649-if { (eval echo "$as_me:11621: \"$ac_link\"") >&5
    9367 +if { (eval echo "$as_me:11999: \"$ac_link\"") >&5
     9650+if { (eval echo "$as_me:12028: \"$ac_link\"") >&5
    93689651   (eval $ac_link) 2>&5
    93699652   ac_status=$?
    93709653-  echo "$as_me:11624: \$? = $ac_status" >&5
    9371 +  echo "$as_me:12002: \$? = $ac_status" >&5
     9654+  echo "$as_me:12031: \$? = $ac_status" >&5
    93729655   (exit $ac_status); } &&
    93739656          { ac_try='test -s conftest$ac_exeext'
    93749657-  { (eval echo "$as_me:11627: \"$ac_try\"") >&5
    9375 +  { (eval echo "$as_me:12005: \"$ac_try\"") >&5
     9658+  { (eval echo "$as_me:12034: \"$ac_try\"") >&5
    93769659   (eval $ac_try) 2>&5
    93779660   ac_status=$?
    93789661-  echo "$as_me:11630: \$? = $ac_status" >&5
    9379 +  echo "$as_me:12008: \$? = $ac_status" >&5
     9662+  echo "$as_me:12037: \$? = $ac_status" >&5
    93809663   (exit $ac_status); }; }; then
    93819664   cf_cv_regex="regex.h"
    93829665 else
    9383 @@ -11635,7 +12013,7 @@
     9666@@ -11635,7 +12042,7 @@
    93849667 cat conftest.$ac_ext >&5
    93859668 
    93869669        cat >conftest.$ac_ext <<_ACEOF
    93879670-#line 11638 "configure"
    9388 +#line 12016 "configure"
     9671+#line 12045 "configure"
    93899672 #include "confdefs.h"
    93909673 #include <regexp.h>
    93919674 int
    9392 @@ -11650,16 +12028,16 @@
     9675@@ -11650,16 +12057,16 @@
    93939676 }
    93949677 _ACEOF
    93959678 rm -f conftest.$ac_objext conftest$ac_exeext
    93969679-if { (eval echo "$as_me:11653: \"$ac_link\"") >&5
    9397 +if { (eval echo "$as_me:12031: \"$ac_link\"") >&5
     9680+if { (eval echo "$as_me:12060: \"$ac_link\"") >&5
    93989681   (eval $ac_link) 2>&5
    93999682   ac_status=$?
    94009683-  echo "$as_me:11656: \$? = $ac_status" >&5
    9401 +  echo "$as_me:12034: \$? = $ac_status" >&5
     9684+  echo "$as_me:12063: \$? = $ac_status" >&5
    94029685   (exit $ac_status); } &&
    94039686          { ac_try='test -s conftest$ac_exeext'
    94049687-  { (eval echo "$as_me:11659: \"$ac_try\"") >&5
    9405 +  { (eval echo "$as_me:12037: \"$ac_try\"") >&5
     9688+  { (eval echo "$as_me:12066: \"$ac_try\"") >&5
    94069689   (eval $ac_try) 2>&5
    94079690   ac_status=$?
    94089691-  echo "$as_me:11662: \$? = $ac_status" >&5
    9409 +  echo "$as_me:12040: \$? = $ac_status" >&5
     9692+  echo "$as_me:12069: \$? = $ac_status" >&5
    94109693   (exit $ac_status); }; }; then
    94119694   cf_cv_regex="regexp.h"
    94129695 else
    9413 @@ -11669,7 +12047,7 @@
     9696@@ -11669,7 +12076,7 @@
    94149697                cf_save_LIBS="$LIBS"
    94159698                LIBS="-lgen $LIBS"
    94169699                cat >conftest.$ac_ext <<_ACEOF
    94179700-#line 11672 "configure"
    9418 +#line 12050 "configure"
     9701+#line 12079 "configure"
    94199702 #include "confdefs.h"
    94209703 #include <regexpr.h>
    94219704 int
    9422 @@ -11684,16 +12062,16 @@
     9705@@ -11684,16 +12091,16 @@
    94239706 }
    94249707 _ACEOF
    94259708 rm -f conftest.$ac_objext conftest$ac_exeext
    94269709-if { (eval echo "$as_me:11687: \"$ac_link\"") >&5
    9427 +if { (eval echo "$as_me:12065: \"$ac_link\"") >&5
     9710+if { (eval echo "$as_me:12094: \"$ac_link\"") >&5
    94289711   (eval $ac_link) 2>&5
    94299712   ac_status=$?
    94309713-  echo "$as_me:11690: \$? = $ac_status" >&5
    9431 +  echo "$as_me:12068: \$? = $ac_status" >&5
     9714+  echo "$as_me:12097: \$? = $ac_status" >&5
    94329715   (exit $ac_status); } &&
    94339716          { ac_try='test -s conftest$ac_exeext'
    94349717-  { (eval echo "$as_me:11693: \"$ac_try\"") >&5
    9435 +  { (eval echo "$as_me:12071: \"$ac_try\"") >&5
     9718+  { (eval echo "$as_me:12100: \"$ac_try\"") >&5
    94369719   (eval $ac_try) 2>&5
    94379720   ac_status=$?
    94389721-  echo "$as_me:11696: \$? = $ac_status" >&5
    9439 +  echo "$as_me:12074: \$? = $ac_status" >&5
     9722+  echo "$as_me:12103: \$? = $ac_status" >&5
    94409723   (exit $ac_status); }; }; then
    94419724   cf_cv_regex="regexpr.h"
    94429725 else
    9443 @@ -11709,7 +12087,7 @@
     9726@@ -11709,7 +12116,7 @@
    94449727 
    94459728 fi
    94469729 
    94479730-echo "$as_me:11712: result: $cf_cv_regex" >&5
    9448 +echo "$as_me:12090: result: $cf_cv_regex" >&5
     9731+echo "$as_me:12119: result: $cf_cv_regex" >&5
    94499732 echo "${ECHO_T}$cf_cv_regex" >&6
    94509733 case $cf_cv_regex in
    94519734        regex.h)   cat >>confdefs.h <<\EOF
    9452 @@ -11745,23 +12123,23 @@
     9735@@ -11745,23 +12152,23 @@
    94539736 
    94549737 do
    94559738 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
    94569739-echo "$as_me:11748: checking for $ac_header" >&5
    9457 +echo "$as_me:12126: checking for $ac_header" >&5
     9740+echo "$as_me:12155: checking for $ac_header" >&5
    94589741 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
    94599742 if eval "test \"\${$as_ac_Header+set}\" = set"; then
     
    94629745   cat >conftest.$ac_ext <<_ACEOF
    94639746-#line 11754 "configure"
    9464 +#line 12132 "configure"
     9747+#line 12161 "configure"
    94659748 #include "confdefs.h"
    94669749 #include <$ac_header>
    94679750 _ACEOF
    94689751-if { (eval echo "$as_me:11758: \"$ac_cpp conftest.$ac_ext\"") >&5
    9469 +if { (eval echo "$as_me:12136: \"$ac_cpp conftest.$ac_ext\"") >&5
     9752+if { (eval echo "$as_me:12165: \"$ac_cpp conftest.$ac_ext\"") >&5
    94709753   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    94719754   ac_status=$?
     
    94749757   cat conftest.err >&5
    94759758-  echo "$as_me:11764: \$? = $ac_status" >&5
    9476 +  echo "$as_me:12142: \$? = $ac_status" >&5
     9759+  echo "$as_me:12171: \$? = $ac_status" >&5
    94779760   (exit $ac_status); } >/dev/null; then
    94789761   if test -s conftest.err; then
    94799762     ac_cpp_err=$ac_c_preproc_warn_flag
    9480 @@ -11780,7 +12158,7 @@
     9763@@ -11780,7 +12187,7 @@
    94819764 fi
    94829765 rm -f conftest.err conftest.$ac_ext
    94839766 fi
    94849767-echo "$as_me:11783: result: `eval echo '${'$as_ac_Header'}'`" >&5
    9485 +echo "$as_me:12161: result: `eval echo '${'$as_ac_Header'}'`" >&5
     9768+echo "$as_me:12190: result: `eval echo '${'$as_ac_Header'}'`" >&5
    94869769 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
    94879770 if test `eval echo '${'$as_ac_Header'}'` = yes; then
    94889771   cat >>confdefs.h <<EOF
    9489 @@ -11794,7 +12172,7 @@
     9772@@ -11794,7 +12201,7 @@
    94909773 # Note: even non-Posix ISC needs <sys/bsdtypes.h> to declare fd_set
    94919774 if test "$ISC" = yes ; then
    94929775 
    94939776-echo "$as_me:11797: checking for main in -lcposix" >&5
    9494 +echo "$as_me:12175: checking for main in -lcposix" >&5
     9777+echo "$as_me:12204: checking for main in -lcposix" >&5
    94959778 echo $ECHO_N "checking for main in -lcposix... $ECHO_C" >&6
    94969779 if test "${ac_cv_lib_cposix_main+set}" = set; then
    94979780   echo $ECHO_N "(cached) $ECHO_C" >&6
    9498 @@ -11802,7 +12180,7 @@
     9781@@ -11802,7 +12209,7 @@
    94999782   ac_check_lib_save_LIBS=$LIBS
    95009783 LIBS="-lcposix  $LIBS"
    95019784 cat >conftest.$ac_ext <<_ACEOF
    95029785-#line 11805 "configure"
    9503 +#line 12183 "configure"
     9786+#line 12212 "configure"
    95049787 #include "confdefs.h"
    95059788 
    95069789 int
    9507 @@ -11814,16 +12192,16 @@
     9790@@ -11814,16 +12221,16 @@
    95089791 }
    95099792 _ACEOF
    95109793 rm -f conftest.$ac_objext conftest$ac_exeext
    95119794-if { (eval echo "$as_me:11817: \"$ac_link\"") >&5
    9512 +if { (eval echo "$as_me:12195: \"$ac_link\"") >&5
     9795+if { (eval echo "$as_me:12224: \"$ac_link\"") >&5
    95139796   (eval $ac_link) 2>&5
    95149797   ac_status=$?
    95159798-  echo "$as_me:11820: \$? = $ac_status" >&5
    9516 +  echo "$as_me:12198: \$? = $ac_status" >&5
     9799+  echo "$as_me:12227: \$? = $ac_status" >&5
    95179800   (exit $ac_status); } &&
    95189801          { ac_try='test -s conftest$ac_exeext'
    95199802-  { (eval echo "$as_me:11823: \"$ac_try\"") >&5
    9520 +  { (eval echo "$as_me:12201: \"$ac_try\"") >&5
     9803+  { (eval echo "$as_me:12230: \"$ac_try\"") >&5
    95219804   (eval $ac_try) 2>&5
    95229805   ac_status=$?
    95239806-  echo "$as_me:11826: \$? = $ac_status" >&5
    9524 +  echo "$as_me:12204: \$? = $ac_status" >&5
     9807+  echo "$as_me:12233: \$? = $ac_status" >&5
    95259808   (exit $ac_status); }; }; then
    95269809   ac_cv_lib_cposix_main=yes
    95279810 else
    9528 @@ -11834,7 +12212,7 @@
     9811@@ -11834,7 +12241,7 @@
    95299812 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    95309813 LIBS=$ac_check_lib_save_LIBS
    95319814 fi
    95329815-echo "$as_me:11837: result: $ac_cv_lib_cposix_main" >&5
    9533 +echo "$as_me:12215: result: $ac_cv_lib_cposix_main" >&5
     9816+echo "$as_me:12244: result: $ac_cv_lib_cposix_main" >&5
    95349817 echo "${ECHO_T}$ac_cv_lib_cposix_main" >&6
    95359818 if test $ac_cv_lib_cposix_main = yes; then
    95369819   cat >>confdefs.h <<EOF
    9537 @@ -11845,7 +12223,7 @@
     9820@@ -11845,7 +12252,7 @@
    95389821 
    95399822 fi
    95409823 
    95419824-       echo "$as_me:11848: checking for bzero in -linet" >&5
    9542 +       echo "$as_me:12226: checking for bzero in -linet" >&5
     9825+       echo "$as_me:12255: checking for bzero in -linet" >&5
    95439826 echo $ECHO_N "checking for bzero in -linet... $ECHO_C" >&6
    95449827 if test "${ac_cv_lib_inet_bzero+set}" = set; then
    95459828   echo $ECHO_N "(cached) $ECHO_C" >&6
    9546 @@ -11853,7 +12231,7 @@
     9829@@ -11853,7 +12260,7 @@
    95479830   ac_check_lib_save_LIBS=$LIBS
    95489831 LIBS="-linet  $LIBS"
    95499832 cat >conftest.$ac_ext <<_ACEOF
    95509833-#line 11856 "configure"
    9551 +#line 12234 "configure"
     9834+#line 12263 "configure"
    95529835 #include "confdefs.h"
    95539836 
    95549837 /* Override any gcc2 internal prototype to avoid an error.  */
    9555 @@ -11872,16 +12250,16 @@
     9838@@ -11872,16 +12279,16 @@
    95569839 }
    95579840 _ACEOF
    95589841 rm -f conftest.$ac_objext conftest$ac_exeext
    95599842-if { (eval echo "$as_me:11875: \"$ac_link\"") >&5
    9560 +if { (eval echo "$as_me:12253: \"$ac_link\"") >&5
     9843+if { (eval echo "$as_me:12282: \"$ac_link\"") >&5
    95619844   (eval $ac_link) 2>&5
    95629845   ac_status=$?
    95639846-  echo "$as_me:11878: \$? = $ac_status" >&5
    9564 +  echo "$as_me:12256: \$? = $ac_status" >&5
     9847+  echo "$as_me:12285: \$? = $ac_status" >&5
    95659848   (exit $ac_status); } &&
    95669849          { ac_try='test -s conftest$ac_exeext'
    95679850-  { (eval echo "$as_me:11881: \"$ac_try\"") >&5
    9568 +  { (eval echo "$as_me:12259: \"$ac_try\"") >&5
     9851+  { (eval echo "$as_me:12288: \"$ac_try\"") >&5
    95699852   (eval $ac_try) 2>&5
    95709853   ac_status=$?
    95719854-  echo "$as_me:11884: \$? = $ac_status" >&5
    9572 +  echo "$as_me:12262: \$? = $ac_status" >&5
     9855+  echo "$as_me:12291: \$? = $ac_status" >&5
    95739856   (exit $ac_status); }; }; then
    95749857   ac_cv_lib_inet_bzero=yes
    95759858 else
    9576 @@ -11892,21 +12270,21 @@
     9859@@ -11892,21 +12299,21 @@
    95779860 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    95789861 LIBS=$ac_check_lib_save_LIBS
    95799862 fi
    95809863-echo "$as_me:11895: result: $ac_cv_lib_inet_bzero" >&5
    9581 +echo "$as_me:12273: result: $ac_cv_lib_inet_bzero" >&5
     9864+echo "$as_me:12302: result: $ac_cv_lib_inet_bzero" >&5
    95829865 echo "${ECHO_T}$ac_cv_lib_inet_bzero" >&6
    95839866 if test $ac_cv_lib_inet_bzero = yes; then
     
    95879870 
    95889871-echo "$as_me:11902: checking if sys/time.h works with sys/select.h" >&5
    9589 +echo "$as_me:12280: checking if sys/time.h works with sys/select.h" >&5
     9872+echo "$as_me:12309: checking if sys/time.h works with sys/select.h" >&5
    95909873 echo $ECHO_N "checking if sys/time.h works with sys/select.h... $ECHO_C" >&6
    95919874 if test "${cf_cv_sys_time_select+set}" = set; then
     
    95959878 cat >conftest.$ac_ext <<_ACEOF
    95969879-#line 11909 "configure"
    9597 +#line 12287 "configure"
     9880+#line 12316 "configure"
    95989881 #include "confdefs.h"
    95999882 
    96009883 #include <sys/types.h>
    9601 @@ -11926,16 +12304,16 @@
     9884@@ -11926,16 +12333,16 @@
    96029885 }
    96039886 _ACEOF
    96049887 rm -f conftest.$ac_objext
    96059888-if { (eval echo "$as_me:11929: \"$ac_compile\"") >&5
    9606 +if { (eval echo "$as_me:12307: \"$ac_compile\"") >&5
     9889+if { (eval echo "$as_me:12336: \"$ac_compile\"") >&5
    96079890   (eval $ac_compile) 2>&5
    96089891   ac_status=$?
    96099892-  echo "$as_me:11932: \$? = $ac_status" >&5
    9610 +  echo "$as_me:12310: \$? = $ac_status" >&5
     9893+  echo "$as_me:12339: \$? = $ac_status" >&5
    96119894   (exit $ac_status); } &&
    96129895          { ac_try='test -s conftest.$ac_objext'
    96139896-  { (eval echo "$as_me:11935: \"$ac_try\"") >&5
    9614 +  { (eval echo "$as_me:12313: \"$ac_try\"") >&5
     9897+  { (eval echo "$as_me:12342: \"$ac_try\"") >&5
    96159898   (eval $ac_try) 2>&5
    96169899   ac_status=$?
    96179900-  echo "$as_me:11938: \$? = $ac_status" >&5
    9618 +  echo "$as_me:12316: \$? = $ac_status" >&5
     9901+  echo "$as_me:12345: \$? = $ac_status" >&5
    96199902   (exit $ac_status); }; }; then
    96209903   cf_cv_sys_time_select=yes
    96219904 else
    9622 @@ -11947,7 +12325,7 @@
     9905@@ -11947,7 +12354,7 @@
    96239906 
    96249907 fi
    96259908 
    96269909-echo "$as_me:11950: result: $cf_cv_sys_time_select" >&5
    9627 +echo "$as_me:12328: result: $cf_cv_sys_time_select" >&5
     9910+echo "$as_me:12357: result: $cf_cv_sys_time_select" >&5
    96289911 echo "${ECHO_T}$cf_cv_sys_time_select" >&6
    96299912 test "$cf_cv_sys_time_select" = yes && cat >>confdefs.h <<\EOF
    96309913 #define HAVE_SYS_TIME_SELECT 1
    9631 @@ -11961,7 +12339,7 @@
     9914@@ -11961,7 +12368,7 @@
    96329915 ac_compiler_gnu=$ac_cv_c_compiler_gnu
    96339916 ac_main_return=return
    96349917 
    96359918-echo "$as_me:11964: checking for $CC option to accept ANSI C" >&5
    9636 +echo "$as_me:12342: checking for $CC option to accept ANSI C" >&5
     9919+echo "$as_me:12371: checking for $CC option to accept ANSI C" >&5
    96379920 echo $ECHO_N "checking for $CC option to accept ANSI C... $ECHO_C" >&6
    96389921 if test "${ac_cv_prog_cc_stdc+set}" = set; then
    96399922   echo $ECHO_N "(cached) $ECHO_C" >&6
    9640 @@ -11969,7 +12347,7 @@
     9923@@ -11969,7 +12376,7 @@
    96419924   ac_cv_prog_cc_stdc=no
    96429925 ac_save_CC=$CC
    96439926 cat >conftest.$ac_ext <<_ACEOF
    96449927-#line 11972 "configure"
    9645 +#line 12350 "configure"
     9928+#line 12379 "configure"
    96469929 #include "confdefs.h"
    96479930 #include <stdarg.h>
    96489931 #include <stdio.h>
    9649 @@ -12018,16 +12396,16 @@
     9932@@ -12018,16 +12425,16 @@
    96509933 do
    96519934   CC="$ac_save_CC $ac_arg"
    96529935   rm -f conftest.$ac_objext
    96539936-if { (eval echo "$as_me:12021: \"$ac_compile\"") >&5
    9654 +if { (eval echo "$as_me:12399: \"$ac_compile\"") >&5
     9937+if { (eval echo "$as_me:12428: \"$ac_compile\"") >&5
    96559938   (eval $ac_compile) 2>&5
    96569939   ac_status=$?
    96579940-  echo "$as_me:12024: \$? = $ac_status" >&5
    9658 +  echo "$as_me:12402: \$? = $ac_status" >&5
     9941+  echo "$as_me:12431: \$? = $ac_status" >&5
    96599942   (exit $ac_status); } &&
    96609943          { ac_try='test -s conftest.$ac_objext'
    96619944-  { (eval echo "$as_me:12027: \"$ac_try\"") >&5
    9662 +  { (eval echo "$as_me:12405: \"$ac_try\"") >&5
     9945+  { (eval echo "$as_me:12434: \"$ac_try\"") >&5
    96639946   (eval $ac_try) 2>&5
    96649947   ac_status=$?
    96659948-  echo "$as_me:12030: \$? = $ac_status" >&5
    9666 +  echo "$as_me:12408: \$? = $ac_status" >&5
     9949+  echo "$as_me:12437: \$? = $ac_status" >&5
    96679950   (exit $ac_status); }; }; then
    96689951   ac_cv_prog_cc_stdc=$ac_arg
    96699952 break
    9670 @@ -12044,21 +12422,21 @@
     9953@@ -12044,21 +12451,21 @@
    96719954 
    96729955 case "x$ac_cv_prog_cc_stdc" in
    96739956   x|xno)
    96749957-    echo "$as_me:12047: result: none needed" >&5
    9675 +    echo "$as_me:12425: result: none needed" >&5
     9958+    echo "$as_me:12454: result: none needed" >&5
    96769959 echo "${ECHO_T}none needed" >&6 ;;
    96779960   *)
    96789961-    echo "$as_me:12050: result: $ac_cv_prog_cc_stdc" >&5
    9679 +    echo "$as_me:12428: result: $ac_cv_prog_cc_stdc" >&5
     9962+    echo "$as_me:12457: result: $ac_cv_prog_cc_stdc" >&5
    96809963 echo "${ECHO_T}$ac_cv_prog_cc_stdc" >&6
    96819964     CC="$CC $ac_cv_prog_cc_stdc" ;;
     
    96839966 
    96849967-echo "$as_me:12055: checking for an ANSI C-conforming const" >&5
    9685 +echo "$as_me:12433: checking for an ANSI C-conforming const" >&5
     9968+echo "$as_me:12462: checking for an ANSI C-conforming const" >&5
    96869969 echo $ECHO_N "checking for an ANSI C-conforming const... $ECHO_C" >&6
    96879970 if test "${ac_cv_c_const+set}" = set; then
     
    96909973   cat >conftest.$ac_ext <<_ACEOF
    96919974-#line 12061 "configure"
    9692 +#line 12439 "configure"
     9975+#line 12468 "configure"
    96939976 #include "confdefs.h"
    96949977 
    96959978 int
    9696 @@ -12116,16 +12494,16 @@
     9979@@ -12116,16 +12523,16 @@
    96979980 }
    96989981 _ACEOF
    96999982 rm -f conftest.$ac_objext
    97009983-if { (eval echo "$as_me:12119: \"$ac_compile\"") >&5
    9701 +if { (eval echo "$as_me:12497: \"$ac_compile\"") >&5
     9984+if { (eval echo "$as_me:12526: \"$ac_compile\"") >&5
    97029985   (eval $ac_compile) 2>&5
    97039986   ac_status=$?
    97049987-  echo "$as_me:12122: \$? = $ac_status" >&5
    9705 +  echo "$as_me:12500: \$? = $ac_status" >&5
     9988+  echo "$as_me:12529: \$? = $ac_status" >&5
    97069989   (exit $ac_status); } &&
    97079990          { ac_try='test -s conftest.$ac_objext'
    97089991-  { (eval echo "$as_me:12125: \"$ac_try\"") >&5
    9709 +  { (eval echo "$as_me:12503: \"$ac_try\"") >&5
     9992+  { (eval echo "$as_me:12532: \"$ac_try\"") >&5
    97109993   (eval $ac_try) 2>&5
    97119994   ac_status=$?
    97129995-  echo "$as_me:12128: \$? = $ac_status" >&5
    9713 +  echo "$as_me:12506: \$? = $ac_status" >&5
     9996+  echo "$as_me:12535: \$? = $ac_status" >&5
    97149997   (exit $ac_status); }; }; then
    97159998   ac_cv_c_const=yes
    97169999 else
    9717 @@ -12135,7 +12513,7 @@
     10000@@ -12135,7 +12542,7 @@
    971810001 fi
    971910002 rm -f conftest.$ac_objext conftest.$ac_ext
    972010003 fi
    972110004-echo "$as_me:12138: result: $ac_cv_c_const" >&5
    9722 +echo "$as_me:12516: result: $ac_cv_c_const" >&5
     10005+echo "$as_me:12545: result: $ac_cv_c_const" >&5
    972310006 echo "${ECHO_T}$ac_cv_c_const" >&6
    972410007 if test $ac_cv_c_const = no; then
    972510008 
    9726 @@ -12145,7 +12523,7 @@
     10009@@ -12145,7 +12552,7 @@
    972710010 
    972810011 fi
    972910012 
    973010013-echo "$as_me:12148: checking for inline" >&5
    9731 +echo "$as_me:12526: checking for inline" >&5
     10014+echo "$as_me:12555: checking for inline" >&5
    973210015 echo $ECHO_N "checking for inline... $ECHO_C" >&6
    973310016 if test "${ac_cv_c_inline+set}" = set; then
    973410017   echo $ECHO_N "(cached) $ECHO_C" >&6
    9735 @@ -12153,7 +12531,7 @@
     10018@@ -12153,7 +12560,7 @@
    973610019   ac_cv_c_inline=no
    973710020 for ac_kw in inline __inline__ __inline; do
    973810021   cat >conftest.$ac_ext <<_ACEOF
    973910022-#line 12156 "configure"
    9740 +#line 12534 "configure"
     10023+#line 12563 "configure"
    974110024 #include "confdefs.h"
    974210025 #ifndef __cplusplus
    974310026 static $ac_kw int static_foo () {return 0; }
    9744 @@ -12162,16 +12540,16 @@
     10027@@ -12162,16 +12569,16 @@
    974510028 
    974610029 _ACEOF
    974710030 rm -f conftest.$ac_objext
    974810031-if { (eval echo "$as_me:12165: \"$ac_compile\"") >&5
    9749 +if { (eval echo "$as_me:12543: \"$ac_compile\"") >&5
     10032+if { (eval echo "$as_me:12572: \"$ac_compile\"") >&5
    975010033   (eval $ac_compile) 2>&5
    975110034   ac_status=$?
    975210035-  echo "$as_me:12168: \$? = $ac_status" >&5
    9753 +  echo "$as_me:12546: \$? = $ac_status" >&5
     10036+  echo "$as_me:12575: \$? = $ac_status" >&5
    975410037   (exit $ac_status); } &&
    975510038          { ac_try='test -s conftest.$ac_objext'
    975610039-  { (eval echo "$as_me:12171: \"$ac_try\"") >&5
    9757 +  { (eval echo "$as_me:12549: \"$ac_try\"") >&5
     10040+  { (eval echo "$as_me:12578: \"$ac_try\"") >&5
    975810041   (eval $ac_try) 2>&5
    975910042   ac_status=$?
    976010043-  echo "$as_me:12174: \$? = $ac_status" >&5
    9761 +  echo "$as_me:12552: \$? = $ac_status" >&5
     10044+  echo "$as_me:12581: \$? = $ac_status" >&5
    976210045   (exit $ac_status); }; }; then
    976310046   ac_cv_c_inline=$ac_kw; break
    976410047 else
    9765 @@ -12182,7 +12560,7 @@
     10048@@ -12182,7 +12589,7 @@
    976610049 done
    976710050 
    976810051 fi
    976910052-echo "$as_me:12185: result: $ac_cv_c_inline" >&5
    9770 +echo "$as_me:12563: result: $ac_cv_c_inline" >&5
     10053+echo "$as_me:12592: result: $ac_cv_c_inline" >&5
    977110054 echo "${ECHO_T}$ac_cv_c_inline" >&6
    977210055 case $ac_cv_c_inline in
    977310056   inline | yes) ;;
    9774 @@ -12205,7 +12583,7 @@
     10057@@ -12205,7 +12612,7 @@
    977510058     :
    977610059   elif test "$GCC" = yes
    977710060   then
    977810061-    echo "$as_me:12208: checking if gcc supports options to tune inlining" >&5
    9779 +    echo "$as_me:12586: checking if gcc supports options to tune inlining" >&5
     10062+    echo "$as_me:12615: checking if gcc supports options to tune inlining" >&5
    978010063 echo $ECHO_N "checking if gcc supports options to tune inlining... $ECHO_C" >&6
    978110064 if test "${cf_cv_gcc_inline+set}" = set; then
    978210065   echo $ECHO_N "(cached) $ECHO_C" >&6
    9783 @@ -12214,7 +12592,7 @@
     10066@@ -12214,7 +12621,7 @@
    978410067       cf_save_CFLAGS=$CFLAGS
    978510068       CFLAGS="$CFLAGS --param max-inline-insns-single=1200"
    978610069       cat >conftest.$ac_ext <<_ACEOF
    978710070-#line 12217 "configure"
    9788 +#line 12595 "configure"
     10071+#line 12624 "configure"
    978910072 #include "confdefs.h"
    979010073 inline int foo(void) { return 1; }
    979110074 int
    9792 @@ -12226,16 +12604,16 @@
     10075@@ -12226,16 +12633,16 @@
    979310076 }
    979410077 _ACEOF
    979510078 rm -f conftest.$ac_objext
    979610079-if { (eval echo "$as_me:12229: \"$ac_compile\"") >&5
    9797 +if { (eval echo "$as_me:12607: \"$ac_compile\"") >&5
     10080+if { (eval echo "$as_me:12636: \"$ac_compile\"") >&5
    979810081   (eval $ac_compile) 2>&5
    979910082   ac_status=$?
    980010083-  echo "$as_me:12232: \$? = $ac_status" >&5
    9801 +  echo "$as_me:12610: \$? = $ac_status" >&5
     10084+  echo "$as_me:12639: \$? = $ac_status" >&5
    980210085   (exit $ac_status); } &&
    980310086          { ac_try='test -s conftest.$ac_objext'
    980410087-  { (eval echo "$as_me:12235: \"$ac_try\"") >&5
    9805 +  { (eval echo "$as_me:12613: \"$ac_try\"") >&5
     10088+  { (eval echo "$as_me:12642: \"$ac_try\"") >&5
    980610089   (eval $ac_try) 2>&5
    980710090   ac_status=$?
    980810091-  echo "$as_me:12238: \$? = $ac_status" >&5
    9809 +  echo "$as_me:12616: \$? = $ac_status" >&5
     10092+  echo "$as_me:12645: \$? = $ac_status" >&5
    981010093   (exit $ac_status); }; }; then
    981110094   cf_cv_gcc_inline=yes
    981210095 else
    9813 @@ -12247,7 +12625,7 @@
     10096@@ -12247,7 +12654,7 @@
    981410097       CFLAGS=$cf_save_CFLAGS
    981510098 
    981610099 fi
    981710100-echo "$as_me:12250: result: $cf_cv_gcc_inline" >&5
    9818 +echo "$as_me:12628: result: $cf_cv_gcc_inline" >&5
     10101+echo "$as_me:12657: result: $cf_cv_gcc_inline" >&5
    981910102 echo "${ECHO_T}$cf_cv_gcc_inline" >&6
    982010103     if test "$cf_cv_gcc_inline" = yes ; then
    982110104 
    9822 @@ -12311,7 +12689,7 @@
     10105@@ -12311,7 +12718,7 @@
    982310106 
    982410107 if test -n "$cf_new_cppflags" ; then
     
    982910112 
    983010113 if test -n "$cf_new_extra_cppflags" ; then
    9831 @@ -12323,7 +12701,7 @@
     10114@@ -12323,7 +12730,7 @@
    983210115   fi
    983310116 fi
    983410117 
    983510118-echo "$as_me:12326: checking for signal global datatype" >&5
    9836 +echo "$as_me:12704: checking for signal global datatype" >&5
     10119+echo "$as_me:12733: checking for signal global datatype" >&5
    983710120 echo $ECHO_N "checking for signal global datatype... $ECHO_C" >&6
    983810121 if test "${cf_cv_sig_atomic_t+set}" = set; then
    983910122   echo $ECHO_N "(cached) $ECHO_C" >&6
    9840 @@ -12335,7 +12713,7 @@
     10123@@ -12335,7 +12742,7 @@
    984110124                "int"
    984210125        do
    984310126        cat >conftest.$ac_ext <<_ACEOF
    984410127-#line 12338 "configure"
    9845 +#line 12716 "configure"
     10128+#line 12745 "configure"
    984610129 #include "confdefs.h"
    984710130 
    984810131 #include <sys/types.h>
    9849 @@ -12358,16 +12736,16 @@
     10132@@ -12358,16 +12765,16 @@
    985010133 }
    985110134 _ACEOF
    985210135 rm -f conftest.$ac_objext
    985310136-if { (eval echo "$as_me:12361: \"$ac_compile\"") >&5
    9854 +if { (eval echo "$as_me:12739: \"$ac_compile\"") >&5
     10137+if { (eval echo "$as_me:12768: \"$ac_compile\"") >&5
    985510138   (eval $ac_compile) 2>&5
    985610139   ac_status=$?
    985710140-  echo "$as_me:12364: \$? = $ac_status" >&5
    9858 +  echo "$as_me:12742: \$? = $ac_status" >&5
     10141+  echo "$as_me:12771: \$? = $ac_status" >&5
    985910142   (exit $ac_status); } &&
    986010143          { ac_try='test -s conftest.$ac_objext'
    986110144-  { (eval echo "$as_me:12367: \"$ac_try\"") >&5
    9862 +  { (eval echo "$as_me:12745: \"$ac_try\"") >&5
     10145+  { (eval echo "$as_me:12774: \"$ac_try\"") >&5
    986310146   (eval $ac_try) 2>&5
    986410147   ac_status=$?
    986510148-  echo "$as_me:12370: \$? = $ac_status" >&5
    9866 +  echo "$as_me:12748: \$? = $ac_status" >&5
     10149+  echo "$as_me:12777: \$? = $ac_status" >&5
    986710150   (exit $ac_status); }; }; then
    986810151   cf_cv_sig_atomic_t=$cf_type
    986910152 else
    9870 @@ -12381,7 +12759,7 @@
     10153@@ -12381,7 +12788,7 @@
    987110154 
    987210155 fi
    987310156 
    987410157-echo "$as_me:12384: result: $cf_cv_sig_atomic_t" >&5
    9875 +echo "$as_me:12762: result: $cf_cv_sig_atomic_t" >&5
     10158+echo "$as_me:12791: result: $cf_cv_sig_atomic_t" >&5
    987610159 echo "${ECHO_T}$cf_cv_sig_atomic_t" >&6
    987710160 test "$cf_cv_sig_atomic_t" != no && cat >>confdefs.h <<EOF
    987810161 #define SIG_ATOMIC_T $cf_cv_sig_atomic_t
    9879 @@ -12389,7 +12767,7 @@
     10162@@ -12389,7 +12796,7 @@
    988010163 
    988110164 if test $NCURSES_CHTYPE = auto ; then
    988210165 
    988310166-echo "$as_me:12392: checking for type of chtype" >&5
    9884 +echo "$as_me:12770: checking for type of chtype" >&5
     10167+echo "$as_me:12799: checking for type of chtype" >&5
    988510168 echo $ECHO_N "checking for type of chtype... $ECHO_C" >&6
    988610169 if test "${cf_cv_typeof_chtype+set}" = set; then
    988710170   echo $ECHO_N "(cached) $ECHO_C" >&6
    9888 @@ -12399,7 +12777,7 @@
     10171@@ -12399,7 +12806,7 @@
    988910172   cf_cv_typeof_chtype=long
    989010173 else
    989110174   cat >conftest.$ac_ext <<_ACEOF
    989210175-#line 12402 "configure"
    9893 +#line 12780 "configure"
     10176+#line 12809 "configure"
    989410177 #include "confdefs.h"
    989510178 
    989610179 #define WANT_BITS 31
    9897 @@ -12434,15 +12812,15 @@
     10180@@ -12434,15 +12841,15 @@
    989810181 
    989910182 _ACEOF
    990010183 rm -f conftest$ac_exeext
    990110184-if { (eval echo "$as_me:12437: \"$ac_link\"") >&5
    9902 +if { (eval echo "$as_me:12815: \"$ac_link\"") >&5
     10185+if { (eval echo "$as_me:12844: \"$ac_link\"") >&5
    990310186   (eval $ac_link) 2>&5
    990410187   ac_status=$?
    990510188-  echo "$as_me:12440: \$? = $ac_status" >&5
    9906 +  echo "$as_me:12818: \$? = $ac_status" >&5
     10189+  echo "$as_me:12847: \$? = $ac_status" >&5
    990710190   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    990810191-  { (eval echo "$as_me:12442: \"$ac_try\"") >&5
    9909 +  { (eval echo "$as_me:12820: \"$ac_try\"") >&5
     10192+  { (eval echo "$as_me:12849: \"$ac_try\"") >&5
    991010193   (eval $ac_try) 2>&5
    991110194   ac_status=$?
    991210195-  echo "$as_me:12445: \$? = $ac_status" >&5
    9913 +  echo "$as_me:12823: \$? = $ac_status" >&5
     10196+  echo "$as_me:12852: \$? = $ac_status" >&5
    991410197   (exit $ac_status); }; }; then
    991510198   cf_cv_typeof_chtype=`cat cf_test.out`
    991610199 else
    9917 @@ -12457,7 +12835,7 @@
     10200@@ -12457,7 +12864,7 @@
    991810201 
    991910202 fi
    992010203 
    992110204-echo "$as_me:12460: result: $cf_cv_typeof_chtype" >&5
    9922 +echo "$as_me:12838: result: $cf_cv_typeof_chtype" >&5
     10205+echo "$as_me:12867: result: $cf_cv_typeof_chtype" >&5
    992310206 echo "${ECHO_T}$cf_cv_typeof_chtype" >&6
    992410207 
    992510208 cat >>confdefs.h <<EOF
    9926 @@ -12469,14 +12847,14 @@
     10209@@ -12469,14 +12876,14 @@
    992710210 fi
    992810211 test "$cf_cv_typeof_chtype" = unsigned && cf_cv_typeof_chtype=""
    992910212 
    993010213-echo "$as_me:12472: checking if unsigned literals are legal" >&5
    9931 +echo "$as_me:12850: checking if unsigned literals are legal" >&5
     10214+echo "$as_me:12879: checking if unsigned literals are legal" >&5
    993210215 echo $ECHO_N "checking if unsigned literals are legal... $ECHO_C" >&6
    993310216 if test "${cf_cv_unsigned_literals+set}" = set; then
     
    993710220        cat >conftest.$ac_ext <<_ACEOF
    993810221-#line 12479 "configure"
    9939 +#line 12857 "configure"
     10222+#line 12886 "configure"
    994010223 #include "confdefs.h"
    994110224 
    994210225 int
    9943 @@ -12488,16 +12866,16 @@
     10226@@ -12488,16 +12895,16 @@
    994410227 }
    994510228 _ACEOF
    994610229 rm -f conftest.$ac_objext
    994710230-if { (eval echo "$as_me:12491: \"$ac_compile\"") >&5
    9948 +if { (eval echo "$as_me:12869: \"$ac_compile\"") >&5
     10231+if { (eval echo "$as_me:12898: \"$ac_compile\"") >&5
    994910232   (eval $ac_compile) 2>&5
    995010233   ac_status=$?
    995110234-  echo "$as_me:12494: \$? = $ac_status" >&5
    9952 +  echo "$as_me:12872: \$? = $ac_status" >&5
     10235+  echo "$as_me:12901: \$? = $ac_status" >&5
    995310236   (exit $ac_status); } &&
    995410237          { ac_try='test -s conftest.$ac_objext'
    995510238-  { (eval echo "$as_me:12497: \"$ac_try\"") >&5
    9956 +  { (eval echo "$as_me:12875: \"$ac_try\"") >&5
     10239+  { (eval echo "$as_me:12904: \"$ac_try\"") >&5
    995710240   (eval $ac_try) 2>&5
    995810241   ac_status=$?
    995910242-  echo "$as_me:12500: \$? = $ac_status" >&5
    9960 +  echo "$as_me:12878: \$? = $ac_status" >&5
     10243+  echo "$as_me:12907: \$? = $ac_status" >&5
    996110244   (exit $ac_status); }; }; then
    996210245   cf_cv_unsigned_literals=yes
    996310246 else
    9964 @@ -12509,7 +12887,7 @@
     10247@@ -12509,7 +12916,7 @@
    996510248 
    996610249 fi
    996710250 
    996810251-echo "$as_me:12512: result: $cf_cv_unsigned_literals" >&5
    9969 +echo "$as_me:12890: result: $cf_cv_unsigned_literals" >&5
     10252+echo "$as_me:12919: result: $cf_cv_unsigned_literals" >&5
    997010253 echo "${ECHO_T}$cf_cv_unsigned_literals" >&6
    997110254 
    997210255 cf_cv_1UL="1"
    9973 @@ -12525,14 +12903,14 @@
     10256@@ -12525,14 +12932,14 @@
    997410257 
    997510258 ###    Checks for external-data
    997610259 
    997710260-echo "$as_me:12528: checking if external errno is declared" >&5
    9978 +echo "$as_me:12906: checking if external errno is declared" >&5
     10261+echo "$as_me:12935: checking if external errno is declared" >&5
    997910262 echo $ECHO_N "checking if external errno is declared... $ECHO_C" >&6
    998010263 if test "${cf_cv_dcl_errno+set}" = set; then
     
    998410267     cat >conftest.$ac_ext <<_ACEOF
    998510268-#line 12535 "configure"
    9986 +#line 12913 "configure"
     10269+#line 12942 "configure"
    998710270 #include "confdefs.h"
    998810271 
    998910272 #ifdef HAVE_STDLIB_H
    9990 @@ -12550,16 +12928,16 @@
     10273@@ -12550,16 +12957,16 @@
    999110274 }
    999210275 _ACEOF
    999310276 rm -f conftest.$ac_objext
    999410277-if { (eval echo "$as_me:12553: \"$ac_compile\"") >&5
    9995 +if { (eval echo "$as_me:12931: \"$ac_compile\"") >&5
     10278+if { (eval echo "$as_me:12960: \"$ac_compile\"") >&5
    999610279   (eval $ac_compile) 2>&5
    999710280   ac_status=$?
    999810281-  echo "$as_me:12556: \$? = $ac_status" >&5
    9999 +  echo "$as_me:12934: \$? = $ac_status" >&5
     10282+  echo "$as_me:12963: \$? = $ac_status" >&5
    1000010283   (exit $ac_status); } &&
    1000110284          { ac_try='test -s conftest.$ac_objext'
    1000210285-  { (eval echo "$as_me:12559: \"$ac_try\"") >&5
    10003 +  { (eval echo "$as_me:12937: \"$ac_try\"") >&5
     10286+  { (eval echo "$as_me:12966: \"$ac_try\"") >&5
    1000410287   (eval $ac_try) 2>&5
    1000510288   ac_status=$?
    1000610289-  echo "$as_me:12562: \$? = $ac_status" >&5
    10007 +  echo "$as_me:12940: \$? = $ac_status" >&5
     10290+  echo "$as_me:12969: \$? = $ac_status" >&5
    1000810291   (exit $ac_status); }; }; then
    1000910292   cf_cv_dcl_errno=yes
    1001010293 else
    10011 @@ -12570,7 +12948,7 @@
     10294@@ -12570,7 +12977,7 @@
    1001210295 rm -f conftest.$ac_objext conftest.$ac_ext
    1001310296 
    1001410297 fi
    1001510298-echo "$as_me:12573: result: $cf_cv_dcl_errno" >&5
    10016 +echo "$as_me:12951: result: $cf_cv_dcl_errno" >&5
     10299+echo "$as_me:12980: result: $cf_cv_dcl_errno" >&5
    1001710300 echo "${ECHO_T}$cf_cv_dcl_errno" >&6
    1001810301 
    1001910302 if test "$cf_cv_dcl_errno" = no ; then
    10020 @@ -12585,14 +12963,14 @@
     10303@@ -12585,14 +12992,14 @@
    1002110304 
    1002210305 # It's possible (for near-UNIX clones) that the data doesn't exist
    1002310306 
    1002410307-echo "$as_me:12588: checking if external errno exists" >&5
    10025 +echo "$as_me:12966: checking if external errno exists" >&5
     10308+echo "$as_me:12995: checking if external errno exists" >&5
    1002610309 echo $ECHO_N "checking if external errno exists... $ECHO_C" >&6
    1002710310 if test "${cf_cv_have_errno+set}" = set; then
     
    1003110314     cat >conftest.$ac_ext <<_ACEOF
    1003210315-#line 12595 "configure"
    10033 +#line 12973 "configure"
     10316+#line 13002 "configure"
    1003410317 #include "confdefs.h"
    1003510318 
    1003610319 #undef errno
    10037 @@ -12607,16 +12985,16 @@
     10320@@ -12607,16 +13014,16 @@
    1003810321 }
    1003910322 _ACEOF
    1004010323 rm -f conftest.$ac_objext conftest$ac_exeext
    1004110324-if { (eval echo "$as_me:12610: \"$ac_link\"") >&5
    10042 +if { (eval echo "$as_me:12988: \"$ac_link\"") >&5
     10325+if { (eval echo "$as_me:13017: \"$ac_link\"") >&5
    1004310326   (eval $ac_link) 2>&5
    1004410327   ac_status=$?
    1004510328-  echo "$as_me:12613: \$? = $ac_status" >&5
    10046 +  echo "$as_me:12991: \$? = $ac_status" >&5
     10329+  echo "$as_me:13020: \$? = $ac_status" >&5
    1004710330   (exit $ac_status); } &&
    1004810331          { ac_try='test -s conftest$ac_exeext'
    1004910332-  { (eval echo "$as_me:12616: \"$ac_try\"") >&5
    10050 +  { (eval echo "$as_me:12994: \"$ac_try\"") >&5
     10333+  { (eval echo "$as_me:13023: \"$ac_try\"") >&5
    1005110334   (eval $ac_try) 2>&5
    1005210335   ac_status=$?
    1005310336-  echo "$as_me:12619: \$? = $ac_status" >&5
    10054 +  echo "$as_me:12997: \$? = $ac_status" >&5
     10337+  echo "$as_me:13026: \$? = $ac_status" >&5
    1005510338   (exit $ac_status); }; }; then
    1005610339   cf_cv_have_errno=yes
    1005710340 else
    10058 @@ -12627,7 +13005,7 @@
     10341@@ -12627,7 +13034,7 @@
    1005910342 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    1006010343 
    1006110344 fi
    1006210345-echo "$as_me:12630: result: $cf_cv_have_errno" >&5
    10063 +echo "$as_me:13008: result: $cf_cv_have_errno" >&5
     10346+echo "$as_me:13037: result: $cf_cv_have_errno" >&5
    1006410347 echo "${ECHO_T}$cf_cv_have_errno" >&6
    1006510348 
    1006610349 if test "$cf_cv_have_errno" = yes ; then
    10067 @@ -12640,7 +13018,7 @@
     10350@@ -12640,7 +13047,7 @@
    1006810351 
    1006910352 fi
    1007010353 
    1007110354-echo "$as_me:12643: checking if data-only library module links" >&5
    10072 +echo "$as_me:13021: checking if data-only library module links" >&5
     10355+echo "$as_me:13050: checking if data-only library module links" >&5
    1007310356 echo $ECHO_N "checking if data-only library module links... $ECHO_C" >&6
    1007410357 if test "${cf_cv_link_dataonly+set}" = set; then
    1007510358   echo $ECHO_N "(cached) $ECHO_C" >&6
    10076 @@ -12648,20 +13026,20 @@
     10359@@ -12648,20 +13055,20 @@
    1007710360 
    1007810361        rm -f conftest.a
    1007910362        cat >conftest.$ac_ext <<EOF
    1008010363-#line 12651 "configure"
    10081 +#line 13029 "configure"
     10364+#line 13058 "configure"
    1008210365 int    testdata[3] = { 123, 456, 789 };
    1008310366 EOF
    1008410367-       if { (eval echo "$as_me:12654: \"$ac_compile\"") >&5
    10085 +       if { (eval echo "$as_me:13032: \"$ac_compile\"") >&5
     10368+       if { (eval echo "$as_me:13061: \"$ac_compile\"") >&5
    1008610369   (eval $ac_compile) 2>&5
    1008710370   ac_status=$?
    1008810371-  echo "$as_me:12657: \$? = $ac_status" >&5
    10089 +  echo "$as_me:13035: \$? = $ac_status" >&5
     10372+  echo "$as_me:13064: \$? = $ac_status" >&5
    1009010373   (exit $ac_status); } ; then
    1009110374                mv conftest.o data.o && \
     
    1009610379        cat >conftest.$ac_ext <<EOF
    1009710380-#line 12664 "configure"
    10098 +#line 13042 "configure"
     10381+#line 13071 "configure"
    1009910382 int    testfunc()
    1010010383 {
    1010110384 #if defined(NeXT)
    10102 @@ -12674,13 +13052,13 @@
     10385@@ -12674,13 +13081,13 @@
    1010310386 #endif
    1010410387 }
    1010510388 EOF
    1010610389-       if { (eval echo "$as_me:12677: \"$ac_compile\"") >&5
    10107 +       if { (eval echo "$as_me:13055: \"$ac_compile\"") >&5
     10390+       if { (eval echo "$as_me:13084: \"$ac_compile\"") >&5
    1010810391   (eval $ac_compile) 2>&5
    1010910392   ac_status=$?
    1011010393-  echo "$as_me:12680: \$? = $ac_status" >&5
    10111 +  echo "$as_me:13058: \$? = $ac_status" >&5
     10394+  echo "$as_me:13087: \$? = $ac_status" >&5
    1011210395   (exit $ac_status); }; then
    1011310396                mv conftest.o func.o && \
     
    1011710400        rm -f conftest.$ac_ext func.o
    1011810401        ( eval $RANLIB conftest.a ) 2>&5 >/dev/null
    10119 @@ -12690,7 +13068,7 @@
     10402@@ -12690,7 +13097,7 @@
    1012010403   cf_cv_link_dataonly=unknown
    1012110404 else
    1012210405   cat >conftest.$ac_ext <<_ACEOF
    1012310406-#line 12693 "configure"
    10124 +#line 13071 "configure"
     10407+#line 13100 "configure"
    1012510408 #include "confdefs.h"
    1012610409 
    1012710410        int main()
    10128 @@ -12701,15 +13079,15 @@
     10411@@ -12701,15 +13108,15 @@
    1012910412 
    1013010413 _ACEOF
    1013110414 rm -f conftest$ac_exeext
    1013210415-if { (eval echo "$as_me:12704: \"$ac_link\"") >&5
    10133 +if { (eval echo "$as_me:13082: \"$ac_link\"") >&5
     10416+if { (eval echo "$as_me:13111: \"$ac_link\"") >&5
    1013410417   (eval $ac_link) 2>&5
    1013510418   ac_status=$?
    1013610419-  echo "$as_me:12707: \$? = $ac_status" >&5
    10137 +  echo "$as_me:13085: \$? = $ac_status" >&5
     10420+  echo "$as_me:13114: \$? = $ac_status" >&5
    1013810421   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    1013910422-  { (eval echo "$as_me:12709: \"$ac_try\"") >&5
    10140 +  { (eval echo "$as_me:13087: \"$ac_try\"") >&5
     10423+  { (eval echo "$as_me:13116: \"$ac_try\"") >&5
    1014110424   (eval $ac_try) 2>&5
    1014210425   ac_status=$?
    1014310426-  echo "$as_me:12712: \$? = $ac_status" >&5
    10144 +  echo "$as_me:13090: \$? = $ac_status" >&5
     10427+  echo "$as_me:13119: \$? = $ac_status" >&5
    1014510428   (exit $ac_status); }; }; then
    1014610429   cf_cv_link_dataonly=yes
    1014710430 else
    10148 @@ -12724,7 +13102,7 @@
     10431@@ -12724,7 +13131,7 @@
    1014910432 
    1015010433 fi
    1015110434 
    1015210435-echo "$as_me:12727: result: $cf_cv_link_dataonly" >&5
    10153 +echo "$as_me:13105: result: $cf_cv_link_dataonly" >&5
     10436+echo "$as_me:13134: result: $cf_cv_link_dataonly" >&5
    1015410437 echo "${ECHO_T}$cf_cv_link_dataonly" >&6
    1015510438 
    1015610439 if test "$cf_cv_link_dataonly" = no ; then
    10157 @@ -12759,13 +13137,13 @@
     10440@@ -12759,13 +13166,13 @@
    1015810441 
    1015910442 do
    1016010443 as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
    1016110444-echo "$as_me:12762: checking for $ac_func" >&5
    10162 +echo "$as_me:13140: checking for $ac_func" >&5
     10445+echo "$as_me:13169: checking for $ac_func" >&5
    1016310446 echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
    1016410447 if eval "test \"\${$as_ac_var+set}\" = set"; then
     
    1016710450   cat >conftest.$ac_ext <<_ACEOF
    1016810451-#line 12768 "configure"
    10169 +#line 13146 "configure"
     10452+#line 13175 "configure"
    1017010453 #include "confdefs.h"
    1017110454 /* System header to define __stub macros and hopefully few prototypes,
    1017210455     which can conflict with char $ac_func (); below.  */
    10173 @@ -12796,16 +13174,16 @@
     10456@@ -12796,16 +13203,16 @@
    1017410457 }
    1017510458 _ACEOF
    1017610459 rm -f conftest.$ac_objext conftest$ac_exeext
    1017710460-if { (eval echo "$as_me:12799: \"$ac_link\"") >&5
    10178 +if { (eval echo "$as_me:13177: \"$ac_link\"") >&5
     10461+if { (eval echo "$as_me:13206: \"$ac_link\"") >&5
    1017910462   (eval $ac_link) 2>&5
    1018010463   ac_status=$?
    1018110464-  echo "$as_me:12802: \$? = $ac_status" >&5
    10182 +  echo "$as_me:13180: \$? = $ac_status" >&5
     10465+  echo "$as_me:13209: \$? = $ac_status" >&5
    1018310466   (exit $ac_status); } &&
    1018410467          { ac_try='test -s conftest$ac_exeext'
    1018510468-  { (eval echo "$as_me:12805: \"$ac_try\"") >&5
    10186 +  { (eval echo "$as_me:13183: \"$ac_try\"") >&5
     10469+  { (eval echo "$as_me:13212: \"$ac_try\"") >&5
    1018710470   (eval $ac_try) 2>&5
    1018810471   ac_status=$?
    1018910472-  echo "$as_me:12808: \$? = $ac_status" >&5
    10190 +  echo "$as_me:13186: \$? = $ac_status" >&5
     10473+  echo "$as_me:13215: \$? = $ac_status" >&5
    1019110474   (exit $ac_status); }; }; then
    1019210475   eval "$as_ac_var=yes"
    1019310476 else
    10194 @@ -12815,7 +13193,7 @@
     10477@@ -12815,7 +13222,7 @@
    1019510478 fi
    1019610479 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    1019710480 fi
    1019810481-echo "$as_me:12818: result: `eval echo '${'$as_ac_var'}'`" >&5
    10199 +echo "$as_me:13196: result: `eval echo '${'$as_ac_var'}'`" >&5
     10482+echo "$as_me:13225: result: `eval echo '${'$as_ac_var'}'`" >&5
    1020010483 echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
    1020110484 if test `eval echo '${'$as_ac_var'}'` = yes; then
    1020210485   cat >>confdefs.h <<EOF
    10203 @@ -12827,14 +13205,14 @@
     10486@@ -12827,14 +13234,14 @@
    1020410487 
    1020510488 if test "$with_getcap" = "yes" ; then
    1020610489 
    1020710490-echo "$as_me:12830: checking for terminal-capability database functions" >&5
    10208 +echo "$as_me:13208: checking for terminal-capability database functions" >&5
     10491+echo "$as_me:13237: checking for terminal-capability database functions" >&5
    1020910492 echo $ECHO_N "checking for terminal-capability database functions... $ECHO_C" >&6
    1021010493 if test "${cf_cv_cgetent+set}" = set; then
     
    1021410497 cat >conftest.$ac_ext <<_ACEOF
    1021510498-#line 12837 "configure"
    10216 +#line 13215 "configure"
     10499+#line 13244 "configure"
    1021710500 #include "confdefs.h"
    1021810501 
    1021910502 #include <stdlib.h>
    10220 @@ -12854,16 +13232,16 @@
     10503@@ -12854,16 +13261,16 @@
    1022110504 }
    1022210505 _ACEOF
    1022310506 rm -f conftest.$ac_objext conftest$ac_exeext
    1022410507-if { (eval echo "$as_me:12857: \"$ac_link\"") >&5
    10225 +if { (eval echo "$as_me:13235: \"$ac_link\"") >&5
     10508+if { (eval echo "$as_me:13264: \"$ac_link\"") >&5
    1022610509   (eval $ac_link) 2>&5
    1022710510   ac_status=$?
    1022810511-  echo "$as_me:12860: \$? = $ac_status" >&5
    10229 +  echo "$as_me:13238: \$? = $ac_status" >&5
     10512+  echo "$as_me:13267: \$? = $ac_status" >&5
    1023010513   (exit $ac_status); } &&
    1023110514          { ac_try='test -s conftest$ac_exeext'
    1023210515-  { (eval echo "$as_me:12863: \"$ac_try\"") >&5
    10233 +  { (eval echo "$as_me:13241: \"$ac_try\"") >&5
     10516+  { (eval echo "$as_me:13270: \"$ac_try\"") >&5
    1023410517   (eval $ac_try) 2>&5
    1023510518   ac_status=$?
    1023610519-  echo "$as_me:12866: \$? = $ac_status" >&5
    10237 +  echo "$as_me:13244: \$? = $ac_status" >&5
     10520+  echo "$as_me:13273: \$? = $ac_status" >&5
    1023810521   (exit $ac_status); }; }; then
    1023910522   cf_cv_cgetent=yes
    1024010523 else
    10241 @@ -12875,7 +13253,7 @@
     10524@@ -12875,7 +13282,7 @@
    1024210525 
    1024310526 fi
    1024410527 
    1024510528-echo "$as_me:12878: result: $cf_cv_cgetent" >&5
    10246 +echo "$as_me:13256: result: $cf_cv_cgetent" >&5
     10529+echo "$as_me:13285: result: $cf_cv_cgetent" >&5
    1024710530 echo "${ECHO_T}$cf_cv_cgetent" >&6
    1024810531 test "$cf_cv_cgetent" = yes && cat >>confdefs.h <<\EOF
    1024910532 #define HAVE_BSD_CGETENT 1
    10250 @@ -12883,14 +13261,14 @@
     10533@@ -12883,14 +13290,14 @@
    1025110534 
    1025210535 fi
    1025310536 
    1025410537-echo "$as_me:12886: checking for isascii" >&5
    10255 +echo "$as_me:13264: checking for isascii" >&5
     10538+echo "$as_me:13293: checking for isascii" >&5
    1025610539 echo $ECHO_N "checking for isascii... $ECHO_C" >&6
    1025710540 if test "${cf_cv_have_isascii+set}" = set; then
     
    1026110544        cat >conftest.$ac_ext <<_ACEOF
    1026210545-#line 12893 "configure"
    10263 +#line 13271 "configure"
     10546+#line 13300 "configure"
    1026410547 #include "confdefs.h"
    1026510548 #include <ctype.h>
    1026610549 int
    10267 @@ -12902,16 +13280,16 @@
     10550@@ -12902,16 +13309,16 @@
    1026810551 }
    1026910552 _ACEOF
    1027010553 rm -f conftest.$ac_objext conftest$ac_exeext
    1027110554-if { (eval echo "$as_me:12905: \"$ac_link\"") >&5
    10272 +if { (eval echo "$as_me:13283: \"$ac_link\"") >&5
     10555+if { (eval echo "$as_me:13312: \"$ac_link\"") >&5
    1027310556   (eval $ac_link) 2>&5
    1027410557   ac_status=$?
    1027510558-  echo "$as_me:12908: \$? = $ac_status" >&5
    10276 +  echo "$as_me:13286: \$? = $ac_status" >&5
     10559+  echo "$as_me:13315: \$? = $ac_status" >&5
    1027710560   (exit $ac_status); } &&
    1027810561          { ac_try='test -s conftest$ac_exeext'
    1027910562-  { (eval echo "$as_me:12911: \"$ac_try\"") >&5
    10280 +  { (eval echo "$as_me:13289: \"$ac_try\"") >&5
     10563+  { (eval echo "$as_me:13318: \"$ac_try\"") >&5
    1028110564   (eval $ac_try) 2>&5
    1028210565   ac_status=$?
    1028310566-  echo "$as_me:12914: \$? = $ac_status" >&5
    10284 +  echo "$as_me:13292: \$? = $ac_status" >&5
     10567+  echo "$as_me:13321: \$? = $ac_status" >&5
    1028510568   (exit $ac_status); }; }; then
    1028610569   cf_cv_have_isascii=yes
    1028710570 else
    10288 @@ -12922,17 +13300,17 @@
     10571@@ -12922,17 +13329,17 @@
    1028910572 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    1029010573 
    1029110574 fi
    1029210575-echo "$as_me:12925: result: $cf_cv_have_isascii" >&5
    10293 +echo "$as_me:13303: result: $cf_cv_have_isascii" >&5
     10576+echo "$as_me:13332: result: $cf_cv_have_isascii" >&5
    1029410577 echo "${ECHO_T}$cf_cv_have_isascii" >&6
    1029510578 test "$cf_cv_have_isascii" = yes && cat >>confdefs.h <<\EOF
     
    1029910582 if test "$ac_cv_func_sigaction" = yes; then
    1030010583-echo "$as_me:12932: checking whether sigaction needs _POSIX_SOURCE" >&5
    10301 +echo "$as_me:13310: checking whether sigaction needs _POSIX_SOURCE" >&5
     10584+echo "$as_me:13339: checking whether sigaction needs _POSIX_SOURCE" >&5
    1030210585 echo $ECHO_N "checking whether sigaction needs _POSIX_SOURCE... $ECHO_C" >&6
    1030310586 cat >conftest.$ac_ext <<_ACEOF
    1030410587-#line 12935 "configure"
    10305 +#line 13313 "configure"
     10588+#line 13342 "configure"
    1030610589 #include "confdefs.h"
    1030710590 
    1030810591 #include <sys/types.h>
    10309 @@ -12946,16 +13324,16 @@
     10592@@ -12946,16 +13353,16 @@
    1031010593 }
    1031110594 _ACEOF
    1031210595 rm -f conftest.$ac_objext
    1031310596-if { (eval echo "$as_me:12949: \"$ac_compile\"") >&5
    10314 +if { (eval echo "$as_me:13327: \"$ac_compile\"") >&5
     10597+if { (eval echo "$as_me:13356: \"$ac_compile\"") >&5
    1031510598   (eval $ac_compile) 2>&5
    1031610599   ac_status=$?
    1031710600-  echo "$as_me:12952: \$? = $ac_status" >&5
    10318 +  echo "$as_me:13330: \$? = $ac_status" >&5
     10601+  echo "$as_me:13359: \$? = $ac_status" >&5
    1031910602   (exit $ac_status); } &&
    1032010603          { ac_try='test -s conftest.$ac_objext'
    1032110604-  { (eval echo "$as_me:12955: \"$ac_try\"") >&5
    10322 +  { (eval echo "$as_me:13333: \"$ac_try\"") >&5
     10605+  { (eval echo "$as_me:13362: \"$ac_try\"") >&5
    1032310606   (eval $ac_try) 2>&5
    1032410607   ac_status=$?
    1032510608-  echo "$as_me:12958: \$? = $ac_status" >&5
    10326 +  echo "$as_me:13336: \$? = $ac_status" >&5
     10609+  echo "$as_me:13365: \$? = $ac_status" >&5
    1032710610   (exit $ac_status); }; }; then
    1032810611   sigact_bad=no
    1032910612 else
    10330 @@ -12963,7 +13341,7 @@
     10613@@ -12963,7 +13370,7 @@
    1033110614 cat conftest.$ac_ext >&5
    1033210615 
    1033310616 cat >conftest.$ac_ext <<_ACEOF
    1033410617-#line 12966 "configure"
    10335 +#line 13344 "configure"
     10618+#line 13373 "configure"
    1033610619 #include "confdefs.h"
    1033710620 
    1033810621 #define _POSIX_SOURCE
    10339 @@ -12978,16 +13356,16 @@
     10622@@ -12978,16 +13385,16 @@
    1034010623 }
    1034110624 _ACEOF
    1034210625 rm -f conftest.$ac_objext
    1034310626-if { (eval echo "$as_me:12981: \"$ac_compile\"") >&5
    10344 +if { (eval echo "$as_me:13359: \"$ac_compile\"") >&5
     10627+if { (eval echo "$as_me:13388: \"$ac_compile\"") >&5
    1034510628   (eval $ac_compile) 2>&5
    1034610629   ac_status=$?
    1034710630-  echo "$as_me:12984: \$? = $ac_status" >&5
    10348 +  echo "$as_me:13362: \$? = $ac_status" >&5
     10631+  echo "$as_me:13391: \$? = $ac_status" >&5
    1034910632   (exit $ac_status); } &&
    1035010633          { ac_try='test -s conftest.$ac_objext'
    1035110634-  { (eval echo "$as_me:12987: \"$ac_try\"") >&5
    10352 +  { (eval echo "$as_me:13365: \"$ac_try\"") >&5
     10635+  { (eval echo "$as_me:13394: \"$ac_try\"") >&5
    1035310636   (eval $ac_try) 2>&5
    1035410637   ac_status=$?
    1035510638-  echo "$as_me:12990: \$? = $ac_status" >&5
    10356 +  echo "$as_me:13368: \$? = $ac_status" >&5
     10639+  echo "$as_me:13397: \$? = $ac_status" >&5
    1035710640   (exit $ac_status); }; }; then
    1035810641   sigact_bad=yes
    1035910642         cat >>confdefs.h <<\EOF
    10360 @@ -13002,11 +13380,11 @@
     10643@@ -13002,11 +13409,11 @@
    1036110644 rm -f conftest.$ac_objext conftest.$ac_ext
    1036210645 fi
    1036310646 rm -f conftest.$ac_objext conftest.$ac_ext
    1036410647-echo "$as_me:13005: result: $sigact_bad" >&5
    10365 +echo "$as_me:13383: result: $sigact_bad" >&5
     10648+echo "$as_me:13412: result: $sigact_bad" >&5
    1036610649 echo "${ECHO_T}$sigact_bad" >&6
    1036710650 fi
    1036810651 
    1036910652-echo "$as_me:13009: checking if nanosleep really works" >&5
    10370 +echo "$as_me:13387: checking if nanosleep really works" >&5
     10653+echo "$as_me:13416: checking if nanosleep really works" >&5
    1037110654 echo $ECHO_N "checking if nanosleep really works... $ECHO_C" >&6
    1037210655 if test "${cf_cv_func_nanosleep+set}" = set; then
    1037310656   echo $ECHO_N "(cached) $ECHO_C" >&6
    10374 @@ -13016,7 +13394,7 @@
     10657@@ -13016,7 +13423,7 @@
    1037510658   cf_cv_func_nanosleep=unknown
    1037610659 else
    1037710660   cat >conftest.$ac_ext <<_ACEOF
    1037810661-#line 13019 "configure"
    10379 +#line 13397 "configure"
     10662+#line 13426 "configure"
    1038010663 #include "confdefs.h"
    1038110664 
    1038210665 #include <stdio.h>
    10383 @@ -13041,15 +13419,15 @@
     10666@@ -13041,15 +13448,15 @@
    1038410667 
    1038510668 _ACEOF
    1038610669 rm -f conftest$ac_exeext
    1038710670-if { (eval echo "$as_me:13044: \"$ac_link\"") >&5
    10388 +if { (eval echo "$as_me:13422: \"$ac_link\"") >&5
     10671+if { (eval echo "$as_me:13451: \"$ac_link\"") >&5
    1038910672   (eval $ac_link) 2>&5
    1039010673   ac_status=$?
    1039110674-  echo "$as_me:13047: \$? = $ac_status" >&5
    10392 +  echo "$as_me:13425: \$? = $ac_status" >&5
     10675+  echo "$as_me:13454: \$? = $ac_status" >&5
    1039310676   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    1039410677-  { (eval echo "$as_me:13049: \"$ac_try\"") >&5
    10395 +  { (eval echo "$as_me:13427: \"$ac_try\"") >&5
     10678+  { (eval echo "$as_me:13456: \"$ac_try\"") >&5
    1039610679   (eval $ac_try) 2>&5
    1039710680   ac_status=$?
    1039810681-  echo "$as_me:13052: \$? = $ac_status" >&5
    10399 +  echo "$as_me:13430: \$? = $ac_status" >&5
     10682+  echo "$as_me:13459: \$? = $ac_status" >&5
    1040010683   (exit $ac_status); }; }; then
    1040110684   cf_cv_func_nanosleep=yes
    1040210685 else
    10403 @@ -13061,7 +13439,7 @@
     10686@@ -13061,7 +13468,7 @@
    1040410687 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
    1040510688 fi
    1040610689 fi
    1040710690-echo "$as_me:13064: result: $cf_cv_func_nanosleep" >&5
    10408 +echo "$as_me:13442: result: $cf_cv_func_nanosleep" >&5
     10691+echo "$as_me:13471: result: $cf_cv_func_nanosleep" >&5
    1040910692 echo "${ECHO_T}$cf_cv_func_nanosleep" >&6
    1041010693 
    1041110694 test "$cf_cv_func_nanosleep" = "yes" && cat >>confdefs.h <<\EOF
    10412 @@ -13075,23 +13453,23 @@
     10695@@ -13075,23 +13482,23 @@
    1041310696 
    1041410697 do
    1041510698 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
    1041610699-echo "$as_me:13078: checking for $ac_header" >&5
    10417 +echo "$as_me:13456: checking for $ac_header" >&5
     10700+echo "$as_me:13485: checking for $ac_header" >&5
    1041810701 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
    1041910702 if eval "test \"\${$as_ac_Header+set}\" = set"; then
     
    1042210705   cat >conftest.$ac_ext <<_ACEOF
    1042310706-#line 13084 "configure"
    10424 +#line 13462 "configure"
     10707+#line 13491 "configure"
    1042510708 #include "confdefs.h"
    1042610709 #include <$ac_header>
    1042710710 _ACEOF
    1042810711-if { (eval echo "$as_me:13088: \"$ac_cpp conftest.$ac_ext\"") >&5
    10429 +if { (eval echo "$as_me:13466: \"$ac_cpp conftest.$ac_ext\"") >&5
     10712+if { (eval echo "$as_me:13495: \"$ac_cpp conftest.$ac_ext\"") >&5
    1043010713   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    1043110714   ac_status=$?
     
    1043410717   cat conftest.err >&5
    1043510718-  echo "$as_me:13094: \$? = $ac_status" >&5
    10436 +  echo "$as_me:13472: \$? = $ac_status" >&5
     10719+  echo "$as_me:13501: \$? = $ac_status" >&5
    1043710720   (exit $ac_status); } >/dev/null; then
    1043810721   if test -s conftest.err; then
    1043910722     ac_cpp_err=$ac_c_preproc_warn_flag
    10440 @@ -13110,7 +13488,7 @@
     10723@@ -13110,7 +13517,7 @@
    1044110724 fi
    1044210725 rm -f conftest.err conftest.$ac_ext
    1044310726 fi
    1044410727-echo "$as_me:13113: result: `eval echo '${'$as_ac_Header'}'`" >&5
    10445 +echo "$as_me:13491: result: `eval echo '${'$as_ac_Header'}'`" >&5
     10728+echo "$as_me:13520: result: `eval echo '${'$as_ac_Header'}'`" >&5
    1044610729 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
    1044710730 if test `eval echo '${'$as_ac_Header'}'` = yes; then
    1044810731   cat >>confdefs.h <<EOF
    10449 @@ -13125,23 +13503,23 @@
     10732@@ -13125,23 +13532,23 @@
    1045010733 for ac_header in sys/termio.h
    1045110734 do
    1045210735 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
    1045310736-echo "$as_me:13128: checking for $ac_header" >&5
    10454 +echo "$as_me:13506: checking for $ac_header" >&5
     10737+echo "$as_me:13535: checking for $ac_header" >&5
    1045510738 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
    1045610739 if eval "test \"\${$as_ac_Header+set}\" = set"; then
     
    1045910742   cat >conftest.$ac_ext <<_ACEOF
    1046010743-#line 13134 "configure"
    10461 +#line 13512 "configure"
     10744+#line 13541 "configure"
    1046210745 #include "confdefs.h"
    1046310746 #include <$ac_header>
    1046410747 _ACEOF
    1046510748-if { (eval echo "$as_me:13138: \"$ac_cpp conftest.$ac_ext\"") >&5
    10466 +if { (eval echo "$as_me:13516: \"$ac_cpp conftest.$ac_ext\"") >&5
     10749+if { (eval echo "$as_me:13545: \"$ac_cpp conftest.$ac_ext\"") >&5
    1046710750   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    1046810751   ac_status=$?
     
    1047110754   cat conftest.err >&5
    1047210755-  echo "$as_me:13144: \$? = $ac_status" >&5
    10473 +  echo "$as_me:13522: \$? = $ac_status" >&5
     10756+  echo "$as_me:13551: \$? = $ac_status" >&5
    1047410757   (exit $ac_status); } >/dev/null; then
    1047510758   if test -s conftest.err; then
    1047610759     ac_cpp_err=$ac_c_preproc_warn_flag
    10477 @@ -13160,7 +13538,7 @@
     10760@@ -13160,7 +13567,7 @@
    1047810761 fi
    1047910762 rm -f conftest.err conftest.$ac_ext
    1048010763 fi
    1048110764-echo "$as_me:13163: result: `eval echo '${'$as_ac_Header'}'`" >&5
    10482 +echo "$as_me:13541: result: `eval echo '${'$as_ac_Header'}'`" >&5
     10765+echo "$as_me:13570: result: `eval echo '${'$as_ac_Header'}'`" >&5
    1048310766 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
    1048410767 if test `eval echo '${'$as_ac_Header'}'` = yes; then
    1048510768   cat >>confdefs.h <<EOF
    10486 @@ -13178,10 +13556,10 @@
     10769@@ -13178,10 +13585,10 @@
    1048710770        *)      termios_bad=maybe ;;
    1048810771        esac
    1048910772        if test "$termios_bad" = maybe ; then
    1049010773-       echo "$as_me:13181: checking whether termios.h needs _POSIX_SOURCE" >&5
    10491 +       echo "$as_me:13559: checking whether termios.h needs _POSIX_SOURCE" >&5
     10774+       echo "$as_me:13588: checking whether termios.h needs _POSIX_SOURCE" >&5
    1049210775 echo $ECHO_N "checking whether termios.h needs _POSIX_SOURCE... $ECHO_C" >&6
    1049310776        cat >conftest.$ac_ext <<_ACEOF
    1049410777-#line 13184 "configure"
    10495 +#line 13562 "configure"
     10778+#line 13591 "configure"
    1049610779 #include "confdefs.h"
    1049710780 #include <termios.h>
    1049810781 int
    10499 @@ -13193,16 +13571,16 @@
     10782@@ -13193,16 +13600,16 @@
    1050010783 }
    1050110784 _ACEOF
    1050210785 rm -f conftest.$ac_objext
    1050310786-if { (eval echo "$as_me:13196: \"$ac_compile\"") >&5
    10504 +if { (eval echo "$as_me:13574: \"$ac_compile\"") >&5
     10787+if { (eval echo "$as_me:13603: \"$ac_compile\"") >&5
    1050510788   (eval $ac_compile) 2>&5
    1050610789   ac_status=$?
    1050710790-  echo "$as_me:13199: \$? = $ac_status" >&5
    10508 +  echo "$as_me:13577: \$? = $ac_status" >&5
     10791+  echo "$as_me:13606: \$? = $ac_status" >&5
    1050910792   (exit $ac_status); } &&
    1051010793          { ac_try='test -s conftest.$ac_objext'
    1051110794-  { (eval echo "$as_me:13202: \"$ac_try\"") >&5
    10512 +  { (eval echo "$as_me:13580: \"$ac_try\"") >&5
     10795+  { (eval echo "$as_me:13609: \"$ac_try\"") >&5
    1051310796   (eval $ac_try) 2>&5
    1051410797   ac_status=$?
    1051510798-  echo "$as_me:13205: \$? = $ac_status" >&5
    10516 +  echo "$as_me:13583: \$? = $ac_status" >&5
     10799+  echo "$as_me:13612: \$? = $ac_status" >&5
    1051710800   (exit $ac_status); }; }; then
    1051810801   termios_bad=no
    1051910802 else
    10520 @@ -13210,7 +13588,7 @@
     10803@@ -13210,7 +13617,7 @@
    1052110804 cat conftest.$ac_ext >&5
    1052210805 
    1052310806                cat >conftest.$ac_ext <<_ACEOF
    1052410807-#line 13213 "configure"
    10525 +#line 13591 "configure"
     10808+#line 13620 "configure"
    1052610809 #include "confdefs.h"
    1052710810 
    1052810811 #define _POSIX_SOURCE
    10529 @@ -13224,16 +13602,16 @@
     10812@@ -13224,16 +13631,16 @@
    1053010813 }
    1053110814 _ACEOF
    1053210815 rm -f conftest.$ac_objext
    1053310816-if { (eval echo "$as_me:13227: \"$ac_compile\"") >&5
    10534 +if { (eval echo "$as_me:13605: \"$ac_compile\"") >&5
     10817+if { (eval echo "$as_me:13634: \"$ac_compile\"") >&5
    1053510818   (eval $ac_compile) 2>&5
    1053610819   ac_status=$?
    1053710820-  echo "$as_me:13230: \$? = $ac_status" >&5
    10538 +  echo "$as_me:13608: \$? = $ac_status" >&5
     10821+  echo "$as_me:13637: \$? = $ac_status" >&5
    1053910822   (exit $ac_status); } &&
    1054010823          { ac_try='test -s conftest.$ac_objext'
    1054110824-  { (eval echo "$as_me:13233: \"$ac_try\"") >&5
    10542 +  { (eval echo "$as_me:13611: \"$ac_try\"") >&5
     10825+  { (eval echo "$as_me:13640: \"$ac_try\"") >&5
    1054310826   (eval $ac_try) 2>&5
    1054410827   ac_status=$?
    1054510828-  echo "$as_me:13236: \$? = $ac_status" >&5
    10546 +  echo "$as_me:13614: \$? = $ac_status" >&5
     10829+  echo "$as_me:13643: \$? = $ac_status" >&5
    1054710830   (exit $ac_status); }; }; then
    1054810831   termios_bad=unknown
    1054910832 else
    10550 @@ -13248,19 +13626,19 @@
     10833@@ -13248,19 +13655,19 @@
    1055110834 
    1055210835 fi
    1055310836 rm -f conftest.$ac_objext conftest.$ac_ext
    1055410837-       echo "$as_me:13251: result: $termios_bad" >&5
    10555 +       echo "$as_me:13629: result: $termios_bad" >&5
     10838+       echo "$as_me:13658: result: $termios_bad" >&5
    1055610839 echo "${ECHO_T}$termios_bad" >&6
    1055710840        fi
     
    1055910842 
    1056010843-echo "$as_me:13256: checking for tcgetattr" >&5
    10561 +echo "$as_me:13634: checking for tcgetattr" >&5
     10844+echo "$as_me:13663: checking for tcgetattr" >&5
    1056210845 echo $ECHO_N "checking for tcgetattr... $ECHO_C" >&6
    1056310846 if test "${cf_cv_have_tcgetattr+set}" = set; then
     
    1056710850 cat >conftest.$ac_ext <<_ACEOF
    1056810851-#line 13263 "configure"
    10569 +#line 13641 "configure"
     10852+#line 13670 "configure"
    1057010853 #include "confdefs.h"
    1057110854 
    1057210855 #include <sys/types.h>
    10573 @@ -13288,16 +13666,16 @@
     10856@@ -13288,16 +13695,16 @@
    1057410857 }
    1057510858 _ACEOF
    1057610859 rm -f conftest.$ac_objext conftest$ac_exeext
    1057710860-if { (eval echo "$as_me:13291: \"$ac_link\"") >&5
    10578 +if { (eval echo "$as_me:13669: \"$ac_link\"") >&5
     10861+if { (eval echo "$as_me:13698: \"$ac_link\"") >&5
    1057910862   (eval $ac_link) 2>&5
    1058010863   ac_status=$?
    1058110864-  echo "$as_me:13294: \$? = $ac_status" >&5
    10582 +  echo "$as_me:13672: \$? = $ac_status" >&5
     10865+  echo "$as_me:13701: \$? = $ac_status" >&5
    1058310866   (exit $ac_status); } &&
    1058410867          { ac_try='test -s conftest$ac_exeext'
    1058510868-  { (eval echo "$as_me:13297: \"$ac_try\"") >&5
    10586 +  { (eval echo "$as_me:13675: \"$ac_try\"") >&5
     10869+  { (eval echo "$as_me:13704: \"$ac_try\"") >&5
    1058710870   (eval $ac_try) 2>&5
    1058810871   ac_status=$?
    1058910872-  echo "$as_me:13300: \$? = $ac_status" >&5
    10590 +  echo "$as_me:13678: \$? = $ac_status" >&5
     10873+  echo "$as_me:13707: \$? = $ac_status" >&5
    1059110874   (exit $ac_status); }; }; then
    1059210875   cf_cv_have_tcgetattr=yes
    1059310876 else
    10594 @@ -13307,20 +13685,20 @@
     10877@@ -13307,20 +13714,20 @@
    1059510878 fi
    1059610879 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    1059710880 fi
    1059810881-echo "$as_me:13310: result: $cf_cv_have_tcgetattr" >&5
    10599 +echo "$as_me:13688: result: $cf_cv_have_tcgetattr" >&5
     10882+echo "$as_me:13717: result: $cf_cv_have_tcgetattr" >&5
    1060010883 echo "${ECHO_T}$cf_cv_have_tcgetattr" >&6
    1060110884 test "$cf_cv_have_tcgetattr" = yes && cat >>confdefs.h <<\EOF
     
    1060410887 
    1060510888-echo "$as_me:13316: checking for vsscanf function or workaround" >&5
    10606 +echo "$as_me:13694: checking for vsscanf function or workaround" >&5
     10889+echo "$as_me:13723: checking for vsscanf function or workaround" >&5
    1060710890 echo $ECHO_N "checking for vsscanf function or workaround... $ECHO_C" >&6
    1060810891 if test "${cf_cv_func_vsscanf+set}" = set; then
     
    1061210895 cat >conftest.$ac_ext <<_ACEOF
    1061310896-#line 13323 "configure"
    10614 +#line 13701 "configure"
     10897+#line 13730 "configure"
    1061510898 #include "confdefs.h"
    1061610899 
    1061710900 #include <stdarg.h>
    10618 @@ -13336,16 +13714,16 @@
     10901@@ -13336,16 +13743,16 @@
    1061910902 }
    1062010903 _ACEOF
    1062110904 rm -f conftest.$ac_objext conftest$ac_exeext
    1062210905-if { (eval echo "$as_me:13339: \"$ac_link\"") >&5
    10623 +if { (eval echo "$as_me:13717: \"$ac_link\"") >&5
     10906+if { (eval echo "$as_me:13746: \"$ac_link\"") >&5
    1062410907   (eval $ac_link) 2>&5
    1062510908   ac_status=$?
    1062610909-  echo "$as_me:13342: \$? = $ac_status" >&5
    10627 +  echo "$as_me:13720: \$? = $ac_status" >&5
     10910+  echo "$as_me:13749: \$? = $ac_status" >&5
    1062810911   (exit $ac_status); } &&
    1062910912          { ac_try='test -s conftest$ac_exeext'
    1063010913-  { (eval echo "$as_me:13345: \"$ac_try\"") >&5
    10631 +  { (eval echo "$as_me:13723: \"$ac_try\"") >&5
     10914+  { (eval echo "$as_me:13752: \"$ac_try\"") >&5
    1063210915   (eval $ac_try) 2>&5
    1063310916   ac_status=$?
    1063410917-  echo "$as_me:13348: \$? = $ac_status" >&5
    10635 +  echo "$as_me:13726: \$? = $ac_status" >&5
     10918+  echo "$as_me:13755: \$? = $ac_status" >&5
    1063610919   (exit $ac_status); }; }; then
    1063710920   cf_cv_func_vsscanf=vsscanf
    1063810921 else
    10639 @@ -13353,7 +13731,7 @@
     10922@@ -13353,7 +13760,7 @@
    1064010923 cat conftest.$ac_ext >&5
    1064110924 
    1064210925 cat >conftest.$ac_ext <<_ACEOF
    1064310926-#line 13356 "configure"
    10644 +#line 13734 "configure"
     10927+#line 13763 "configure"
    1064510928 #include "confdefs.h"
    1064610929 
    1064710930 #include <stdarg.h>
    10648 @@ -13375,16 +13753,16 @@
     10931@@ -13375,16 +13782,16 @@
    1064910932 }
    1065010933 _ACEOF
    1065110934 rm -f conftest.$ac_objext conftest$ac_exeext
    1065210935-if { (eval echo "$as_me:13378: \"$ac_link\"") >&5
    10653 +if { (eval echo "$as_me:13756: \"$ac_link\"") >&5
     10936+if { (eval echo "$as_me:13785: \"$ac_link\"") >&5
    1065410937   (eval $ac_link) 2>&5
    1065510938   ac_status=$?
    1065610939-  echo "$as_me:13381: \$? = $ac_status" >&5
    10657 +  echo "$as_me:13759: \$? = $ac_status" >&5
     10940+  echo "$as_me:13788: \$? = $ac_status" >&5
    1065810941   (exit $ac_status); } &&
    1065910942          { ac_try='test -s conftest$ac_exeext'
    1066010943-  { (eval echo "$as_me:13384: \"$ac_try\"") >&5
    10661 +  { (eval echo "$as_me:13762: \"$ac_try\"") >&5
     10944+  { (eval echo "$as_me:13791: \"$ac_try\"") >&5
    1066210945   (eval $ac_try) 2>&5
    1066310946   ac_status=$?
    1066410947-  echo "$as_me:13387: \$? = $ac_status" >&5
    10665 +  echo "$as_me:13765: \$? = $ac_status" >&5
     10948+  echo "$as_me:13794: \$? = $ac_status" >&5
    1066610949   (exit $ac_status); }; }; then
    1066710950   cf_cv_func_vsscanf=vfscanf
    1066810951 else
    10669 @@ -13392,7 +13770,7 @@
     10952@@ -13392,7 +13799,7 @@
    1067010953 cat conftest.$ac_ext >&5
    1067110954 
    1067210955 cat >conftest.$ac_ext <<_ACEOF
    1067310956-#line 13395 "configure"
    10674 +#line 13773 "configure"
     10957+#line 13802 "configure"
    1067510958 #include "confdefs.h"
    1067610959 
    1067710960 #include <stdarg.h>
    10678 @@ -13414,16 +13792,16 @@
     10961@@ -13414,16 +13821,16 @@
    1067910962 }
    1068010963 _ACEOF
    1068110964 rm -f conftest.$ac_objext conftest$ac_exeext
    1068210965-if { (eval echo "$as_me:13417: \"$ac_link\"") >&5
    10683 +if { (eval echo "$as_me:13795: \"$ac_link\"") >&5
     10966+if { (eval echo "$as_me:13824: \"$ac_link\"") >&5
    1068410967   (eval $ac_link) 2>&5
    1068510968   ac_status=$?
    1068610969-  echo "$as_me:13420: \$? = $ac_status" >&5
    10687 +  echo "$as_me:13798: \$? = $ac_status" >&5
     10970+  echo "$as_me:13827: \$? = $ac_status" >&5
    1068810971   (exit $ac_status); } &&
    1068910972          { ac_try='test -s conftest$ac_exeext'
    1069010973-  { (eval echo "$as_me:13423: \"$ac_try\"") >&5
    10691 +  { (eval echo "$as_me:13801: \"$ac_try\"") >&5
     10974+  { (eval echo "$as_me:13830: \"$ac_try\"") >&5
    1069210975   (eval $ac_try) 2>&5
    1069310976   ac_status=$?
    1069410977-  echo "$as_me:13426: \$? = $ac_status" >&5
    10695 +  echo "$as_me:13804: \$? = $ac_status" >&5
     10978+  echo "$as_me:13833: \$? = $ac_status" >&5
    1069610979   (exit $ac_status); }; }; then
    1069710980   cf_cv_func_vsscanf=_doscan
    1069810981 else
    10699 @@ -13438,7 +13816,7 @@
     10982@@ -13438,7 +13845,7 @@
    1070010983 fi
    1070110984 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    1070210985 fi
    1070310986-echo "$as_me:13441: result: $cf_cv_func_vsscanf" >&5
    10704 +echo "$as_me:13819: result: $cf_cv_func_vsscanf" >&5
     10987+echo "$as_me:13848: result: $cf_cv_func_vsscanf" >&5
    1070510988 echo "${ECHO_T}$cf_cv_func_vsscanf" >&6
    1070610989 
    1070710990 case $cf_cv_func_vsscanf in #(vi
    10708 @@ -13456,7 +13834,7 @@
     10991@@ -13456,7 +13863,7 @@
    1070910992 ;;
    1071010993 esac
    1071110994 
    1071210995-echo "$as_me:13459: checking for working mkstemp" >&5
    10713 +echo "$as_me:13837: checking for working mkstemp" >&5
     10996+echo "$as_me:13866: checking for working mkstemp" >&5
    1071410997 echo $ECHO_N "checking for working mkstemp... $ECHO_C" >&6
    1071510998 if test "${cf_cv_func_mkstemp+set}" = set; then
    1071610999   echo $ECHO_N "(cached) $ECHO_C" >&6
    10717 @@ -13464,13 +13842,13 @@
     11000@@ -13464,13 +13871,13 @@
    1071811001 
    1071911002 rm -f conftest*
    1072011003 if test "$cross_compiling" = yes; then
    1072111004-  echo "$as_me:13467: checking for mkstemp" >&5
    10722 +  echo "$as_me:13845: checking for mkstemp" >&5
     11005+  echo "$as_me:13874: checking for mkstemp" >&5
    1072311006 echo $ECHO_N "checking for mkstemp... $ECHO_C" >&6
    1072411007 if test "${ac_cv_func_mkstemp+set}" = set; then
     
    1072711010   cat >conftest.$ac_ext <<_ACEOF
    1072811011-#line 13473 "configure"
    10729 +#line 13851 "configure"
     11012+#line 13880 "configure"
    1073011013 #include "confdefs.h"
    1073111014 /* System header to define __stub macros and hopefully few prototypes,
    1073211015     which can conflict with char mkstemp (); below.  */
    10733 @@ -13501,16 +13879,16 @@
     11016@@ -13501,16 +13908,16 @@
    1073411017 }
    1073511018 _ACEOF
    1073611019 rm -f conftest.$ac_objext conftest$ac_exeext
    1073711020-if { (eval echo "$as_me:13504: \"$ac_link\"") >&5
    10738 +if { (eval echo "$as_me:13882: \"$ac_link\"") >&5
     11021+if { (eval echo "$as_me:13911: \"$ac_link\"") >&5
    1073911022   (eval $ac_link) 2>&5
    1074011023   ac_status=$?
    1074111024-  echo "$as_me:13507: \$? = $ac_status" >&5
    10742 +  echo "$as_me:13885: \$? = $ac_status" >&5
     11025+  echo "$as_me:13914: \$? = $ac_status" >&5
    1074311026   (exit $ac_status); } &&
    1074411027          { ac_try='test -s conftest$ac_exeext'
    1074511028-  { (eval echo "$as_me:13510: \"$ac_try\"") >&5
    10746 +  { (eval echo "$as_me:13888: \"$ac_try\"") >&5
     11029+  { (eval echo "$as_me:13917: \"$ac_try\"") >&5
    1074711030   (eval $ac_try) 2>&5
    1074811031   ac_status=$?
    1074911032-  echo "$as_me:13513: \$? = $ac_status" >&5
    10750 +  echo "$as_me:13891: \$? = $ac_status" >&5
     11033+  echo "$as_me:13920: \$? = $ac_status" >&5
    1075111034   (exit $ac_status); }; }; then
    1075211035   ac_cv_func_mkstemp=yes
    1075311036 else
    10754 @@ -13520,12 +13898,12 @@
     11037@@ -13520,12 +13927,12 @@
    1075511038 fi
    1075611039 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    1075711040 fi
    1075811041-echo "$as_me:13523: result: $ac_cv_func_mkstemp" >&5
    10759 +echo "$as_me:13901: result: $ac_cv_func_mkstemp" >&5
     11042+echo "$as_me:13930: result: $ac_cv_func_mkstemp" >&5
    1076011043 echo "${ECHO_T}$ac_cv_func_mkstemp" >&6
    1076111044 
     
    1076311046   cat >conftest.$ac_ext <<_ACEOF
    1076411047-#line 13528 "configure"
    10765 +#line 13906 "configure"
     11048+#line 13935 "configure"
    1076611049 #include "confdefs.h"
    1076711050 
    1076811051 #include <sys/types.h>
    10769 @@ -13563,15 +13941,15 @@
     11052@@ -13563,15 +13970,15 @@
    1077011053 
    1077111054 _ACEOF
    1077211055 rm -f conftest$ac_exeext
    1077311056-if { (eval echo "$as_me:13566: \"$ac_link\"") >&5
    10774 +if { (eval echo "$as_me:13944: \"$ac_link\"") >&5
     11057+if { (eval echo "$as_me:13973: \"$ac_link\"") >&5
    1077511058   (eval $ac_link) 2>&5
    1077611059   ac_status=$?
    1077711060-  echo "$as_me:13569: \$? = $ac_status" >&5
    10778 +  echo "$as_me:13947: \$? = $ac_status" >&5
     11061+  echo "$as_me:13976: \$? = $ac_status" >&5
    1077911062   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    1078011063-  { (eval echo "$as_me:13571: \"$ac_try\"") >&5
    10781 +  { (eval echo "$as_me:13949: \"$ac_try\"") >&5
     11064+  { (eval echo "$as_me:13978: \"$ac_try\"") >&5
    1078211065   (eval $ac_try) 2>&5
    1078311066   ac_status=$?
    1078411067-  echo "$as_me:13574: \$? = $ac_status" >&5
    10785 +  echo "$as_me:13952: \$? = $ac_status" >&5
     11068+  echo "$as_me:13981: \$? = $ac_status" >&5
    1078611069   (exit $ac_status); }; }; then
    1078711070   cf_cv_func_mkstemp=yes
    1078811071 
    10789 @@ -13586,7 +13964,7 @@
     11072@@ -13586,7 +13993,7 @@
    1079011073 fi
    1079111074 
    1079211075 fi
    1079311076-echo "$as_me:13589: result: $cf_cv_func_mkstemp" >&5
    10794 +echo "$as_me:13967: result: $cf_cv_func_mkstemp" >&5
     11077+echo "$as_me:13996: result: $cf_cv_func_mkstemp" >&5
    1079511078 echo "${ECHO_T}$cf_cv_func_mkstemp" >&6
    1079611079 if test "$cf_cv_func_mkstemp" = yes ; then
    1079711080        cat >>confdefs.h <<\EOF
    10798 @@ -13604,21 +13982,21 @@
     11081@@ -13604,21 +14011,21 @@
    1079911082 fi
    1080011083 
    1080111084 if test "$cross_compiling" = yes ; then
    1080211085-       { echo "$as_me:13607: WARNING: cross compiling: assume setvbuf params not reversed" >&5
    10803 +       { echo "$as_me:13985: WARNING: cross compiling: assume setvbuf params not reversed" >&5
     11086+       { echo "$as_me:14014: WARNING: cross compiling: assume setvbuf params not reversed" >&5
    1080411087 echo "$as_me: WARNING: cross compiling: assume setvbuf params not reversed" >&2;}
    1080511088 else
    1080611089-       echo "$as_me:13610: checking whether setvbuf arguments are reversed" >&5
    10807 +       echo "$as_me:13988: checking whether setvbuf arguments are reversed" >&5
     11090+       echo "$as_me:14017: checking whether setvbuf arguments are reversed" >&5
    1080811091 echo $ECHO_N "checking whether setvbuf arguments are reversed... $ECHO_C" >&6
    1080911092 if test "${ac_cv_func_setvbuf_reversed+set}" = set; then
     
    1081211095   if test "$cross_compiling" = yes; then
    1081311096-  { { echo "$as_me:13616: error: cannot run test program while cross compiling" >&5
    10814 +  { { echo "$as_me:13994: error: cannot run test program while cross compiling" >&5
     11097+  { { echo "$as_me:14023: error: cannot run test program while cross compiling" >&5
    1081511098 echo "$as_me: error: cannot run test program while cross compiling" >&2;}
    1081611099    { (exit 1); exit 1; }; }
     
    1081811101   cat >conftest.$ac_ext <<_ACEOF
    1081911102-#line 13621 "configure"
    10820 +#line 13999 "configure"
     11103+#line 14028 "configure"
    1082111104 #include "confdefs.h"
    1082211105 #include <stdio.h>
    1082311106 /* If setvbuf has the reversed format, exit 0. */
    10824 @@ -13635,15 +14013,15 @@
     11107@@ -13635,15 +14042,15 @@
    1082511108 }
    1082611109 _ACEOF
    1082711110 rm -f conftest$ac_exeext
    1082811111-if { (eval echo "$as_me:13638: \"$ac_link\"") >&5
    10829 +if { (eval echo "$as_me:14016: \"$ac_link\"") >&5
     11112+if { (eval echo "$as_me:14045: \"$ac_link\"") >&5
    1083011113   (eval $ac_link) 2>&5
    1083111114   ac_status=$?
    1083211115-  echo "$as_me:13641: \$? = $ac_status" >&5
    10833 +  echo "$as_me:14019: \$? = $ac_status" >&5
     11116+  echo "$as_me:14048: \$? = $ac_status" >&5
    1083411117   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    1083511118-  { (eval echo "$as_me:13643: \"$ac_try\"") >&5
    10836 +  { (eval echo "$as_me:14021: \"$ac_try\"") >&5
     11119+  { (eval echo "$as_me:14050: \"$ac_try\"") >&5
    1083711120   (eval $ac_try) 2>&5
    1083811121   ac_status=$?
    1083911122-  echo "$as_me:13646: \$? = $ac_status" >&5
    10840 +  echo "$as_me:14024: \$? = $ac_status" >&5
     11123+  echo "$as_me:14053: \$? = $ac_status" >&5
    1084111124   (exit $ac_status); }; }; then
    1084211125   ac_cv_func_setvbuf_reversed=yes
    1084311126 else
    10844 @@ -13656,7 +14034,7 @@
     11127@@ -13656,7 +14063,7 @@
    1084511128 fi
    1084611129 rm -f core core.* *.core
    1084711130 fi
    1084811131-echo "$as_me:13659: result: $ac_cv_func_setvbuf_reversed" >&5
    10849 +echo "$as_me:14037: result: $ac_cv_func_setvbuf_reversed" >&5
     11132+echo "$as_me:14066: result: $ac_cv_func_setvbuf_reversed" >&5
    1085011133 echo "${ECHO_T}$ac_cv_func_setvbuf_reversed" >&6
    1085111134 if test $ac_cv_func_setvbuf_reversed = yes; then
    1085211135 
    10853 @@ -13667,13 +14045,13 @@
     11136@@ -13667,13 +14074,13 @@
    1085411137 fi
    1085511138 
    1085611139 fi
    1085711140-echo "$as_me:13670: checking return type of signal handlers" >&5
    10858 +echo "$as_me:14048: checking return type of signal handlers" >&5
     11141+echo "$as_me:14077: checking return type of signal handlers" >&5
    1085911142 echo $ECHO_N "checking return type of signal handlers... $ECHO_C" >&6
    1086011143 if test "${ac_cv_type_signal+set}" = set; then
     
    1086311146   cat >conftest.$ac_ext <<_ACEOF
    1086411147-#line 13676 "configure"
    10865 +#line 14054 "configure"
     11148+#line 14083 "configure"
    1086611149 #include "confdefs.h"
    1086711150 #include <sys/types.h>
    1086811151 #include <signal.h>
    10869 @@ -13695,16 +14073,16 @@
     11152@@ -13695,16 +14102,16 @@
    1087011153 }
    1087111154 _ACEOF
    1087211155 rm -f conftest.$ac_objext
    1087311156-if { (eval echo "$as_me:13698: \"$ac_compile\"") >&5
    10874 +if { (eval echo "$as_me:14076: \"$ac_compile\"") >&5
     11157+if { (eval echo "$as_me:14105: \"$ac_compile\"") >&5
    1087511158   (eval $ac_compile) 2>&5
    1087611159   ac_status=$?
    1087711160-  echo "$as_me:13701: \$? = $ac_status" >&5
    10878 +  echo "$as_me:14079: \$? = $ac_status" >&5
     11161+  echo "$as_me:14108: \$? = $ac_status" >&5
    1087911162   (exit $ac_status); } &&
    1088011163          { ac_try='test -s conftest.$ac_objext'
    1088111164-  { (eval echo "$as_me:13704: \"$ac_try\"") >&5
    10882 +  { (eval echo "$as_me:14082: \"$ac_try\"") >&5
     11165+  { (eval echo "$as_me:14111: \"$ac_try\"") >&5
    1088311166   (eval $ac_try) 2>&5
    1088411167   ac_status=$?
    1088511168-  echo "$as_me:13707: \$? = $ac_status" >&5
    10886 +  echo "$as_me:14085: \$? = $ac_status" >&5
     11169+  echo "$as_me:14114: \$? = $ac_status" >&5
    1088711170   (exit $ac_status); }; }; then
    1088811171   ac_cv_type_signal=void
    1088911172 else
    10890 @@ -13714,21 +14092,21 @@
     11173@@ -13714,21 +14121,21 @@
    1089111174 fi
    1089211175 rm -f conftest.$ac_objext conftest.$ac_ext
    1089311176 fi
    1089411177-echo "$as_me:13717: result: $ac_cv_type_signal" >&5
    10895 +echo "$as_me:14095: result: $ac_cv_type_signal" >&5
     11178+echo "$as_me:14124: result: $ac_cv_type_signal" >&5
    1089611179 echo "${ECHO_T}$ac_cv_type_signal" >&6
    1089711180 
     
    1090111184 
    1090211185-echo "$as_me:13724: checking for type sigaction_t" >&5
    10903 +echo "$as_me:14102: checking for type sigaction_t" >&5
     11186+echo "$as_me:14131: checking for type sigaction_t" >&5
    1090411187 echo $ECHO_N "checking for type sigaction_t... $ECHO_C" >&6
    1090511188 if test "${cf_cv_type_sigaction+set}" = set; then
     
    1090911192        cat >conftest.$ac_ext <<_ACEOF
    1091011193-#line 13731 "configure"
    10911 +#line 14109 "configure"
     11194+#line 14138 "configure"
    1091211195 #include "confdefs.h"
    1091311196 
    1091411197 #include <signal.h>
    10915 @@ -13741,16 +14119,16 @@
     11198@@ -13741,16 +14148,16 @@
    1091611199 }
    1091711200 _ACEOF
    1091811201 rm -f conftest.$ac_objext
    1091911202-if { (eval echo "$as_me:13744: \"$ac_compile\"") >&5
    10920 +if { (eval echo "$as_me:14122: \"$ac_compile\"") >&5
     11203+if { (eval echo "$as_me:14151: \"$ac_compile\"") >&5
    1092111204   (eval $ac_compile) 2>&5
    1092211205   ac_status=$?
    1092311206-  echo "$as_me:13747: \$? = $ac_status" >&5
    10924 +  echo "$as_me:14125: \$? = $ac_status" >&5
     11207+  echo "$as_me:14154: \$? = $ac_status" >&5
    1092511208   (exit $ac_status); } &&
    1092611209          { ac_try='test -s conftest.$ac_objext'
    1092711210-  { (eval echo "$as_me:13750: \"$ac_try\"") >&5
    10928 +  { (eval echo "$as_me:14128: \"$ac_try\"") >&5
     11211+  { (eval echo "$as_me:14157: \"$ac_try\"") >&5
    1092911212   (eval $ac_try) 2>&5
    1093011213   ac_status=$?
    1093111214-  echo "$as_me:13753: \$? = $ac_status" >&5
    10932 +  echo "$as_me:14131: \$? = $ac_status" >&5
     11215+  echo "$as_me:14160: \$? = $ac_status" >&5
    1093311216   (exit $ac_status); }; }; then
    1093411217   cf_cv_type_sigaction=yes
    1093511218 else
    10936 @@ -13761,13 +14139,13 @@
     11219@@ -13761,13 +14168,13 @@
    1093711220 rm -f conftest.$ac_objext conftest.$ac_ext
    1093811221 fi
    1093911222 
    1094011223-echo "$as_me:13764: result: $cf_cv_type_sigaction" >&5
    10941 +echo "$as_me:14142: result: $cf_cv_type_sigaction" >&5
     11224+echo "$as_me:14171: result: $cf_cv_type_sigaction" >&5
    1094211225 echo "${ECHO_T}$cf_cv_type_sigaction" >&6
    1094311226 test "$cf_cv_type_sigaction" = yes && cat >>confdefs.h <<\EOF
     
    1094611229 
    1094711230-echo "$as_me:13770: checking declaration of size-change" >&5
    10948 +echo "$as_me:14148: checking declaration of size-change" >&5
     11231+echo "$as_me:14177: checking declaration of size-change" >&5
    1094911232 echo $ECHO_N "checking declaration of size-change... $ECHO_C" >&6
    1095011233 if test "${cf_cv_sizechange+set}" = set; then
    1095111234   echo $ECHO_N "(cached) $ECHO_C" >&6
    10952 @@ -13782,7 +14160,7 @@
     11235@@ -13782,7 +14189,7 @@
    1095311236     CPPFLAGS="$cf_save_CPPFLAGS"
    1095411237     test -n "$cf_opts" && CPPFLAGS="$CPPFLAGS -D$cf_opts"
    1095511238     cat >conftest.$ac_ext <<_ACEOF
    1095611239-#line 13785 "configure"
    10957 +#line 14163 "configure"
     11240+#line 14192 "configure"
    1095811241 #include "confdefs.h"
    1095911242 #include <sys/types.h>
    1096011243 #ifdef HAVE_TERMIOS_H
    10961 @@ -13826,16 +14204,16 @@
     11244@@ -13826,16 +14233,16 @@
    1096211245 }
    1096311246 _ACEOF
    1096411247 rm -f conftest.$ac_objext
    1096511248-if { (eval echo "$as_me:13829: \"$ac_compile\"") >&5
    10966 +if { (eval echo "$as_me:14207: \"$ac_compile\"") >&5
     11249+if { (eval echo "$as_me:14236: \"$ac_compile\"") >&5
    1096711250   (eval $ac_compile) 2>&5
    1096811251   ac_status=$?
    1096911252-  echo "$as_me:13832: \$? = $ac_status" >&5
    10970 +  echo "$as_me:14210: \$? = $ac_status" >&5
     11253+  echo "$as_me:14239: \$? = $ac_status" >&5
    1097111254   (exit $ac_status); } &&
    1097211255          { ac_try='test -s conftest.$ac_objext'
    1097311256-  { (eval echo "$as_me:13835: \"$ac_try\"") >&5
    10974 +  { (eval echo "$as_me:14213: \"$ac_try\"") >&5
     11257+  { (eval echo "$as_me:14242: \"$ac_try\"") >&5
    1097511258   (eval $ac_try) 2>&5
    1097611259   ac_status=$?
    1097711260-  echo "$as_me:13838: \$? = $ac_status" >&5
    10978 +  echo "$as_me:14216: \$? = $ac_status" >&5
     11261+  echo "$as_me:14245: \$? = $ac_status" >&5
    1097911262   (exit $ac_status); }; }; then
    1098011263   cf_cv_sizechange=yes
    1098111264 else
    10982 @@ -13854,7 +14232,7 @@
     11265@@ -13854,7 +14261,7 @@
    1098311266 done
    1098411267 
    1098511268 fi
    1098611269-echo "$as_me:13857: result: $cf_cv_sizechange" >&5
    10987 +echo "$as_me:14235: result: $cf_cv_sizechange" >&5
     11270+echo "$as_me:14264: result: $cf_cv_sizechange" >&5
    1098811271 echo "${ECHO_T}$cf_cv_sizechange" >&6
    1098911272 if test "$cf_cv_sizechange" != no ; then
    1099011273        cat >>confdefs.h <<\EOF
    10991 @@ -13871,13 +14249,13 @@
     11274@@ -13871,13 +14278,13 @@
    1099211275        esac
    1099311276 fi
    1099411277 
    1099511278-echo "$as_me:13874: checking for memmove" >&5
    10996 +echo "$as_me:14252: checking for memmove" >&5
     11279+echo "$as_me:14281: checking for memmove" >&5
    1099711280 echo $ECHO_N "checking for memmove... $ECHO_C" >&6
    1099811281 if test "${ac_cv_func_memmove+set}" = set; then
     
    1100111284   cat >conftest.$ac_ext <<_ACEOF
    1100211285-#line 13880 "configure"
    11003 +#line 14258 "configure"
     11286+#line 14287 "configure"
    1100411287 #include "confdefs.h"
    1100511288 /* System header to define __stub macros and hopefully few prototypes,
    1100611289     which can conflict with char memmove (); below.  */
    11007 @@ -13908,16 +14286,16 @@
     11290@@ -13908,16 +14315,16 @@
    1100811291 }
    1100911292 _ACEOF
    1101011293 rm -f conftest.$ac_objext conftest$ac_exeext
    1101111294-if { (eval echo "$as_me:13911: \"$ac_link\"") >&5
    11012 +if { (eval echo "$as_me:14289: \"$ac_link\"") >&5
     11295+if { (eval echo "$as_me:14318: \"$ac_link\"") >&5
    1101311296   (eval $ac_link) 2>&5
    1101411297   ac_status=$?
    1101511298-  echo "$as_me:13914: \$? = $ac_status" >&5
    11016 +  echo "$as_me:14292: \$? = $ac_status" >&5
     11299+  echo "$as_me:14321: \$? = $ac_status" >&5
    1101711300   (exit $ac_status); } &&
    1101811301          { ac_try='test -s conftest$ac_exeext'
    1101911302-  { (eval echo "$as_me:13917: \"$ac_try\"") >&5
    11020 +  { (eval echo "$as_me:14295: \"$ac_try\"") >&5
     11303+  { (eval echo "$as_me:14324: \"$ac_try\"") >&5
    1102111304   (eval $ac_try) 2>&5
    1102211305   ac_status=$?
    1102311306-  echo "$as_me:13920: \$? = $ac_status" >&5
    11024 +  echo "$as_me:14298: \$? = $ac_status" >&5
     11307+  echo "$as_me:14327: \$? = $ac_status" >&5
    1102511308   (exit $ac_status); }; }; then
    1102611309   ac_cv_func_memmove=yes
    1102711310 else
    11028 @@ -13927,19 +14305,19 @@
     11311@@ -13927,19 +14334,19 @@
    1102911312 fi
    1103011313 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    1103111314 fi
    1103211315-echo "$as_me:13930: result: $ac_cv_func_memmove" >&5
    11033 +echo "$as_me:14308: result: $ac_cv_func_memmove" >&5
     11316+echo "$as_me:14337: result: $ac_cv_func_memmove" >&5
    1103411317 echo "${ECHO_T}$ac_cv_func_memmove" >&6
    1103511318 if test $ac_cv_func_memmove = yes; then
     
    1103811321 
    1103911322-echo "$as_me:13936: checking for bcopy" >&5
    11040 +echo "$as_me:14314: checking for bcopy" >&5
     11323+echo "$as_me:14343: checking for bcopy" >&5
    1104111324 echo $ECHO_N "checking for bcopy... $ECHO_C" >&6
    1104211325 if test "${ac_cv_func_bcopy+set}" = set; then
     
    1104511328   cat >conftest.$ac_ext <<_ACEOF
    1104611329-#line 13942 "configure"
    11047 +#line 14320 "configure"
     11330+#line 14349 "configure"
    1104811331 #include "confdefs.h"
    1104911332 /* System header to define __stub macros and hopefully few prototypes,
    1105011333     which can conflict with char bcopy (); below.  */
    11051 @@ -13970,16 +14348,16 @@
     11334@@ -13970,16 +14377,16 @@
    1105211335 }
    1105311336 _ACEOF
    1105411337 rm -f conftest.$ac_objext conftest$ac_exeext
    1105511338-if { (eval echo "$as_me:13973: \"$ac_link\"") >&5
    11056 +if { (eval echo "$as_me:14351: \"$ac_link\"") >&5
     11339+if { (eval echo "$as_me:14380: \"$ac_link\"") >&5
    1105711340   (eval $ac_link) 2>&5
    1105811341   ac_status=$?
    1105911342-  echo "$as_me:13976: \$? = $ac_status" >&5
    11060 +  echo "$as_me:14354: \$? = $ac_status" >&5
     11343+  echo "$as_me:14383: \$? = $ac_status" >&5
    1106111344   (exit $ac_status); } &&
    1106211345          { ac_try='test -s conftest$ac_exeext'
    1106311346-  { (eval echo "$as_me:13979: \"$ac_try\"") >&5
    11064 +  { (eval echo "$as_me:14357: \"$ac_try\"") >&5
     11347+  { (eval echo "$as_me:14386: \"$ac_try\"") >&5
    1106511348   (eval $ac_try) 2>&5
    1106611349   ac_status=$?
    1106711350-  echo "$as_me:13982: \$? = $ac_status" >&5
    11068 +  echo "$as_me:14360: \$? = $ac_status" >&5
     11351+  echo "$as_me:14389: \$? = $ac_status" >&5
    1106911352   (exit $ac_status); }; }; then
    1107011353   ac_cv_func_bcopy=yes
    1107111354 else
    11072 @@ -13989,11 +14367,11 @@
     11355@@ -13989,11 +14396,11 @@
    1107311356 fi
    1107411357 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    1107511358 fi
    1107611359-echo "$as_me:13992: result: $ac_cv_func_bcopy" >&5
    11077 +echo "$as_me:14370: result: $ac_cv_func_bcopy" >&5
     11360+echo "$as_me:14399: result: $ac_cv_func_bcopy" >&5
    1107811361 echo "${ECHO_T}$ac_cv_func_bcopy" >&6
    1107911362 if test $ac_cv_func_bcopy = yes; then
    1108011363 
    1108111364-       echo "$as_me:13996: checking if bcopy does overlapping moves" >&5
    11082 +       echo "$as_me:14374: checking if bcopy does overlapping moves" >&5
     11365+       echo "$as_me:14403: checking if bcopy does overlapping moves" >&5
    1108311366 echo $ECHO_N "checking if bcopy does overlapping moves... $ECHO_C" >&6
    1108411367 if test "${cf_cv_good_bcopy+set}" = set; then
    1108511368   echo $ECHO_N "(cached) $ECHO_C" >&6
    11086 @@ -14003,7 +14381,7 @@
     11369@@ -14003,7 +14410,7 @@
    1108711370   cf_cv_good_bcopy=unknown
    1108811371 else
    1108911372   cat >conftest.$ac_ext <<_ACEOF
    1109011373-#line 14006 "configure"
    11091 +#line 14384 "configure"
     11374+#line 14413 "configure"
    1109211375 #include "confdefs.h"
    1109311376 
    1109411377 int main() {
    11095 @@ -14017,15 +14395,15 @@
     11378@@ -14017,15 +14424,15 @@
    1109611379 
    1109711380 _ACEOF
    1109811381 rm -f conftest$ac_exeext
    1109911382-if { (eval echo "$as_me:14020: \"$ac_link\"") >&5
    11100 +if { (eval echo "$as_me:14398: \"$ac_link\"") >&5
     11383+if { (eval echo "$as_me:14427: \"$ac_link\"") >&5
    1110111384   (eval $ac_link) 2>&5
    1110211385   ac_status=$?
    1110311386-  echo "$as_me:14023: \$? = $ac_status" >&5
    11104 +  echo "$as_me:14401: \$? = $ac_status" >&5
     11387+  echo "$as_me:14430: \$? = $ac_status" >&5
    1110511388   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    1110611389-  { (eval echo "$as_me:14025: \"$ac_try\"") >&5
    11107 +  { (eval echo "$as_me:14403: \"$ac_try\"") >&5
     11390+  { (eval echo "$as_me:14432: \"$ac_try\"") >&5
    1110811391   (eval $ac_try) 2>&5
    1110911392   ac_status=$?
    1111011393-  echo "$as_me:14028: \$? = $ac_status" >&5
    11111 +  echo "$as_me:14406: \$? = $ac_status" >&5
     11394+  echo "$as_me:14435: \$? = $ac_status" >&5
    1111211395   (exit $ac_status); }; }; then
    1111311396   cf_cv_good_bcopy=yes
    1111411397 else
    11115 @@ -14038,7 +14416,7 @@
     11398@@ -14038,7 +14445,7 @@
    1111611399 fi
    1111711400 
    1111811401 fi
    1111911402-echo "$as_me:14041: result: $cf_cv_good_bcopy" >&5
    11120 +echo "$as_me:14419: result: $cf_cv_good_bcopy" >&5
     11403+echo "$as_me:14448: result: $cf_cv_good_bcopy" >&5
    1112111404 echo "${ECHO_T}$cf_cv_good_bcopy" >&6
    1112211405 
    1112311406 else
    11124 @@ -14059,7 +14437,7 @@
     11407@@ -14059,7 +14466,7 @@
    1112511408 
    1112611409 fi
    1112711410 
    1112811411-echo "$as_me:14062: checking if poll really works" >&5
    11129 +echo "$as_me:14440: checking if poll really works" >&5
     11412+echo "$as_me:14469: checking if poll really works" >&5
    1113011413 echo $ECHO_N "checking if poll really works... $ECHO_C" >&6
    1113111414 if test "${cf_cv_working_poll+set}" = set; then
    1113211415   echo $ECHO_N "(cached) $ECHO_C" >&6
    11133 @@ -14069,7 +14447,7 @@
     11416@@ -14069,7 +14476,7 @@
    1113411417   cf_cv_working_poll=unknown
    1113511418 else
    1113611419   cat >conftest.$ac_ext <<_ACEOF
    1113711420-#line 14072 "configure"
    11138 +#line 14450 "configure"
     11421+#line 14479 "configure"
    1113911422 #include "confdefs.h"
    1114011423 
    1114111424 #include <stdio.h>
    11142 @@ -14090,15 +14468,15 @@
     11425@@ -14090,15 +14497,15 @@
    1114311426 }
    1114411427 _ACEOF
    1114511428 rm -f conftest$ac_exeext
    1114611429-if { (eval echo "$as_me:14093: \"$ac_link\"") >&5
    11147 +if { (eval echo "$as_me:14471: \"$ac_link\"") >&5
     11430+if { (eval echo "$as_me:14500: \"$ac_link\"") >&5
    1114811431   (eval $ac_link) 2>&5
    1114911432   ac_status=$?
    1115011433-  echo "$as_me:14096: \$? = $ac_status" >&5
    11151 +  echo "$as_me:14474: \$? = $ac_status" >&5
     11434+  echo "$as_me:14503: \$? = $ac_status" >&5
    1115211435   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    1115311436-  { (eval echo "$as_me:14098: \"$ac_try\"") >&5
    11154 +  { (eval echo "$as_me:14476: \"$ac_try\"") >&5
     11437+  { (eval echo "$as_me:14505: \"$ac_try\"") >&5
    1115511438   (eval $ac_try) 2>&5
    1115611439   ac_status=$?
    1115711440-  echo "$as_me:14101: \$? = $ac_status" >&5
    11158 +  echo "$as_me:14479: \$? = $ac_status" >&5
     11441+  echo "$as_me:14508: \$? = $ac_status" >&5
    1115911442   (exit $ac_status); }; }; then
    1116011443   cf_cv_working_poll=yes
    1116111444 else
    11162 @@ -14110,7 +14488,7 @@
     11445@@ -14110,7 +14517,7 @@
    1116311446 rm -f core core.* *.core conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
    1116411447 fi
    1116511448 fi
    1116611449-echo "$as_me:14113: result: $cf_cv_working_poll" >&5
    11167 +echo "$as_me:14491: result: $cf_cv_working_poll" >&5
     11450+echo "$as_me:14520: result: $cf_cv_working_poll" >&5
    1116811451 echo "${ECHO_T}$cf_cv_working_poll" >&6
    1116911452 test "$cf_cv_working_poll" = "yes" && cat >>confdefs.h <<\EOF
    1117011453 #define HAVE_WORKING_POLL 1
    11171 @@ -14118,7 +14496,7 @@
     11454@@ -14118,7 +14525,7 @@
    1117211455 
    1117311456 # special check for test/ditto.c
    1117411457 
    1117511458-echo "$as_me:14121: checking for openpty in -lutil" >&5
    11176 +echo "$as_me:14499: checking for openpty in -lutil" >&5
     11459+echo "$as_me:14528: checking for openpty in -lutil" >&5
    1117711460 echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6
    1117811461 if test "${ac_cv_lib_util_openpty+set}" = set; then
    1117911462   echo $ECHO_N "(cached) $ECHO_C" >&6
    11180 @@ -14126,7 +14504,7 @@
     11463@@ -14126,7 +14533,7 @@
    1118111464   ac_check_lib_save_LIBS=$LIBS
    1118211465 LIBS="-lutil  $LIBS"
    1118311466 cat >conftest.$ac_ext <<_ACEOF
    1118411467-#line 14129 "configure"
    11185 +#line 14507 "configure"
     11468+#line 14536 "configure"
    1118611469 #include "confdefs.h"
    1118711470 
    1118811471 /* Override any gcc2 internal prototype to avoid an error.  */
    11189 @@ -14145,16 +14523,16 @@
     11472@@ -14145,16 +14552,16 @@
    1119011473 }
    1119111474 _ACEOF
    1119211475 rm -f conftest.$ac_objext conftest$ac_exeext
    1119311476-if { (eval echo "$as_me:14148: \"$ac_link\"") >&5
    11194 +if { (eval echo "$as_me:14526: \"$ac_link\"") >&5
     11477+if { (eval echo "$as_me:14555: \"$ac_link\"") >&5
    1119511478   (eval $ac_link) 2>&5
    1119611479   ac_status=$?
    1119711480-  echo "$as_me:14151: \$? = $ac_status" >&5
    11198 +  echo "$as_me:14529: \$? = $ac_status" >&5
     11481+  echo "$as_me:14558: \$? = $ac_status" >&5
    1119911482   (exit $ac_status); } &&
    1120011483          { ac_try='test -s conftest$ac_exeext'
    1120111484-  { (eval echo "$as_me:14154: \"$ac_try\"") >&5
    11202 +  { (eval echo "$as_me:14532: \"$ac_try\"") >&5
     11485+  { (eval echo "$as_me:14561: \"$ac_try\"") >&5
    1120311486   (eval $ac_try) 2>&5
    1120411487   ac_status=$?
    1120511488-  echo "$as_me:14157: \$? = $ac_status" >&5
    11206 +  echo "$as_me:14535: \$? = $ac_status" >&5
     11489+  echo "$as_me:14564: \$? = $ac_status" >&5
    1120711490   (exit $ac_status); }; }; then
    1120811491   ac_cv_lib_util_openpty=yes
    1120911492 else
    11210 @@ -14165,7 +14543,7 @@
     11493@@ -14165,7 +14572,7 @@
    1121111494 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    1121211495 LIBS=$ac_check_lib_save_LIBS
    1121311496 fi
    1121411497-echo "$as_me:14168: result: $ac_cv_lib_util_openpty" >&5
    11215 +echo "$as_me:14546: result: $ac_cv_lib_util_openpty" >&5
     11498+echo "$as_me:14575: result: $ac_cv_lib_util_openpty" >&5
    1121611499 echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6
    1121711500 if test $ac_cv_lib_util_openpty = yes; then
    1121811501   cf_cv_lib_util=yes
    11219 @@ -14173,7 +14551,7 @@
     11502@@ -14173,7 +14580,7 @@
    1122011503   cf_cv_lib_util=no
    1122111504 fi
    1122211505 
    1122311506-echo "$as_me:14176: checking for openpty header" >&5
    11224 +echo "$as_me:14554: checking for openpty header" >&5
     11507+echo "$as_me:14583: checking for openpty header" >&5
    1122511508 echo $ECHO_N "checking for openpty header... $ECHO_C" >&6
    1122611509 if test "${cf_cv_func_openpty+set}" = set; then
    1122711510   echo $ECHO_N "(cached) $ECHO_C" >&6
    11228 @@ -14184,7 +14562,7 @@
     11511@@ -14184,7 +14591,7 @@
    1122911512     for cf_header in pty.h libutil.h util.h
    1123011513     do
    1123111514     cat >conftest.$ac_ext <<_ACEOF
    1123211515-#line 14187 "configure"
    11233 +#line 14565 "configure"
     11516+#line 14594 "configure"
    1123411517 #include "confdefs.h"
    1123511518 
    1123611519 #include <$cf_header>
    11237 @@ -14201,16 +14579,16 @@
     11520@@ -14201,16 +14608,16 @@
    1123811521 }
    1123911522 _ACEOF
    1124011523 rm -f conftest.$ac_objext conftest$ac_exeext
    1124111524-if { (eval echo "$as_me:14204: \"$ac_link\"") >&5
    11242 +if { (eval echo "$as_me:14582: \"$ac_link\"") >&5
     11525+if { (eval echo "$as_me:14611: \"$ac_link\"") >&5
    1124311526   (eval $ac_link) 2>&5
    1124411527   ac_status=$?
    1124511528-  echo "$as_me:14207: \$? = $ac_status" >&5
    11246 +  echo "$as_me:14585: \$? = $ac_status" >&5
     11529+  echo "$as_me:14614: \$? = $ac_status" >&5
    1124711530   (exit $ac_status); } &&
    1124811531          { ac_try='test -s conftest$ac_exeext'
    1124911532-  { (eval echo "$as_me:14210: \"$ac_try\"") >&5
    11250 +  { (eval echo "$as_me:14588: \"$ac_try\"") >&5
     11533+  { (eval echo "$as_me:14617: \"$ac_try\"") >&5
    1125111534   (eval $ac_try) 2>&5
    1125211535   ac_status=$?
    1125311536-  echo "$as_me:14213: \$? = $ac_status" >&5
    11254 +  echo "$as_me:14591: \$? = $ac_status" >&5
     11537+  echo "$as_me:14620: \$? = $ac_status" >&5
    1125511538   (exit $ac_status); }; }; then
    1125611539 
    1125711540         cf_cv_func_openpty=$cf_header
    11258 @@ -14228,7 +14606,7 @@
     11541@@ -14228,7 +14635,7 @@
    1125911542     LIBS="$cf_save_LIBS"
    1126011543 
    1126111544 fi
    1126211545-echo "$as_me:14231: result: $cf_cv_func_openpty" >&5
    11263 +echo "$as_me:14609: result: $cf_cv_func_openpty" >&5
     11546+echo "$as_me:14638: result: $cf_cv_func_openpty" >&5
    1126411547 echo "${ECHO_T}$cf_cv_func_openpty" >&6
    1126511548 
    1126611549 if test "$cf_cv_func_openpty" != no ; then
    11267 @@ -14274,13 +14652,13 @@
     11550@@ -14274,13 +14681,13 @@
    1126811551                fi
    1126911552 
     
    1127711560                          cat >conftest.$ac_ext <<_ACEOF
    1127811561-#line 14283 "configure"
    11279 +#line 14661 "configure"
     11562+#line 14690 "configure"
    1128011563 #include "confdefs.h"
    1128111564 #include <stdio.h>
    1128211565 int
    11283 @@ -14292,16 +14670,16 @@
     11566@@ -14292,16 +14699,16 @@
    1128411567 }
    1128511568 _ACEOF
    1128611569 rm -f conftest.$ac_objext
    1128711570-if { (eval echo "$as_me:14295: \"$ac_compile\"") >&5
    11288 +if { (eval echo "$as_me:14673: \"$ac_compile\"") >&5
     11571+if { (eval echo "$as_me:14702: \"$ac_compile\"") >&5
    1128911572   (eval $ac_compile) 2>&5
    1129011573   ac_status=$?
    1129111574-  echo "$as_me:14298: \$? = $ac_status" >&5
    11292 +  echo "$as_me:14676: \$? = $ac_status" >&5
     11575+  echo "$as_me:14705: \$? = $ac_status" >&5
    1129311576   (exit $ac_status); } &&
    1129411577          { ac_try='test -s conftest.$ac_objext'
    1129511578-  { (eval echo "$as_me:14301: \"$ac_try\"") >&5
    11296 +  { (eval echo "$as_me:14679: \"$ac_try\"") >&5
     11579+  { (eval echo "$as_me:14708: \"$ac_try\"") >&5
    1129711580   (eval $ac_try) 2>&5
    1129811581   ac_status=$?
    1129911582-  echo "$as_me:14304: \$? = $ac_status" >&5
    11300 +  echo "$as_me:14682: \$? = $ac_status" >&5
     11583+  echo "$as_me:14711: \$? = $ac_status" >&5
    1130111584   (exit $ac_status); }; }; then
    1130211585   :
    1130311586 else
    11304 @@ -14318,13 +14696,13 @@
     11587@@ -14318,13 +14725,13 @@
    1130511588                if test "$cf_have_incdir" = no ; then
    1130611589                  test -n "$verbose" && echo "  adding $cf_add_incdir to include-path" 1>&6
    1130711590 
    1130811591-echo "${as_me-configure}:14321: testing adding $cf_add_incdir to include-path ..." 1>&5
    11309 +echo "${as_me-configure}:14699: testing adding $cf_add_incdir to include-path ..." 1>&5
     11592+echo "${as_me-configure}:14728: testing adding $cf_add_incdir to include-path ..." 1>&5
    1131011593 
    1131111594-                 CPPFLAGS="-I$cf_add_incdir $CPPFLAGS"
     
    1132111604                  break
    1132211605                fi
    11323 @@ -14352,7 +14730,7 @@
     11606@@ -14352,7 +14759,7 @@
    1132411607       if test "$cf_have_libdir" = no ; then
    1132511608         test -n "$verbose" && echo "   adding $cf_add_libdir to library-path" 1>&6
    1132611609 
    1132711610-echo "${as_me-configure}:14355: testing adding $cf_add_libdir to library-path ..." 1>&5
    11328 +echo "${as_me-configure}:14733: testing adding $cf_add_libdir to library-path ..." 1>&5
     11611+echo "${as_me-configure}:14762: testing adding $cf_add_libdir to library-path ..." 1>&5
    1132911612 
    1133011613         LDFLAGS="-L$cf_add_libdir $LDFLAGS"
    1133111614       fi
    11332 @@ -14363,23 +14741,23 @@
     11615@@ -14363,23 +14770,23 @@
    1133311616     fi
    1133411617 esac
    1133511618 
    1133611619-echo "$as_me:14366: checking for db.h" >&5
    11337 +echo "$as_me:14744: checking for db.h" >&5
     11620+echo "$as_me:14773: checking for db.h" >&5
    1133811621 echo $ECHO_N "checking for db.h... $ECHO_C" >&6
    1133911622 if test "${ac_cv_header_db_h+set}" = set; then
     
    1134211625   cat >conftest.$ac_ext <<_ACEOF
    1134311626-#line 14372 "configure"
    11344 +#line 14750 "configure"
     11627+#line 14779 "configure"
    1134511628 #include "confdefs.h"
    1134611629 #include <db.h>
    1134711630 _ACEOF
    1134811631-if { (eval echo "$as_me:14376: \"$ac_cpp conftest.$ac_ext\"") >&5
    11349 +if { (eval echo "$as_me:14754: \"$ac_cpp conftest.$ac_ext\"") >&5
     11632+if { (eval echo "$as_me:14783: \"$ac_cpp conftest.$ac_ext\"") >&5
    1135011633   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    1135111634   ac_status=$?
     
    1135411637   cat conftest.err >&5
    1135511638-  echo "$as_me:14382: \$? = $ac_status" >&5
    11356 +  echo "$as_me:14760: \$? = $ac_status" >&5
     11639+  echo "$as_me:14789: \$? = $ac_status" >&5
    1135711640   (exit $ac_status); } >/dev/null; then
    1135811641   if test -s conftest.err; then
    1135911642     ac_cpp_err=$ac_c_preproc_warn_flag
    11360 @@ -14398,11 +14776,11 @@
     11643@@ -14398,11 +14805,11 @@
    1136111644 fi
    1136211645 rm -f conftest.err conftest.$ac_ext
    1136311646 fi
    1136411647-echo "$as_me:14401: result: $ac_cv_header_db_h" >&5
    11365 +echo "$as_me:14779: result: $ac_cv_header_db_h" >&5
     11648+echo "$as_me:14808: result: $ac_cv_header_db_h" >&5
    1136611649 echo "${ECHO_T}$ac_cv_header_db_h" >&6
    1136711650 if test $ac_cv_header_db_h = yes; then
    1136811651 
    1136911652-echo "$as_me:14405: checking for version of db" >&5
    11370 +echo "$as_me:14783: checking for version of db" >&5
     11653+echo "$as_me:14812: checking for version of db" >&5
    1137111654 echo $ECHO_N "checking for version of db... $ECHO_C" >&6
    1137211655 if test "${cf_cv_hashed_db_version+set}" = set; then
    1137311656   echo $ECHO_N "(cached) $ECHO_C" >&6
    11374 @@ -14413,10 +14791,10 @@
     11657@@ -14413,10 +14820,10 @@
    1137511658 for cf_db_version in 1 2 3 4 5
    1137611659 do
    1137711660 
    1137811661-echo "${as_me-configure}:14416: testing checking for db version $cf_db_version ..." 1>&5
    11379 +echo "${as_me-configure}:14794: testing checking for db version $cf_db_version ..." 1>&5
     11662+echo "${as_me-configure}:14823: testing checking for db version $cf_db_version ..." 1>&5
    1138011663 
    1138111664        cat >conftest.$ac_ext <<_ACEOF
    1138211665-#line 14419 "configure"
    11383 +#line 14797 "configure"
     11666+#line 14826 "configure"
    1138411667 #include "confdefs.h"
    1138511668 
    1138611669 $ac_includes_default
    11387 @@ -14446,16 +14824,16 @@
     11670@@ -14446,16 +14853,16 @@
    1138811671 }
    1138911672 _ACEOF
    1139011673 rm -f conftest.$ac_objext
    1139111674-if { (eval echo "$as_me:14449: \"$ac_compile\"") >&5
    11392 +if { (eval echo "$as_me:14827: \"$ac_compile\"") >&5
     11675+if { (eval echo "$as_me:14856: \"$ac_compile\"") >&5
    1139311676   (eval $ac_compile) 2>&5
    1139411677   ac_status=$?
    1139511678-  echo "$as_me:14452: \$? = $ac_status" >&5
    11396 +  echo "$as_me:14830: \$? = $ac_status" >&5
     11679+  echo "$as_me:14859: \$? = $ac_status" >&5
    1139711680   (exit $ac_status); } &&
    1139811681          { ac_try='test -s conftest.$ac_objext'
    1139911682-  { (eval echo "$as_me:14455: \"$ac_try\"") >&5
    11400 +  { (eval echo "$as_me:14833: \"$ac_try\"") >&5
     11683+  { (eval echo "$as_me:14862: \"$ac_try\"") >&5
    1140111684   (eval $ac_try) 2>&5
    1140211685   ac_status=$?
    1140311686-  echo "$as_me:14458: \$? = $ac_status" >&5
    11404 +  echo "$as_me:14836: \$? = $ac_status" >&5
     11687+  echo "$as_me:14865: \$? = $ac_status" >&5
    1140511688   (exit $ac_status); }; }; then
    1140611689 
    1140711690        cf_cv_hashed_db_version=$cf_db_version
    11408 @@ -14469,16 +14847,16 @@
     11691@@ -14469,16 +14876,16 @@
    1140911692 done
    1141011693 
    1141111694 fi
    1141211695-echo "$as_me:14472: result: $cf_cv_hashed_db_version" >&5
    11413 +echo "$as_me:14850: result: $cf_cv_hashed_db_version" >&5
     11696+echo "$as_me:14879: result: $cf_cv_hashed_db_version" >&5
    1141411697 echo "${ECHO_T}$cf_cv_hashed_db_version" >&6
    1141511698 
    1141611699 if test "$cf_cv_hashed_db_version" = unknown ; then
    1141711700-       { { echo "$as_me:14476: error: Cannot determine version of db" >&5
    11418 +       { { echo "$as_me:14854: error: Cannot determine version of db" >&5
     11701+       { { echo "$as_me:14883: error: Cannot determine version of db" >&5
    1141911702 echo "$as_me: error: Cannot determine version of db" >&2;}
    1142011703    { (exit 1); exit 1; }; }
     
    1142211705 
    1142311706-echo "$as_me:14481: checking for db libraries" >&5
    11424 +echo "$as_me:14859: checking for db libraries" >&5
     11707+echo "$as_me:14888: checking for db libraries" >&5
    1142511708 echo $ECHO_N "checking for db libraries... $ECHO_C" >&6
    1142611709 if test "${cf_cv_hashed_db_libs+set}" = set; then
    1142711710   echo $ECHO_N "(cached) $ECHO_C" >&6
    11428 @@ -14492,10 +14870,10 @@
     11711@@ -14492,10 +14899,10 @@
    1142911712                LIBS="-l$cf_db_libs $LIBS"
    1143011713        fi
    1143111714 
    1143211715-echo "${as_me-configure}:14495: testing checking for library "$cf_db_libs" ..." 1>&5
    11433 +echo "${as_me-configure}:14873: testing checking for library "$cf_db_libs" ..." 1>&5
     11716+echo "${as_me-configure}:14902: testing checking for library "$cf_db_libs" ..." 1>&5
    1143411717 
    1143511718        cat >conftest.$ac_ext <<_ACEOF
    1143611719-#line 14498 "configure"
    11437 +#line 14876 "configure"
     11720+#line 14905 "configure"
    1143811721 #include "confdefs.h"
    1143911722 
    1144011723 $ac_includes_default
    11441 @@ -14550,16 +14928,16 @@
     11724@@ -14550,16 +14957,16 @@
    1144211725 }
    1144311726 _ACEOF
    1144411727 rm -f conftest.$ac_objext conftest$ac_exeext
    1144511728-if { (eval echo "$as_me:14553: \"$ac_link\"") >&5
    11446 +if { (eval echo "$as_me:14931: \"$ac_link\"") >&5
     11729+if { (eval echo "$as_me:14960: \"$ac_link\"") >&5
    1144711730   (eval $ac_link) 2>&5
    1144811731   ac_status=$?
    1144911732-  echo "$as_me:14556: \$? = $ac_status" >&5
    11450 +  echo "$as_me:14934: \$? = $ac_status" >&5
     11733+  echo "$as_me:14963: \$? = $ac_status" >&5
    1145111734   (exit $ac_status); } &&
    1145211735          { ac_try='test -s conftest$ac_exeext'
    1145311736-  { (eval echo "$as_me:14559: \"$ac_try\"") >&5
    11454 +  { (eval echo "$as_me:14937: \"$ac_try\"") >&5
     11737+  { (eval echo "$as_me:14966: \"$ac_try\"") >&5
    1145511738   (eval $ac_try) 2>&5
    1145611739   ac_status=$?
    1145711740-  echo "$as_me:14562: \$? = $ac_status" >&5
    11458 +  echo "$as_me:14940: \$? = $ac_status" >&5
     11741+  echo "$as_me:14969: \$? = $ac_status" >&5
    1145911742   (exit $ac_status); }; }; then
    1146011743 
    1146111744        if test -n "$cf_db_libs" ; then
    11462 @@ -14579,11 +14957,11 @@
     11745@@ -14579,11 +14986,11 @@
    1146311746 done
    1146411747 
    1146511748 fi
    1146611749-echo "$as_me:14582: result: $cf_cv_hashed_db_libs" >&5
    11467 +echo "$as_me:14960: result: $cf_cv_hashed_db_libs" >&5
     11750+echo "$as_me:14989: result: $cf_cv_hashed_db_libs" >&5
    1146811751 echo "${ECHO_T}$cf_cv_hashed_db_libs" >&6
    1146911752 
    1147011753        if test "$cf_cv_hashed_db_libs" = unknown ; then
    1147111754-               { { echo "$as_me:14586: error: Cannot determine library for db" >&5
    11472 +               { { echo "$as_me:14964: error: Cannot determine library for db" >&5
     11755+               { { echo "$as_me:14993: error: Cannot determine library for db" >&5
    1147311756 echo "$as_me: error: Cannot determine library for db" >&2;}
    1147411757    { (exit 1); exit 1; }; }
    1147511758        elif test "$cf_cv_hashed_db_libs" != default ; then
    11476 @@ -14593,7 +14971,7 @@
     11759@@ -14593,7 +15000,7 @@
    1147711760 
    1147811761 else
    1147911762 
    1148011763-       { { echo "$as_me:14596: error: Cannot find db.h" >&5
    11481 +       { { echo "$as_me:14974: error: Cannot find db.h" >&5
     11764+       { { echo "$as_me:15003: error: Cannot find db.h" >&5
    1148211765 echo "$as_me: error: Cannot find db.h" >&2;}
    1148311766    { (exit 1); exit 1; }; }
    1148411767 
    11485 @@ -14608,7 +14986,7 @@
     11768@@ -14608,7 +15015,7 @@
    1148611769 
    1148711770 # Just in case, check if the C compiler has a bool type.
    1148811771 
    1148911772-echo "$as_me:14611: checking if we should include stdbool.h" >&5
    11490 +echo "$as_me:14989: checking if we should include stdbool.h" >&5
     11773+echo "$as_me:15018: checking if we should include stdbool.h" >&5
    1149111774 echo $ECHO_N "checking if we should include stdbool.h... $ECHO_C" >&6
    1149211775 
    1149311776 if test "${cf_cv_header_stdbool_h+set}" = set; then
    11494 @@ -14616,7 +14994,7 @@
     11777@@ -14616,7 +15023,7 @@
    1149511778 else
    1149611779 
    1149711780        cat >conftest.$ac_ext <<_ACEOF
    1149811781-#line 14619 "configure"
    11499 +#line 14997 "configure"
     11782+#line 15026 "configure"
    1150011783 #include "confdefs.h"
    1150111784 
    1150211785 int
    11503 @@ -14628,23 +15006,23 @@
     11786@@ -14628,23 +15035,23 @@
    1150411787 }
    1150511788 _ACEOF
    1150611789 rm -f conftest.$ac_objext
    1150711790-if { (eval echo "$as_me:14631: \"$ac_compile\"") >&5
    11508 +if { (eval echo "$as_me:15009: \"$ac_compile\"") >&5
     11791+if { (eval echo "$as_me:15038: \"$ac_compile\"") >&5
    1150911792   (eval $ac_compile) 2>&5
    1151011793   ac_status=$?
    1151111794-  echo "$as_me:14634: \$? = $ac_status" >&5
    11512 +  echo "$as_me:15012: \$? = $ac_status" >&5
     11795+  echo "$as_me:15041: \$? = $ac_status" >&5
    1151311796   (exit $ac_status); } &&
    1151411797          { ac_try='test -s conftest.$ac_objext'
    1151511798-  { (eval echo "$as_me:14637: \"$ac_try\"") >&5
    11516 +  { (eval echo "$as_me:15015: \"$ac_try\"") >&5
     11799+  { (eval echo "$as_me:15044: \"$ac_try\"") >&5
    1151711800   (eval $ac_try) 2>&5
    1151811801   ac_status=$?
    1151911802-  echo "$as_me:14640: \$? = $ac_status" >&5
    11520 +  echo "$as_me:15018: \$? = $ac_status" >&5
     11803+  echo "$as_me:15047: \$? = $ac_status" >&5
    1152111804   (exit $ac_status); }; }; then
    1152211805   cf_cv_header_stdbool_h=0
     
    1152611809 cat >conftest.$ac_ext <<_ACEOF
    1152711810-#line 14647 "configure"
    11528 +#line 15025 "configure"
     11811+#line 15054 "configure"
    1152911812 #include "confdefs.h"
    1153011813 
    1153111814 #ifndef __BEOS__
    11532 @@ -14660,16 +15038,16 @@
     11815@@ -14660,16 +15067,16 @@
    1153311816 }
    1153411817 _ACEOF
    1153511818 rm -f conftest.$ac_objext
    1153611819-if { (eval echo "$as_me:14663: \"$ac_compile\"") >&5
    11537 +if { (eval echo "$as_me:15041: \"$ac_compile\"") >&5
     11820+if { (eval echo "$as_me:15070: \"$ac_compile\"") >&5
    1153811821   (eval $ac_compile) 2>&5
    1153911822   ac_status=$?
    1154011823-  echo "$as_me:14666: \$? = $ac_status" >&5
    11541 +  echo "$as_me:15044: \$? = $ac_status" >&5
     11824+  echo "$as_me:15073: \$? = $ac_status" >&5
    1154211825   (exit $ac_status); } &&
    1154311826          { ac_try='test -s conftest.$ac_objext'
    1154411827-  { (eval echo "$as_me:14669: \"$ac_try\"") >&5
    11545 +  { (eval echo "$as_me:15047: \"$ac_try\"") >&5
     11828+  { (eval echo "$as_me:15076: \"$ac_try\"") >&5
    1154611829   (eval $ac_try) 2>&5
    1154711830   ac_status=$?
    1154811831-  echo "$as_me:14672: \$? = $ac_status" >&5
    11549 +  echo "$as_me:15050: \$? = $ac_status" >&5
     11832+  echo "$as_me:15079: \$? = $ac_status" >&5
    1155011833   (exit $ac_status); }; }; then
    1155111834   cf_cv_header_stdbool_h=1
    1155211835 else
    11553 @@ -14683,13 +15061,13 @@
     11836@@ -14683,13 +15090,13 @@
    1155411837 fi
    1155511838 
    1155611839 if test "$cf_cv_header_stdbool_h" = 1
    1155711840-then   echo "$as_me:14686: result: yes" >&5
    11558 +then   echo "$as_me:15064: result: yes" >&5
     11841+then   echo "$as_me:15093: result: yes" >&5
    1155911842 echo "${ECHO_T}yes" >&6
    1156011843-else   echo "$as_me:14688: result: no" >&5
    11561 +else   echo "$as_me:15066: result: no" >&5
     11844+else   echo "$as_me:15095: result: no" >&5
    1156211845 echo "${ECHO_T}no" >&6
    1156311846 fi
    1156411847 
    1156511848-echo "$as_me:14692: checking for builtin bool type" >&5
    11566 +echo "$as_me:15070: checking for builtin bool type" >&5
     11849+echo "$as_me:15099: checking for builtin bool type" >&5
    1156711850 echo $ECHO_N "checking for builtin bool type... $ECHO_C" >&6
    1156811851 
    1156911852 if test "${cf_cv_cc_bool_type+set}" = set; then
    11570 @@ -14697,7 +15075,7 @@
     11853@@ -14697,7 +15104,7 @@
    1157111854 else
    1157211855 
    1157311856        cat >conftest.$ac_ext <<_ACEOF
    1157411857-#line 14700 "configure"
    11575 +#line 15078 "configure"
     11858+#line 15107 "configure"
    1157611859 #include "confdefs.h"
    1157711860 
    1157811861 #include <stdio.h>
    11579 @@ -14712,16 +15090,16 @@
     11862@@ -14712,16 +15119,16 @@
    1158011863 }
    1158111864 _ACEOF
    1158211865 rm -f conftest.$ac_objext
    1158311866-if { (eval echo "$as_me:14715: \"$ac_compile\"") >&5
    11584 +if { (eval echo "$as_me:15093: \"$ac_compile\"") >&5
     11867+if { (eval echo "$as_me:15122: \"$ac_compile\"") >&5
    1158511868   (eval $ac_compile) 2>&5
    1158611869   ac_status=$?
    1158711870-  echo "$as_me:14718: \$? = $ac_status" >&5
    11588 +  echo "$as_me:15096: \$? = $ac_status" >&5
     11871+  echo "$as_me:15125: \$? = $ac_status" >&5
    1158911872   (exit $ac_status); } &&
    1159011873          { ac_try='test -s conftest.$ac_objext'
    1159111874-  { (eval echo "$as_me:14721: \"$ac_try\"") >&5
    11592 +  { (eval echo "$as_me:15099: \"$ac_try\"") >&5
     11875+  { (eval echo "$as_me:15128: \"$ac_try\"") >&5
    1159311876   (eval $ac_try) 2>&5
    1159411877   ac_status=$?
    1159511878-  echo "$as_me:14724: \$? = $ac_status" >&5
    11596 +  echo "$as_me:15102: \$? = $ac_status" >&5
     11879+  echo "$as_me:15131: \$? = $ac_status" >&5
    1159711880   (exit $ac_status); }; }; then
    1159811881   cf_cv_cc_bool_type=1
    1159911882 else
    11600 @@ -14734,9 +15112,9 @@
     11883@@ -14734,9 +15141,9 @@
    1160111884 fi
    1160211885 
    1160311886 if test "$cf_cv_cc_bool_type" = 1
    1160411887-then   echo "$as_me:14737: result: yes" >&5
    11605 +then   echo "$as_me:15115: result: yes" >&5
     11888+then   echo "$as_me:15144: result: yes" >&5
    1160611889 echo "${ECHO_T}yes" >&6
    1160711890-else   echo "$as_me:14739: result: no" >&5
    11608 +else   echo "$as_me:15117: result: no" >&5
     11891+else   echo "$as_me:15146: result: no" >&5
    1160911892 echo "${ECHO_T}no" >&6
    1161011893 fi
    1161111894 
    11612 @@ -14758,7 +15136,7 @@
     11895@@ -14758,7 +15165,7 @@
    1161311896        cf_stdcpp_libname=stdc++
    1161411897        ;;
    1161511898 esac
    1161611899-echo "$as_me:14761: checking for library $cf_stdcpp_libname" >&5
    11617 +echo "$as_me:15139: checking for library $cf_stdcpp_libname" >&5
     11900+echo "$as_me:15168: checking for library $cf_stdcpp_libname" >&5
    1161811901 echo $ECHO_N "checking for library $cf_stdcpp_libname... $ECHO_C" >&6
    1161911902 if test "${cf_cv_libstdcpp+set}" = set; then
    1162011903   echo $ECHO_N "(cached) $ECHO_C" >&6
    11621 @@ -14767,7 +15145,7 @@
     11904@@ -14767,7 +15174,7 @@
    1162211905        cf_save="$LIBS"
    1162311906        LIBS="$LIBS -l$cf_stdcpp_libname"
    1162411907 cat >conftest.$ac_ext <<_ACEOF
    1162511908-#line 14770 "configure"
    11626 +#line 15148 "configure"
     11909+#line 15177 "configure"
    1162711910 #include "confdefs.h"
    1162811911 
    1162911912 #include <strstream.h>
    11630 @@ -14783,16 +15161,16 @@
     11913@@ -14783,16 +15190,16 @@
    1163111914 }
    1163211915 _ACEOF
    1163311916 rm -f conftest.$ac_objext conftest$ac_exeext
    1163411917-if { (eval echo "$as_me:14786: \"$ac_link\"") >&5
    11635 +if { (eval echo "$as_me:15164: \"$ac_link\"") >&5
     11918+if { (eval echo "$as_me:15193: \"$ac_link\"") >&5
    1163611919   (eval $ac_link) 2>&5
    1163711920   ac_status=$?
    1163811921-  echo "$as_me:14789: \$? = $ac_status" >&5
    11639 +  echo "$as_me:15167: \$? = $ac_status" >&5
     11922+  echo "$as_me:15196: \$? = $ac_status" >&5
    1164011923   (exit $ac_status); } &&
    1164111924          { ac_try='test -s conftest$ac_exeext'
    1164211925-  { (eval echo "$as_me:14792: \"$ac_try\"") >&5
    11643 +  { (eval echo "$as_me:15170: \"$ac_try\"") >&5
     11926+  { (eval echo "$as_me:15199: \"$ac_try\"") >&5
    1164411927   (eval $ac_try) 2>&5
    1164511928   ac_status=$?
    1164611929-  echo "$as_me:14795: \$? = $ac_status" >&5
    11647 +  echo "$as_me:15173: \$? = $ac_status" >&5
     11930+  echo "$as_me:15202: \$? = $ac_status" >&5
    1164811931   (exit $ac_status); }; }; then
    1164911932   cf_cv_libstdcpp=yes
    1165011933 else
    11651 @@ -14804,12 +15182,12 @@
     11934@@ -14804,12 +15211,12 @@
    1165211935        LIBS="$cf_save"
    1165311936 
    1165411937 fi
    1165511938-echo "$as_me:14807: result: $cf_cv_libstdcpp" >&5
    11656 +echo "$as_me:15185: result: $cf_cv_libstdcpp" >&5
     11939+echo "$as_me:15214: result: $cf_cv_libstdcpp" >&5
    1165711940 echo "${ECHO_T}$cf_cv_libstdcpp" >&6
    1165811941 test "$cf_cv_libstdcpp" = yes && CXXLIBS="$CXXLIBS -l$cf_stdcpp_libname"
     
    1166011943 
    1166111944-       echo "$as_me:14812: checking whether $CXX understands -c and -o together" >&5
    11662 +       echo "$as_me:15190: checking whether $CXX understands -c and -o together" >&5
     11945+       echo "$as_me:15219: checking whether $CXX understands -c and -o together" >&5
    1166311946 echo $ECHO_N "checking whether $CXX understands -c and -o together... $ECHO_C" >&6
    1166411947 if test "${cf_cv_prog_CXX_c_o+set}" = set; then
    1166511948   echo $ECHO_N "(cached) $ECHO_C" >&6
    11666 @@ -14825,15 +15203,15 @@
     11949@@ -14825,15 +15232,15 @@
    1166711950 # We do the test twice because some compilers refuse to overwrite an
    1166811951 # existing .o file with -o, though they will create one.
    1166911952 ac_try='$CXX -c conftest.$ac_ext -o conftest2.$ac_objext >&5'
    1167011953-if { (eval echo "$as_me:14828: \"$ac_try\"") >&5
    11671 +if { (eval echo "$as_me:15206: \"$ac_try\"") >&5
     11954+if { (eval echo "$as_me:15235: \"$ac_try\"") >&5
    1167211955   (eval $ac_try) 2>&5
    1167311956   ac_status=$?
    1167411957-  echo "$as_me:14831: \$? = $ac_status" >&5
    11675 +  echo "$as_me:15209: \$? = $ac_status" >&5
     11958+  echo "$as_me:15238: \$? = $ac_status" >&5
    1167611959   (exit $ac_status); } &&
    1167711960-  test -f conftest2.$ac_objext && { (eval echo "$as_me:14833: \"$ac_try\"") >&5
    11678 +  test -f conftest2.$ac_objext && { (eval echo "$as_me:15211: \"$ac_try\"") >&5
     11961+  test -f conftest2.$ac_objext && { (eval echo "$as_me:15240: \"$ac_try\"") >&5
    1167911962   (eval $ac_try) 2>&5
    1168011963   ac_status=$?
    1168111964-  echo "$as_me:14836: \$? = $ac_status" >&5
    11682 +  echo "$as_me:15214: \$? = $ac_status" >&5
     11965+  echo "$as_me:15243: \$? = $ac_status" >&5
    1168311966   (exit $ac_status); };
    1168411967 then
    1168511968   eval cf_cv_prog_CXX_c_o=yes
    11686 @@ -14844,10 +15222,10 @@
     11969@@ -14844,10 +15251,10 @@
    1168711970 
    1168811971 fi
    1168911972 if test $cf_cv_prog_CXX_c_o = yes; then
    1169011973-  echo "$as_me:14847: result: yes" >&5
    11691 +  echo "$as_me:15225: result: yes" >&5
     11974+  echo "$as_me:15254: result: yes" >&5
    1169211975 echo "${ECHO_T}yes" >&6
    1169311976 else
    1169411977-  echo "$as_me:14850: result: no" >&5
    11695 +  echo "$as_me:15228: result: no" >&5
     11978+  echo "$as_me:15257: result: no" >&5
    1169611979 echo "${ECHO_T}no" >&6
    1169711980 fi
    1169811981 
    11699 @@ -14867,12 +15245,12 @@
     11982@@ -14867,12 +15274,12 @@
    1170011983        ;;
    1170111984 esac
    1170211985 if test "$GXX" = yes; then
    1170311986-       echo "$as_me:14870: checking for lib$cf_gpp_libname" >&5
    11704 +       echo "$as_me:15248: checking for lib$cf_gpp_libname" >&5
     11987+       echo "$as_me:15277: checking for lib$cf_gpp_libname" >&5
    1170511988 echo $ECHO_N "checking for lib$cf_gpp_libname... $ECHO_C" >&6
    1170611989        cf_save="$LIBS"
     
    1170811991        cat >conftest.$ac_ext <<_ACEOF
    1170911992-#line 14875 "configure"
    11710 +#line 15253 "configure"
     11993+#line 15282 "configure"
    1171111994 #include "confdefs.h"
    1171211995 
    1171311996 #include <$cf_gpp_libname/builtin.h>
    11714 @@ -14886,16 +15264,16 @@
     11997@@ -14886,16 +15293,16 @@
    1171511998 }
    1171611999 _ACEOF
    1171712000 rm -f conftest.$ac_objext conftest$ac_exeext
    1171812001-if { (eval echo "$as_me:14889: \"$ac_link\"") >&5
    11719 +if { (eval echo "$as_me:15267: \"$ac_link\"") >&5
     12002+if { (eval echo "$as_me:15296: \"$ac_link\"") >&5
    1172012003   (eval $ac_link) 2>&5
    1172112004   ac_status=$?
    1172212005-  echo "$as_me:14892: \$? = $ac_status" >&5
    11723 +  echo "$as_me:15270: \$? = $ac_status" >&5
     12006+  echo "$as_me:15299: \$? = $ac_status" >&5
    1172412007   (exit $ac_status); } &&
    1172512008          { ac_try='test -s conftest$ac_exeext'
    1172612009-  { (eval echo "$as_me:14895: \"$ac_try\"") >&5
    11727 +  { (eval echo "$as_me:15273: \"$ac_try\"") >&5
     12010+  { (eval echo "$as_me:15302: \"$ac_try\"") >&5
    1172812011   (eval $ac_try) 2>&5
    1172912012   ac_status=$?
    1173012013-  echo "$as_me:14898: \$? = $ac_status" >&5
    11731 +  echo "$as_me:15276: \$? = $ac_status" >&5
     12014+  echo "$as_me:15305: \$? = $ac_status" >&5
    1173212015   (exit $ac_status); }; }; then
    1173312016   cf_cxx_library=yes
    1173412017         CXXLIBS="$CXXLIBS -l$cf_gpp_libname"
    11735 @@ -14914,7 +15292,7 @@
     12018@@ -14914,7 +15321,7 @@
    1173612019   echo "$as_me: failed program was:" >&5
    1173712020 cat conftest.$ac_ext >&5
    1173812021 cat >conftest.$ac_ext <<_ACEOF
    1173912022-#line 14917 "configure"
    11740 +#line 15295 "configure"
     12023+#line 15324 "configure"
    1174112024 #include "confdefs.h"
    1174212025 
    1174312026 #include <builtin.h>
    11744 @@ -14928,16 +15306,16 @@
     12027@@ -14928,16 +15335,16 @@
    1174512028 }
    1174612029 _ACEOF
    1174712030 rm -f conftest.$ac_objext conftest$ac_exeext
    1174812031-if { (eval echo "$as_me:14931: \"$ac_link\"") >&5
    11749 +if { (eval echo "$as_me:15309: \"$ac_link\"") >&5
     12032+if { (eval echo "$as_me:15338: \"$ac_link\"") >&5
    1175012033   (eval $ac_link) 2>&5
    1175112034   ac_status=$?
    1175212035-  echo "$as_me:14934: \$? = $ac_status" >&5
    11753 +  echo "$as_me:15312: \$? = $ac_status" >&5
     12036+  echo "$as_me:15341: \$? = $ac_status" >&5
    1175412037   (exit $ac_status); } &&
    1175512038          { ac_try='test -s conftest$ac_exeext'
    1175612039-  { (eval echo "$as_me:14937: \"$ac_try\"") >&5
    11757 +  { (eval echo "$as_me:15315: \"$ac_try\"") >&5
     12040+  { (eval echo "$as_me:15344: \"$ac_try\"") >&5
    1175812041   (eval $ac_try) 2>&5
    1175912042   ac_status=$?
    1176012043-  echo "$as_me:14940: \$? = $ac_status" >&5
    11761 +  echo "$as_me:15318: \$? = $ac_status" >&5
     12044+  echo "$as_me:15347: \$? = $ac_status" >&5
    1176212045   (exit $ac_status); }; }; then
    1176312046   cf_cxx_library=yes
    1176412047         CXXLIBS="$CXXLIBS -l$cf_gpp_libname"
    11765 @@ -14954,7 +15332,7 @@
     12048@@ -14954,7 +15361,7 @@
    1176612049 fi
    1176712050 rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
    1176812051        LIBS="$cf_save"
    1176912052-       echo "$as_me:14957: result: $cf_cxx_library" >&5
    11770 +       echo "$as_me:15335: result: $cf_cxx_library" >&5
     12053+       echo "$as_me:15364: result: $cf_cxx_library" >&5
    1177112054 echo "${ECHO_T}$cf_cxx_library" >&6
    1177212055 fi
    1177312056 
    11774 @@ -14970,7 +15348,7 @@
     12057@@ -14970,7 +15377,7 @@
    1177512058 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
    1177612059 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu
    1177712060 ac_main_return=return
    1177812061-echo "$as_me:14973: checking how to run the C++ preprocessor" >&5
    11779 +echo "$as_me:15351: checking how to run the C++ preprocessor" >&5
     12062+echo "$as_me:15380: checking how to run the C++ preprocessor" >&5
    1178012063 echo $ECHO_N "checking how to run the C++ preprocessor... $ECHO_C" >&6
    1178112064 if test -z "$CXXCPP"; then
    1178212065   if test "${ac_cv_prog_CXXCPP+set}" = set; then
    11783 @@ -14987,18 +15365,18 @@
     12066@@ -14987,18 +15394,18 @@
    1178412067   # On the NeXT, cc -E runs the code through the compiler's parser,
    1178512068   # not just through cpp. "Syntax error" is here to catch this case.
    1178612069   cat >conftest.$ac_ext <<_ACEOF
    1178712070-#line 14990 "configure"
    11788 +#line 15368 "configure"
     12071+#line 15397 "configure"
    1178912072 #include "confdefs.h"
    1179012073 #include <assert.h>
     
    1179212075 _ACEOF
    1179312076-if { (eval echo "$as_me:14995: \"$ac_cpp conftest.$ac_ext\"") >&5
    11794 +if { (eval echo "$as_me:15373: \"$ac_cpp conftest.$ac_ext\"") >&5
     12077+if { (eval echo "$as_me:15402: \"$ac_cpp conftest.$ac_ext\"") >&5
    1179512078   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    1179612079   ac_status=$?
     
    1179912082   cat conftest.err >&5
    1180012083-  echo "$as_me:15001: \$? = $ac_status" >&5
    11801 +  echo "$as_me:15379: \$? = $ac_status" >&5
     12084+  echo "$as_me:15408: \$? = $ac_status" >&5
    1180212085   (exit $ac_status); } >/dev/null; then
    1180312086   if test -s conftest.err; then
    1180412087     ac_cpp_err=$ac_cxx_preproc_warn_flag
    11805 @@ -15021,17 +15399,17 @@
     12088@@ -15021,17 +15428,17 @@
    1180612089   # OK, works on sane cases.  Now check whether non-existent headers
    1180712090   # can be detected and how.
    1180812091   cat >conftest.$ac_ext <<_ACEOF
    1180912092-#line 15024 "configure"
    11810 +#line 15402 "configure"
     12093+#line 15431 "configure"
    1181112094 #include "confdefs.h"
    1181212095 #include <ac_nonexistent.h>
    1181312096 _ACEOF
    1181412097-if { (eval echo "$as_me:15028: \"$ac_cpp conftest.$ac_ext\"") >&5
    11815 +if { (eval echo "$as_me:15406: \"$ac_cpp conftest.$ac_ext\"") >&5
     12098+if { (eval echo "$as_me:15435: \"$ac_cpp conftest.$ac_ext\"") >&5
    1181612099   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    1181712100   ac_status=$?
     
    1182012103   cat conftest.err >&5
    1182112104-  echo "$as_me:15034: \$? = $ac_status" >&5
    11822 +  echo "$as_me:15412: \$? = $ac_status" >&5
     12105+  echo "$as_me:15441: \$? = $ac_status" >&5
    1182312106   (exit $ac_status); } >/dev/null; then
    1182412107   if test -s conftest.err; then
    1182512108     ac_cpp_err=$ac_cxx_preproc_warn_flag
    11826 @@ -15068,7 +15446,7 @@
     12109@@ -15068,7 +15475,7 @@
    1182712110 else
    1182812111   ac_cv_prog_CXXCPP=$CXXCPP
    1182912112 fi
    1183012113-echo "$as_me:15071: result: $CXXCPP" >&5
    11831 +echo "$as_me:15449: result: $CXXCPP" >&5
     12114+echo "$as_me:15478: result: $CXXCPP" >&5
    1183212115 echo "${ECHO_T}$CXXCPP" >&6
    1183312116 ac_preproc_ok=false
    1183412117 for ac_cxx_preproc_warn_flag in '' yes
    11835 @@ -15078,18 +15456,18 @@
     12118@@ -15078,18 +15485,18 @@
    1183612119   # On the NeXT, cc -E runs the code through the compiler's parser,
    1183712120   # not just through cpp. "Syntax error" is here to catch this case.
    1183812121   cat >conftest.$ac_ext <<_ACEOF
    1183912122-#line 15081 "configure"
    11840 +#line 15459 "configure"
     12123+#line 15488 "configure"
    1184112124 #include "confdefs.h"
    1184212125 #include <assert.h>
     
    1184412127 _ACEOF
    1184512128-if { (eval echo "$as_me:15086: \"$ac_cpp conftest.$ac_ext\"") >&5
    11846 +if { (eval echo "$as_me:15464: \"$ac_cpp conftest.$ac_ext\"") >&5
     12129+if { (eval echo "$as_me:15493: \"$ac_cpp conftest.$ac_ext\"") >&5
    1184712130   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    1184812131   ac_status=$?
     
    1185112134   cat conftest.err >&5
    1185212135-  echo "$as_me:15092: \$? = $ac_status" >&5
    11853 +  echo "$as_me:15470: \$? = $ac_status" >&5
     12136+  echo "$as_me:15499: \$? = $ac_status" >&5
    1185412137   (exit $ac_status); } >/dev/null; then
    1185512138   if test -s conftest.err; then
    1185612139     ac_cpp_err=$ac_cxx_preproc_warn_flag
    11857 @@ -15112,17 +15490,17 @@
     12140@@ -15112,17 +15519,17 @@
    1185812141   # OK, works on sane cases.  Now check whether non-existent headers
    1185912142   # can be detected and how.
    1186012143   cat >conftest.$ac_ext <<_ACEOF
    1186112144-#line 15115 "configure"
    11862 +#line 15493 "configure"
     12145+#line 15522 "configure"
    1186312146 #include "confdefs.h"
    1186412147 #include <ac_nonexistent.h>
    1186512148 _ACEOF
    1186612149-if { (eval echo "$as_me:15119: \"$ac_cpp conftest.$ac_ext\"") >&5
    11867 +if { (eval echo "$as_me:15497: \"$ac_cpp conftest.$ac_ext\"") >&5
     12150+if { (eval echo "$as_me:15526: \"$ac_cpp conftest.$ac_ext\"") >&5
    1186812151   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    1186912152   ac_status=$?
     
    1187212155   cat conftest.err >&5
    1187312156-  echo "$as_me:15125: \$? = $ac_status" >&5
    11874 +  echo "$as_me:15503: \$? = $ac_status" >&5
     12157+  echo "$as_me:15532: \$? = $ac_status" >&5
    1187512158   (exit $ac_status); } >/dev/null; then
    1187612159   if test -s conftest.err; then
    1187712160     ac_cpp_err=$ac_cxx_preproc_warn_flag
    11878 @@ -15150,7 +15528,7 @@
     12161@@ -15150,7 +15557,7 @@
    1187912162 if $ac_preproc_ok; then
    1188012163   :
    1188112164 else
    1188212165-  { { echo "$as_me:15153: error: C++ preprocessor \"$CXXCPP\" fails sanity check" >&5
    11883 +  { { echo "$as_me:15531: error: C++ preprocessor \"$CXXCPP\" fails sanity check" >&5
     12166+  { { echo "$as_me:15560: error: C++ preprocessor \"$CXXCPP\" fails sanity check" >&5
    1188412167 echo "$as_me: error: C++ preprocessor \"$CXXCPP\" fails sanity check" >&2;}
    1188512168    { (exit 1); exit 1; }; }
    1188612169 fi
    11887 @@ -15165,23 +15543,23 @@
     12170@@ -15165,23 +15572,23 @@
    1188812171 for ac_header in iostream typeinfo
    1188912172 do
    1189012173 as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
    1189112174-echo "$as_me:15168: checking for $ac_header" >&5
    11892 +echo "$as_me:15546: checking for $ac_header" >&5
     12175+echo "$as_me:15575: checking for $ac_header" >&5
    1189312176 echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
    1189412177 if eval "test \"\${$as_ac_Header+set}\" = set"; then
     
    1189712180   cat >conftest.$ac_ext <<_ACEOF
    1189812181-#line 15174 "configure"
    11899 +#line 15552 "configure"
     12182+#line 15581 "configure"
    1190012183 #include "confdefs.h"
    1190112184 #include <$ac_header>
    1190212185 _ACEOF
    1190312186-if { (eval echo "$as_me:15178: \"$ac_cpp conftest.$ac_ext\"") >&5
    11904 +if { (eval echo "$as_me:15556: \"$ac_cpp conftest.$ac_ext\"") >&5
     12187+if { (eval echo "$as_me:15585: \"$ac_cpp conftest.$ac_ext\"") >&5
    1190512188   (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
    1190612189   ac_status=$?
     
    1190912192   cat conftest.err >&5
    1191012193-  echo "$as_me:15184: \$? = $ac_status" >&5
    11911 +  echo "$as_me:15562: \$? = $ac_status" >&5
     12194+  echo "$as_me:15591: \$? = $ac_status" >&5
    1191212195   (exit $ac_status); } >/dev/null; then
    1191312196   if test -s conftest.err; then
    1191412197     ac_cpp_err=$ac_cxx_preproc_warn_flag
    11915 @@ -15200,7 +15578,7 @@
     12198@@ -15200,7 +15607,7 @@
    1191612199 fi
    1191712200 rm -f conftest.err conftest.$ac_ext
    1191812201 fi
    1191912202-echo "$as_me:15203: result: `eval echo '${'$as_ac_Header'}'`" >&5
    11920 +echo "$as_me:15581: result: `eval echo '${'$as_ac_Header'}'`" >&5
     12203+echo "$as_me:15610: result: `eval echo '${'$as_ac_Header'}'`" >&5
    1192112204 echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
    1192212205 if test `eval echo '${'$as_ac_Header'}'` = yes; then
    1192312206   cat >>confdefs.h <<EOF
    11924 @@ -15211,10 +15589,10 @@
     12207@@ -15211,10 +15618,10 @@
    1192512208 done
    1192612209 
    1192712210     if test x"$ac_cv_header_iostream" = xyes ; then
    1192812211-        echo "$as_me:15214: checking if iostream uses std-namespace" >&5
    11929 +        echo "$as_me:15592: checking if iostream uses std-namespace" >&5
     12212+        echo "$as_me:15621: checking if iostream uses std-namespace" >&5
    1193012213 echo $ECHO_N "checking if iostream uses std-namespace... $ECHO_C" >&6
    1193112214         cat >conftest.$ac_ext <<_ACEOF
    1193212215-#line 15217 "configure"
    11933 +#line 15595 "configure"
     12216+#line 15624 "configure"
    1193412217 #include "confdefs.h"
    1193512218 
    1193612219 #include <iostream>
    11937 @@ -15231,16 +15609,16 @@
     12220@@ -15231,16 +15638,16 @@
    1193812221 }
    1193912222 _ACEOF
    1194012223 rm -f conftest.$ac_objext
    1194112224-if { (eval echo "$as_me:15234: \"$ac_compile\"") >&5
    11942 +if { (eval echo "$as_me:15612: \"$ac_compile\"") >&5
     12225+if { (eval echo "$as_me:15641: \"$ac_compile\"") >&5
    1194312226   (eval $ac_compile) 2>&5
    1194412227   ac_status=$?
    1194512228-  echo "$as_me:15237: \$? = $ac_status" >&5
    11946 +  echo "$as_me:15615: \$? = $ac_status" >&5
     12229+  echo "$as_me:15644: \$? = $ac_status" >&5
    1194712230   (exit $ac_status); } &&
    1194812231          { ac_try='test -s conftest.$ac_objext'
    1194912232-  { (eval echo "$as_me:15240: \"$ac_try\"") >&5
    11950 +  { (eval echo "$as_me:15618: \"$ac_try\"") >&5
     12233+  { (eval echo "$as_me:15647: \"$ac_try\"") >&5
    1195112234   (eval $ac_try) 2>&5
    1195212235   ac_status=$?
    1195312236-  echo "$as_me:15243: \$? = $ac_status" >&5
    11954 +  echo "$as_me:15621: \$? = $ac_status" >&5
     12237+  echo "$as_me:15650: \$? = $ac_status" >&5
    1195512238   (exit $ac_status); }; }; then
    1195612239   cf_iostream_namespace=yes
    1195712240 else
    11958 @@ -15249,7 +15627,7 @@
     12241@@ -15249,7 +15656,7 @@
    1195912242 cf_iostream_namespace=no
    1196012243 fi
    1196112244 rm -f conftest.$ac_objext conftest.$ac_ext
    1196212245-        echo "$as_me:15252: result: $cf_iostream_namespace" >&5
    11963 +        echo "$as_me:15630: result: $cf_iostream_namespace" >&5
     12246+        echo "$as_me:15659: result: $cf_iostream_namespace" >&5
    1196412247 echo "${ECHO_T}$cf_iostream_namespace" >&6
    1196512248         if test "$cf_iostream_namespace" = yes ; then
    1196612249             cat >>confdefs.h <<\EOF
    11967 @@ -15259,7 +15637,7 @@
     12250@@ -15259,7 +15666,7 @@
    1196812251         fi
    1196912252     fi
    1197012253 
    1197112254-echo "$as_me:15262: checking if we should include stdbool.h" >&5
    11972 +echo "$as_me:15640: checking if we should include stdbool.h" >&5
     12255+echo "$as_me:15669: checking if we should include stdbool.h" >&5
    1197312256 echo $ECHO_N "checking if we should include stdbool.h... $ECHO_C" >&6
    1197412257 
    1197512258 if test "${cf_cv_header_stdbool_h+set}" = set; then
    11976 @@ -15267,7 +15645,7 @@
     12259@@ -15267,7 +15674,7 @@
    1197712260 else
    1197812261 
    1197912262        cat >conftest.$ac_ext <<_ACEOF
    1198012263-#line 15270 "configure"
    11981 +#line 15648 "configure"
     12264+#line 15677 "configure"
    1198212265 #include "confdefs.h"
    1198312266 
    1198412267 int
    11985 @@ -15279,23 +15657,23 @@
     12268@@ -15279,23 +15686,23 @@
    1198612269 }
    1198712270 _ACEOF
    1198812271 rm -f conftest.$ac_objext
    1198912272-if { (eval echo "$as_me:15282: \"$ac_compile\"") >&5
    11990 +if { (eval echo "$as_me:15660: \"$ac_compile\"") >&5
     12273+if { (eval echo "$as_me:15689: \"$ac_compile\"") >&5
    1199112274   (eval $ac_compile) 2>&5
    1199212275   ac_status=$?
    1199312276-  echo "$as_me:15285: \$? = $ac_status" >&5
    11994 +  echo "$as_me:15663: \$? = $ac_status" >&5
     12277+  echo "$as_me:15692: \$? = $ac_status" >&5
    1199512278   (exit $ac_status); } &&
    1199612279          { ac_try='test -s conftest.$ac_objext'
    1199712280-  { (eval echo "$as_me:15288: \"$ac_try\"") >&5
    11998 +  { (eval echo "$as_me:15666: \"$ac_try\"") >&5
     12281+  { (eval echo "$as_me:15695: \"$ac_try\"") >&5
    1199912282   (eval $ac_try) 2>&5
    1200012283   ac_status=$?
    1200112284-  echo "$as_me:15291: \$? = $ac_status" >&5
    12002 +  echo "$as_me:15669: \$? = $ac_status" >&5
     12285+  echo "$as_me:15698: \$? = $ac_status" >&5
    1200312286   (exit $ac_status); }; }; then
    1200412287   cf_cv_header_stdbool_h=0
     
    1200812291 cat >conftest.$ac_ext <<_ACEOF
    1200912292-#line 15298 "configure"
    12010 +#line 15676 "configure"
     12293+#line 15705 "configure"
    1201112294 #include "confdefs.h"
    1201212295 
    1201312296 #ifndef __BEOS__
    12014 @@ -15311,16 +15689,16 @@
     12297@@ -15311,16 +15718,16 @@
    1201512298 }
    1201612299 _ACEOF
    1201712300 rm -f conftest.$ac_objext
    1201812301-if { (eval echo "$as_me:15314: \"$ac_compile\"") >&5
    12019 +if { (eval echo "$as_me:15692: \"$ac_compile\"") >&5
     12302+if { (eval echo "$as_me:15721: \"$ac_compile\"") >&5
    1202012303   (eval $ac_compile) 2>&5
    1202112304   ac_status=$?
    1202212305-  echo "$as_me:15317: \$? = $ac_status" >&5
    12023 +  echo "$as_me:15695: \$? = $ac_status" >&5
     12306+  echo "$as_me:15724: \$? = $ac_status" >&5
    1202412307   (exit $ac_status); } &&
    1202512308          { ac_try='test -s conftest.$ac_objext'
    1202612309-  { (eval echo "$as_me:15320: \"$ac_try\"") >&5
    12027 +  { (eval echo "$as_me:15698: \"$ac_try\"") >&5
     12310+  { (eval echo "$as_me:15727: \"$ac_try\"") >&5
    1202812311   (eval $ac_try) 2>&5
    1202912312   ac_status=$?
    1203012313-  echo "$as_me:15323: \$? = $ac_status" >&5
    12031 +  echo "$as_me:15701: \$? = $ac_status" >&5
     12314+  echo "$as_me:15730: \$? = $ac_status" >&5
    1203212315   (exit $ac_status); }; }; then
    1203312316   cf_cv_header_stdbool_h=1
    1203412317 else
    12035 @@ -15334,13 +15712,13 @@
     12318@@ -15334,13 +15741,13 @@
    1203612319 fi
    1203712320 
    1203812321 if test "$cf_cv_header_stdbool_h" = 1
    1203912322-then   echo "$as_me:15337: result: yes" >&5
    12040 +then   echo "$as_me:15715: result: yes" >&5
     12323+then   echo "$as_me:15744: result: yes" >&5
    1204112324 echo "${ECHO_T}yes" >&6
    1204212325-else   echo "$as_me:15339: result: no" >&5
    12043 +else   echo "$as_me:15717: result: no" >&5
     12326+else   echo "$as_me:15746: result: no" >&5
    1204412327 echo "${ECHO_T}no" >&6
    1204512328 fi
    1204612329 
    1204712330-echo "$as_me:15343: checking for builtin bool type" >&5
    12048 +echo "$as_me:15721: checking for builtin bool type" >&5
     12331+echo "$as_me:15750: checking for builtin bool type" >&5
    1204912332 echo $ECHO_N "checking for builtin bool type... $ECHO_C" >&6
    1205012333 
    1205112334 if test "${cf_cv_builtin_bool+set}" = set; then
    12052 @@ -15348,7 +15726,7 @@
     12335@@ -15348,7 +15755,7 @@
    1205312336 else
    1205412337 
    1205512338        cat >conftest.$ac_ext <<_ACEOF
    1205612339-#line 15351 "configure"
    12057 +#line 15729 "configure"
     12340+#line 15758 "configure"
    1205812341 #include "confdefs.h"
    1205912342 
    1206012343 #include <stdio.h>
    12061 @@ -15363,16 +15741,16 @@
     12344@@ -15363,16 +15770,16 @@
    1206212345 }
    1206312346 _ACEOF
    1206412347 rm -f conftest.$ac_objext
    1206512348-if { (eval echo "$as_me:15366: \"$ac_compile\"") >&5
    12066 +if { (eval echo "$as_me:15744: \"$ac_compile\"") >&5
     12349+if { (eval echo "$as_me:15773: \"$ac_compile\"") >&5
    1206712350   (eval $ac_compile) 2>&5
    1206812351   ac_status=$?
    1206912352-  echo "$as_me:15369: \$? = $ac_status" >&5
    12070 +  echo "$as_me:15747: \$? = $ac_status" >&5
     12353+  echo "$as_me:15776: \$? = $ac_status" >&5
    1207112354   (exit $ac_status); } &&
    1207212355          { ac_try='test -s conftest.$ac_objext'
    1207312356-  { (eval echo "$as_me:15372: \"$ac_try\"") >&5
    12074 +  { (eval echo "$as_me:15750: \"$ac_try\"") >&5
     12357+  { (eval echo "$as_me:15779: \"$ac_try\"") >&5
    1207512358   (eval $ac_try) 2>&5
    1207612359   ac_status=$?
    1207712360-  echo "$as_me:15375: \$? = $ac_status" >&5
    12078 +  echo "$as_me:15753: \$? = $ac_status" >&5
     12361+  echo "$as_me:15782: \$? = $ac_status" >&5
    1207912362   (exit $ac_status); }; }; then
    1208012363   cf_cv_builtin_bool=1
    1208112364 else
    12082 @@ -15385,13 +15763,13 @@
     12365@@ -15385,13 +15792,13 @@
    1208312366 fi
    1208412367 
    1208512368 if test "$cf_cv_builtin_bool" = 1
    1208612369-then   echo "$as_me:15388: result: yes" >&5
    12087 +then   echo "$as_me:15766: result: yes" >&5
     12370+then   echo "$as_me:15795: result: yes" >&5
    1208812371 echo "${ECHO_T}yes" >&6
    1208912372-else   echo "$as_me:15390: result: no" >&5
    12090 +else   echo "$as_me:15768: result: no" >&5
     12373+else   echo "$as_me:15797: result: no" >&5
    1209112374 echo "${ECHO_T}no" >&6
    1209212375 fi
    1209312376 
    1209412377-echo "$as_me:15394: checking for size of bool" >&5
    12095 +echo "$as_me:15772: checking for size of bool" >&5
     12378+echo "$as_me:15801: checking for size of bool" >&5
    1209612379 echo $ECHO_N "checking for size of bool... $ECHO_C" >&6
    1209712380 if test "${cf_cv_type_of_bool+set}" = set; then
    1209812381   echo $ECHO_N "(cached) $ECHO_C" >&6
    12099 @@ -15402,7 +15780,7 @@
     12382@@ -15402,7 +15809,7 @@
    1210012383   cf_cv_type_of_bool=unknown
    1210112384 else
    1210212385   cat >conftest.$ac_ext <<_ACEOF
    1210312386-#line 15405 "configure"
    12104 +#line 15783 "configure"
     12387+#line 15812 "configure"
    1210512388 #include "confdefs.h"
    1210612389 
    1210712390 #include <stdlib.h>
    12108 @@ -15444,15 +15822,15 @@
     12391@@ -15444,15 +15851,15 @@
    1210912392 
    1211012393 _ACEOF
    1211112394 rm -f conftest$ac_exeext
    1211212395-if { (eval echo "$as_me:15447: \"$ac_link\"") >&5
    12113 +if { (eval echo "$as_me:15825: \"$ac_link\"") >&5
     12396+if { (eval echo "$as_me:15854: \"$ac_link\"") >&5
    1211412397   (eval $ac_link) 2>&5
    1211512398   ac_status=$?
    1211612399-  echo "$as_me:15450: \$? = $ac_status" >&5
    12117 +  echo "$as_me:15828: \$? = $ac_status" >&5
     12400+  echo "$as_me:15857: \$? = $ac_status" >&5
    1211812401   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    1211912402-  { (eval echo "$as_me:15452: \"$ac_try\"") >&5
    12120 +  { (eval echo "$as_me:15830: \"$ac_try\"") >&5
     12403+  { (eval echo "$as_me:15859: \"$ac_try\"") >&5
    1212112404   (eval $ac_try) 2>&5
    1212212405   ac_status=$?
    1212312406-  echo "$as_me:15455: \$? = $ac_status" >&5
    12124 +  echo "$as_me:15833: \$? = $ac_status" >&5
     12407+  echo "$as_me:15862: \$? = $ac_status" >&5
    1212512408   (exit $ac_status); }; }; then
    1212612409   cf_cv_type_of_bool=`cat cf_test.out`
    1212712410                 if test -z "$cf_cv_type_of_bool"; then
    12128 @@ -15470,18 +15848,18 @@
     12411@@ -15470,18 +15877,18 @@
    1212912412 fi
    1213012413 
    1213112414        rm -f cf_test.out
    1213212415-echo "$as_me:15473: result: $cf_cv_type_of_bool" >&5
    12133 +echo "$as_me:15851: result: $cf_cv_type_of_bool" >&5
     12416+echo "$as_me:15880: result: $cf_cv_type_of_bool" >&5
    1213412417 echo "${ECHO_T}$cf_cv_type_of_bool" >&6
    1213512418 if test "$cf_cv_type_of_bool" = unknown ; then
     
    1213812421        esac
    1213912422-       { echo "$as_me:15479: WARNING: Assuming $NCURSES_BOOL for type of bool" >&5
    12140 +       { echo "$as_me:15857: WARNING: Assuming $NCURSES_BOOL for type of bool" >&5
     12423+       { echo "$as_me:15886: WARNING: Assuming $NCURSES_BOOL for type of bool" >&5
    1214112424 echo "$as_me: WARNING: Assuming $NCURSES_BOOL for type of bool" >&2;}
    1214212425        cf_cv_type_of_bool=$NCURSES_BOOL
     
    1214412427 
    1214512428-echo "$as_me:15484: checking for special defines needed for etip.h" >&5
    12146 +echo "$as_me:15862: checking for special defines needed for etip.h" >&5
     12429+echo "$as_me:15891: checking for special defines needed for etip.h" >&5
    1214712430 echo $ECHO_N "checking for special defines needed for etip.h... $ECHO_C" >&6
    1214812431 cf_save_CXXFLAGS="$CXXFLAGS"
    1214912432 cf_result="none"
    12150 @@ -15493,7 +15871,7 @@
     12433@@ -15493,7 +15900,7 @@
    1215112434        test -n "$cf_math" && CXXFLAGS="$CXXFLAGS -DETIP_NEEDS_${cf_math}"
    1215212435        test -n "$cf_excp" && CXXFLAGS="$CXXFLAGS -DETIP_NEEDS_${cf_excp}"
    1215312436 cat >conftest.$ac_ext <<_ACEOF
    1215412437-#line 15496 "configure"
    12155 +#line 15874 "configure"
     12438+#line 15903 "configure"
    1215612439 #include "confdefs.h"
    1215712440 
    1215812441 #include <etip.h.in>
    12159 @@ -15507,16 +15885,16 @@
     12442@@ -15507,16 +15914,16 @@
    1216012443 }
    1216112444 _ACEOF
    1216212445 rm -f conftest.$ac_objext
    1216312446-if { (eval echo "$as_me:15510: \"$ac_compile\"") >&5
    12164 +if { (eval echo "$as_me:15888: \"$ac_compile\"") >&5
     12447+if { (eval echo "$as_me:15917: \"$ac_compile\"") >&5
    1216512448   (eval $ac_compile) 2>&5
    1216612449   ac_status=$?
    1216712450-  echo "$as_me:15513: \$? = $ac_status" >&5
    12168 +  echo "$as_me:15891: \$? = $ac_status" >&5
     12451+  echo "$as_me:15920: \$? = $ac_status" >&5
    1216912452   (exit $ac_status); } &&
    1217012453          { ac_try='test -s conftest.$ac_objext'
    1217112454-  { (eval echo "$as_me:15516: \"$ac_try\"") >&5
    12172 +  { (eval echo "$as_me:15894: \"$ac_try\"") >&5
     12455+  { (eval echo "$as_me:15923: \"$ac_try\"") >&5
    1217312456   (eval $ac_try) 2>&5
    1217412457   ac_status=$?
    1217512458-  echo "$as_me:15519: \$? = $ac_status" >&5
    12176 +  echo "$as_me:15897: \$? = $ac_status" >&5
     12459+  echo "$as_me:15926: \$? = $ac_status" >&5
    1217712460   (exit $ac_status); }; }; then
    1217812461 
    1217912462        test -n "$cf_math" && cat >>confdefs.h <<EOF
    12180 @@ -15537,12 +15915,12 @@
     12463@@ -15537,12 +15944,12 @@
    1218112464 rm -f conftest.$ac_objext conftest.$ac_ext
    1218212465 done
    1218312466 done
    1218412467-echo "$as_me:15540: result: $cf_result" >&5
    12185 +echo "$as_me:15918: result: $cf_result" >&5
     12468+echo "$as_me:15947: result: $cf_result" >&5
    1218612469 echo "${ECHO_T}$cf_result" >&6
    1218712470 CXXFLAGS="$cf_save_CXXFLAGS"
     
    1218912472 if test -n "$CXX"; then
    1219012473-echo "$as_me:15545: checking if $CXX accepts parameter initialization" >&5
    12191 +echo "$as_me:15923: checking if $CXX accepts parameter initialization" >&5
     12474+echo "$as_me:15952: checking if $CXX accepts parameter initialization" >&5
    1219212475 echo $ECHO_N "checking if $CXX accepts parameter initialization... $ECHO_C" >&6
    1219312476 if test "${cf_cv_cpp_param_init+set}" = set; then
    1219412477   echo $ECHO_N "(cached) $ECHO_C" >&6
    12195 @@ -15559,7 +15937,7 @@
     12478@@ -15559,7 +15966,7 @@
    1219612479   cf_cv_cpp_param_init=unknown
    1219712480 else
    1219812481   cat >conftest.$ac_ext <<_ACEOF
    1219912482-#line 15562 "configure"
    12200 +#line 15940 "configure"
     12483+#line 15969 "configure"
    1220112484 #include "confdefs.h"
    1220212485 
    1220312486 class TEST {
    12204 @@ -15578,15 +15956,15 @@
     12487@@ -15578,15 +15985,15 @@
    1220512488 
    1220612489 _ACEOF
    1220712490 rm -f conftest$ac_exeext
    1220812491-if { (eval echo "$as_me:15581: \"$ac_link\"") >&5
    12209 +if { (eval echo "$as_me:15959: \"$ac_link\"") >&5
     12492+if { (eval echo "$as_me:15988: \"$ac_link\"") >&5
    1221012493   (eval $ac_link) 2>&5
    1221112494   ac_status=$?
    1221212495-  echo "$as_me:15584: \$? = $ac_status" >&5
    12213 +  echo "$as_me:15962: \$? = $ac_status" >&5
     12496+  echo "$as_me:15991: \$? = $ac_status" >&5
    1221412497   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    1221512498-  { (eval echo "$as_me:15586: \"$ac_try\"") >&5
    12216 +  { (eval echo "$as_me:15964: \"$ac_try\"") >&5
     12499+  { (eval echo "$as_me:15993: \"$ac_try\"") >&5
    1221712500   (eval $ac_try) 2>&5
    1221812501   ac_status=$?
    1221912502-  echo "$as_me:15589: \$? = $ac_status" >&5
    12220 +  echo "$as_me:15967: \$? = $ac_status" >&5
     12503+  echo "$as_me:15996: \$? = $ac_status" >&5
    1222112504   (exit $ac_status); }; }; then
    1222212505   cf_cv_cpp_param_init=yes
    1222312506 else
    12224 @@ -15605,7 +15983,7 @@
     12507@@ -15605,7 +16012,7 @@
    1222512508 ac_main_return=return
    1222612509 
    1222712510 fi
    1222812511-echo "$as_me:15608: result: $cf_cv_cpp_param_init" >&5
    12229 +echo "$as_me:15986: result: $cf_cv_cpp_param_init" >&5
     12512+echo "$as_me:16015: result: $cf_cv_cpp_param_init" >&5
    1223012513 echo "${ECHO_T}$cf_cv_cpp_param_init" >&6
    1223112514 fi
    1223212515 test "$cf_cv_cpp_param_init" = yes && cat >>confdefs.h <<\EOF
    12233 @@ -15614,7 +15992,7 @@
     12516@@ -15614,7 +16021,7 @@
    1223412517 
    1223512518 if test -n "$CXX"; then
    1223612519 
    1223712520-echo "$as_me:15617: checking if $CXX accepts static_cast" >&5
    12238 +echo "$as_me:15995: checking if $CXX accepts static_cast" >&5
     12521+echo "$as_me:16024: checking if $CXX accepts static_cast" >&5
    1223912522 echo $ECHO_N "checking if $CXX accepts static_cast... $ECHO_C" >&6
    1224012523 if test "${cf_cv_cpp_static_cast+set}" = set; then
    1224112524   echo $ECHO_N "(cached) $ECHO_C" >&6
    12242 @@ -15628,7 +16006,7 @@
     12525@@ -15628,7 +16035,7 @@
    1224312526 ac_main_return=return
    1224412527 
    1224512528        cat >conftest.$ac_ext <<_ACEOF
    1224612529-#line 15631 "configure"
    12247 +#line 16009 "configure"
     12530+#line 16038 "configure"
    1224812531 #include "confdefs.h"
    1224912532 
    1225012533 class NCursesPanel
    12251 @@ -15672,16 +16050,16 @@
     12534@@ -15672,16 +16079,16 @@
    1225212535 }
    1225312536 _ACEOF
    1225412537 rm -f conftest.$ac_objext
    1225512538-if { (eval echo "$as_me:15675: \"$ac_compile\"") >&5
    12256 +if { (eval echo "$as_me:16053: \"$ac_compile\"") >&5
     12539+if { (eval echo "$as_me:16082: \"$ac_compile\"") >&5
    1225712540   (eval $ac_compile) 2>&5
    1225812541   ac_status=$?
    1225912542-  echo "$as_me:15678: \$? = $ac_status" >&5
    12260 +  echo "$as_me:16056: \$? = $ac_status" >&5
     12543+  echo "$as_me:16085: \$? = $ac_status" >&5
    1226112544   (exit $ac_status); } &&
    1226212545          { ac_try='test -s conftest.$ac_objext'
    1226312546-  { (eval echo "$as_me:15681: \"$ac_try\"") >&5
    12264 +  { (eval echo "$as_me:16059: \"$ac_try\"") >&5
     12547+  { (eval echo "$as_me:16088: \"$ac_try\"") >&5
    1226512548   (eval $ac_try) 2>&5
    1226612549   ac_status=$?
    1226712550-  echo "$as_me:15684: \$? = $ac_status" >&5
    12268 +  echo "$as_me:16062: \$? = $ac_status" >&5
     12551+  echo "$as_me:16091: \$? = $ac_status" >&5
    1226912552   (exit $ac_status); }; }; then
    1227012553   cf_cv_cpp_static_cast=yes
    1227112554 else
    12272 @@ -15699,7 +16077,7 @@
     12555@@ -15699,7 +16106,7 @@
    1227312556 ac_main_return=return
    1227412557 
    1227512558 fi
    1227612559-echo "$as_me:15702: result: $cf_cv_cpp_static_cast" >&5
    12277 +echo "$as_me:16080: result: $cf_cv_cpp_static_cast" >&5
     12560+echo "$as_me:16109: result: $cf_cv_cpp_static_cast" >&5
    1227812561 echo "${ECHO_T}$cf_cv_cpp_static_cast" >&6
    1227912562 
    1228012563 fi
    12281 @@ -15709,12 +16087,12 @@
     12564@@ -15709,12 +16116,12 @@
    1228212565 EOF
    1228312566 
     
    1229412577            ;;
    1229512578        sco3.2v5*) #(vi
    12296 @@ -15723,7 +16101,7 @@
     12579@@ -15723,7 +16130,7 @@
    1229712580        solaris2*)
    1229812581            if test "$GXX" != yes ; then
     
    1230312586            ;;
    1230412587        esac
    12305 @@ -15747,7 +16125,7 @@
     12588@@ -15747,7 +16154,7 @@
    1230612589        else
    1230712590                if test "$cf_cv_header_stdbool_h" = 1 ; then
    1230812591 
    1230912592-echo "$as_me:15750: checking for size of bool" >&5
    12310 +echo "$as_me:16128: checking for size of bool" >&5
     12593+echo "$as_me:16157: checking for size of bool" >&5
    1231112594 echo $ECHO_N "checking for size of bool... $ECHO_C" >&6
    1231212595 if test "${cf_cv_type_of_bool+set}" = set; then
    1231312596   echo $ECHO_N "(cached) $ECHO_C" >&6
    12314 @@ -15758,7 +16136,7 @@
     12597@@ -15758,7 +16165,7 @@
    1231512598   cf_cv_type_of_bool=unknown
    1231612599 else
    1231712600   cat >conftest.$ac_ext <<_ACEOF
    1231812601-#line 15761 "configure"
    12319 +#line 16139 "configure"
     12602+#line 16168 "configure"
    1232012603 #include "confdefs.h"
    1232112604 
    1232212605 #include <stdlib.h>
    12323 @@ -15800,15 +16178,15 @@
     12606@@ -15800,15 +16207,15 @@
    1232412607 
    1232512608 _ACEOF
    1232612609 rm -f conftest$ac_exeext
    1232712610-if { (eval echo "$as_me:15803: \"$ac_link\"") >&5
    12328 +if { (eval echo "$as_me:16181: \"$ac_link\"") >&5
     12611+if { (eval echo "$as_me:16210: \"$ac_link\"") >&5
    1232912612   (eval $ac_link) 2>&5
    1233012613   ac_status=$?
    1233112614-  echo "$as_me:15806: \$? = $ac_status" >&5
    12332 +  echo "$as_me:16184: \$? = $ac_status" >&5
     12615+  echo "$as_me:16213: \$? = $ac_status" >&5
    1233312616   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
    1233412617-  { (eval echo "$as_me:15808: \"$ac_try\"") >&5
    12335 +  { (eval echo "$as_me:16186: \"$ac_try\"") >&5
     12618+  { (eval echo "$as_me:16215: \"$ac_try\"") >&5
    1233612619   (eval $ac_try) 2>&5
    1233712620   ac_status=$?
    1233812621-  echo "$as_me:15811: \$? = $ac_status" >&5
    12339 +  echo "$as_me:16189: \$? = $ac_status" >&5
     12622+  echo "$as_me:16218: \$? = $ac_status" >&5
    1234012623   (exit $ac_status); }; }; then
    1234112624   cf_cv_type_of_bool=`cat cf_test.out`
    1234212625                 if test -z "$cf_cv_type_of_bool"; then
    12343 @@ -15826,25 +16204,25 @@
     12626@@ -15826,25 +16233,25 @@
    1234412627 fi
    1234512628 
    1234612629        rm -f cf_test.out
    1234712630-echo "$as_me:15829: result: $cf_cv_type_of_bool" >&5
    12348 +echo "$as_me:16207: result: $cf_cv_type_of_bool" >&5
     12631+echo "$as_me:16236: result: $cf_cv_type_of_bool" >&5
    1234912632 echo "${ECHO_T}$cf_cv_type_of_bool" >&6
    1235012633 if test "$cf_cv_type_of_bool" = unknown ; then
     
    1235312636        esac
    1235412637-       { echo "$as_me:15835: WARNING: Assuming $NCURSES_BOOL for type of bool" >&5
    12355 +       { echo "$as_me:16213: WARNING: Assuming $NCURSES_BOOL for type of bool" >&5
     12638+       { echo "$as_me:16242: WARNING: Assuming $NCURSES_BOOL for type of bool" >&5
    1235612639 echo "$as_me: WARNING: Assuming $NCURSES_BOOL for type of bool" >&2;}
    1235712640        cf_cv_type_of_bool=$NCURSES_BOOL
     
    1236012643                else
    1236112644-                       echo "$as_me:15841: checking for fallback type of bool" >&5
    12362 +                       echo "$as_me:16219: checking for fallback type of bool" >&5
     12645+                       echo "$as_me:16248: checking for fallback type of bool" >&5
    1236312646 echo $ECHO_N "checking for fallback type of bool... $ECHO_C" >&6
    1236412647                        case "$host_cpu" in #(vi
     
    1236712650                        esac
    1236812651-                       echo "$as_me:15847: result: $cf_cv_type_of_bool" >&5
    12369 +                       echo "$as_me:16225: result: $cf_cv_type_of_bool" >&5
     12652+                       echo "$as_me:16254: result: $cf_cv_type_of_bool" >&5
    1237012653 echo "${ECHO_T}$cf_cv_type_of_bool" >&6
    1237112654                fi
    1237212655        fi
    12373 @@ -15873,7 +16251,7 @@
     12656@@ -15873,7 +16280,7 @@
    1237412657 
    1237512658 if test "$cf_with_ada" != "no" ; then
    1237612659     if test "$with_libtool" != "no"; then
    1237712660-       { echo "$as_me:15876: WARNING: libtool does not support Ada - disabling feature" >&5
    12378 +       { echo "$as_me:16254: WARNING: libtool does not support Ada - disabling feature" >&5
     12661+       { echo "$as_me:16283: WARNING: libtool does not support Ada - disabling feature" >&5
    1237912662 echo "$as_me: WARNING: libtool does not support Ada - disabling feature" >&2;}
    1238012663        cf_with_ada=no
    1238112664     fi
    12382 @@ -15883,7 +16261,7 @@
     12665@@ -15883,7 +16290,7 @@
    1238312666 cf_ada_make=gnatmake
    1238412667 # Extract the first word of "$cf_ada_make", so it can be a program name with args.
    1238512668 set dummy $cf_ada_make; ac_word=$2
    1238612669-echo "$as_me:15886: checking for $ac_word" >&5
    12387 +echo "$as_me:16264: checking for $ac_word" >&5
     12670+echo "$as_me:16293: checking for $ac_word" >&5
    1238812671 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    1238912672 if test "${ac_cv_prog_gnat_exists+set}" = set; then
    1239012673   echo $ECHO_N "(cached) $ECHO_C" >&6
    12391 @@ -15898,7 +16276,7 @@
     12674@@ -15898,7 +16305,7 @@
    1239212675   test -z "$ac_dir" && ac_dir=.
    1239312676   $as_executable_p "$ac_dir/$ac_word" || continue
    1239412677 ac_cv_prog_gnat_exists="yes"
    1239512678-echo "$as_me:15901: found $ac_dir/$ac_word" >&5
    12396 +echo "$as_me:16279: found $ac_dir/$ac_word" >&5
     12679+echo "$as_me:16308: found $ac_dir/$ac_word" >&5
    1239712680 break
    1239812681 done
    1239912682 
    12400 @@ -15907,10 +16285,10 @@
     12683@@ -15907,10 +16314,10 @@
    1240112684 fi
    1240212685 gnat_exists=$ac_cv_prog_gnat_exists
    1240312686 if test -n "$gnat_exists"; then
    1240412687-  echo "$as_me:15910: result: $gnat_exists" >&5
    12405 +  echo "$as_me:16288: result: $gnat_exists" >&5
     12688+  echo "$as_me:16317: result: $gnat_exists" >&5
    1240612689 echo "${ECHO_T}$gnat_exists" >&6
    1240712690 else
    1240812691-  echo "$as_me:15913: result: no" >&5
    12409 +  echo "$as_me:16291: result: no" >&5
     12692+  echo "$as_me:16320: result: no" >&5
    1241012693 echo "${ECHO_T}no" >&6
    1241112694 fi
    1241212695 
    12413 @@ -15918,11 +16296,11 @@
     12696@@ -15918,11 +16325,11 @@
    1241412697    cf_ada_make=
    1241512698 else
    1241612699 
    1241712700-echo "$as_me:15921: checking for gnat version" >&5
    12418 +echo "$as_me:16299: checking for gnat version" >&5
     12701+echo "$as_me:16328: checking for gnat version" >&5
    1241912702 echo $ECHO_N "checking for gnat version... $ECHO_C" >&6
    1242012703 cf_gnat_version=`${cf_ada_make-gnatmake} -v 2>&1 | grep '[0-9].[0-9][0-9]*' |\
    1242112704   sed -e '2,$d' -e 's/[^0-9 \.]//g' -e 's/^[ ]*//' -e 's/ .*//'`
    1242212705-echo "$as_me:15925: result: $cf_gnat_version" >&5
    12423 +echo "$as_me:16303: result: $cf_gnat_version" >&5
     12706+echo "$as_me:16332: result: $cf_gnat_version" >&5
    1242412707 echo "${ECHO_T}$cf_gnat_version" >&6
    1242512708 
    1242612709 case $cf_gnat_version in
    12427 @@ -15945,7 +16323,7 @@
     12710@@ -15945,7 +16352,7 @@
    1242812711 
    1242912712    # Extract the first word of "m4", so it can be a program name with args.
    1243012713 set dummy m4; ac_word=$2
    1243112714-echo "$as_me:15948: checking for $ac_word" >&5
    12432 +echo "$as_me:16326: checking for $ac_word" >&5
     12715+echo "$as_me:16355: checking for $ac_word" >&5
    1243312716 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6
    1243412717 if test "${ac_cv_prog_M4_exists+set}" = set; then
    1243512718   echo $ECHO_N "(cached) $ECHO_C" >&6
    12436 @@ -15960,7 +16338,7 @@
     12719@@ -15960,7 +16367,7 @@
    1243712720   test -z "$ac_dir" && ac_dir=.
    1243812721   $as_executable_p "$ac_dir/$ac_word" || continue
    1243912722 ac_cv_prog_M4_exists="yes"
    1244012723-echo "$as_me:15963: found $ac_dir/$ac_word" >&5
    12441 +echo "$as_me:16341: found $ac_dir/$ac_word" >&5
     12724+echo "$as_me:16370: found $ac_dir/$ac_word" >&5
    1244212725 break
    1244312726 done
    1244412727 
    12445 @@ -15969,10 +16347,10 @@
     12728@@ -15969,10 +16376,10 @@
    1244612729 fi
    1244712730 M4_exists=$ac_cv_prog_M4_exists
    1244812731 if test -n "$M4_exists"; then
    1244912732-  echo "$as_me:15972: result: $M4_exists" >&5
    12450 +  echo "$as_me:16350: result: $M4_exists" >&5
     12733+  echo "$as_me:16379: result: $M4_exists" >&5
    1245112734 echo "${ECHO_T}$M4_exists" >&6
    1245212735 else
    1245312736-  echo "$as_me:15975: result: no" >&5
    12454 +  echo "$as_me:16353: result: no" >&5
     12737+  echo "$as_me:16382: result: no" >&5
    1245512738 echo "${ECHO_T}no" >&6
    1245612739 fi
    1245712740 
    12458 @@ -15981,7 +16359,7 @@
     12741@@ -15981,7 +16388,7 @@
    1245912742       echo Ada95 binding required program m4 not found. Ada95 binding disabled.
    1246012743    fi
    1246112744    if test "$cf_cv_prog_gnat_correct" = yes; then
    1246212745-      echo "$as_me:15984: checking if GNAT works" >&5
    12463 +      echo "$as_me:16362: checking if GNAT works" >&5
     12746+      echo "$as_me:16391: checking if GNAT works" >&5
    1246412747 echo $ECHO_N "checking if GNAT works... $ECHO_C" >&6
    1246512748 
    1246612749 rm -f conftest*
    12467 @@ -16009,14 +16387,14 @@
     12750@@ -16009,14 +16416,14 @@
    1246812751 fi
    1246912752 rm -f conftest*
    1247012753 
    1247112754-      echo "$as_me:16012: result: $cf_cv_prog_gnat_correct" >&5
    12472 +      echo "$as_me:16390: result: $cf_cv_prog_gnat_correct" >&5
     12755+      echo "$as_me:16419: result: $cf_cv_prog_gnat_correct" >&5
    1247312756 echo "${ECHO_T}$cf_cv_prog_gnat_correct" >&6
    1247412757    fi
     
    1247812761 
    1247912762-   echo "$as_me:16019: checking if GNAT pragma Unreferenced works" >&5
    12480 +   echo "$as_me:16397: checking if GNAT pragma Unreferenced works" >&5
     12763+   echo "$as_me:16426: checking if GNAT pragma Unreferenced works" >&5
    1248112764 echo $ECHO_N "checking if GNAT pragma Unreferenced works... $ECHO_C" >&6
    1248212765 
    1248312766 rm -f conftest*
    12484 @@ -16043,7 +16421,7 @@
     12767@@ -16043,7 +16450,7 @@
    1248512768 fi
    1248612769 rm -f conftest*
    1248712770 
    1248812771-   echo "$as_me:16046: result: $cf_cv_pragma_unreferenced" >&5
    12489 +   echo "$as_me:16424: result: $cf_cv_pragma_unreferenced" >&5
     12772+   echo "$as_me:16453: result: $cf_cv_pragma_unreferenced" >&5
    1249012773 echo "${ECHO_T}$cf_cv_pragma_unreferenced" >&6
    1249112774 
    1249212775    # if the pragma is supported, use it (needed in the Trace code).
    12493 @@ -16096,7 +16474,7 @@
     12776@@ -16096,7 +16503,7 @@
    1249412777   withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
    1249512778   ;;
    1249612779 *)
    1249712780-  { { echo "$as_me:16099: error: expected a pathname, not \"$withval\"" >&5
    12498 +  { { echo "$as_me:16477: error: expected a pathname, not \"$withval\"" >&5
     12781+  { { echo "$as_me:16506: error: expected a pathname, not \"$withval\"" >&5
    1249912782 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
    1250012783    { (exit 1); exit 1; }; }
    1250112784   ;;
    12502 @@ -16138,7 +16516,7 @@
     12785@@ -16138,7 +16545,7 @@
    1250312786   withval=`echo $withval | sed -e s%NONE%$cf_path_syntax%`
    1250412787   ;;
    1250512788 *)
    1250612789-  { { echo "$as_me:16141: error: expected a pathname, not \"$withval\"" >&5
    12507 +  { { echo "$as_me:16519: error: expected a pathname, not \"$withval\"" >&5
     12790+  { { echo "$as_me:16548: error: expected a pathname, not \"$withval\"" >&5
    1250812791 echo "$as_me: error: expected a pathname, not \"$withval\"" >&2;}
    1250912792    { (exit 1); exit 1; }; }
    1251012793   ;;
    12511 @@ -16163,7 +16541,7 @@
     12794@@ -16163,7 +16570,7 @@
    1251212795 ### chooses to split module lists into libraries.
    1251312796 ###
    1251412797 ### (see CF_LIB_RULES).
    1251512798-echo "$as_me:16166: checking for library subsets" >&5
    12516 +echo "$as_me:16544: checking for library subsets" >&5
     12799+echo "$as_me:16573: checking for library subsets" >&5
    1251712800 echo $ECHO_N "checking for library subsets... $ECHO_C" >&6
    1251812801 LIB_SUBSETS=
    1251912802 
    12520 @@ -16176,7 +16554,17 @@
     12803@@ -16176,7 +16583,17 @@
    1252112804        fi
    1252212805 fi
     
    1253712820 if test "$with_termlib" != no ; then
    1253812821        LIB_SUBSETS="${LIB_SUBSETS} "
    12539 @@ -16185,17 +16573,18 @@
     12822@@ -16185,17 +16602,18 @@
    1254012823 fi
    1254112824 
     
    1254612829 
    1254712830-echo "$as_me:16191: result: $LIB_SUBSETS" >&5
    12548 +echo "$as_me:16580: result: $LIB_SUBSETS" >&5
     12831+echo "$as_me:16609: result: $LIB_SUBSETS" >&5
    1254912832 echo "${ECHO_T}$LIB_SUBSETS" >&6
    1255012833 
     
    1255912842 if test "$GCC" != yes; then
    1256012843        CPPFLAGS="$CPPFLAGS -I\${includedir}"
    12561 @@ -16226,7 +16615,7 @@
     12844@@ -16226,7 +16644,7 @@
    1256212845 fi
    1256312846 
    1256412847 ### Build up pieces for makefile rules
    1256512848-echo "$as_me:16229: checking default library suffix" >&5
    12566 +echo "$as_me:16618: checking default library suffix" >&5
     12849+echo "$as_me:16647: checking default library suffix" >&5
    1256712850 echo $ECHO_N "checking default library suffix... $ECHO_C" >&6
    1256812851 
    1256912852        case $DFT_LWR_MODEL in
    12570 @@ -16237,46 +16626,50 @@
     12853@@ -16237,46 +16655,50 @@
    1257112854        shared)  DFT_ARG_SUFFIX=''   ;;
    1257212855        esac
    1257312856        test -n "$LIB_SUFFIX" && DFT_ARG_SUFFIX="${LIB_SUFFIX}${DFT_ARG_SUFFIX}"
    1257412857-echo "$as_me:16240: result: $DFT_ARG_SUFFIX" >&5
    12575 +echo "$as_me:16629: result: $DFT_ARG_SUFFIX" >&5
     12858+echo "$as_me:16658: result: $DFT_ARG_SUFFIX" >&5
    1257612859 echo "${ECHO_T}$DFT_ARG_SUFFIX" >&6
    1257712860 
    1257812861-echo "$as_me:16243: checking default library-dependency suffix" >&5
    12579 +echo "$as_me:16632: checking default library-dependency suffix" >&5
     12862+echo "$as_me:16661: checking default library-dependency suffix" >&5
    1258012863 echo $ECHO_N "checking default library-dependency suffix... $ECHO_C" >&6
    1258112864 
     
    1263212915                                DFT_DEP_SUFFIX=$DFT_LIB_SUFFIX
    1263312916                                ;;
    12634 @@ -16289,10 +16682,10 @@
     12917@@ -16289,10 +16711,10 @@
    1263512918        esac
    1263612919        test -n "$LIB_SUFFIX" && DFT_LIB_SUFFIX="${LIB_SUFFIX}${DFT_LIB_SUFFIX}"
    1263712920        test -n "$LIB_SUFFIX" && DFT_DEP_SUFFIX="${LIB_SUFFIX}${DFT_DEP_SUFFIX}"
    1263812921-echo "$as_me:16292: result: $DFT_DEP_SUFFIX" >&5
    12639 +echo "$as_me:16685: result: $DFT_DEP_SUFFIX" >&5
     12922+echo "$as_me:16714: result: $DFT_DEP_SUFFIX" >&5
    1264012923 echo "${ECHO_T}$DFT_DEP_SUFFIX" >&6
    1264112924 
    1264212925-echo "$as_me:16295: checking default object directory" >&5
    12643 +echo "$as_me:16688: checking default object directory" >&5
     12926+echo "$as_me:16717: checking default object directory" >&5
    1264412927 echo $ECHO_N "checking default object directory... $ECHO_C" >&6
    1264512928 
    1264612929        case $DFT_LWR_MODEL in
    12647 @@ -16308,51 +16701,55 @@
     12930@@ -16308,51 +16730,55 @@
    1264812931                        DFT_OBJ_SUBDIR='obj_s' ;;
    1264912932                esac
    1265012933        esac
    1265112934-echo "$as_me:16311: result: $DFT_OBJ_SUBDIR" >&5
    12652 +echo "$as_me:16704: result: $DFT_OBJ_SUBDIR" >&5
     12935+echo "$as_me:16733: result: $DFT_OBJ_SUBDIR" >&5
    1265312936 echo "${ECHO_T}$DFT_OBJ_SUBDIR" >&6
    1265412937 
     
    1265612939 if test "$cf_with_cxx" = yes ; then
    1265712940-echo "$as_me:16316: checking c++ library-dependency suffix" >&5
    12658 +echo "$as_me:16709: checking c++ library-dependency suffix" >&5
     12941+echo "$as_me:16738: checking c++ library-dependency suffix" >&5
    1265912942 echo $ECHO_N "checking c++ library-dependency suffix... $ECHO_C" >&6
    1266012943 if test "$with_libtool" != "no"; then
     
    1271412997                                CXX_DEP_SUFFIX=$CXX_LIB_SUFFIX
    1271512998                                ;;
    12716 @@ -16366,7 +16763,7 @@
     12999@@ -16366,7 +16792,7 @@
    1271713000        test -n "$LIB_SUFFIX" && CXX_LIB_SUFFIX="${LIB_SUFFIX}${CXX_LIB_SUFFIX}"
    1271813001        test -n "$LIB_SUFFIX" && CXX_DEP_SUFFIX="${LIB_SUFFIX}${CXX_DEP_SUFFIX}"
    1271913002 fi
    1272013003-echo "$as_me:16369: result: $CXX_LIB_SUFFIX" >&5
    12721 +echo "$as_me:16766: result: $CXX_LIB_SUFFIX" >&5
     13004+echo "$as_me:16795: result: $CXX_LIB_SUFFIX" >&5
    1272213005 echo "${ECHO_T}$CXX_LIB_SUFFIX" >&6
    1272313006 
    1272413007 fi
    12725 @@ -16480,7 +16877,7 @@
     13008@@ -16431,6 +16857,8 @@
     13009                TEST_ARGS="${TEST_DEPS}"
     13010                TEST_ARG2="${TEST_DEP2}"
     13011                TINFO_ARGS="-L${LIB_DIR} $TEST_ARGS"
     13012+               TICS_LIST="$SHLIB_LIST $TEST_ARGS"
     13013+               SHLIB_LIST="${SHLIB_LIST} $TEST_ARGS"
     13014        else
     13015                TEST_ARGS="-l${TINFO_ARG_SUFFIX}"
     13016                TEST_ARG2="-l${TINFO_ARG_SUFFIX}"
     13017@@ -16480,7 +16908,7 @@
    1272613018 
    1272713019 if test "$GCC" = yes ; then
    1272813020        case $cf_cv_system_name in #(
    1272913021-       OS/2*|os2*|aix[45]*)    #( vi
    12730 +       OS/2*|os2*|aix[4]*)     #( vi
     13022+       OS/2*|os2*|aix[4]*|solaris2.1[0-9]|darwin*)     #( vi
    1273113023                LDFLAGS_STATIC=
    1273213024                LDFLAGS_SHARED=
    1273313025                ;;
    12734 @@ -16491,7 +16888,7 @@
     13026@@ -16491,7 +16919,7 @@
    1273513027     esac
    1273613028 else
     
    1274113033                LDFLAGS_SHARED=-bdynamic
    1274213034                ;;
    12743 @@ -16519,12 +16916,12 @@
     13035@@ -16519,12 +16947,12 @@
    1274413036        ;;
    1274513037 esac
    1274613038 
    1274713039-echo "$as_me:16522: checking where we will install curses.h" >&5
    12748 +echo "$as_me:16919: checking where we will install curses.h" >&5
     13040+echo "$as_me:16950: checking where we will install curses.h" >&5
    1274913041 echo $ECHO_N "checking where we will install curses.h... $ECHO_C" >&6
    1275013042 test "$with_overwrite" = no && \
     
    1275213044        includedir='${prefix}/include/ncurses'${LIB_SUFFIX}
    1275313045-echo "$as_me:16527: result: $includedir" >&5
    12754 +echo "$as_me:16924: result: $includedir" >&5
     13046+echo "$as_me:16955: result: $includedir" >&5
    1275513047 echo "${ECHO_T}$includedir" >&6
    1275613048 
    1275713049 ### Resolve a conflict between normal and wide-curses by forcing applications
    12758 @@ -16532,10 +16929,11 @@
     13050@@ -16532,10 +16960,11 @@
    1275913051 if test "$with_overwrite" != no ; then
    1276013052 if test "$NCURSES_LIBUTF8" = 1 ; then
    1276113053        NCURSES_LIBUTF8='defined(HAVE_LIBUTF8_H)'
    1276213054-       { echo "$as_me:16535: WARNING: Wide-character applications must define HAVE_LIBUTF8_H to include curses.h" >&5
    12763 +       { echo "$as_me:16932: WARNING: Wide-character applications must define HAVE_LIBUTF8_H to include curses.h" >&5
     13055+       { echo "$as_me:16963: WARNING: Wide-character applications must define HAVE_LIBUTF8_H to include curses.h" >&5
    1276413056 echo "$as_me: WARNING: Wide-character applications must define HAVE_LIBUTF8_H to include curses.h" >&2;}
    1276513057 fi
     
    1276913061 # used to separate tack out of the tree
    1277013062 NCURSES_TREE=
    12771 @@ -16548,7 +16946,7 @@
     13063@@ -16548,7 +16977,7 @@
    1277213064 ### Construct the list of subdirectories for which we'll customize makefiles
    1277313065 ### with the appropriate compile-rules.
    1277413066 
    1277513067-echo "$as_me:16551: checking for src modules" >&5
    12776 +echo "$as_me:16949: checking for src modules" >&5
     13068+echo "$as_me:16980: checking for src modules" >&5
    1277713069 echo $ECHO_N "checking for src modules... $ECHO_C" >&6
    1277813070 
    1277913071 # dependencies and linker-arguments for test-programs
    12780 @@ -16611,13 +17009,17 @@
     13072@@ -16611,13 +17040,17 @@
    1278113073                fi
    1278213074        fi
    1278313075 done
    1278413076-echo "$as_me:16614: result: $cf_cv_src_modules" >&5
    12785 +echo "$as_me:17012: result: $cf_cv_src_modules" >&5
     13077+echo "$as_me:17043: result: $cf_cv_src_modules" >&5
    1278613078 echo "${ECHO_T}$cf_cv_src_modules" >&6
    1278713079 
     
    1279813090 do
    1279913091        SRC_SUBDIRS="$SRC_SUBDIRS $cf_dir"
    12800 @@ -16628,8 +17030,8 @@
     13092@@ -16628,8 +17061,8 @@
    1280113093 
    1280213094 ADA_SUBDIRS=
     
    1280913101 
    1281013102 SUB_MAKEFILES=
    12811 @@ -16639,15 +17041,15 @@
     13103@@ -16639,15 +17072,15 @@
    1281213104 done
    1281313105 
     
    1283013122 
    1283113123 DIRS_TO_MAKE="lib"
    12832 @@ -16680,7 +17082,7 @@
     13124@@ -16680,7 +17113,7 @@
    1283313125 done
    1283413126 
     
    1283913131 
    1284013132 cat >>confdefs.h <<EOF
    12841 @@ -16749,7 +17151,7 @@
     13133@@ -16749,7 +17182,7 @@
    1284213134 
    1284313135 if test -n "$cf_new_cppflags" ; then
     
    1284813140 
    1284913141 if test -n "$cf_new_extra_cppflags" ; then
    12850 @@ -16760,18 +17162,18 @@
     13142@@ -16760,18 +17193,18 @@
    1285113143 ### If we're building with rpath, try to link non-standard libs that way too.
    1285213144 if test "$DFT_LWR_MODEL" = "shared"; then
    1285313145 
    1285413146-echo "$as_me:16763: checking for updated LDFLAGS" >&5
    12855 +echo "$as_me:17165: checking for updated LDFLAGS" >&5
     13147+echo "$as_me:17196: checking for updated LDFLAGS" >&5
    1285613148 echo $ECHO_N "checking for updated LDFLAGS... $ECHO_C" >&6
    1285713149 if test -n "$LDFLAGS" ; then
    1285813150-echo "$as_me:16766: result: maybe" >&5
    12859 +echo "$as_me:17168: result: maybe" >&5
     13151+echo "$as_me:17199: result: maybe" >&5
    1286013152 echo "${ECHO_T}maybe" >&6
    1286113153 test -n "$verbose" && echo "   ...checking LDFLAGS $LDFLAGS" 1>&6
    1286213154 
    1286313155-echo "${as_me-configure}:16770: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
    12864 +echo "${as_me-configure}:17172: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
     13156+echo "${as_me-configure}:17203: testing ...checking LDFLAGS $LDFLAGS ..." 1>&5
    1286513157 
    1286613158 test -n "$verbose" && echo "   ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
    1286713159 
    1286813160-echo "${as_me-configure}:16774: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
    12869 +echo "${as_me-configure}:17176: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
     13161+echo "${as_me-configure}:17207: testing ...checking EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
    1287013162 
    1287113163 case "$EXTRA_LDFLAGS" in #(vi
    1287213164 -Wl,-rpath,*) #(vi
    12873 @@ -16793,7 +17195,7 @@
     13165@@ -16793,7 +17226,7 @@
    1287413166        do
    1287513167                test -n "$verbose" && echo "    Filtering $cf_rpath_src" 1>&6
    1287613168 
    1287713169-echo "${as_me-configure}:16796: testing Filtering $cf_rpath_src ..." 1>&5
    12878 +echo "${as_me-configure}:17198: testing Filtering $cf_rpath_src ..." 1>&5
     13170+echo "${as_me-configure}:17229: testing Filtering $cf_rpath_src ..." 1>&5
    1287913171 
    1288013172                case $cf_rpath_src in #(vi
    1288113173                -L*) #(vi
    12882 @@ -16804,7 +17206,7 @@
     13174@@ -16804,7 +17237,7 @@
    1288313175                        fi
    1288413176                        test -n "$verbose" && echo "    ...Filter $cf_rpath_tmp" 1>&6
    1288513177 
    1288613178-echo "${as_me-configure}:16807: testing ...Filter $cf_rpath_tmp ..." 1>&5
    12887 +echo "${as_me-configure}:17209: testing ...Filter $cf_rpath_tmp ..." 1>&5
     13179+echo "${as_me-configure}:17240: testing ...Filter $cf_rpath_tmp ..." 1>&5
    1288813180 
    1288913181                        EXTRA_LDFLAGS="$cf_rpath_tmp $EXTRA_LDFLAGS"
    1289013182                        ;;
    12891 @@ -16814,15 +17216,15 @@
     13183@@ -16814,15 +17247,15 @@
    1289213184        LDFLAGS=$cf_rpath_dst
    1289313185        test -n "$verbose" && echo "    ...checked LDFLAGS $LDFLAGS" 1>&6
    1289413186 
    1289513187-echo "${as_me-configure}:16817: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
    12896 +echo "${as_me-configure}:17219: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
     13188+echo "${as_me-configure}:17250: testing ...checked LDFLAGS $LDFLAGS ..." 1>&5
    1289713189 
    1289813190        test -n "$verbose" && echo "    ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS" 1>&6
    1289913191 
    1290013192-echo "${as_me-configure}:16821: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
    12901 +echo "${as_me-configure}:17223: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
     13193+echo "${as_me-configure}:17254: testing ...checked EXTRA_LDFLAGS $EXTRA_LDFLAGS ..." 1>&5
    1290213194 
    1290313195 fi
    1290413196 else
    1290513197-echo "$as_me:16825: result: no" >&5
    12906 +echo "$as_me:17227: result: no" >&5
     13198+echo "$as_me:17258: result: no" >&5
    1290713199 echo "${ECHO_T}no" >&6
    1290813200 fi
    1290913201 
    12910 @@ -16849,8 +17251,18 @@
     13202@@ -16849,8 +17282,18 @@
    1291113203 fi
    1291213204 
     
    1292813220 ac_config_commands="$ac_config_commands default"
    1292913221 cat >confcache <<\_ACEOF
    12930 @@ -16932,7 +17344,7 @@
     13222@@ -16932,7 +17375,7 @@
    1293113223 : ${CONFIG_STATUS=./config.status}
    1293213224 ac_clean_files_save=$ac_clean_files
    1293313225 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
    1293413226-{ echo "$as_me:16935: creating $CONFIG_STATUS" >&5
    12935 +{ echo "$as_me:17347: creating $CONFIG_STATUS" >&5
     13227+{ echo "$as_me:17378: creating $CONFIG_STATUS" >&5
    1293613228 echo "$as_me: creating $CONFIG_STATUS" >&6;}
    1293713229 cat >$CONFIG_STATUS <<_ACEOF
    1293813230 #! $SHELL
    12939 @@ -17064,7 +17476,7 @@
     13231@@ -17064,7 +17507,7 @@
    1294013232 cat >>$CONFIG_STATUS <<EOF
    1294113233 ac_cs_version="\\
     
    1294613238 
    1294713239 Copyright 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001
    12948 @@ -17108,7 +17520,7 @@
     13240@@ -17108,7 +17551,7 @@
    1294913241     echo "$ac_cs_version"; exit 0 ;;
    1295013242   --he | --h)
    1295113243     # Conflict between --help and --header
    1295213244-    { { echo "$as_me:17111: error: ambiguous option: $1
    12953 +    { { echo "$as_me:17523: error: ambiguous option: $1
     13245+    { { echo "$as_me:17554: error: ambiguous option: $1
    1295413246 Try \`$0 --help' for more information." >&5
    1295513247 echo "$as_me: error: ambiguous option: $1
    1295613248 Try \`$0 --help' for more information." >&2;}
    12957 @@ -17127,7 +17539,7 @@
     13249@@ -17127,7 +17570,7 @@
    1295813250     ac_need_defaults=false;;
    1295913251 
    1296013252   # This is an error.
    1296113253-  -*) { { echo "$as_me:17130: error: unrecognized option: $1
    12962 +  -*) { { echo "$as_me:17542: error: unrecognized option: $1
     13254+  -*) { { echo "$as_me:17573: error: unrecognized option: $1
    1296313255 Try \`$0 --help' for more information." >&5
    1296413256 echo "$as_me: error: unrecognized option: $1
    1296513257 Try \`$0 --help' for more information." >&2;}
    12966 @@ -17146,7 +17558,7 @@
     13258@@ -17146,7 +17589,7 @@
    1296713259 ## Running config.status.  ##
    1296813260 ## ----------------------- ##
     
    1297313265   CONFIG_HEADERS  = $CONFIG_HEADERS
    1297413266   CONFIG_LINKS    = $CONFIG_LINKS
    12975 @@ -17181,13 +17593,13 @@
     13267@@ -17181,13 +17624,13 @@
    1297613268 NCURSES_PATCH="$NCURSES_PATCH"
    1297713269 SRC_SUBDIRS="$SRC_SUBDIRS"
     
    1299013282 WITH_ECHO="$with_echo"
    1299113283 WITH_OVERWRITE="$with_overwrite"
    12992 @@ -17206,6 +17618,7 @@
     13284@@ -17206,6 +17649,7 @@
    1299313285 cf_cv_shlib_version_infix="$cf_cv_shlib_version_infix"
    1299413286 cf_cv_system_name="$cf_cv_system_name"
     
    1299813290 target="$target"
    1299913291 
    13000 @@ -17224,7 +17637,7 @@
     13292@@ -17224,7 +17668,7 @@
    1300113293   "Makefile" ) CONFIG_FILES="$CONFIG_FILES Makefile" ;;
    1300213294   "default" ) CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;;
    1300313295   "include/ncurses_cfg.h" ) CONFIG_HEADERS="$CONFIG_HEADERS include/ncurses_cfg.h:include/ncurses_cfg.hin" ;;
    1300413296-  *) { { echo "$as_me:17227: error: invalid argument: $ac_config_target" >&5
    13005 +  *) { { echo "$as_me:17640: error: invalid argument: $ac_config_target" >&5
     13297+  *) { { echo "$as_me:17671: error: invalid argument: $ac_config_target" >&5
    1300613298 echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
    1300713299    { (exit 1); exit 1; }; };;
    1300813300   esac
    13009 @@ -17349,6 +17762,8 @@
     13301@@ -17349,6 +17793,8 @@
    1301013302 s,@LINT@,$LINT,;t t
    1301113303 s,@LINT_OPTS@,$LINT_OPTS,;t t
     
    1301613308 s,@MAKE_LOWER_TAGS@,$MAKE_LOWER_TAGS,;t t
    1301713309 s,@MAKE_UPPER_TAGS@,$MAKE_UPPER_TAGS,;t t
    13018 @@ -17359,7 +17774,7 @@
     13310@@ -17359,7 +17805,7 @@
    1301913311 s,@ac_ct_LD@,$ac_ct_LD,;t t
    1302013312 s,@AR@,$AR,;t t
     
    1302513317 s,@BUILD_CC@,$BUILD_CC,;t t
    1302613318 s,@BUILD_CPP@,$BUILD_CPP,;t t
    13027 @@ -17392,6 +17807,7 @@
     13319@@ -17371,6 +17817,7 @@
     13320 s,@BUILD_OBJEXT@,$BUILD_OBJEXT,;t t
     13321 s,@cf_list_models@,$cf_list_models,;t t
     13322 s,@LIBTOOL@,$LIBTOOL,;t t
     13323+s,@LT_UNDEF@,$LT_UNDEF,;t t
     13324 s,@LIBTOOL_CXX@,$LIBTOOL_CXX,;t t
     13325 s,@LIBTOOL_OPTS@,$LIBTOOL_OPTS,;t t
     13326 s,@LIB_CREATE@,$LIB_CREATE,;t t
     13327@@ -17392,6 +17839,7 @@
    1302813328 s,@CXX_G_OPT@,$CXX_G_OPT,;t t
    1302913329 s,@LD_MODEL@,$LD_MODEL,;t t
     
    1303313333 s,@MK_SHARED_LIB@,$MK_SHARED_LIB,;t t
    1303413334 s,@LINK_PROGS@,$LINK_PROGS,;t t
    13035 @@ -17401,7 +17817,6 @@
     13335@@ -17401,7 +17849,6 @@
    1303613336 s,@LOCAL_LDFLAGS2@,$LOCAL_LDFLAGS2,;t t
    1303713337 s,@INSTALL_LIB@,$INSTALL_LIB,;t t
     
    1304113341 s,@WHICH_XTERM@,$WHICH_XTERM,;t t
    1304213342 s,@TERMINFO_DIRS@,$TERMINFO_DIRS,;t t
    13043 @@ -17425,6 +17840,9 @@
     13343@@ -17425,6 +17872,9 @@
    1304413344 s,@NCURSES_OSPEED@,$NCURSES_OSPEED,;t t
    1304513345 s,@MANPAGE_RENAMES@,$MANPAGE_RENAMES,;t t
     
    1305113351 s,@NCURSES_EXT_COLORS@,$NCURSES_EXT_COLORS,;t t
    1305213352 s,@NCURSES_MOUSE_VERSION@,$NCURSES_MOUSE_VERSION,;t t
    13053 @@ -17449,7 +17867,7 @@
     13353@@ -17435,6 +17885,7 @@
     13354 s,@cf_cv_enable_opaque@,$cf_cv_enable_opaque,;t t
     13355 s,@NCURSES_OPAQUE@,$NCURSES_OPAQUE,;t t
     13356 s,@NCURSES_SIZE_T@,$NCURSES_SIZE_T,;t t
     13357+s,@NCURSES_WRAP_PREFIX@,$NCURSES_WRAP_PREFIX,;t t
     13358 s,@ECHO_LINK@,$ECHO_LINK,;t t
     13359 s,@EXTRA_CFLAGS@,$EXTRA_CFLAGS,;t t
     13360 s,@EXTRA_CXXFLAGS@,$EXTRA_CXXFLAGS,;t t
     13361@@ -17449,7 +17900,7 @@
    1305413362 s,@CXXCPP@,$CXXCPP,;t t
    1305513363 s,@CXXLDFLAGS@,$CXXLDFLAGS,;t t
     
    1306013368 s,@USE_CXX_BOOL@,$USE_CXX_BOOL,;t t
    1306113369 s,@gnat_exists@,$gnat_exists,;t t
    13062 @@ -17493,6 +17911,7 @@
     13370@@ -17493,6 +17944,7 @@
    1306313371 s,@HAVE_TCGETATTR@,$HAVE_TCGETATTR,;t t
    1306413372 s,@HAVE_TERMIO_H@,$HAVE_TERMIO_H,;t t
     
    1306813376 
    1306913377 EOF
    13070 @@ -17607,7 +18026,7 @@
     13378@@ -17607,7 +18059,7 @@
    1307113379   esac
    1307213380 
    1307313381   if test x"$ac_file" != x-; then
    1307413382-    { echo "$as_me:17610: creating $ac_file" >&5
    13075 +    { echo "$as_me:18029: creating $ac_file" >&5
     13383+    { echo "$as_me:18062: creating $ac_file" >&5
    1307613384 echo "$as_me: creating $ac_file" >&6;}
    1307713385     rm -f "$ac_file"
    1307813386   fi
    13079 @@ -17625,7 +18044,7 @@
     13387@@ -17625,7 +18077,7 @@
    1308013388       -) echo $tmp/stdin ;;
    1308113389       [\\/$]*)
    1308213390          # Absolute (can't be DOS-style, as IFS=:)
    1308313391-         test -f "$f" || { { echo "$as_me:17628: error: cannot find input file: $f" >&5
    13084 +         test -f "$f" || { { echo "$as_me:18047: error: cannot find input file: $f" >&5
     13392+         test -f "$f" || { { echo "$as_me:18080: error: cannot find input file: $f" >&5
    1308513393 echo "$as_me: error: cannot find input file: $f" >&2;}
    1308613394    { (exit 1); exit 1; }; }
    1308713395          echo $f;;
    13088 @@ -17638,7 +18057,7 @@
     13396@@ -17638,7 +18090,7 @@
    1308913397            echo $srcdir/$f
    1309013398          else
    1309113399            # /dev/null tree
    1309213400-           { { echo "$as_me:17641: error: cannot find input file: $f" >&5
    13093 +           { { echo "$as_me:18060: error: cannot find input file: $f" >&5
     13401+           { { echo "$as_me:18093: error: cannot find input file: $f" >&5
    1309413402 echo "$as_me: error: cannot find input file: $f" >&2;}
    1309513403    { (exit 1); exit 1; }; }
    1309613404          fi;;
    13097 @@ -17704,7 +18123,7 @@
     13405@@ -17704,7 +18156,7 @@
    1309813406   * )   ac_file_in=$ac_file.in ;;
    1309913407   esac
    1310013408 
    1310113409-  test x"$ac_file" != x- && { echo "$as_me:17707: creating $ac_file" >&5
    13102 +  test x"$ac_file" != x- && { echo "$as_me:18126: creating $ac_file" >&5
     13410+  test x"$ac_file" != x- && { echo "$as_me:18159: creating $ac_file" >&5
    1310313411 echo "$as_me: creating $ac_file" >&6;}
    1310413412 
    1310513413   # First look for the input files in the build tree, otherwise in the
    13106 @@ -17715,7 +18134,7 @@
     13414@@ -17715,7 +18167,7 @@
    1310713415       -) echo $tmp/stdin ;;
    1310813416       [\\/$]*)
    1310913417          # Absolute (can't be DOS-style, as IFS=:)
    1311013418-         test -f "$f" || { { echo "$as_me:17718: error: cannot find input file: $f" >&5
    13111 +         test -f "$f" || { { echo "$as_me:18137: error: cannot find input file: $f" >&5
     13419+         test -f "$f" || { { echo "$as_me:18170: error: cannot find input file: $f" >&5
    1311213420 echo "$as_me: error: cannot find input file: $f" >&2;}
    1311313421    { (exit 1); exit 1; }; }
    1311413422          echo $f;;
    13115 @@ -17728,7 +18147,7 @@
     13423@@ -17728,7 +18180,7 @@
    1311613424            echo $srcdir/$f
    1311713425          else
    1311813426            # /dev/null tree
    1311913427-           { { echo "$as_me:17731: error: cannot find input file: $f" >&5
    13120 +           { { echo "$as_me:18150: error: cannot find input file: $f" >&5
     13428+           { { echo "$as_me:18183: error: cannot find input file: $f" >&5
    1312113429 echo "$as_me: error: cannot find input file: $f" >&2;}
    1312213430    { (exit 1); exit 1; }; }
    1312313431          fi;;
    13124 @@ -17786,7 +18205,7 @@
     13432@@ -17786,7 +18238,7 @@
    1312513433   rm -f $tmp/in
    1312613434   if test x"$ac_file" != x-; then
    1312713435     if cmp -s $ac_file $tmp/config.h 2>/dev/null; then
    1312813436-      { echo "$as_me:17789: $ac_file is unchanged" >&5
    13129 +      { echo "$as_me:18208: $ac_file is unchanged" >&5
     13437+      { echo "$as_me:18241: $ac_file is unchanged" >&5
    1313013438 echo "$as_me: $ac_file is unchanged" >&6;}
    1313113439     else
    1313213440       ac_dir=`$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
    13133 @@ -17873,40 +18292,44 @@
     13441@@ -17873,40 +18325,44 @@
    1313413442                for cf_item in $cf_LIST_MODELS
    1313513443                do
     
    1318713495                                cf_depsuf=$cf_suffix
    1318813496                                ;;
    13189 @@ -18020,40 +18443,44 @@
     13497@@ -18020,40 +18476,44 @@
    1319013498 
    1319113499 cf_ITEM=`echo "$cf_item" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
     
    1324313551                                cf_depsuf=$cf_suffix
    1324413552                                ;;
    13245 @@ -18234,18 +18661,28 @@
     13553@@ -18234,18 +18694,28 @@
    1324613554 install.libs uninstall.libs \\
    1324713555 install.data uninstall.data ::
     
    1327213580 if test -f $srcdir/$tack.h; then
    1327313581 cat >> Makefile <<CF_EOF
    13274 @@ -18256,6 +18693,7 @@
     13582@@ -18256,6 +18726,7 @@
    1327513583 CF_EOF
    1327613584 fi
     
    1328213590diff -Naur ncurses-5.7.orig/configure.in ncurses-5.7/configure.in
    1328313591--- ncurses-5.7.orig/configure.in       2008-10-18 07:53:32.000000000 -0700
    13284 +++ ncurses-5.7/configure.in    2009-02-28 20:38:57.043235088 -0800
     13592+++ ncurses-5.7/configure.in    2009-06-05 14:01:30.000000000 -0700
    1328513593@@ -1,5 +1,5 @@
    1328613594 dnl***************************************************************************
     
    1329513603 dnl
    1329613604-dnl $Id: configure.in,v 1.454 2008/10/18 14:53:32 tom Exp $
    13297 +dnl $Id: configure.in,v 1.466 2009/02/15 00:19:01 tom Exp $
     13605+dnl $Id: configure.in,v 1.470 2009/03/28 18:22:39 Charles.Wilson Exp $
    1329813606 dnl Process this file with autoconf to produce a configure script.
    1329913607 dnl
     
    1330313611 AC_PREREQ(2.13.20020210)
    1330413612-AC_REVISION($Revision: 1.454 $)
    13305 +AC_REVISION($Revision: 1.466 $)
     13613+AC_REVISION($Revision: 1.470 $)
    1330613614 AC_INIT(ncurses/base/lib_initscr.c)
    1330713615 AC_CONFIG_HEADER(include/ncurses_cfg.h:include/ncurses_cfg.hin)
     
    1340213710 ###   use option --enable-const to turn on use of const beyond that in XSI.
    1340313711 AC_MSG_CHECKING(for extended use of const keyword)
    13404 @@ -1165,12 +1217,18 @@
     13712@@ -1024,11 +1076,11 @@
     13713        cf_cv_enable_opaque="NCURSES_INTERNALS"
     13714        NCURSES_OPAQUE=1
     13715        NCURSES_SIZE_T=int
     13716-    if test $cf_cv_weak_symbols = yes ; then
     13717-        CF_REMOVE_LIB(LIBS,$LIBS,pthread)
     13718-    else
     13719-        LIB_SUFFIX="t${LIB_SUFFIX}"
     13720-    fi
     13721+       if test $cf_cv_weak_symbols = yes ; then
     13722+               CF_REMOVE_LIB(LIBS,$LIBS,pthread)
     13723+       else
     13724+               LIB_SUFFIX="t${LIB_SUFFIX}"
     13725+       fi
     13726        AC_DEFINE(USE_REENTRANT)
     13727        CF_NCURSES_ABI_6
     13728 else
     13729@@ -1042,6 +1094,20 @@
     13730 AC_SUBST(NCURSES_OPAQUE)
     13731 AC_SUBST(NCURSES_SIZE_T)
     13732 
     13733+### Allow using a different wrap-prefix
     13734+if test "$cf_cv_enable_reentrant" != 0 || test "$BROKEN_LINKER" = 1 ; then
     13735+       AC_MSG_CHECKING(for prefix used to wrap public variables)
     13736+       AC_ARG_WITH(wrap-prefix,
     13737+               [  --with-wrap-prefix=XXX  override prefix used for public variables],
     13738+               [NCURSES_WRAP_PREFIX=$withval],
     13739+               [NCURSES_WRAP_PREFIX=_nc_])
     13740+       AC_MSG_RESULT($NCURSES_WRAP_PREFIX)
     13741+else
     13742+       NCURSES_WRAP_PREFIX=_nc_
     13743+fi
     13744+AC_SUBST(NCURSES_WRAP_PREFIX)
     13745+AC_DEFINE_UNQUOTED(NCURSES_WRAP_PREFIX,"$NCURSES_WRAP_PREFIX")
     13746+
     13747 AC_MSG_CHECKING(if you want experimental safe-sprintf code)
     13748 AC_ARG_ENABLE(safe-sprintf,
     13749        [  --enable-safe-sprintf   compile with experimental safe-sprintf code],
     13750@@ -1165,12 +1231,18 @@
    1340513751 AC_SUBST(ADA_TRACE)
    1340613752 
     
    1342113767 CF_MATH_LIB(MATH_LIB,sin(x))
    1342213768 AC_SUBST(MATH_LIB)
    13423 @@ -1354,12 +1412,12 @@
     13769@@ -1354,12 +1426,12 @@
    1342413770        CF_CPP_STATIC_CAST
    1342513771 
     
    1343613782            ;;
    1343713783        sco3.2v5*) #(vi
    13438 @@ -1368,13 +1426,13 @@
     13784@@ -1368,13 +1440,13 @@
    1343913785        solaris2*)
    1344013786            if test "$GXX" != yes ; then
     
    1345213798        cf_cxx_library=no
    1345313799        cf_cv_builtin_bool=1
    13454 @@ -1552,7 +1610,17 @@
     13800@@ -1552,7 +1624,17 @@
    1345513801        fi
    1345613802 fi
     
    1347113817 if test "$with_termlib" != no ; then
    1347213818        LIB_SUBSETS="${LIB_SUBSETS} "
    13473 @@ -1561,6 +1629,7 @@
     13819@@ -1561,6 +1643,7 @@
    1347413820 fi
    1347513821 
     
    1347913825 test "$with_ext_funcs" = yes && LIB_SUBSETS="${LIB_SUBSETS}+ext_funcs"
    1348013826 
    13481 @@ -1723,6 +1792,7 @@
     13827@@ -1656,6 +1739,8 @@
     13828                TEST_ARGS="${TEST_DEPS}"
     13829                TEST_ARG2="${TEST_DEP2}"
     13830                TINFO_ARGS="-L${LIB_DIR} $TEST_ARGS"
     13831+               TICS_LIST="$SHLIB_LIST $TEST_ARGS"
     13832+               SHLIB_LIST="${SHLIB_LIST} $TEST_ARGS"
     13833        else
     13834                TEST_ARGS="-l${TINFO_ARG_SUFFIX}"
     13835                TEST_ARG2="-l${TINFO_ARG_SUFFIX}"
     13836@@ -1723,6 +1808,7 @@
    1348213837        AC_MSG_WARN(Wide-character applications must define HAVE_LIBUTF8_H to include curses.h)
    1348313838 fi
     
    1348713842 AC_SUBST(WITH_OVERWRITE)
    1348813843 AC_SUBST(TICS_LIST)
    13489 @@ -1742,12 +1812,12 @@
     13844@@ -1742,12 +1828,12 @@
    1349013845 CF_SRC_MODULES($modules_to_build)
    1349113846 
     
    1350213857 AC_DEFINE_UNQUOTED(NCURSES_VERSION_STRING, "${NCURSES_MAJOR}.${NCURSES_MINOR}.${NCURSES_PATCH}")
    1350313858 
    13504 @@ -1765,8 +1835,19 @@
     13859@@ -1765,8 +1851,19 @@
    1350513860 CF_SUBST_IF(["$ac_cv_header_termios_h" = yes], HAVE_TERMIOS_H, 1, 0)
    1350613861 
     
    1352313878        include/MKterm.h.awk \
    1352413879        include/curses.head:include/curses.h.in \
    13525 @@ -1796,13 +1877,13 @@
     13880@@ -1796,13 +1893,13 @@
    1352613881 NCURSES_PATCH="$NCURSES_PATCH"
    1352713882 SRC_SUBDIRS="$SRC_SUBDIRS"
     
    1354013895 WITH_ECHO="$with_echo"
    1354113896 WITH_OVERWRITE="$with_overwrite"
    13542 @@ -1821,6 +1902,7 @@
     13897@@ -1821,6 +1918,7 @@
    1354313898 cf_cv_shlib_version_infix="$cf_cv_shlib_version_infix"
    1354413899 cf_cv_system_name="$cf_cv_system_name"
     
    1355013905diff -Naur ncurses-5.7.orig/dist.mk ncurses-5.7/dist.mk
    1355113906--- ncurses-5.7.orig/dist.mk    2008-11-01 17:58:38.000000000 -0700
    13552 +++ ncurses-5.7/dist.mk 2009-02-28 20:38:59.855417236 -0800
     13907+++ ncurses-5.7/dist.mk 2009-06-05 14:01:55.000000000 -0700
    1355313908@@ -25,7 +25,7 @@
    1355413909 # use or other dealings in this Software without prior written               #
     
    1355613911 ##############################################################################
    1355713912-# $Id: dist.mk,v 1.671 2008/11/02 00:58:38 tom Exp $
    13558 +# $Id: dist.mk,v 1.688 2009/02/28 14:49:13 tom Exp $
     13913+# $Id: dist.mk,v 1.702 2009/05/30 13:36:52 tom Exp $
    1355913914 # Makefile for creating ncurses distributions.
    1356013915 #
     
    1356513920 NCURSES_MINOR = 7
    1356613921-NCURSES_PATCH = 20081102
    13567 +NCURSES_PATCH = 20090228
     13922+NCURSES_PATCH = 20090530
    1356813923 
    1356913924 # We don't append the patch to the version, since this only applies to releases
     
    1357113926diff -Naur ncurses-5.7.orig/form/fld_def.c ncurses-5.7/form/fld_def.c
    1357213927--- ncurses-5.7.orig/form/fld_def.c     2007-10-13 12:29:58.000000000 -0700
    13573 +++ ncurses-5.7/form/fld_def.c  2009-02-28 20:38:59.855417236 -0800
     13928+++ ncurses-5.7/form/fld_def.c  2009-06-05 14:01:18.000000000 -0700
    1357413929@@ -32,7 +32,7 @@
    1357513930 
     
    1359113946 
    1359213947 /*---------------------------------------------------------------------------
     13948diff -Naur ncurses-5.7.orig/form/fld_newftyp.c ncurses-5.7/form/fld_newftyp.c
     13949--- ncurses-5.7.orig/form/fld_newftyp.c 2007-10-13 12:30:55.000000000 -0700
     13950+++ ncurses-5.7/form/fld_newftyp.c      2009-06-05 14:01:33.000000000 -0700
     13951@@ -1,5 +1,5 @@
     13952 /****************************************************************************
     13953- * Copyright (c) 1998-2004,2007 Free Software Foundation, Inc.              *
     13954+ * Copyright (c) 1998-2007,2009 Free Software Foundation, Inc.              *
     13955  *                                                                          *
     13956  * Permission is hereby granted, free of charge, to any person obtaining a  *
     13957  * copy of this software and associated documentation files (the            *
     13958@@ -32,9 +32,9 @@
     13959 
     13960 #include "form.priv.h"
     13961 
     13962-MODULE_ID("$Id: fld_newftyp.c,v 1.15 2007/10/13 19:30:55 tom Exp $")
     13963+MODULE_ID("$Id: fld_newftyp.c,v 1.16 2009/04/11 21:27:33 tom Exp $")
     13964 
     13965-static FIELDTYPE const default_fieldtype =
     13966+static FIELDTYPE default_fieldtype =
     13967 {
     13968   0,                           /* status                                      */
     13969   0L,                          /* reference count                             */
     13970@@ -49,7 +49,7 @@
     13971   NULL                         /* enumerate previous function                 */
     13972 };
     13973 
     13974-NCURSES_EXPORT_VAR(const FIELDTYPE *)
     13975+NCURSES_EXPORT_VAR(FIELDTYPE *)
     13976 _nc_Default_FieldType = &default_fieldtype;
     13977 
     13978 /*---------------------------------------------------------------------------
     13979diff -Naur ncurses-5.7.orig/form/form.priv.h ncurses-5.7/form/form.priv.h
     13980--- ncurses-5.7.orig/form/form.priv.h   2008-09-08 13:29:05.000000000 -0700
     13981+++ ncurses-5.7/form/form.priv.h        2009-06-05 14:01:33.000000000 -0700
     13982@@ -1,5 +1,5 @@
     13983 /****************************************************************************
     13984- * Copyright (c) 1998-2006,2008 Free Software Foundation, Inc.              *
     13985+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     13986  *                                                                          *
     13987  * Permission is hereby granted, free of charge, to any person obtaining a  *
     13988  * copy of this software and associated documentation files (the            *
     13989@@ -30,7 +30,7 @@
     13990  *   Author:  Juergen Pfeifer, 1995,1997                                    *
     13991  ****************************************************************************/
     13992 
     13993-/* $Id: form.priv.h,v 0.27 2008/09/08 20:29:05 tom Exp $ */
     13994+/* $Id: form.priv.h,v 0.28 2009/04/11 21:27:04 tom Exp $ */
     13995 
     13996 #ifndef FORM_PRIV_H
     13997 #define FORM_PRIV_H 1
     13998@@ -62,6 +62,13 @@
     13999 
     14000 #include "form.h"
     14001 
     14002+       /***********************
     14003+       *   Default objects    *
     14004+       ***********************/
     14005+extern NCURSES_EXPORT_VAR(FORM *)      _nc_Default_Form;
     14006+extern NCURSES_EXPORT_VAR(FIELD *)     _nc_Default_Field;
     14007+extern NCURSES_EXPORT_VAR(FIELDTYPE *) _nc_Default_FieldType;
     14008+
     14009 /* form  status values */
     14010 #define _OVLMODE         (0x04U) /* Form is in overlay mode                */
     14011 #define _WINDOW_MODIFIED (0x10U) /* Current field window has been modified */
     14012@@ -91,6 +98,11 @@
     14013 #define Normalize_Field(field) \
     14014   ((field) = (field != 0) ? (field) : _nc_Default_Field)
     14015 
     14016+#if NCURSES_SP_FUNCS
     14017+#define Get_Form_Screen(form) \
     14018+  ((form)->win ? _nc_screen_of((form->win)):CURRENT_SCREEN)
     14019+#endif
     14020+
     14021 /* Retrieve forms window */
     14022 #define Get_Form_Window(form) \
     14023   ((form)->sub?(form)->sub:((form)->win?(form)->win:stdscr))
     14024@@ -144,8 +156,6 @@
     14025 
     14026 #define C_ZEROS '\0'
     14027 
     14028-extern NCURSES_EXPORT_VAR(const FIELDTYPE *) _nc_Default_FieldType;
     14029-
     14030 extern NCURSES_EXPORT(TypeArgument *) _nc_Make_Argument (const FIELDTYPE*, va_list*, int*);
     14031 extern NCURSES_EXPORT(TypeArgument *) _nc_Copy_Argument (const FIELDTYPE*, const TypeArgument*, int*);
     14032 extern NCURSES_EXPORT(void) _nc_Free_Argument (const FIELDTYPE*, TypeArgument*);
     14033@@ -176,8 +186,8 @@
     14034 extern NCURSES_EXPORT(FIELD **)            _nc_retrace_field_ptr (FIELD **);
     14035 extern NCURSES_EXPORT(FIELD *)     _nc_retrace_field (FIELD *);
     14036 extern NCURSES_EXPORT(FIELDTYPE *)  _nc_retrace_field_type (FIELDTYPE *);
     14037-extern NCURSES_EXPORT(FORM *)  _nc_retrace_form (FORM *);
     14038-extern NCURSES_EXPORT(Form_Hook)  _nc_retrace_form_hook (Form_Hook);
     14039+extern NCURSES_EXPORT(FORM *)       _nc_retrace_form (FORM *);
     14040+extern NCURSES_EXPORT(Form_Hook)    _nc_retrace_form_hook (Form_Hook);
     14041 
     14042 #else /* !TRACE */
     14043 
    1359314044diff -Naur ncurses-5.7.orig/form/frm_driver.c ncurses-5.7/form/frm_driver.c
    1359414045--- ncurses-5.7.orig/form/frm_driver.c  2008-10-18 09:25:00.000000000 -0700
    13595 +++ ncurses-5.7/form/frm_driver.c       2009-02-28 20:38:39.770130185 -0800
     14046+++ ncurses-5.7/form/frm_driver.c       2009-06-05 14:00:55.000000000 -0700
    1359614047@@ -32,7 +32,7 @@
    1359714048 
     
    1361114062   mvwaddstr(field->working, 0, 0, value);
    1361214063 
     14064diff -Naur ncurses-5.7.orig/form/frm_sub.c ncurses-5.7/form/frm_sub.c
     14065--- ncurses-5.7.orig/form/frm_sub.c     2004-12-11 14:13:39.000000000 -0800
     14066+++ ncurses-5.7/form/frm_sub.c  2009-06-05 14:01:33.000000000 -0700
     14067@@ -1,5 +1,5 @@
     14068 /****************************************************************************
     14069- * Copyright (c) 1998-2003,2004 Free Software Foundation, Inc.              *
     14070+ * Copyright (c) 1998-2004,2009 Free Software Foundation, Inc.              *
     14071  *                                                                          *
     14072  * Permission is hereby granted, free of charge, to any person obtaining a  *
     14073  * copy of this software and associated documentation files (the            *
     14074@@ -27,12 +27,12 @@
     14075  ****************************************************************************/
     14076 
     14077 /****************************************************************************
     14078- *   Author:  Juergen Pfeifer, 1995,1997                                    *
     14079+ *   Author:  Juergen Pfeifer, 1995-1997,2009                               *
     14080  ****************************************************************************/
     14081 
     14082 #include "form.priv.h"
     14083 
     14084-MODULE_ID("$Id: frm_sub.c,v 1.9 2004/12/11 22:13:39 tom Exp $")
     14085+MODULE_ID("$Id: frm_sub.c,v 1.10 2009/04/11 18:32:47 tom Exp $")
     14086 
     14087 /*---------------------------------------------------------------------------
     14088 |   Facility      :  libnform 
     14089@@ -50,9 +50,18 @@
     14090 
     14091   if (form && (form->status & _POSTED))
     14092     RETURN(E_POSTED);
     14093-
     14094-  Normalize_Form(form)->sub = win;
     14095-  RETURN(E_OK);
     14096+  else
     14097+    {
     14098+#if NCURSES_SP_FUNCS
     14099+      FORM *f = Normalize_Form(form);
     14100+
     14101+      f->sub = win ? win : Get_Form_Screen(f)->_stdscr;
     14102+      RETURN(E_OK);
     14103+#else
     14104+      Normalize_Form(form)->sub = win;
     14105+      RETURN(E_OK);
     14106+#endif
     14107+    }
     14108 }
     14109 
     14110 /*---------------------------------------------------------------------------
     14111diff -Naur ncurses-5.7.orig/form/frm_win.c ncurses-5.7/form/frm_win.c
     14112--- ncurses-5.7.orig/form/frm_win.c     2004-12-11 14:15:27.000000000 -0800
     14113+++ ncurses-5.7/form/frm_win.c  2009-06-05 14:01:44.000000000 -0700
     14114@@ -1,5 +1,5 @@
     14115 /****************************************************************************
     14116- * Copyright (c) 1998-2003,2004 Free Software Foundation, Inc.              *
     14117+ * Copyright (c) 1998-2004,2009 Free Software Foundation, Inc.              *
     14118  *                                                                          *
     14119  * Permission is hereby granted, free of charge, to any person obtaining a  *
     14120  * copy of this software and associated documentation files (the            *
     14121@@ -32,7 +32,7 @@
     14122 
     14123 #include "form.priv.h"
     14124 
     14125-MODULE_ID("$Id: frm_win.c,v 1.13 2004/12/11 22:15:27 tom Exp $")
     14126+MODULE_ID("$Id: frm_win.c,v 1.14 2009/04/18 18:38:57 tom Exp $")
     14127 
     14128 /*---------------------------------------------------------------------------
     14129 |   Facility      :  libnform 
     14130@@ -50,9 +50,18 @@
     14131 
     14132   if (form && (form->status & _POSTED))
     14133     RETURN(E_POSTED);
     14134-
     14135-  Normalize_Form(form)->win = win;
     14136-  RETURN(E_OK);
     14137+  else
     14138+    {
     14139+#if NCURSES_SP_FUNCS
     14140+      FORM *f = Normalize_Form(form);
     14141+
     14142+      f->win = win ? win : Get_Form_Screen(f)->_stdscr;
     14143+      RETURN(E_OK);
     14144+#else
     14145+      Normalize_Form(form)->win = win;
     14146+      RETURN(E_OK);
     14147+#endif
     14148+    }
     14149 }
     14150 
     14151 /*---------------------------------------------------------------------------
     14152@@ -66,12 +75,18 @@
     14153 NCURSES_EXPORT(WINDOW *)
     14154 form_win(const FORM *form)
     14155 {
     14156+  WINDOW *result;
     14157   const FORM *f;
     14158 
     14159   T((T_CALLED("form_win(%p)"), form));
     14160 
     14161   f = Normalize_Form(form);
     14162-  returnWin(f->win ? f->win : stdscr);
     14163+#if NCURSES_SP_FUNCS
     14164+  result = (f->win ? f->win : Get_Form_Screen(f)->_stdscr);
     14165+#else
     14166+  result = (f->win ? f->win : stdscr);
     14167+#endif
     14168+  returnWin(result);
     14169 }
     14170 
     14171 /* frm_win.c ends here */
    1361314172diff -Naur ncurses-5.7.orig/form/Makefile.in ncurses-5.7/form/Makefile.in
    1361414173--- ncurses-5.7.orig/form/Makefile.in   2007-04-28 07:56:11.000000000 -0700
    13615 +++ ncurses-5.7/form/Makefile.in        2009-02-28 20:38:46.310547562 -0800
     14174+++ ncurses-5.7/form/Makefile.in        2009-06-05 14:01:30.000000000 -0700
    1361614175@@ -1,6 +1,6 @@
    1361714176-# $Id: Makefile.in,v 1.47 2007/04/28 14:56:11 tom Exp $
    13618 +# $Id: Makefile.in,v 1.48 2009/01/03 19:09:26 tom Exp $
     14177+# $Id: Makefile.in,v 1.49 2009/03/28 18:22:39 Charles.Wilson Exp $
    1361914178 ##############################################################################
    1362014179-# Copyright (c) 1998-2006,2007 Free Software Foundation, Inc.                #
     
    1362314182 # Permission is hereby granted, free of charge, to any person obtaining a    #
    1362414183 # copy of this software and associated documentation files (the "Software"), #
    13625 @@ -70,7 +70,7 @@
     14184@@ -63,6 +63,7 @@
     14185 LIBTOOL_LINK   = @LIB_LINK@
     14186 LIBTOOL_INSTALL        = @LIB_INSTALL@
     14187 LIBTOOL_UNINSTALL = @LIB_UNINSTALL@
     14188+LT_UNDEF       = @LT_UNDEF@
     14189 
     14190 INSTALL                = @INSTALL@
     14191 INSTALL_LIB    = @INSTALL@ @INSTALL_LIB@
     14192@@ -70,7 +71,7 @@
    1362614193 INSTALL_DATA   = @INSTALL_DATA@
    1362714194 
     
    1363414201diff -Naur ncurses-5.7.orig/include/capdefaults.c ncurses-5.7/include/capdefaults.c
    1363514202--- ncurses-5.7.orig/include/capdefaults.c      2008-08-04 05:33:42.000000000 -0700
    13636 +++ ncurses-5.7/include/capdefaults.c   2009-02-28 20:38:58.435326721 -0800
     14203+++ ncurses-5.7/include/capdefaults.c   2009-06-05 14:01:16.000000000 -0700
    1363714204@@ -32,7 +32,7 @@
    1363814205  *     and: Thomas E. Dickey                        1996-on                 *
     
    1366014227diff -Naur ncurses-5.7.orig/include/curses.h.in ncurses-5.7/include/curses.h.in
    1366114228--- ncurses-5.7.orig/include/curses.h.in        2008-08-30 13:11:29.000000000 -0700
    13662 +++ ncurses-5.7/include/curses.h.in     2009-02-28 20:38:58.435326721 -0800
     14229+++ ncurses-5.7/include/curses.h.in     2009-06-05 14:01:54.000000000 -0700
    1366314230@@ -1,5 +1,5 @@
    1366414231 /****************************************************************************
     
    1367314240 
    1367414241-/* $Id: curses.h.in,v 1.187 2008/08/30 20:11:29 tom Exp $ */
    13675 +/* $Id: curses.h.in,v 1.194 2009/02/21 22:44:41 tom Exp $ */
     14242+/* $Id: curses.h.in,v 1.201 2009/05/23 21:31:35 tom Exp $ */
    1367614243 
    1367714244 #ifndef __NCURSES_H
     
    1369014257 #define NCURSES_VERSION_MAJOR @NCURSES_MAJOR@
    1369114258 #define NCURSES_VERSION_MINOR @NCURSES_MINOR@
    13692 @@ -110,6 +104,13 @@
     14259@@ -110,6 +104,20 @@
    1369314260 #endif
    1369414261 
     
    1370114268+
    1370214269+/*
     14270+ * For reentrant code, we map the various global variables into SCREEN by
     14271+ * using functions to access them.
     14272+ */
     14273+#define NCURSES_PUBLIC_VAR(name) @NCURSES_WRAP_PREFIX@##name
     14274+#define NCURSES_WRAPPED_VAR(type,name) extern type NCURSES_PUBLIC_VAR(name)(void)
     14275+
     14276+/*
    1370314277  * The internal type used for window dimensions.
    1370414278  */
    1370514279 #undef NCURSES_SIZE_T
    13706 @@ -224,7 +225,7 @@
     14280@@ -138,7 +146,6 @@
     14281 #endif
     14282 
     14283 #include <stdio.h>
     14284-#include <unctrl.h>
     14285 #include <stdarg.h>    /* we need va_list */
     14286 #ifdef _XOPEN_SOURCE_EXTENDED
     14287 #include <stddef.h>    /* we want wchar_t */
     14288@@ -224,9 +231,9 @@
    1370714289 
    1370814290 /* line graphics */
     
    1371114293+#if @BROKEN_LINKER@ || NCURSES_REENTRANT
    1371214294 NCURSES_WRAPPED_VAR(chtype*, acs_map);
    13713  #define acs_map (_nc_acs_map())
     14295-#define acs_map (_nc_acs_map())
     14296+#define acs_map NCURSES_PUBLIC_VAR(acs_map())
    1371414297 #else
    13715 @@ -646,7 +647,7 @@
     14298 extern NCURSES_EXPORT_VAR(chtype) acs_map[];
     14299 #endif
     14300@@ -511,6 +518,12 @@
     14301 #endif
     14302 
     14303 /*
     14304+ * Curses uses a helper function.  Define our type for this to simplify
     14305+ * extending it for the sp-funcs feature.
     14306+ */
     14307+typedef int (*NCURSES_OUTC)(int);
     14308+
     14309+/*
     14310  * Function prototypes.  This is the complete X/Open Curses list of required
     14311  * functions.  Those marked `generated' will have sources generated from the
     14312  * macro definitions later in this file, in order to satisfy XPG4.2
     14313@@ -646,7 +659,7 @@
    1371614314 extern NCURSES_EXPORT(int) mvwinnstr (WINDOW *, int, int, char *, int);                /* generated */
    1371714315 extern NCURSES_EXPORT(int) mvwinsch (WINDOW *, int, int, chtype);              /* generated */
     
    1372214320 extern NCURSES_EXPORT(int) mvwprintw (WINDOW*,int,int, const char *,...)       /* implemented */
    1372314321                GCC_PRINTFLIKE(4,5);
    13724 @@ -654,9 +655,9 @@
     14322@@ -654,9 +667,9 @@
    1372514323                GCC_SCANFLIKE(4,5);
    1372614324 extern NCURSES_EXPORT(int) mvwvline (WINDOW *,int, int, chtype, int);  /* generated */
     
    1373414332 extern NCURSES_EXPORT(int) nocbreak (void);                            /* implemented */
    1373514333 extern NCURSES_EXPORT(int) nodelay (WINDOW *,bool);                    /* implemented */
    13736 @@ -710,7 +711,7 @@
     14334@@ -710,7 +723,7 @@
    1373714335 extern NCURSES_EXPORT(int) slk_refresh (void);                         /* implemented */
    1373814336 extern NCURSES_EXPORT(int) slk_restore (void);                         /* implemented */
     
    1374314341 extern NCURSES_EXPORT(int) standend (void);                            /* generated */
    1374414342 extern NCURSES_EXPORT(int) start_color (void);                         /* implemented */
    13745 @@ -856,23 +857,119 @@
     14343@@ -727,7 +740,7 @@
     14344 extern NCURSES_EXPORT(int) untouchwin (WINDOW *);                      /* generated */
     14345 extern NCURSES_EXPORT(void) use_env (bool);                            /* implemented */
     14346 extern NCURSES_EXPORT(int) vidattr (chtype);                           /* implemented */
     14347-extern NCURSES_EXPORT(int) vidputs (chtype, int (*)(int));             /* implemented */
     14348+extern NCURSES_EXPORT(int) vidputs (chtype, NCURSES_OUTC);             /* implemented */
     14349 extern NCURSES_EXPORT(int) vline (chtype, int);                                /* generated */
     14350 extern NCURSES_EXPORT(int) vwprintw (WINDOW *, const char *,va_list);  /* implemented */
     14351 extern NCURSES_EXPORT(int) vw_printw (WINDOW *, const char *,va_list); /* generated */
     14352@@ -856,23 +869,133 @@
    1374614353  * These extensions provide access to information stored in the WINDOW even
    1374714354  * when NCURSES_OPAQUE is set:
     
    1378514392+#define NCURSES_SP_NAME(name) name##_sp
    1378614393+
     14394+/* Define the sp-funcs helper function */
     14395+#define NCURSES_SP_OUTC NCURSES_SP_NAME(NCURSES_OUTC)
     14396+typedef int (*NCURSES_SP_OUTC)(SCREEN*, int);
     14397+
    1378714398+extern NCURSES_EXPORT(SCREEN*) new_prescr(void); /* implemented */
    1378814399+
     
    1379114402+extern NCURSES_EXPORT(bool) NCURSES_SP_NAME(can_change_color) (SCREEN*); /* implemented */
    1379214403+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(cbreak) (SCREEN*); /* implemented */
     14404+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(curs_set) (SCREEN*, int); /* implemented */
    1379314405+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(color_content) (SCREEN*, short, short*, short*, short*); /* implemented */
    1379414406+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(def_prog_mode) (SCREEN*); /* implemented */
     
    1380214414+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(flash) (SCREEN*); /* implemented */
    1380314415+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(flushinp) (SCREEN*); /* implemented */
     14416+extern NCURSES_EXPORT(WINDOW *) NCURSES_SP_NAME(getwin) (SCREEN*, FILE *);                     /* implemented */
    1380414417+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(halfdelay)(SCREEN*, int); /* implemented */
    1380514418+extern NCURSES_EXPORT(bool) NCURSES_SP_NAME(has_colors) (SCREEN*); /* implemented */
     
    1381614429+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(napms) (SCREEN*, int); /* implemented */
    1381714430+extern NCURSES_EXPORT(WINDOW *) NCURSES_SP_NAME(newpad) (SCREEN*, int, int); /* implemented */
    13818 +extern NCURSES_EXPORT(SCREEN *) NCURSES_SP_NAME(newterm) (SCREEN*, NCURSES_CONST char *, FILE *, FILE *); /* implemented */
     14431+extern NCURSES_EXPORT(SCREEN*) NCURSES_SP_NAME(newterm) (SCREEN*, NCURSES_CONST char *, FILE *, FILE *); /* implemented */
    1381914432+extern NCURSES_EXPORT(WINDOW *) NCURSES_SP_NAME(newwin) (SCREEN*, int, int, int, int); /* implemented */
    1382014433+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(nl) (SCREEN*); /* implemented */
    1382114434+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(nocbreak) (SCREEN*); /* implemented */
    1382214435+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(noecho) (SCREEN*); /* implemented */
    13823 +extern NCURSES_EXPORT(void) NCURSES_SP_NAME(nofilter) (SCREEN*); /* implemented */
    1382414436+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(nonl) (SCREEN*); /* implemented */
    1382514437+extern NCURSES_EXPORT(void) NCURSES_SP_NAME(noqiflush) (SCREEN*); /* implemented */
     
    1383014442+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(reset_prog_mode) (SCREEN*); /* implemented */
    1383114443+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(reset_shell_mode) (SCREEN*); /* implemented */
     14444+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(resetty) (SCREEN*); /* implemented */
    1383214445+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(ripoffline) (SCREEN*, int, int (*)(WINDOW *, int)); /* implemented */
     14446+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(savetty) (SCREEN*); /* implemented */
    1383314447+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(scr_init) (SCREEN*, const char *); /* implemented */
    1383414448+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(scr_restore) (SCREEN*, const char *); /* implemented */
     
    1385414468+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(ungetch) (SCREEN*, int); /* implemented */
    1385514469+extern NCURSES_EXPORT(void) NCURSES_SP_NAME(use_env) (SCREEN*, bool); /* implemented */
     14470+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(vidattr) (SCREEN*, chtype); /* implemented */
     14471+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(vidputs) (SCREEN*, chtype, NCURSES_SP_OUTC); /* implemented */
    1385614472+#if @NCURSES_EXT_FUNCS@
    1385714473+extern NCURSES_EXPORT(char *) NCURSES_SP_NAME(keybound) (SCREEN*, int, int);
     
    1385914475+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(define_key) (SCREEN*, const char *, int);
    1386014476+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(get_escdelay) (SCREEN*);
     14477+extern NCURSES_EXPORT(bool) NCURSES_SP_NAME(is_term_resized) (SCREEN*, int, int);
    1386114478+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(key_defined)(SCREEN*, const char *);
    1386214479+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(keyok) (SCREEN*, int, bool);
     14480+extern NCURSES_EXPORT(void) NCURSES_SP_NAME(nofilter) (SCREEN*); /* implemented */
     14481+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(resize_term) (SCREEN*, int, int);
     14482+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(resizeterm) (SCREEN*, int, int);
    1386314483+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(set_escdelay) (SCREEN*, int);
    1386414484+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(set_tabsize) (SCREEN*, int);
     
    1387014490+#define NCURSES_SP_FUNCS 0
    1387114491+#define NCURSES_SP_NAME(name) name
     14492+#define NCURSES_SP_OUTC NCURSES_OUTC
    1387214493+#endif
    1387314494+
     
    1387514496 
    1387614497 #define NCURSES_ATTR_SHIFT       8
    13877 @@ -1173,7 +1270,7 @@
     14498@@ -971,9 +1094,9 @@
     14499 #if !NCURSES_OPAQUE
     14500 #if defined(_XOPEN_SOURCE_EXTENDED) && @NCURSES_EXT_COLORS@
     14501 #define wattrset(win,at)       ((win)->_color = PAIR_NUMBER(at), \
     14502-                                (win)->_attrs = (at))
     14503+                                 NCURSES_CAST(int, (win)->_attrs = (at)))
     14504 #else
     14505-#define wattrset(win,at)       ((win)->_attrs = (at))
     14506+#define wattrset(win,at)        NCURSES_CAST(int, (win)->_attrs = (at))
     14507 #endif
     14508 #endif /* NCURSES_OPAQUE */
     14509 
     14510@@ -1173,7 +1296,7 @@
    1387814511  *        It gives the ESC expire time in milliseconds.
    1387914512  *     b. ttytype is needed for backward compatibility
     
    1388614519diff -Naur ncurses-5.7.orig/include/curses.tail ncurses-5.7/include/curses.tail
    1388714520--- ncurses-5.7.orig/include/curses.tail        2008-07-05 13:20:38.000000000 -0700
    13888 +++ ncurses-5.7/include/curses.tail     2009-02-28 20:38:37.161961447 -0800
     14521+++ ncurses-5.7/include/curses.tail     2009-06-05 14:01:54.000000000 -0700
    1388914522@@ -1,4 +1,4 @@
    1389014523-/* $Id: curses.tail,v 1.16 2008/07/05 20:20:38 tom Exp $ */
    13891 +/* $Id: curses.tail,v 1.17 2008/11/23 00:12:12 tom Exp $ */
     14524+/* $Id: curses.tail,v 1.19 2009/05/23 19:19:43 tom Exp $ */
    1389214525 /*
    1389314526  * vile:cmode:
    1389414527  * This file is part of ncurses, designed to be appended after curses.h.in
    13895 @@ -94,6 +94,7 @@
     14528@@ -94,13 +94,22 @@
    1389614529 }
    1389714530 MEVENT;
    1389814531 
    13899 +extern NCURSES_EXPORT(bool) has_mouse (void);
    13900  extern NCURSES_EXPORT(int) getmouse (MEVENT *);
    13901  extern NCURSES_EXPORT(int) ungetmouse (MEVENT *);
     14532-extern NCURSES_EXPORT(int) getmouse (MEVENT *);
     14533-extern NCURSES_EXPORT(int) ungetmouse (MEVENT *);
     14534+extern NCURSES_EXPORT(bool)    has_mouse(void);
     14535+extern NCURSES_EXPORT(int)     getmouse (MEVENT *);
     14536+extern NCURSES_EXPORT(int)     ungetmouse (MEVENT *);
    1390214537 extern NCURSES_EXPORT(mmask_t) mousemask (mmask_t, mmask_t *);
     14538-extern NCURSES_EXPORT(bool) wenclose (const WINDOW *, int, int);
     14539-extern NCURSES_EXPORT(int) mouseinterval (int);
     14540-extern NCURSES_EXPORT(bool) wmouse_trafo (const WINDOW*, int*, int*, bool);
     14541-extern NCURSES_EXPORT(bool) mouse_trafo (int*, int*, bool);              /* generated */
     14542+extern NCURSES_EXPORT(bool)    wenclose (const WINDOW *, int, int);
     14543+extern NCURSES_EXPORT(int)     mouseinterval (int);
     14544+extern NCURSES_EXPORT(bool)    wmouse_trafo (const WINDOW*, int*, int*, bool);
     14545+extern NCURSES_EXPORT(bool)    mouse_trafo (int*, int*, bool);              /* generated */
     14546+
     14547+#if NCURSES_SP_FUNCS
     14548+extern NCURSES_EXPORT(bool)    NCURSES_SP_NAME(has_mouse) (SCREEN*);
     14549+extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(getmouse) (SCREEN*, MEVENT *);
     14550+extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(ungetmouse) (SCREEN*,MEVENT *);
     14551+extern NCURSES_EXPORT(mmask_t) NCURSES_SP_NAME(mousemask) (SCREEN*, mmask_t, mmask_t *);
     14552+extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(mouseinterval) (SCREEN*, int);
     14553+#endif
     14554 
     14555 #define mouse_trafo(y,x,to_screen) wmouse_trafo(stdscr,y,x,to_screen)
     14556 
     14557@@ -109,6 +118,11 @@
     14558 extern NCURSES_EXPORT(int) mcprint (char *, int);      /* direct data to printer */
     14559 extern NCURSES_EXPORT(int) has_key (int);              /* do we have given key? */
     14560 
     14561+#if NCURSES_SP_FUNCS
     14562+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(has_key) (SCREEN*, int);    /* do we have given key? */
     14563+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(mcprint) (SCREEN*, char *, int);    /* direct data to printer */
     14564+#endif
     14565+
     14566 /* Debugging : use with libncurses_g.a */
     14567 
     14568 extern NCURSES_EXPORT(void) _tracef (const char *, ...) GCC_PRINTFLIKE(1,2);
     14569@@ -160,6 +174,8 @@
     14570 #define OPTIMIZE_ALL           0xff    /* enable all optimizations (dflt) */
     14571 #endif
     14572 
     14573+#include <unctrl.h>
     14574+
     14575 #ifdef __cplusplus
     14576 
     14577 #ifndef NCURSES_NOMACROS
    1390314578diff -Naur ncurses-5.7.orig/include/curses.wide ncurses-5.7/include/curses.wide
    1390414579--- ncurses-5.7.orig/include/curses.wide        2007-03-10 09:52:23.000000000 -0800
    13905 +++ ncurses-5.7/include/curses.wide     2009-02-28 20:38:38.454044419 -0800
     14580+++ ncurses-5.7/include/curses.wide     2009-06-05 14:01:51.000000000 -0700
    1390614581@@ -1,9 +1,11 @@
    1390714582-/* $Id: curses.wide,v 1.34 2007/03/10 17:52:23 tom Exp $ */
    13908 +/* $Id: curses.wide,v 1.36 2008/11/29 18:44:08 tom Exp $ */
     14583+/* $Id: curses.wide,v 1.39 2009/05/09 15:43:00 tom Exp $ */
    1390914584 /*
    1391014585  * vile:cmode:
     
    1391714592 
    1391814593 extern NCURSES_EXPORT_VAR(cchar_t *) _nc_wacs;
     14594@@ -138,7 +140,7 @@
     14595 extern NCURSES_EXPORT(attr_t) term_attrs (void);                       /* implemented */
     14596 extern NCURSES_EXPORT(int) unget_wch (const wchar_t);                  /* implemented */
     14597 extern NCURSES_EXPORT(int) vid_attr (attr_t, short, void *);           /* implemented */
     14598-extern NCURSES_EXPORT(int) vid_puts (attr_t, short, void *, int (*)(int)); /* implemented */
     14599+extern NCURSES_EXPORT(int) vid_puts (attr_t, short, void *, NCURSES_OUTC); /* implemented */
     14600 extern NCURSES_EXPORT(int) vline_set (const cchar_t *, int);           /* generated:WIDEC */
     14601 extern NCURSES_EXPORT(int) wadd_wch (WINDOW *,const cchar_t *);                /* implemented */
     14602 extern NCURSES_EXPORT(int) wadd_wchnstr (WINDOW *,const cchar_t *,int);        /* implemented */
     14603@@ -165,6 +167,14 @@
     14604 extern NCURSES_EXPORT(wchar_t*) wunctrl (cchar_t *);                   /* implemented */
     14605 extern NCURSES_EXPORT(int) wvline_set (WINDOW *, const cchar_t *, int);        /* implemented */
     14606 
     14607+#if NCURSES_SP_FUNCS
     14608+extern NCURSES_EXPORT(attr_t) NCURSES_SP_NAME(term_attrs) (SCREEN*);           /* implemented */
     14609+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(unget_wch) (SCREEN*, const wchar_t);        /* implemented */
     14610+extern NCURSES_EXPORT(wchar_t*) NCURSES_SP_NAME(wunctrl) (SCREEN*, cchar_t *); /* implemented */
     14611+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(vid_attr) (SCREEN*, attr_t, short, void *);
     14612+extern NCURSES_EXPORT(int) NCURSES_SP_NAME(vid_puts) (SCREEN*, attr_t, short, void *, NCURSES_SP_OUTC);
     14613+#endif
     14614+
     14615 #ifndef NCURSES_NOMACROS
     14616 
     14617 /*
    1391914618diff -Naur ncurses-5.7.orig/include/MKterm.h.awk.in ncurses-5.7/include/MKterm.h.awk.in
    1392014619--- ncurses-5.7.orig/include/MKterm.h.awk.in    2008-05-24 16:13:59.000000000 -0700
    13921 +++ ncurses-5.7/include/MKterm.h.awk.in 2009-02-28 20:38:59.855417236 -0800
     14620+++ ncurses-5.7/include/MKterm.h.awk.in 2009-06-05 14:01:51.000000000 -0700
    1392214621@@ -1,7 +1,7 @@
    1392314622 # vile:awkmode
     
    1393414633                    print  ""
    1393514634-                   print  "/* $Id: MKterm.h.awk.in,v 1.50 2008/05/24 23:13:59 tom Exp $ */"
    13936 +                   print  "/* $Id: MKterm.h.awk.in,v 1.53 2009/02/28 21:27:45 tom Exp $ */"
     14635+                   print  "/* $Id: MKterm.h.awk.in,v 1.57 2009/05/09 15:54:50 tom Exp $ */"
    1393714636                    print  ""
    1393814637                    print  "/*"
    1393914638                    print  "**  term.h -- Definition of struct term"
    13940 @@ -228,8 +228,16 @@
     14639@@ -130,11 +130,15 @@
     14640                    print  ""
     14641                    print  "#else /* !HAVE_TERMIO_H */"
     14642                    print  ""
     14643+                   print  "#if __MINGW32__"
     14644+                   print  "#  include <ncurses_mingw.h>"
     14645+                   print  "#  define TTY struct termios"
     14646+                   print  "#else"
     14647                    print  "#undef TERMIOS"
     14648                    print  "#include <sgtty.h>"
     14649                    print  "#include <sys/ioctl.h>"
     14650                    print  "#define TTY struct sgttyb"
     14651-                   print  ""
     14652+                   print  "#endif /* MINGW32 */"
     14653                    print  "#endif /* HAVE_TERMIO_H */"
     14654                    print  ""
     14655                    print  "#endif /* HAVE_TERMIOS_H */"
     14656@@ -228,8 +232,16 @@
    1394114657                        print  "    char *      _termname;      /* used for termname() */"
    1394214658                        print  "} TERMINAL;"
     
    1395614672                        print  "NCURSES_WRAPPED_VAR(NCURSES_CONST char * const *, boolcodes);"
    1395714673                        print  "NCURSES_WRAPPED_VAR(NCURSES_CONST char * const *, boolfnames);"
    13958 @@ -240,7 +248,6 @@
     14674@@ -240,7 +252,6 @@
    1395914675                        print  "NCURSES_WRAPPED_VAR(NCURSES_CONST char * const *, strcodes);"
    1396014676                        print  "NCURSES_WRAPPED_VAR(NCURSES_CONST char * const *, strfnames);"
     
    1396414680                        print  "#define boolcodes  NCURSES_PUBLIC_VAR(boolcodes())"
    1396514681                        print  "#define boolfnames NCURSES_PUBLIC_VAR(boolfnames())"
    13966 @@ -253,8 +260,6 @@
     14682@@ -253,8 +264,6 @@
    1396714683                        print  ""
    1396814684                        print  "#else"
     
    1397314689                        print  "extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) boolcodes[];"
    1397414690                        print  "extern NCURSES_EXPORT_VAR(NCURSES_CONST char * const ) boolfnames[];"
     14691@@ -312,6 +321,37 @@
     14692                        print  "extern NCURSES_EXPORT(int) tputs (const char *, int, int (*)(int));"
     14693                        print  "#endif /* NCURSES_TERMCAP_H_incl */"
     14694                        print  ""
     14695+                       print  "/*"
     14696+                       print  " * Include curses.h before term.h to enable these extensions."
     14697+                       print  " */"
     14698+                       print  "#if defined(NCURSES_SP_FUNCS) && (NCURSES_SP_FUNCS != 0)"
     14699+                       print  ""
     14700+                       print  "extern NCURSES_EXPORT(char *)  NCURSES_SP_NAME(tigetstr) (SCREEN*, NCURSES_CONST char *);"
     14701+                       print  "extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(putp) (SCREEN*, const char *);"
     14702+                       print  "extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(tigetflag) (SCREEN*, NCURSES_CONST char *);"
     14703+                       print  "extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(tigetnum) (SCREEN*, NCURSES_CONST char *);"
     14704+                       print  ""
     14705+                       print  "#if @NCURSES_TPARM_VARARGS@ /* NCURSES_TPARM_VARARGS */"
     14706+                       print  "extern NCURSES_EXPORT(char *)  NCURSES_SP_NAME(tparm) (SCREEN*, NCURSES_CONST char *, ...);     /* special */"
     14707+                       print  "#else"
     14708+                       print  "extern NCURSES_EXPORT(char *)  NCURSES_SP_NAME(tparm) (SCREEN*, NCURSES_CONST char *, long,long,long,long,long,long,long,long,long);    /* special */"
     14709+                       print  "extern NCURSES_EXPORT(char *)  NCURSES_SP_NAME(tparm_varargs) (SCREEN*, NCURSES_CONST char *, ...);     /* special */"
     14710+                       print  "#endif"
     14711+                       print  ""
     14712+                       print  "/* termcap database emulation (XPG4 uses const only for 2nd param of tgetent) */"
     14713+                       print  "extern NCURSES_EXPORT(char *)  NCURSES_SP_NAME(tgetstr) (SCREEN*, NCURSES_CONST char *, char **);"
     14714+                       print  "extern NCURSES_EXPORT(char *)  NCURSES_SP_NAME(tgoto) (SCREEN*, const char *, int, int);"
     14715+                       print  "extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(tgetent) (SCREEN*, char *, const char *);"
     14716+                       print  "extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(tgetflag) (SCREEN*, NCURSES_CONST char *);"
     14717+                       print  "extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(tgetnum) (SCREEN*, NCURSES_CONST char *);"
     14718+                       print  "extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(tputs) (SCREEN*, const char *, int, NCURSES_SP_OUTC);"
     14719+                       print  ""
     14720+                       print  "extern NCURSES_EXPORT(TERMINAL *) NCURSES_SP_NAME(set_curterm) (SCREEN*, TERMINAL *);"
     14721+                       print  "extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(del_curterm) (SCREEN*, TERMINAL *);"
     14722+                       print  ""
     14723+                       print  "extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(restartterm) (SCREEN*, NCURSES_CONST char *, int, int *);"
     14724+                       print  "#endif /* NCURSES_SP_FUNCS */"
     14725+                       print  ""
     14726                        print  "#ifdef __cplusplus"
     14727                        print  "}"
     14728                        print  "#endif"
     14729diff -Naur ncurses-5.7.orig/include/nc_alloc.h ncurses-5.7/include/nc_alloc.h
     14730--- ncurses-5.7.orig/include/nc_alloc.h 2008-09-27 15:30:33.000000000 -0700
     14731+++ ncurses-5.7/include/nc_alloc.h      2009-06-05 14:01:44.000000000 -0700
     14732@@ -1,5 +1,5 @@
     14733 /****************************************************************************
     14734- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     14735+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     14736  *                                                                          *
     14737  * Permission is hereby granted, free of charge, to any person obtaining a  *
     14738  * copy of this software and associated documentation files (the            *
     14739@@ -29,7 +29,7 @@
     14740 /****************************************************************************
     14741  *  Author: Thomas E. Dickey                    1996-on                     *
     14742  ****************************************************************************/
     14743-/* $Id: nc_alloc.h,v 1.16 2008/09/27 22:30:33 tom Exp $ */
     14744+/* $Id: nc_alloc.h,v 1.17 2009/04/18 20:48:19 tom Exp $ */
     14745 
     14746 #ifndef NC_ALLOC_included
     14747 #define NC_ALLOC_included 1
     14748@@ -74,9 +74,15 @@
     14749 extern NCURSES_EXPORT(void) _nc_free_tparm(void);
     14750 extern NCURSES_EXPORT(void) _nc_leaks_dump_entry(void);
     14751 extern NCURSES_EXPORT(void) _nc_leaks_tic(void);
     14752-#define ExitProgram(code) _nc_free_and_exit(code)
     14753+
     14754+#if NCURSES_SP_FUNCS
     14755+extern NCURSES_EXPORT(void) NCURSES_SP_NAME(_nc_free_and_exit)(SCREEN*, int) GCC_NORETURN;
     14756 #endif
     14757 
     14758+#define ExitProgram(code) _nc_free_and_exit(code)
     14759+
     14760+#endif /* NO_LEAKS, etc */
     14761+
     14762 #ifndef HAVE_NC_FREEALL
     14763 #define HAVE_NC_FREEALL 0
     14764 #endif
     14765diff -Naur ncurses-5.7.orig/include/nc_panel.h ncurses-5.7/include/nc_panel.h
     14766--- ncurses-5.7.orig/include/nc_panel.h 2008-08-04 11:26:46.000000000 -0700
     14767+++ ncurses-5.7/include/nc_panel.h      2009-06-05 14:01:33.000000000 -0700
     14768@@ -1,5 +1,5 @@
     14769 /****************************************************************************
     14770- * Copyright (c) 1998-2000,2008 Free Software Foundation, Inc.              *
     14771+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     14772  *                                                                          *
     14773  * Permission is hereby granted, free of charge, to any person obtaining a  *
     14774  * copy of this software and associated documentation files (the            *
     14775@@ -33,7 +33,7 @@
     14776 
     14777 
     14778 /*
     14779- * $Id: nc_panel.h,v 1.5 2008/08/04 18:26:46 tom Exp $
     14780+ * $Id: nc_panel.h,v 1.6 2009/04/11 21:17:57 tom Exp $
     14781  *
     14782  *     nc_panel.h
     14783  *
     14784@@ -62,6 +62,10 @@
     14785 /* Retrieve the panelhook of the current screen */
     14786 extern NCURSES_EXPORT(struct panelhook*) _nc_panelhook (void);
     14787 
     14788+#if NCURSES_SP_FUNCS
     14789+extern NCURSES_EXPORT(struct panelhook*) NCURSES_SP_NAME(_nc_panelhook) (SCREEN *);
     14790+#endif
     14791+
     14792 #ifdef __cplusplus
     14793 }
     14794 #endif
     14795diff -Naur ncurses-5.7.orig/include/ncurses_defs ncurses-5.7/include/ncurses_defs
     14796--- ncurses-5.7.orig/include/ncurses_defs       2008-09-06 08:57:41.000000000 -0700
     14797+++ ncurses-5.7/include/ncurses_defs    2009-06-05 14:01:49.000000000 -0700
     14798@@ -1,4 +1,4 @@
     14799-# $Id: ncurses_defs,v 1.40 2008/09/06 15:57:41 tom Exp $
     14800+# $Id: ncurses_defs,v 1.41 2008/11/16 00:19:59 juergen Exp $
     14801 ##############################################################################
     14802 # Copyright (c) 2000-2007,2008 Free Software Foundation, Inc.                #
     14803 #                                                                            #
     14804@@ -171,7 +171,6 @@
     14805 NCURSES_EXT_FUNCS
     14806 NCURSES_NO_PADDING
     14807 NCURSES_PATHSEP        ':'
     14808-NDEBUG
     14809 NEED_PTEM_H
     14810 NO_LEAKS
     14811 PURE_TERMINFO
     14812diff -Naur ncurses-5.7.orig/include/ncurses_dll.h ncurses-5.7/include/ncurses_dll.h
     14813--- ncurses-5.7.orig/include/ncurses_dll.h      2007-03-10 11:21:49.000000000 -0800
     14814+++ ncurses-5.7/include/ncurses_dll.h   2009-06-05 14:01:44.000000000 -0700
     14815@@ -1,5 +1,5 @@
     14816 /****************************************************************************
     14817- * Copyright (c) 1998-2006,2007 Free Software Foundation, Inc.              *
     14818+ * Copyright (c) 1998-2007,2009 Free Software Foundation, Inc.              *
     14819  *                                                                          *
     14820  * Permission is hereby granted, free of charge, to any person obtaining a  *
     14821  * copy of this software and associated documentation files (the            *
     14822@@ -25,7 +25,7 @@
     14823  * sale, use or other dealings in this Software without prior written       *
     14824  * authorization.                                                           *
     14825  ****************************************************************************/
     14826-/* $Id: ncurses_dll.h,v 1.6 2007/03/10 19:21:49 tom Exp $ */
     14827+/* $Id: ncurses_dll.h,v 1.8 2009/04/04 22:26:27 tom Exp $ */
     14828 
     14829 #ifndef NCURSES_DLL_H_incl
     14830 #define NCURSES_DLL_H_incl 1
     14831@@ -37,7 +37,7 @@
     14832 #undef NCURSES_DLL
     14833 #define NCURSES_STATIC
     14834 
     14835-#if defined(__CYGWIN__)
     14836+#if defined(__CYGWIN__) || defined(__MINGW32__)
     14837 #  if defined(NCURSES_DLL)
     14838 #    if defined(NCURSES_STATIC)
     14839 #      undef NCURSES_STATIC
     14840@@ -76,11 +76,4 @@
     14841 #  define NCURSES_EXPORT_VAR(type) NCURSES_IMPEXP type
     14842 #endif
     14843 
     14844-/*
     14845- * For reentrant code, we map the various global variables into SCREEN by
     14846- * using functions to access them.
     14847- */
     14848-#define NCURSES_PUBLIC_VAR(name) _nc_##name
     14849-#define NCURSES_WRAPPED_VAR(type,name) extern type NCURSES_PUBLIC_VAR(name)(void)
     14850-
     14851 #endif /* NCURSES_DLL_H_incl */
     14852diff -Naur ncurses-5.7.orig/include/term_entry.h ncurses-5.7/include/term_entry.h
     14853--- ncurses-5.7.orig/include/term_entry.h       2008-08-16 09:16:03.000000000 -0700
     14854+++ ncurses-5.7/include/term_entry.h    2009-06-05 14:01:33.000000000 -0700
     14855@@ -32,7 +32,7 @@
     14856  *     and: Thomas E. Dickey                        1998-on                 *
     14857  ****************************************************************************/
     14858 
     14859-/* $Id: term_entry.h,v 1.35 2008/08/16 16:16:03 tom Exp $ */
     14860+/* $Id: term_entry.h,v 1.36 2008/11/16 00:19:59 juergen Exp $ */
     14861 
     14862 /*
     14863  *     term_entry.h -- interface to entry-manipulation code
     14864@@ -81,7 +81,7 @@
     14865 #define EXT_NAMES(tp,i,limit,index,table) table[i]
     14866 #endif
     14867 
     14868-#define NUM_EXT_NAMES(tp) ((tp)->ext_Booleans + (tp)->ext_Numbers + (tp)->ext_Strings)
     14869+#define NUM_EXT_NAMES(tp) (unsigned) ((tp)->ext_Booleans + (tp)->ext_Numbers + (tp)->ext_Strings)
     14870 
     14871 #define for_each_boolean(n,tp) for(n = 0; n < NUM_BOOLEANS(tp); n++)
     14872 #define for_each_number(n,tp)  for(n = 0; n < NUM_NUMBERS(tp);  n++)
     14873diff -Naur ncurses-5.7.orig/include/unctrl.h.in ncurses-5.7/include/unctrl.h.in
     14874--- ncurses-5.7.orig/include/unctrl.h.in        2001-03-24 13:53:25.000000000 -0800
     14875+++ ncurses-5.7/include/unctrl.h.in     2009-06-05 14:01:44.000000000 -0700
     14876@@ -1,5 +1,5 @@
     14877 /****************************************************************************
     14878- * Copyright (c) 1998,2000 Free Software Foundation, Inc.                   *
     14879+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     14880  *                                                                          *
     14881  * Permission is hereby granted, free of charge, to any person obtaining a  *
     14882  * copy of this software and associated documentation files (the            *
     14883@@ -39,7 +39,7 @@
     14884  * as ^?. Printable characters are displayed as is.
     14885  */
     14886 
     14887-/* $Id: unctrl.h.in,v 1.10 2001/03/24 21:53:25 tom Exp $ */
     14888+/* $Id: unctrl.h.in,v 1.11 2009/04/18 21:00:52 tom Exp $ */
     14889 
     14890 #ifndef NCURSES_UNCTRL_H_incl
     14891 #define NCURSES_UNCTRL_H_incl  1
     14892@@ -56,6 +56,10 @@
     14893 #undef unctrl
     14894 NCURSES_EXPORT(NCURSES_CONST char *) unctrl (chtype);
     14895 
     14896+#if @NCURSES_SP_FUNCS@
     14897+NCURSES_EXPORT(NCURSES_CONST char *) NCURSES_SP_NAME(unctrl) (SCREEN*, chtype);
     14898+#endif
     14899+
     14900 #ifdef __cplusplus
     14901 }
     14902 #endif
    1397514903diff -Naur ncurses-5.7.orig/INSTALL ncurses-5.7/INSTALL
    1397614904--- ncurses-5.7.orig/INSTALL    2008-11-02 13:13:51.000000000 -0800
    13977 +++ ncurses-5.7/INSTALL 2009-02-28 20:38:46.282546444 -0800
     14905+++ ncurses-5.7/INSTALL 2009-06-05 14:01:24.000000000 -0700
    1397814906@@ -1,5 +1,5 @@
    1397914907 -------------------------------------------------------------------------------
     
    1398814916 -------------------------------------------------------------------------------
    1398914917--- $Id: INSTALL,v 1.135 2008/11/02 21:13:51 tom Exp $
    13990 +-- $Id: INSTALL,v 1.137 2009/01/03 23:59:23 tom Exp $
     14918+-- $Id: INSTALL,v 1.138 2009/03/21 20:23:29 tom Exp $
    1399114919 ---------------------------------------------------------------------
    1399214920              How to install Ncurses/Terminfo on your system
     
    1401414942        Generate profile-libraries These are named by adding "_p" to the root,
    1401514943        e.g., libncurses_p.a
    14016 @@ -975,6 +983,9 @@
     14944@@ -946,6 +954,17 @@
     14945        For testing, compile with debug option.
     14946        This also sets the --disable-leaks option.
     14947 
     14948+    --with-wrap-prefix=XXX
     14949+       When using the --enable-reentrant option, ncurses redefines variables
     14950+       that would be global in curses, e.g., LINES, as a macro that calls a
     14951+       "wrapping" function which fetches the data from the current SCREEN
     14952+       structure.  Normally that function is named by prepending "_nc_" to the
     14953+       variable's name.  The function is technically private (since portable
     14954+       applications would not refer directly to it).  But according to one
     14955+       line of reasoning, it is not the same type of "private" as functions
     14956+       which applications should not call even via a macro.  This configure
     14957+       option lets you choose the prefix for these wrapped variables.
     14958+
     14959     --without-ada
     14960        Suppress the configure script's check for Ada95, do not build the
     14961        Ada95 binding and related demo.
     14962@@ -975,6 +994,9 @@
    1401714963     --without-dlsym
    1401814964        Do not use dlsym() to load GPM dynamically.
     
    1402614972diff -Naur ncurses-5.7.orig/man/curs_color.3x ncurses-5.7/man/curs_color.3x
    1402714973--- ncurses-5.7.orig/man/curs_color.3x  2005-12-17 16:00:37.000000000 -0800
    14028 +++ ncurses-5.7/man/curs_color.3x       2009-02-28 20:38:53.014978628 -0800
     14974+++ ncurses-5.7/man/curs_color.3x       2009-06-05 14:01:11.000000000 -0700
    1402914975@@ -1,5 +1,5 @@
    1403014976 .\"***************************************************************************
     
    1405715003diff -Naur ncurses-5.7.orig/man/curs_mouse.3x ncurses-5.7/man/curs_mouse.3x
    1405815004--- ncurses-5.7.orig/man/curs_mouse.3x  2006-12-30 15:43:34.000000000 -0800
    14059 +++ ncurses-5.7/man/curs_mouse.3x       2009-02-28 20:38:37.161961447 -0800
     15005+++ ncurses-5.7/man/curs_mouse.3x       2009-06-05 14:00:52.000000000 -0700
    1406015006@@ -1,6 +1,6 @@
    1406115007 '\" t
     
    1410115047 cause an error beep when cooked mode is being simulated in a window by a
    1410215048 function such as \fBgetstr\fR that expects a linefeed for input-loop
     15049diff -Naur ncurses-5.7.orig/man/form_field_validation.3x ncurses-5.7/man/form_field_validation.3x
     15050--- ncurses-5.7.orig/man/form_field_validation.3x       2006-12-24 08:08:08.000000000 -0800
     15051+++ ncurses-5.7/man/form_field_validation.3x    2009-06-05 14:01:33.000000000 -0700
     15052@@ -26,7 +26,7 @@
     15053 .\" authorization.                                                           *
     15054 .\"***************************************************************************
     15055 .\"
     15056-.\" $Id: form_field_validation.3x,v 1.16 2006/12/24 16:08:08 tom Exp $
     15057+.\" $Id: form_field_validation.3x,v 1.17 2008/12/14 19:22:16 juergen Exp $
     15058 .TH form_field_validation 3X ""
     15059 .SH NAME
     15060 \fBform_field_validation\fR - data type validation for fields
     15061@@ -70,9 +70,7 @@
     15062 case-sensitivity; and a fifth \fBint\fR flag argument specifying whether a partial
     15063 match must be a unique one (if this flag is off, a prefix matches the first
     15064 of any set of more than one list elements with that prefix). Please notice
     15065-that the string list is not copied, only a reference to it is stored in the
     15066-field. So you should avoid using a list that lives in automatic variables
     15067-on the stack.
     15068+that the string list is copied. So you may use a list that lives in automatic variables on the stack.
     15069 .TP 5
     15070 TYPE_INTEGER
     15071 Integer data, parsable to an integer by \fBatoi(3)\fR.  Requires a third
    1410315072diff -Naur ncurses-5.7.orig/man/keybound.3x ncurses-5.7/man/keybound.3x
    1410415073--- ncurses-5.7.orig/man/keybound.3x    2006-02-25 13:47:06.000000000 -0800
    14105 +++ ncurses-5.7/man/keybound.3x 2009-02-28 20:38:41.374231037 -0800
     15074+++ ncurses-5.7/man/keybound.3x 2009-06-05 14:00:57.000000000 -0700
    1410615075@@ -1,5 +1,5 @@
    1410715076 .\"***************************************************************************
     
    1412415093diff -Naur ncurses-5.7.orig/man/tabs.1 ncurses-5.7/man/tabs.1
    1412515094--- ncurses-5.7.orig/man/tabs.1 1969-12-31 16:00:00.000000000 -0800
    14126 +++ ncurses-5.7/man/tabs.1      2009-02-28 20:38:35.777872887 -0800
     15095+++ ncurses-5.7/man/tabs.1      2009-06-05 14:00:50.000000000 -0700
    1412715096@@ -0,0 +1,143 @@
    1412815097+.\"***************************************************************************
     
    1427115240diff -Naur ncurses-5.7.orig/man/tset.1 ncurses-5.7/man/tset.1
    1427215241--- ncurses-5.7.orig/man/tset.1 2006-12-24 07:00:30.000000000 -0800
    14273 +++ ncurses-5.7/man/tset.1      2009-02-28 20:38:35.777872887 -0800
     15242+++ ncurses-5.7/man/tset.1      2009-06-05 14:00:50.000000000 -0700
    1427415243@@ -1,5 +1,5 @@
    1427515244 .\"***************************************************************************
     
    1429215261diff -Naur ncurses-5.7.orig/MANIFEST ncurses-5.7/MANIFEST
    1429315262--- ncurses-5.7.orig/MANIFEST   2008-10-25 16:47:24.000000000 -0700
    14294 +++ ncurses-5.7/MANIFEST        2009-02-28 20:38:46.282546444 -0800
     15263+++ ncurses-5.7/MANIFEST        2009-06-05 14:01:21.000000000 -0700
    1429515264@@ -640,6 +640,7 @@
    1429615265 ./man/ncurses.3x
     
    1430915278 ./misc/jpf-indent
    1431015279 ./misc/makedef.cmd
    14311 @@ -947,6 +949,7 @@
     15280@@ -947,9 +949,11 @@
    1431215281 ./progs/infocmp.c
    1431315282 ./progs/modules
     
    1431715286 ./progs/toe.c
    1431815287 ./progs/tput.c
    14319 @@ -963,6 +966,7 @@
     15288+./progs/transform.c
     15289 ./progs/tset.c
     15290 ./tar-copy.sh
     15291 ./test/Makefile.in
     15292@@ -963,6 +967,7 @@
    1432015293 ./test/cardfile.c
    1432115294 ./test/cardfile.dat
     
    1432515298 ./test/configure
    1432615299 ./test/configure.in
    14327 @@ -990,6 +994,7 @@
     15300@@ -990,6 +995,7 @@
    1432815301 ./test/inch_wide.c
    1432915302 ./test/inchs.c
     
    1433515308diff -Naur ncurses-5.7.orig/menu/Makefile.in ncurses-5.7/menu/Makefile.in
    1433615309--- ncurses-5.7.orig/menu/Makefile.in   2007-04-28 07:56:11.000000000 -0700
    14337 +++ ncurses-5.7/menu/Makefile.in        2009-02-28 20:38:46.310547562 -0800
     15310+++ ncurses-5.7/menu/Makefile.in        2009-06-05 14:01:30.000000000 -0700
    1433815311@@ -1,6 +1,6 @@
    1433915312-# $Id: Makefile.in,v 1.48 2007/04/28 14:56:11 tom Exp $
    14340 +# $Id: Makefile.in,v 1.49 2009/01/03 19:09:26 tom Exp $
     15313+# $Id: Makefile.in,v 1.50 2009/03/28 18:22:39 Charles.Wilson Exp $
    1434115314 ##############################################################################
    1434215315-# Copyright (c) 1998-2006,2007 Free Software Foundation, Inc.                #
     
    1434515318 # Permission is hereby granted, free of charge, to any person obtaining a    #
    1434615319 # copy of this software and associated documentation files (the "Software"), #
    14347 @@ -70,7 +70,7 @@
     15320@@ -63,6 +63,7 @@
     15321 LIBTOOL_LINK   = @LIB_LINK@
     15322 LIBTOOL_INSTALL        = @LIB_INSTALL@
     15323 LIBTOOL_UNINSTALL = @LIB_UNINSTALL@
     15324+LT_UNDEF       = @LT_UNDEF@
     15325 
     15326 INSTALL                = @INSTALL@
     15327 INSTALL_LIB    = @INSTALL@ @INSTALL_LIB@
     15328@@ -70,7 +71,7 @@
    1434815329 INSTALL_DATA   = @INSTALL_DATA@
    1434915330 
     
    1435415335 LD             = @LD@
    1435515336 LN_S           = @LN_S@
     15337diff -Naur ncurses-5.7.orig/menu/m_attribs.c ncurses-5.7/menu/m_attribs.c
     15338--- ncurses-5.7.orig/menu/m_attribs.c   2004-12-11 15:29:12.000000000 -0800
     15339+++ ncurses-5.7/menu/m_attribs.c        2009-06-05 14:01:33.000000000 -0700
     15340@@ -37,7 +37,7 @@
     15341 
     15342 #include "menu.priv.h"
     15343 
     15344-MODULE_ID("$Id: m_attribs.c,v 1.14 2004/12/11 23:29:12 tom Exp $")
     15345+MODULE_ID("$Id: m_attribs.c,v 1.15 2008/11/16 00:19:59 juergen Exp $")
     15346 
     15347 /* Macro to redraw menu if it is posted and changed */
     15348 #define Refresh_Menu(menu) \
     15349@@ -49,9 +49,9 @@
     15350 
     15351 /* "Template" macro to generate a function to set a menus attribute */
     15352 #define GEN_MENU_ATTR_SET_FCT( name ) \
     15353-NCURSES_IMPEXP int NCURSES_API set_menu_ ## name (MENU * menu, chtype attr)\
     15354+NCURSES_IMPEXP int NCURSES_API set_menu_ ## name (MENU* menu, chtype attr) \
     15355 {\
     15356-   T((T_CALLED("set_menu_" #name "(%p,%s)"), menu, _traceattr(attr)));\
     15357+  T((T_CALLED("set_menu_" #name "(%p,%s)"), menu, _traceattr(attr))); \
     15358    if (!(attr==A_NORMAL || (attr & A_ATTRIBUTES)==attr))\
     15359       RETURN(E_BAD_ARGUMENT);\
     15360    if (menu && ( menu -> name != attr))\
     15361@@ -140,4 +140,5 @@
     15362 |   Return Values :  Attribute value
     15363 +--------------------------------------------------------------------------*/
     15364 GEN_MENU_ATTR_GET_FCT(grey)
     15365+
     15366 /* m_attribs.c ends here */
    1435615367diff -Naur ncurses-5.7.orig/menu/m_cursor.c ncurses-5.7/menu/m_cursor.c
    1435715368--- ncurses-5.7.orig/menu/m_cursor.c    2005-10-22 16:03:32.000000000 -0700
    14358 +++ ncurses-5.7/menu/m_cursor.c 2009-02-28 20:38:59.855417236 -0800
     15369+++ ncurses-5.7/menu/m_cursor.c 2009-06-05 14:01:18.000000000 -0700
    1435915370@@ -1,5 +1,5 @@
    1436015371 /****************************************************************************
     
    1438415395diff -Naur ncurses-5.7.orig/menu/m_driver.c ncurses-5.7/menu/m_driver.c
    1438515396--- ncurses-5.7.orig/menu/m_driver.c    2008-08-03 15:08:22.000000000 -0700
    14386 +++ ncurses-5.7/menu/m_driver.c 2009-02-28 20:38:59.855417236 -0800
     15397+++ ncurses-5.7/menu/m_driver.c 2009-06-05 14:01:18.000000000 -0700
    1438715398@@ -1,5 +1,5 @@
    1438815399 /****************************************************************************
     
    1441015421 |   Description   :  Central dispatcher for the menu. Translates the logical
    1441115422 |                    request 'c' into a menu action.
     15423diff -Naur ncurses-5.7.orig/menu/menu.h ncurses-5.7/menu/menu.h
     15424--- ncurses-5.7.orig/menu/menu.h        2007-02-24 09:32:13.000000000 -0800
     15425+++ ncurses-5.7/menu/menu.h     2009-06-05 14:01:33.000000000 -0700
     15426@@ -1,5 +1,5 @@
     15427 /****************************************************************************
     15428- * Copyright (c) 1998-2003,2007 Free Software Foundation, Inc.              *
     15429+ * Copyright (c) 1998-2007,2009 Free Software Foundation, Inc.              *
     15430  *                                                                          *
     15431  * Permission is hereby granted, free of charge, to any person obtaining a  *
     15432  * copy of this software and associated documentation files (the            *
     15433@@ -30,7 +30,7 @@
     15434  *   Author:  Juergen Pfeifer, 1995,1997                                    *
     15435  ****************************************************************************/
     15436 
     15437-/* $Id: menu.h,v 1.19 2007/02/24 17:32:13 tom Exp $ */
     15438+/* $Id: menu.h,v 1.20 2009/04/05 00:28:07 tom Exp $ */
     15439 
     15440 #ifndef ETI_MENU
     15441 #define ETI_MENU
     15442@@ -249,6 +249,10 @@
     15443 
     15444 extern NCURSES_EXPORT(void)    menu_format (const MENU *,int *,int *);
     15445 
     15446+#if NCURSES_SP_FUNCS
     15447+extern NCURSES_EXPORT(MENU *)  NCURSES_SP_NAME(new_menu) (SCREEN*, ITEM **);
     15448+#endif
     15449+
     15450 #ifdef __cplusplus
     15451   }
     15452 #endif
    1441215453diff -Naur ncurses-5.7.orig/menu/menu.priv.h ncurses-5.7/menu/menu.priv.h
    1441315454--- ncurses-5.7.orig/menu/menu.priv.h   2005-01-15 17:02:23.000000000 -0800
    14414 +++ ncurses-5.7/menu/menu.priv.h        2009-02-28 20:38:59.859415560 -0800
     15455+++ ncurses-5.7/menu/menu.priv.h        2009-06-05 14:01:18.000000000 -0700
    1441515456@@ -1,5 +1,5 @@
    1441615457 /****************************************************************************
     
    1444515486diff -Naur ncurses-5.7.orig/menu/m_global.c ncurses-5.7/menu/m_global.c
    1444615487--- ncurses-5.7.orig/menu/m_global.c    2005-12-31 13:51:52.000000000 -0800
    14447 +++ ncurses-5.7/menu/m_global.c 2009-02-28 20:38:59.855417236 -0800
     15488+++ ncurses-5.7/menu/m_global.c 2009-06-05 14:01:18.000000000 -0700
    1444815489@@ -1,5 +1,5 @@
    1444915490 /****************************************************************************
     
    1448415525   ITEM *cur_item;
    1448515526   bool mterm_called = FALSE;
     15527diff -Naur ncurses-5.7.orig/menu/m_new.c ncurses-5.7/menu/m_new.c
     15528--- ncurses-5.7.orig/menu/m_new.c       2006-11-04 11:04:06.000000000 -0800
     15529+++ ncurses-5.7/menu/m_new.c    2009-06-05 14:01:33.000000000 -0700
     15530@@ -1,5 +1,5 @@
     15531 /****************************************************************************
     15532- * Copyright (c) 1998-2004,2006 Free Software Foundation, Inc.              *
     15533+ * Copyright (c) 1998-2006,2009 Free Software Foundation, Inc.              *
     15534  *                                                                          *
     15535  * Permission is hereby granted, free of charge, to any person obtaining a  *
     15536  * copy of this software and associated documentation files (the            *
     15537@@ -37,11 +37,11 @@
     15538 
     15539 #include "menu.priv.h"
     15540 
     15541-MODULE_ID("$Id: m_new.c,v 1.18 2006/11/04 19:04:06 tom Exp $")
     15542+MODULE_ID("$Id: m_new.c,v 1.19 2009/04/05 00:32:13 tom Exp $")
     15543 
     15544 /*---------------------------------------------------------------------------
     15545 |   Facility      :  libnmenu 
     15546-|   Function      :  MENU *new_menu(ITEM **items)
     15547+|   Function      :  MENU* _nc_new_menu(SCREEN*, ITEM **items)
     15548 |   
     15549 |   Description   :  Creates a new menu connected to the item pointer
     15550 |                    array items and returns a pointer to the new menu.
     15551@@ -51,18 +51,25 @@
     15552 |   Return Values :  NULL on error
     15553 +--------------------------------------------------------------------------*/
     15554 NCURSES_EXPORT(MENU *)
     15555-new_menu(ITEM ** items)
     15556+NCURSES_SP_NAME(new_menu) (NCURSES_SP_DCLx ITEM ** items)
     15557 {
     15558   int err = E_SYSTEM_ERROR;
     15559   MENU *menu = (MENU *) calloc(1, sizeof(MENU));
     15560 
     15561-  T((T_CALLED("new_menu(%p)"), items));
     15562+  T((T_CALLED("new_menu(%p,%p)"), SP_PARM, items));
     15563   if (menu)
     15564     {
     15565       *menu = _nc_Default_Menu;
     15566       menu->status = 0;
     15567       menu->rows = menu->frows;
     15568       menu->cols = menu->fcols;
     15569+#if NCURSES_SP_FUNCS
     15570+      /* This ensures userwin and usersub are always non-null,
     15571+         so we can derive always the SCREEN that this menu is
     15572+         running on. */
     15573+      menu->userwin = SP_PARM->_stdscr;
     15574+      menu->usersub = SP_PARM->_stdscr;
     15575+#endif
     15576       if (items && *items)
     15577        {
     15578          if (!_nc_Connect_Items(menu, items))
     15579@@ -71,6 +78,8 @@
     15580              free(menu);
     15581              menu = (MENU *) 0;
     15582            }
     15583+         else
     15584+           err = E_OK;
     15585        }
     15586     }
     15587 
     15588@@ -82,6 +91,25 @@
     15589 
     15590 /*---------------------------------------------------------------------------
     15591 |   Facility      :  libnmenu 
     15592+|   Function      :  MENU *new_menu(ITEM **items)
     15593+|   
     15594+|   Description   :  Creates a new menu connected to the item pointer
     15595+|                    array items and returns a pointer to the new menu.
     15596+|                    The new menu is initialized with the values from the
     15597+|                    default menu.
     15598+|
     15599+|   Return Values :  NULL on error
     15600++--------------------------------------------------------------------------*/
     15601+#if NCURSES_SP_FUNCS
     15602+NCURSES_EXPORT(MENU *)
     15603+new_menu(ITEM ** items)
     15604+{
     15605+  return NCURSES_SP_NAME(new_menu) (CURRENT_SCREEN, items);
     15606+}
     15607+#endif
     15608+
     15609+/*---------------------------------------------------------------------------
     15610+|   Facility      :  libnmenu 
     15611 |   Function      :  int free_menu(MENU *menu) 
     15612 |   
     15613 |   Description   :  Disconnects menu from its associated item pointer
     15614diff -Naur ncurses-5.7.orig/menu/m_pad.c ncurses-5.7/menu/m_pad.c
     15615--- ncurses-5.7.orig/menu/m_pad.c       2004-12-25 13:40:58.000000000 -0800
     15616+++ ncurses-5.7/menu/m_pad.c    2009-06-05 14:01:33.000000000 -0700
     15617@@ -37,19 +37,19 @@
     15618 
     15619 #include "menu.priv.h"
     15620 
     15621-MODULE_ID("$Id: m_pad.c,v 1.10 2004/12/25 21:40:58 tom Exp $")
     15622+MODULE_ID("$Id: m_pad.c,v 1.11 2009/02/07 23:11:44 tom Exp $")
     15623 
     15624 /* Macro to redraw menu if it is posted and changed */
     15625 #define Refresh_Menu(menu) \
     15626    if ( (menu) && ((menu)->status & _POSTED) )\
     15627    {\
     15628       _nc_Draw_Menu( menu );\
     15629-      _nc_Show_Menu( menu );\
     15630+      _nc_Show_Menu( menu ); \
     15631    }
     15632 
     15633 /*---------------------------------------------------------------------------
     15634 |   Facility      :  libnmenu 
     15635-|   Function      :  int set_menu_pad(MENU *menu, int pad)
     15636+|   Function      :  int set_menu_pad(MENU* menu, int pad)
     15637 |   
     15638 |   Description   :  Set the character to be used to separate the item name
     15639 |                    from its description. This must be a printable
    1448615640diff -Naur ncurses-5.7.orig/menu/m_post.c ncurses-5.7/menu/m_post.c
    1448715641--- ncurses-5.7.orig/menu/m_post.c      2004-12-25 15:57:04.000000000 -0800
    14488 +++ ncurses-5.7/menu/m_post.c   2009-02-28 20:38:59.855417236 -0800
     15642+++ ncurses-5.7/menu/m_post.c   2009-06-05 14:01:18.000000000 -0700
    1448915643@@ -1,5 +1,5 @@
    1449015644 /****************************************************************************
     
    1452115675 |   Description   :  Detach menu from screen
    1452215676 |
     15677diff -Naur ncurses-5.7.orig/menu/m_sub.c ncurses-5.7/menu/m_sub.c
     15678--- ncurses-5.7.orig/menu/m_sub.c       2004-12-25 13:38:31.000000000 -0800
     15679+++ ncurses-5.7/menu/m_sub.c    2009-06-05 14:01:33.000000000 -0700
     15680@@ -37,7 +37,7 @@
     15681 
     15682 #include "menu.priv.h"
     15683 
     15684-MODULE_ID("$Id: m_sub.c,v 1.10 2004/12/25 21:38:31 tom Exp $")
     15685+MODULE_ID("$Id: m_sub.c,v 1.11 2009/04/05 00:35:51 tom Exp $")
     15686 
     15687 /*---------------------------------------------------------------------------
     15688 |   Facility      :  libnmenu 
     15689@@ -57,8 +57,22 @@
     15690     {
     15691       if (menu->status & _POSTED)
     15692        RETURN(E_POSTED);
     15693-      menu->usersub = win;
     15694-      _nc_Calculate_Item_Length_and_Width(menu);
     15695+      else
     15696+#if NCURSES_SP_FUNCS
     15697+       {
     15698+         /* We ensure that usersub is never null. So even if a null
     15699+            WINDOW parameter is passed, we store the SCREENS stdscr.
     15700+            The only MENU that can have a null usersub is the static
     15701+            _nc_default_Menu.
     15702+          */
     15703+         SCREEN *sp = _nc_screen_of(menu->usersub);
     15704+
     15705+         menu->usersub = win ? win : sp->_stdscr;
     15706+         _nc_Calculate_Item_Length_and_Width(menu);
     15707+       }
     15708+#else
     15709+       menu->usersub = win;
     15710+#endif
     15711     }
     15712   else
     15713     _nc_Default_Menu.usersub = win;
     15714@@ -68,7 +82,7 @@
     15715 
     15716 /*---------------------------------------------------------------------------
     15717 |   Facility      :  libnmenu 
     15718-|   Function      :  WINDOW *menu_sub(const MENU *menu)
     15719+|   Function      :  WINDOW* menu_sub(const MENU *menu)
     15720 |   
     15721 |   Description   :  Returns a pointer to the subwindow of the menu
     15722 |
     15723diff -Naur ncurses-5.7.orig/menu/m_win.c ncurses-5.7/menu/m_win.c
     15724--- ncurses-5.7.orig/menu/m_win.c       2004-12-25 13:39:20.000000000 -0800
     15725+++ ncurses-5.7/menu/m_win.c    2009-06-05 14:01:33.000000000 -0700
     15726@@ -37,7 +37,7 @@
     15727 
     15728 #include "menu.priv.h"
     15729 
     15730-MODULE_ID("$Id: m_win.c,v 1.15 2004/12/25 21:39:20 tom Exp $")
     15731+MODULE_ID("$Id: m_win.c,v 1.16 2009/04/05 00:38:22 tom Exp $")
     15732 
     15733 /*---------------------------------------------------------------------------
     15734 |   Facility      :  libnmenu 
     15735@@ -57,8 +57,22 @@
     15736     {
     15737       if (menu->status & _POSTED)
     15738        RETURN(E_POSTED);
     15739-      menu->userwin = win;
     15740-      _nc_Calculate_Item_Length_and_Width(menu);
     15741+      else
     15742+#if NCURSES_SP_FUNCS
     15743+       {
     15744+         /* We ensure that userwin is never null. So even if a null
     15745+            WINDOW parameter is passed, we store the SCREENS stdscr.
     15746+            The only MENU that can have a null userwin is the static
     15747+            _nc_default_Menu.
     15748+          */
     15749+         SCREEN *sp = _nc_screen_of(menu->userwin);
     15750+
     15751+         menu->userwin = win ? win : sp->_stdscr;
     15752+         _nc_Calculate_Item_Length_and_Width(menu);
     15753+       }
     15754+#else
     15755+       menu->userwin = win;
     15756+#endif
     15757     }
     15758   else
     15759     _nc_Default_Menu.userwin = win;
     15760@@ -68,7 +82,7 @@
     15761 
     15762 /*---------------------------------------------------------------------------
     15763 |   Facility      :  libnmenu 
     15764-|   Function      :  WINDOW *menu_win(const MENU *)
     15765+|   Function      :  WINDOW* menu_win(const MENU*)
     15766 |   
     15767 |   Description   :  Returns pointer to the window of the menu
     15768 |
     15769@@ -80,7 +94,7 @@
     15770   const MENU *m = Normalize_Menu(menu);
     15771 
     15772   T((T_CALLED("menu_win(%p)"), menu));
     15773-  returnWin(m->userwin ? m->userwin : stdscr);
     15774+  returnWin(Get_Menu_UserWin(m));
     15775 }
     15776 
     15777 /* m_win.c ends here */
    1452315778diff -Naur ncurses-5.7.orig/misc/gen-pkgconfig.in ncurses-5.7/misc/gen-pkgconfig.in
    1452415779--- ncurses-5.7.orig/misc/gen-pkgconfig.in      1969-12-31 16:00:00.000000000 -0800
    14525 +++ ncurses-5.7/misc/gen-pkgconfig.in   2009-02-28 20:38:53.014978628 -0800
    14526 @@ -0,0 +1,119 @@
     15780+++ ncurses-5.7/misc/gen-pkgconfig.in   2009-06-05 14:01:21.000000000 -0700
     15781@@ -0,0 +1,140 @@
    1452715782+#!@SHELL@
    14528 +# $Id: gen-pkgconfig.in,v 1.5 2009/01/24 21:06:36 tom Exp $
     15783+# $Id: gen-pkgconfig.in,v 1.7 2009/03/14 20:37:54 tom Exp $
    1452915784+##############################################################################
    1453015785+# Copyright (c) 2009 Free Software Foundation, Inc.                          #
     
    1456615821+LIB_NAME=@LIB_NAME@
    1456715822+TINFO_NAME=@TINFO_NAME@
     15823+PANEL_NAME=panel # @PANEL_NAME@
     15824+MENU_NAME=menu # @MENU_NAME@
     15825+FORM_NAME=form # @FORM_NAME@
     15826+CXX_NAME=ncurses++ # @CXX_NAME@
    1456815827+DFT_DEP_SUFFIX=@DFT_DEP_SUFFIX@
    1456915828+CXX_LIB_SUFFIX=@CXX_LIB_SUFFIX@
     
    1458115840+MAIN_LIBRARY="${LIB_NAME}@DFT_ARG_SUFFIX@"
    1458215841+SUB_LIBRARY="${TINFO_NAME}@DFT_ARG_SUFFIX@"
     15842+PANEL_LIBRARY="${PANEL_NAME}@DFT_ARG_SUFFIX@"
     15843+MENU_LIBRARY="${MENU_NAME}@DFT_ARG_SUFFIX@"
     15844+FORM_LIBRARY="${FORM_NAME}@DFT_ARG_SUFFIX@"
     15845+
     15846+SUB_LIBRARY_REQ=${SUB_LIBRARY}
     15847+TINFO_NAME_REQ=${TINFO_NAME}
     15848+if test $TINFO_NAME = $LIB_NAME ; then
     15849+       SUB_LIBRARY_REQ=
     15850+       TINFO_NAME_REQ=
     15851+fi
    1458315852+
    1458415853+for lib in ../lib/*
    1458515854+do
    1458615855+       name=`basename $lib`
     15856+       if test "$name" = "*" ; then
     15857+               break
     15858+       fi
     15859+
    1458715860+       root=`basename $name "$DFT_DEP_SUFFIX"`
    1458815861+       if test "$name" = "$root" ; then
     
    1459715870+       desc="ncurses @NCURSES_MAJOR@.@NCURSES_MINOR@"
    1459815871+       if test $name = $MAIN_LIBRARY ; then
    14599 +               reqs=
     15872+               reqs=$TINFO_NAME_REQ
    1460015873+               desc="$desc library"
    1460115874+       elif test $name = $SUB_LIBRARY ; then
    1460215875+               reqs=
    1460315876+               desc="$desc terminal interface library"
     15877+       elif expr $name : ".*${CXX_NAME}.*" >/dev/null ; then
     15878+               reqs="$PANEL_LIBRARY $MENU_LIBRARY $FORM_LIBRARY $MAIN_LIBRARY $SUB_LIBRARY_REQ"
     15879+               desc="$desc add-on library"
    1460415880+       else
    14605 +               reqs=$MAIN_LIBRARY
     15881+               reqs="$MAIN_LIBRARY $SUB_LIBRARY_REQ"
    1460615882+               desc="$desc add-on library"
    1460715883+       fi
     
    1464615922diff -Naur ncurses-5.7.orig/misc/Makefile.in ncurses-5.7/misc/Makefile.in
    1464715923--- ncurses-5.7.orig/misc/Makefile.in   2007-03-31 08:54:17.000000000 -0700
    14648 +++ ncurses-5.7/misc/Makefile.in        2009-02-28 20:38:54.335061600 -0800
     15924+++ ncurses-5.7/misc/Makefile.in        2009-06-05 14:01:12.000000000 -0700
    1464915925@@ -1,6 +1,6 @@
    1465015926-# $Id: Makefile.in,v 1.43 2007/03/31 15:54:17 tom Exp $
     
    1472916005diff -Naur ncurses-5.7.orig/misc/ncu-indent ncurses-5.7/misc/ncu-indent
    1473016006--- ncurses-5.7.orig/misc/ncu-indent    2008-08-03 08:46:44.000000000 -0700
    14731 +++ ncurses-5.7/misc/ncu-indent 2009-02-28 20:38:59.859415560 -0800
     16007+++ ncurses-5.7/misc/ncu-indent 2009-06-05 14:01:18.000000000 -0700
    1473216008@@ -26,7 +26,7 @@
    1473316009 #* sale, use or other dealings in this Software without prior written       *
     
    1477816054diff -Naur ncurses-5.7.orig/misc/ncurses-config.in ncurses-5.7/misc/ncurses-config.in
    1477916055--- ncurses-5.7.orig/misc/ncurses-config.in     2007-03-17 13:02:19.000000000 -0700
    14780 +++ ncurses-5.7/misc/ncurses-config.in  2009-02-28 20:38:53.014978628 -0800
     16056+++ ncurses-5.7/misc/ncurses-config.in  2009-06-05 14:01:21.000000000 -0700
    1478116057@@ -1,7 +1,7 @@
    1478216058 #!@SHELL@
    1478316059-# $Id: ncurses-config.in,v 1.12 2007/03/17 20:02:19 tom Exp $
    14784 +# $Id: ncurses-config.in,v 1.22 2009/01/24 21:06:45 tom Exp $
     16060+# $Id: ncurses-config.in,v 1.23 2009/03/14 19:20:57 Charles.Wilson Exp $
    1478516061 ##############################################################################
    1478616062-# Copyright (c) 2006,2007 Free Software Foundation, Inc.                     #
     
    1478916065 # Permission is hereby granted, free of charge, to any person obtaining a    #
    1479016066 # copy of this software and associated documentation files (the "Software"), #
    14791 @@ -28,58 +28,54 @@
     16067@@ -28,67 +28,70 @@
    1479216068 # authorization.                                                             #
    1479316069 ##############################################################################
     
    1480716083-THIS="ncurses@DFT_ARG_SUFFIX@"
    1480816084+THIS="@LIB_NAME@@DFT_ARG_SUFFIX@"
     16085+TINFO_LIB="@TINFO_NAME@@DFT_ARG_SUFFIX@"
    1480916086 
    1481016087 LANG=C;                export LANG
     
    1483216109        esac
    1483316110+fi
    14834  
     16111+
    1483516112+test $# = 0 && exec @SHELL@ $0 --error
    14836 +
     16113 
    1483716114+while test $# -gt 0; do
    1483816115        case "$1" in
     
    1486616143                sed -e 's,^[ ]*,,' -e 's, [ ]*, ,g' -e 's,[ ]*$,,' <<-ENDECHO
    1486716144                        $INCS
    14868 @@ -87,7 +83,7 @@
     16145 ENDECHO
    1486916146                ;;
    1487016147        --libs)
     16148+               if test @TINFO_NAME@ = @LIB_NAME@ ; then
    1487116149                sed -e 's,^[ ]*,,' -e 's, [ ]*, ,g' -e 's,[ ]*$,,' <<-ENDECHO
    1487216150-                       -L${exec_prefix}/lib @EXTRA_LDFLAGS@ -l${THIS} @LIBS@
    1487316151+                       -L$libdir @EXTRA_LDFLAGS@ -l${THIS} @LIBS@
    1487416152 ENDECHO
     16153+               else
     16154+               sed -e 's,^[ ]*,,' -e 's, [ ]*, ,g' -e 's,[ ]*$,,' <<-ENDECHO
     16155+                       -L$libdir @EXTRA_LDFLAGS@ -l${THIS} -l${TINFO_LIB} @LIBS@
     16156+ENDECHO
     16157+               fi
    1487516158                ;;
    1487616159        # identification
    14877 @@ -107,6 +103,9 @@
     16160        --version)
     16161@@ -107,6 +110,9 @@
    1487816162        --datadir)
    1487916163                echo "${datadir}"
     
    1488516169                echo "${libdir}"
    1488616170                ;;
    14887 @@ -129,9 +128,7 @@
     16171@@ -129,9 +135,7 @@
    1488816172 
    1488916173 Options:
     
    1489516179   --cflags           echos the C compiler flags needed to compile with ${THIS}
    1489616180   --libs             echos the libraries needed to link with ${THIS}
    14897 @@ -142,6 +139,7 @@
     16181@@ -142,6 +146,7 @@
    1489816182 
    1489916183   --bindir           echos the directory containing ${THIS} programs
     
    1490516189diff -Naur ncurses-5.7.orig/misc/terminfo.src ncurses-5.7/misc/terminfo.src
    1490616190--- ncurses-5.7.orig/misc/terminfo.src  2008-10-12 16:03:54.000000000 -0700
    14907 +++ ncurses-5.7/misc/terminfo.src       2009-02-28 20:38:50.326805978 -0800
     16191+++ ncurses-5.7/misc/terminfo.src       2009-06-05 14:01:49.000000000 -0700
    1490816192@@ -6,8 +6,8 @@
    1490916193 # Report bugs and new terminal descriptions to
     
    1491216196-#      $Revision: 1.341 $
    1491316197-#      $Date: 2008/10/12 23:03:54 $
    14914 +#      $Revision: 1.345 $
    14915 +#      $Date: 2009/01/11 00:47:37 $
     16198+#      $Revision: 1.348 $
     16199+#      $Date: 2009/05/02 22:23:20 $
    1491616200 #
    1491716201 # The original header is preserved below for reference.  It is noted that there
     
    1494416228 
    1494516229 ansi+enq|ncurses extension for ANSI ENQ,
    14946 @@ -1005,7 +1005,7 @@
     16230@@ -617,11 +617,45 @@
     16231        clear=\E[2J, cub1=^H, cud1=\E[B, cuf1=\E[C,
     16232        cup=\E[%i%p1%d;%p2%dH, cuu1=\E[A, el=\E[k, home=\E[H,
     16233        is2=\E[m\E[?7h, kcub1=^H, kcud1=^J, kcuf1=^L, kcuu1=^K,
     16234-       khome=^^, pfkey=\E[0;%p1%{58}%+%d;%p2"%s", rc=\E[u,
     16235+       khome=^^, pfkey=\E[0;%p1%{58}%+%d;%p2"%s"p, rc=\E[u,
     16236        rmam=\E[?7l, sc=\E[s, smam=\E[?7h, u6=\E[%i%d;%dR,
     16237        u7=\E[6n, use=klone+color, use=klone+sgr8,
     16238+
     16239+# Keypad:      Home=\0G        Up=\0H  PrPag=\0I
     16240+#              ka1,kh          kcuu1           kpp,ka3
     16241+#
     16242+#              Left=\0K        5=\0L           Right=\0M
     16243+#              kcub1           kb2             kcuf1
     16244+#
     16245+#              End=\0O         Down=\0P        NxPag=\0Q
     16246+#              kc1,kend        kcud1           kc3,knp
     16247+#
     16248+#              Ins=\0R         Del=\0S
     16249+#              kich1           kdch1
     16250+#
     16251+# On keyboard with 12 function keys,
     16252+#      shifted f-keys: F13-F24
     16253+#      control f-keys: F25-F36
     16254+#      alt f-keys:     F37-F48
     16255+# The shift/control/alt keys do not modify each other, but alt overrides both,
     16256+# and control overrides shift.
     16257+#
     16258+# <pfkey> capability for F1-F48 -TD
     16259 ansi.sys|ANSI.SYS 3.1 and later versions,
     16260-       el=\E[K, use=ansi.sys-old,
     16261+       el=\E[K, ka1=\0G, ka3=\0I, kb2=\0L, kbs=^H, kc1=\0O, kc3=\0Q,
     16262+       kcbt=\0^O, kcub1=\0K, kcud1=\0P, kcuf1=\0M, kcuu1=\0H,
     16263+       kdch1=\0S, kend=\0O, kf1=\0;, kf10=\0D, kf11=\0\205,
     16264+       kf12=\0\206, kf13=\0T, kf14=\0U, kf15=\0V, kf16=\0W,
     16265+       kf17=\0X, kf18=\0Y, kf19=\0Z, kf2=\0<, kf20=\0[, kf21=\0\\,
     16266+       kf22=\0], kf23=\0\207, kf24=\0\210, kf25=\0\^, kf26=\0_,
     16267+       kf27=\0`, kf28=\0a, kf29=\0b, kf3=\0=, kf30=\0c, kf31=\0d,
     16268+       kf32=\0e, kf33=\0f, kf34=\0g, kf35=\0\211, kf36=\0\212,
     16269+       kf37=\0h, kf38=\0i, kf39=\0j, kf4=\0>, kf40=\0k, kf41=\0l,
     16270+       kf42=\0m, kf43=\0n, kf44=\0o, kf45=\0p, kf46=\0q,
     16271+       kf47=\0\213, kf48=\0\214, kf5=\0?, kf6=\0@, kf7=\0A, kf8=\0B,
     16272+       kf9=\0C, khome=\0G, kich1=\0R, knp=\0Q, kpp=\0I,
     16273+       pfkey=\E[0;%?%p1%{11}%<%t%'\:'%e%?%p1%{13}%<%t%'z'%e%?%p1%{23}%<%t%'G'%e%?%p1%{25}%<%t%'p'%e%?%p1%'#'%<%t%'E'%e%?%p1%'%'%<%t%'f'%e%?%p1%'/'%<%t%'C'%e%{92}%;%;%;%;%;%;%;%p1%+%d;%p2"%s"p,
     16274+       use=ansi.sys-old,
     16275 
     16276 #
     16277 # Define IBM PC keypad keys for vi as per MS-Kermit while using ANSI.SYS.
     16278@@ -1005,7 +1039,7 @@
    1494716279        sc=\E7,
    1494816280        sgr=\E[10m\E[0%?%p1%p3%|%t;7%;%?%p2%t;4%;%?%p4%t;5%;%?%p5%t;2%;%?%p6%t;1%;%?%p9%t;12%e;10%;%?%p7%t;9%;m,
     
    1495316285 pc6300plus|AT&T 6300 plus,
    1495416286        OTbs, am, xon,
    14955 @@ -1416,7 +1416,7 @@
     16287@@ -1416,7 +1450,7 @@
    1495616288        setf=\E[3%?%p1%{1}%=%t4%e%p1%{3}%=%t6%e%p1%{4}%=%t1%e%p1%{6}%=%t3%e%p1%d%;m,
    1495716289        sgr=\E[0%?%p6%t;1%;%?%p5%t;2%;%?%p2%t;4%;%?%p4%t;5%;%?%p3%p1%|%t;7%;%?%p7%t;9%;m%?%p9%t\016%e\017%;,
     
    1496216294 #
    1496316295 qansi|QNX ansi with console writes,
    14964 @@ -4357,6 +4357,26 @@
     16296@@ -4285,6 +4319,30 @@
     16297        smkx=\E[?1h\E=, smso=\E[7m, smul=\E[4m, u6=\E[%i%d;%dR,
     16298        u7=\E[6n, vpa=\E[%i%p1%dd,
     16299 
     16300+#### VWM
     16301+#
     16302+# vwmterm is a terminal emulator written for the VWM console window manager
     16303+#
     16304+vwmterm|(vwm term),
     16305+       am, bce, ccc, mir, msgr, npc, xenl, xon,
     16306+       colors#8, pairs#64,
     16307+       acsc=``aaffggjjkkllmmnnooppqqrrssttuuvvwwxxyyzz{{||}}~~,
     16308+       bel=^G, blink=\E[5m, bold=\E[1m, civis=\E[?25l,
     16309+       clear=\E[H\E[J, cnorm=\E[?25h, cr=^M, cub1=^H,
     16310+       cuf=\E[%p1%dC, cuf1=\E[C, cup=\E[%i%p1%d;%p2%dH,
     16311+       cvvis=\E[?25h, dim=\E[2m, ed=\E[J, el=\E[K, home=\E[H,
     16312+       il1=\E[L, ind=^J, invis=\E[8m, kcub1=\E[D, kcud1=\E[B,
     16313+       kcuf1=\E[C, kcuu1=\E[A, kdch1=\E[3~, kend=\E[4~, kf1=\E[[A,
     16314+       kf10=\E[21~, kf11=\E[22~, kf12=\E[23~, kf2=\E[[B,
     16315+       kf3=\E[[C, kf4=\E[[D, kf5=\E[[E, kf6=\E[17~, kf7=\E[18~,
     16316+       kf8=\E[19~, kf9=\E[20~, khome=\E[1~, knp=\E[6~, kpp=\E[5~,
     16317+       rev=\E[7m, rmacs=\E[10m, rmam=\E[?7l, rmcup=\E[?1049l,
     16318+       rs1=\E[H\E[J\E[m\Ec, setab=\E[4%p1%dm,
     16319+       setaf=\E[3%p1%dm,
     16320+       sgr=\E[0;10%?%p1%t;7%;%?%p2%t;4%;%?%p3%t;7%;%?%p4%t;5%;%?%p6%t;1%;%?%p7%t;8%;%?%p9%t;11%;m,
     16321+       sgr0=\E[0;10m, smacs=\E[11m, smam=\E[?7h,
     16322+       smcup=\E[?1049h, smso=\E[3m, smul=\E[4m,
     16323+
     16324 #### MGR
     16325 #
     16326 # MGR is a Bell Labs window system lighter-weight than X.
     16327@@ -4357,6 +4415,26 @@
    1496516328        sgr0=\E[m, smcup=\E7\E[?47h, smir=\E[4h, smso=\E[7m,
    1496616329        smul=\E[4m,
     
    1498916352 # Michael Schroeder, Oliver Laumann.  The screen and
    1499016353 # screen-w entries came with version 3.7.1.  The screen2 and screen3 entries
    14991 @@ -4497,6 +4517,8 @@
     16354@@ -4497,6 +4575,8 @@
    1499216355        cvvis@, flash@, kcub1=\EOD, kcud1=\EOB, kcuf1=\EOC,
    1499316356        kcuu1=\EOA, use=screen+fkeys, use=vt100+enq,
     
    1499816361 screen.linux|screen in linux console,
    1499916362        bw,
    15000 @@ -5247,7 +5269,7 @@
     16363@@ -5042,44 +5122,13 @@
     16364 
     16365 ### EMX termcap.dat compatibility modes
     16366 #
     16367-# Keypad:      Home=\0G        Up=\0H  PrPag=\0I
     16368-#              ka1,kh          kcuu1           kpp,ka3
     16369-#
     16370-#              Left=\0K        5=\0L           Right=\0M
     16371-#              kcub1           kb2             kcuf1
     16372-#
     16373-#              End=\0O         Down=\0P        NxPag=\0Q
     16374-#              kc1,kend        kcud1           kc3,knp
     16375-#
     16376-#              Ins=\0R         Del=\0S
     16377-#              kich1           kdch1
     16378-#
     16379-# On keyboard with 12 function keys,
     16380-#      shifted f-keys: F13-F24
     16381-#      control f-keys: F25-F36
     16382-#      alt f-keys:     F37-F48
     16383-# The shift/control/alt keys do not modify each other, but alt overrides both,
     16384-# and control overrides shift.
     16385-#
     16386 # Also (possibly only EMX, so we don't put it in ansi.sys, etc): set the
     16387 # no_color_video to inform the application that standout(1), underline(2)
     16388 # reverse(4) and invisible(64) don't work with color.
     16389 emx-base|DOS special keys,
     16390        bce, bw,
     16391        it#8, ncv#71,
     16392-       bel=^G, ka1=\0G, ka3=\0I, kb2=\0L, kbs=^H, kc1=\0O, kc3=\0Q,
     16393-       kcbt=\0^O, kcub1=\0K, kcud1=\0P, kcuf1=\0M, kcuu1=\0H,
     16394-       kdch1=\0S, kend=\0O, kf1=\0;, kf10=\0D, kf11=\0\205,
     16395-       kf12=\0\206, kf13=\0T, kf14=\0U, kf15=\0V, kf16=\0W,
     16396-       kf17=\0X, kf18=\0Y, kf19=\0Z, kf2=\0<, kf20=\0[, kf21=\0\\,
     16397-       kf22=\0], kf23=\0\207, kf24=\0\210, kf25=\0\^, kf26=\0_,
     16398-       kf27=\0`, kf28=\0a, kf29=\0b, kf3=\0=, kf30=\0c, kf31=\0d,
     16399-       kf32=\0e, kf33=\0f, kf34=\0g, kf35=\0\211, kf36=\0\212,
     16400-       kf37=\0h, kf38=\0i, kf39=\0j, kf4=\0>, kf40=\0k, kf41=\0l,
     16401-       kf42=\0m, kf43=\0n, kf44=\0o, kf45=\0p, kf46=\0q,
     16402-       kf47=\0\213, kf48=\0\214, kf5=\0?, kf6=\0@, kf7=\0A, kf8=\0B,
     16403-       kf9=\0C, khome=\0G, kich1=\0R, knp=\0Q, kpp=\0I,
     16404-       use=ansi.sys,
     16405+       bel=^G, use=ansi.sys,
     16406 
     16407 # Except for the "-emx" suffixes, these are as distributed with EMX 0.9b,
     16408 # a Unix-style environment used on OS/2.  (Note that the suffix makes some
     16409@@ -5247,7 +5296,7 @@
    1500116410        setab=\E[4%p1%dm, setaf=\E[3%p1%dm,
    1500216411        sgr=\E[0;10%?%p1%t;7%;%?%p2%t;4%;%?%p3%t;7%;%?%p4%t;5%;%?%p6%t;1%;%?%p7%t;8%;%?%p9%t;12%;m,
     
    1500716416 # Key definitions:
    1500816417 # The encodings for unshifted arrow keys, F1-F12, Home, Insert, etc.  match the
    15009 @@ -11060,7 +11082,7 @@
     16418@@ -11060,7 +11109,7 @@
    1501016419        sgr=\E[%?%p1%t7;%;%?%p2%t4;%;%?%p3%t7;%;%?%p4%t5;%;%?%p6%t1;%;m,
    1501116420        sgr0=\E[m,
     
    1501616425 
    1501716426 aaa+rv|ann arbor ambassador in reverse video,
    15018 @@ -12147,7 +12169,7 @@
     16427@@ -12147,7 +12196,7 @@
    1501916428        sgr=\E[%?%p1%t7;%;%?%p2%t4;%;%?%p3%t7;%;%?%p4%t5;%;%?%p6%t1;%;m,
    1502016429        sgr0=\E[m, smacs=\017$<1>, smcup=\E[=4l\E[1;24w\E2\r,
     
    1502516434        flash=\E[=205l$<200>\E[=205h, is1=\E[=103l\E[=205h,
    1502616435        use=avt-ns,
    15027 @@ -14584,7 +14606,7 @@
     16436@@ -14584,7 +14633,7 @@
    1502816437        sc=\E[%y,
    1502916438        sgr=\E[%{0}%?%p1%p3%|%t%{7}%+%;%?%p2%t%{2}%+%;%?%p4%t%{5}%+%;%?%p6%t%{1}%+%;m%?%p8%t\E[%{32}%+%d%%{%;%?%p9%t\016%e\017%;,
     
    1503416443 # p9-w: Prism-9 in 132 column mode
    1503516444 # --------------------------------
    15036 @@ -16037,7 +16059,7 @@
     16445@@ -16037,7 +16086,7 @@
    1503716446        rep=%p1%c\E[%p2%{1}%-%db, rev=\E[7m, rmam=\E[?7l,
    1503816447        rmso=\E[m, rmul=\E[m,
     
    1504316452 # The tek4125 emulates a vt100 incorrectly - the scrolling region
    1504416453 # command is ignored.  The following entry replaces <csr> with the needed
    15045 @@ -17729,7 +17751,7 @@
     16454@@ -17729,7 +17778,7 @@
    1504616455        rmul=\E[m, rs2=\E[?=h\Ec, s0ds=^O, s1ds=^N,
    1504716456        sgr=\E[0%?%p1%p3%|%t;7%;%?%p2%t;4%;%?%p4%t;5%;%?%p5%t;2%;%?%p7%t;8%;m%?%p9%t\016%e\017%;,
     
    1505216461 tws2102-sna|dku7102-sna|BULL Questar tws2102 for SNA,
    1505316462        dsl=\E[0;98v\E[2J\E[v, fsl=\E[v, is3=\Eb, tsl=\E[0;98v,
    15054 @@ -21791,6 +21813,16 @@
     16463@@ -21791,6 +21840,25 @@
    1505516464 #      * add "aterm" -TD
    1505616465 #      * add "linux2.6.26" -TD
     
    1506616475+#      * add screen.Eterm -TD
    1506716476+#
     16477+# 2009-03-28
     16478+#      * correct typo in pfkey of ansi.sys-old
     16479+#        (report by Kalle Olavi Niemitalo)
     16480+#      * move function- and cursor-keys from emx-base to ansi.sys, and create
     16481+#        a pfkey capability which handles F1-F48 -TD
     16482+#
     16483+# 2009-05-02
     16484+#      * add vwmterm entry (Bryan Christ)
     16485+#
    1506816486 # The following sets edit modes for GNU EMACS.
    1506916487 # Local Variables:
     
    1507116489diff -Naur ncurses-5.7.orig/mk-1st.awk ncurses-5.7/mk-1st.awk
    1507216490--- ncurses-5.7.orig/mk-1st.awk 2007-03-24 15:10:55.000000000 -0700
    15073 +++ ncurses-5.7/mk-1st.awk      2009-02-28 20:38:47.598636401 -0800
     16491+++ ncurses-5.7/mk-1st.awk      2009-06-05 14:01:30.000000000 -0700
    1507416492@@ -1,6 +1,6 @@
    1507516493-# $Id: mk-1st.awk,v 1.78 2007/03/24 22:10:55 tom Exp $
    15076 +# $Id: mk-1st.awk,v 1.80 2009/01/04 21:51:38 tom Exp $
     16494+# $Id: mk-1st.awk,v 1.81 2009/03/28 18:59:51 Charles.Wilson Exp $
    1507716495 ##############################################################################
    1507816496-# Copyright (c) 1998-2006,2007 Free Software Foundation, Inc.                #
    15079 +# Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.                #
     16497+# Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.                #
    1508016498 #                                                                            #
    1508116499 # Permission is hereby granted, free of charge, to any person obtaining a    #
     
    1509016508 # see lib_name
    1509116509 function lib_name_of(a_name) {
    15092 @@ -404,7 +404,7 @@
     16510@@ -386,7 +386,13 @@
     16511                                }
     16512                                end_name = lib_name;
     16513                                printf "../lib/%s : $(%s_OBJS)\n", lib_name, OBJS
     16514-                               printf "\tcd ../lib && $(LIBTOOL_LINK) $(%s) -o %s $(%s_OBJS:$o=.lo) -rpath $(DESTDIR)$(libdir) -version-info $(NCURSES_MAJOR):$(NCURSES_MINOR) $(SHLIB_LIST)\n", compile, lib_name, OBJS
     16515+                               if ( is_ticlib() ) {
     16516+                                       printf "\tcd ../lib && $(LIBTOOL_LINK) $(%s) -o %s $(%s_OBJS:$o=.lo) -rpath $(DESTDIR)$(libdir) -version-info $(NCURSES_MAJOR):$(NCURSES_MINOR) $(LT_UNDEF) $(TICS_LIST)\n", compile, lib_name, OBJS
     16517+                               } else if ( is_termlib() ) {
     16518+                                       printf "\tcd ../lib && $(LIBTOOL_LINK) $(%s) -o %s $(%s_OBJS:$o=.lo) -rpath $(DESTDIR)$(libdir) -version-info $(NCURSES_MAJOR):$(NCURSES_MINOR) $(LT_UNDEF) $(TINFO_LIST)\n", compile, lib_name, OBJS
     16519+                               } else {
     16520+                                       printf "\tcd ../lib && $(LIBTOOL_LINK) $(%s) -o %s $(%s_OBJS:$o=.lo) -rpath $(DESTDIR)$(libdir) -version-info $(NCURSES_MAJOR):$(NCURSES_MINOR) $(LT_UNDEF) $(SHLIB_LIST)\n", compile, lib_name, OBJS
     16521+                               }
     16522                                print  ""
     16523                                print  "install \\"
     16524                                print  "install.libs \\"
     16525@@ -404,7 +410,7 @@
    1509316526                        {
    1509416527                                end_name = lib_name;
     
    1510116534diff -Naur ncurses-5.7.orig/ncurses/base/define_key.c ncurses-5.7/ncurses/base/define_key.c
    1510216535--- ncurses-5.7.orig/ncurses/base/define_key.c  2006-12-30 15:23:31.000000000 -0800
    15103 +++ ncurses-5.7/ncurses/base/define_key.c       2009-02-28 20:38:57.043235088 -0800
     16536+++ ncurses-5.7/ncurses/base/define_key.c       2009-06-05 14:01:51.000000000 -0700
    1510416537@@ -1,5 +1,5 @@
    1510516538 /****************************************************************************
     
    1510916542  * Permission is hereby granted, free of charge, to any person obtaining a  *
    1511016543  * copy of this software and associated documentation files (the            *
    15111 @@ -27,20 +27,21 @@
     16544@@ -27,33 +27,34 @@
    1511216545  ****************************************************************************/
    1511316546 
     
    1512116554 
    1512216555-MODULE_ID("$Id: define_key.c,v 1.13 2006/12/30 23:23:31 tom Exp $")
    15123 +MODULE_ID("$Id: define_key.c,v 1.15 2009/02/15 00:30:40 tom Exp $")
     16556+MODULE_ID("$Id: define_key.c,v 1.17 2009/05/09 18:30:16 tom Exp $")
    1512416557 
    1512516558 NCURSES_EXPORT(int)
     
    1512916562     int code = ERR;
    1513016563 
    15131      T((T_CALLED("define_key(%s,%d)"), _nc_visbuf(str), keycode));
     16564-    T((T_CALLED("define_key(%s,%d)"), _nc_visbuf(str), keycode));
    1513216565-    if (SP == 0) {
    15133 +    if (SP_PARM == 0) {
     16566+    T((T_CALLED("define_key(%p, %s,%d)"), SP_PARM, _nc_visbuf(str), keycode));
     16567+    if (SP_PARM == 0 || !HasTInfoTerminal(SP_PARM)) {
    1513416568        code = ERR;
    1513516569     } else if (keycode > 0) {
    1513616570        unsigned ukey = (unsigned) keycode;
    15137 @@ -48,12 +49,12 @@
     16571 
    1513816572        if (str != 0) {
    15139             define_key(str, 0);
    15140         } else if (has_key(keycode)) {
     16573-           define_key(str, 0);
     16574-       } else if (has_key(keycode)) {
    1514116575-           while (_nc_remove_key(&(SP->_keytry), ukey))
     16576+           NCURSES_SP_NAME(define_key) (NCURSES_SP_ARGx str, 0);
     16577+       } else if (NCURSES_SP_NAME(has_key) (NCURSES_SP_ARGx keycode)) {
    1514216578+           while (_nc_remove_key(&(SP_PARM->_keytry), ukey))
    1514316579                code = OK;
    1514416580        }
    1514516581        if (str != 0) {
    15146             if (key_defined(str) == 0) {
     16582-           if (key_defined(str) == 0) {
    1514716583-               if (_nc_add_to_try(&(SP->_keytry), str, ukey) == OK) {
     16584+           if (NCURSES_SP_NAME(key_defined) (NCURSES_SP_ARGx str) == 0) {
    1514816585+               if (_nc_add_to_try(&(SP_PARM->_keytry), str, ukey) == OK) {
    1514916586                    code = OK;
     
    1517016607diff -Naur ncurses-5.7.orig/ncurses/base/keybound.c ncurses-5.7/ncurses/base/keybound.c
    1517116608--- ncurses-5.7.orig/ncurses/base/keybound.c    2006-06-17 11:19:24.000000000 -0700
    15172 +++ ncurses-5.7/ncurses/base/keybound.c 2009-02-28 20:38:58.435326721 -0800
     16609+++ ncurses-5.7/ncurses/base/keybound.c 2009-06-05 14:01:16.000000000 -0700
    1517316610@@ -1,5 +1,5 @@
    1517416611 /****************************************************************************
     
    1522116658diff -Naur ncurses-5.7.orig/ncurses/base/key_defined.c ncurses-5.7/ncurses/base/key_defined.c
    1522216659--- ncurses-5.7.orig/ncurses/base/key_defined.c 2006-12-30 15:22:55.000000000 -0800
    15223 +++ ncurses-5.7/ncurses/base/key_defined.c      2009-02-28 20:38:58.435326721 -0800
     16660+++ ncurses-5.7/ncurses/base/key_defined.c      2009-06-05 14:01:16.000000000 -0700
    1522416661@@ -1,5 +1,5 @@
    1522516662 /****************************************************************************
     
    1526716704diff -Naur ncurses-5.7.orig/ncurses/base/keyok.c ncurses-5.7/ncurses/base/keyok.c
    1526816705--- ncurses-5.7.orig/ncurses/base/keyok.c       2006-12-30 08:22:33.000000000 -0800
    15269 +++ ncurses-5.7/ncurses/base/keyok.c    2009-02-28 20:38:57.043235088 -0800
     16706+++ ncurses-5.7/ncurses/base/keyok.c    2009-06-05 14:01:14.000000000 -0700
    1527016707@@ -1,5 +1,5 @@
    1527116708 /****************************************************************************
     
    1533916776diff -Naur ncurses-5.7.orig/ncurses/base/legacy_coding.c ncurses-5.7/ncurses/base/legacy_coding.c
    1534016777--- ncurses-5.7.orig/ncurses/base/legacy_coding.c       2005-12-17 15:38:17.000000000 -0800
    15341 +++ ncurses-5.7/ncurses/base/legacy_coding.c    2009-02-28 20:38:58.435326721 -0800
     16778+++ ncurses-5.7/ncurses/base/legacy_coding.c    2009-06-05 14:01:16.000000000 -0700
    1534216779@@ -1,5 +1,5 @@
    1534316780 /****************************************************************************
     
    1538816825diff -Naur ncurses-5.7.orig/ncurses/base/lib_addch.c ncurses-5.7/ncurses/base/lib_addch.c
    1538916826--- ncurses-5.7.orig/ncurses/base/lib_addch.c   2008-08-16 12:20:04.000000000 -0700
    15390 +++ ncurses-5.7/ncurses/base/lib_addch.c        2009-02-28 20:38:51.642889230 -0800
     16827+++ ncurses-5.7/ncurses/base/lib_addch.c        2009-06-05 14:01:52.000000000 -0700
    1539116828@@ -1,5 +1,5 @@
    1539216829 /****************************************************************************
     
    1540116838 
    1540216839-MODULE_ID("$Id: lib_addch.c,v 1.113 2008/08/16 19:20:04 tom Exp $")
    15403 +MODULE_ID("$Id: lib_addch.c,v 1.115 2009/01/17 20:37:32 tom Exp $")
     16840+MODULE_ID("$Id: lib_addch.c,v 1.119 2009/05/15 23:47:26 tom Exp $")
    1540416841 
    1540516842 static const NCURSES_CH_T blankchar = NewChar(BLANK_TEXT);
    1540616843 
    15407 @@ -265,15 +265,25 @@
     16844@@ -260,20 +260,37 @@
     16845     /*
     16846      * Build up multibyte characters until we have a wide-character.
     16847      */
     16848+#if NCURSES_SP_FUNCS
     16849+#define DeriveSP() SCREEN *sp = _nc_screen_of(win);
     16850+#else
     16851+#define DeriveSP() /*nothing*/
     16852+#endif
     16853     if_WIDEC({
     16854+       DeriveSP();
     16855        if (WINDOW_EXT(win, addch_used) != 0 || !Charable(ch)) {
    1540816856            int len = _nc_build_wch(win, CHREF(ch));
    1540916857 
     
    1541416862+               /* handle EILSEQ (i.e., when len >= -1) */
    1541516863                if (is8bits(CharOf(ch))) {
    15416 +                   int rc = OK;
    15417                     const char *s = unctrl((chtype) CharOf(ch));
     16864-                   const char *s = unctrl((chtype) CharOf(ch));
    1541816865-                   if (s[1] != 0) {
    1541916866-                       return waddstr(win, s);
     16867+                   int rc = OK;
     16868+                   const char *s = NCURSES_SP_NAME(unctrl)
     16869+                     (NCURSES_SP_ARGx (chtype) CharOf(ch));
    1542016870+
    1542116871+                   if (s[1] != '\0') {
     
    1543516885                return OK;
    1543616886            }
    15437 @@ -327,6 +337,7 @@
     16887@@ -327,6 +344,7 @@
    1543816888                    return ERR;
    1543916889                x = win->_curx;
     
    1544316893            /*
    1544416894             * Check for cells which are orphaned by adding this character, set
     16895@@ -394,8 +412,11 @@
     16896 {
     16897     NCURSES_SIZE_T x, y;
     16898     chtype t = CharOf(ch);
     16899-    const char *s = unctrl(t);
     16900-
     16901+#if USE_WIDEC_SUPPORT || NCURSES_SP_FUNCS || USE_REENTRANT
     16902+    SCREEN *sp = _nc_screen_of(win);
     16903+#endif
     16904+    const char *s = NCURSES_SP_NAME(unctrl) (NCURSES_SP_ARGx t);
     16905+    int tabsize = 8;
     16906     /*
     16907      * If we are using the alternate character set, forget about locale.
     16908      * Otherwise, if unctrl() returns a single-character or the locale
     16909@@ -404,14 +425,14 @@
     16910     if ((AttrOf(ch) & A_ALTCHARSET)
     16911        || (
     16912 #if USE_WIDEC_SUPPORT
     16913-              (SP != 0 && SP->_legacy_coding) &&
     16914+              (sp != 0 && sp->_legacy_coding) &&
     16915 #endif
     16916               s[1] == 0
     16917        )
     16918        || (
     16919               isprint(t)
     16920 #if USE_WIDEC_SUPPORT
     16921-              || ((SP == 0 || !SP->_legacy_coding) &&
     16922+              || ((sp == 0 || !sp->_legacy_coding) &&
     16923                   (WINDOW_EXT(win, addch_used)
     16924                    || !_nc_is_charable(CharOf(ch))))
     16925 #endif
     16926@@ -427,8 +448,12 @@
     16927 
     16928     switch (t) {
     16929     case '\t':
     16930-       x += (TABSIZE - (x % TABSIZE));
     16931-
     16932+#if USE_REENTRANT
     16933+       tabsize = sp->_TABSIZE;
     16934+#else
     16935+       tabsize = TABSIZE;
     16936+#endif
     16937+       x += (tabsize - (x % tabsize));
     16938        /*
     16939         * Space-fill the tab on the bottom line so that we'll get the
     16940         * "correct" cursor position.
    1544516941diff -Naur ncurses-5.7.orig/ncurses/base/lib_beep.c ncurses-5.7/ncurses/base/lib_beep.c
    1544616942--- ncurses-5.7.orig/ncurses/base/lib_beep.c    2005-04-09 08:20:04.000000000 -0700
    15447 +++ ncurses-5.7/ncurses/base/lib_beep.c 2009-02-28 20:38:57.043235088 -0800
     16943+++ ncurses-5.7/ncurses/base/lib_beep.c 2009-06-05 14:01:54.000000000 -0700
    1544816944@@ -1,5 +1,5 @@
    1544916945 /****************************************************************************
    1545016946- * Copyright (c) 1998-2000,2005 Free Software Foundation, Inc.              *
    15451 + * Copyright (c) 1998-2005,2009 Free Software Foundation, Inc.              *
     16947+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
    1545216948  *                                                                          *
    1545316949  * Permission is hereby granted, free of charge, to any person obtaining a  *
     
    1546116957 
    1546216958 /*
    15463 @@ -42,7 +43,7 @@
     16959@@ -40,9 +41,12 @@
     16960  */
     16961 
    1546416962 #include <curses.priv.h>
    15465  #include <term.h>              /* beep, flash */
     16963-#include <term.h>              /* beep, flash */
    1546616964 
    1546716965-MODULE_ID("$Id: lib_beep.c,v 1.10 2005/04/09 15:20:04 tom Exp $")
    15468 +MODULE_ID("$Id: lib_beep.c,v 1.11 2009/02/15 00:32:06 tom Exp $")
     16966+#ifndef CUR
     16967+#define CUR SP_TERMTYPE
     16968+#endif
     16969+
     16970+MODULE_ID("$Id: lib_beep.c,v 1.14 2009/05/23 19:33:20 tom Exp $")
    1546916971 
    1547016972 /*
    1547116973  *     beep()
    15472 @@ -53,7 +54,7 @@
     16974@@ -53,12 +57,16 @@
    1547316975  */
    1547416976 
     
    1547916981     int res = ERR;
    1548016982 
    15481 @@ -74,3 +75,11 @@
     16983-    T((T_CALLED("beep()")));
     16984+    T((T_CALLED("beep(%p)"), SP_PARM));
     16985 
     16986+#ifdef USE_TERM_DRIVER
     16987+    if (SP_PARM != 0)
     16988+       res = CallDriver_1(SP_PARM, doBeepOrFlash, TRUE);
     16989+#else
     16990     /* FIXME: should make sure that we are not in altchar mode */
     16991     if (cur_term == 0) {
     16992        res = ERR;
     16993@@ -71,6 +79,15 @@
     16994        res = putp(flash_screen);
     16995        _nc_flush();
     16996     }
     16997+#endif
    1548216998 
    1548316999     returnCode(res);
     
    1549317009diff -Naur ncurses-5.7.orig/ncurses/base/lib_color.c ncurses-5.7/ncurses/base/lib_color.c
    1549417010--- ncurses-5.7.orig/ncurses/base/lib_color.c   2007-04-07 10:07:28.000000000 -0700
    15495 +++ ncurses-5.7/ncurses/base/lib_color.c        2009-02-28 20:38:57.047235367 -0800
     17011+++ ncurses-5.7/ncurses/base/lib_color.c        2009-06-05 14:01:51.000000000 -0700
    1549617012@@ -1,5 +1,5 @@
    1549717013 /****************************************************************************
     
    1550917025 
    1551017026 /* lib_color.c
    15511 @@ -42,7 +43,7 @@
     17027@@ -42,7 +43,11 @@
    1551217028 #include <term.h>
    1551317029 #include <tic.h>
    1551417030 
    1551517031-MODULE_ID("$Id: lib_color.c,v 1.85 2007/04/07 17:07:28 tom Exp $")
    15516 +MODULE_ID("$Id: lib_color.c,v 1.88 2009/02/15 00:33:02 tom Exp $")
     17032+#ifndef CUR
     17033+#define CUR SP_TERMTYPE
     17034+#endif
     17035+
     17036+MODULE_ID("$Id: lib_color.c,v 1.91 2009/05/10 00:48:29 tom Exp $")
    1551717037 
    1551817038 /*
    1551917039  * These should be screen structure members.  They need to be globals for
    15520 @@ -108,6 +109,13 @@
     17040@@ -108,6 +113,13 @@
    1552117041 };
    1552217042 /* *INDENT-ON* */
     
    1553217052 /*
    1553317053  * These are called from _nc_do_color(), which in turn is called from
    15534 @@ -237,15 +245,15 @@
     17054@@ -147,31 +159,39 @@
     17055 }
     17056 
     17057 static void
     17058-set_background_color(int bg, int (*outc) (int))
     17059+set_background_color(NCURSES_SP_DCLx int bg, NCURSES_SP_OUTC outc)
     17060 {
     17061     if (set_a_background) {
     17062        TPUTS_TRACE("set_a_background");
     17063-       tputs(TPARM_1(set_a_background, bg), 1, outc);
     17064+       NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     17065+                               TPARM_1(set_a_background, bg),
     17066+                               1, outc);
     17067     } else {
     17068        TPUTS_TRACE("set_background");
     17069-       tputs(TPARM_1(set_background, toggled_colors(bg)), 1, outc);
     17070+       NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     17071+                               TPARM_1(set_background, toggled_colors(bg)),
     17072+                               1, outc);
     17073     }
     17074 }
     17075 
     17076 static void
     17077-set_foreground_color(int fg, int (*outc) (int))
     17078+set_foreground_color(NCURSES_SP_DCLx int fg, NCURSES_SP_OUTC outc)
     17079 {
     17080     if (set_a_foreground) {
     17081        TPUTS_TRACE("set_a_foreground");
     17082-       tputs(TPARM_1(set_a_foreground, fg), 1, outc);
     17083+       NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     17084+                               TPARM_1(set_a_foreground, fg),
     17085+                               1, outc);
     17086     } else {
     17087        TPUTS_TRACE("set_foreground");
     17088-       tputs(TPARM_1(set_foreground, toggled_colors(fg)), 1, outc);
     17089+       NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     17090+                               TPARM_1(set_foreground, toggled_colors(fg)),
     17091+                               1, outc);
     17092     }
     17093 }
     17094 
     17095 static void
     17096-init_color_table(void)
     17097+init_color_table(NCURSES_SP_DCL0)
     17098 {
     17099     const color_t *tp;
     17100     int n;
     17101@@ -200,7 +220,7 @@
     17102  * Reset the color pair, e.g., to whatever color pair 0 is.
     17103  */
     17104 static bool
     17105-reset_color_pair(void)
     17106+reset_color_pair(NCURSES_SP_DCL0)
     17107 {
     17108     bool result = FALSE;
     17109 
     17110@@ -220,13 +240,16 @@
     17111 bool
     17112 _nc_reset_colors(void)
     17113 {
     17114+#if NCURSES_SP_FUNCS
     17115+    SCREEN *sp = CURRENT_SCREEN;
     17116+#endif
     17117     int result = FALSE;
     17118 
     17119     T((T_CALLED("_nc_reset_colors()")));
     17120     if (SP->_color_defs > 0)
     17121        SP->_color_defs = -(SP->_color_defs);
     17122 
     17123-    if (reset_color_pair())
     17124+    if (reset_color_pair(NCURSES_SP_ARG))
     17125        result = TRUE;
     17126     if (orig_colors != 0) {
     17127        TPUTS_TRACE("orig_colors");
     17128@@ -237,45 +260,60 @@
    1553517129 }
    1553617130 
     
    1555117145     } else {
    1555217146 
    15553 @@ -255,27 +263,38 @@
     17147-       if (reset_color_pair() != TRUE) {
     17148-           set_foreground_color(default_fg(), _nc_outch);
     17149-           set_background_color(default_bg(), _nc_outch);
     17150+       if (reset_color_pair(NCURSES_SP_ARG) != TRUE) {
     17151+           set_foreground_color(NCURSES_SP_ARGx
     17152+                                default_fg(),
     17153+                                NCURSES_SP_NAME(_nc_outch));
     17154+           set_background_color(NCURSES_SP_ARGx
     17155+                                default_bg(),
     17156+                                NCURSES_SP_NAME(_nc_outch));
    1555417157        }
    1555517158 
     
    1557817181-                                                   max_colors)) != 0) {
    1557917182-                   SP->_color_pairs[0] = PAIR_OF(default_fg(), default_bg());
     17183-                   init_color_table();
    1558017184+           SP_PARM->_color_pairs = TYPE_CALLOC(colorpair_t,
    1558117185+                                               SP_PARM->_pair_limit);
     
    1558517189+                   SP_PARM->_color_pairs[0] = PAIR_OF(default_fg(),
    1558617190+                                                      default_bg());
    15587                     init_color_table();
     17191+                   init_color_table(NCURSES_SP_ARG);
    1558817192 
    1558917193                    T(("started color: COLORS = %d, COLOR_PAIRS = %d",
     
    1560017204            }
    1560117205        } else {
    15602 @@ -285,6 +304,14 @@
     17206@@ -285,6 +323,14 @@
    1560317207     returnCode(result);
    1560417208 }
     
    1561517219 static void
    1561617220 rgb2hls(short r, short g, short b, short *h, short *l, short *s)
    15617 @@ -328,24 +355,72 @@
     17221@@ -328,24 +374,72 @@
    1561817222  * values.
    1561917223  */
     
    1569517299 #endif
    1569617300     {
    15697 @@ -361,8 +436,8 @@
     17301@@ -361,8 +455,8 @@
    1569817302      * pair colors with the new ones).
    1569917303      */
     
    1570617310 
    1570717311        for (y = 0; y <= curscr->_maxy; y++) {
    15708 @@ -381,9 +456,9 @@
     17312@@ -381,9 +475,9 @@
    1570917313                _nc_make_oldhash(y);
    1571017314        }
     
    1571917323     if (initialize_pair && InPalette(f) && InPalette(b)) {
    1572017324        const color_t *tp = hue_lightness_saturation ? hls_palette : cga_palette;
    15721 @@ -404,54 +479,79 @@
     17325@@ -404,54 +498,79 @@
    1572217326     returnCode(OK);
    1572317327 }
     
    1581517419     T((T_CALLED("has_colors()")));
    1581617420     returnCode((VALID_NUMERIC(max_colors) && VALID_NUMERIC(max_pairs)
    15817 @@ -462,18 +562,27 @@
     17421@@ -462,18 +581,27 @@
    1581817422                    || set_color_pair)) ? TRUE : FALSE);
    1581917423 }
     
    1584817452        if (r)
    1584917453            *r = c_r;
    15850 @@ -489,18 +598,27 @@
     17454@@ -489,18 +617,27 @@
    1585117455     returnCode(result);
    1585217456 }
     
    1588017484 #if NCURSES_EXT_FUNCS
    1588117485        if (fg == COLOR_DEFAULT)
    15882 @@ -520,6 +638,14 @@
     17486@@ -520,19 +657,33 @@
    1588317487     returnCode(result);
    1588417488 }
     
    1589317497+
    1589417498 NCURSES_EXPORT(void)
    15895  _nc_do_color(short old_pair, short pair, bool reverse, int (*outc) (int))
     17499-_nc_do_color(short old_pair, short pair, bool reverse, int (*outc) (int))
     17500+NCURSES_SP_NAME(_nc_do_color) (NCURSES_SP_DCLx
     17501+                              short old_pair,
     17502+                              short pair,
     17503+                              bool reverse,
     17504+                              NCURSES_SP_OUTC outc)
    1589617505 {
    15897 @@ -527,7 +653,7 @@
     17506     NCURSES_COLOR_T fg = COLOR_DEFAULT;
    1589817507     NCURSES_COLOR_T bg = COLOR_DEFAULT;
    1589917508     NCURSES_COLOR_T old_fg, old_bg;
     
    1590417513     } else if (pair != 0) {
    1590517514        if (set_color_pair) {
     17515            TPUTS_TRACE("set_color_pair");
     17516-           tputs(TPARM_1(set_color_pair, pair), 1, outc);
     17517+           NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     17518+                                   TPARM_1(set_color_pair, pair),
     17519+                                   1, outc);
     17520            return;
     17521        } else if (SP != 0) {
     17522            pair_content((short) pair, &fg, &bg);
     17523@@ -553,17 +704,17 @@
     17524            if (SP->_has_sgr_39_49
     17525                && isDefaultColor(old_bg)
     17526                && !isDefaultColor(old_fg)) {
     17527-               tputs("\033[39m", 1, outc);
     17528+               NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx "\033[39m", 1, outc);
     17529            } else if (SP->_has_sgr_39_49
     17530                       && isDefaultColor(old_fg)
     17531                       && !isDefaultColor(old_bg)) {
     17532-               tputs("\033[49m", 1, outc);
     17533+               NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx "\033[49m", 1, outc);
     17534            } else
     17535 #endif
     17536-               reset_color_pair();
     17537+               reset_color_pair(NCURSES_SP_ARG);
     17538        }
     17539     } else {
     17540-       reset_color_pair();
     17541+       reset_color_pair(NCURSES_SP_ARG);
     17542        if (old_pair < 0)
     17543            return;
     17544     }
     17545@@ -585,9 +736,22 @@
     17546                     fg, bg));
     17547 
     17548     if (!isDefaultColor(fg)) {
     17549-       set_foreground_color(fg, outc);
     17550+       set_foreground_color(NCURSES_SP_ARGx fg, outc);
     17551     }
     17552     if (!isDefaultColor(bg)) {
     17553-       set_background_color(bg, outc);
     17554+       set_background_color(NCURSES_SP_ARGx bg, outc);
     17555     }
     17556 }
     17557+
     17558+#if NCURSES_SP_FUNCS
     17559+NCURSES_EXPORT(void)
     17560+_nc_do_color(short old_pair, short pair, bool reverse, NCURSES_OUTC outc)
     17561+{
     17562+    SetSafeOutcWrapper(outc);
     17563+    NCURSES_SP_NAME(_nc_do_color) (CURRENT_SCREEN,
     17564+                                  old_pair,
     17565+                                  pair,
     17566+                                  reverse,
     17567+                                  _nc_outc_wrapper);
     17568+}
     17569+#endif
    1590617570diff -Naur ncurses-5.7.orig/ncurses/base/lib_colorset.c ncurses-5.7/ncurses/base/lib_colorset.c
    1590717571--- ncurses-5.7.orig/ncurses/base/lib_colorset.c        2005-01-29 13:40:51.000000000 -0800
    15908 +++ ncurses-5.7/ncurses/base/lib_colorset.c     2009-02-28 20:38:53.014978628 -0800
     17572+++ ncurses-5.7/ncurses/base/lib_colorset.c     2009-06-05 14:01:11.000000000 -0700
    1590917573@@ -1,5 +1,5 @@
    1591017574 /****************************************************************************
     
    1595217616+    returnCode(code);
    1595317617 }
     17618diff -Naur ncurses-5.7.orig/ncurses/base/lib_delwin.c ncurses-5.7/ncurses/base/lib_delwin.c
     17619--- ncurses-5.7.orig/ncurses/base/lib_delwin.c  2008-06-07 07:10:56.000000000 -0700
     17620+++ ncurses-5.7/ncurses/base/lib_delwin.c       2009-06-05 14:01:54.000000000 -0700
     17621@@ -1,5 +1,5 @@
     17622 /****************************************************************************
     17623- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     17624+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     17625  *                                                                          *
     17626  * Permission is hereby granted, free of charge, to any person obtaining a  *
     17627  * copy of this software and associated documentation files (the            *
     17628@@ -29,6 +29,8 @@
     17629 /****************************************************************************
     17630  *  Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1992,1995               *
     17631  *     and: Eric S. Raymond <esr@snark.thyrsus.com>                         *
     17632+ *     and: Thomas E. Dickey                        1996-on                 *
     17633+ *     and: Juergen Pfeifer                         2008                    *
     17634  ****************************************************************************/
     17635 
     17636 /*
     17637@@ -40,15 +42,18 @@
     17638 
     17639 #include <curses.priv.h>
     17640 
     17641-MODULE_ID("$Id: lib_delwin.c,v 1.17 2008/06/07 14:10:56 tom Exp $")
     17642+MODULE_ID("$Id: lib_delwin.c,v 1.19 2009/05/23 19:56:55 tom Exp $")
     17643 
     17644 static bool
     17645 cannot_delete(WINDOW *win)
     17646 {
     17647     WINDOWLIST *p;
     17648     bool result = TRUE;
     17649+#ifdef USE_SP_WINDOWLIST
     17650+    SCREEN *sp = _nc_screen_of(win);
     17651+#endif
     17652 
     17653-    for (each_window(p)) {
     17654+    for (each_window(SP_PARM, p)) {
     17655        if (&(p->win) == win) {
     17656            result = FALSE;
     17657        } else if ((p->win._flags & _SUBWIN) != 0
     17658@@ -72,11 +77,13 @@
     17659            || cannot_delete(win)) {
     17660            result = ERR;
     17661        } else {
     17662-
     17663+#if NCURSES_SP_FUNCS
     17664+           SCREEN *sp = _nc_screen_of(win);
     17665+#endif
     17666            if (win->_flags & _SUBWIN)
     17667                touchwin(win->_parent);
     17668-           else if (curscr != 0)
     17669-               touchwin(curscr);
     17670+           else if (CurScreen(SP_PARM) != 0)
     17671+               touchwin(CurScreen(SP_PARM));
     17672 
     17673            result = _nc_freewin(win);
     17674        }
    1595417675diff -Naur ncurses-5.7.orig/ncurses/base/lib_dft_fgbg.c ncurses-5.7/ncurses/base/lib_dft_fgbg.c
    1595517676--- ncurses-5.7.orig/ncurses/base/lib_dft_fgbg.c        2005-11-26 12:03:38.000000000 -0800
    15956 +++ ncurses-5.7/ncurses/base/lib_dft_fgbg.c     2009-02-28 20:38:57.047235367 -0800
     17677+++ ncurses-5.7/ncurses/base/lib_dft_fgbg.c     2009-06-05 14:01:55.000000000 -0700
    1595717678@@ -1,5 +1,5 @@
    1595817679 /****************************************************************************
     
    1596217683  * Permission is hereby granted, free of charge, to any person obtaining a  *
    1596317684  * copy of this software and associated documentation files (the            *
    15964 @@ -27,31 +27,40 @@
     17685@@ -27,49 +27,73 @@
    1596517686  ****************************************************************************/
    1596617687 
     
    1597217693 
    1597317694 #include <curses.priv.h>
    15974  #include <term.h>
     17695-#include <term.h>
    1597517696 
    1597617697-MODULE_ID("$Id: lib_dft_fgbg.c,v 1.18 2005/11/26 20:03:38 tom Exp $")
    15977 +MODULE_ID("$Id: lib_dft_fgbg.c,v 1.19 2009/02/14 21:53:21 tom Exp $")
     17698+#ifndef CUR
     17699+#define CUR SP_TERMTYPE
     17700+#endif
     17701+
     17702+MODULE_ID("$Id: lib_dft_fgbg.c,v 1.24 2009/05/30 20:00:00 tom Exp $")
    1597817703 
    1597917704 /*
     
    1598217707  */
    1598317708 NCURSES_EXPORT(int)
    15984 -use_default_colors(void)
    1598517709+NCURSES_SP_NAME(use_default_colors) (NCURSES_SP_DCL0)
    15986  {
    15987      T((T_CALLED("use_default_colors()")));
    15988 -    returnCode(assume_default_colors(-1, -1));
    15989 +    returnCode(NCURSES_SP_NAME(assume_default_colors) (NCURSES_SP_ARGx - 1, -1));
     17710+{
     17711+    T((T_CALLED("use_default_colors(%p)"), SP_PARM));
     17712+    returnCode(NCURSES_SP_NAME(assume_default_colors) (NCURSES_SP_ARGx -1, -1));
    1599017713+}
    1599117714+
    1599217715+#if NCURSES_SP_FUNCS
    1599317716+NCURSES_EXPORT(int)
    15994 +use_default_colors(void)
    15995 +{
     17717 use_default_colors(void)
     17718 {
     17719-    T((T_CALLED("use_default_colors()")));
     17720-    returnCode(assume_default_colors(-1, -1));
    1599617721+    return NCURSES_SP_NAME(use_default_colors) (CURRENT_SCREEN);
    1599717722 }
     
    1600617731+NCURSES_SP_NAME(assume_default_colors) (NCURSES_SP_DCLx int fg, int bg)
    1600717732 {
    16008      T((T_CALLED("assume_default_colors(%d,%d)"), fg, bg));
    16009  
    16010 @@ -61,15 +70,23 @@
    16011      if (initialize_pair)       /* don't know how to handle this */
    16012         returnCode(ERR);
    16013  
     17733-    T((T_CALLED("assume_default_colors(%d,%d)"), fg, bg));
     17734-
     17735-    if (!orig_pair && !orig_colors)
     17736-       returnCode(ERR);
     17737+    int code = ERR;
     17738 
     17739-    if (initialize_pair)       /* don't know how to handle this */
     17740-       returnCode(ERR);
     17741-
    1601417742-    SP->_default_color = isDefaultColor(fg) || isDefaultColor(bg);
    1601517743-    SP->_has_sgr_39_49 = (tigetflag("AX") == TRUE);
     
    1601917747-       bool save = SP->_default_color;
    1602017748-       SP->_default_color = TRUE;
    16021 +    SP_PARM->_default_color = isDefaultColor(fg) || isDefaultColor(bg);
    16022 +    SP_PARM->_has_sgr_39_49 = (tigetflag("AX") == TRUE);
    16023 +    SP_PARM->_default_fg = isDefaultColor(fg) ? COLOR_DEFAULT : (fg & C_MASK);
    16024 +    SP_PARM->_default_bg = isDefaultColor(bg) ? COLOR_DEFAULT : (bg & C_MASK);
    16025 +    if (SP_PARM->_color_pairs != 0) {
    16026 +       bool save = SP_PARM->_default_color;
    16027 +       SP_PARM->_default_color = TRUE;
    16028         init_pair(0, (short) fg, (short) bg);
     17749-       init_pair(0, (short) fg, (short) bg);
    1602917750-       SP->_default_color = save;
    16030 +       SP_PARM->_default_color = save;
     17751+    T((T_CALLED("assume_default_colors(%p,%d,%d)"), SP_PARM, fg, bg));
     17752+#ifdef USE_TERM_DRIVER
     17753+    if (sp != 0)
     17754+       code = CallDriver_2(sp, defaultcolors, fg, bg);
     17755+#else
     17756+    if ((orig_pair || orig_colors) && !initialize_pair) {
     17757+
     17758+       SP_PARM->_default_color = isDefaultColor(fg) || isDefaultColor(bg);
     17759+       SP_PARM->_has_sgr_39_49 = (tigetflag("AX") == TRUE);
     17760+       SP_PARM->_default_fg = isDefaultColor(fg) ? COLOR_DEFAULT : (fg & C_MASK);
     17761+       SP_PARM->_default_bg = isDefaultColor(bg) ? COLOR_DEFAULT : (bg & C_MASK);
     17762+       if (SP_PARM->_color_pairs != 0) {
     17763+           bool save = SP_PARM->_default_color;
     17764+           SP_PARM->_default_color = TRUE;
     17765+           init_pair(0, (short) fg, (short) bg);
     17766+           SP_PARM->_default_color = save;
     17767+       }
     17768+       code = OK;
    1603117769     }
    16032      returnCode(OK);
    16033  }
     17770-    returnCode(OK);
     17771+#endif
     17772+    returnCode(code);
     17773+}
    1603417774+
    1603517775+#if NCURSES_SP_FUNCS
     
    1603817778+{
    1603917779+    return NCURSES_SP_NAME(assume_default_colors) (CURRENT_SCREEN, fg, bg);
    16040 +}
     17780 }
    1604117781+#endif
    1604217782diff -Naur ncurses-5.7.orig/ncurses/base/lib_echo.c ncurses-5.7/ncurses/base/lib_echo.c
    1604317783--- ncurses-5.7.orig/ncurses/base/lib_echo.c    2000-12-09 18:43:27.000000000 -0800
    16044 +++ ncurses-5.7/ncurses/base/lib_echo.c 2009-02-28 20:38:58.435326721 -0800
     17784+++ ncurses-5.7/ncurses/base/lib_echo.c 2009-06-05 14:01:16.000000000 -0700
    1604517785@@ -1,5 +1,5 @@
    1604617786 /****************************************************************************
     
    1610817848diff -Naur ncurses-5.7.orig/ncurses/base/lib_endwin.c ncurses-5.7/ncurses/base/lib_endwin.c
    1610917849--- ncurses-5.7.orig/ncurses/base/lib_endwin.c  2000-12-09 18:43:27.000000000 -0800
    16110 +++ ncurses-5.7/ncurses/base/lib_endwin.c       2009-02-28 20:38:57.047235367 -0800
     17850+++ ncurses-5.7/ncurses/base/lib_endwin.c       2009-06-05 14:01:14.000000000 -0700
    1611117851@@ -1,5 +1,5 @@
    1611217852 /****************************************************************************
     
    1616117901diff -Naur ncurses-5.7.orig/ncurses/base/lib_flash.c ncurses-5.7/ncurses/base/lib_flash.c
    1616217902--- ncurses-5.7.orig/ncurses/base/lib_flash.c   2000-12-09 18:43:27.000000000 -0800
    16163 +++ ncurses-5.7/ncurses/base/lib_flash.c        2009-02-28 20:38:57.047235367 -0800
     17903+++ ncurses-5.7/ncurses/base/lib_flash.c        2009-06-05 14:01:54.000000000 -0700
    1616417904@@ -1,5 +1,5 @@
    1616517905 /****************************************************************************
     
    1617817918 
    1617917919 /*
    16180 @@ -41,7 +43,7 @@
     17920@@ -39,9 +41,12 @@
     17921  */
     17922 
    1618117923 #include <curses.priv.h>
    16182  #include <term.h>              /* beep, flash */
     17924-#include <term.h>              /* beep, flash */
    1618317925 
    1618417926-MODULE_ID("$Id: lib_flash.c,v 1.6 2000/12/10 02:43:27 tom Exp $")
    16185 +MODULE_ID("$Id: lib_flash.c,v 1.7 2009/02/15 00:35:15 tom Exp $")
     17927+#ifndef CUR
     17928+#define CUR SP_TERMTYPE
     17929+#endif
     17930+
     17931+MODULE_ID("$Id: lib_flash.c,v 1.10 2009/05/23 19:37:09 tom Exp $")
    1618617932 
    1618717933 /*
    1618817934  *     flash()
    16189 @@ -52,7 +54,7 @@
     17935@@ -52,12 +57,15 @@
    1619017936  */
    1619117937 
     
    1619617942     int res = ERR;
    1619717943 
    16198 @@ -71,3 +73,11 @@
    16199  
     17944-    T((T_CALLED("flash()")));
     17945-
     17946+    T((T_CALLED("flash(%p)"), SP_PARM));
     17947+#ifdef USE_TERM_DRIVER
     17948+    if (SP_PARM != 0)
     17949+       res = CallDriver_1(SP_PARM, doBeepOrFlash, FALSE);
     17950+#else
     17951     /* FIXME: should make sure that we are not in altchar mode */
     17952     if (flash_screen) {
     17953        TPUTS_TRACE("flash_screen");
     17954@@ -68,6 +76,14 @@
     17955        res = putp(bell);
     17956        _nc_flush();
     17957     }
     17958-
     17959+#endif
    1620017960     returnCode(res);
    1620117961 }
     
    1621017970diff -Naur ncurses-5.7.orig/ncurses/base/lib_freeall.c ncurses-5.7/ncurses/base/lib_freeall.c
    1621117971--- ncurses-5.7.orig/ncurses/base/lib_freeall.c 2008-09-27 06:09:57.000000000 -0700
    16212 +++ ncurses-5.7/ncurses/base/lib_freeall.c      2009-02-28 20:38:39.770130185 -0800
    16213 @@ -40,7 +40,7 @@
     17972+++ ncurses-5.7/ncurses/base/lib_freeall.c      2009-06-05 14:01:51.000000000 -0700
     17973@@ -1,5 +1,5 @@
     17974 /****************************************************************************
     17975- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     17976+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     17977  *                                                                          *
     17978  * Permission is hereby granted, free of charge, to any person obtaining a  *
     17979  * copy of this software and associated documentation files (the            *
     17980@@ -40,40 +40,40 @@
    1621417981 extern int malloc_errfd;       /* FIXME */
    1621517982 #endif
    1621617983 
    1621717984-MODULE_ID("$Id: lib_freeall.c,v 1.54 2008/09/27 13:09:57 tom Exp $")
    16218 +MODULE_ID("$Id: lib_freeall.c,v 1.55 2008/12/06 23:52:29 tom Exp $")
     17985+MODULE_ID("$Id: lib_freeall.c,v 1.58 2009/05/09 18:34:30 tom Exp $")
    1621917986 
    1622017987 /*
    1622117988  * Free all ncurses data.  This is used for testing only (there's no practical
    16222 @@ -98,8 +98,6 @@
    16223         delscreen(SP);
     17989  * use for it as an extension).
     17990  */
     17991 NCURSES_EXPORT(void)
     17992-_nc_freeall(void)
     17993+NCURSES_SP_NAME(_nc_freeall) (NCURSES_SP_DCL0)
     17994 {
     17995     WINDOWLIST *p, *q;
     17996     static va_list empty_va;
     17997 
     17998     T((T_CALLED("_nc_freeall()")));
     17999 #if NO_LEAKS
     18000-    if (SP != 0) {
     18001-       if (SP->_oldnum_list != 0) {
     18002-           FreeAndNull(SP->_oldnum_list);
     18003+    if (SP_PARM != 0) {
     18004+       if (SP_PARM->_oldnum_list != 0) {
     18005+           FreeAndNull(SP_PARM->_oldnum_list);
     18006        }
     18007-       if (SP->_panelHook.destroy != 0) {
     18008-           SP->_panelHook.destroy(SP->_panelHook.stdscr_pseudo_panel);
     18009+       if (SP_PARM->_panelHook.destroy != 0) {
     18010+           SP_PARM->_panelHook.destroy(SP_PARM->_panelHook.stdscr_pseudo_panel);
     18011        }
     18012     }
     18013 #endif
     18014-    if (SP != 0) {
     18015+    if (SP_PARM != 0) {
     18016        _nc_lock_global(curses);
     18017 
     18018-       while (_nc_windows != 0) {
     18019+       while (WindowList(SP_PARM) != 0) {
     18020            bool deleted = FALSE;
     18021 
     18022            /* Delete only windows that're not a parent */
     18023-           for (each_window(p)) {
     18024+           for (each_window(SP_PARM, p)) {
     18025                bool found = FALSE;
     18026 
     18027-               for (each_window(q)) {
     18028+               for (each_window(SP_PARM, q)) {
     18029                    if ((p != q)
     18030                        && (q->win._flags & _SUBWIN)
     18031                        && (&(p->win) == q->win._parent)) {
     18032@@ -95,11 +95,9 @@
     18033            if (!deleted)
     18034                break;
     18035        }
     18036-       delscreen(SP);
     18037+       delscreen(SP_PARM);
    1622418038        _nc_unlock_global(curses);
    1622518039     }
     
    1622918043     (void) _nc_printf_string(0, empty_va);
    1623018044 #ifdef TRACE
     18045@@ -121,12 +119,20 @@
     18046     returnVoid;
     18047 }
     18048 
     18049+#if NCURSES_SP_FUNCS
     18050 NCURSES_EXPORT(void)
     18051-_nc_free_and_exit(int code)
     18052+_nc_freeall(void)
     18053+{
     18054+    NCURSES_SP_NAME(_nc_freeall) (CURRENT_SCREEN);
     18055+}
     18056+#endif
     18057+
     18058+NCURSES_EXPORT(void)
     18059+NCURSES_SP_NAME(_nc_free_and_exit) (NCURSES_SP_DCLx int code)
     18060 {
     18061-    char *last_setbuf = (SP != 0) ? SP->_setbuf : 0;
     18062+    char *last_setbuf = (SP_PARM != 0) ? SP_PARM->_setbuf : 0;
     18063 
     18064-    _nc_freeall();
     18065+    NCURSES_SP_NAME(_nc_freeall) (NCURSES_SP_ARG);
     18066 #ifdef TRACE
     18067     trace(0);                  /* close trace file, freeing its setbuf */
     18068     {
     18069@@ -146,12 +152,21 @@
     18070 }
     18071 
     18072 NCURSES_EXPORT(void)
     18073-_nc_free_and_exit(int code)
     18074+NCURSES_SP_NAME(_nc_free_and_exit) (NCURSES_SP_DCLx int code)
     18075 {
     18076-    if (SP)
     18077-       delscreen(SP);
     18078-    if (cur_term != 0)
     18079-       del_curterm(cur_term);
     18080+    if (SP_PARM) {
     18081+       delscreen(SP_PARM);
     18082+       if (SP_PARM->_term)
     18083+           NCURSES_SP_NAME(del_curterm) (NCURSES_SP_ARGx SP_PARM->_term);
     18084+    }
     18085     exit(code);
     18086 }
     18087 #endif
     18088+
     18089+#if NCURSES_SP_FUNCS
     18090+NCURSES_EXPORT(void)
     18091+_nc_free_and_exit(int code)
     18092+{
     18093+    NCURSES_SP_NAME(_nc_free_and_exit) (CURRENT_SCREEN, code);
     18094+}
     18095+#endif
    1623118096diff -Naur ncurses-5.7.orig/ncurses/base/lib_getch.c ncurses-5.7/ncurses/base/lib_getch.c
    1623218097--- ncurses-5.7.orig/ncurses/base/lib_getch.c   2008-09-20 12:46:13.000000000 -0700
    16233 +++ ncurses-5.7/ncurses/base/lib_getch.c        2009-02-28 20:38:59.859415560 -0800
     18098+++ ncurses-5.7/ncurses/base/lib_getch.c        2009-06-05 14:01:55.000000000 -0700
    1623418099@@ -1,5 +1,5 @@
    1623518100 /****************************************************************************
     
    1624718112 
    1624818113 /*
    16249 @@ -41,7 +42,7 @@
     18114@@ -41,40 +42,54 @@
    1625018115 
    1625118116 #include <curses.priv.h>
    1625218117 
    1625318118-MODULE_ID("$Id: lib_getch.c,v 1.99 2008/09/20 19:46:13 tom Exp $")
    16254 +MODULE_ID("$Id: lib_getch.c,v 1.101 2009/02/28 19:16:40 tom Exp $")
     18119+MODULE_ID("$Id: lib_getch.c,v 1.103 2009/05/30 15:50:47 tom Exp $")
    1625518120 
    1625618121 #include <fifo_defs.h>
    1625718122 
    16258 @@ -54,27 +55,36 @@
     18123 #if USE_REENTRANT
     18124 #define GetEscdelay(sp) (sp)->_ESCDELAY
     18125+NCURSES_EXPORT(int *)
     18126+_nc_ptr_Escdelay(SCREEN *sp)
     18127+{
     18128+    return ptrEscdelay(sp);
     18129+}
     18130 NCURSES_EXPORT(int)
     18131 NCURSES_PUBLIC_VAR(ESCDELAY) (void)
     18132 {
     18133-    return SP ? GetEscdelay(SP) : 1000;
     18134+    return *_nc_ptr_Escdelay(CURRENT_SCREEN);
    1625918135 }
    1626018136 #else
     
    1629818174 static int
    1629918175 _nc_use_meta(WINDOW *win)
    16300 @@ -84,9 +94,9 @@
     18176@@ -84,9 +99,9 @@
    1630118177 }
    1630218178 
     
    1631018186 
    1631118187 /*
    16312 @@ -109,7 +119,7 @@
     18188@@ -109,7 +124,7 @@
    1631318189        && (sp->_sysmouse_head < sp->_sysmouse_tail)
    1631418190        && (rc == 0)
     
    1631918195 #endif
    1632018196     return rc;
    16321 @@ -173,7 +183,7 @@
     18197@@ -173,9 +188,9 @@
    1632218198     } else
    1632318199        mask = 0;
     
    1632618202+    if (mask & TW_EVENT) {
    1632718203        T(("fifo_push: ungetch KEY_EVENT"));
    16328         _nc_ungetch(sp, KEY_EVENT);
     18204-       _nc_ungetch(sp, KEY_EVENT);
     18205+       safe_ungetch(sp, KEY_EVENT);
    1632918206        return KEY_EVENT;
    16330 @@ -185,7 +195,7 @@
     18207     }
     18208 #elif USE_GPM_SUPPORT || USE_EMX_MOUSE || USE_SYSMOUSE
     18209@@ -185,7 +200,7 @@
    1633118210 #endif
    1633218211 
     
    1633718216        ch = KEY_MOUSE;
    1633818217        n = 1;
    16339 @@ -260,12 +270,12 @@
     18218@@ -260,12 +275,12 @@
    1634018219 {
    1634118220 #ifdef USE_PTHREADS
     
    1635218231        recur_wrefresh(win);
    1635318232        _nc_set_screen(save_SP);
    16354 @@ -286,12 +296,12 @@
     18233@@ -286,12 +301,12 @@
    1635518234 
    1635618235     if (sp != 0) {
     
    1636718246            rc = recur_wgetnstr(win, buf);
    1636818247            _nc_set_screen(save_SP);
    16369 @@ -402,7 +412,7 @@
     18248@@ -362,9 +377,9 @@
     18249 #ifdef NCURSES_WGETCH_EVENTS
     18250        if (rc != KEY_EVENT)
     18251 #endif
     18252-           _nc_ungetch(sp, '\n');
     18253+           safe_ungetch(sp, '\n');
     18254        for (bufp = buf + strlen(buf); bufp > buf; bufp--)
     18255-           _nc_ungetch(sp, bufp[-1]);
     18256+           safe_ungetch(sp, bufp[-1]);
     18257 
     18258 #ifdef NCURSES_WGETCH_EVENTS
     18259        /* Return it first */
     18260@@ -402,7 +417,7 @@
    1637018261            rc = check_mouse_activity(sp, delay EVENTLIST_2nd(evl));
    1637118262 
     
    1637618267                returnCode(KEY_CODE_YES);
    1637718268            }
    16378 @@ -427,7 +437,7 @@
     18269@@ -427,7 +442,7 @@
    1637918270         * increase the wait with mouseinterval().
    1638018271         */
     
    1638518276        do {
    1638618277            ch = kgetch(sp EVENTLIST_2nd(evl));
    16387 @@ -442,10 +452,10 @@
     18278@@ -442,11 +457,11 @@
    1638818279            (ch == KEY_MOUSE
    1638918280             && (((rc = check_mouse_activity(sp, sp->_maxclick
     
    1639418285 #ifdef NCURSES_WGETCH_EVENTS
    1639518286-       if ((rc & 4) && !ch == KEY_EVENT) {
     18287-           _nc_ungetch(sp, ch);
    1639618288+       if ((rc & TW_EVENT) && !(ch == KEY_EVENT)) {
    16397             _nc_ungetch(sp, ch);
     18289+           safe_ungetch(sp, ch);
    1639818290            ch = KEY_EVENT;
    1639918291        }
    16400 @@ -645,7 +655,7 @@
     18292 #endif
     18293@@ -454,12 +469,12 @@
     18294 #ifdef NCURSES_WGETCH_EVENTS
     18295            /* mouse event sequence ended by an event, report event */
     18296            if (ch == KEY_EVENT) {
     18297-               _nc_ungetch(sp, KEY_MOUSE);     /* FIXME This interrupts a gesture... */
     18298+               safe_ungetch(sp, KEY_MOUSE);    /* FIXME This interrupts a gesture... */
     18299            } else
     18300 #endif
     18301            {
     18302                /* mouse event sequence ended by keystroke, store keystroke */
     18303-               _nc_ungetch(sp, ch);
     18304+               safe_ungetch(sp, ch);
     18305                ch = KEY_MOUSE;
     18306            }
     18307        }
     18308@@ -645,7 +660,7 @@
    1640118309            TR(TRACE_IEVENT, ("waiting for rest of sequence"));
    1640218310            rc = check_mouse_activity(sp, timeleft EVENTLIST_2nd(evl));
     
    1640718315                /* FIXME Should have preserved remainder timeleft for reuse... */
    1640818316                peek = head;    /* Restart interpreting later */
     18317diff -Naur ncurses-5.7.orig/ncurses/base/lib_getstr.c ncurses-5.7/ncurses/base/lib_getstr.c
     18318--- ncurses-5.7.orig/ncurses/base/lib_getstr.c  2008-08-16 12:20:04.000000000 -0700
     18319+++ ncurses-5.7/ncurses/base/lib_getstr.c       2009-06-05 14:01:51.000000000 -0700
     18320@@ -1,5 +1,5 @@
     18321 /****************************************************************************
     18322- * Copyright (c) 1998-2006,2008 Free Software Foundation, Inc.              *
     18323+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     18324  *                                                                          *
     18325  * Permission is hereby granted, free of charge, to any person obtaining a  *
     18326  * copy of this software and associated documentation files (the            *
     18327@@ -39,9 +39,8 @@
     18328 */
     18329 
     18330 #include <curses.priv.h>
     18331-#include <term.h>
     18332 
     18333-MODULE_ID("$Id: lib_getstr.c,v 1.27 2008/08/16 19:20:04 tom Exp $")
     18334+MODULE_ID("$Id: lib_getstr.c,v 1.28 2009/05/09 17:02:41 tom Exp $")
     18335 
     18336 /*
     18337  * This wipes out the last character, no matter whether it was a tab, control
     18338@@ -89,19 +88,19 @@
     18339     if (!win)
     18340        returnCode(ERR);
     18341 
     18342-    _nc_get_tty_mode(&buf);
     18343+    NCURSES_SP_NAME(_nc_get_tty_mode) (NCURSES_SP_ARGx &buf);
     18344 
     18345     oldnl = sp->_nl;
     18346     oldecho = sp->_echo;
     18347     oldraw = sp->_raw;
     18348     oldcbreak = sp->_cbreak;
     18349-    nl();
     18350-    noecho();
     18351-    noraw();
     18352-    cbreak();
     18353+    NCURSES_SP_NAME(nl) (NCURSES_SP_ARG);
     18354+    NCURSES_SP_NAME(noecho) (NCURSES_SP_ARG);
     18355+    NCURSES_SP_NAME(noraw) (NCURSES_SP_ARG);
     18356+    NCURSES_SP_NAME(cbreak) (NCURSES_SP_ARG);
     18357 
     18358-    erasec = erasechar();
     18359-    killc = killchar();
     18360+    erasec = NCURSES_SP_NAME(erasechar) (NCURSES_SP_ARG);
     18361+    killc = NCURSES_SP_NAME(killchar) (NCURSES_SP_ARG);
     18362 
     18363     oldstr = str;
     18364     getyx(win, y, x);
     18365@@ -144,7 +143,7 @@
     18366            }
     18367        } else if (ch >= KEY_MIN
     18368                   || (maxlen >= 0 && str - oldstr >= maxlen)) {
     18369-           beep();
     18370+           NCURSES_SP_NAME(beep) (NCURSES_SP_ARG);
     18371        } else {
     18372            *str++ = (char) ch;
     18373            if (oldecho == TRUE) {
     18374@@ -193,7 +192,7 @@
     18375     sp->_raw = oldraw;
     18376     sp->_cbreak = oldcbreak;
     18377 
     18378-    _nc_set_tty_mode(&buf);
     18379+    NCURSES_SP_NAME(_nc_set_tty_mode) (NCURSES_SP_ARGx &buf);
     18380 
     18381     *str = '\0';
     18382     if (ch == ERR)
     18383diff -Naur ncurses-5.7.orig/ncurses/base/lib_initscr.c ncurses-5.7/ncurses/base/lib_initscr.c
     18384--- ncurses-5.7.orig/ncurses/base/lib_initscr.c 2008-08-16 14:20:48.000000000 -0700
     18385+++ ncurses-5.7/ncurses/base/lib_initscr.c      2009-06-05 14:01:33.000000000 -0700
     18386@@ -1,5 +1,5 @@
     18387 /****************************************************************************
     18388- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     18389+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     18390  *                                                                          *
     18391  * Permission is hereby granted, free of charge, to any person obtaining a  *
     18392  * copy of this software and associated documentation files (the            *
     18393@@ -45,7 +45,7 @@
     18394 #include <sys/termio.h>                /* needed for ISC */
     18395 #endif
     18396 
     18397-MODULE_ID("$Id: lib_initscr.c,v 1.38 2008/08/16 21:20:48 Werner.Fink Exp $")
     18398+MODULE_ID("$Id: lib_initscr.c,v 1.39 2009/02/14 20:55:49 tom Exp $")
     18399 
     18400 NCURSES_EXPORT(WINDOW *)
     18401 initscr(void)
     18402@@ -90,7 +90,11 @@
     18403        }
     18404 
     18405        /* def_shell_mode - done in newterm/_nc_setupscreen */
     18406+#if NCURSES_SP_FUNCS
     18407+       NCURSES_SP_NAME(def_prog_mode) (CURRENT_SCREEN);
     18408+#else
     18409        def_prog_mode();
     18410+#endif
     18411     }
     18412     result = stdscr;
     18413     _nc_unlock_global(curses);
     18414diff -Naur ncurses-5.7.orig/ncurses/base/lib_insch.c ncurses-5.7/ncurses/base/lib_insch.c
     18415--- ncurses-5.7.orig/ncurses/base/lib_insch.c   2008-02-02 16:14:37.000000000 -0800
     18416+++ ncurses-5.7/ncurses/base/lib_insch.c        2009-06-05 14:01:55.000000000 -0700
     18417@@ -1,5 +1,5 @@
     18418 /****************************************************************************
     18419- * Copyright (c) 1998-2005,2008 Free Software Foundation, Inc.              *
     18420+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     18421  *                                                                          *
     18422  * Permission is hereby granted, free of charge, to any person obtaining a  *
     18423  * copy of this software and associated documentation files (the            *
     18424@@ -43,24 +43,31 @@
     18425 #include <curses.priv.h>
     18426 #include <ctype.h>
     18427 
     18428-MODULE_ID("$Id: lib_insch.c,v 1.25 2008/02/03 00:14:37 tom Exp $")
     18429+MODULE_ID("$Id: lib_insch.c,v 1.29 2009/05/30 16:45:16 tom Exp $")
     18430 
     18431 /*
     18432  * Insert the given character, updating the current location to simplify
     18433  * inserting a string.
     18434  */
     18435 NCURSES_EXPORT(int)
     18436-_nc_insert_ch(WINDOW *win, chtype ch)
     18437+_nc_insert_ch(SCREEN *sp, WINDOW *win, chtype ch)
     18438 {
     18439     int code = OK;
     18440     NCURSES_CH_T wch;
     18441     int count;
     18442     NCURSES_CONST char *s;
     18443+    int tabsize =
     18444+#if USE_REENTRANT
     18445+    sp->_TABSIZE
     18446+#else
     18447+    TABSIZE
     18448+#endif
     18449+     ;
     18450 
     18451     switch (ch) {
     18452     case '\t':
     18453-       for (count = (TABSIZE - (win->_curx % TABSIZE)); count > 0; count--) {
     18454-           if ((code = _nc_insert_ch(win, ' ')) != OK)
     18455+       for (count = (tabsize - (win->_curx % tabsize)); count > 0; count--) {
     18456+           if ((code = _nc_insert_ch(sp, win, ' ')) != OK)
     18457                break;
     18458        }
     18459        break;
     18460@@ -76,7 +83,9 @@
     18461               WINDOW_EXT(win, addch_used) == 0 &&
     18462 #endif
     18463               is8bits(ChCharOf(ch)) &&
     18464-              isprint(ChCharOf(ch))) {
     18465+              (isprint(ChCharOf(ch)) ||
     18466+               (ChAttrOf(ch) & A_ALTCHARSET) ||
     18467+               (sp != 0 && sp->_legacy_coding && !iscntrl(ChCharOf(ch))))) {
     18468            if (win->_curx <= win->_maxx) {
     18469                struct ldat *line = &(win->_line[win->_cury]);
     18470                NCURSES_CH_T *end = &(line->text[win->_curx]);
     18471@@ -93,9 +102,9 @@
     18472                win->_curx++;
     18473            }
     18474        } else if (is8bits(ChCharOf(ch)) && iscntrl(ChCharOf(ch))) {
     18475-           s = unctrl(ChCharOf(ch));
     18476+           s = NCURSES_SP_NAME(unctrl) (NCURSES_SP_ARGx ChCharOf(ch));
     18477            while (*s != '\0') {
     18478-               code = _nc_insert_ch(win, ChAttrOf(ch) | UChar(*s));
     18479+               code = _nc_insert_ch(sp, win, ChAttrOf(ch) | UChar(*s));
     18480                if (code != OK)
     18481                    break;
     18482                ++s;
     18483@@ -114,12 +123,17 @@
     18484            } else if (count == -1) {
     18485                /* handle EILSEQ */
     18486                if (is8bits(ch)) {
     18487-                   s = unctrl(ChCharOf(ch));
     18488-                   while (*s != '\0') {
     18489-                       code = _nc_insert_ch(win, ChAttrOf(ch) | UChar(*s));
     18490-                       if (code != OK)
     18491-                           break;
     18492-                       ++s;
     18493+                   s = NCURSES_SP_NAME(unctrl) (NCURSES_SP_ARGx ChCharOf(ch));
     18494+                   if (strlen(s) > 1) {
     18495+                       while (*s != '\0') {
     18496+                           code = _nc_insert_ch(sp, win,
     18497+                                                ChAttrOf(ch) | UChar(*s));
     18498+                           if (code != OK)
     18499+                               break;
     18500+                           ++s;
     18501+                       }
     18502+                   } else {
     18503+                       code = ERR;
     18504                    }
     18505                } else {
     18506                    code = ERR;
     18507@@ -145,7 +159,7 @@
     18508        oy = win->_cury;
     18509        ox = win->_curx;
     18510 
     18511-       code = _nc_insert_ch(win, c);
     18512+       code = _nc_insert_ch(_nc_screen_of(win), win, c);
     18513 
     18514        win->_curx = ox;
     18515        win->_cury = oy;
     18516diff -Naur ncurses-5.7.orig/ncurses/base/lib_insnstr.c ncurses-5.7/ncurses/base/lib_insnstr.c
     18517--- ncurses-5.7.orig/ncurses/base/lib_insnstr.c 2004-02-28 15:44:56.000000000 -0800
     18518+++ ncurses-5.7/ncurses/base/lib_insnstr.c      2009-06-05 14:01:55.000000000 -0700
     18519@@ -1,5 +1,5 @@
     18520 /****************************************************************************
     18521- * Copyright (c) 2004 Free Software Foundation, Inc.                        *
     18522+ * Copyright (c) 2004,2009 Free Software Foundation, Inc.                   *
     18523  *                                                                          *
     18524  * Permission is hereby granted, free of charge, to any person obtaining a  *
     18525  * copy of this software and associated documentation files (the            *
     18526@@ -40,7 +40,7 @@
     18527 #include <curses.priv.h>
     18528 #include <ctype.h>
     18529 
     18530-MODULE_ID("$Id: lib_insnstr.c,v 1.1 2004/02/28 23:44:56 tom Exp $")
     18531+MODULE_ID("$Id: lib_insnstr.c,v 1.2 2009/05/30 14:53:49 tom Exp $")
     18532 
     18533 NCURSES_EXPORT(int)
     18534 winsnstr(WINDOW *win, const char *s, int n)
     18535@@ -54,10 +54,12 @@
     18536     T((T_CALLED("winsnstr(%p,%s,%d)"), win, _nc_visbufn(s, n), n));
     18537 
     18538     if (win != 0 && str != 0) {
     18539+       SCREEN *sp = _nc_screen_of(win);
     18540+
     18541        oy = win->_cury;
     18542        ox = win->_curx;
     18543        for (cp = str; *cp && (n <= 0 || (cp - str) < n); cp++) {
     18544-           _nc_insert_ch(win, (chtype) UChar(*cp));
     18545+           _nc_insert_ch(sp, win, (chtype) UChar(*cp));
     18546        }
     18547        win->_curx = ox;
     18548        win->_cury = oy;
    1640918549diff -Naur ncurses-5.7.orig/ncurses/base/lib_isendwin.c ncurses-5.7/ncurses/base/lib_isendwin.c
    1641018550--- ncurses-5.7.orig/ncurses/base/lib_isendwin.c        2000-12-09 18:43:27.000000000 -0800
    16411 +++ ncurses-5.7/ncurses/base/lib_isendwin.c     2009-02-28 20:38:57.047235367 -0800
     18551+++ ncurses-5.7/ncurses/base/lib_isendwin.c     2009-06-05 14:01:14.000000000 -0700
    1641218552@@ -1,5 +1,5 @@
    1641318553 /****************************************************************************
     
    1645318593diff -Naur ncurses-5.7.orig/ncurses/base/lib_mouse.c ncurses-5.7/ncurses/base/lib_mouse.c
    1645418594--- ncurses-5.7.orig/ncurses/base/lib_mouse.c   2008-10-18 14:48:55.000000000 -0700
    16455 +++ ncurses-5.7/ncurses/base/lib_mouse.c        2009-02-28 20:38:59.859415560 -0800
     18595+++ ncurses-5.7/ncurses/base/lib_mouse.c        2009-06-05 14:01:51.000000000 -0700
    1645618596@@ -1,5 +1,5 @@
    1645718597 /****************************************************************************
     
    1646118601  * Permission is hereby granted, free of charge, to any person obtaining a  *
    1646218602  * copy of this software and associated documentation files (the            *
    16463 @@ -79,9 +79,8 @@
     18603@@ -79,9 +79,12 @@
    1646418604 
    1646518605 #include <curses.priv.h>
    1646618606 
    1646718607-MODULE_ID("$Id: lib_mouse.c,v 1.102 2008/10/18 21:48:55 tom Exp $")
    16468 +MODULE_ID("$Id: lib_mouse.c,v 1.105 2009/02/28 21:09:20 tom Exp $")
     18608+#ifndef CUR
     18609+#define CUR SP_TERMTYPE
     18610+#endif
     18611+
     18612+MODULE_ID("$Id: lib_mouse.c,v 1.107 2009/05/10 00:48:29 tom Exp $")
    1646918613 
    1647018614-#include <term.h>
     
    1647218616 
    1647318617 #if USE_GPM_SUPPORT
    16474 @@ -150,7 +149,7 @@
     18618@@ -150,7 +153,7 @@
    1647518619 #define LIBGPM_SONAME "libgpm.so"
    1647618620 #endif
     
    1648118625 #endif                         /* USE_GPM_SUPPORT */
    1648218626 
    16483 @@ -164,13 +163,13 @@
     18627@@ -164,13 +167,13 @@
    1648418628 #define LastEV(sp)     ((sp)->_mouse_events + EV_MAX - 1)
    1648518629 
     
    1649918643 
    1650018644 #define IndexEV(sp, ep)        (ep - FirstEV(sp))
    16501 @@ -340,7 +339,7 @@
     18645@@ -340,7 +343,7 @@
    1650218646 static void
    1650318647 handle_sysmouse(int sig GCC_UNUSED)
     
    1650818652 #endif /* USE_SYSMOUSE */
    1650918653 
    16510 @@ -359,7 +358,9 @@
     18654@@ -359,7 +362,9 @@
    1651118655 #if USE_EMX_MOUSE
    1651218656     sp->_emxmouse_activated = enable;
     
    1651918663     sp->_mouse_active = enable;
    1652018664 }
    16521 @@ -398,7 +399,7 @@
     18665@@ -398,7 +403,7 @@
    1652218666 static void
    1652318667 unload_gpm_library(SCREEN *sp)
     
    1652818672        sp->_mouse_gpm_loaded = FALSE;
    1652918673        sp->_mouse_fd = -1;
    16530 @@ -694,11 +695,16 @@
     18674@@ -694,11 +699,16 @@
    1653118675 
    1653218676 #if USE_GPM_SUPPORT
     
    1654718691                eventp->id = NORMAL_EVENT;
    1654818692 
    16549 @@ -731,6 +737,7 @@
     18693@@ -731,6 +741,7 @@
    1655018694                /* bump the next-free pointer into the circular list */
    1655118695                sp->_mouse_eventp = eventp = NEXT(eventp);
     
    1655518699        }
    1655618700        break;
    16557 @@ -937,7 +944,7 @@
     18701@@ -937,7 +948,7 @@
    1655818702        switch (sp->_mouse_type) {
    1655918703        case M_XTERM:
     
    1656418708            TPUTS_TRACE("xterm mouse initialization");
    1656518709            enable_xterm_mouse(sp, 1);
    16566 @@ -989,7 +996,7 @@
     18710@@ -989,7 +1000,7 @@
    1656718711            return;
    1656818712        }
     
    1657318717 
    1657418718 /**************************************************************************
    16575 @@ -1264,13 +1271,13 @@
     18719@@ -1264,13 +1275,13 @@
    1657618720  *
    1657718721  **************************************************************************/
     
    1659218736        MEVENT *prev = PREV(eventp);
    1659318737 
    16594 @@ -1278,8 +1285,8 @@
     18738@@ -1278,8 +1289,8 @@
    1659518739        *aevent = *prev;
    1659618740 
     
    1660318747        prev->id = INVALID_EVENT;       /* so the queue slot becomes free */
    1660418748        returnCode(OK);
    16605 @@ -1287,57 +1294,61 @@
     18749@@ -1287,57 +1298,61 @@
    1660618750     returnCode(ERR);
    1660718751 }
     
    1668118825                    (REPORT_MOUSE_POSITION
    1668218826                     | BUTTON_ALT
    16683 @@ -1349,15 +1360,23 @@
     18827@@ -1349,15 +1364,23 @@
    1668418828                     | BUTTON_DOUBLE_CLICKED
    1668518829                     | BUTTON_TRIPLE_CLICKED);
     
    1670718851 wenclose(const WINDOW *win, int y, int x)
    1670818852 /* check to see if given window encloses given screen location */
    16709 @@ -1377,17 +1396,17 @@
     18853@@ -1377,17 +1400,17 @@
    1671018854 }
    1671118855 
     
    1673018874        oldval = DEFAULT_MAXCLICK;
    1673118875     }
    16732 @@ -1395,15 +1414,37 @@
     18876@@ -1395,15 +1418,37 @@
    1673318877     returnCode(oldval);
    1673418878 }
     
    1677118915 {
    1677218916     bool result = FALSE;
     18917diff -Naur ncurses-5.7.orig/ncurses/base/lib_mvwin.c ncurses-5.7/ncurses/base/lib_mvwin.c
     18918--- ncurses-5.7.orig/ncurses/base/lib_mvwin.c   2006-02-25 14:53:46.000000000 -0800
     18919+++ ncurses-5.7/ncurses/base/lib_mvwin.c        2009-06-05 14:01:44.000000000 -0700
     18920@@ -1,5 +1,5 @@
     18921 /****************************************************************************
     18922- * Copyright (c) 1998-2001,2006 Free Software Foundation, Inc.              *
     18923+ * Copyright (c) 1998-2006,2009 Free Software Foundation, Inc.              *
     18924  *                                                                          *
     18925  * Permission is hereby granted, free of charge, to any person obtaining a  *
     18926  * copy of this software and associated documentation files (the            *
     18927@@ -40,7 +40,7 @@
     18928 
     18929 #include <curses.priv.h>
     18930 
     18931-MODULE_ID("$Id: lib_mvwin.c,v 1.14 2006/02/25 22:53:46 tom Exp $")
     18932+MODULE_ID("$Id: lib_mvwin.c,v 1.15 2009/04/18 18:25:37 tom Exp $")
     18933 
     18934 NCURSES_EXPORT(int)
     18935 mvwin(WINDOW *win, int by, int bx)
     18936@@ -96,8 +96,8 @@
     18937     }
     18938 #endif
     18939 
     18940-    if (by + win->_maxy > screen_lines - 1
     18941-       || bx + win->_maxx > screen_columns - 1
     18942+    if (by + win->_maxy > screen_lines(CURRENT_SCREEN) - 1
     18943+       || bx + win->_maxx > screen_columns(CURRENT_SCREEN) - 1
     18944        || by < 0
     18945        || bx < 0)
     18946        returnCode(ERR);
    1677318947diff -Naur ncurses-5.7.orig/ncurses/base/lib_newterm.c ncurses-5.7/ncurses/base/lib_newterm.c
    1677418948--- ncurses-5.7.orig/ncurses/base/lib_newterm.c 2008-08-16 14:20:48.000000000 -0700
    16775 +++ ncurses-5.7/ncurses/base/lib_newterm.c      2009-02-28 20:38:57.047235367 -0800
     18949+++ ncurses-5.7/ncurses/base/lib_newterm.c      2009-06-05 14:01:51.000000000 -0700
    1677618950@@ -1,5 +1,5 @@
    1677718951 /****************************************************************************
     
    1678918963 
    1679018964 /*
    16791 @@ -48,7 +49,7 @@
     18965@@ -45,10 +46,14 @@
     18966 #define _POSIX_SOURCE
     18967 #endif
     18968 
     18969+#ifndef CUR
     18970+#define CUR SP_TERMTYPE
     18971+#endif
     18972+
    1679218973 #include <term.h>              /* clear_screen, cup & friends, cur_term */
    1679318974 #include <tic.h>
    1679418975 
    1679518976-MODULE_ID("$Id: lib_newterm.c,v 1.73 2008/08/16 21:20:48 Werner.Fink Exp $")
    16796 +MODULE_ID("$Id: lib_newterm.c,v 1.74 2009/02/15 00:37:10 tom Exp $")
     18977+MODULE_ID("$Id: lib_newterm.c,v 1.77 2009/05/10 00:48:29 tom Exp $")
    1679718978 
    1679818979 #ifndef ONLCR                  /* Allows compilation under the QNX 4.2 OS */
    1679918980 #define ONLCR 0
    16800 @@ -95,7 +96,7 @@
     18981@@ -95,7 +100,7 @@
    1680118982  * initialized.
    1680218983  */
     
    1680718988     START_TRACE();
    1680818989     T((T_CALLED("filter")));
    16809 @@ -103,23 +104,40 @@
     18990@@ -103,23 +108,42 @@
    1681018991     returnVoid;
    1681118992 }
     
    1684519026 NCURSES_EXPORT(SCREEN *)
    1684619027-newterm(NCURSES_CONST char *name, FILE *ofp, FILE *ifp)
    16847 +NCURSES_SP_NAME(newterm) (NCURSES_SP_DCLx NCURSES_CONST char *name, FILE
    16848 +                         *ofp, FILE *ifp)
     19028+NCURSES_SP_NAME(newterm) (NCURSES_SP_DCLx
     19029+                         NCURSES_CONST char *name,
     19030+                         FILE *ofp,
     19031+                         FILE *ifp)
    1684919032 {
    1685019033     int value;
    1685119034     int errret;
    16852 @@ -133,8 +151,8 @@
     19035@@ -133,8 +157,8 @@
    1685319036     _nc_init_pthreads();
    1685419037     _nc_lock_global(curses);
     
    1686119044     /* this loads the capability entry, then sets LINES and COLS */
    1686219045     if (setupterm(name, fileno(ofp), &errret) != ERR) {
    16863 @@ -159,7 +177,7 @@
     19046@@ -159,7 +183,7 @@
    1686419047            _nc_set_screen(current);
    1686519048            result = 0;
     
    1687019053             * In setupterm() we did a set_curterm(), but it was before we set
    1687119054             * SP.  So the "current" screen's terminal pointer was overwritten
    16872 @@ -233,3 +251,11 @@
     19055@@ -233,3 +257,11 @@
    1687319056     _nc_unlock_global(curses);
    1687419057     returnSP(result);
     
    1688419067diff -Naur ncurses-5.7.orig/ncurses/base/lib_newwin.c ncurses-5.7/ncurses/base/lib_newwin.c
    1688519068--- ncurses-5.7.orig/ncurses/base/lib_newwin.c  2008-06-07 06:58:09.000000000 -0700
    16886 +++ ncurses-5.7/ncurses/base/lib_newwin.c       2009-02-28 20:38:57.047235367 -0800
     19069+++ ncurses-5.7/ncurses/base/lib_newwin.c       2009-06-05 14:01:51.000000000 -0700
    1688719070@@ -1,5 +1,5 @@
    1688819071 /****************************************************************************
     
    1690519088 
    1690619089-MODULE_ID("$Id: lib_newwin.c,v 1.52 2008/06/07 13:58:09 tom Exp $")
    16907 +MODULE_ID("$Id: lib_newwin.c,v 1.53 2009/02/15 00:38:00 tom Exp $")
     19090+MODULE_ID("$Id: lib_newwin.c,v 1.57 2009/05/09 23:40:03 tom Exp $")
    1690819091 
    1690919092 #define window_is(name) ((sp)->_##name == win)
     19093 
     19094@@ -87,11 +88,11 @@
     19095     if (win != 0) {
     19096        if (_nc_try_global(curses) == 0) {
     19097            q = 0;
     19098-           for (each_window(p)) {
     19099+           for (each_window(SP, p)) {
     19100                if (&(p->win) == win) {
     19101                    remove_window_from_screen(win);
     19102                    if (q == 0)
     19103-                       _nc_windows = p->next;
     19104+                       WindowList(SP) = p->next;
     19105                    else
     19106                        q->next = p->next;
    1691019107 
    1691119108@@ -115,7 +116,8 @@
     
    1691919116     WINDOW *win;
    1692019117     NCURSES_CH_T *ptr;
    16921 @@ -127,7 +129,7 @@
     19118@@ -127,11 +129,13 @@
    1692219119        returnWin(0);
    1692319120 
     
    1692619123+       num_lines = SP_PARM->_lines_avail - begy;
    1692719124     if (num_columns == 0)
    16928         num_columns = screen_columns - begx;
    16929  
    16930 @@ -149,6 +151,15 @@
     19125-       num_columns = screen_columns - begx;
     19126+       num_columns = screen_columns(SP_PARM) - begx;
     19127 
     19128-    if ((win = _nc_makenew(num_lines, num_columns, begy, begx, 0)) == 0)
     19129+    win = NCURSES_SP_NAME(_nc_makenew) (NCURSES_SP_ARGx
     19130+                                       num_lines, num_columns, begy, begx, 0);
     19131+    if (win == 0)
     19132        returnWin(0);
     19133 
     19134     for (i = 0; i < num_lines; i++) {
     19135@@ -149,9 +153,22 @@
    1693119136     returnWin(win);
    1693219137 }
     
    1693619141+newwin(int num_lines, int num_columns, int begy, int begx)
    1693719142+{
    16938 +    return NCURSES_SP_NAME(newwin) (CURRENT_SCREEN, num_lines, num_columns,
     19143+    return NCURSES_SP_NAME(newwin) (CURRENT_SCREEN,
     19144+                                   num_lines, num_columns,
    1693919145+                                   begy, begx);
    1694019146+}
     
    1694419150 derwin(WINDOW *orig, int num_lines, int num_columns, int begy, int begx)
    1694519151 {
     19152+#if NCURSES_SP_FUNCS
     19153+    SCREEN *sp = CURRENT_SCREEN;
     19154+#endif
     19155     WINDOW *win;
     19156     int i;
     19157     int flags = _SUBWIN;
     19158@@ -177,8 +194,10 @@
     19159     if (orig->_flags & _ISPAD)
     19160        flags |= _ISPAD;
     19161 
     19162-    if ((win = _nc_makenew(num_lines, num_columns, orig->_begy + begy,
     19163-                          orig->_begx + begx, flags)) == 0)
     19164+    win = NCURSES_SP_NAME(_nc_makenew) (NCURSES_SP_ARGx num_lines, num_columns,
     19165+                                       orig->_begy + begy,
     19166+                                       orig->_begx + begx, flags);
     19167+    if (win == 0)
     19168        returnWin(0);
     19169 
     19170     win->_pary = begy;
     19171@@ -211,16 +230,22 @@
     19172 }
     19173 
     19174 NCURSES_EXPORT(WINDOW *)
     19175-_nc_makenew(int num_lines, int num_columns, int begy, int begx, int flags)
     19176+NCURSES_SP_NAME(_nc_makenew) (NCURSES_SP_DCLx
     19177+                             int num_lines,
     19178+                             int num_columns,
     19179+                             int begy,
     19180+                             int begx,
     19181+                             int flags)
     19182 {
     19183     int i;
     19184     WINDOWLIST *wp;
     19185     WINDOW *win;
     19186     bool is_pad = (flags & _ISPAD);
     19187 
     19188-    T((T_CALLED("_nc_makenew(%d,%d,%d,%d)"), num_lines, num_columns, begy, begx));
     19189+    T((T_CALLED("_nc_makenew(%p,%d,%d,%d,%d)"),
     19190+       SP_PARM, num_lines, num_columns, begy, begx));
     19191 
     19192-    if (SP == 0)
     19193+    if (SP_PARM == 0)
     19194        returnWin(0);
     19195 
     19196     if (!dimension_limit(num_lines) || !dimension_limit(num_columns))
     19197@@ -244,14 +269,16 @@
     19198     win->_maxx = num_columns - 1;
     19199     win->_begy = begy;
     19200     win->_begx = begx;
     19201-    win->_yoffset = SP->_topstolen;
     19202+    win->_yoffset = SP_PARM->_topstolen;
     19203 
     19204     win->_flags = flags;
     19205     WINDOW_ATTRS(win) = A_NORMAL;
     19206     SetChar(win->_nc_bkgd, BLANK_TEXT, BLANK_ATTR);
     19207 
     19208-    win->_clear = is_pad ? FALSE : (num_lines == screen_lines
     19209-                                   && num_columns == screen_columns);
     19210+    win->_clear = (is_pad
     19211+                  ? FALSE
     19212+                  : (num_lines == screen_lines(SP_PARM)
     19213+                     && num_columns == screen_columns(SP_PARM)));
     19214     win->_idlok = FALSE;
     19215     win->_idcok = TRUE;
     19216     win->_scroll = FALSE;
     19217@@ -300,19 +327,19 @@
     19218        if_USE_SCROLL_HINTS(win->_line[i].oldindex = i);
     19219     }
     19220 
     19221-    if (!is_pad && (begx + num_columns == screen_columns)) {
     19222+    if (!is_pad && (begx + num_columns == screen_columns(SP_PARM))) {
     19223        win->_flags |= _ENDLINE;
     19224 
     19225-       if (begx == 0 && num_lines == screen_lines && begy == 0)
     19226+       if (begx == 0 && num_lines == screen_lines(SP_PARM) && begy == 0)
     19227            win->_flags |= _FULLWIN;
     19228 
     19229-       if (begy + num_lines == screen_lines)
     19230+       if (begy + num_lines == screen_lines(SP_PARM))
     19231            win->_flags |= _SCROLLWIN;
     19232     }
     19233 
     19234-    wp->next = _nc_windows;
     19235-    wp->screen = SP;
     19236-    _nc_windows = wp;
     19237+    wp->next = WindowList(SP_PARM);
     19238+    wp->screen = SP_PARM;
     19239+    WindowList(SP_PARM) = wp;
     19240 
     19241     T((T_CREATE("window %p"), win));
     19242 
     19243@@ -320,6 +347,16 @@
     19244     returnWin(win);
     19245 }
     19246 
     19247+#if NCURSES_SP_FUNCS
     19248+NCURSES_EXPORT(WINDOW *)
     19249+_nc_makenew(int num_lines, int num_columns, int begy, int begx, int flags)
     19250+{
     19251+    return NCURSES_SP_NAME(_nc_makenew) (CURRENT_SCREEN,
     19252+                                        num_lines, num_columns,
     19253+                                        begy, begx, flags);
     19254+}
     19255+#endif
     19256+
     19257 /*
     19258  * wgetch() and other functions with a WINDOW* parameter may use a SCREEN*
     19259  * internally, and it is useful to allow those to be invoked without switching
     19260@@ -336,3 +373,23 @@
     19261     }
     19262     return (sp);
     19263 }
     19264+
     19265+#if NCURSES_SP_FUNCS
     19266+NCURSES_EXPORT(WINDOW *)
     19267+_nc_curscr_of(SCREEN *sp)
     19268+{
     19269+    return sp == 0 ? 0 : sp->_curscr;
     19270+}
     19271+
     19272+NCURSES_EXPORT(WINDOW *)
     19273+_nc_newscr_of(SCREEN *sp)
     19274+{
     19275+    return sp == 0 ? 0 : sp->_newscr;
     19276+}
     19277+
     19278+NCURSES_EXPORT(WINDOW *)
     19279+_nc_stdscr_of(SCREEN *sp)
     19280+{
     19281+    return sp == 0 ? 0 : sp->_stdscr;
     19282+}
     19283+#endif
    1694619284diff -Naur ncurses-5.7.orig/ncurses/base/lib_nl.c ncurses-5.7/ncurses/base/lib_nl.c
    1694719285--- ncurses-5.7.orig/ncurses/base/lib_nl.c      2000-12-09 18:43:27.000000000 -0800
    16948 +++ ncurses-5.7/ncurses/base/lib_nl.c   2009-02-28 20:38:58.435326721 -0800
     19286+++ ncurses-5.7/ncurses/base/lib_nl.c   2009-06-05 14:01:16.000000000 -0700
    1694919287@@ -1,5 +1,5 @@
    1695019288 /****************************************************************************
     
    1703019368diff -Naur ncurses-5.7.orig/ncurses/base/lib_pad.c ncurses-5.7/ncurses/base/lib_pad.c
    1703119369--- ncurses-5.7.orig/ncurses/base/lib_pad.c     2006-10-14 13:47:13.000000000 -0700
    17032 +++ ncurses-5.7/ncurses/base/lib_pad.c  2009-02-28 20:38:57.047235367 -0800
     19370+++ ncurses-5.7/ncurses/base/lib_pad.c  2009-06-05 14:01:44.000000000 -0700
    1703319371@@ -1,5 +1,5 @@
    1703419372 /****************************************************************************
    1703519373- * Copyright (c) 1998-2004,2006 Free Software Foundation, Inc.                   *
    17036 + * Copyright (c) 1998-2006,2009 Free Software Foundation, Inc.                   *
     19374+ * Copyright (c) 1998-2006,2009 Free Software Foundation, Inc.              *
    1703719375  *                                                                          *
    1703819376  * Permission is hereby granted, free of charge, to any person obtaining a  *
     
    1705219390 
    1705319391-MODULE_ID("$Id: lib_pad.c,v 1.41 2006/10/14 20:47:13 tom Exp $")
    17054 +MODULE_ID("$Id: lib_pad.c,v 1.42 2009/02/15 00:38:48 tom Exp $")
     19392+MODULE_ID("$Id: lib_pad.c,v 1.43 2009/04/18 18:25:37 tom Exp $")
    1705519393 
    1705619394 NCURSES_EXPORT(WINDOW *)
     
    1707519413 subpad(WINDOW *orig, int l, int c, int begy, int begx)
    1707619414 {
    17077 diff -Naur ncurses-5.7.orig/ncurses/base/lib_screen.c ncurses-5.7/ncurses/base/lib_screen.c
    17078 --- ncurses-5.7.orig/ncurses/base/lib_screen.c  2008-08-16 12:05:37.000000000 -0700
    17079 +++ ncurses-5.7/ncurses/base/lib_screen.c       2009-02-28 20:38:57.047235367 -0800
     19415@@ -162,8 +172,8 @@
     19416        pmaxcol = pmincol + smaxcol - smincol;
     19417     }
     19418 
     19419-    if (smaxrow >= screen_lines
     19420-       || smaxcol >= screen_columns
     19421+    if (smaxrow >= screen_lines(CURRENT_SCREEN)
     19422+       || smaxcol >= screen_columns(CURRENT_SCREEN)
     19423        || sminrow > smaxrow
     19424        || smincol > smaxcol)
     19425        returnCode(ERR);
     19426diff -Naur ncurses-5.7.orig/ncurses/base/lib_printw.c ncurses-5.7/ncurses/base/lib_printw.c
     19427--- ncurses-5.7.orig/ncurses/base/lib_printw.c  2006-12-17 11:21:39.000000000 -0800
     19428+++ ncurses-5.7/ncurses/base/lib_printw.c       2009-06-05 14:01:44.000000000 -0700
     19429@@ -1,5 +1,5 @@
     19430 /****************************************************************************
     19431- * Copyright (c) 1998-2003,2005 Free Software Foundation, Inc.              *
     19432+ * Copyright (c) 1998-2005,2009 Free Software Foundation, Inc.              *
     19433  *                                                                          *
     19434  * Permission is hereby granted, free of charge, to any person obtaining a  *
     19435  * copy of this software and associated documentation files (the            *
     19436@@ -39,7 +39,7 @@
     19437 
     19438 #include <curses.priv.h>
     19439 
     19440-MODULE_ID("$Id: lib_printw.c,v 1.18 2006/12/17 19:21:39 tom Exp $")
     19441+MODULE_ID("$Id: lib_printw.c,v 1.19 2009/04/18 18:45:55 tom Exp $")
     19442 
     19443 NCURSES_EXPORT(int)
     19444 printw(const char *fmt,...)
     19445@@ -128,10 +128,14 @@
     19446 {
     19447     char *buf;
     19448     int code = ERR;
     19449+#if NCURSES_SP_FUNCS
     19450+    SCREEN *sp = _nc_screen_of(win);
     19451+#endif
     19452 
     19453     T((T_CALLED("vwprintw(%p,%s,va_list)"), win, _nc_visbuf(fmt)));
     19454 
     19455-    if ((buf = _nc_printf_string(fmt, argp)) != 0) {
     19456+    buf = NCURSES_SP_NAME(_nc_printf_string) (NCURSES_SP_ARGx fmt, argp);
     19457+    if (buf != 0) {
     19458        code = waddstr(win, buf);
     19459     }
     19460     returnCode(code);
     19461diff -Naur ncurses-5.7.orig/ncurses/base/lib_redrawln.c ncurses-5.7/ncurses/base/lib_redrawln.c
     19462--- ncurses-5.7.orig/ncurses/base/lib_redrawln.c        2007-10-13 13:08:56.000000000 -0700
     19463+++ ncurses-5.7/ncurses/base/lib_redrawln.c     2009-06-05 14:01:44.000000000 -0700
     19464@@ -1,5 +1,5 @@
     19465 /****************************************************************************
     19466- * Copyright (c) 1998-2006,2007 Free Software Foundation, Inc.              *
     19467+ * Copyright (c) 1998-2007,2009 Free Software Foundation, Inc.              *
     19468  *                                                                          *
     19469  * Permission is hereby granted, free of charge, to any person obtaining a  *
     19470  * copy of this software and associated documentation files (the            *
     19471@@ -39,7 +39,7 @@
     19472 
     19473 #include <curses.priv.h>
     19474 
     19475-MODULE_ID("$Id: lib_redrawln.c,v 1.12 2007/10/13 20:08:56 tom Exp $")
     19476+MODULE_ID("$Id: lib_redrawln.c,v 1.13 2009/04/18 18:46:00 tom Exp $")
     19477 
     19478 NCURSES_EXPORT(int)
     19479 wredrawln(WINDOW *win, int beg, int num)
     19480@@ -47,37 +47,40 @@
     19481     int i;
     19482     int end;
     19483     size_t len;
     19484+    SCREEN *sp;
     19485 
     19486     T((T_CALLED("wredrawln(%p,%d,%d)"), win, beg, num));
     19487 
     19488     if (win == 0)
     19489        returnCode(ERR);
     19490 
     19491+    sp = _nc_screen_of(win);
     19492+
     19493     if (beg < 0)
     19494        beg = 0;
     19495 
     19496     if (touchline(win, beg, num) == ERR)
     19497        returnCode(ERR);
     19498 
     19499-    if (touchline(curscr, beg + win->_begy, num) == ERR)
     19500+    if (touchline(sp->_curscr, beg + win->_begy, num) == ERR)
     19501        returnCode(ERR);
     19502 
     19503     end = beg + num;
     19504-    if (end > curscr->_maxy + 1)
     19505-       end = curscr->_maxy + 1;
     19506+    if (end > sp->_curscr->_maxy + 1)
     19507+       end = sp->_curscr->_maxy + 1;
     19508     if (end > win->_maxy + 1)
     19509        end = win->_maxy + 1;
     19510 
     19511     len = (win->_maxx + 1);
     19512-    if (len > (size_t) (curscr->_maxx + 1))
     19513-       len = (size_t) (curscr->_maxx + 1);
     19514-    len *= sizeof(curscr->_line[0].text[0]);
     19515+    if (len > (size_t) (sp->_curscr->_maxx + 1))
     19516+       len = (size_t) (sp->_curscr->_maxx + 1);
     19517+    len *= sizeof(sp->_curscr->_line[0].text[0]);
     19518 
     19519     for (i = beg; i < end; i++) {
     19520        int crow = i + win->_begy;
     19521 
     19522-       memset(curscr->_line[crow].text + win->_begx, 0, len);
     19523-       _nc_make_oldhash(crow);
     19524+       memset(sp->_curscr->_line[crow].text + win->_begx, 0, len);
     19525+       NCURSES_SP_NAME(_nc_make_oldhash) (NCURSES_SP_ARGx crow);
     19526     }
     19527 
     19528     returnCode(OK);
     19529diff -Naur ncurses-5.7.orig/ncurses/base/lib_restart.c ncurses-5.7/ncurses/base/lib_restart.c
     19530--- ncurses-5.7.orig/ncurses/base/lib_restart.c 2008-06-21 10:31:22.000000000 -0700
     19531+++ ncurses-5.7/ncurses/base/lib_restart.c      2009-06-05 14:01:49.000000000 -0700
    1708019532@@ -1,5 +1,5 @@
    1708119533 /****************************************************************************
     
    1708519537  * Permission is hereby granted, free of charge, to any person obtaining a  *
    1708619538  * copy of this software and associated documentation files (the            *
    17087 @@ -30,11 +30,12 @@
     19539@@ -30,6 +30,7 @@
     19540  *  Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1992,1995               *
     19541  *     and: Eric S. Raymond <esr@snark.thyrsus.com>                         *
     19542  *     and: Thomas E. Dickey                        1996-on                 *
     19543+ *     and: Juergen Pfeifer                         2008                    *
     19544  ****************************************************************************/
     19545 
     19546 /*
     19547@@ -44,49 +45,52 @@
     19548 #define _POSIX_SOURCE
     19549 #endif
     19550 
     19551-#include <term.h>              /* lines, columns, cur_term */
     19552-
     19553-MODULE_ID("$Id: lib_restart.c,v 1.10 2008/06/21 17:31:22 tom Exp $")
     19554+MODULE_ID("$Id: lib_restart.c,v 1.11 2009/05/02 20:47:42 tom Exp $")
     19555 
     19556 NCURSES_EXPORT(int)
     19557-restartterm(NCURSES_CONST char *termp, int filenum, int *errret)
     19558+NCURSES_SP_NAME(restartterm) (NCURSES_SP_DCLx
     19559+                             NCURSES_CONST char *termp,
     19560+                             int filenum,
     19561+                             int *errret)
     19562 {
     19563     int result;
     19564 
     19565-    T((T_CALLED("restartterm(%s,%d,%p)"), termp, filenum, errret));
     19566+    T((T_CALLED("restartterm(%p,%s,%d,%p)"), SP_PARM, termp, filenum, errret));
     19567 
     19568     if (setupterm(termp, filenum, errret) != OK) {
     19569        result = ERR;
     19570-    } else if (SP != 0) {
     19571-       int saveecho = SP->_echo;
     19572-       int savecbreak = SP->_cbreak;
     19573-       int saveraw = SP->_raw;
     19574-       int savenl = SP->_nl;
     19575-
     19576-       if (saveecho)
     19577-           echo();
     19578-       else
     19579-           noecho();
     19580+    } else if (SP_PARM != 0) {
     19581+       int saveecho = SP_PARM->_echo;
     19582+       int savecbreak = SP_PARM->_cbreak;
     19583+       int saveraw = SP_PARM->_raw;
     19584+       int savenl = SP_PARM->_nl;
     19585+
     19586+       if (saveecho) {
     19587+           NCURSES_SP_NAME(echo) (NCURSES_SP_ARG);
     19588+       } else {
     19589+           NCURSES_SP_NAME(noecho) (NCURSES_SP_ARG);
     19590+       }
     19591 
     19592        if (savecbreak) {
     19593-           cbreak();
     19594-           noraw();
     19595+           NCURSES_SP_NAME(cbreak) (NCURSES_SP_ARG);
     19596+           NCURSES_SP_NAME(noraw) (NCURSES_SP_ARG);
     19597        } else if (saveraw) {
     19598-           nocbreak();
     19599-           raw();
     19600+           NCURSES_SP_NAME(nocbreak) (NCURSES_SP_ARG);
     19601+           NCURSES_SP_NAME(raw) (NCURSES_SP_ARG);
     19602+       } else {
     19603+           NCURSES_SP_NAME(nocbreak) (NCURSES_SP_ARG);
     19604+           NCURSES_SP_NAME(noraw) (NCURSES_SP_ARG);
     19605+       }
     19606+       if (savenl) {
     19607+           NCURSES_SP_NAME(nl) (NCURSES_SP_ARG);
     19608        } else {
     19609-           nocbreak();
     19610-           noraw();
     19611+           NCURSES_SP_NAME(nonl) (NCURSES_SP_ARG);
     19612        }
     19613-       if (savenl)
     19614-           nl();
     19615-       else
     19616-           nonl();
     19617 
     19618-       reset_prog_mode();
     19619+       NCURSES_SP_NAME(reset_prog_mode) (NCURSES_SP_ARG);
     19620 
     19621 #if USE_SIZECHANGE
     19622-       _nc_update_screensize(SP);
     19623+       _nc_update_screensize(SP_PARM);
     19624 #endif
     19625 
     19626        result = OK;
     19627@@ -95,3 +99,11 @@
     19628     }
     19629     returnCode(result);
     19630 }
     19631+
     19632+#if NCURSES_SP_FUNCS
     19633+NCURSES_EXPORT(int)
     19634+restartterm(NCURSES_CONST char *termp, int filenum, int *errret)
     19635+{
     19636+    return NCURSES_SP_NAME(restartterm) (CURRENT_SCREEN, termp, filenum, errret);
     19637+}
     19638+#endif
     19639diff -Naur ncurses-5.7.orig/ncurses/base/lib_screen.c ncurses-5.7/ncurses/base/lib_screen.c
     19640--- ncurses-5.7.orig/ncurses/base/lib_screen.c  2008-08-16 12:05:37.000000000 -0700
     19641+++ ncurses-5.7/ncurses/base/lib_screen.c       2009-06-05 14:01:51.000000000 -0700
     19642@@ -1,5 +1,5 @@
     19643 /****************************************************************************
     19644- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     19645+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     19646  *                                                                          *
     19647  * Permission is hereby granted, free of charge, to any person obtaining a  *
     19648  * copy of this software and associated documentation files (the            *
     19649@@ -30,11 +30,16 @@
    1708819650  *  Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1992,1995               *
    1708919651  *     and: Eric S. Raymond <esr@snark.thyrsus.com>                         *
     
    1709519657 
    1709619658-MODULE_ID("$Id: lib_screen.c,v 1.31 2008/08/16 19:05:37 tom Exp $")
    17097 +MODULE_ID("$Id: lib_screen.c,v 1.32 2009/02/15 00:39:13 tom Exp $")
     19659+#ifndef CUR
     19660+#define CUR SP_TERMTYPE
     19661+#endif
     19662+
     19663+MODULE_ID("$Id: lib_screen.c,v 1.34 2009/05/10 00:48:29 tom Exp $")
    1709819664 
    1709919665 #define MAX_SIZE 0x3fff                /* 16k is big enough for a window or pad */
    1710019666 
    17101 @@ -141,7 +142,7 @@
     19667@@ -141,7 +146,7 @@
    1710219668 }
    1710319669 
     
    1710819674     FILE *fp = 0;
    1710919675 
    17110 @@ -152,15 +153,23 @@
     19676@@ -152,15 +157,23 @@
    1711119677        returnCode(ERR);
    1711219678     } else {
     
    1713419700 scr_dump(const char *file)
    1713519701 {
    17136 @@ -179,7 +188,7 @@
     19702@@ -179,7 +192,7 @@
    1713719703 }
    1713819704 
     
    1714319709     FILE *fp = 0;
    1714419710 
    17145 @@ -193,17 +202,25 @@
     19711@@ -193,17 +206,25 @@
    1714619712        returnCode(ERR);
    1714719713     } else {
     
    1717219738     T((T_CALLED("scr_set(%s)"), _nc_visbuf(file)));
    1717319739 
    17174 @@ -211,10 +228,18 @@
     19740@@ -211,10 +232,18 @@
    1717519741        returnCode(ERR);
    1717619742     } else {
     
    1719519761diff -Naur ncurses-5.7.orig/ncurses/base/lib_set_term.c ncurses-5.7/ncurses/base/lib_set_term.c
    1719619762--- ncurses-5.7.orig/ncurses/base/lib_set_term.c        2008-08-04 11:11:12.000000000 -0700
    17197 +++ ncurses-5.7/ncurses/base/lib_set_term.c     2009-02-28 20:38:57.051235647 -0800
     19763+++ ncurses-5.7/ncurses/base/lib_set_term.c     2009-06-05 14:01:51.000000000 -0700
    1719819764@@ -1,5 +1,5 @@
    1719919765 /****************************************************************************
     
    1721119777 
    1721219778 /*
    17213 @@ -44,7 +45,7 @@
     19779@@ -44,7 +45,11 @@
    1721419780 #include <term.h>              /* cur_term */
    1721519781 #include <tic.h>
    1721619782 
    1721719783-MODULE_ID("$Id: lib_set_term.c,v 1.117 2008/08/04 18:11:12 tom Exp $")
    17218 +MODULE_ID("$Id: lib_set_term.c,v 1.118 2009/02/15 00:39:46 tom Exp $")
     19784+#ifndef CUR
     19785+#define CUR SP_TERMTYPE
     19786+#endif
     19787+
     19788+MODULE_ID("$Id: lib_set_term.c,v 1.122 2009/05/10 00:48:29 tom Exp $")
    1721919789 
    1722019790 NCURSES_EXPORT(SCREEN *)
    1722119791 set_term(SCREEN *screenp)
    17222 @@ -635,7 +636,9 @@
     19792@@ -256,6 +261,9 @@
     19793                bool filtered,
     19794                int slk_format)
     19795 {
     19796+#if NCURSES_SP_FUNCS
     19797+    SCREEN *sp = CURRENT_SCREEN;
     19798+#endif
     19799     char *env;
     19800     int bottom_stolen = 0;
     19801     bool support_cookies = USE_XMC_SUPPORT;
     19802@@ -555,8 +563,8 @@
     19803     def_shell_mode();
     19804     def_prog_mode();
     19805 
     19806-    for (rop = ripoff_stack;
     19807-        rop != ripoff_sp && (rop - ripoff_stack) < N_RIPS;
     19808+    for (rop = safe_ripoff_stack;
     19809+        rop != safe_ripoff_sp && (rop - safe_ripoff_stack) < N_RIPS;
     19810         rop++) {
     19811 
     19812        /* If we must simulate soft labels, grab off the line to be used.
     19813@@ -595,7 +603,7 @@
     19814        }
     19815     }
     19816     /* reset the stack */
     19817-    ripoff_sp = ripoff_stack;
     19818+    safe_ripoff_sp = safe_ripoff_stack;
     19819 
     19820     T(("creating stdscr"));
     19821     assert((SP->_lines_avail + SP->_topstolen + bottom_stolen) == slines);
     19822@@ -615,27 +623,39 @@
     19823  * off from the top or bottom.
     19824  */
     19825 NCURSES_EXPORT(int)
     19826-_nc_ripoffline(int line, int (*init) (WINDOW *, int))
     19827+NCURSES_SP_NAME(_nc_ripoffline) (NCURSES_SP_DCLx
     19828+                                int line,
     19829+                                int (*init) (WINDOW *, int))
     19830 {
     19831     T((T_CALLED("_nc_ripoffline(%d, %p)"), line, init));
     19832 
     19833     if (line != 0) {
     19834 
     19835-       if (ripoff_sp == 0)
     19836-           ripoff_sp = ripoff_stack;
     19837-       if (ripoff_sp >= ripoff_stack + N_RIPS)
     19838+       if (safe_ripoff_sp == 0)
     19839+           safe_ripoff_sp = safe_ripoff_stack;
     19840+       if (safe_ripoff_sp >= safe_ripoff_stack + N_RIPS)
     19841            returnCode(ERR);
     19842 
     19843-       ripoff_sp->line = line;
     19844-       ripoff_sp->hook = init;
     19845-       ripoff_sp++;
     19846+       safe_ripoff_sp->line = line;
     19847+       safe_ripoff_sp->hook = init;
     19848+       safe_ripoff_sp++;
     19849     }
     19850 
     19851     returnCode(OK);
    1722319852 }
    1722419853 
     19854+#if NCURSES_SP_FUNCS
    1722519855 NCURSES_EXPORT(int)
    1722619856-ripoffline(int line, int (*init) (WINDOW *, int))
     19857+_nc_ripoffline(int line, int (*init) (WINDOW *, int))
     19858+{
     19859+    return NCURSES_SP_NAME(_nc_ripoffline) (CURRENT_SCREEN, line, init);
     19860+}
     19861+#endif
     19862+
     19863+NCURSES_EXPORT(int)
    1722719864+NCURSES_SP_NAME(ripoffline) (NCURSES_SP_DCLx
    1722819865+                            int line,
     
    1723119868     START_TRACE();
    1723219869     T((T_CALLED("ripoffline(%d,%p)"), line, init));
    17233 @@ -645,3 +648,11 @@
    17234  
    17235      returnCode(_nc_ripoffline((line < 0) ? -1 : 1, init));
    17236  }
     19870@@ -643,5 +663,15 @@
     19871     if (line == 0)
     19872        returnCode(OK);
     19873 
     19874-    returnCode(_nc_ripoffline((line < 0) ? -1 : 1, init));
     19875+    returnCode(NCURSES_SP_NAME(_nc_ripoffline) (NCURSES_SP_ARGx
     19876+                                               (line < 0) ? -1 : 1,
     19877+                                               init));
     19878+}
    1723719879+
    1723819880+#if NCURSES_SP_FUNCS
     
    1724119883+{
    1724219884+    return NCURSES_SP_NAME(ripoffline) (CURRENT_SCREEN, line, init);
    17243 +}
     19885 }
    1724419886+#endif
    1724519887diff -Naur ncurses-5.7.orig/ncurses/base/lib_slkatrof.c ncurses-5.7/ncurses/base/lib_slkatrof.c
    1724619888--- ncurses-5.7.orig/ncurses/base/lib_slkatrof.c        2005-01-08 15:01:32.000000000 -0800
    17247 +++ ncurses-5.7/ncurses/base/lib_slkatrof.c     2009-02-28 20:38:58.439326442 -0800
     19889+++ ncurses-5.7/ncurses/base/lib_slkatrof.c     2009-06-05 14:01:16.000000000 -0700
    1724819890@@ -1,5 +1,5 @@
    1724919891 /****************************************************************************
     
    1729319935diff -Naur ncurses-5.7.orig/ncurses/base/lib_slkatron.c ncurses-5.7/ncurses/base/lib_slkatron.c
    1729419936--- ncurses-5.7.orig/ncurses/base/lib_slkatron.c        2005-01-08 15:02:01.000000000 -0800
    17295 +++ ncurses-5.7/ncurses/base/lib_slkatron.c     2009-02-28 20:38:58.439326442 -0800
     19937+++ ncurses-5.7/ncurses/base/lib_slkatron.c     2009-06-05 14:01:16.000000000 -0700
    1729619938@@ -1,5 +1,5 @@
    1729719939 /****************************************************************************
     
    1734119983diff -Naur ncurses-5.7.orig/ncurses/base/lib_slkatr_set.c ncurses-5.7/ncurses/base/lib_slkatr_set.c
    1734219984--- ncurses-5.7.orig/ncurses/base/lib_slkatr_set.c      2005-01-28 13:11:53.000000000 -0800
    17343 +++ ncurses-5.7/ncurses/base/lib_slkatr_set.c   2009-02-28 20:38:58.439326442 -0800
     19985+++ ncurses-5.7/ncurses/base/lib_slkatr_set.c   2009-06-05 14:01:16.000000000 -0700
    1734419986@@ -1,5 +1,5 @@
    1734519987 /****************************************************************************
     
    1741220054diff -Naur ncurses-5.7.orig/ncurses/base/lib_slkatrset.c ncurses-5.7/ncurses/base/lib_slkatrset.c
    1741320055--- ncurses-5.7.orig/ncurses/base/lib_slkatrset.c       2005-01-08 13:46:47.000000000 -0800
    17414 +++ ncurses-5.7/ncurses/base/lib_slkatrset.c    2009-02-28 20:38:58.439326442 -0800
     20056+++ ncurses-5.7/ncurses/base/lib_slkatrset.c    2009-06-05 14:01:16.000000000 -0700
    1741520057@@ -1,5 +1,5 @@
    1741620058 /****************************************************************************
     
    1745220094diff -Naur ncurses-5.7.orig/ncurses/base/lib_slkattr.c ncurses-5.7/ncurses/base/lib_slkattr.c
    1745320095--- ncurses-5.7.orig/ncurses/base/lib_slkattr.c 2005-01-08 13:44:28.000000000 -0800
    17454 +++ ncurses-5.7/ncurses/base/lib_slkattr.c      2009-02-28 20:38:58.439326442 -0800
     20096+++ ncurses-5.7/ncurses/base/lib_slkattr.c      2009-06-05 14:01:16.000000000 -0700
    1745520097@@ -1,5 +1,5 @@
    1745620098 /****************************************************************************
     
    1749620138diff -Naur ncurses-5.7.orig/ncurses/base/lib_slk.c ncurses-5.7/ncurses/base/lib_slk.c
    1749720139--- ncurses-5.7.orig/ncurses/base/lib_slk.c     2008-09-27 07:07:33.000000000 -0700
    17498 +++ ncurses-5.7/ncurses/base/lib_slk.c  2009-02-28 20:38:57.051235647 -0800
     20140+++ ncurses-5.7/ncurses/base/lib_slk.c  2009-06-05 14:01:51.000000000 -0700
    1749920141@@ -1,5 +1,5 @@
    1750020142 /****************************************************************************
     
    1750420146  * Permission is hereby granted, free of charge, to any person obtaining a  *
    1750520147  * copy of this software and associated documentation files (the            *
    17506 @@ -45,7 +45,7 @@
     20148@@ -45,7 +45,11 @@
    1750720149 #include <ctype.h>
    1750820150 #include <term.h>              /* num_labels, label_*, plab_norm */
    1750920151 
    1751020152-MODULE_ID("$Id: lib_slk.c,v 1.35 2008/09/27 14:07:33 juergen Exp $")
    17511 +MODULE_ID("$Id: lib_slk.c,v 1.36 2009/02/15 00:33:48 tom Exp $")
     20153+#ifndef CUR
     20154+#define CUR SP_TERMTYPE
     20155+#endif
     20156+
     20157+MODULE_ID("$Id: lib_slk.c,v 1.38 2009/05/10 00:48:29 tom Exp $")
    1751220158 
    1751320159 /*
    1751420160  * Free any memory related to soft labels, return an error.
    17515 @@ -178,14 +178,22 @@
     20161@@ -68,6 +72,9 @@
     20162 NCURSES_EXPORT(int)
     20163 _nc_slk_initialize(WINDOW *stwin, int cols)
     20164 {
     20165+#if NCURSES_SP_FUNCS
     20166+    SCREEN *sp = CURRENT_SCREEN;
     20167+#endif
     20168     int i, x;
     20169     int res = OK;
     20170     unsigned max_length;
     20171@@ -178,14 +185,22 @@
    1751620172  * Restore the soft labels on the screen.
    1751720173  */
     
    1754220198diff -Naur ncurses-5.7.orig/ncurses/base/lib_slkclear.c ncurses-5.7/ncurses/base/lib_slkclear.c
    1754320199--- ncurses-5.7.orig/ncurses/base/lib_slkclear.c        2007-12-29 09:51:47.000000000 -0800
    17544 +++ ncurses-5.7/ncurses/base/lib_slkclear.c     2009-02-28 20:38:58.439326442 -0800
     20200+++ ncurses-5.7/ncurses/base/lib_slkclear.c     2009-06-05 14:01:16.000000000 -0700
    1754520201@@ -1,5 +1,5 @@
    1754620202 /****************************************************************************
     
    1759820254diff -Naur ncurses-5.7.orig/ncurses/base/lib_slkcolor.c ncurses-5.7/ncurses/base/lib_slkcolor.c
    1759920255--- ncurses-5.7.orig/ncurses/base/lib_slkcolor.c        2005-01-28 13:11:53.000000000 -0800
    17600 +++ ncurses-5.7/ncurses/base/lib_slkcolor.c     2009-02-28 20:38:58.439326442 -0800
     20256+++ ncurses-5.7/ncurses/base/lib_slkcolor.c     2009-06-05 14:01:16.000000000 -0700
    1760120257@@ -1,5 +1,5 @@
    1760220258 /****************************************************************************
     
    1766220318diff -Naur ncurses-5.7.orig/ncurses/base/lib_slkinit.c ncurses-5.7/ncurses/base/lib_slkinit.c
    1766320319--- ncurses-5.7.orig/ncurses/base/lib_slkinit.c 2008-01-12 12:23:39.000000000 -0800
    17664 +++ ncurses-5.7/ncurses/base/lib_slkinit.c      2009-02-28 20:38:57.051235647 -0800
     20320+++ ncurses-5.7/ncurses/base/lib_slkinit.c      2009-06-05 14:01:54.000000000 -0700
    1766520321@@ -1,5 +1,5 @@
    1766620322 /****************************************************************************
     
    1767820334 
    1767920335 /*
    17680 @@ -39,10 +40,10 @@
     20336@@ -39,17 +40,40 @@
    1768120337  */
    1768220338 #include <curses.priv.h>
    1768320339 
    1768420340-MODULE_ID("$Id: lib_slkinit.c,v 1.7 2008/01/12 20:23:39 tom Exp $")
    17685 +MODULE_ID("$Id: lib_slkinit.c,v 1.8 2009/02/15 00:42:36 tom Exp $")
     20341+MODULE_ID("$Id: lib_slkinit.c,v 1.11 2009/05/23 23:32:57 tom Exp $")
     20342+
     20343+#ifdef USE_SP_RIPOFF
     20344+#define SoftkeyFormat SP_PARM->slk_format
     20345+#else
     20346+#define SoftkeyFormat _nc_globals.slk_format
     20347+#endif
    1768620348 
    1768720349 NCURSES_EXPORT(int)
     
    1769120353     int code = ERR;
    1769220354 
    17693 @@ -53,3 +54,11 @@
     20355-    T((T_CALLED("slk_init(%d)"), format));
     20356-    if (format >= 0 && format <= 3 && !_nc_globals.slk_format) {
     20357-       _nc_globals.slk_format = 1 + format;
     20358-       code = _nc_ripoffline(-SLK_LINES(_nc_globals.slk_format), _nc_slk_initialize);
     20359+    T((T_CALLED("slk_init(%p,%d)"), SP_PARM, format));
     20360+
     20361+    if (format >= 0
     20362+       && format <= 3
     20363+#ifdef USE_SP_RIPOFF
     20364+       && SP_PARM
     20365+       && SP_PARM->_prescreen
     20366+#endif
     20367+       && !SoftkeyFormat) {
     20368+       SoftkeyFormat = 1 + format;
     20369+       code = NCURSES_SP_NAME(_nc_ripoffline) (NCURSES_SP_ARGx
     20370+                                               -SLK_LINES(SoftkeyFormat),
     20371+                                               _nc_slk_initialize);
    1769420372     }
    1769520373     returnCode(code);
     
    1770020378+slk_init(int format)
    1770120379+{
    17702 +    return NCURSES_SP_NAME(slk_init) (CURRENT_SCREEN, format);
     20380+    return NCURSES_SP_NAME(slk_init) (CURRENT_SCREEN_PRE, format);
    1770320381+}
    1770420382+#endif
    1770520383diff -Naur ncurses-5.7.orig/ncurses/base/lib_slklab.c ncurses-5.7/ncurses/base/lib_slklab.c
    1770620384--- ncurses-5.7.orig/ncurses/base/lib_slklab.c  2003-03-29 14:53:48.000000000 -0800
    17707 +++ ncurses-5.7/ncurses/base/lib_slklab.c       2009-02-28 20:38:58.439326442 -0800
     20385+++ ncurses-5.7/ncurses/base/lib_slklab.c       2009-06-05 14:01:16.000000000 -0700
    1770820386@@ -1,5 +1,5 @@
    1770920387 /****************************************************************************
     
    1775220430diff -Naur ncurses-5.7.orig/ncurses/base/lib_slkrefr.c ncurses-5.7/ncurses/base/lib_slkrefr.c
    1775320431--- ncurses-5.7.orig/ncurses/base/lib_slkrefr.c 2008-09-27 07:07:53.000000000 -0700
    17754 +++ ncurses-5.7/ncurses/base/lib_slkrefr.c      2009-02-28 20:38:57.051235647 -0800
     20432+++ ncurses-5.7/ncurses/base/lib_slkrefr.c      2009-06-05 14:01:51.000000000 -0700
    1775520433@@ -1,5 +1,5 @@
    1775620434 /****************************************************************************
     
    1776020438  * Permission is hereby granted, free of charge, to any person obtaining a  *
    1776120439  * copy of this software and associated documentation files (the            *
    17762 @@ -40,7 +40,7 @@
     20440@@ -40,7 +40,11 @@
    1776320441 #include <curses.priv.h>
    1776420442 #include <term.h>              /* num_labels, label_*, plab_norm */
    1776520443 
    1776620444-MODULE_ID("$Id: lib_slkrefr.c,v 1.17 2008/09/27 14:07:53 juergen Exp $")
    17767 +MODULE_ID("$Id: lib_slkrefr.c,v 1.18 2009/02/15 00:33:48 tom Exp $")
     20445+#ifndef CUR
     20446+#define CUR SP_TERMTYPE
     20447+#endif
     20448+
     20449+MODULE_ID("$Id: lib_slkrefr.c,v 1.20 2009/05/10 00:48:29 tom Exp $")
    1776820450 
    1776920451 /*
    1777020452  * Paint the info line for the PC style SLK emulation.
    17771 @@ -113,32 +113,48 @@
     20453@@ -68,6 +72,9 @@
     20454 static void
     20455 slk_intern_refresh(SLK * slk)
     20456 {
     20457+#if NCURSES_SP_FUNCS
     20458+    SCREEN *sp = CURRENT_SCREEN;
     20459+#endif
     20460     int i;
     20461     int fmt = SP->slk_format;
     20462 
     20463@@ -113,32 +120,48 @@
    1777220464  * Refresh the soft labels.
    1777320465  */
     
    1783020522diff -Naur ncurses-5.7.orig/ncurses/base/lib_slkset.c ncurses-5.7/ncurses/base/lib_slkset.c
    1783120523--- ncurses-5.7.orig/ncurses/base/lib_slkset.c  2007-10-13 13:08:46.000000000 -0700
    17832 +++ ncurses-5.7/ncurses/base/lib_slkset.c       2009-02-28 20:38:58.439326442 -0800
     20524+++ ncurses-5.7/ncurses/base/lib_slkset.c       2009-06-05 14:01:16.000000000 -0700
    1783320525@@ -1,5 +1,5 @@
    1783420526 /****************************************************************************
     
    1789120583diff -Naur ncurses-5.7.orig/ncurses/base/lib_slktouch.c ncurses-5.7/ncurses/base/lib_slktouch.c
    1789220584--- ncurses-5.7.orig/ncurses/base/lib_slktouch.c        2000-12-09 18:43:27.000000000 -0800
    17893 +++ ncurses-5.7/ncurses/base/lib_slktouch.c     2009-02-28 20:38:58.439326442 -0800
     20585+++ ncurses-5.7/ncurses/base/lib_slktouch.c     2009-06-05 14:01:16.000000000 -0700
    1789420586@@ -1,5 +1,5 @@
    1789520587 /****************************************************************************
     
    1794220634diff -Naur ncurses-5.7.orig/ncurses/base/lib_ungetch.c ncurses-5.7/ncurses/base/lib_ungetch.c
    1794320635--- ncurses-5.7.orig/ncurses/base/lib_ungetch.c 2008-05-31 09:44:54.000000000 -0700
    17944 +++ ncurses-5.7/ncurses/base/lib_ungetch.c      2009-02-28 20:38:57.055236206 -0800
     20636+++ ncurses-5.7/ncurses/base/lib_ungetch.c      2009-06-05 14:01:44.000000000 -0700
    1794520637@@ -1,5 +1,5 @@
    1794620638 /****************************************************************************
     
    1796320655 
    1796420656-MODULE_ID("$Id: lib_ungetch.c,v 1.11 2008/05/31 16:44:54 tom Exp $")
    17965 +MODULE_ID("$Id: lib_ungetch.c,v 1.12 2009/02/15 00:46:58 tom Exp $")
     20657+MODULE_ID("$Id: lib_ungetch.c,v 1.13 2009/04/18 20:30:12 tom Exp $")
    1796620658 
    1796720659 #include <fifo_defs.h>
    1796820660 
    17969 @@ -83,8 +84,16 @@
     20661@@ -57,10 +58,12 @@
     20662 #endif /* TRACE */
     20663 
     20664 NCURSES_EXPORT(int)
     20665-_nc_ungetch(SCREEN *sp, int ch)
     20666+safe_ungetch(SCREEN *sp, int ch)
     20667 {
     20668     int rc = ERR;
     20669 
     20670+    T((T_CALLED("ungetch(%p,%s)"), sp, _nc_tracechar(sp, ch)));
     20671+
     20672     if (tail != -1) {
     20673        if (head == -1) {
     20674            head = 0;
     20675@@ -79,12 +82,11 @@
     20676 #endif
     20677        rc = OK;
     20678     }
     20679-    return rc;
     20680+    returnCode(rc);
    1797020681 }
    1797120682 
    1797220683 NCURSES_EXPORT(int)
    17973 +NCURSES_SP_NAME(ungetch) (NCURSES_SP_DCLx int ch)
    17974 +{
    17975 +    T((T_CALLED("ungetch(%s)"), _nc_tracechar(SP_PARM, ch)));
    17976 +    returnCode(_nc_ungetch(SP_PARM, ch));
    17977 +}
    17978 +
    17979 +#if NCURSES_SP_FUNCS
    17980 +NCURSES_EXPORT(int)
    1798120684 ungetch(int ch)
    1798220685 {
    1798320686-    T((T_CALLED("ungetch(%s)"), _nc_tracechar(SP, ch)));
    1798420687-    returnCode(_nc_ungetch(SP, ch));
    17985 +    return NCURSES_SP_NAME(ungetch) (CURRENT_SCREEN, ch);
     20688+    return safe_ungetch(CURRENT_SCREEN, ch);
    1798620689 }
    17987 +#endif
    1798820690diff -Naur ncurses-5.7.orig/ncurses/base/lib_winch.c ncurses-5.7/ncurses/base/lib_winch.c
    1798920691--- ncurses-5.7.orig/ncurses/base/lib_winch.c   2001-06-02 16:42:08.000000000 -0700
    17990 +++ ncurses-5.7/ncurses/base/lib_winch.c        2009-02-28 20:38:58.439326442 -0800
     20692+++ ncurses-5.7/ncurses/base/lib_winch.c        2009-06-05 14:01:16.000000000 -0700
    1799120693@@ -39,16 +39,16 @@
    1799220694 
     
    1801020712     }
    1801120713 }
     20714diff -Naur ncurses-5.7.orig/ncurses/base/lib_window.c ncurses-5.7/ncurses/base/lib_window.c
     20715--- ncurses-5.7.orig/ncurses/base/lib_window.c  2008-06-07 07:12:56.000000000 -0700
     20716+++ ncurses-5.7/ncurses/base/lib_window.c       2009-06-05 14:01:44.000000000 -0700
     20717@@ -1,5 +1,5 @@
     20718 /****************************************************************************
     20719- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     20720+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     20721  *                                                                          *
     20722  * Permission is hereby granted, free of charge, to any person obtaining a  *
     20723  * copy of this software and associated documentation files (the            *
     20724@@ -39,7 +39,7 @@
     20725 
     20726 #include <curses.priv.h>
     20727 
     20728-MODULE_ID("$Id: lib_window.c,v 1.25 2008/06/07 14:12:56 tom Exp $")
     20729+MODULE_ID("$Id: lib_window.c,v 1.26 2009/04/18 18:46:09 tom Exp $")
     20730 
     20731 NCURSES_EXPORT(void)
     20732 _nc_synchook(WINDOW *win)
     20733@@ -185,16 +185,20 @@
     20734     T((T_CALLED("dupwin(%p)"), win));
     20735 
     20736     if (win != 0) {
     20737-
     20738+#if NCURSES_SP_FUNCS
     20739+       SCREEN *sp = _nc_screen_of(win);
     20740+#endif
     20741        _nc_lock_global(curses);
     20742        if (win->_flags & _ISPAD) {
     20743-           nwin = newpad(win->_maxy + 1,
     20744-                         win->_maxx + 1);
     20745+           nwin = NCURSES_SP_NAME(newpad) (NCURSES_SP_ARGx
     20746+                                           win->_maxy + 1,
     20747+                                           win->_maxx + 1);
     20748        } else {
     20749-           nwin = newwin(win->_maxy + 1,
     20750-                         win->_maxx + 1,
     20751-                         win->_begy,
     20752-                         win->_begx);
     20753+           nwin = NCURSES_SP_NAME(newwin) (NCURSES_SP_ARGx
     20754+                                           win->_maxy + 1,
     20755+                                           win->_maxx + 1,
     20756+                                           win->_begy,
     20757+                                           win->_begx);
     20758        }
     20759 
     20760        if (nwin != 0) {
    1801220761diff -Naur ncurses-5.7.orig/ncurses/base/MKkeyname.awk ncurses-5.7/ncurses/base/MKkeyname.awk
    1801320762--- ncurses-5.7.orig/ncurses/base/MKkeyname.awk 2008-07-12 11:40:00.000000000 -0700
    18014 +++ ncurses-5.7/ncurses/base/MKkeyname.awk      2009-02-28 20:38:57.043235088 -0800
     20763+++ ncurses-5.7/ncurses/base/MKkeyname.awk      2009-06-05 14:01:51.000000000 -0700
    1801520764@@ -1,6 +1,6 @@
    1801620765-# $Id: MKkeyname.awk,v 1.40 2008/07/12 18:40:00 tom Exp $
    18017 +# $Id: MKkeyname.awk,v 1.41 2009/02/15 00:24:58 tom Exp $
     20766+# $Id: MKkeyname.awk,v 1.43 2009/05/09 19:01:49 tom Exp $
    1801820767 ##############################################################################
    1801920768-# Copyright (c) 1999-2007,2008 Free Software Foundation, Inc.                #
     
    1802220771 # Permission is hereby granted, free of charge, to any person obtaining a    #
    1802320772 # copy of this software and associated documentation files (the "Software"), #
    18024 @@ -141,11 +141,20 @@
     20773@@ -67,7 +67,8 @@
     20774        print "#define SIZEOF_TABLE 256"
     20775        print "#define MyTable _nc_globals.keyname_table"
     20776        print ""
     20777-       print "NCURSES_EXPORT(NCURSES_CONST char *) _nc_keyname (SCREEN *sp, int c)"
     20778+       print "NCURSES_EXPORT(NCURSES_CONST char *)"
     20779+       print "safe_keyname (SCREEN *sp, int c)"
     20780        print "{"
     20781        print " int i;"
     20782        print " char name[20];"
     20783@@ -116,14 +117,14 @@
     20784        print "                         result = MyTable[c];"
     20785        print "                 }"
     20786        print "#if NCURSES_EXT_FUNCS && NCURSES_XNAMES"
     20787-       print "         } else if (result == 0 && cur_term != 0) {"
     20788+       print "         } else if (result == 0 && HasTerminal(sp)) {"
     20789        print "                 int j, k;"
     20790        print "                 char * bound;"
     20791-       print "                 TERMTYPE *tp = &(cur_term->type);"
     20792+       print "                 TERMTYPE *tp = &(TerminalOf(sp)->type);"
     20793        print "                 int save_trace = _nc_tracing;"
     20794        print ""
     20795        print "                 _nc_tracing = 0;        /* prevent recursion via keybound() */"
     20796-       print "                 for (j = 0; (bound = keybound(c, j)) != 0; ++j) {"
     20797+       print "                 for (j = 0; (bound = NCURSES_SP_NAME(keybound)(NCURSES_SP_ARGx c, j)) != 0; ++j) {"
     20798        print "                         for(k = STRCOUNT; k < (int) NUM_STRINGS(tp);  k++) {"
     20799        print "                                 if (tp->Strings[k] != 0 && !strcmp(bound, tp->Strings[k])) {"
     20800        print "                                         result = ExtStrname(tp, k, strnames);"
     20801@@ -141,9 +142,10 @@
    1802520802        print " return result;"
    1802620803        print "}"
     
    1802820805-       print "NCURSES_EXPORT(NCURSES_CONST char *) keyname (int c)"
    1802920806+       print "NCURSES_EXPORT(NCURSES_CONST char *)"
    18030 +       print "NCURSES_SP_NAME(keyname) (NCURSES_SP_DCLx int c)"
     20807+       print "keyname (int c)"
    1803120808        print "{"
    1803220809-       print "\treturn _nc_keyname(SP, c);"
    18033 +       print "\treturn _nc_keyname(SP_PARM, c);"
     20810+       print " return safe_keyname (CURRENT_SCREEN, c);"
    1803420811        print "}"
    1803520812        print ""
    18036 +       print "#if NCURSES_SP_FUNCS"
    18037 +       print "NCURSES_EXPORT(NCURSES_CONST char *)"
    18038 +       print "keyname (int c)"
    18039 +       print "{"
    18040 +       print " return NCURSES_SP_NAME(keyname) (CURRENT_SCREEN, c);"
    18041 +       print "}"
    18042 +       print "#endif"
    18043 +       print ""
    1804420813        print "#if NO_LEAKS"
    18045         print "void _nc_keyname_leaks(void)"
    18046         print "{"
    1804720814diff -Naur ncurses-5.7.orig/ncurses/base/MKlib_gen.sh ncurses-5.7/ncurses/base/MKlib_gen.sh
    1804820815--- ncurses-5.7.orig/ncurses/base/MKlib_gen.sh  2008-08-30 12:20:50.000000000 -0700
    18049 +++ ncurses-5.7/ncurses/base/MKlib_gen.sh       2009-02-28 20:38:58.435326721 -0800
     20816+++ ncurses-5.7/ncurses/base/MKlib_gen.sh       2009-06-05 14:01:16.000000000 -0700
    1805020817@@ -2,7 +2,7 @@
    1805120818 #
     
    1806620833                returnType = "SP";
    1806720834        } else if ( $first == "WINDOW" ) {
     20835diff -Naur ncurses-5.7.orig/ncurses/base/MKunctrl.awk ncurses-5.7/ncurses/base/MKunctrl.awk
     20836--- ncurses-5.7.orig/ncurses/base/MKunctrl.awk  2008-10-04 14:40:24.000000000 -0700
     20837+++ ncurses-5.7/ncurses/base/MKunctrl.awk       2009-06-05 14:01:44.000000000 -0700
     20838@@ -1,6 +1,6 @@
     20839-# $Id: MKunctrl.awk,v 1.23 2008/10/04 21:40:24 tom Exp $
     20840+# $Id: MKunctrl.awk,v 1.25 2009/04/18 23:43:49 tom Exp $
     20841 ##############################################################################
     20842-# Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.                #
     20843+# Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.                #
     20844 #                                                                            #
     20845 # Permission is hereby granted, free of charge, to any person obtaining a    #
     20846 # copy of this software and associated documentation files (the "Software"), #
     20847@@ -46,9 +46,8 @@
     20848                print ""
     20849        }
     20850 END    {
     20851-               print "NCURSES_EXPORT(NCURSES_CONST char *) _nc_unctrl (SCREEN *sp, chtype ch)"
     20852+               print "NCURSES_EXPORT(NCURSES_CONST char *) safe_unctrl(SCREEN *sp, chtype ch)"
     20853                print "{"
     20854-
     20855                blob=""
     20856                offset=0
     20857                if (bigstrings) {
     20858@@ -187,6 +186,6 @@
     20859                print  ""
     20860                print  "NCURSES_EXPORT(NCURSES_CONST char *) unctrl (chtype ch)"
     20861                print  "{"
     20862-               print  "\treturn _nc_unctrl(SP, ch);"
     20863+               print  "\treturn safe_unctrl(CURRENT_SCREEN, ch);"
     20864                print  "}"
     20865        }
     20866diff -Naur ncurses-5.7.orig/ncurses/base/nc_panel.c ncurses-5.7/ncurses/base/nc_panel.c
     20867--- ncurses-5.7.orig/ncurses/base/nc_panel.c    2000-12-09 18:43:28.000000000 -0800
     20868+++ ncurses-5.7/ncurses/base/nc_panel.c 2009-06-05 14:01:33.000000000 -0700
     20869@@ -1,5 +1,5 @@
     20870 /****************************************************************************
     20871- * Copyright (c) 1998,2000 Free Software Foundation, Inc.                   *
     20872+ * Copyright (c) 1998-2000,2009 Free Software Foundation, Inc.              *
     20873  *                                                                          *
     20874  * Permission is hereby granted, free of charge, to any person obtaining a  *
     20875  * copy of this software and associated documentation files (the            *
     20876@@ -32,10 +32,22 @@
     20877 
     20878 #include <curses.priv.h>
     20879 
     20880-MODULE_ID("$Id: nc_panel.c,v 1.4 2000/12/10 02:43:28 tom Exp $")
     20881+MODULE_ID("$Id: nc_panel.c,v 1.5 2009/04/11 21:05:10 tom Exp $")
     20882 
     20883 NCURSES_EXPORT(struct panelhook *)
     20884+NCURSES_SP_NAME(_nc_panelhook) (NCURSES_SP_DCL0)
     20885+{
     20886+    return (SP_PARM
     20887+           ? &(SP_PARM->_panelHook)
     20888+           : (CURRENT_SCREEN
     20889+              ? &(CURRENT_SCREEN->_panelHook)
     20890+              : 0));
     20891+}
     20892+
     20893+#if NCURSES_SP_FUNCS
     20894+NCURSES_EXPORT(struct panelhook *)
     20895 _nc_panelhook(void)
     20896 {
     20897-    return (SP ? &(SP->_panelHook) : NULL);
     20898+    return NCURSES_SP_NAME(_nc_panelhook) (CURRENT_SCREEN);
     20899 }
     20900+#endif
     20901diff -Naur ncurses-5.7.orig/ncurses/base/resizeterm.c ncurses-5.7/ncurses/base/resizeterm.c
     20902--- ncurses-5.7.orig/ncurses/base/resizeterm.c  2008-06-07 06:58:40.000000000 -0700
     20903+++ ncurses-5.7/ncurses/base/resizeterm.c       2009-06-05 14:01:51.000000000 -0700
     20904@@ -1,5 +1,5 @@
     20905 /****************************************************************************
     20906- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     20907+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     20908  *                                                                          *
     20909  * Permission is hereby granted, free of charge, to any person obtaining a  *
     20910  * copy of this software and associated documentation files (the            *
     20911@@ -41,7 +41,11 @@
     20912 #include <curses.priv.h>
     20913 #include <term.h>
     20914 
     20915-MODULE_ID("$Id: resizeterm.c,v 1.34 2008/06/07 13:58:40 tom Exp $")
     20916+#ifndef CUR
     20917+#define CUR SP_TERMTYPE
     20918+#endif
     20919+
     20920+MODULE_ID("$Id: resizeterm.c,v 1.39 2009/05/10 00:48:29 tom Exp $")
     20921 
     20922 #define stolen_lines (screen_lines - SP->_lines_avail)
     20923 
     20924@@ -64,18 +68,23 @@
     20925 static void
     20926 show_window_sizes(const char *name)
     20927 {
     20928+    SCREEN *sp;
     20929     WINDOWLIST *wp;
     20930 
     20931     _nc_lock_global(curses);
     20932-    _tracef("%s resizing: %2d x %2d (%2d x %2d)", name, LINES, COLS,
     20933-           screen_lines, screen_columns);
     20934-    for (each_window(wp)) {
     20935-       _tracef("  window %p is %2ld x %2ld at %2ld,%2ld",
     20936-               &(wp->win),
     20937-               (long) wp->win._maxy + 1,
     20938-               (long) wp->win._maxx + 1,
     20939-               (long) wp->win._begy,
     20940-               (long) wp->win._begx);
     20941+    for (each_screen(sp)) {
     20942+       _tracef("%s resizing: %p: %2d x %2d (%2d x %2d)", name, sp,
     20943+               *(ptrLines(sp)),
     20944+               *(ptrCols(sp)),
     20945+               screen_lines(sp), screen_columns(sp));
     20946+       for (each_window(sp, wp)) {
     20947+           _tracef("  window %p is %2ld x %2ld at %2ld,%2ld",
     20948+                   &(wp->win),
     20949+                   (long) wp->win._maxy + 1,
     20950+                   (long) wp->win._maxx + 1,
     20951+                   (long) wp->win._begy,
     20952+                   (long) wp->win._begx);
     20953+       }
     20954     }
     20955     _nc_unlock_global(curses);
     20956 }
     20957@@ -86,15 +95,23 @@
     20958  * structure's size.
     20959  */
     20960 NCURSES_EXPORT(bool)
     20961-is_term_resized(int ToLines, int ToCols)
     20962+NCURSES_SP_NAME(is_term_resized) (NCURSES_SP_DCLx int ToLines, int ToCols)
     20963 {
     20964-    T((T_CALLED("is_term_resized(%d, %d)"), ToLines, ToCols));
     20965+    T((T_CALLED("is_term_resized(%p, %d, %d)"), SP_PARM, ToLines, ToCols));
     20966     returnCode(ToLines > 0
     20967               && ToCols > 0
     20968-              && (ToLines != screen_lines
     20969-                  || ToCols != screen_columns));
     20970+              && (ToLines != screen_lines(SP_PARM)
     20971+                  || ToCols != screen_columns(SP_PARM)));
     20972 }
     20973 
     20974+#if NCURSES_SP_FUNCS
     20975+NCURSES_EXPORT(bool)
     20976+is_term_resized(int ToLines, int ToCols)
     20977+{
     20978+    return NCURSES_SP_NAME(is_term_resized) (CURRENT_SCREEN, ToLines, ToCols);
     20979+}
     20980+#endif
     20981+
     20982 /*
     20983  */
     20984 static ripoff_t *
     20985@@ -104,6 +121,9 @@
     20986     ripoff_t *rop;
     20987 
     20988     if (win != 0) {
     20989+#if NCURSES_SP_FUNCS
     20990+       SCREEN *sp = _nc_screen_of(win);
     20991+#endif
     20992        for (each_ripoff(rop)) {
     20993            if (rop->win == win && rop->line != 0) {
     20994                result = rop;
     20995@@ -125,6 +145,9 @@
     20996     ripoff_t *rop;
     20997 
     20998     if (win != 0) {
     20999+#if NCURSES_SP_FUNCS
     21000+       SCREEN *sp = _nc_screen_of(win);
     21001+#endif
     21002        for (each_ripoff(rop)) {
     21003            if (rop->line < 0) {
     21004                result -= rop->line;
     21005@@ -146,9 +169,12 @@
     21006     int depth = 0;
     21007 
     21008     if (cmp != 0) {
     21009+#if NCURSES_SP_FUNCS
     21010+       SCREEN *sp = _nc_screen_of(cmp);
     21011+#endif
     21012        WINDOWLIST *wp;
     21013 
     21014-       for (each_window(wp)) {
     21015+       for (each_window(sp, wp)) {
     21016            WINDOW *tst = &(wp->win);
     21017            if (tst->_parent == cmp) {
     21018                depth = 1 + child_depth(tst);
     21019@@ -184,7 +210,7 @@
     21020 adjust_window(WINDOW *win, int ToLines, int ToCols, int stolen EXTRA_DCLS)
     21021 {
     21022     int result;
     21023-    int bottom = CurLines + SP->_topstolen - stolen;
     21024+    int bottom = CurLines + _nc_screen_of(win)->_topstolen - stolen;
     21025     int myLines = win->_maxy + 1;
     21026     int myCols = win->_maxx + 1;
     21027     ripoff_t *rop = ripped_window(win);
     21028@@ -239,19 +265,19 @@
     21029  * children, decrease those to fit, then decrease the containing window, etc.
     21030  */
     21031 static int
     21032-decrease_size(int ToLines, int ToCols, int stolen EXTRA_DCLS)
     21033+decrease_size(NCURSES_SP_DCLx int ToLines, int ToCols, int stolen EXTRA_DCLS)
     21034 {
     21035     bool found;
     21036     int depth = 0;
     21037     WINDOWLIST *wp;
     21038 
     21039-    T((T_CALLED("decrease_size(%d, %d)"), ToLines, ToCols));
     21040+    T((T_CALLED("decrease_size(%p, %d, %d)"), SP_PARM, ToLines, ToCols));
     21041 
     21042     do {
     21043        found = FALSE;
     21044        TR(TRACE_UPDATE, ("decreasing size of windows to %dx%d, depth=%d",
     21045                          ToLines, ToCols, depth));
     21046-       for (each_window(wp)) {
     21047+       for (each_window(SP_PARM, wp)) {
     21048            WINDOW *win = &(wp->win);
     21049 
     21050            if (!(win->_flags & _ISPAD)) {
     21051@@ -273,19 +299,19 @@
     21052  * parent, increase those to fit, then increase the contained window, etc.
     21053  */
     21054 static int
     21055-increase_size(int ToLines, int ToCols, int stolen EXTRA_DCLS)
     21056+increase_size(NCURSES_SP_DCLx int ToLines, int ToCols, int stolen EXTRA_DCLS)
     21057 {
     21058     bool found;
     21059     int depth = 0;
     21060     WINDOWLIST *wp;
     21061 
     21062-    T((T_CALLED("increase_size(%d, %d)"), ToLines, ToCols));
     21063+    T((T_CALLED("increase_size(%p, %d, %d)"), SP_PARM, ToLines, ToCols));
     21064 
     21065     do {
     21066        found = FALSE;
     21067        TR(TRACE_UPDATE, ("increasing size of windows to %dx%d, depth=%d",
     21068                          ToLines, ToCols, depth));
     21069-       for (each_window(wp)) {
     21070+       for (each_window(SP_PARM, wp)) {
     21071            WINDOW *win = &(wp->win);
     21072 
     21073            if (!(win->_flags & _ISPAD)) {
     21074@@ -307,25 +333,26 @@
     21075  * such as ungetch().
     21076  */
     21077 NCURSES_EXPORT(int)
     21078-resize_term(int ToLines, int ToCols)
     21079+NCURSES_SP_NAME(resize_term) (NCURSES_SP_DCLx int ToLines, int ToCols)
     21080 {
     21081     int result = OK EXTRA_ARGS;
     21082     int was_stolen;
     21083 
     21084-    T((T_CALLED("resize_term(%d,%d) old(%d,%d)"),
     21085-       ToLines, ToCols,
     21086-       screen_lines, screen_columns));
     21087+    T((T_CALLED("resize_term(%p,%d,%d) old(%d,%d)"),
     21088+       SP_PARM, ToLines, ToCols,
     21089+       SP_PARM == 0 ? -1 : screen_lines(SP_PARM),
     21090+       SP_PARM == 0 ? -1 : screen_columns(SP_PARM)));
     21091 
     21092-    if (SP == 0) {
     21093+    if (SP_PARM == 0) {
     21094        returnCode(ERR);
     21095     }
     21096 
     21097     _nc_lock_global(curses);
     21098 
     21099-    was_stolen = (screen_lines - SP->_lines_avail);
     21100-    if (is_term_resized(ToLines, ToCols)) {
     21101-       int myLines = CurLines = screen_lines;
     21102-       int myCols = CurCols = screen_columns;
     21103+    was_stolen = (screen_lines(SP_PARM) - SP_PARM->_lines_avail);
     21104+    if (NCURSES_SP_NAME(is_term_resized) (NCURSES_SP_ARGx ToLines, ToCols)) {
     21105+       int myLines = CurLines = screen_lines(SP_PARM);
     21106+       int myCols = CurCols = screen_columns(SP_PARM);
     21107 
     21108 #ifdef TRACE
     21109        if (USE_TRACEF(TRACE_UPDATE)) {
     21110@@ -333,33 +360,35 @@
     21111            _nc_unlock_global(tracef);
     21112        }
     21113 #endif
     21114-       if (ToLines > screen_lines) {
     21115-           increase_size(myLines = ToLines, myCols, was_stolen EXTRA_ARGS);
     21116+       if (ToLines > screen_lines(SP_PARM)) {
     21117+           increase_size(NCURSES_SP_ARGx
     21118+                         myLines = ToLines, myCols, was_stolen EXTRA_ARGS);
     21119            CurLines = myLines;
     21120            CurCols = myCols;
     21121        }
     21122 
     21123-       if (ToCols > screen_columns) {
     21124-           increase_size(myLines, myCols = ToCols, was_stolen EXTRA_ARGS);
     21125+       if (ToCols > screen_columns(SP_PARM)) {
     21126+           increase_size(NCURSES_SP_ARGx
     21127+                         myLines, myCols = ToCols, was_stolen EXTRA_ARGS);
     21128            CurLines = myLines;
     21129            CurCols = myCols;
     21130        }
     21131 
     21132        if (ToLines < myLines ||
     21133            ToCols < myCols) {
     21134-           decrease_size(ToLines, ToCols, was_stolen EXTRA_ARGS);
     21135+           decrease_size(NCURSES_SP_ARGx ToLines, ToCols, was_stolen EXTRA_ARGS);
     21136        }
     21137 
     21138-       screen_lines = lines = ToLines;
     21139-       screen_columns = columns = ToCols;
     21140+       screen_lines(SP_PARM) = lines = ToLines;
     21141+       screen_columns(SP_PARM) = columns = ToCols;
     21142 
     21143-       SP->_lines_avail = lines - was_stolen;
     21144+       SP_PARM->_lines_avail = lines - was_stolen;
     21145 
     21146-       if (SP->oldhash) {
     21147-           FreeAndNull(SP->oldhash);
     21148+       if (SP_PARM->oldhash) {
     21149+           FreeAndNull(SP_PARM->oldhash);
     21150        }
     21151-       if (SP->newhash) {
     21152-           FreeAndNull(SP->newhash);
     21153+       if (SP_PARM->newhash) {
     21154+           FreeAndNull(SP_PARM->newhash);
     21155        }
     21156 #ifdef TRACE
     21157        if (USE_TRACEF(TRACE_UPDATE)) {
     21158@@ -383,6 +412,18 @@
     21159     returnCode(result);
     21160 }
     21161 
     21162+#if NCURSES_SP_FUNCS
     21163+NCURSES_EXPORT(int)
     21164+resize_term(int ToLines, int ToCols)
     21165+{
     21166+    int res = ERR;
     21167+    _nc_lock_global(curses);
     21168+    res = NCURSES_SP_NAME(resize_term) (CURRENT_SCREEN, ToLines, ToCols);
     21169+    _nc_unlock_global(curses);
     21170+    return (res);
     21171+}
     21172+#endif
     21173+
     21174 /*
     21175  * This function reallocates NCURSES window structures.  It is invoked in
     21176  * response to a SIGWINCH interrupt.  Other user-defined windows may also need
     21177@@ -392,34 +433,34 @@
     21178  * invoked directly from the signal handler.
     21179  */
     21180 NCURSES_EXPORT(int)
     21181-resizeterm(int ToLines, int ToCols)
     21182+NCURSES_SP_NAME(resizeterm) (NCURSES_SP_DCLx int ToLines, int ToCols)
     21183 {
     21184     int result = ERR;
     21185 
     21186-    T((T_CALLED("resizeterm(%d,%d) old(%d,%d)"),
     21187-       ToLines, ToCols,
     21188-       screen_lines, screen_columns));
     21189+    T((T_CALLED("resizeterm(%p, %d,%d) old(%d,%d)"),
     21190+       SP_PARM, ToLines, ToCols,
     21191+       SP_PARM == 0 ? -1 : screen_lines(SP_PARM), screen_columns(SP_PARM)));
     21192 
     21193-    if (SP != 0) {
     21194+    if (SP_PARM != 0) {
     21195        result = OK;
     21196-       SP->_sig_winch = FALSE;
     21197+       SP_PARM->_sig_winch = FALSE;
     21198 
     21199-       if (is_term_resized(ToLines, ToCols)) {
     21200+       if (NCURSES_SP_NAME(is_term_resized) (NCURSES_SP_ARGx ToLines, ToCols)) {
     21201 #if USE_SIGWINCH
     21202            ripoff_t *rop;
     21203-           bool slk_visible = (SP != 0
     21204-                               && SP->_slk != 0
     21205-                               && !(SP->_slk->hidden));
     21206+           bool slk_visible = (SP_PARM != 0
     21207+                               && SP_PARM->_slk != 0
     21208+                               && !(SP_PARM->_slk->hidden));
     21209 
     21210            if (slk_visible) {
     21211                slk_clear();
     21212            }
     21213 #endif
     21214-           result = resize_term(ToLines, ToCols);
     21215+           result = NCURSES_SP_NAME(resize_term) (NCURSES_SP_ARGx ToLines, ToCols);
     21216 
     21217 #if USE_SIGWINCH
     21218-           _nc_ungetch(SP, KEY_RESIZE);        /* so application can know this */
     21219-           clearok(curscr, TRUE);      /* screen contents are unknown */
     21220+           safe_ungetch(SP_PARM, KEY_RESIZE);  /* so application can know this */
     21221+           clearok(CurScreen(SP_PARM), TRUE);  /* screen contents are unknown */
     21222 
     21223            /* ripped-off lines are a special case: if we did not lengthen
     21224             * them, we haven't moved them either.  repaint them, too.
     21225@@ -429,7 +470,7 @@
     21226             * not know which are really on top.
     21227             */
     21228            for (each_ripoff(rop)) {
     21229-               if (rop->win != stdscr
     21230+               if (rop->win != StdScreen(SP_PARM)
     21231                    && rop->win != 0
     21232                    && rop->line < 0) {
     21233 
     21234@@ -442,10 +483,9 @@
     21235 
     21236            /* soft-keys are a special case: we _know_ how to repaint them */
     21237            if (slk_visible) {
     21238-               slk_restore();
     21239-               slk_touch();
     21240-
     21241-               slk_refresh();
     21242+               NCURSES_SP_NAME(slk_restore) (NCURSES_SP_ARG);
     21243+               NCURSES_SP_NAME(slk_touch) (NCURSES_SP_ARG);
     21244+               NCURSES_SP_NAME(slk_refresh) (NCURSES_SP_ARG);
     21245            }
     21246 #endif
     21247        }
     21248@@ -453,3 +493,11 @@
     21249 
     21250     returnCode(result);
     21251 }
     21252+
     21253+#if NCURSES_SP_FUNCS
     21254+NCURSES_EXPORT(int)
     21255+resizeterm(int ToLines, int ToCols)
     21256+{
     21257+    return NCURSES_SP_NAME(resizeterm) (CURRENT_SCREEN, ToLines, ToCols);
     21258+}
     21259+#endif
     21260diff -Naur ncurses-5.7.orig/ncurses/base/safe_sprintf.c ncurses-5.7/ncurses/base/safe_sprintf.c
     21261--- ncurses-5.7.orig/ncurses/base/safe_sprintf.c        2007-04-21 15:28:06.000000000 -0700
     21262+++ ncurses-5.7/ncurses/base/safe_sprintf.c     2009-06-05 14:01:44.000000000 -0700
     21263@@ -1,5 +1,5 @@
     21264 /****************************************************************************
     21265- * Copyright (c) 1998-2003,2007 Free Software Foundation, Inc.              *
     21266+ * Copyright (c) 1998-2007,2009 Free Software Foundation, Inc.              *
     21267  *                                                                          *
     21268  * Permission is hereby granted, free of charge, to any person obtaining a  *
     21269  * copy of this software and associated documentation files (the            *
     21270@@ -33,7 +33,7 @@
     21271 #include <curses.priv.h>
     21272 #include <ctype.h>
     21273 
     21274-MODULE_ID("$Id: safe_sprintf.c,v 1.20 2007/04/21 22:28:06 tom Exp $")
     21275+MODULE_ID("$Id: safe_sprintf.c,v 1.22 2009/04/18 18:46:46 tom Exp $")
     21276 
     21277 #if USE_SAFE_SPRINTF
     21278 
     21279@@ -111,7 +111,7 @@
     21280                    }
     21281                    sprintf(fmt_arg, "%d", ival);
     21282                    fmt_len += strlen(fmt_arg);
     21283-                   if ((format = realloc(format, fmt_len)) == 0) {
     21284+                   if ((format = _nc_doalloc(format, fmt_len)) == 0) {
     21285                        return -1;
     21286                    }
     21287                    strcpy(&format[--f], fmt_arg);
     21288@@ -214,7 +214,9 @@
     21289  * Wrapper for vsprintf that allocates a buffer big enough to hold the result.
     21290  */
     21291 NCURSES_EXPORT(char *)
     21292-_nc_printf_string(const char *fmt, va_list ap)
     21293+NCURSES_SP_NAME(_nc_printf_string) (NCURSES_SP_DCLx
     21294+                                   const char *fmt,
     21295+                                   va_list ap)
     21296 {
     21297     char *result = 0;
     21298 
     21299@@ -237,11 +239,11 @@
     21300 #define MyCols _nc_globals.safeprint_cols
     21301 #define MyRows _nc_globals.safeprint_rows
     21302 
     21303-       if (screen_lines > MyRows || screen_columns > MyCols) {
     21304-           if (screen_lines > MyRows)
     21305-               MyRows = screen_lines;
     21306-           if (screen_columns > MyCols)
     21307-               MyCols = screen_columns;
     21308+       if (screen_lines(SP_PARM) > MyRows || screen_columns(SP_PARM) > MyCols) {
     21309+           if (screen_lines(SP_PARM) > MyRows)
     21310+               MyRows = screen_lines(SP_PARM);
     21311+           if (screen_columns(SP_PARM) > MyCols)
     21312+               MyCols = screen_columns(SP_PARM);
     21313            my_length = (MyRows * (MyCols + 1)) + 1;
     21314            my_buffer = typeRealloc(char, my_length, my_buffer);
     21315        }
     21316@@ -262,3 +264,11 @@
     21317     }
     21318     return result;
     21319 }
     21320+
     21321+#if NCURSES_SP_FUNCS
     21322+NCURSES_EXPORT(char *)
     21323+_nc_printf_string(const char *fmt, va_list ap)
     21324+{
     21325+    return NCURSES_SP_NAME(_nc_printf_string) (CURRENT_SCREEN, fmt, ap);
     21326+}
     21327+#endif
    1806821328diff -Naur ncurses-5.7.orig/ncurses/base/tries.c ncurses-5.7/ncurses/base/tries.c
    1806921329--- ncurses-5.7.orig/ncurses/base/tries.c       2008-08-16 12:22:55.000000000 -0700
    18070 +++ ncurses-5.7/ncurses/base/tries.c    2009-02-28 20:38:58.439326442 -0800
     21330+++ ncurses-5.7/ncurses/base/tries.c    2009-06-05 14:01:16.000000000 -0700
    1807121331@@ -39,7 +39,7 @@
    1807221332 
     
    1808921349        }
    1809021350 #endif
     21351diff -Naur ncurses-5.7.orig/ncurses/base/wresize.c ncurses-5.7/ncurses/base/wresize.c
     21352--- ncurses-5.7.orig/ncurses/base/wresize.c     2008-06-07 06:59:01.000000000 -0700
     21353+++ ncurses-5.7/ncurses/base/wresize.c  2009-06-05 14:01:54.000000000 -0700
     21354@@ -1,5 +1,5 @@
     21355 /****************************************************************************
     21356- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     21357+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     21358  *                                                                          *
     21359  * Permission is hereby granted, free of charge, to any person obtaining a  *
     21360  * copy of this software and associated documentation files (the            *
     21361@@ -27,12 +27,13 @@
     21362  ****************************************************************************/
     21363 
     21364 /****************************************************************************
     21365- *  Author: Thomas E. Dickey 1996-2002                                      *
     21366+ *  Author: Thomas E. Dickey 1996-on                                        *
     21367+ *     and: Juergen Pfeifer                                                 *
     21368  ****************************************************************************/
     21369 
     21370 #include <curses.priv.h>
     21371 
     21372-MODULE_ID("$Id: wresize.c,v 1.29 2008/06/07 13:59:01 tom Exp $")
     21373+MODULE_ID("$Id: wresize.c,v 1.31 2009/05/23 19:50:16 tom Exp $")
     21374 
     21375 static int
     21376 cleanup_lines(struct ldat *data, int length)
     21377@@ -53,10 +54,13 @@
     21378     WINDOWLIST *wp;
     21379     struct ldat *pline = cmp->_line;
     21380     int row;
     21381+#ifdef USE_SP_WINDOWLIST
     21382+    SCREEN *sp = _nc_screen_of(cmp);
     21383+#endif
     21384 
     21385     _nc_lock_global(curses);
     21386 
     21387-    for (each_window(wp)) {
     21388+    for (each_window(SP_PARM, wp)) {
     21389        WINDOW *tst = &(wp->win);
     21390 
     21391        if (tst->_parent == cmp) {
    1809121392diff -Naur ncurses-5.7.orig/ncurses/curses.priv.h ncurses-5.7/ncurses/curses.priv.h
    1809221393--- ncurses-5.7.orig/ncurses/curses.priv.h      2008-10-04 14:37:45.000000000 -0700
    18093 +++ ncurses-5.7/ncurses/curses.priv.h   2009-02-28 20:38:59.859415560 -0800
     21394+++ ncurses-5.7/ncurses/curses.priv.h   2009-06-05 14:01:55.000000000 -0700
    1809421395@@ -1,5 +1,5 @@
    1809521396 /****************************************************************************
     
    1810921410 /*
    1811021411- * $Id: curses.priv.h,v 1.394 2008/10/04 21:37:45 tom Exp $
    18111 + * $Id: curses.priv.h,v 1.403 2009/02/28 20:55:48 tom Exp $
     21412+ * $Id: curses.priv.h,v 1.420 2009/05/30 15:53:46 tom Exp $
    1811221413  *
    1811321414  *     curses.priv.h
     
    1812221423 #if HAVE_WORKING_POLL
    1812321424 #define USE_FUNC_POLL 1
    18124 @@ -257,6 +256,38 @@
     21425@@ -195,6 +194,16 @@
     21426 #endif
     21427 
     21428 /*
     21429+ * Options for terminal drivers, etc...
     21430+ */
     21431+#if 0
     21432+#define USE_SP_RIPOFF     1
     21433+#define USE_SP_TERMTYPE   1
     21434+#define USE_SP_WINDOWLIST 1
     21435+#define USE_TERM_DRIVER   1
     21436+#endif
     21437+
     21438+/*
     21439  * Note:  ht/cbt expansion flakes out randomly under Linux 1.1.47, but only
     21440  * when we're throwing control codes at the screen at high volume.  To see
     21441  * this, re-enable USE_HARD_TABS and run worm for a while.  Other systems
     21442@@ -257,8 +266,59 @@
    1812521443 #define NCURSES_OPAQUE 0
    1812621444 
     
    1814921467+#include <nc_panel.h>
    1815021468+
    18151 +#define IsPreScreen(sp)      (((sp)!=0) && sp->_prescreen)
    18152 +#define HasTerminal(sp)      (((sp)!=0) && (0!=((sp)->_term)))
    18153 +#define IsValidScreen(sp)    (HasTerminal(sp) && !sp->_prescreen)
     21469+#define IsPreScreen(sp)      (((sp) != 0) && sp->_prescreen)
     21470+#define HasTerminal(sp)      (((sp) != 0) && (0 != ((sp)->_term)))
     21471+#define IsValidScreen(sp)    (HasTerminal(sp) && !IsPreScreen(sp))
     21472+
    1815421473+#if BROKEN_LINKER || USE_REENTRANT
    18155 +#define TerminalOf(sp)       ((sp)?((sp)->_term?(sp)->_term:_nc_prescreen._cur_term): _nc_prescreen._cur_term)
     21474+#define CurTerm              _nc_prescreen._cur_term
    1815621475+#else
    18157 +#define TerminalOf(sp)       ((sp)?((sp)->_term?(sp)->_term:cur_term):cur_term)
     21476+#define CurTerm              cur_term
    1815821477+#endif
    1815921478+
     21479+#if NCURSES_SP_FUNCS
     21480+#define TerminalOf(sp)       ((sp) ? ((sp)->_term ? (sp)->_term : CurTerm) : CurTerm)
     21481+#else
     21482+#define TerminalOf(sp)       CurTerm
     21483+#endif
     21484+
    1816021485 #include <term.h>
     21486+
     21487+/*
     21488+ * Reduce dependency on cur_term global by using terminfo data from SCREEN's
     21489+ * pointer to this data.
     21490+ */
     21491+#ifdef USE_SP_TERMTYPE
     21492+#undef CUR
     21493+#endif
     21494+
     21495+#define SP_TERMTYPE TerminalOf(sp)->type.
     21496+
    1816121497 #include <term_entry.h>
     21498+
    1816221499 #include <nc_tparm.h>
    18163 @@ -289,7 +320,7 @@
     21500 
     21501 #if NCURSES_EXT_COLORS && USE_WIDEC_SUPPORT
     21502@@ -272,8 +332,14 @@
     21503 #define GET_WINDOW_PAIR(w)     (w)->_color
     21504 #define SET_WINDOW_PAIR(w,p)   (w)->_color = (p)
     21505 #define SameAttrOf(a,b)                (AttrOf(a) == AttrOf(b) && GetPair(a) == GetPair(b))
     21506-#define VIDATTR(attr, pair)    vid_attr(attr, pair, 0)
     21507+
     21508+#if NCURSES_SP_FUNCS
     21509+#define VIDATTR(sp,attr,pair)  NCURSES_SP_NAME(vid_attr)(sp, attr, pair, 0)
     21510 #else
     21511+#define VIDATTR(sp,attr,pair)  vid_attr(attr, pair, 0)
     21512+#endif
     21513+
     21514+#else /* !(NCURSES_EXT_COLORS && USE_WIDEC_SUPPORT) */
     21515 #define if_EXT_COLORS(stmt)    /* nothing */
     21516 #define SetPair(value,p)       RemAttr(value, A_COLOR), \
     21517                                SetAttr(value, AttrOf(value) | (A_COLOR & COLOR_PAIR(p)))
     21518@@ -283,13 +349,19 @@
     21519 #define SET_WINDOW_PAIR(w,p)   WINDOW_ATTRS(w) &= ALL_BUT_COLOR, \
     21520                                WINDOW_ATTRS(w) |= (A_COLOR & COLOR_PAIR(p))
     21521 #define SameAttrOf(a,b)                (AttrOf(a) == AttrOf(b))
     21522-#define VIDATTR(attr, pair)    vidattr(attr)
     21523+
     21524+#if NCURSES_SP_FUNCS
     21525+#define VIDATTR(sp,attr,pair)  NCURSES_SP_NAME(vidattr)(sp, attr)
     21526+#else
     21527+#define VIDATTR(sp,attr,pair)  vidattr(attr)
     21528 #endif
     21529 
     21530+#endif /* NCURSES_EXT_COLORS && USE_WIDEC_SUPPORT */
     21531+
    1816421532 #if NCURSES_NO_PADDING
    1816521533 #define GetNoPadding(sp)       ((sp) ? (sp)->_no_padding : _nc_prescreen._no_padding)
     
    1817021538 #define GetNoPadding(sp)       FALSE
    1817121539 #define SetNoPadding(sp)       /*nothing*/
    18172 @@ -404,6 +435,8 @@
     21540@@ -302,17 +374,31 @@
     21541 #define SET_SCREEN_PAIR(s,p)   SetPair(SCREEN_ATTRS(s), p)
     21542 
     21543 #if USE_REENTRANT
     21544-NCURSES_EXPORT(int *) _nc_ptr_Lines (void);
     21545-NCURSES_EXPORT(int *) _nc_ptr_Cols (void);
     21546-#define ptrLines() (SP ? &(SP->_LINES) : &(_nc_prescreen._LINES))
     21547-#define ptrCols()  (SP ? &(SP->_COLS)  : &(_nc_prescreen._COLS))
     21548-#define SET_LINES(value) *_nc_ptr_Lines() = value
     21549-#define SET_COLS(value)  *_nc_ptr_Cols() = value
     21550-#else
     21551-#define ptrLines() &LINES
     21552-#define ptrCols()  &COLS
     21553-#define SET_LINES(value) LINES = value
     21554-#define SET_COLS(value)  COLS = value
     21555+
     21556+NCURSES_EXPORT(int *)        _nc_ptr_Lines (SCREEN *);
     21557+NCURSES_EXPORT(int *)        _nc_ptr_Cols (SCREEN *);
     21558+NCURSES_EXPORT(int *)        _nc_ptr_Tabsize (SCREEN *);
     21559+NCURSES_EXPORT(int *)        _nc_ptr_Escdelay (SCREEN *);
     21560+
     21561+#define ptrLines(sp)         (sp ? &(sp->_LINES) : &(_nc_prescreen._LINES))
     21562+#define ptrCols(sp)          (sp ? &(sp->_COLS) : &(_nc_prescreen._COLS))
     21563+#define ptrTabsize(sp)       (sp ? &(sp->_TABSIZE) : &(_nc_prescreen._TABSIZE))
     21564+#define ptrEscdelay(sp)      (sp ? &(sp->_ESCDELAY) : &(_nc_prescreen._ESCDELAY))
     21565+
     21566+#define SET_LINES(value)     *_nc_ptr_Lines(SP_PARM) = value
     21567+#define SET_COLS(value)      *_nc_ptr_Cols(SP_PARM) = value
     21568+#define SET_TABSIZE(value)   *_nc_ptr_Tabsize(SP_PARM) = value
     21569+#define SET_ESCDELAY(value)  *_nc_ptr_Escdelay(SP_PARM) = value
     21570+
     21571+#else
     21572+
     21573+#define ptrLines(sp)         &LINES
     21574+#define ptrCols(sp)          &COLS
     21575+#define SET_LINES(value)     LINES = value
     21576+#define SET_COLS(value)      COLS = value
     21577+#define SET_TABSIZE(value)   TABSIZE = value
     21578+#define SET_ESCDELAY(value)  ESCDELAY = value
     21579+
     21580 #endif
     21581 
     21582 #define TR_MUTEX(data) _tracef("%s@%d: me:%08lX COUNT:%2u/%2d/%6d/%2d/%s%9u: " #data, \
     21583@@ -404,6 +490,8 @@
    1817321584 #define C_SHIFT 9              /* we need more bits than there are colors */
    1817421585 #define C_MASK                 ((1 << C_SHIFT) - 1)
     
    1817921590 
    1818021591 #define COLOR_DEFAULT          C_MASK
    18181 @@ -464,13 +497,13 @@
     21592@@ -464,13 +552,13 @@
    1818221593 } slk_ent;
    1818321594 
     
    1819921610 } SLK;
    1820021611 
    18201 @@ -703,6 +736,8 @@
     21612@@ -493,10 +581,10 @@
     21613 typedef int (*TYPE_Gpm_Close) (void);
     21614 typedef int (*TYPE_Gpm_GetEvent) (Gpm_Event *);
     21615 
     21616-#define my_gpm_fd       SP->_mouse_gpm_fd
     21617-#define my_Gpm_Open     SP->_mouse_Gpm_Open
     21618-#define my_Gpm_Close    SP->_mouse_Gpm_Close
     21619-#define my_Gpm_GetEvent SP->_mouse_Gpm_GetEvent
     21620+#define my_gpm_fd       SP_PARM->_mouse_gpm_fd
     21621+#define my_Gpm_Open     SP_PARM->_mouse_Gpm_Open
     21622+#define my_Gpm_Close    SP_PARM->_mouse_Gpm_Close
     21623+#define my_Gpm_GetEvent SP_PARM->_mouse_Gpm_GetEvent
     21624 #else
     21625 /* link statically to GPM */
     21626 #define my_gpm_fd       &gpm_fd
     21627@@ -609,8 +697,10 @@
     21628        int             tgetent_index;
     21629        long            tgetent_sequence;
     21630 
     21631+#ifndef USE_SP_WINDOWLIST
     21632        WINDOWLIST      *_nc_windowlist;
     21633-#define _nc_windows    _nc_globals._nc_windowlist
     21634+#define WindowList(sp) _nc_globals._nc_windowlist
     21635+#endif
     21636 
     21637 #if USE_HOME_TERMINFO
     21638        char            *home_terminfo;
     21639@@ -644,7 +734,9 @@
     21640        char            traceatr_color_buf[2][80];
     21641        int             traceatr_color_sel;
     21642        int             traceatr_color_last;
     21643-
     21644+#if !defined(USE_PTHREADS) && USE_REENTRANT
     21645+       int             nested_tracef;
     21646+#endif
     21647 #endif /* TRACE */
     21648 
     21649 #ifdef USE_PTHREADS
     21650@@ -669,8 +761,10 @@
     21651        bool            use_env;
     21652        bool            filter_mode;
     21653        attr_t          previous_attr;
     21654+#ifndef USE_SP_RIPOFF
     21655        ripoff_t        rippedoff[N_RIPS];
     21656        ripoff_t        *rsp;
     21657+#endif
     21658        TPARM_STATE     tparm_state;
     21659        TTY             *saved_tty;     /* savetty/resetty information      */
     21660 #if NCURSES_NO_PADDING
     21661@@ -680,6 +774,8 @@
     21662        chtype          *real_acs_map;
     21663        int             _LINES;
     21664        int             _COLS;
     21665+       int             _TABSIZE;
     21666+       int             _ESCDELAY;
     21667        TERMINAL        *_cur_term;
     21668 #ifdef TRACE
     21669        long            _outchars;
     21670@@ -688,8 +784,16 @@
     21671 #endif
     21672 } NCURSES_PRESCREEN;
     21673 
     21674-#define ripoff_sp      _nc_prescreen.rsp
     21675-#define ripoff_stack   _nc_prescreen.rippedoff
     21676+/*
     21677+ * Use screen-specific ripoff data (for softkeys) rather than global.
     21678+ */
     21679+#ifdef USE_SP_RIPOFF
     21680+#define safe_ripoff_sp     (sp)->rsp
     21681+#define safe_ripoff_stack  (sp)->rippedoff
     21682+#else
     21683+#define safe_ripoff_sp    _nc_prescreen.rsp
     21684+#define safe_ripoff_stack  _nc_prescreen.rippedoff
     21685+#endif
     21686 
     21687 extern NCURSES_EXPORT_VAR(NCURSES_PRESCREEN) _nc_prescreen;
     21688 
     21689@@ -703,6 +807,8 @@
    1820221690        char            *_setbuf;       /* buffered I/O for output          */
    1820321691        bool            _filtered;      /* filter() was called              */
     
    1820821696        TERMINAL        *_term;         /* terminal type information        */
    1820921697        TTY             _saved_tty;     /* savetty/resetty information      */
    18210 @@ -794,11 +829,13 @@
     21698@@ -716,6 +822,10 @@
     21699        WINDOW          *_newscr;       /* virtual screen to be updated to  */
     21700        WINDOW          *_stdscr;       /* screen's full-window context     */
     21701 
     21702+#define CurScreen(sp)  (sp)->_curscr
     21703+#define NewScreen(sp)  (sp)->_newscr
     21704+#define StdScreen(sp)  (sp)->_stdscr
     21705+
     21706        TRIES           *_keytry;       /* "Try" for use with keypad mode   */
     21707        TRIES           *_key_ok;       /* Disabled keys via keyok(,FALSE)  */
     21708        bool            _tried;         /* keypad mode was initialized      */
     21709@@ -794,11 +904,13 @@
    1821121710        int             _color_count;   /* count of colors in palette        */
    1821221711        colorpair_t     *_color_pairs;  /* screen's color pair list          */
     
    1822221721        chtype          _ok_attributes; /* valid attributes for terminal     */
    1822321722        chtype          _xmc_suppress;  /* attributes to suppress if xmc     */
    18224 @@ -1263,7 +1300,7 @@
     21723@@ -895,7 +1007,7 @@
     21724        int             _oldnum_size;
     21725 
     21726        bool            _cleanup;       /* cleanup after int/quit signal */
     21727-       int             (*_outch)(int); /* output handler if not putc */
     21728+       NCURSES_SP_OUTC _outch;         /* output handler if not putc */
     21729 
     21730        int             _legacy_coding; /* see use_legacy_coding() */
     21731 
     21732@@ -915,6 +1027,15 @@
     21733        char            tracechr_buf[40];
     21734        char            tracemse_buf[TRACEMSE_MAX];
     21735 #endif
     21736+#ifdef USE_SP_WINDOWLIST
     21737+       WINDOWLIST*     _windowlist;
     21738+#define WindowList(sp)  (sp)->_windowlist
     21739+#endif
     21740+       NCURSES_OUTC    jump;
     21741+
     21742+       ripoff_t        rippedoff[N_RIPS];
     21743+       ripoff_t        *rsp;
     21744+
     21745        /*
     21746         * ncurses/ncursesw are the same up to this point.
     21747         */
     21748@@ -943,6 +1064,20 @@
     21749 
     21750 #define WINDOW_EXT(win,field) (((WINDOWLIST *)(win))->field)
     21751 
     21752+#define SP_PRE_INIT(sp)                         \
     21753+    sp->_cursrow = -1;                          \
     21754+    sp->_curscol = -1;                          \
     21755+    sp->_nl = TRUE;                             \
     21756+    sp->_raw = FALSE;                           \
     21757+    sp->_cbreak = 0;                            \
     21758+    sp->_echo = TRUE;                           \
     21759+    sp->_fifohead = -1;                         \
     21760+    sp->_endwin = TRUE;                         \
     21761+    sp->_cursor = -1;                           \
     21762+    WindowList(sp) = 0;                         \
     21763+    sp->_outch = NCURSES_SP_NAME(_nc_outch);    \
     21764+    sp->jump = 0                                \
     21765+
     21766 /* usually in <limits.h> */
     21767 #ifndef UCHAR_MAX
     21768 #define UCHAR_MAX 255
     21769@@ -1112,7 +1247,7 @@
     21770                                AttrOf(dst) |= (ext + 1)
     21771 
     21772 #define if_WIDEC(code)  code
     21773-#define Charable(ch)   ((SP != 0 && SP->_legacy_coding)                \
     21774+#define Charable(ch)   ((SP_PARM != 0 && SP_PARM->_legacy_coding)      \
     21775                         || (AttrOf(ch) & A_ALTCHARSET)                 \
     21776                         || (!isWidecExt(ch) &&                         \
     21777                             (ch).chars[1] == L'\0' &&                  \
     21778@@ -1214,8 +1349,8 @@
     21779  * Standardize/simplify common loops
     21780  */
     21781 #define each_screen(p) p = _nc_screen_chain; p != 0; p = (p)->_next_screen
     21782-#define each_window(p) p = _nc_windows; p != 0; p = (p)->next
     21783-#define each_ripoff(p) p = ripoff_stack; (p - ripoff_stack) < N_RIPS; ++p
     21784+#define each_window(sp,p) p = WindowList(sp); p != 0; p = (p)->next
     21785+#define each_ripoff(p) p = safe_ripoff_stack; (p - safe_ripoff_stack) < N_RIPS; ++p
     21786 
     21787 /*
     21788  * Prefixes for call/return points of library function traces.  We use these to
     21789@@ -1263,7 +1398,7 @@
    1822521790 #define returnBool(code)       TRACE_RETURN(code,bool)
    1822621791 #define returnCPtr(code)       TRACE_RETURN(code,cptr)
     
    1823121796 #define returnPtr(code)                TRACE_RETURN(code,ptr)
    1823221797 #define returnSP(code)         TRACE_RETURN(code,sp)
    18233 @@ -1322,7 +1359,7 @@
     21798@@ -1322,7 +1457,7 @@
    1823421799 #define returnBool(code)       return code
    1823521800 #define returnCPtr(code)       return code
     
    1824021805 #define returnPtr(code)                return code
    1824121806 #define returnSP(code)         return code
    18242 @@ -1519,7 +1556,7 @@
     21807@@ -1348,7 +1483,7 @@
     21808 
     21809 #define ALL_BUT_COLOR ((chtype)~(A_COLOR))
     21810 #define NONBLANK_ATTR (A_NORMAL|A_BOLD|A_DIM|A_BLINK)
     21811-#define XMC_CHANGES(c) ((c) & SP->_xmc_suppress)
     21812+#define XMC_CHANGES(c) ((c) & SP_PARM->_xmc_suppress)
     21813 
     21814 #define toggle_attr_on(S,at) {\
     21815    if (PAIR_NUMBER(at) > 0) {\
     21816@@ -1367,38 +1502,38 @@
     21817    }\
     21818    TR(TRACE_ATTRS, ("new attribute is %s", _traceattr((S))));}
     21819 
     21820-#define DelCharCost(count) \
     21821+#define DelCharCost(sp,count) \
     21822                ((parm_dch != 0) \
     21823-               ? SP->_dch_cost \
     21824+               ? sp->_dch_cost \
     21825                : ((delete_character != 0) \
     21826-                       ? (SP->_dch1_cost * count) \
     21827+                       ? (sp->_dch1_cost * count) \
     21828                        : INFINITY))
     21829 
     21830-#define InsCharCost(count) \
     21831+#define InsCharCost(sp,count) \
     21832                ((parm_ich != 0) \
     21833-               ? SP->_ich_cost \
     21834+               ? sp->_ich_cost \
     21835                : ((enter_insert_mode && exit_insert_mode) \
     21836-                 ? SP->_smir_cost + SP->_rmir_cost + (SP->_ip_cost * count) \
     21837+                 ? sp->_smir_cost + sp->_rmir_cost + (sp->_ip_cost * count) \
     21838                  : ((insert_character != 0) \
     21839-                   ? ((SP->_ich1_cost + SP->_ip_cost) * count) \
     21840+                   ? ((sp->_ich1_cost + sp->_ip_cost) * count) \
     21841                    : INFINITY)))
     21842 
     21843 #if USE_XMC_SUPPORT
     21844-#define UpdateAttrs(c) if (!SameAttrOf(SCREEN_ATTRS(SP), c)) { \
     21845-                               attr_t chg = AttrOf(SCREEN_ATTRS(SP)); \
     21846-                               VIDATTR(AttrOf(c), GetPair(c)); \
     21847+#define UpdateAttrs(sp,c)      if (!SameAttrOf(SCREEN_ATTRS(sp), c)) { \
     21848+                               attr_t chg = AttrOf(SCREEN_ATTRS(sp)); \
     21849+                               VIDATTR(sp, AttrOf(c), GetPair(c)); \
     21850                                if (magic_cookie_glitch > 0 \
     21851-                                && XMC_CHANGES((chg ^ AttrOf(SCREEN_ATTRS(SP))))) { \
     21852+                                && XMC_CHANGES((chg ^ AttrOf(SCREEN_ATTRS(sp))))) { \
     21853                                        T(("%s @%d before glitch %d,%d", \
     21854                                                __FILE__, __LINE__, \
     21855-                                               SP->_cursrow, \
     21856-                                               SP->_curscol)); \
     21857-                                       _nc_do_xmc_glitch(chg); \
     21858+                                               sp->_cursrow, \
     21859+                                               sp->_curscol)); \
     21860+                                       NCURSES_SP_NAME(_nc_do_xmc_glitch)(NCURSES_SP_ARGx chg); \
     21861                                } \
     21862                        }
     21863 #else
     21864-#define UpdateAttrs(c) if (!SameAttrOf(SCREEN_ATTRS(SP), c)) \
     21865-                               VIDATTR(AttrOf(c), GetPair(c));
     21866+#define UpdateAttrs(sp,c)      if (!SameAttrOf(SCREEN_ATTRS(sp), c)) \
     21867+                                   VIDATTR(sp, AttrOf(c), GetPair(c));
     21868 #endif
     21869 
     21870 /*
     21871@@ -1483,8 +1618,8 @@
     21872 #endif
     21873 
     21874 /* lib_acs.c */
     21875-extern NCURSES_EXPORT(void) _nc_init_acs (void);       /* corresponds to traditional 'init_acs()' */
     21876-extern NCURSES_EXPORT(int) _nc_msec_cost (const char *const, int);  /* used by 'tack' program */
     21877+extern NCURSES_EXPORT(void) _nc_init_acs (void); /* corresponds to traditional 'init_acs()' */
     21878+extern NCURSES_EXPORT(int)  _nc_msec_cost (const char *const, int);  /* used by 'tack' program */
     21879 
     21880 /* lib_addch.c */
     21881 #if USE_WIDEC_SUPPORT
     21882@@ -1503,7 +1638,7 @@
     21883 extern NCURSES_EXPORT(int) _nc_wgetch(WINDOW *, unsigned long *, int EVENTLIST_2nd(_nc_eventlist *));
     21884 
     21885 /* lib_insch.c */
     21886-extern NCURSES_EXPORT(int) _nc_insert_ch(WINDOW *, chtype);
     21887+extern NCURSES_EXPORT(int) _nc_insert_ch(SCREEN *, WINDOW *, chtype);
     21888 
     21889 /* lib_mvcur.c */
     21890 #define INFINITY       1000000 /* cost: too high to use */
     21891@@ -1519,7 +1654,7 @@
    1824321892 extern NCURSES_EXPORT(void) _nc_screen_wrap (void);
    1824421893 
     
    1824921898 /* lib_mvcur.c */
    1825021899 #define INFINITY       1000000 /* cost: too high to use */
    18251 @@ -1592,6 +1629,8 @@
     21900@@ -1527,10 +1662,13 @@
     21901 
     21902 /* lib_setup.c */
     21903 extern NCURSES_EXPORT(char *) _nc_get_locale(void);
     21904-extern NCURSES_EXPORT(int) _nc_unicode_locale(void);
     21905-extern NCURSES_EXPORT(int) _nc_locale_breaks_acs(TERMINAL *);
     21906-extern NCURSES_EXPORT(int) _nc_setupterm(NCURSES_CONST char *, int, int *, bool);
     21907-extern NCURSES_EXPORT(void) _nc_get_screensize(SCREEN *, int *, int *);
     21908+extern NCURSES_EXPORT(int)    _nc_unicode_locale(void);
     21909+extern NCURSES_EXPORT(int)    _nc_locale_breaks_acs(TERMINAL *);
     21910+extern NCURSES_EXPORT(int)    _nc_setupterm(NCURSES_CONST char *, int, int *, bool);
     21911+extern NCURSES_EXPORT(void)   _nc_get_screensize(SCREEN *, int *, int *);
     21912+
     21913+/* lib_set_term.c */
     21914+extern NCURSES_EXPORT(int)    _nc_ripoffline(int, int(*)(WINDOW*, int));
     21915 
     21916 /* lib_tstp.c */
     21917 #if USE_SIGWINCH
     21918@@ -1539,9 +1677,6 @@
     21919 #define _nc_handle_sigwinch(a) /* nothing */
     21920 #endif
     21921 
     21922-/* lib_ungetch.c */
     21923-extern NCURSES_EXPORT(int) _nc_ungetch (SCREEN *, int);
     21924-
     21925 /* lib_wacs.c */
     21926 #if USE_WIDEC_SUPPORT
     21927 extern NCURSES_EXPORT(void) _nc_init_wacs(void);
     21928@@ -1577,8 +1712,6 @@
     21929 
     21930 /* elsewhere ... */
     21931 extern NCURSES_EXPORT(ENTRY *) _nc_delink_entry (ENTRY *, TERMTYPE *);
     21932-extern NCURSES_EXPORT(NCURSES_CONST char *) _nc_keyname (SCREEN *, int);
     21933-extern NCURSES_EXPORT(NCURSES_CONST char *) _nc_unctrl (SCREEN *, chtype);
     21934 extern NCURSES_EXPORT(SCREEN *) _nc_screen_of (WINDOW *);
     21935 extern NCURSES_EXPORT(WINDOW *) _nc_makenew (int, int, int, int, int);
     21936 extern NCURSES_EXPORT(char *) _nc_trace_buf (int, size_t);
     21937@@ -1592,12 +1725,14 @@
    1825221938 extern NCURSES_EXPORT(int) _nc_keypad (SCREEN *, bool);
    1825321939 extern NCURSES_EXPORT(int) _nc_ospeed (int);
     
    1825821944 extern NCURSES_EXPORT(int) _nc_setupscreen (int, int, FILE *, bool, int);
    1825921945 extern NCURSES_EXPORT(int) _nc_timed_wait (SCREEN *, int, int, int * EVENTLIST_2nd(_nc_eventlist *));
    18260 @@ -1663,7 +1702,7 @@
    18261  
    18262  #define NC_BUFFERED(flag) _nc_set_buffer(SP->_ofp, flag)
     21946-extern NCURSES_EXPORT(void) _nc_do_color (short, short, bool, int (*)(int));
     21947+extern NCURSES_EXPORT(void) _nc_do_color (short, short, bool, NCURSES_OUTC);
     21948 extern NCURSES_EXPORT(void) _nc_flush (void);
     21949-extern NCURSES_EXPORT(void) _nc_free_and_exit (int);
     21950+extern NCURSES_EXPORT(void) _nc_free_and_exit (int) GCC_NORETURN;
     21951 extern NCURSES_EXPORT(void) _nc_free_entry (ENTRY *, TERMTYPE *);
     21952 extern NCURSES_EXPORT(void) _nc_freeall (void);
     21953 extern NCURSES_EXPORT(void) _nc_hash_map (void);
     21954@@ -1661,9 +1796,9 @@
     21955 
     21956 #define USE_SETBUF_0 0
     21957 
     21958-#define NC_BUFFERED(flag) _nc_set_buffer(SP->_ofp, flag)
     21959+#define NC_BUFFERED(sp,flag) NCURSES_SP_NAME(_nc_set_buffer)(NCURSES_SP_ARGx sp->_ofp, flag)
    1826321960 
    1826421961-#define NC_OUTPUT ((SP != 0) ? SP->_ofp : stdout)
    18265 +#define NC_OUTPUT ((SP_PARM != 0) ? SP_PARM->_ofp : stdout)
     21962+#define NC_OUTPUT(sp) ((sp != 0) ? sp->_ofp : stdout)
    1826621963 
    1826721964 /*
    1826821965  * On systems with a broken linker, define 'SP' as a function to force the
    18269 @@ -1681,6 +1720,8 @@
    18270  #define _nc_set_screen(sp) SP = sp
     21966@@ -1672,13 +1807,21 @@
     21967 #if BROKEN_LINKER
     21968 #define SP _nc_screen()
     21969 extern NCURSES_EXPORT(SCREEN *) _nc_screen (void);
     21970-extern NCURSES_EXPORT(int) _nc_alloc_screen (void);
     21971-extern NCURSES_EXPORT(void) _nc_set_screen (SCREEN *);
     21972+extern NCURSES_EXPORT(int)      _nc_alloc_screen (void);
     21973+extern NCURSES_EXPORT(void)     _nc_set_screen (SCREEN *);
     21974+#define CURRENT_SCREEN          _nc_screen()
     21975 #else
     21976 /* current screen is private data; avoid possible linking conflicts too */
     21977 extern NCURSES_EXPORT_VAR(SCREEN *) SP;
     21978-#define _nc_alloc_screen() ((SP = typeCalloc(SCREEN, 1)) != 0)
     21979-#define _nc_set_screen(sp) SP = sp
     21980+#define CURRENT_SCREEN SP
     21981+#define _nc_alloc_screen()      ((SP = typeCalloc(SCREEN, 1)) != 0)
     21982+#define _nc_set_screen(sp)      SP = sp
     21983+#endif
     21984+
     21985+#if NCURSES_SP_FUNCS && 0
     21986+#define CURRENT_SCREEN_PRE      (IsPreScreen(CURRENT_SCREEN) ? CURRENT_SCREEN : new_prescr())
     21987+#else
     21988+#define CURRENT_SCREEN_PRE      CURRENT_SCREEN
    1827121989 #endif
    1827221990 
    18273 +#define CURRENT_SCREEN SP
    18274 +
    1827521991 /*
    18276   * We don't want to use the lines or columns capabilities internally, because
     21992@@ -1686,10 +1829,11 @@
    1827721993  * if the application is running multiple screens under X, it's quite possible
    18278 @@ -1715,6 +1756,79 @@
     21994  * they could all have type xterm but have different sizes!  So...
     21995  */
     21996-#define screen_lines   SP->_lines
     21997-#define screen_columns SP->_columns
     21998+#define screen_lines(sp)        (sp)->_lines
     21999+#define screen_columns(sp)      (sp)->_columns
     22000 
     22001 extern NCURSES_EXPORT(int) _nc_slk_initialize (WINDOW *, int);
     22002+extern NCURSES_EXPORT(int) _nc_format_slks (SCREEN *, int);
     22003 
     22004 /*
     22005  * Some constants related to SLK's
     22006@@ -1707,14 +1851,243 @@
     22007 #define MAX_SKEY(fmt)     (SLK_STDFMT(fmt)? MAX_SKEY_OLD : MAX_SKEY_PC)
     22008 #define MAX_SKEY_LEN(fmt) (SLK_STDFMT(fmt)? MAX_SKEY_LEN_OLD : MAX_SKEY_LEN_PC)
     22009 
     22010-extern NCURSES_EXPORT(int) _nc_ripoffline (int line, int (*init)(WINDOW *,int));
     22011-
     22012 /*
     22013  * Common error messages
     22014  */
    1827922015 #define MSG_NO_MEMORY "Out of memory"
    1828022016 #define MSG_NO_INPUTS "Premature EOF"
    1828122017 
     22018+extern NCURSES_EXPORT(int) _nc_set_tty_mode(TTY *);
     22019+extern NCURSES_EXPORT(int) _nc_get_tty_mode(TTY *);
     22020+
    1828222021+/* timed_wait flag definitions */
    1828322022+#define TW_NONE    0
     
    1828622025+#define TW_ANY     (TW_INPUT | TW_MOUSE)
    1828722026+#define TW_EVENT   4
     22027+
     22028+#define SetSafeOutcWrapper(outc)           \
     22029+    SCREEN* sp = CURRENT_SCREEN;            \
     22030+    if (sp==0) {                            \
     22031+       struct screen dummy;                \
     22032+       sp = &dummy;                        \
     22033+       memset(sp,0,sizeof(struct screen)); \
     22034+       sp->_outch = _nc_outc_wrapper;      \
     22035+    }\
     22036+    sp->jump = outc
     22037+
     22038+struct DriverTCB; /* Terminal Control Block forward declaration */
     22039+typedef void* TERM_HANDLE;
     22040+
     22041+typedef struct _termInfo
     22042+{
     22043+    bool caninit;
     22044+
     22045+    bool hascolor;
     22046+    bool initcolor;
     22047+    bool canchange;
     22048+
     22049+    int  tabsize;
     22050+
     22051+    int  maxcolors;
     22052+    int  maxpairs;
     22053+    int  nocolorvideo;
     22054+
     22055+    int  numlabels;
     22056+    int  labelwidth;
     22057+    int  labelheight;
     22058+
     22059+    const color_t* defaultPalette;
     22060+} TerminalInfo;
     22061+
     22062+typedef struct term_driver {
     22063+    bool   isTerminfo;
     22064+    bool   (*CanHandle)(struct DriverTCB*,const char*,int*);
     22065+    void   (*init)(struct DriverTCB*);
     22066+    void   (*release)(struct DriverTCB*);
     22067+    int    (*size)(struct DriverTCB*, int* Line, int *Cols);
     22068+    int    (*sgmode)(struct DriverTCB*, bool setFlag, TTY*);
     22069+    chtype (*conattr)(struct DriverTCB*);
     22070+    int    (*hwcur)(struct DriverTCB*, int yold, int xold, int y, int x);
     22071+    int    (*mode)(struct DriverTCB*, bool progFlag, bool defFlag);
     22072+    bool   (*rescol)(struct DriverTCB*);
     22073+    bool   (*rescolors)(struct DriverTCB*);
     22074+    void   (*color)(struct DriverTCB*,bool fore, int color, int(*)(SCREEN*,int));
     22075+    int    (*doBeepOrFlash)(struct DriverTCB*, bool);
     22076+    void   (*initpair)(struct DriverTCB*,short,short,short);
     22077+    void   (*initcolor)(struct DriverTCB*,short,short,short,short);
     22078+    void   (*docolor)(struct DriverTCB*,short,short,bool,int(*)(SCREEN*,int));
     22079+    void   (*initmouse)(struct DriverTCB*);
     22080+    void   (*setfilter)(struct DriverTCB*);
     22081+    void   (*hwlabel)(struct DriverTCB*,int,char*);
     22082+    void   (*hwlabelOnOff)(struct DriverTCB*,bool);
     22083+    int    (*update)(struct DriverTCB*);
     22084+    int    (*defaultcolors)(struct DriverTCB*,int,int);
     22085+    int    (*print)(struct DriverTCB*,char*,int);
     22086+    int    (*getsize)(struct DriverTCB*,int*,int*);
     22087+    int    (*setsize)(struct DriverTCB*,int,int);
     22088+    void   (*initacs)(struct DriverTCB*,chtype*,chtype*);
     22089+    void   (*scinit)(SCREEN *);
     22090+    void   (*scexit)(SCREEN *);
     22091+    int    (*twait)(struct DriverTCB*,int,int,int* EVENTLIST_2nd(_nc_eventlist*));
     22092+    int    (*read)(struct DriverTCB*,int*);
     22093+    int    (*nap)(struct DriverTCB*,int);
     22094+    int    (*kpad)(struct DriverTCB*, bool);
     22095+    int    (*kyOk)(struct DriverTCB*, int, bool);
     22096+    bool   (*kyExist)(struct DriverTCB*, int);
     22097+} TERM_DRIVER;
     22098+
     22099+
     22100+typedef struct DriverTCB
     22101+{
     22102+    TERMINAL      term;   /* needs to be the first Element !!! */
     22103+    TERM_HANDLE   inp;    /* The input handle of the Terminal */
     22104+    TERM_HANDLE   out;    /* The output handle of the Terminal in shell mode */
     22105+    TERM_HANDLE   hdl;    /* The output handle of the Terminal in prog  mode */
     22106+    TERM_DRIVER*  drv;    /* The driver for that Terminal */
     22107+    SCREEN*       csp;    /* The screen that owns that Terminal */
     22108+    TerminalInfo  info;   /* Driver independent core capabilities of the Terminal */
     22109+    void*         prop;   /* Driver dependent property storage to be used by the Driver */
     22110+    long          magic;
     22111+} TERMINAL_CONTROL_BLOCK;
     22112+
     22113+#define NCDRV_MAGIC(id) (0x47110000 | (id&0xffff))
     22114+#define NCDRV_TINFO      0x01
     22115+#define NCDRV_WINCONSOLE 0x02
     22116+
     22117+#define TCBOf(sp)    ((TERMINAL_CONTROL_BLOCK*)(TerminalOf(sp)))
     22118+#define InfoOf(sp)   TCBOf(sp)->info
     22119+#define CallDriver(sp,method)                        TCBOf(sp)->drv->method(TCBOf(sp))
     22120+#define CallDriver_1(sp,method,arg1)                 TCBOf(sp)->drv->method(TCBOf(sp),arg1)
     22121+#define CallDriver_2(sp,method,arg1,arg2)            TCBOf(sp)->drv->method(TCBOf(sp),arg1,arg2)
     22122+#define CallDriver_3(sp,method,arg1,arg2,arg3)       TCBOf(sp)->drv->method(TCBOf(sp),arg1,arg2,arg3)
     22123+#define CallDriver_4(sp,method,arg1,arg2,arg3,arg4)  TCBOf(sp)->drv->method(TCBOf(sp),arg1,arg2,arg3,arg4)
     22124+
     22125+extern NCURSES_EXPORT_VAR(const color_t*) _nc_cga_palette;
     22126+extern NCURSES_EXPORT_VAR(const color_t*) _nc_hls_palette;
     22127+
     22128+#ifdef USE_TERM_DRIVER
     22129+extern NCURSES_EXPORT(int)      _nc_tinfo_has_key(SCREEN*, int);
     22130+extern NCURSES_EXPORT(int)      _nc_tinfo_doupdate(SCREEN *sp);
     22131+extern NCURSES_EXPORT(int)      _nc_tinfo_mvcur(SCREEN*,int,int,int,int);
     22132+extern NCURSES_EXPORT(int)      _nc_get_driver(TERMINAL_CONTROL_BLOCK*, const char*, int*);
     22133+#endif
     22134+
     22135+#ifdef __MINGW32__
     22136+#include <nc_mingw.h>
     22137+extern NCURSES_EXPORT_VAR(TERM_DRIVER) _nc_WIN_DRIVER;
     22138+#endif
     22139+extern NCURSES_EXPORT_VAR(TERM_DRIVER) _nc_TINFO_DRIVER;
     22140+
     22141+#ifdef USE_TERM_DRIVER
     22142+#define IsTermInfo(sp)       (TCBOf(sp) && ((TCBOf(sp)->drv->isTerminfo)))
     22143+#else
     22144+#define IsTermInfo(sp)       TRUE
     22145+#endif
     22146+
     22147+#define HasTInfoTerminal(sp) ((0 != TerminalOf(sp)) && IsTermInfo(sp))
     22148+#define IsValidTIScreen(sp)  (HasTInfoTerminal(sp))
    1828822149+
    1828922150+/*
     
    1829622157+extern NCURSES_EXPORT(int)      _nc_outc_wrapper(SCREEN*,int);
    1829722158+
    18298 +extern NCURSES_EXPORT(TERMINAL*) NCURSES_SP_NAME(_nc_set_curterm)(SCREEN*,TERMINAL*);
    18299 +extern NCURSES_EXPORT(int)       NCURSES_SP_NAME(_nc_del_curterm)(SCREEN*,TERMINAL*);
     22159+#if USE_REENTRANT
     22160+extern NCURSES_EXPORT(char *)    NCURSES_SP_NAME(_nc_ttytype)(SCREEN*);
     22161+extern NCURSES_EXPORT(int)       NCURSES_SP_NAME(_nc_TABSIZE)(SCREEN*);
     22162+extern NCURSES_EXPORT(char *)    NCURSES_SP_NAME(longname)(SCREEN*);
     22163+#endif
    1830022164+
    1830122165+#if NCURSES_EXT_FUNCS
    1830222166+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_set_tabsize)(SCREEN*, int);
    1830322167+#endif
    18304 +
    18305 +extern NCURSES_EXPORT(chtype)   NCURSES_SP_NAME(_nc_acs_char)(SCREEN*,int);
    1830622168+
    1830722169+/*
     
    1831122173+extern NCURSES_EXPORT(SCREEN*)  _nc_SP(void);
    1831222174+
     22175+extern NCURSES_EXPORT(TERMINAL*) NCURSES_SP_NAME(_nc_set_curterm)(SCREEN*,TERMINAL*);
     22176+extern NCURSES_EXPORT(TERMINAL*) NCURSES_SP_NAME(cur_term)(SCREEN *sp);
     22177+extern NCURSES_EXPORT(WINDOW *) NCURSES_SP_NAME(_nc_makenew) (SCREEN*, int, int, int, int, int);
     22178+extern NCURSES_EXPORT(bool)     NCURSES_SP_NAME(_nc_reset_colors)(SCREEN*);
     22179+extern NCURSES_EXPORT(char *)   NCURSES_SP_NAME(_nc_printf_string)(SCREEN*, const char *, va_list);
     22180+extern NCURSES_EXPORT(chtype)   NCURSES_SP_NAME(_nc_acs_char)(SCREEN*,int);
     22181+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_curs_set)(SCREEN*,int);
     22182+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_get_tty_mode)(SCREEN*,TTY*);
     22183+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_mcprint)(SCREEN*,char*, int);
     22184+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_msec_cost)(SCREEN*, const char *, int);
     22185+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_outch)(SCREEN*, int);
     22186+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_putp)(SCREEN*, const char *, const char*);
     22187+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_putp_flush)(SCREEN*, const char *, const char *);
     22188+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_resetty)(SCREEN*);
     22189+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_resize_term)(SCREEN*,int,int);
     22190+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_ripoffline)(SCREEN*, int, int (*)(WINDOW *,int));
     22191+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_savetty)(SCREEN*);
     22192+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_scr_init)(SCREEN*,const char*);
     22193+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_scr_restore)(SCREEN*, const char*);
     22194+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_scrolln)(SCREEN*, int, int, int, int);
     22195+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_set_tty_mode)(SCREEN*, TTY*);
     22196+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_setupscreen)(SCREEN**, int, int, FILE *, bool, int);
     22197+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_tgetent)(SCREEN*,char*,const char *);
     22198+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_tigetnum)(SCREEN*,NCURSES_CONST char*);
     22199+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_vid_attr)(SCREEN *, attr_t, short, void *);
    1831322200+extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_vidputs)(SCREEN*,chtype,int(*) (SCREEN*, int));
    18314 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_vidattr)(SCREEN *, chtype);
    18315 +
    18316 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_scr_restore)(SCREEN*, const char*);
    18317 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_scr_init)(SCREEN*,const char*);
    18318 +
    18319 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_restartterm)(SCREEN*,NCURSES_CONST char*,int,int*);
    18320 +extern NCURSES_EXPORT(bool)     NCURSES_SP_NAME(_nc_is_term_resized)(SCREEN*,int,int);
    18321 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_resize_term)(SCREEN*,int,int);
    18322 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_resizeterm)(SCREEN*,int,int);
    18323 +
    18324 +extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(_nc_outch)(SCREEN*, int ch);
    18325 +extern NCURSES_EXPORT(void)    NCURSES_SP_NAME(_nc_flush)(SCREEN*);
    18326 +extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(_nc_putp)(SCREEN*, const char *, const char *);
    18327 +extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(_nc_putp_flush)(SCREEN*, const char *, const char *);
    18328 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_tgetent)(SCREEN*,char*,const char *);
    18329 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_tputs)(SCREEN*,const char*,int,int(*)(SCREEN*, int));
    18330 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_savetty)(SCREEN*);
    18331 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_resetty)(SCREEN*);
    18332 +
    18333 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_mcprint)(SCREEN*,char*, int);
    18334 +extern NCURSES_EXPORT(char *)   NCURSES_SP_NAME(_nc_tgetstr)(SCREEN*,NCURSES_CONST char*,char**);
    18335 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_tgetflag)(SCREEN*,NCURSES_CONST char*);
    18336 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_tgetnum)(SCREEN*,NCURSES_CONST char*);
    18337 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_tigetflag)(SCREEN*,NCURSES_CONST char*);
    18338 +extern NCURSES_EXPORT(int)      NCURSES_SP_NAME(_nc_tigetnum)(SCREEN*,NCURSES_CONST char*);
    18339 +extern NCURSES_EXPORT(char *)   NCURSES_SP_NAME(_nc_tigetstr)(SCREEN*, NCURSES_CONST char*);
     22201+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_do_color)(SCREEN*, short, short, bool, NCURSES_SP_OUTC);
     22202+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_do_xmc_glitch)(SCREEN*, attr_t);
     22203+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_flush)(SCREEN*);
     22204+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_free_and_exit)(SCREEN*, int) GCC_NORETURN;
     22205+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_freeall)(SCREEN*);
     22206+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_hash_map)(SCREEN*);
     22207+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_init_acs)(SCREEN*);
     22208+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_make_oldhash)(SCREEN*, int i);
     22209+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_mvcur_init)(SCREEN*);
     22210+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_mvcur_resume)(SCREEN*);
     22211+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_mvcur_wrap)(SCREEN*);
     22212+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_screen_init)(SCREEN*);
     22213+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_screen_resume)(SCREEN*);
     22214+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_screen_wrap)(SCREEN*);
     22215+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_scroll_oldhash)(SCREEN*, int n, int top, int bot);
     22216+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_scroll_optimize)(SCREEN*);
     22217+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_set_buffer)(SCREEN*, FILE *, bool);
     22218+
    1834022219+extern NCURSES_EXPORT(void)     _nc_cookie_init(SCREEN *sp);
    18341 +extern NCURSES_EXPORT(int)      _nc_tinfo_doupdate(SCREEN *sp);
    18342 +extern NCURSES_EXPORT(int)      _nc_tinfo_mcprint(SCREEN*,char*,int);
     22220+
     22221+#if defined(TRACE) || defined(SCROLLDEBUG) || defined(HASHDEBUG)
     22222+extern NCURSES_EXPORT(void)     NCURSES_SP_NAME(_nc_linedump)(SCREEN*);
     22223+#endif
     22224+
    1834322225+#if USE_WIDEC_SUPPORT
    1834422226+extern NCURSES_EXPORT(wchar_t *) NCURSES_SP_NAME(_nc_wunctrl)(SCREEN*, cchar_t *);
    1834522227+#endif
    1834622228+
    18347 +/* FIXME - move these to curses.h.in */
    18348 +extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(getmouse) (SCREEN*, MEVENT *);
    18349 +extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(ungetmouse) (SCREEN*, MEVENT *);
    18350 +extern NCURSES_EXPORT(mmask_t) NCURSES_SP_NAME(mousemask) (SCREEN*, mmask_t, mmask_t *);
    18351 +extern NCURSES_EXPORT(int)     NCURSES_SP_NAME(mouseinterval) (SCREEN*, int);
    18352 +extern NCURSES_EXPORT(bool)    NCURSES_SP_NAME(has_mouse) (SCREEN*);
    1835322229+#endif /* NCURSES_SP_FUNCS */
     22230+
     22231+#if NCURSES_SP_FUNCS
     22232+
     22233+#define safe_keyname NCURSES_SP_NAME(keyname)
     22234+#define safe_unctrl  NCURSES_SP_NAME(unctrl)
     22235+#define safe_ungetch NCURSES_SP_NAME(ungetch)
     22236+
     22237+#else
     22238+
     22239+#define safe_keyname _nc_keyname
     22240+#define safe_unctrl  _nc_unctrl
     22241+#define safe_ungetch _nc_ungetch
     22242+
     22243+extern NCURSES_EXPORT(NCURSES_CONST char *) _nc_keyname (SCREEN *, int);
     22244+extern NCURSES_EXPORT(int) _nc_ungetch (SCREEN *, int);
     22245+extern NCURSES_EXPORT(NCURSES_CONST char *) _nc_unctrl (SCREEN *, chtype);
     22246+
     22247+#endif
    1835422248+
    1835522249 #ifdef __cplusplus
     
    1835822252diff -Naur ncurses-5.7.orig/ncurses/Makefile.in ncurses-5.7/ncurses/Makefile.in
    1835922253--- ncurses-5.7.orig/ncurses/Makefile.in        2008-10-18 07:11:54.000000000 -0700
    18360 +++ ncurses-5.7/ncurses/Makefile.in     2009-02-28 20:38:46.310547562 -0800
     22254+++ ncurses-5.7/ncurses/Makefile.in     2009-06-05 14:01:30.000000000 -0700
    1836122255@@ -1,6 +1,6 @@
    1836222256-# $Id: Makefile.in,v 1.113 2008/10/18 14:11:54 tom Exp $
    18363 +# $Id: Makefile.in,v 1.114 2009/01/03 19:09:26 tom Exp $
     22257+# $Id: Makefile.in,v 1.115 2009/03/28 18:22:39 Charles.Wilson Exp $
    1836422258 ##############################################################################
    1836522259-# Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.                #
     
    1836822262 # Permission is hereby granted, free of charge, to any person obtaining a    #
    1836922263 # copy of this software and associated documentation files (the "Software"), #
    18370 @@ -78,7 +78,7 @@
     22264@@ -71,6 +71,7 @@
     22265 LIBTOOL_LINK   = @LIB_LINK@
     22266 LIBTOOL_INSTALL        = @LIB_INSTALL@
     22267 LIBTOOL_UNINSTALL = @LIB_UNINSTALL@
     22268+LT_UNDEF       = @LT_UNDEF@
     22269 
     22270 INSTALL                = @INSTALL@
     22271 INSTALL_LIB    = @INSTALL@ @INSTALL_LIB@
     22272@@ -78,7 +79,7 @@
    1837122273 INSTALL_DATA   = @INSTALL_DATA@
    1837222274 
     
    1837722279 LD             = @LD@
    1837822280 LN_S           = @LN_S@
     22281diff -Naur ncurses-5.7.orig/ncurses/tinfo/access.c ncurses-5.7/ncurses/tinfo/access.c
     22282--- ncurses-5.7.orig/ncurses/tinfo/access.c     2007-11-17 16:57:53.000000000 -0800
     22283+++ ncurses-5.7/ncurses/tinfo/access.c  2009-06-05 14:01:33.000000000 -0700
     22284@@ -1,5 +1,5 @@
     22285 /****************************************************************************
     22286- * Copyright (c) 1998-2006,2007 Free Software Foundation, Inc.              *
     22287+ * Copyright (c) 1998-2007,2009 Free Software Foundation, Inc.              *
     22288  *                                                                          *
     22289  * Permission is hereby granted, free of charge, to any person obtaining a  *
     22290  * copy of this software and associated documentation files (the            *
     22291@@ -38,7 +38,7 @@
     22292 #include <tic.h>
     22293 #include <nc_alloc.h>
     22294 
     22295-MODULE_ID("$Id: access.c,v 1.14 2007/11/18 00:57:53 tom Exp $")
     22296+MODULE_ID("$Id: access.c,v 1.15 2009/04/05 00:03:10 tom Exp $")
     22297 
     22298 #define LOWERCASE(c) ((isalpha(UChar(c)) && isupper(UChar(c))) ? tolower(UChar(c)) : (c))
     22299 
     22300@@ -97,7 +97,7 @@
     22301        test = path;
     22302     else
     22303        test++;
     22304-    return (test - path);
     22305+    return (unsigned) (test - path);
     22306 }
     22307 
     22308 NCURSES_EXPORT(char *)
     22309diff -Naur ncurses-5.7.orig/ncurses/tinfo/alloc_ttype.c ncurses-5.7/ncurses/tinfo/alloc_ttype.c
     22310--- ncurses-5.7.orig/ncurses/tinfo/alloc_ttype.c        2008-10-12 09:12:00.000000000 -0700
     22311+++ ncurses-5.7/ncurses/tinfo/alloc_ttype.c     2009-06-05 14:01:44.000000000 -0700
     22312@@ -1,5 +1,5 @@
     22313 /****************************************************************************
     22314- * Copyright (c) 1999-2006,2008 Free Software Foundation, Inc.              *
     22315+ * Copyright (c) 1999-2008,2009 Free Software Foundation, Inc.              *
     22316  *                                                                          *
     22317  * Permission is hereby granted, free of charge, to any person obtaining a  *
     22318  * copy of this software and associated documentation files (the            *
     22319@@ -43,7 +43,7 @@
     22320 #include <tic.h>
     22321 #include <term_entry.h>
     22322 
     22323-MODULE_ID("$Id: alloc_ttype.c,v 1.17 2008/10/12 16:12:00 tom Exp $")
     22324+MODULE_ID("$Id: alloc_ttype.c,v 1.18 2009/04/18 21:01:38 tom Exp $")
     22325 
     22326 #if NCURSES_XNAMES
     22327 /*
     22328@@ -147,10 +147,10 @@
     22329 /*
     22330  * Returns the first index in ext_Names[] for the given token-type
     22331  */
     22332-static int
     22333+static unsigned
     22334 _nc_first_ext_name(TERMTYPE *tp, int token_type)
     22335 {
     22336-    int first;
     22337+    unsigned first;
     22338 
     22339     switch (token_type) {
     22340     case BOOLEAN:
     22341@@ -160,7 +160,7 @@
     22342        first = tp->ext_Booleans;
     22343        break;
     22344     case STRING:
     22345-       first = tp->ext_Booleans + tp->ext_Numbers;
     22346+       first = (unsigned) (tp->ext_Booleans + tp->ext_Numbers);
     22347        break;
     22348     default:
     22349        first = 0;
     22350@@ -172,17 +172,17 @@
     22351 /*
     22352  * Returns the last index in ext_Names[] for the given token-type
     22353  */
     22354-static int
     22355+static unsigned
     22356 _nc_last_ext_name(TERMTYPE *tp, int token_type)
     22357 {
     22358-    int last;
     22359+    unsigned last;
     22360 
     22361     switch (token_type) {
     22362     case BOOLEAN:
     22363        last = tp->ext_Booleans;
     22364        break;
     22365     case NUMBER:
     22366-       last = tp->ext_Booleans + tp->ext_Numbers;
     22367+       last = (unsigned) (tp->ext_Booleans + tp->ext_Numbers);
     22368        break;
     22369     default:
     22370     case STRING:
     22371@@ -204,7 +204,7 @@
     22372 
     22373     for (j = first; j < last; j++) {
     22374        if (!strcmp(name, tp->ext_Names[j])) {
     22375-           return j;
     22376+           return (int) j;
     22377        }
     22378     }
     22379     return -1;
     22380@@ -244,7 +244,7 @@
     22381     int first, last;
     22382 
     22383     if ((first = _nc_find_ext_name(tp, name, token_type)) >= 0) {
     22384-       last = NUM_EXT_NAMES(tp) - 1;
     22385+       last = (int) NUM_EXT_NAMES(tp) - 1;
     22386        for (j = first; j < last; j++) {
     22387            tp->ext_Names[j] = tp->ext_Names[j + 1];
     22388        }
     22389@@ -254,22 +254,22 @@
     22390            last = tp->num_Booleans - 1;
     22391            for (j = first; j < last; j++)
     22392                tp->Booleans[j] = tp->Booleans[j + 1];
     22393-           tp->ext_Booleans -= 1;
     22394-           tp->num_Booleans -= 1;
     22395+           tp->ext_Booleans--;
     22396+           tp->num_Booleans--;
     22397            break;
     22398        case NUMBER:
     22399            last = tp->num_Numbers - 1;
     22400            for (j = first; j < last; j++)
     22401                tp->Numbers[j] = tp->Numbers[j + 1];
     22402-           tp->ext_Numbers -= 1;
     22403-           tp->num_Numbers -= 1;
     22404+           tp->ext_Numbers--;
     22405+           tp->num_Numbers--;
     22406            break;
     22407        case STRING:
     22408            last = tp->num_Strings - 1;
     22409            for (j = first; j < last; j++)
     22410                tp->Strings[j] = tp->Strings[j + 1];
     22411-           tp->ext_Strings -= 1;
     22412-           tp->num_Strings -= 1;
     22413+           tp->ext_Strings--;
     22414+           tp->num_Strings--;
     22415            break;
     22416        }
     22417        return TRUE;
     22418@@ -307,22 +307,22 @@
     22419 
     22420     switch (token_type) {
     22421     case BOOLEAN:
     22422-       tp->ext_Booleans += 1;
     22423-       tp->num_Booleans += 1;
     22424+       tp->ext_Booleans++;
     22425+       tp->num_Booleans++;
     22426        tp->Booleans = typeRealloc(NCURSES_SBOOL, tp->num_Booleans, tp->Booleans);
     22427        for (k = tp->num_Booleans - 1; k > j; k--)
     22428            tp->Booleans[k] = tp->Booleans[k - 1];
     22429        break;
     22430     case NUMBER:
     22431-       tp->ext_Numbers += 1;
     22432-       tp->num_Numbers += 1;
     22433+       tp->ext_Numbers++;
     22434+       tp->num_Numbers++;
     22435        tp->Numbers = typeRealloc(short, tp->num_Numbers, tp->Numbers);
     22436        for (k = tp->num_Numbers - 1; k > j; k--)
     22437            tp->Numbers[k] = tp->Numbers[k - 1];
     22438        break;
     22439     case STRING:
     22440-       tp->ext_Strings += 1;
     22441-       tp->num_Strings += 1;
     22442+       tp->ext_Strings++;
     22443+       tp->num_Strings++;
     22444        tp->Strings = typeRealloc(char *, tp->num_Strings, tp->Strings);
     22445        for (k = tp->num_Strings - 1; k > j; k--)
     22446            tp->Strings[k] = tp->Strings[k - 1];
     22447@@ -345,7 +345,7 @@
     22448 
     22449     for (j = first; j < last;) {
     22450        char *name = to->ext_Names[j];
     22451-       unsigned j_str = to->num_Strings - first - to->ext_Strings;
     22452+       int j_str = to->num_Strings - first - to->ext_Strings;
     22453 
     22454        if (to->Strings[j + j_str] == CANCELLED_STRING) {
     22455            if ((k = _nc_find_ext_name(from, to->ext_Names[j], BOOLEAN)) >= 0) {
     22456diff -Naur ncurses-5.7.orig/ncurses/tinfo/captoinfo.c ncurses-5.7/ncurses/tinfo/captoinfo.c
     22457--- ncurses-5.7.orig/ncurses/tinfo/captoinfo.c  2008-08-16 12:24:51.000000000 -0700
     22458+++ ncurses-5.7/ncurses/tinfo/captoinfo.c       2009-06-05 14:01:30.000000000 -0700
     22459@@ -1,5 +1,5 @@
     22460 /****************************************************************************
     22461- * Copyright (c) 1998-2006,2008 Free Software Foundation, Inc.              *
     22462+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     22463  *                                                                          *
     22464  * Permission is hereby granted, free of charge, to any person obtaining a  *
     22465  * copy of this software and associated documentation files (the            *
     22466@@ -93,7 +93,7 @@
     22467 #include <ctype.h>
     22468 #include <tic.h>
     22469 
     22470-MODULE_ID("$Id: captoinfo.c,v 1.52 2008/08/16 19:24:51 tom Exp $")
     22471+MODULE_ID("$Id: captoinfo.c,v 1.53 2009/03/28 20:44:23 tom Exp $")
     22472 
     22473 #define MAX_PUSHED     16      /* max # args we can push onto the stack */
     22474 
     22475@@ -128,7 +128,7 @@
     22476     size_t have = (d - my_string);
     22477     size_t need = have + strlen(s) + 2;
     22478     if (need > my_length) {
     22479-       my_string = (char *) realloc(my_string, my_length = (need + need));
     22480+       my_string = (char *) _nc_doalloc(my_string, my_length = (need + need));
     22481        if (my_string == 0)
     22482            _nc_err_abort(MSG_NO_MEMORY);
     22483        d = my_string + have;
     22484diff -Naur ncurses-5.7.orig/ncurses/tinfo/comp_scan.c ncurses-5.7/ncurses/tinfo/comp_scan.c
     22485--- ncurses-5.7.orig/ncurses/tinfo/comp_scan.c  2008-08-16 12:22:55.000000000 -0700
     22486+++ ncurses-5.7/ncurses/tinfo/comp_scan.c       2009-06-05 14:01:51.000000000 -0700
     22487@@ -51,7 +51,7 @@
     22488 #include <term_entry.h>
     22489 #include <tic.h>
     22490 
     22491-MODULE_ID("$Id: comp_scan.c,v 1.83 2008/08/16 19:22:55 tom Exp $")
     22492+MODULE_ID("$Id: comp_scan.c,v 1.84 2009/05/09 16:37:42 tom Exp $")
     22493 
     22494 /*
     22495  * Maximum length of string capability we'll accept before raising an error.
     22496@@ -61,19 +61,13 @@
     22497 
     22498 #define iswhite(ch)    (ch == ' '  ||  ch == '\t')
     22499 
     22500-NCURSES_EXPORT_VAR(int)
     22501-_nc_syntax = 0;                        /* termcap or terminfo? */
     22502-NCURSES_EXPORT_VAR(long)
     22503-_nc_curr_file_pos = 0;         /* file offset of current line */
     22504-NCURSES_EXPORT_VAR(long)
     22505-_nc_comment_start = 0;         /* start of comment range before name */
     22506-NCURSES_EXPORT_VAR(long)
     22507-_nc_comment_end = 0;           /* end of comment range before name */
     22508-NCURSES_EXPORT_VAR(long)
     22509-_nc_start_line = 0;            /* start line of current entry */
     22510+NCURSES_EXPORT_VAR (int) _nc_syntax = 0;         /* termcap or terminfo? */
     22511+NCURSES_EXPORT_VAR (long) _nc_curr_file_pos = 0; /* file offset of current line */
     22512+NCURSES_EXPORT_VAR (long) _nc_comment_start = 0; /* start of comment range before name */
     22513+NCURSES_EXPORT_VAR (long) _nc_comment_end = 0;   /* end of comment range before name */
     22514+NCURSES_EXPORT_VAR (long) _nc_start_line = 0;    /* start line of current entry */
     22515 
     22516-NCURSES_EXPORT_VAR(struct token)
     22517-_nc_curr_token =
     22518+NCURSES_EXPORT_VAR (struct token) _nc_curr_token =
     22519 {
     22520     0, 0, 0
     22521 };
     22522@@ -91,8 +85,7 @@
     22523 static char *pushname;
     22524 
     22525 #if NCURSES_EXT_FUNCS
     22526-NCURSES_EXPORT_VAR(bool)
     22527-_nc_disable_period = FALSE;    /* used by tic -a option */
     22528+NCURSES_EXPORT_VAR (bool) _nc_disable_period = FALSE; /* used by tic -a option */
     22529 #endif
     22530 
     22531 /*****************************************************************************
     22532@@ -637,7 +630,8 @@
     22533                /* just to get rid of the compiler warning */
     22534                type = UNDEF;
     22535                if (!silent)
     22536-                   _nc_warning("Illegal character - '%s'", unctrl((chtype) ch));
     22537+                   _nc_warning("Illegal character - '%s'",
     22538+                               unctrl((chtype) ch));
     22539            }
     22540        }                       /* end else (first_column == FALSE) */
     22541     }                          /* end else (ch != EOF) */
    1837922542diff -Naur ncurses-5.7.orig/ncurses/tinfo/entries.c ncurses-5.7/ncurses/tinfo/entries.c
    1838022543--- ncurses-5.7.orig/ncurses/tinfo/entries.c    2008-09-27 06:11:10.000000000 -0700
    18381 +++ ncurses-5.7/ncurses/tinfo/entries.c 2009-02-28 20:38:39.770130185 -0800
     22544+++ ncurses-5.7/ncurses/tinfo/entries.c 2009-06-05 14:01:21.000000000 -0700
     22545@@ -1,5 +1,5 @@
     22546 /****************************************************************************
     22547- * Copyright (c) 2006-2007,2008 Free Software Foundation, Inc.              *
     22548+ * Copyright (c) 2006-2008,2009 Free Software Foundation, Inc.              *
     22549  *                                                                          *
     22550  * Permission is hereby granted, free of charge, to any person obtaining a  *
     22551  * copy of this software and associated documentation files (the            *
    1838222552@@ -37,7 +37,7 @@
    1838322553 #include <tic.h>
     
    1838522555 
    1838622556-MODULE_ID("$Id: entries.c,v 1.8 2008/09/27 13:11:10 tom Exp $")
    18387 +MODULE_ID("$Id: entries.c,v 1.10 2008/12/07 00:11:45 tom Exp $")
     22557+MODULE_ID("$Id: entries.c,v 1.11 2009/03/14 15:22:37 tom Exp $")
    1838822558 
    1838922559 /****************************************************************************
    1839022560  *
    18391 @@ -117,6 +117,9 @@
    18392  
    18393      T((T_CALLED("_nc_free_tinfo()")));
     22561@@ -119,6 +119,10 @@
    1839422562 #if NO_LEAKS
     22563     _nc_free_tparm();
     22564     _nc_tgetent_leaks();
     22565+
    1839522566+    if (cur_term != 0)
    1839622567+       del_curterm(cur_term);
    1839722568+
    18398      _nc_free_tparm();
    18399      _nc_tgetent_leaks();
    1840022569     _nc_free_entries(_nc_head);
     22570     _nc_get_type(0);
     22571     _nc_first_name(0);
    1840122572diff -Naur ncurses-5.7.orig/ncurses/tinfo/hashed_db.c ncurses-5.7/ncurses/tinfo/hashed_db.c
    1840222573--- ncurses-5.7.orig/ncurses/tinfo/hashed_db.c  2006-08-19 12:48:38.000000000 -0700
    18403 +++ ncurses-5.7/ncurses/tinfo/hashed_db.c       2009-02-28 20:38:41.374231037 -0800
     22574+++ ncurses-5.7/ncurses/tinfo/hashed_db.c       2009-06-05 14:00:57.000000000 -0700
    1840422575@@ -1,5 +1,5 @@
    1840522576 /****************************************************************************
     
    1850522676 }
    1850622677 
    18507 diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_baudrate.c ncurses-5.7/ncurses/tinfo/lib_baudrate.c
    18508 --- ncurses-5.7.orig/ncurses/tinfo/lib_baudrate.c       2008-06-28 08:19:24.000000000 -0700
    18509 +++ ncurses-5.7/ncurses/tinfo/lib_baudrate.c    2009-02-28 20:38:57.055236206 -0800
     22678diff -Naur ncurses-5.7.orig/ncurses/tinfo/init_keytry.c ncurses-5.7/ncurses/tinfo/init_keytry.c
     22679--- ncurses-5.7.orig/ncurses/tinfo/init_keytry.c        2008-05-24 14:44:51.000000000 -0700
     22680+++ ncurses-5.7/ncurses/tinfo/init_keytry.c     2009-06-05 14:01:51.000000000 -0700
     22681@@ -1,5 +1,5 @@
     22682 /****************************************************************************
     22683- * Copyright (c) 1999-2006,2008 Free Software Foundation, Inc.              *
     22684+ * Copyright (c) 1999-2008,2009 Free Software Foundation, Inc.              *
     22685  *                                                                          *
     22686  * Permission is hereby granted, free of charge, to any person obtaining a  *
     22687  * copy of this software and associated documentation files (the            *
     22688@@ -27,16 +27,11 @@
     22689  ****************************************************************************/
     22690 
     22691 #include <curses.priv.h>
     22692-
     22693-#include <term.h>
     22694-/* keypad_xmit, keypad_local, meta_on, meta_off */
     22695-/* cursor_visible,cursor_normal,cursor_invisible */
     22696-
     22697 #include <tic.h>               /* struct tinfo_fkeys */
     22698 
     22699 #include <term_entry.h>
     22700 
     22701-MODULE_ID("$Id: init_keytry.c,v 1.12 2008/05/24 21:44:51 tom Exp $")
     22702+MODULE_ID("$Id: init_keytry.c,v 1.14 2009/05/10 00:48:29 tom Exp $")
     22703 
     22704 /*
     22705 **      _nc_init_keytry()
     22706@@ -50,7 +45,7 @@
     22707  * than cur_term.
     22708  */
     22709 #undef CUR
     22710-#define CUR (sp->_term)->type.
     22711+#define CUR SP_TERMTYPE
     22712 
     22713 #if    BROKEN_LINKER
     22714 #undef _nc_tinfo_fkeys
     22715@@ -102,7 +97,8 @@
     22716                if (name != 0
     22717                    && *name == 'k'
     22718                    && value != 0
     22719-                   && key_defined(value) == 0) {
     22720+                   && NCURSES_SP_NAME(key_defined) (NCURSES_SP_ARGx
     22721+                                                    value) == 0) {
     22722                    (void) _nc_add_to_try(&(sp->_keytry),
     22723                                          value,
     22724                                          n - STRCOUNT + KEY_MAX);
     22725diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_acs.c ncurses-5.7/ncurses/tinfo/lib_acs.c
     22726--- ncurses-5.7.orig/ncurses/tinfo/lib_acs.c    2008-08-16 12:22:55.000000000 -0700
     22727+++ ncurses-5.7/ncurses/tinfo/lib_acs.c 2009-06-05 14:01:51.000000000 -0700
    1851022728@@ -1,5 +1,5 @@
    1851122729 /****************************************************************************
     
    1851522733  * Permission is hereby granted, free of charge, to any person obtaining a  *
    1851622734  * copy of this software and associated documentation files (the            *
    18517 @@ -80,7 +80,7 @@
     22735@@ -35,12 +35,16 @@
     22736 #include <curses.priv.h>
     22737 #include <term.h>              /* ena_acs, acs_chars */
     22738 
     22739-MODULE_ID("$Id: lib_acs.c,v 1.36 2008/08/16 19:22:55 tom Exp $")
     22740+#ifndef CUR
     22741+#define CUR SP_TERMTYPE
     22742+#endif
     22743+
     22744+MODULE_ID("$Id: lib_acs.c,v 1.39 2009/05/10 00:48:29 tom Exp $")
     22745 
     22746 #if BROKEN_LINKER || USE_REENTRANT
     22747 #define MyBuffer _nc_prescreen.real_acs_map
     22748-NCURSES_EXPORT_VAR(chtype *)
     22749-_nc_acs_map(void)
     22750+NCURSES_EXPORT(chtype *)
     22751+NCURSES_PUBLIC_VAR(acs_map) (void)
     22752 {
     22753     if (MyBuffer == 0)
     22754        MyBuffer = typeCalloc(chtype, ACS_LEN);
     22755@@ -48,7 +52,7 @@
     22756 }
     22757 #undef MyBuffer
     22758 #else
     22759-NCURSES_EXPORT_VAR(chtype) acs_map[ACS_LEN] =
     22760+NCURSES_EXPORT_VAR (chtype) acs_map[ACS_LEN] =
     22761 {
     22762     0
     22763 };
     22764@@ -57,6 +61,9 @@
     22765 NCURSES_EXPORT(void)
     22766 _nc_init_acs(void)
     22767 {
     22768+#if NCURSES_SP_FUNCS
     22769+    SCREEN *sp = CURRENT_SCREEN;
     22770+#endif
     22771     chtype *fake_map = acs_map;
     22772     chtype *real_map = SP != 0 ? SP->_acs_map : fake_map;
     22773     int j;
     22774diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_baudrate.c ncurses-5.7/ncurses/tinfo/lib_baudrate.c
     22775--- ncurses-5.7.orig/ncurses/tinfo/lib_baudrate.c       2008-06-28 08:19:24.000000000 -0700
     22776+++ ncurses-5.7/ncurses/tinfo/lib_baudrate.c    2009-06-05 14:01:51.000000000 -0700
     22777@@ -1,5 +1,5 @@
     22778 /****************************************************************************
     22779- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     22780+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     22781  *                                                                          *
     22782  * Permission is hereby granted, free of charge, to any person obtaining a  *
     22783  * copy of this software and associated documentation files (the            *
     22784@@ -38,7 +38,6 @@
     22785  */
     22786 
     22787 #include <curses.priv.h>
     22788-#include <term.h>              /* cur_term, pad_char */
     22789 #include <termcap.h>           /* ospeed */
     22790 #if defined(__FreeBSD__)
     22791 #include <sys/param.h>
     22792@@ -80,7 +79,7 @@
    1851822793 #undef USE_OLD_TTY
    1851922794 #endif /* USE_OLD_TTY */
    1852022795 
    1852122796-MODULE_ID("$Id: lib_baudrate.c,v 1.27 2008/06/28 15:19:24 tom Exp $")
    18522 +MODULE_ID("$Id: lib_baudrate.c,v 1.28 2009/02/14 21:41:22 tom Exp $")
     22797+MODULE_ID("$Id: lib_baudrate.c,v 1.29 2009/02/21 17:22:13 tom Exp $")
    1852322798 
    1852422799 /*
    1852522800  *     int
    18526 @@ -195,7 +195,7 @@
     22801@@ -195,11 +194,11 @@
    1852722802 }
    1852822803 
     
    1853322808     int result;
    1853422809 
    18535 @@ -207,7 +207,7 @@
     22810-    T((T_CALLED("baudrate()")));
     22811+    T((T_CALLED("baudrate(%p)"), SP_PARM));
     22812 
     22813     /*
     22814      * In debugging, allow the environment symbol to override when we're
     22815@@ -207,7 +206,8 @@
    1853622816      * that take into account costs that depend on baudrate.
    1853722817      */
    1853822818 #ifdef TRACE
    1853922819-    if (!isatty(fileno(SP ? SP->_ofp : stdout))
    18540 +    if (!isatty(fileno(SP_PARM ? SP_PARM->_ofp : stdout))
     22820+    if (IsValidTIScreen(SP_PARM)
     22821+       && !isatty(fileno(SP_PARM ? SP_PARM->_ofp : stdout))
    1854122822        && getenv("BAUDRATE") != 0) {
    1854222823        int ret;
    1854322824        if ((ret = _nc_getenv_num("BAUDRATE")) <= 0)
    18544 @@ -236,3 +236,11 @@
     22825@@ -217,22 +217,30 @@
     22826     }
     22827 #endif
     22828 
     22829-    if (cur_term != 0) {
     22830+    if (IsValidTIScreen(SP_PARM)) {
     22831 #ifdef USE_OLD_TTY
     22832-       result = cfgetospeed(&cur_term->Nttyb);
     22833+       result = cfgetospeed(&(TerminalOf(SP_PARM)->Nttyb));
     22834        ospeed = _nc_ospeed(result);
     22835 #else /* !USE_OLD_TTY */
     22836 #ifdef TERMIOS
     22837-       ospeed = cfgetospeed(&cur_term->Nttyb);
     22838+       ospeed = cfgetospeed(&(TerminalOf(SP_PARM)->Nttyb));
     22839 #else
     22840-       ospeed = cur_term->Nttyb.sg_ospeed;
     22841+       ospeed = TerminalOf(SP_PARM)->Nttyb.sg_ospeed;
     22842 #endif
     22843        result = _nc_baudrate(ospeed);
     22844 #endif
     22845-       cur_term->_baudrate = result;
     22846+       TerminalOf(SP_PARM)->_baudrate = result;
     22847     } else {
     22848        result = ERR;
     22849     }
    1854522850 
    1854622851     returnCode(result);
     
    1855622861diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_cur_term.c ncurses-5.7/ncurses/tinfo/lib_cur_term.c
    1855722862--- ncurses-5.7.orig/ncurses/tinfo/lib_cur_term.c       2008-08-16 12:22:55.000000000 -0700
    18558 +++ ncurses-5.7/ncurses/tinfo/lib_cur_term.c    2009-02-28 20:38:59.859415560 -0800
     22863+++ ncurses-5.7/ncurses/tinfo/lib_cur_term.c    2009-06-05 14:01:55.000000000 -0700
    1855922864@@ -1,5 +1,5 @@
    1856022865 /****************************************************************************
     
    1856922874 
    1857022875-MODULE_ID("$Id: lib_cur_term.c,v 1.18 2008/08/16 19:22:55 tom Exp $")
    18571 +MODULE_ID("$Id: lib_cur_term.c,v 1.19 2009/02/28 15:49:58 tom Exp $")
     22876+MODULE_ID("$Id: lib_cur_term.c,v 1.22 2009/05/30 13:55:19 tom Exp $")
    1857222877 
    1857322878 #undef CUR
     
    1858122886 NCURSES_PUBLIC_VAR(cur_term) (void)
    1858222887 {
     22888@@ -66,7 +68,9 @@
     22889     oldterm = cur_term;
     22890     if (SP)
     22891        SP->_term = termp;
     22892-#if BROKEN_LINKER || USE_REENTRANT
     22893+#if BROKEN_LINKER && !USE_REENTRANT
     22894+    cur_term = termp;
     22895+#elif BROKEN_LINKER || USE_REENTRANT
     22896     _nc_prescreen._cur_term = termp;
     22897 #else
     22898     cur_term = termp;
     22899@@ -84,7 +88,7 @@
     22900 }
     22901 
     22902 NCURSES_EXPORT(int)
     22903-del_curterm(TERMINAL * termp)
     22904+NCURSES_SP_NAME(del_curterm) (NCURSES_SP_DCLx TERMINAL * termp)
     22905 {
     22906     int rc = ERR;
     22907 
     22908@@ -94,6 +98,10 @@
     22909     if (termp != 0) {
     22910        _nc_free_termtype(&(termp->type));
     22911        FreeIfNeeded(termp->_termname);
     22912+#if USE_HOME_TERMINFO
     22913+       if (_nc_globals.home_terminfo != 0)
     22914+           FreeAndNull(_nc_globals.home_terminfo);
     22915+#endif
     22916        free(termp);
     22917        if (termp == cur_term)
     22918            set_curterm(0);
     22919@@ -103,3 +111,13 @@
     22920 
     22921     returnCode(rc);
     22922 }
     22923+
     22924+#if NCURSES_SP_FUNCS
     22925+NCURSES_EXPORT(int)
     22926+del_curterm(TERMINAL * termp)
     22927+{
     22928+    int rc = ERR;
     22929+    rc = NCURSES_SP_NAME(del_curterm) (CURRENT_SCREEN, termp);
     22930+    return (rc);
     22931+}
     22932+#endif
     22933diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_data.c ncurses-5.7/ncurses/tinfo/lib_data.c
     22934--- ncurses-5.7.orig/ncurses/tinfo/lib_data.c   2008-08-23 15:16:15.000000000 -0700
     22935+++ ncurses-5.7/ncurses/tinfo/lib_data.c        2009-06-05 14:01:55.000000000 -0700
     22936@@ -1,5 +1,5 @@
     22937 /****************************************************************************
     22938- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     22939+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     22940  *                                                                          *
     22941  * Permission is hereby granted, free of charge, to any person obtaining a  *
     22942  * copy of this software and associated documentation files (the            *
     22943@@ -41,7 +41,7 @@
     22944 
     22945 #include <curses.priv.h>
     22946 
     22947-MODULE_ID("$Id: lib_data.c,v 1.52 2008/08/23 22:16:15 tom Exp $")
     22948+MODULE_ID("$Id: lib_data.c,v 1.53 2009/05/30 15:59:25 tom Exp $")
     22949 
     22950 /*
     22951  * OS/2's native linker complains if we don't initialize public data when
     22952@@ -225,6 +225,8 @@
     22953     NULL,                      /* real_acs_map */
     22954     0,                         /* LINES */
     22955     0,                         /* COLS */
     22956+    8,                         /* TABSIZE */
     22957+    1000,                      /* ESCDELAY */
     22958     0,                         /* cur_term */
     22959 #ifdef TRACE
     22960     0L,                                /* _outchars */
    1858322961diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_has_cap.c ncurses-5.7/ncurses/tinfo/lib_has_cap.c
    1858422962--- ncurses-5.7.orig/ncurses/tinfo/lib_has_cap.c        2003-10-25 12:43:55.000000000 -0700
    18585 +++ ncurses-5.7/ncurses/tinfo/lib_has_cap.c     2009-02-28 20:38:57.055236206 -0800
     22963+++ ncurses-5.7/ncurses/tinfo/lib_has_cap.c     2009-06-05 14:01:51.000000000 -0700
    1858622964@@ -1,5 +1,5 @@
    1858722965 /****************************************************************************
     
    1859922977 
    1860022978 /*
    18601 @@ -43,10 +44,10 @@
    18602  
    18603  #include <term.h>
     22979@@ -41,25 +42,53 @@
     22980 
     22981 #include <curses.priv.h>
     22982 
     22983-#include <term.h>
     22984+#ifndef CUR
     22985+#define CUR SP_TERMTYPE
     22986+#endif
    1860422987 
    1860522988-MODULE_ID("$Id: lib_has_cap.c,v 1.4 2003/10/25 19:43:55 tom Exp $")
    18606 +MODULE_ID("$Id: lib_has_cap.c,v 1.5 2009/02/15 00:47:12 tom Exp $")
     22989+MODULE_ID("$Id: lib_has_cap.c,v 1.8 2009/05/10 00:53:52 tom Exp $")
    1860722990 
    1860822991 NCURSES_EXPORT(bool)
    18609 -has_ic(void)
    1861022992+NCURSES_SP_NAME(has_ic) (NCURSES_SP_DCL0)
     22993+{
     22994+    bool code = FALSE;
     22995+
     22996+    T((T_CALLED("has_ic(%p)"), SP_PARM));
     22997+
     22998+    if (IsValidTIScreen(SP_PARM) && IsTermInfo(SP_PARM)) {
     22999+       code = ((insert_character || parm_ich
     23000+                || (enter_insert_mode && exit_insert_mode))
     23001+               && (delete_character || parm_dch)) ? TRUE : FALSE;
     23002+    }
     23003+
     23004+    returnCode(code);
     23005+}
     23006+
     23007+#if NCURSES_SP_FUNCS
     23008+NCURSES_EXPORT(bool)
     23009 has_ic(void)
    1861123010 {
    18612      T((T_CALLED("has_ic()")));
    18613      returnCode(cur_term &&
    18614 @@ -55,11 +56,27 @@
    18615                && (delete_character || parm_dch));
    18616  }
    18617  
    18618 +#if NCURSES_SP_FUNCS
    18619  NCURSES_EXPORT(bool)
    18620 -has_il(void)
    18621 +has_ic(void)
    18622 +{
     23011-    T((T_CALLED("has_ic()")));
     23012-    returnCode(cur_term &&
     23013-              (insert_character || parm_ich
     23014-               || (enter_insert_mode && exit_insert_mode))
     23015-              && (delete_character || parm_dch));
    1862323016+    return NCURSES_SP_NAME(has_ic) (CURRENT_SCREEN);
    1862423017+}
     
    1862723020+NCURSES_EXPORT(bool)
    1862823021+NCURSES_SP_NAME(has_il) (NCURSES_SP_DCL0)
     23022+{
     23023+    bool code = FALSE;
     23024+    T((T_CALLED("has_il(%p)"), SP_PARM));
     23025+    if (IsValidTIScreen(SP_PARM) && IsTermInfo(SP_PARM)) {
     23026+       code = ((insert_line || parm_insert_line)
     23027+               && (delete_line || parm_delete_line)) ? TRUE : FALSE;
     23028+    }
     23029+
     23030+    returnCode(code);
     23031 }
     23032 
     23033+#if NCURSES_SP_FUNCS
     23034 NCURSES_EXPORT(bool)
     23035 has_il(void)
    1862923036 {
    18630      T((T_CALLED("has_il()")));
    18631      returnCode(cur_term
    18632                && (insert_line || parm_insert_line)
    18633                && (delete_line || parm_delete_line));
     23037-    T((T_CALLED("has_il()")));
     23038-    returnCode(cur_term
     23039-              && (insert_line || parm_insert_line)
     23040-              && (delete_line || parm_delete_line));
     23041+    return NCURSES_SP_NAME(has_il) (CURRENT_SCREEN);
    1863423042 }
    18635 +
    18636 +#if NCURSES_SP_FUNCS
    18637 +NCURSES_EXPORT(bool)
    18638 +has_il(void)
    18639 +{
    18640 +    return NCURSES_SP_NAME(has_il) (CURRENT_SCREEN);
    18641 +}
    1864223043+#endif
    1864323044diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_kernel.c ncurses-5.7/ncurses/tinfo/lib_kernel.c
    1864423045--- ncurses-5.7.orig/ncurses/tinfo/lib_kernel.c 2004-05-08 10:11:21.000000000 -0700
    18645 +++ ncurses-5.7/ncurses/tinfo/lib_kernel.c      2009-02-28 20:38:57.055236206 -0800
     23046+++ ncurses-5.7/ncurses/tinfo/lib_kernel.c      2009-06-05 14:01:14.000000000 -0700
    1864623047@@ -1,5 +1,5 @@
    1864723048 /****************************************************************************
     
    1875423155diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_longname.c ncurses-5.7/ncurses/tinfo/lib_longname.c
    1875523156--- ncurses-5.7.orig/ncurses/tinfo/lib_longname.c       2000-12-09 18:55:07.000000000 -0800
    18756 +++ ncurses-5.7/ncurses/tinfo/lib_longname.c    2009-02-28 20:38:57.055236206 -0800
     23157+++ ncurses-5.7/ncurses/tinfo/lib_longname.c    2009-06-05 14:01:51.000000000 -0700
    1875723158@@ -1,5 +1,5 @@
    1875823159 /****************************************************************************
     
    1877123172 
    1877223173 /*
    18773 @@ -40,10 +42,10 @@
     23174@@ -40,8 +42,38 @@
    1877423175 
    1877523176 #include <curses.priv.h>
    1877623177 
    1877723178-MODULE_ID("$Id: lib_longname.c,v 1.9 2000/12/10 02:55:07 tom Exp $")
    18778 +MODULE_ID("$Id: lib_longname.c,v 1.10 2009/02/15 00:48:15 tom Exp $")
    18779  
    18780  NCURSES_EXPORT(char *)
    18781 -longname(void)
     23179+MODULE_ID("$Id: lib_longname.c,v 1.11 2009/02/21 17:18:02 tom Exp $")
     23180 
     23181+#if USE_REENTRANT
     23182+NCURSES_EXPORT(char *)
    1878223183+NCURSES_SP_NAME(longname) (NCURSES_SP_DCL0)
    18783  {
    18784      char *ptr;
    18785  
    18786 @@ -55,3 +57,11 @@
    18787  
    18788      returnPtr(ttytype);
    18789  }
     23184+{
     23185+    static char empty[] =
     23186+    {'\0'};
     23187+    char *ptr;
     23188+
     23189+    T((T_CALLED("longname(%p)"), SP_PARM));
     23190+
     23191+    if (SP_PARM) {
     23192+       for (ptr = SP_PARM->_ttytype + strlen(SP_PARM->_ttytype);
     23193+            ptr > SP_PARM->_ttytype;
     23194+            ptr--)
     23195+           if (*ptr == '|')
     23196+               returnPtr(ptr + 1);
     23197+       returnPtr(SP_PARM->_ttytype);
     23198+    }
     23199+    return empty;
     23200+}
    1879023201+
    1879123202+#if NCURSES_SP_FUNCS
     
    1879623207+}
    1879723208+#endif
     23209+
     23210+#else
     23211 NCURSES_EXPORT(char *)
     23212 longname(void)
     23213 {
     23214@@ -49,9 +81,11 @@
     23215 
     23216     T((T_CALLED("longname()")));
     23217 
     23218-    for (ptr = ttytype + strlen(ttytype); ptr > ttytype; ptr--)
     23219+    for (ptr = ttytype + strlen(ttytype);
     23220+        ptr > ttytype;
     23221+        ptr--)
     23222        if (*ptr == '|')
     23223            returnPtr(ptr + 1);
     23224-
     23225     returnPtr(ttytype);
     23226 }
     23227+#endif
    1879823228diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_napms.c ncurses-5.7/ncurses/tinfo/lib_napms.c
    1879923229--- ncurses-5.7.orig/ncurses/tinfo/lib_napms.c  2008-05-03 14:34:13.000000000 -0700
    18800 +++ ncurses-5.7/ncurses/tinfo/lib_napms.c       2009-02-28 20:38:57.055236206 -0800
     23230+++ ncurses-5.7/ncurses/tinfo/lib_napms.c       2009-06-05 14:01:14.000000000 -0700
    1880123231@@ -1,5 +1,5 @@
    1880223232 /****************************************************************************
     
    1884223272diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_options.c ncurses-5.7/ncurses/tinfo/lib_options.c
    1884323273--- ncurses-5.7.orig/ncurses/tinfo/lib_options.c        2008-08-16 14:20:48.000000000 -0700
    18844 +++ ncurses-5.7/ncurses/tinfo/lib_options.c     2009-02-28 20:38:59.859415560 -0800
     23274+++ ncurses-5.7/ncurses/tinfo/lib_options.c     2009-06-05 14:01:54.000000000 -0700
    1884523275@@ -1,5 +1,5 @@
    1884623276 /****************************************************************************
     
    1885823288 
    1885923289 /*
    18860 @@ -43,7 +44,7 @@
     23290@@ -43,14 +44,20 @@
    1886123291 
    1886223292 #include <term.h>
    1886323293 
    1886423294-MODULE_ID("$Id: lib_options.c,v 1.58 2008/08/16 21:20:48 Werner.Fink Exp $")
    18865 +MODULE_ID("$Id: lib_options.c,v 1.60 2009/02/28 21:07:56 tom Exp $")
    18866  
    18867  static int _nc_curs_set(SCREEN *, int);
     23295+#ifndef CUR
     23296+#define CUR SP_TERMTYPE
     23297+#endif
     23298+
     23299+MODULE_ID("$Id: lib_options.c,v 1.64 2009/05/23 23:58:07 tom Exp $")
     23300 
     23301-static int _nc_curs_set(SCREEN *, int);
    1886823302 static int _nc_meta(SCREEN *, bool);
    18869 @@ -72,18 +73,26 @@
     23303 
     23304 NCURSES_EXPORT(int)
     23305 idlok(WINDOW *win, bool flag)
     23306 {
     23307+#if NCURSES_SP_FUNCS
     23308+    SCREEN *sp = CURRENT_SCREEN;
     23309+#endif
     23310     T((T_CALLED("idlok(%p,%d)"), win, flag));
     23311 
     23312     if (win) {
     23313@@ -72,18 +79,26 @@
    1887023314 }
    1887123315 
     
    1889723341 nodelay(WINDOW *win, bool flag)
    1889823342 {
    18899 @@ -158,17 +167,25 @@
     23343@@ -148,27 +163,64 @@
     23344 /* curs_set() moved here to narrow the kernel interface */
     23345 
     23346 NCURSES_EXPORT(int)
     23347-curs_set(int vis)
     23348+NCURSES_SP_NAME(curs_set) (NCURSES_SP_DCLx int vis)
     23349 {
     23350-    int result;
     23351+    int result = ERR;
     23352+
     23353+    T((T_CALLED("curs_set(%p,%d)"), SP_PARM, vis));
     23354+    if (SP_PARM != 0 && vis >= 0 && vis <= 2) {
     23355+       int cursor = SP_PARM->_cursor;
     23356 
     23357-    T((T_CALLED("curs_set(%d)"), vis));
     23358-    result = _nc_curs_set(SP, vis);
     23359+       if (vis == cursor) {
     23360+           result = cursor;
     23361+       } else {
     23362+           switch (vis) {
     23363+           case 2:
     23364+               result = _nc_putp_flush("cursor_visible", cursor_visible);
     23365+               break;
     23366+           case 1:
     23367+               result = _nc_putp_flush("cursor_normal", cursor_normal);
     23368+               break;
     23369+           case 0:
     23370+               result = _nc_putp_flush("cursor_invisible", cursor_invisible);
     23371+               break;
     23372+           }
     23373+           if (result != ERR)
     23374+               result = (cursor == -1 ? 1 : cursor);
     23375+           SP_PARM->_cursor = vis;
     23376+       }
     23377+    }
     23378     returnCode(result);
    1890023379 }
    1890123380 
     23381+#if NCURSES_SP_FUNCS
    1890223382 NCURSES_EXPORT(int)
    1890323383-typeahead(int fd)
     23384+curs_set(int vis)
     23385+{
     23386+    return (NCURSES_SP_NAME(curs_set) (CURRENT_SCREEN, vis));
     23387+}
     23388+#endif
     23389+
     23390+NCURSES_EXPORT(int)
    1890423391+NCURSES_SP_NAME(typeahead) (NCURSES_SP_DCLx int fd)
    1890523392 {
     
    1892623413 **      has_key()
    1892723414 **
    18928 @@ -204,8 +221,9 @@
     23415@@ -190,11 +242,19 @@
     23416 }
     23417 
     23418 NCURSES_EXPORT(int)
     23419+NCURSES_SP_NAME(has_key) (NCURSES_SP_DCLx int keycode)
     23420+{
     23421+    T((T_CALLED("has_key(%p,%d)"), SP_PARM, keycode));
     23422+    returnCode(SP != 0 ? has_key_internal(keycode, SP_PARM->_keytry) : FALSE);
     23423+}
     23424+
     23425+#if NCURSES_SP_FUNCS
     23426+NCURSES_EXPORT(int)
     23427 has_key(int keycode)
     23428 {
     23429-    T((T_CALLED("has_key(%d)"), keycode));
     23430-    returnCode(SP != 0 ? has_key_internal(keycode, SP->_keytry) : FALSE);
     23431+    return NCURSES_SP_NAME(has_key) (CURRENT_SCREEN, keycode);
     23432 }
     23433+#endif
     23434 #endif /* NCURSES_EXT_FUNCS */
     23435 
     23436 /*
     23437@@ -202,29 +262,26 @@
     23438  * than cur_term.
     23439  */
    1892923440 #undef CUR
    18930  #define CUR (sp->_term)->type.
     23441-#define CUR (sp->_term)->type.
     23442+#define CUR SP_TERMTYPE
    1893123443 
    1893223444-static int
    1893323445-_nc_putp(const char *name GCC_UNUSED, const char *value)
    18934 +NCURSES_EXPORT(int)
    18935 +NCURSES_SP_NAME(_nc_putp) (NCURSES_SP_DCLx
    18936 +                          const char *name GCC_UNUSED, const char *value)
    18937  {
    18938      int rc = ERR;
    18939  
    18940 @@ -216,8 +234,17 @@
    18941      return rc;
    18942  }
    18943  
    18944 -static int
    18945 -_nc_putp_flush(const char *name, const char *value)
    18946 +#if NCURSES_SP_FUNCS
    18947 +NCURSES_EXPORT(int)
    18948 +_nc_putp(const char *name, const char *value)
    18949 +{
    18950 +    return NCURSES_SP_NAME(_nc_putp) (CURRENT_SCREEN, name, value);
    18951 +}
    18952 +#endif
    18953 +
    1895423446+NCURSES_EXPORT(int)
    1895523447+NCURSES_SP_NAME(_nc_putp_flush) (NCURSES_SP_DCLx
    1895623448+                                const char *name, const char *value)
    1895723449 {
    18958      int rc = _nc_putp(name, value);
    18959      if (rc != ERR) {
    18960 @@ -226,6 +253,14 @@
     23450-    int rc = ERR;
     23451-
     23452-    if (value) {
     23453-       TPUTS_TRACE(name);
     23454-       rc = putp(value);
     23455+    int rc = _nc_putp(name, value);
     23456+    if (rc != ERR) {
     23457+       _nc_flush();
     23458     }
    1896123459     return rc;
    1896223460 }
    1896323461 
     23462-static int
    1896423463+#if NCURSES_SP_FUNCS
    1896523464+NCURSES_EXPORT(int)
    18966 +_nc_putp_flush(const char *name, const char *value)
    18967 +{
     23465 _nc_putp_flush(const char *name, const char *value)
     23466 {
     23467-    int rc = _nc_putp(name, value);
     23468-    if (rc != ERR) {
     23469-       _nc_flush();
     23470-    }
     23471-    return rc;
    1896823472+    return NCURSES_SP_NAME(_nc_putp_flush) (CURRENT_SCREEN, name, value);
    18969 +}
     23473 }
    1897023474+#endif
    18971 +
     23475 
    1897223476 /* Turn the keypad on/off
    1897323477  *
    18974   * Note:  we flush the output because changing this mode causes some terminals
    18975 @@ -245,12 +280,12 @@
     23478@@ -245,12 +302,12 @@
    1897623479         * has wgetch() reading in more than one thread.  putp() and below
    1897723480         * may use SP explicitly.
     
    1898823491            rc = _nc_keypad(sp, flag);
    1898923492            _nc_set_screen(save_sp);
    18990 @@ -313,8 +348,8 @@
     23493@@ -276,45 +333,14 @@
     23494 }
     23495 
     23496 static int
     23497-_nc_curs_set(SCREEN *sp, int vis)
     23498-{
     23499-    int result = ERR;
     23500-
     23501-    T((T_CALLED("curs_set(%d)"), vis));
     23502-    if (sp != 0 && vis >= 0 && vis <= 2) {
     23503-       int cursor = sp->_cursor;
     23504-
     23505-       if (vis == cursor) {
     23506-           result = cursor;
     23507-       } else {
     23508-           switch (vis) {
     23509-           case 2:
     23510-               result = _nc_putp_flush("cursor_visible", cursor_visible);
     23511-               break;
     23512-           case 1:
     23513-               result = _nc_putp_flush("cursor_normal", cursor_normal);
     23514-               break;
     23515-           case 0:
     23516-               result = _nc_putp_flush("cursor_invisible", cursor_invisible);
     23517-               break;
     23518-           }
     23519-           if (result != ERR)
     23520-               result = (cursor == -1 ? 1 : cursor);
     23521-           sp->_cursor = vis;
     23522-       }
     23523-    }
     23524-    returnCode(result);
     23525-}
     23526-
     23527-static int
     23528 _nc_meta(SCREEN *sp, bool flag)
     23529 {
     23530     int result = ERR;
    1899123531 
    1899223532     /* Ok, we stay relaxed and don't signal an error if win is NULL */
     
    1899923539        if (flag) {
    1900023540            _nc_putp("meta_on", meta_on);
     23541diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_print.c ncurses-5.7/ncurses/tinfo/lib_print.c
     23542--- ncurses-5.7.orig/ncurses/tinfo/lib_print.c  2006-11-25 16:26:34.000000000 -0800
     23543+++ ncurses-5.7/ncurses/tinfo/lib_print.c       2009-06-05 14:01:51.000000000 -0700
     23544@@ -1,5 +1,5 @@
     23545 /****************************************************************************
     23546- * Copyright (c) 1998-2002,2006 Free Software Foundation, Inc.              *
     23547+ * Copyright (c) 1998-2006,2009 Free Software Foundation, Inc.              *
     23548  *                                                                          *
     23549  * Permission is hereby granted, free of charge, to any person obtaining a  *
     23550  * copy of this software and associated documentation files (the            *
     23551@@ -35,12 +35,19 @@
     23552 
     23553 #include <term.h>
     23554 
     23555-MODULE_ID("$Id: lib_print.c,v 1.16 2006/11/26 00:26:34 tom Exp $")
     23556+#ifndef CUR
     23557+#define CUR SP_TERMTYPE
     23558+#endif
     23559+
     23560+MODULE_ID("$Id: lib_print.c,v 1.18 2009/05/10 00:48:29 tom Exp $")
     23561 
     23562 NCURSES_EXPORT(int)
     23563 mcprint(char *data, int len)
     23564 /* ship binary character data to the printer via mc4/mc5/mc5p */
     23565 {
     23566+#if NCURSES_SP_FUNCS
     23567+    SCREEN *sp = CURRENT_SCREEN;
     23568+#endif
     23569     char *mybuf, *switchon;
     23570     size_t onsize, offsize, res;
     23571 
    1900123572diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_raw.c ncurses-5.7/ncurses/tinfo/lib_raw.c
    1900223573--- ncurses-5.7.orig/ncurses/tinfo/lib_raw.c    2007-09-29 14:50:22.000000000 -0700
    19003 +++ ncurses-5.7/ncurses/tinfo/lib_raw.c 2009-02-28 20:38:57.055236206 -0800
     23574+++ ncurses-5.7/ncurses/tinfo/lib_raw.c 2009-06-05 14:01:14.000000000 -0700
    1900423575@@ -1,5 +1,5 @@
    1900523576 /****************************************************************************
     
    1925023821diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_setup.c ncurses-5.7/ncurses/tinfo/lib_setup.c
    1925123822--- ncurses-5.7.orig/ncurses/tinfo/lib_setup.c  2008-08-03 15:42:33.000000000 -0700
    19252 +++ ncurses-5.7/ncurses/tinfo/lib_setup.c       2009-02-28 20:38:57.055236206 -0800
     23823+++ ncurses-5.7/ncurses/tinfo/lib_setup.c       2009-06-05 14:01:55.000000000 -0700
    1925323824@@ -1,5 +1,5 @@
    1925423825 /****************************************************************************
     
    1927123842 
    1927223843-MODULE_ID("$Id: lib_setup.c,v 1.111 2008/08/03 22:42:33 tom Exp $")
    19273 +MODULE_ID("$Id: lib_setup.c,v 1.113 2009/02/14 22:21:40 tom Exp $")
     23844+MODULE_ID("$Id: lib_setup.c,v 1.116 2009/05/30 20:39:21 tom Exp $")
    1927423845 
    1927523846 /****************************************************************************
    1927623847  *
    19277 @@ -149,21 +150,30 @@
     23848@@ -116,54 +117,68 @@
     23849     return cur_term ? cur_term->type.term_names : empty;
     23850 }
     23851 NCURSES_EXPORT(int *)
     23852-_nc_ptr_Lines(void)
     23853+_nc_ptr_Lines(SCREEN *sp)
     23854 {
     23855-    return ptrLines();
     23856+    return ptrLines(sp);
     23857 }
     23858 NCURSES_EXPORT(int)
     23859 NCURSES_PUBLIC_VAR(LINES) (void)
     23860 {
     23861-    return *_nc_ptr_Lines();
     23862+    return *_nc_ptr_Lines(CURRENT_SCREEN);
     23863 }
     23864 NCURSES_EXPORT(int *)
     23865-_nc_ptr_Cols(void)
     23866+_nc_ptr_Cols(SCREEN *sp)
     23867 {
     23868-    return ptrCols();
     23869+    return ptrCols(sp);
     23870 }
     23871 NCURSES_EXPORT(int)
     23872 NCURSES_PUBLIC_VAR(COLS) (void)
     23873 {
     23874-    return *_nc_ptr_Cols();
     23875+    return *_nc_ptr_Cols(CURRENT_SCREEN);
     23876+}
     23877+NCURSES_EXPORT(int *)
     23878+_nc_ptr_Tabsize(SCREEN *sp)
     23879+{
     23880+    return ptrTabsize(sp);
     23881 }
     23882 NCURSES_EXPORT(int)
     23883 NCURSES_PUBLIC_VAR(TABSIZE) (void)
     23884 {
     23885-    return SP ? SP->_TABSIZE : 8;
     23886+    return *_nc_ptr_Tabsize(CURRENT_SCREEN);
     23887 }
     23888 #else
     23889 NCURSES_EXPORT_VAR(char) ttytype[NAMESIZE] = "";
     23890 NCURSES_EXPORT_VAR(int) LINES = 0;
     23891 NCURSES_EXPORT_VAR(int) COLS = 0;
     23892-NCURSES_EXPORT_VAR(int) TABSIZE = 0;
     23893+NCURSES_EXPORT_VAR(int) TABSIZE = 8;
     23894 #endif
    1927823895 
    1927923896 #if NCURSES_EXT_FUNCS
     
    1930923926 #if USE_SIGWINCH
    1931023927 /*
    19311 @@ -188,13 +198,25 @@
     23928@@ -188,13 +203,25 @@
    1931223929 #endif
    1931323930 
     
    1933723954 _nc_get_screensize(SCREEN *sp, int *linep, int *colp)
    1933823955 /* Obtain lines/columns values from the environment and/or terminfo entry */
     23956@@ -604,7 +631,7 @@
     23957     /*
     23958      * We should always check the screensize, just in case.
     23959      */
     23960-    _nc_get_screensize(SP, ptrLines(), ptrCols());
     23961+    _nc_get_screensize(SP, ptrLines(SP), ptrCols(SP));
     23962 
     23963     if (errret)
     23964        *errret = TGETENT_YES;
     23965diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_termcap.c ncurses-5.7/ncurses/tinfo/lib_termcap.c
     23966--- ncurses-5.7.orig/ncurses/tinfo/lib_termcap.c        2008-08-16 12:22:55.000000000 -0700
     23967+++ ncurses-5.7/ncurses/tinfo/lib_termcap.c     2009-06-05 14:01:54.000000000 -0700
     23968@@ -1,5 +1,5 @@
     23969 /****************************************************************************
     23970- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     23971+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     23972  *                                                                          *
     23973  * Permission is hereby granted, free of charge, to any person obtaining a  *
     23974  * copy of this software and associated documentation files (the            *
     23975@@ -30,6 +30,7 @@
     23976  *  Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1992,1995               *
     23977  *     and: Eric S. Raymond <esr@snark.thyrsus.com>                         *
     23978  *     and: Thomas E. Dickey                        1996-on                 *
     23979+ *     and: Juergen Pfeifer                                                 *
     23980  *                                                                          *
     23981  * some of the code in here was contributed by:                             *
     23982  * Magnus Bengtsson, d6mbeng@dtek.chalmers.se (Nov'93)                      *
     23983@@ -45,7 +46,11 @@
     23984 
     23985 #include <term_entry.h>
     23986 
     23987-MODULE_ID("$Id: lib_termcap.c,v 1.63 2008/08/16 19:22:55 tom Exp $")
     23988+#ifndef CUR
     23989+#define CUR SP_TERMTYPE
     23990+#endif
     23991+
     23992+MODULE_ID("$Id: lib_termcap.c,v 1.66 2009/05/23 23:47:34 tom Exp $")
     23993 
     23994 NCURSES_EXPORT_VAR(char *) UP = 0;
     23995 NCURSES_EXPORT_VAR(char *) BC = 0;
     23996@@ -76,7 +81,7 @@
     23997  ***************************************************************************/
     23998 
     23999 NCURSES_EXPORT(int)
     24000-tgetent(char *bufp, const char *name)
     24001+NCURSES_SP_NAME(tgetent) (NCURSES_SP_DCLx char *bufp, const char *name)
     24002 {
     24003     int errcode;
     24004     int n;
     24005@@ -111,7 +116,7 @@
     24006             */
     24007            if (LAST_TRM != 0 && LAST_TRM != cur_term) {
     24008                TERMINAL *trm = LAST_TRM;
     24009-               del_curterm(LAST_TRM);
     24010+               NCURSES_SP_NAME(del_curterm) (NCURSES_SP_ARGx LAST_TRM);
     24011                for (CacheInx = 0; CacheInx < TGETENT_MAX; ++CacheInx)
     24012                    if (LAST_TRM == trm)
     24013                        LAST_TRM = 0;
     24014@@ -164,8 +169,8 @@
     24015        LAST_BUF = bufp;
     24016        LAST_USE = TRUE;
     24017 
     24018-       SetNoPadding(SP);
     24019-       (void) baudrate();      /* sets ospeed as a side-effect */
     24020+       SetNoPadding(SP_PARM);
     24021+       (void) NCURSES_SP_NAME(baudrate) (NCURSES_SP_ARG);      /* sets ospeed as a side-effect */
     24022 
     24023 /* LINT_PREPRO
     24024 #if 0*/
     24025@@ -177,6 +182,14 @@
     24026     returnCode(errcode);
     24027 }
     24028 
     24029+#if NCURSES_SP_FUNCS
     24030+NCURSES_EXPORT(int)
     24031+tgetent(char *bufp, const char *name)
     24032+{
     24033+    return NCURSES_SP_NAME(tgetent) (CURRENT_SCREEN, bufp, name);
     24034+}
     24035+#endif
     24036+
     24037 /***************************************************************************
     24038  *
     24039  * tgetflag(str)
     24040@@ -187,7 +200,7 @@
     24041  ***************************************************************************/
     24042 
     24043 NCURSES_EXPORT(int)
     24044-tgetflag(NCURSES_CONST char *id)
     24045+NCURSES_SP_NAME(tgetflag) (NCURSES_SP_DCLx NCURSES_CONST char *id)
     24046 {
     24047     unsigned i;
     24048 
     24049@@ -205,6 +218,14 @@
     24050     returnCode(0);             /* Solaris does this */
     24051 }
     24052 
     24053+#if NCURSES_SP_FUNCS
     24054+NCURSES_EXPORT(int)
     24055+tgetflag(NCURSES_CONST char *id)
     24056+{
     24057+    return NCURSES_SP_NAME(tgetflag) (CURRENT_SCREEN, id);
     24058+}
     24059+#endif
     24060+
     24061 /***************************************************************************
     24062  *
     24063  * tgetnum(str)
     24064@@ -215,7 +236,7 @@
     24065  ***************************************************************************/
     24066 
     24067 NCURSES_EXPORT(int)
     24068-tgetnum(NCURSES_CONST char *id)
     24069+NCURSES_SP_NAME(tgetnum) (NCURSES_SP_DCLx NCURSES_CONST char *id)
     24070 {
     24071     unsigned i;
     24072 
     24073@@ -234,6 +255,14 @@
     24074     returnCode(ABSENT_NUMERIC);
     24075 }
     24076 
     24077+#if NCURSES_SP_FUNCS
     24078+NCURSES_EXPORT(int)
     24079+tgetnum(NCURSES_CONST char *id)
     24080+{
     24081+    return NCURSES_SP_NAME(tgetnum) (CURRENT_SCREEN, id);
     24082+}
     24083+#endif
     24084+
     24085 /***************************************************************************
     24086  *
     24087  * tgetstr(str, area)
     24088@@ -244,7 +273,7 @@
     24089  ***************************************************************************/
     24090 
     24091 NCURSES_EXPORT(char *)
     24092-tgetstr(NCURSES_CONST char *id, char **area)
     24093+NCURSES_SP_NAME(tgetstr) (NCURSES_SP_DCLx NCURSES_CONST char *id, char **area)
     24094 {
     24095     unsigned i;
     24096     char *result = NULL;
     24097@@ -278,6 +307,14 @@
     24098     returnPtr(result);
     24099 }
     24100 
     24101+#if NCURSES_SP_FUNCS
     24102+NCURSES_EXPORT(char *)
     24103+tgetstr(NCURSES_CONST char *id, char **area)
     24104+{
     24105+    return NCURSES_SP_NAME(tgetstr) (CURRENT_SCREEN, id, area);
     24106+}
     24107+#endif
     24108+
     24109 #if NO_LEAKS
     24110 NCURSES_EXPORT(void)
     24111 _nc_tgetent_leaks(void)
    1933924112diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_termname.c ncurses-5.7/ncurses/tinfo/lib_termname.c
    1934024113--- ncurses-5.7.orig/ncurses/tinfo/lib_termname.c       2003-12-27 10:23:01.000000000 -0800
    19341 +++ ncurses-5.7/ncurses/tinfo/lib_termname.c    2009-02-28 20:38:58.439326442 -0800
     24114+++ ncurses-5.7/ncurses/tinfo/lib_termname.c    2009-06-05 14:01:16.000000000 -0700
    1934224115@@ -1,5 +1,5 @@
    1934324116 /****************************************************************************
     
    1938224155+}
    1938324156+#endif
     24157diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_ti.c ncurses-5.7/ncurses/tinfo/lib_ti.c
     24158--- ncurses-5.7.orig/ncurses/tinfo/lib_ti.c     2003-05-24 14:10:28.000000000 -0700
     24159+++ ncurses-5.7/ncurses/tinfo/lib_ti.c  2009-06-05 14:01:51.000000000 -0700
     24160@@ -1,5 +1,5 @@
     24161 /****************************************************************************
     24162- * Copyright (c) 1998-2000,2003 Free Software Foundation, Inc.              *
     24163+ * Copyright (c) 1998-2003,2009 Free Software Foundation, Inc.              *
     24164  *                                                                          *
     24165  * Permission is hereby granted, free of charge, to any person obtaining a  *
     24166  * copy of this software and associated documentation files (the            *
     24167@@ -36,17 +36,17 @@
     24168 #include <term_entry.h>
     24169 #include <tic.h>
     24170 
     24171-MODULE_ID("$Id: lib_ti.c,v 1.23 2003/05/24 21:10:28 tom Exp $")
     24172+MODULE_ID("$Id: lib_ti.c,v 1.24 2009/04/18 17:37:50 tom Exp $")
     24173 
     24174 NCURSES_EXPORT(int)
     24175-tigetflag(NCURSES_CONST char *str)
     24176+NCURSES_SP_NAME(tigetflag) (NCURSES_SP_DCLx NCURSES_CONST char *str)
     24177 {
     24178     unsigned i;
     24179 
     24180-    T((T_CALLED("tigetflag(%s)"), str));
     24181+    T((T_CALLED("tigetflag(%p, %s)"), SP_PARM, str));
     24182 
     24183-    if (cur_term != 0) {
     24184-       TERMTYPE *tp = &(cur_term->type);
     24185+    if (HasTInfoTerminal(SP_PARM)) {
     24186+       TERMTYPE *tp = &(TerminalOf(SP_PARM)->type);
     24187        for_each_boolean(i, tp) {
     24188            const char *capname = ExtBoolname(tp, i, boolnames);
     24189            if (!strcmp(str, capname)) {
     24190@@ -59,15 +59,23 @@
     24191     returnCode(ABSENT_BOOLEAN);
     24192 }
     24193 
     24194+#if NCURSES_SP_FUNCS
     24195 NCURSES_EXPORT(int)
     24196-tigetnum(NCURSES_CONST char *str)
     24197+tigetflag(NCURSES_CONST char *str)
     24198+{
     24199+    return NCURSES_SP_NAME(tigetflag) (CURRENT_SCREEN, str);
     24200+}
     24201+#endif
     24202+
     24203+NCURSES_EXPORT(int)
     24204+NCURSES_SP_NAME(tigetnum) (NCURSES_SP_DCLx NCURSES_CONST char *str)
     24205 {
     24206     unsigned i;
     24207 
     24208-    T((T_CALLED("tigetnum(%s)"), str));
     24209+    T((T_CALLED("tigetnum(%p, %s)"), SP_PARM, str));
     24210 
     24211-    if (cur_term != 0) {
     24212-       TERMTYPE *tp = &(cur_term->type);
     24213+    if (HasTInfoTerminal(SP_PARM)) {
     24214+       TERMTYPE *tp = &(TerminalOf(SP_PARM)->type);
     24215        for_each_number(i, tp) {
     24216            const char *capname = ExtNumname(tp, i, numnames);
     24217            if (!strcmp(str, capname)) {
     24218@@ -81,15 +89,23 @@
     24219     returnCode(CANCELLED_NUMERIC);     /* Solaris returns a -1 instead */
     24220 }
     24221 
     24222+#if NCURSES_SP_FUNCS
     24223+NCURSES_EXPORT(int)
     24224+tigetnum(NCURSES_CONST char *str)
     24225+{
     24226+    return NCURSES_SP_NAME(tigetnum) (CURRENT_SCREEN, str);
     24227+}
     24228+#endif
     24229+
     24230 NCURSES_EXPORT(char *)
     24231-tigetstr(NCURSES_CONST char *str)
     24232+NCURSES_SP_NAME(tigetstr) (NCURSES_SP_DCLx NCURSES_CONST char *str)
     24233 {
     24234     unsigned i;
     24235 
     24236-    T((T_CALLED("tigetstr(%s)"), str));
     24237+    T((T_CALLED("tigetstr(%p, %s)"), SP_PARM, str));
     24238 
     24239-    if (cur_term != 0) {
     24240-       TERMTYPE *tp = &(cur_term->type);
     24241+    if (HasTInfoTerminal(SP_PARM)) {
     24242+       TERMTYPE *tp = &(TerminalOf(SP_PARM)->type);
     24243        for_each_string(i, tp) {
     24244            const char *capname = ExtStrname(tp, i, strnames);
     24245            if (!strcmp(str, capname)) {
     24246@@ -101,3 +117,11 @@
     24247 
     24248     returnPtr(CANCELLED_STRING);
     24249 }
     24250+
     24251+#if NCURSES_SP_FUNCS
     24252+NCURSES_EXPORT(char *)
     24253+tigetstr(NCURSES_CONST char *str)
     24254+{
     24255+    return NCURSES_SP_NAME(tigetstr) (CURRENT_SCREEN, str);
     24256+}
     24257+#endif
    1938424258diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_tparm.c ncurses-5.7/ncurses/tinfo/lib_tparm.c
    1938524259--- ncurses-5.7.orig/ncurses/tinfo/lib_tparm.c  2008-08-16 12:22:55.000000000 -0700
    19386 +++ ncurses-5.7/ncurses/tinfo/lib_tparm.c       2009-02-28 20:38:58.439326442 -0800
     24260+++ ncurses-5.7/ncurses/tinfo/lib_tparm.c       2009-06-05 14:01:16.000000000 -0700
    1938724261@@ -40,10 +40,9 @@
    1938824262 #include <curses.priv.h>
     
    1939924273diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_tputs.c ncurses-5.7/ncurses/tinfo/lib_tputs.c
    1940024274--- ncurses-5.7.orig/ncurses/tinfo/lib_tputs.c  2008-06-28 06:12:15.000000000 -0700
    19401 +++ ncurses-5.7/ncurses/tinfo/lib_tputs.c       2009-02-28 20:38:59.859415560 -0800
     24275+++ ncurses-5.7/ncurses/tinfo/lib_tputs.c       2009-06-05 14:01:54.000000000 -0700
    1940224276@@ -1,5 +1,5 @@
    1940324277 /****************************************************************************
     
    1941524289 
    1941624290 /*
    19417 @@ -46,7 +47,7 @@
     24291@@ -41,12 +42,16 @@
     24292  */
     24293 
     24294 #include <curses.priv.h>
     24295+
     24296+#ifndef CUR
     24297+#define CUR SP_TERMTYPE
     24298+#endif
     24299+
     24300 #include <ctype.h>
     24301-#include <term.h>              /* padding_baud_rate, xon_xoff */
    1941824302 #include <termcap.h>           /* ospeed */
    1941924303 #include <tic.h>
    1942024304 
    1942124305-MODULE_ID("$Id: lib_tputs.c,v 1.66 2008/06/28 13:12:15 tom Exp $")
    19422 +MODULE_ID("$Id: lib_tputs.c,v 1.68 2009/02/28 21:08:18 tom Exp $")
     24306+MODULE_ID("$Id: lib_tputs.c,v 1.74 2009/05/23 23:56:23 tom Exp $")
    1942324307 
    1942424308 NCURSES_EXPORT_VAR(char) PC = 0;              /* used by termcap library */
    1942524309 NCURSES_EXPORT_VAR(NCURSES_OSPEED) ospeed = 0;        /* used by termcap library */
    19426 @@ -72,7 +73,7 @@
    19427  static int (*my_outch) (int c) = _nc_outch;
     24310@@ -69,62 +74,122 @@
     24311 }
     24312 #endif
     24313 
     24314-static int (*my_outch) (int c) = _nc_outch;
     24315+#if NCURSES_SP_FUNCS
     24316+#define my_outch SP_PARM->_outch
     24317+#else
     24318+static NCURSES_SP_OUTC my_outch = NCURSES_SP_NAME(_nc_outch);
     24319+#endif
    1942824320 
    1942924321 NCURSES_EXPORT(int)
     
    1943124323+NCURSES_SP_NAME(delay_output) (NCURSES_SP_DCLx int ms)
    1943224324 {
    19433      T((T_CALLED("delay_output(%d)"), ms));
    19434  
    19435 @@ -92,19 +93,35 @@
     24325-    T((T_CALLED("delay_output(%d)"), ms));
     24326+    T((T_CALLED("delay_output(%p,%d)"), SP_PARM, ms));
     24327 
     24328     if (no_pad_char) {
     24329-       _nc_flush();
     24330+       NCURSES_SP_NAME(_nc_flush) (NCURSES_SP_ARG);
     24331        napms(ms);
     24332     } else {
     24333        register int nullcount;
     24334 
     24335        nullcount = (ms * _nc_baudrate(ospeed)) / (BAUDBYTE * 1000);
     24336        for (_nc_nulls_sent += nullcount; nullcount > 0; nullcount--)
     24337-           my_outch(PC);
     24338-       if (my_outch == _nc_outch)
     24339-           _nc_flush();
     24340+           my_outch(NCURSES_SP_ARGx PC);
     24341+       if (my_outch == NCURSES_SP_NAME(_nc_outch))
     24342+           NCURSES_SP_NAME(_nc_flush) (NCURSES_SP_ARG);
     24343     }
     24344 
    1943624345     returnCode(OK);
    1943724346 }
     
    1944524354+#endif
    1944624355+
     24356+NCURSES_EXPORT(void)
     24357+NCURSES_SP_NAME(_nc_flush) (NCURSES_SP_DCL0)
     24358+{
     24359+    (void) fflush(NC_OUTPUT(SP_PARM));
     24360+}
     24361+
     24362+#if NCURSES_SP_FUNCS
    1944724363 NCURSES_EXPORT(void)
    19448 -_nc_flush(void)
    19449 +NCURSES_SP_NAME(_nc_flush) (NCURSES_SP_DCL0)
     24364 _nc_flush(void)
    1945024365 {
    19451      (void) fflush(NC_OUTPUT);
     24366-    (void) fflush(NC_OUTPUT);
     24367+    NCURSES_SP_NAME(_nc_flush) (CURRENT_SCREEN);
    1945224368 }
    19453  
    19454 +#if NCURSES_SP_FUNCS
    19455 +NCURSES_EXPORT(void)
    19456 +_nc_flush(void)
    19457 +{
    19458 +    NCURSES_SP_NAME(_nc_flush) (CURRENT_SCREEN);
    19459 +}
    1946024369+#endif
    19461 +
     24370 
    1946224371 NCURSES_EXPORT(int)
    1946324372-_nc_outch(int ch)
     
    1947324382        /*
    1947424383         * POSIX says write() is safe in a signal handler, but the
    19475 @@ -117,6 +134,14 @@
     24384         * buffered I/O is not.
     24385         */
     24386-       write(fileno(NC_OUTPUT), &tmp, 1);
     24387+       write(fileno(NC_OUTPUT(SP_PARM)), &tmp, 1);
     24388     } else {
     24389-       putc(ch, NC_OUTPUT);
     24390+       putc(ch, NC_OUTPUT(SP_PARM));
     24391     }
    1947624392     return OK;
    1947724393 }
     
    1948524401+#endif
    1948624402+
     24403+NCURSES_EXPORT(int)
     24404+NCURSES_SP_NAME(putp) (NCURSES_SP_DCLx const char *string)
     24405+{
     24406+    return NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     24407+                                  string, 1, NCURSES_SP_NAME(_nc_outch));
     24408+}
     24409+
     24410+NCURSES_EXPORT(int)
     24411+NCURSES_SP_NAME(_nc_putp) (NCURSES_SP_DCLx
     24412+                          const char *name GCC_UNUSED,
     24413+                          const char *string)
     24414+{
     24415+    int rc = ERR;
     24416+
     24417+    if (string != 0) {
     24418+       TPUTS_TRACE(name);
     24419+       rc = NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx string);
     24420+    }
     24421+    return rc;
     24422+}
     24423+
     24424+#if NCURSES_SP_FUNCS
    1948724425 NCURSES_EXPORT(int)
    1948824426 putp(const char *string)
    1948924427 {
     24428-    return tputs(string, 1, _nc_outch);
     24429+    return NCURSES_SP_NAME(putp) (CURRENT_SCREEN, string);
     24430 }
     24431 
     24432 NCURSES_EXPORT(int)
     24433-tputs(const char *string, int affcnt, int (*outc) (int))
     24434+_nc_putp(const char *name, const char *string)
     24435+{
     24436+    return NCURSES_SP_NAME(_nc_putp) (CURRENT_SCREEN, name, string);
     24437+}
     24438+#endif
     24439+
     24440+NCURSES_EXPORT(int)
     24441+NCURSES_SP_NAME(tputs) (NCURSES_SP_DCLx
     24442+                       const char *string,
     24443+                       int affcnt,
     24444+                       NCURSES_SP_OUTC outc)
     24445 {
     24446     bool always_delay;
     24447     bool normal_delay;
     24448@@ -137,7 +202,7 @@
     24449     char addrbuf[32];
     24450 
     24451     if (USE_TRACEF(TRACE_TPUTS)) {
     24452-       if (outc == _nc_outch)
     24453+       if (outc == NCURSES_SP_NAME(_nc_outch))
     24454            (void) strcpy(addrbuf, "_nc_outch");
     24455        else
     24456            (void) sprintf(addrbuf, "%p", outc);
     24457@@ -164,7 +229,7 @@
     24458            !xon_xoff
     24459            && padding_baud_rate
     24460 #if NCURSES_NO_PADDING
     24461-           && !GetNoPadding(SP)
     24462+           && !GetNoPadding(SP_PARM)
     24463 #endif
     24464            && (_nc_baudrate(ospeed) >= padding_baud_rate);
     24465     }
     24466@@ -201,21 +266,21 @@
     24467     my_outch = outc;           /* redirect delay_output() */
     24468     while (*string) {
     24469        if (*string != '$')
     24470-           (*outc) (*string);
     24471+           (*outc) (NCURSES_SP_ARGx *string);
     24472        else {
     24473            string++;
     24474            if (*string != '<') {
     24475-               (*outc) ('$');
     24476+               (*outc) (NCURSES_SP_ARGx '$');
     24477                if (*string)
     24478-                   (*outc) (*string);
     24479+                   (*outc) (NCURSES_SP_ARGx *string);
     24480            } else {
     24481                bool mandatory;
     24482 
     24483                string++;
     24484                if ((!isdigit(UChar(*string)) && *string != '.')
     24485                    || !strchr(string, '>')) {
     24486-                   (*outc) ('$');
     24487-                   (*outc) ('<');
     24488+                   (*outc) (NCURSES_SP_ARGx '$');
     24489+                   (*outc) (NCURSES_SP_ARGx '<');
     24490                    continue;
     24491                }
     24492 
     24493@@ -250,7 +315,7 @@
     24494                    && (always_delay
     24495                        || normal_delay
     24496                        || mandatory))
     24497-                   delay_output(number / 10);
     24498+                   NCURSES_SP_NAME(delay_output) (NCURSES_SP_ARGx number / 10);
     24499 
     24500            }                   /* endelse (*string == '<') */
     24501        }                       /* endelse (*string == '$') */
     24502@@ -270,6 +335,25 @@
     24503        delay_output(trailpad / 10);
     24504 #endif /* BSD_TPUTS */
     24505 
     24506-    my_outch = _nc_outch;
     24507+    my_outch = NCURSES_SP_NAME(_nc_outch);
     24508     return OK;
     24509 }
     24510+
     24511+#if NCURSES_SP_FUNCS
     24512+NCURSES_EXPORT(int)
     24513+_nc_outc_wrapper(SCREEN *sp, int c)
     24514+{
     24515+    if (0 == sp) {
     24516+       return (ERR);
     24517+    } else {
     24518+       return sp->jump(c);
     24519+    }
     24520+}
     24521+
     24522+NCURSES_EXPORT(int)
     24523+tputs(const char *string, int affcnt, int (*outc) (int))
     24524+{
     24525+    SetSafeOutcWrapper(outc);
     24526+    return NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx string, affcnt, _nc_outc_wrapper);
     24527+}
     24528+#endif
    1949024529diff -Naur ncurses-5.7.orig/ncurses/tinfo/lib_ttyflags.c ncurses-5.7/ncurses/tinfo/lib_ttyflags.c
    1949124530--- ncurses-5.7.orig/ncurses/tinfo/lib_ttyflags.c       2008-08-03 15:10:44.000000000 -0700
    19492 +++ ncurses-5.7/ncurses/tinfo/lib_ttyflags.c    2009-02-28 20:38:57.059236485 -0800
     24531+++ ncurses-5.7/ncurses/tinfo/lib_ttyflags.c    2009-06-05 14:01:51.000000000 -0700
    1949324532@@ -1,5 +1,5 @@
    1949424533 /****************************************************************************
     
    1949824537  * Permission is hereby granted, free of charge, to any person obtaining a  *
    1949924538  * copy of this software and associated documentation files (the            *
    19500 @@ -38,7 +38,7 @@
     24539@@ -38,10 +38,14 @@
    1950124540 #include <curses.priv.h>
    1950224541 #include <term.h>              /* cur_term */
    1950324542 
    1950424543-MODULE_ID("$Id: lib_ttyflags.c,v 1.18 2008/08/03 22:10:44 tom Exp $")
    19505 +MODULE_ID("$Id: lib_ttyflags.c,v 1.19 2009/02/15 00:33:49 tom Exp $")
     24544+#ifndef CUR
     24545+#define CUR SP_TERMTYPE
     24546+#endif
     24547+
     24548+MODULE_ID("$Id: lib_ttyflags.c,v 1.24 2009/05/10 00:48:29 tom Exp $")
    1950624549 
    1950724550 NCURSES_EXPORT(int)
    19508  _nc_get_tty_mode(TTY * buf)
    19509 @@ -101,7 +101,7 @@
     24551-_nc_get_tty_mode(TTY * buf)
     24552+NCURSES_SP_NAME(_nc_get_tty_mode) (NCURSES_SP_DCLx TTY * buf)
     24553 {
     24554     int result = OK;
     24555 
     24556@@ -71,8 +75,16 @@
     24557     return (result);
    1951024558 }
    1951124559 
     24560+#if NCURSES_SP_FUNCS
     24561 NCURSES_EXPORT(int)
     24562-_nc_set_tty_mode(TTY * buf)
     24563+_nc_get_tty_mode(TTY * buf)
     24564+{
     24565+    return NCURSES_SP_NAME(_nc_get_tty_mode) (CURRENT_SCREEN, buf);
     24566+}
     24567+#endif
     24568+
     24569+NCURSES_EXPORT(int)
     24570+NCURSES_SP_NAME(_nc_set_tty_mode) (NCURSES_SP_DCLx TTY * buf)
     24571 {
     24572     int result = OK;
     24573 
     24574@@ -86,8 +98,8 @@
     24575                if (SET_TTY(cur_term->Filedes, buf) != 0) {
     24576                    if (errno == EINTR)
     24577                        continue;
     24578-                   if ((errno == ENOTTY) && (SP != 0))
     24579-                       SP->_notty = TRUE;
     24580+                   if ((errno == ENOTTY) && (SP_PARM != 0))
     24581+                       SP_PARM->_notty = TRUE;
     24582                    result = ERR;
     24583                }
     24584                break;
     24585@@ -100,8 +112,16 @@
     24586     return (result);
     24587 }
     24588 
     24589+#if NCURSES_SP_FUNCS
    1951224590 NCURSES_EXPORT(int)
    1951324591-def_shell_mode(void)
     24592+_nc_set_tty_mode(TTY * buf)
     24593+{
     24594+    return NCURSES_SP_NAME(_nc_set_tty_mode) (CURRENT_SCREEN, buf);
     24595+}
     24596+#endif
     24597+
     24598+NCURSES_EXPORT(int)
    1951424599+NCURSES_SP_NAME(def_shell_mode) (NCURSES_SP_DCL0)
    1951524600 {
    1951624601     int rc = ERR;
    1951724602 
    19518 @@ -125,8 +125,16 @@
     24603@@ -125,8 +145,16 @@
    1951924604     returnCode(rc);
    1952024605 }
     
    1953424619     int rc = ERR;
    1953524620 
    19536 @@ -148,16 +156,24 @@
     24621@@ -148,17 +176,25 @@
    1953724622     returnCode(rc);
    1953824623 }
     
    1955724642-               if (SP->_keypad_on)
    1955824643-                   _nc_keypad(SP, TRUE);
     24644-               NC_BUFFERED(TRUE);
    1955924645+           if (SP_PARM) {
    1956024646+               if (SP_PARM->_keypad_on)
    1956124647+                   _nc_keypad(SP_PARM, TRUE);
    19562                 NC_BUFFERED(TRUE);
     24648+               NC_BUFFERED(SP_PARM, TRUE);
    1956324649            }
    1956424650            returnCode(OK);
    19565 @@ -166,14 +182,22 @@
     24651        }
     24652@@ -166,22 +202,38 @@
    1956624653     returnCode(ERR);
    1956724654 }
     
    1958724674+           _nc_keypad(SP_PARM, FALSE);
    1958824675            _nc_flush();
    19589             NC_BUFFERED(FALSE);
     24676-           NC_BUFFERED(FALSE);
     24677+           NC_BUFFERED(SP_PARM, FALSE);
    1959024678        }
    19591 @@ -182,6 +206,14 @@
     24679        returnCode(_nc_set_tty_mode(&cur_term->Ottyb));
     24680     }
    1959224681     returnCode(ERR);
    1959324682 }
     
    1960624695diff -Naur ncurses-5.7.orig/ncurses/tinfo/make_keys.c ncurses-5.7/ncurses/tinfo/make_keys.c
    1960724696--- ncurses-5.7.orig/ncurses/tinfo/make_keys.c  2008-08-03 14:57:22.000000000 -0700
    19608 +++ ncurses-5.7/ncurses/tinfo/make_keys.c       2009-02-28 20:38:58.439326442 -0800
     24697+++ ncurses-5.7/ncurses/tinfo/make_keys.c       2009-06-05 14:01:16.000000000 -0700
    1960924698@@ -39,16 +39,16 @@
    1961024699 #define USE_TERMLIB 1
     
    1964924738            fprintf(ofp, "\t{ %4d, %-*.*s },\t/* %s */\n",
    1965024739                    code,
     24740diff -Naur ncurses-5.7.orig/ncurses/tinfo/MKcodes.awk ncurses-5.7/ncurses/tinfo/MKcodes.awk
     24741--- ncurses-5.7.orig/ncurses/tinfo/MKcodes.awk  2008-06-28 16:13:25.000000000 -0700
     24742+++ ncurses-5.7/ncurses/tinfo/MKcodes.awk       2009-06-05 14:01:54.000000000 -0700
     24743@@ -1,5 +1,5 @@
     24744 ##############################################################################
     24745-# Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.                #
     24746+# Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.                #
     24747 #                                                                            #
     24748 # Permission is hereby granted, free of charge, to any person obtaining a    #
     24749 # copy of this software and associated documentation files (the "Software"), #
     24750@@ -25,7 +25,7 @@
     24751 # use or other dealings in this Software without prior written               #
     24752 # authorization.                                                             #
     24753 ##############################################################################
     24754-# $Id: MKcodes.awk,v 1.5 2008/06/28 23:13:25 tom Exp $
     24755+# $Id: MKcodes.awk,v 1.8 2009/05/23 19:09:54 tom Exp $
     24756 function large_item(value) {
     24757        result = sprintf("%d,", offset);
     24758        offset = offset + length(value) + 1;
     24759@@ -117,28 +117,39 @@
     24760                        print  "                if ((*value = typeCalloc(NCURSES_CONST char *, size + 1)) != 0) {"
     24761                        print  "                        unsigned n;"
     24762                        print  "                        for (n = 0; n < size; ++n) {"
     24763-                       print  "                                (*value)[n] = _nc_code_blob + offsets[n];"
     24764+                       print  "                                (*value)[n] = (NCURSES_CONST char *) _nc_code_blob + offsets[n];"
     24765                        print  "                        }"
     24766                        print  "                }"
     24767                        print  "        }"
     24768                        print  "        return *value;"
     24769                        print  "}"
     24770                        print  ""
     24771-                       print  "#define FIX(it) NCURSES_IMPEXP IT * NCURSES_API _nc_##it(void) { return alloc_array(&ptr_##it, _nc_offset_##it, SIZEOF(_nc_offset_##it)); }"
     24772+                       print  "#define FIX(it) NCURSES_IMPEXP IT * NCURSES_API NCURSES_PUBLIC_VAR(it)(void) { return alloc_array(&ptr_##it, _nc_offset_##it, SIZEOF(_nc_offset_##it)); }"
     24773                } else {
     24774                        print  "#define DCL(it) static IT data##it[]"
     24775                        print  ""
     24776                        print_strings("boolcodes", small_boolcodes);
     24777                        print_strings("numcodes", small_numcodes);
     24778                        print_strings("strcodes", small_strcodes);
     24779-                       print  "#define FIX(it) NCURSES_IMPEXP IT * NCURSES_API _nc_##it(void) { return data##it; }"
     24780+                       print  "#define FIX(it) NCURSES_IMPEXP IT * NCURSES_API NCURSES_PUBLIC_VAR(it)(void) { return data##it; }"
     24781                }
     24782                print  ""
     24783+               print  "/* remove public definition which conflicts with FIX() */"
     24784+               print  "#undef boolcodes"
     24785+               print  "#undef numcodes"
     24786+               print  "#undef strcodes"
     24787+               print  ""
     24788+               print  "/* add local definition */"
     24789                print  "FIX(boolcodes)"
     24790                print  "FIX(numcodes)"
     24791                print  "FIX(strcodes)"
     24792                print  ""
     24793+               print  "/* restore the public definition */"
     24794+               print  ""
     24795                print  "#define FREE_FIX(it) if (ptr_##it) { FreeAndNull(ptr_##it); }"
     24796+               print  "#define boolcodes  NCURSES_PUBLIC_VAR(boolcodes())"
     24797+               print  "#define numcodes   NCURSES_PUBLIC_VAR(numcodes())"
     24798+               print  "#define strcodes   NCURSES_PUBLIC_VAR(strcodes())"
     24799                print  ""
     24800                print  "#if NO_LEAKS"
     24801                print  "NCURSES_EXPORT(void)"
     24802diff -Naur ncurses-5.7.orig/ncurses/tinfo/MKfallback.sh ncurses-5.7/ncurses/tinfo/MKfallback.sh
     24803--- ncurses-5.7.orig/ncurses/tinfo/MKfallback.sh        2006-07-15 09:54:20.000000000 -0700
     24804+++ ncurses-5.7/ncurses/tinfo/MKfallback.sh     2009-06-05 14:01:44.000000000 -0700
     24805@@ -1,6 +1,6 @@
     24806 #!/bin/sh
     24807 ##############################################################################
     24808-# Copyright (c) 1998-2001,2006 Free Software Foundation, Inc.                #
     24809+# Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.                #
     24810 #                                                                            #
     24811 # Permission is hereby granted, free of charge, to any person obtaining a    #
     24812 # copy of this software and associated documentation files (the "Software"), #
     24813@@ -26,7 +26,7 @@
     24814 # use or other dealings in this Software without prior written               #
     24815 # authorization.                                                             #
     24816 ##############################################################################
     24817-# $Id: MKfallback.sh,v 1.13 2006/07/15 16:54:20 tom Exp $
     24818+# $Id: MKfallback.sh,v 1.14 2009/04/18 21:01:38 tom Exp $
     24819 #
     24820 # MKfallback.sh -- create fallback table for entry reads
     24821 #
     24822@@ -63,7 +63,6 @@
     24823  */
     24824 
     24825 #include <curses.priv.h>
     24826-#include <term.h>
     24827 
     24828 EOF
     24829 
    1965124830diff -Naur ncurses-5.7.orig/ncurses/tinfo/MKnames.awk ncurses-5.7/ncurses/tinfo/MKnames.awk
    1965224831--- ncurses-5.7.orig/ncurses/tinfo/MKnames.awk  2008-10-11 14:07:56.000000000 -0700
    19653 +++ ncurses-5.7/ncurses/tinfo/MKnames.awk       2009-02-28 20:38:58.439326442 -0800
     24832+++ ncurses-5.7/ncurses/tinfo/MKnames.awk       2009-06-05 14:01:24.000000000 -0700
     24833@@ -1,5 +1,5 @@
     24834 ##############################################################################
     24835-# Copyright (c) 2007,2008 Free Software Foundation, Inc.                     #
     24836+# Copyright (c) 2007-2008,2009 Free Software Foundation, Inc.                #
     24837 #                                                                            #
     24838 # Permission is hereby granted, free of charge, to any person obtaining a    #
     24839 # copy of this software and associated documentation files (the "Software"), #
    1965424840@@ -25,7 +25,7 @@
    1965524841 # use or other dealings in this Software without prior written               #
     
    1965724843 ##############################################################################
    1965824844-# $Id: MKnames.awk,v 1.20 2008/10/11 21:07:56 tom Exp $
    19659 +# $Id: MKnames.awk,v 1.21 2008/11/16 00:19:59 juergen Exp $
     24845+# $Id: MKnames.awk,v 1.22 2009/03/21 21:03:39 tom Exp $
    1966024846 function large_item(value) {
    1966124847        result = sprintf("%d,", offset);
     
    1967024856                        printf "static const char _nc_name_blob[] = \n"
    1967124857                        printf "%s;\n", bigstr;
     24858@@ -133,7 +131,7 @@
     24859                        print  "        return *value;"
     24860                        print  "}"
     24861                        print  ""
     24862-                       print  "#define FIX(it) NCURSES_IMPEXP IT * NCURSES_API _nc_##it(void) { return alloc_array(&ptr_##it, _nc_offset_##it, SIZEOF(_nc_offset_##it)); }"
     24863+                       print  "#define FIX(it) NCURSES_IMPEXP IT * NCURSES_API NCURSES_PUBLIC_VAR(it)(void) { return alloc_array(&ptr_##it, _nc_offset_##it, SIZEOF(_nc_offset_##it)); }"
     24864                } else {
     24865                        print  "#define DCL(it) static IT data##it[]"
     24866                        print  ""
     24867@@ -143,9 +141,18 @@
     24868                        print_strings("numfnames", small_numfnames);
     24869                        print_strings("strnames", small_strnames);
     24870                        print_strings("strfnames", small_strfnames);
     24871-                       print  "#define FIX(it) NCURSES_IMPEXP IT * NCURSES_API _nc_##it(void) { return data##it; }"
     24872+                       print  "#define FIX(it) NCURSES_IMPEXP IT * NCURSES_API NCURSES_PUBLIC_VAR(it)(void) { return data##it; }"
     24873                }
     24874                print  ""
     24875+               print  "/* remove public definition which conflicts with FIX() */"
     24876+               print  "#undef boolnames"
     24877+               print  "#undef boolfnames"
     24878+               print  "#undef numnames"
     24879+               print  "#undef numfnames"
     24880+               print  "#undef strnames"
     24881+               print  "#undef strfnames"
     24882+               print  ""
     24883+               print  "/* add local definition */"
     24884                print  "FIX(boolnames)"
     24885                print  "FIX(boolfnames)"
     24886                print  "FIX(numnames)"
     24887@@ -153,6 +160,13 @@
     24888                print  "FIX(strnames)"
     24889                print  "FIX(strfnames)"
     24890                print  ""
     24891+               print  "/* restore the public definition */"
     24892+               print  "#define boolnames  NCURSES_PUBLIC_VAR(boolnames())"
     24893+               print  "#define boolfnames NCURSES_PUBLIC_VAR(boolfnames())"
     24894+               print  "#define numnames   NCURSES_PUBLIC_VAR(numnames())"
     24895+               print  "#define numfnames  NCURSES_PUBLIC_VAR(numfnames())"
     24896+               print  "#define strnames   NCURSES_PUBLIC_VAR(strnames())"
     24897+               print  "#define strfnames  NCURSES_PUBLIC_VAR(strfnames())"
     24898                print  ""
     24899                print  "#define FREE_FIX(it) if (ptr_##it) { FreeAndNull(ptr_##it); }"
     24900                print  ""
    1967224901diff -Naur ncurses-5.7.orig/ncurses/tinfo/name_match.c ncurses-5.7/ncurses/tinfo/name_match.c
    1967324902--- ncurses-5.7.orig/ncurses/tinfo/name_match.c 2008-08-03 12:49:33.000000000 -0700
    19674 +++ ncurses-5.7/ncurses/tinfo/name_match.c      2009-02-28 20:38:58.439326442 -0800
     24903+++ ncurses-5.7/ncurses/tinfo/name_match.c      2009-06-05 14:01:16.000000000 -0700
    1967524904@@ -31,10 +31,9 @@
    1967624905  ****************************************************************************/
     
    1968524914 /*
    1968624915  *     _nc_first_name(char *names)
     24916diff -Naur ncurses-5.7.orig/ncurses/tinfo/parse_entry.c ncurses-5.7/ncurses/tinfo/parse_entry.c
     24917--- ncurses-5.7.orig/ncurses/tinfo/parse_entry.c        2008-08-16 14:52:03.000000000 -0700
     24918+++ ncurses-5.7/ncurses/tinfo/parse_entry.c     2009-06-05 14:01:44.000000000 -0700
     24919@@ -1,5 +1,5 @@
     24920 /****************************************************************************
     24921- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     24922+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     24923  *                                                                          *
     24924  * Permission is hereby granted, free of charge, to any person obtaining a  *
     24925  * copy of this software and associated documentation files (the            *
     24926@@ -48,7 +48,7 @@
     24927 #include <tic.h>
     24928 #include <term_entry.h>
     24929 
     24930-MODULE_ID("$Id: parse_entry.c,v 1.69 2008/08/16 21:52:03 tom Exp $")
     24931+MODULE_ID("$Id: parse_entry.c,v 1.70 2009/04/18 21:01:38 tom Exp $")
     24932 
     24933 #ifdef LINT
     24934 static short const parametrized[] =
     24935@@ -84,13 +84,13 @@
     24936     case NUMBER:
     24937        first = tp->ext_Booleans;
     24938        last = tp->ext_Numbers + first;
     24939-       offset = tp->ext_Booleans + tp->ext_Numbers;
     24940+       offset = (unsigned) (tp->ext_Booleans + tp->ext_Numbers);
     24941        tindex = tp->num_Numbers;
     24942        break;
     24943     case STRING:
     24944-       first = tp->ext_Booleans + tp->ext_Numbers;
     24945+       first = (unsigned) (tp->ext_Booleans + tp->ext_Numbers);
     24946        last = tp->ext_Strings + first;
     24947-       offset = tp->ext_Booleans + tp->ext_Numbers + tp->ext_Strings;
     24948+       offset = (unsigned) (tp->ext_Booleans + tp->ext_Numbers + tp->ext_Strings);
     24949        tindex = tp->num_Strings;
     24950        break;
     24951     case CANCEL:
     24952@@ -137,27 +137,31 @@
     24953            break;
     24954        }
     24955     }
     24956+
     24957+#define for_each_value(max) \
     24958+       for (last = (unsigned) (max - 1); last > tindex; last--)
     24959+
     24960     if (!found) {
     24961        switch (token_type) {
     24962        case BOOLEAN:
     24963-           tp->ext_Booleans += 1;
     24964-           tp->num_Booleans += 1;
     24965+           tp->ext_Booleans++;
     24966+           tp->num_Booleans++;
     24967            tp->Booleans = typeRealloc(NCURSES_SBOOL, tp->num_Booleans, tp->Booleans);
     24968-           for (last = tp->num_Booleans - 1; last > tindex; last--)
     24969+           for_each_value(tp->num_Booleans)
     24970                tp->Booleans[last] = tp->Booleans[last - 1];
     24971            break;
     24972        case NUMBER:
     24973-           tp->ext_Numbers += 1;
     24974-           tp->num_Numbers += 1;
     24975+           tp->ext_Numbers++;
     24976+           tp->num_Numbers++;
     24977            tp->Numbers = typeRealloc(short, tp->num_Numbers, tp->Numbers);
     24978-           for (last = tp->num_Numbers - 1; last > tindex; last--)
     24979+           for_each_value(tp->num_Numbers)
     24980                tp->Numbers[last] = tp->Numbers[last - 1];
     24981            break;
     24982        case STRING:
     24983-           tp->ext_Strings += 1;
     24984-           tp->num_Strings += 1;
     24985+           tp->ext_Strings++;
     24986+           tp->num_Strings++;
     24987            tp->Strings = typeRealloc(char *, tp->num_Strings, tp->Strings);
     24988-           for (last = tp->num_Strings - 1; last > tindex; last--)
     24989+           for_each_value(tp->num_Strings)
     24990                tp->Strings[last] = tp->Strings[last - 1];
     24991            break;
     24992        }
     24993@@ -170,7 +174,7 @@
     24994 
     24995     temp.nte_name = tp->ext_Names[offset];
     24996     temp.nte_type = token_type;
     24997-    temp.nte_index = tindex;
     24998+    temp.nte_index = (short) tindex;
     24999     temp.nte_link = -1;
     25000 
     25001     return &temp;
     25002@@ -444,7 +448,7 @@
     25003 
     25004            case NUMBER:
     25005                entryp->tterm.Numbers[entry_ptr->nte_index] =
     25006-                   _nc_curr_token.tk_valnumber;
     25007+                   (short) _nc_curr_token.tk_valnumber;
     25008                break;
     25009 
     25010            case STRING:
     25011@@ -788,7 +792,7 @@
     25012        for (base = other_non_function_keys;
     25013             (cp = strchr(base, ',')) != 0;
     25014             base = cp + 1) {
     25015-           size_t len = cp - base;
     25016+           size_t len = (unsigned) (cp - base);
     25017 
     25018            for (ap = ko_xlate; ap->from; ap++) {
     25019                if (len == strlen(ap->from)
     25020diff -Naur ncurses-5.7.orig/ncurses/tinfo/setbuf.c ncurses-5.7/ncurses/tinfo/setbuf.c
     25021--- ncurses-5.7.orig/ncurses/tinfo/setbuf.c     2007-05-12 12:04:02.000000000 -0700
     25022+++ ncurses-5.7/ncurses/tinfo/setbuf.c  2009-06-05 14:01:51.000000000 -0700
     25023@@ -1,5 +1,5 @@
     25024 /****************************************************************************
     25025- * Copyright (c) 1998-2003,2007 Free Software Foundation, Inc.              *
     25026+ * Copyright (c) 1998-2007,2009 Free Software Foundation, Inc.              *
     25027  *                                                                          *
     25028  * Permission is hereby granted, free of charge, to any person obtaining a  *
     25029  * copy of this software and associated documentation files (the            *
     25030@@ -29,6 +29,8 @@
     25031 /****************************************************************************
     25032  *  Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1992,1995               *
     25033  *     and: Eric S. Raymond <esr@snark.thyrsus.com>                         *
     25034+ *     and: Thomas E. Dickey                        1996-on                 *
     25035+ *     and: Juergen Pfeifer                         2008                    *
     25036  ****************************************************************************/
     25037 
     25038 /*
     25039@@ -40,7 +42,7 @@
     25040 
     25041 #include <curses.priv.h>
     25042 
     25043-MODULE_ID("$Id: setbuf.c,v 1.13 2007/05/12 19:04:02 tom Exp $")
     25044+MODULE_ID("$Id: setbuf.c,v 1.14 2009/05/09 23:09:00 tom Exp $")
     25045 
     25046 /*
     25047  * If the output file descriptor is connected to a tty (the typical case) it
     25048@@ -98,11 +100,11 @@
     25049  * buffer.  So we disable this by default (there may yet be a workaround).
     25050  */
     25051 NCURSES_EXPORT(void)
     25052-_nc_set_buffer(FILE *ofp, bool buffered)
     25053+NCURSES_SP_NAME(_nc_set_buffer) (NCURSES_SP_DCLx FILE *ofp, bool buffered)
     25054 {
     25055     /* optional optimization hack -- do before any output to ofp */
     25056 #if HAVE_SETVBUF || HAVE_SETBUFFER
     25057-    if (SP->_buffered != buffered) {
     25058+    if (SP_PARM->_buffered != buffered) {
     25059        unsigned buf_len;
     25060        char *buf_ptr;
     25061 
     25062@@ -115,10 +117,10 @@
     25063 #endif
     25064        if (buffered != 0) {
     25065            buf_len = min(LINES * (COLS + 6), 2800);
     25066-           if ((buf_ptr = SP->_setbuf) == 0) {
     25067+           if ((buf_ptr = SP_PARM->_setbuf) == 0) {
     25068                if ((buf_ptr = typeMalloc(char, buf_len)) == NULL)
     25069                      return;
     25070-               SP->_setbuf = buf_ptr;
     25071+               SP_PARM->_setbuf = buf_ptr;
     25072                /* Don't try to free this! */
     25073            }
     25074 #if !USE_SETBUF_0
     25075@@ -144,7 +146,15 @@
     25076        (void) setbuffer(ofp, buf_ptr, (int) buf_len);
     25077 #endif
     25078 
     25079-       SP->_buffered = buffered;
     25080+       SP_PARM->_buffered = buffered;
     25081     }
     25082 #endif /* HAVE_SETVBUF || HAVE_SETBUFFER */
     25083 }
     25084+
     25085+#if NCURSES_SP_FUNCS
     25086+NCURSES_EXPORT(void)
     25087+_nc_set_buffer(FILE *ofp, bool buffered)
     25088+{
     25089+    return NCURSES_SP_NAME(_nc_set_buffer) (CURRENT_SCREEN, ofp, buffered);
     25090+}
     25091+#endif
    1968725092diff -Naur ncurses-5.7.orig/ncurses/tinfo/use_screen.c ncurses-5.7/ncurses/tinfo/use_screen.c
    1968825093--- ncurses-5.7.orig/ncurses/tinfo/use_screen.c 2008-06-07 12:16:56.000000000 -0700
    19689 +++ ncurses-5.7/ncurses/tinfo/use_screen.c      2009-02-28 20:38:58.443328118 -0800
     25094+++ ncurses-5.7/ncurses/tinfo/use_screen.c      2009-06-05 14:01:16.000000000 -0700
    1969025095@@ -32,7 +32,7 @@
    1969125096 
     
    1970625111 
    1970725112     code = func(screen, data);
     25113diff -Naur ncurses-5.7.orig/ncurses/tinfo/write_entry.c ncurses-5.7/ncurses/tinfo/write_entry.c
     25114--- ncurses-5.7.orig/ncurses/tinfo/write_entry.c        2008-08-03 12:24:00.000000000 -0700
     25115+++ ncurses-5.7/ncurses/tinfo/write_entry.c     2009-06-05 14:01:44.000000000 -0700
     25116@@ -1,5 +1,5 @@
     25117 /****************************************************************************
     25118- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     25119+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     25120  *                                                                          *
     25121  * Permission is hereby granted, free of charge, to any person obtaining a  *
     25122  * copy of this software and associated documentation files (the            *
     25123@@ -54,7 +54,7 @@
     25124 #define TRACE_OUT(p)           /*nothing */
     25125 #endif
     25126 
     25127-MODULE_ID("$Id: write_entry.c,v 1.72 2008/08/03 19:24:00 tom Exp $")
     25128+MODULE_ID("$Id: write_entry.c,v 1.73 2009/04/18 21:01:38 tom Exp $")
     25129 
     25130 static int total_written;
     25131 
     25132@@ -171,7 +171,11 @@
     25133        struct stat statbuf;
     25134 
     25135        if ((rc = stat(path, &statbuf)) < 0) {
     25136-           rc = mkdir(path, 0777);
     25137+           rc = mkdir(path
     25138+#if !defined(__MINGW32__)
     25139+                      ,0777
     25140+#endif
     25141+               );
     25142        } else if (_nc_access(path, R_OK | W_OK | X_OK) < 0) {
     25143            rc = -1;            /* permission denied */
     25144        } else if (!(S_ISDIR(statbuf.st_mode))) {
     25145@@ -338,6 +342,7 @@
     25146 
     25147            while (*other_names != '\0') {
     25148                ptr = other_names++;
     25149+               assert(ptr < buffer + sizeof(buffer) - 1);
     25150                while (*other_names != '|' && *other_names != '\0')
     25151                    other_names++;
     25152 
     25153@@ -385,7 +390,6 @@
     25154     }
     25155     while (*other_names != '\0') {
     25156        ptr = other_names++;
     25157-       assert(ptr < buffer + sizeof(buffer) - 1);
     25158        while (*other_names != '|' && *other_names != '\0')
     25159            other_names++;
     25160 
     25161@@ -468,18 +472,18 @@
     25162           unsigned want,
     25163           unsigned size)
     25164 {
     25165-    int have = (limit - *offset);
     25166+    unsigned have = (limit - *offset);
     25167 
     25168     want *= size;
     25169     if (have > 0) {
     25170-       if ((int) want > have)
     25171+       if (want > have)
     25172            want = have;
     25173        memcpy(dst + *offset, src, want);
     25174        *offset += want;
     25175     } else {
     25176        want = 0;
     25177     }
     25178-    return (int) (want / size);
     25179+    return (want / size);
     25180 }
     25181 
     25182 #define Write(buf, size, count) fake_write(buffer, offset, limit, (char *) buf, count, size)
     25183@@ -487,14 +491,15 @@
     25184 #undef LITTLE_ENDIAN           /* BSD/OS defines this as a feature macro */
     25185 #define HI(x)                  ((x) / 256)
     25186 #define LO(x)                  ((x) % 256)
     25187-#define LITTLE_ENDIAN(p, x)    (p)[0] = LO(x), (p)[1] = HI(x)
     25188+#define LITTLE_ENDIAN(p, x)    (p)[0] = (unsigned char)LO(x),  \
     25189+                                (p)[1] = (unsigned char)HI(x)
     25190 
     25191 #define WRITE_STRING(str) (Write(str, sizeof(char), strlen(str) + 1) == strlen(str) + 1)
     25192 
     25193 static int
     25194 compute_offsets(char **Strings, unsigned strmax, short *offsets)
     25195 {
     25196-    size_t nextfree = 0;
     25197+    int nextfree = 0;
     25198     unsigned i;
     25199 
     25200     for (i = 0; i < strmax; i++) {
     25201@@ -503,8 +508,8 @@
     25202        } else if (Strings[i] == CANCELLED_STRING) {
     25203            offsets[i] = -2;
     25204        } else {
     25205-           offsets[i] = nextfree;
     25206-           nextfree += strlen(Strings[i]) + 1;
     25207+           offsets[i] = (short) nextfree;
     25208+           nextfree += (int) strlen(Strings[i]) + 1;
     25209            TRACE_OUT(("put Strings[%d]=%s(%d)", (int) i,
     25210                       _nc_visbuf(Strings[i]), (int) nextfree));
     25211        }
     25212@@ -536,8 +541,8 @@
     25213 static unsigned
     25214 extended_Booleans(TERMTYPE *tp)
     25215 {
     25216-    unsigned short result = 0;
     25217-    unsigned short i;
     25218+    unsigned result = 0;
     25219+    unsigned i;
     25220 
     25221     for (i = 0; i < tp->ext_Booleans; ++i) {
     25222        if (tp->Booleans[BOOLCOUNT + i] == TRUE)
     25223@@ -549,8 +554,8 @@
     25224 static unsigned
     25225 extended_Numbers(TERMTYPE *tp)
     25226 {
     25227-    unsigned short result = 0;
     25228-    unsigned short i;
     25229+    unsigned result = 0;
     25230+    unsigned i;
     25231 
     25232     for (i = 0; i < tp->ext_Numbers; ++i) {
     25233        if (tp->Numbers[NUMCOUNT + i] != ABSENT_NUMERIC)
     25234@@ -597,7 +602,7 @@
     25235     size_t namelen, boolmax, nummax, strmax;
     25236     char zero = '\0';
     25237     size_t i;
     25238-    short nextfree;
     25239+    int nextfree;
     25240     short offsets[MAX_ENTRY_SIZE / 2];
     25241     unsigned char buf[MAX_ENTRY_SIZE];
     25242     unsigned last_bool = BOOLWRITE;
     25243@@ -690,7 +695,7 @@
     25244 
     25245 #if NCURSES_XNAMES
     25246     if (extended_object(tp)) {
     25247-       unsigned extcnt = NUM_EXT_NAMES(tp);
     25248+       unsigned extcnt = (unsigned) NUM_EXT_NAMES(tp);
     25249 
     25250        if (even_boundary(nextfree))
     25251            return (ERR);
    1970825252diff -Naur ncurses-5.7.orig/ncurses/trace/lib_traceatr.c ncurses-5.7/ncurses/trace/lib_traceatr.c
    1970925253--- ncurses-5.7.orig/ncurses/trace/lib_traceatr.c       2008-08-03 09:24:53.000000000 -0700
    19710 +++ ncurses-5.7/ncurses/trace/lib_traceatr.c    2009-02-28 20:38:59.863415840 -0800
     25254+++ ncurses-5.7/ncurses/trace/lib_traceatr.c    2009-06-05 14:01:51.000000000 -0700
    1971125255@@ -1,5 +1,5 @@
    1971225256 /****************************************************************************
     
    1972425268 
    1972525269 /*
    19726 @@ -39,7 +40,7 @@
     25270@@ -37,9 +38,12 @@
     25271  */
     25272 
    1972725273 #include <curses.priv.h>
    19728  #include <term.h>              /* acs_chars */
     25274-#include <term.h>              /* acs_chars */
    1972925275 
    1973025276-MODULE_ID("$Id: lib_traceatr.c,v 1.63 2008/08/03 16:24:53 tom Exp $")
    19731 +MODULE_ID("$Id: lib_traceatr.c,v 1.64 2009/02/28 21:10:20 tom Exp $")
     25277+#ifndef CUR
     25278+#define CUR SP_TERMTYPE
     25279+#endif
     25280+
     25281+MODULE_ID("$Id: lib_traceatr.c,v 1.66 2009/05/10 00:48:29 tom Exp $")
    1973225282 
    1973325283 #define COLOR_OF(c) ((c < 0) ? "default" : (c > 7 ? color_of(c) : colors[c].name))
    1973425284 
    19735 @@ -228,7 +229,7 @@
     25285@@ -186,6 +190,9 @@
     25286        unsigned int val;
     25287        const char *name;
     25288     } ALT_NAMES;
     25289+#if NCURSES_SP_FUNCS
     25290+    SCREEN *sp = CURRENT_SCREEN;
     25291+#endif
     25292     static const ALT_NAMES names[] =
     25293     {
     25294        {'l', "ACS_ULCORNER"},  /* upper left corner */
     25295@@ -228,7 +235,7 @@
    1973625296     if ((attr & A_ALTCHARSET) && (acs_chars != 0)) {
    1973725297        char *cp;
     
    1974225302        for (cp = acs_chars; cp[0] && cp[1]; cp += 2) {
    1974325303            if (ChCharOf(cp[1]) == ChCharOf(ch)) {
    19744 @@ -239,9 +240,9 @@
     25304@@ -239,9 +246,9 @@
    1974525305 
    1974625306        if (found != 0) {
     
    1975525315                }
    1975625316        }
    19757 @@ -260,7 +261,8 @@
     25317@@ -260,7 +267,9 @@
    1975825318        if ((found = _nc_altcharset_name(ChAttrOf(ch), ch)) != 0) {
    1975925319            (void) _nc_trace_bufcat(bufnum, found);
    1976025320        } else
    1976125321-           (void) _nc_trace_bufcat(bufnum, _nc_tracechar(SP, (int) ChCharOf(ch)));
    19762 +           (void) _nc_trace_bufcat(bufnum, _nc_tracechar(CURRENT_SCREEN,
    19763 +                                   (int) ChCharOf(ch)));
     25322+           (void) _nc_trace_bufcat(bufnum,
     25323+                                   _nc_tracechar(CURRENT_SCREEN,
     25324+                                                 (int) ChCharOf(ch)));
    1976425325 
    1976525326        if (ChAttrOf(ch) != A_NORMAL) {
    1976625327            (void) _nc_trace_bufcat(bufnum, " | ");
    19767 @@ -320,7 +322,7 @@
     25328@@ -320,7 +329,7 @@
    1976825329                        if (PUTC_ch != L'\0') {
    1976925330                            /* it could not be a multibyte sequence */
     
    1977425335                        }
    1977525336                        break;
    19776 @@ -329,7 +331,7 @@
     25337@@ -329,7 +338,7 @@
    1977725338                        if (n)
    1977825339                            (void) _nc_trace_bufcat(bufnum, ", ");
     
    1978525346diff -Naur ncurses-5.7.orig/ncurses/trace/lib_tracebits.c ncurses-5.7/ncurses/trace/lib_tracebits.c
    1978625347--- ncurses-5.7.orig/ncurses/trace/lib_tracebits.c      2008-08-03 09:09:26.000000000 -0700
    19787 +++ ncurses-5.7/ncurses/trace/lib_tracebits.c   2009-02-28 20:38:58.443328118 -0800
     25348+++ ncurses-5.7/ncurses/trace/lib_tracebits.c   2009-06-05 14:01:16.000000000 -0700
    1978825349@@ -33,9 +33,8 @@
    1978925350  ****************************************************************************/
     
    1979925360diff -Naur ncurses-5.7.orig/ncurses/trace/lib_trace.c ncurses-5.7/ncurses/trace/lib_trace.c
    1980025361--- ncurses-5.7.orig/ncurses/trace/lib_trace.c  2008-08-23 11:04:29.000000000 -0700
    19801 +++ ncurses-5.7/ncurses/trace/lib_trace.c       2009-02-28 20:38:59.859415560 -0800
     25362+++ ncurses-5.7/ncurses/trace/lib_trace.c       2009-06-05 14:01:18.000000000 -0700
    1980225363@@ -1,5 +1,5 @@
    1980325364 /****************************************************************************
     
    1985725418        _nc_prescreen._outchars += increment;
    1985825419 }
     25420diff -Naur ncurses-5.7.orig/ncurses/trace/lib_tracechr.c ncurses-5.7/ncurses/trace/lib_tracechr.c
     25421--- ncurses-5.7.orig/ncurses/trace/lib_tracechr.c       2008-08-03 08:39:29.000000000 -0700
     25422+++ ncurses-5.7/ncurses/trace/lib_tracechr.c    2009-06-05 14:01:44.000000000 -0700
     25423@@ -1,5 +1,5 @@
     25424 /****************************************************************************
     25425- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     25426+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     25427  *                                                                          *
     25428  * Permission is hereby granted, free of charge, to any person obtaining a  *
     25429  * copy of this software and associated documentation files (the            *
     25430@@ -39,7 +39,7 @@
     25431 
     25432 #include <ctype.h>
     25433 
     25434-MODULE_ID("$Id: lib_tracechr.c,v 1.19 2008/08/03 15:39:29 tom Exp $")
     25435+MODULE_ID("$Id: lib_tracechr.c,v 1.20 2009/04/18 22:48:29 tom Exp $")
     25436 
     25437 #ifdef TRACE
     25438 
     25439@@ -52,7 +52,7 @@
     25440                      : _nc_globals.tracechr_buf);
     25441 
     25442     if (ch > KEY_MIN || ch < 0) {
     25443-       name = _nc_keyname(sp, ch);
     25444+       name = safe_keyname(SP_PARM, ch);
     25445        if (name == 0 || *name == '\0')
     25446            name = "NULL";
     25447        (void) sprintf(MyBuffer, "'%.30s' = %#03o", name, ch);
     25448@@ -64,7 +64,7 @@
     25449         */
     25450        (void) sprintf(MyBuffer, "%#03o", ch);
     25451     } else {
     25452-       name = _nc_unctrl(sp, (chtype) ch);
     25453+       name = safe_unctrl(SP_PARM, (chtype) ch);
     25454        if (name == 0 || *name == 0)
     25455            name = "null";      /* shouldn't happen */
     25456        (void) sprintf(MyBuffer, "'%.30s' = %#03o", name, ch);
     25457@@ -75,7 +75,7 @@
     25458 NCURSES_EXPORT(char *)
     25459 _tracechar(int ch)
     25460 {
     25461-    return _nc_tracechar(SP, ch);
     25462+    return _nc_tracechar(CURRENT_SCREEN, ch);
     25463 }
     25464 #else
     25465 EMPTY_MODULE(_nc_lib_tracechr)
     25466diff -Naur ncurses-5.7.orig/ncurses/trace/lib_tracedmp.c ncurses-5.7/ncurses/trace/lib_tracedmp.c
     25467--- ncurses-5.7.orig/ncurses/trace/lib_tracedmp.c       2008-08-16 12:30:56.000000000 -0700
     25468+++ ncurses-5.7/ncurses/trace/lib_tracedmp.c    2009-06-05 14:01:44.000000000 -0700
     25469@@ -1,5 +1,5 @@
     25470 /****************************************************************************
     25471- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     25472+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     25473  *                                                                          *
     25474  * Permission is hereby granted, free of charge, to any person obtaining a  *
     25475  * copy of this software and associated documentation files (the            *
     25476@@ -39,7 +39,7 @@
     25477 #include <curses.priv.h>
     25478 #include <ctype.h>
     25479 
     25480-MODULE_ID("$Id: lib_tracedmp.c,v 1.31 2008/08/16 19:30:56 tom Exp $")
     25481+MODULE_ID("$Id: lib_tracedmp.c,v 1.32 2009/04/18 21:01:38 tom Exp $")
     25482 
     25483 #ifdef TRACE
     25484 
     25485@@ -68,7 +68,7 @@
     25486     if (width < win->_maxx)
     25487        ++width;
     25488     if (++width + 1 > (int) my_length) {
     25489-       my_length = 2 * (width + 1);
     25490+       my_length = (unsigned) (2 * (width + 1));
     25491        my_buffer = typeRealloc(char, my_length, my_buffer);
     25492     }
     25493 
     25494@@ -82,7 +82,7 @@
     25495         * we map those to '.' and '?' respectively.
     25496         */
     25497        for (j = 0; j < width; ++j) {
     25498-           chtype test = CharOf(win->_line[n].text[j]);
     25499+           chtype test = (chtype) CharOf(win->_line[n].text[j]);
     25500            ep[j] = (char) ((UChar(test) == test
     25501 #if USE_WIDEC_SUPPORT
     25502                             && (win->_line[n].text[j].chars[1] == 0)
     25503@@ -111,7 +111,7 @@
     25504            if (multicolumn) {
     25505                ep = my_buffer;
     25506                for (j = 0; j < width; ++j) {
     25507-                   int test = WidecExt(win->_line[n].text[j]);
     25508+                   chtype test = WidecExt(win->_line[n].text[j]);
     25509                    if (test) {
     25510                        ep[j] = (char) (test + '0');
     25511                    } else {
     25512@@ -153,7 +153,7 @@
     25513 
     25514        for (i = 0; i < 4; ++i) {
     25515            const char *hex = " 123456789ABCDEF";
     25516-           attr_t mask = (0xf << ((i + 4) * 4));
     25517+           attr_t mask = (attr_t) (0xf << ((i + 4) * 4));
     25518 
     25519            haveattrs = FALSE;
     25520            for (j = 0; j < width; ++j)
    1985925521diff -Naur ncurses-5.7.orig/ncurses/trace/lib_tracemse.c ncurses-5.7/ncurses/trace/lib_tracemse.c
    1986025522--- ncurses-5.7.orig/ncurses/trace/lib_tracemse.c       2008-08-03 08:39:29.000000000 -0700
    19861 +++ ncurses-5.7/ncurses/trace/lib_tracemse.c    2009-02-28 20:38:58.443328118 -0800
     25523+++ ncurses-5.7/ncurses/trace/lib_tracemse.c    2009-06-05 14:01:16.000000000 -0700
    1986225524@@ -38,7 +38,7 @@
    1986325525 
     
    1987825540 
    1987925541 #else /* !TRACE */
     25542diff -Naur ncurses-5.7.orig/ncurses/trace/trace_tries.c ncurses-5.7/ncurses/trace/trace_tries.c
     25543--- ncurses-5.7.orig/ncurses/trace/trace_tries.c        2008-08-03 08:43:30.000000000 -0700
     25544+++ ncurses-5.7/ncurses/trace/trace_tries.c     2009-06-05 14:01:30.000000000 -0700
     25545@@ -1,5 +1,5 @@
     25546 /****************************************************************************
     25547- * Copyright (c) 1999-2007,2008 Free Software Foundation, Inc.              *
     25548+ * Copyright (c) 1999-2008,2009 Free Software Foundation, Inc.              *
     25549  *                                                                          *
     25550  * Permission is hereby granted, free of charge, to any person obtaining a  *
     25551  * copy of this software and associated documentation files (the            *
     25552@@ -35,7 +35,7 @@
     25553 
     25554 #include <curses.priv.h>
     25555 
     25556-MODULE_ID("$Id: trace_tries.c,v 1.13 2008/08/03 15:43:30 tom Exp $")
     25557+MODULE_ID("$Id: trace_tries.c,v 1.14 2009/03/28 20:44:01 tom Exp $")
     25558 
     25559 #ifdef TRACE
     25560 #define my_buffer _nc_globals.tracetry_buf
     25561@@ -46,7 +46,7 @@
     25562 {
     25563     if (level > my_length) {
     25564        my_length = (level + 1) * 4;
     25565-       my_buffer = (unsigned char *) realloc(my_buffer, my_length);
     25566+       my_buffer = (unsigned char *) _nc_doalloc(my_buffer, my_length);
     25567     }
     25568 
     25569     while (tree != 0) {
    1988025570diff -Naur ncurses-5.7.orig/ncurses/trace/varargs.c ncurses-5.7/ncurses/trace/varargs.c
    1988125571--- ncurses-5.7.orig/ncurses/trace/varargs.c    2008-08-03 08:42:49.000000000 -0700
    19882 +++ ncurses-5.7/ncurses/trace/varargs.c 2009-02-28 20:38:58.443328118 -0800
     25572+++ ncurses-5.7/ncurses/trace/varargs.c 2009-06-05 14:01:16.000000000 -0700
    1988325573@@ -34,7 +34,7 @@
    1988425574 
     
    1989925589 #define VA_PTR(type) pval = (char *)va_arg(ap, type)
    1990025590 #define VA_STR(type) sval = va_arg(ap, type)
     25591diff -Naur ncurses-5.7.orig/ncurses/tty/hardscroll.c ncurses-5.7/ncurses/tty/hardscroll.c
     25592--- ncurses-5.7.orig/ncurses/tty/hardscroll.c   2008-08-03 16:49:30.000000000 -0700
     25593+++ ncurses-5.7/ncurses/tty/hardscroll.c        2009-06-05 14:01:44.000000000 -0700
     25594@@ -1,5 +1,5 @@
     25595 /****************************************************************************
     25596- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     25597+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     25598  *                                                                          *
     25599  * Permission is hereby granted, free of charge, to any person obtaining a  *
     25600  * copy of this software and associated documentation files (the            *
     25601@@ -147,90 +147,96 @@
     25602 
     25603 #include <curses.priv.h>
     25604 
     25605-MODULE_ID("$Id: hardscroll.c,v 1.42 2008/08/03 23:49:30 tom Exp $")
     25606+MODULE_ID("$Id: hardscroll.c,v 1.43 2009/04/18 21:41:30 tom Exp $")
     25607 
     25608 #if defined(SCROLLDEBUG) || defined(HASHDEBUG)
     25609 
     25610 # undef screen_lines
     25611-# define screen_lines MAXLINES
     25612-NCURSES_EXPORT_VAR(int)
     25613-oldnums[MAXLINES];
     25614-# define OLDNUM(n)     oldnums[n]
     25615+# define screen_lines(sp) MAXLINES
     25616+NCURSES_EXPORT_VAR (int)
     25617+  oldnums[MAXLINES];
     25618+# define OLDNUM(sp,n)  oldnums[n]
     25619 # define _tracef       printf
     25620 # undef TR
     25621 # define TR(n, a)      if (_nc_tracing & (n)) { _tracef a ; putchar('\n'); }
     25622 
     25623-extern NCURSES_EXPORT_VAR(unsigned) _nc_tracing;
     25624+extern                         NCURSES_EXPORT_VAR(unsigned) _nc_tracing;
     25625 
     25626 #else /* no debug */
     25627 
     25628 /* OLDNUM(n) indicates which line will be shifted to the position n.
     25629    if OLDNUM(n) == _NEWINDEX, then the line n in new, not shifted from
     25630    somewhere. */
     25631-NCURSES_EXPORT_VAR(int *)
     25632-_nc_oldnums = 0;               /* obsolete: keep for ABI compat */
     25633+NCURSES_EXPORT_VAR (int *)
     25634+  _nc_oldnums = 0;             /* obsolete: keep for ABI compat */
     25635 
     25636 # if USE_HASHMAP
     25637-#  define oldnums       SP->_oldnum_list
     25638-#  define OLDNUM(n)    oldnums[n]
     25639+#  define oldnums(sp)   (sp)->_oldnum_list
     25640+#  define OLDNUM(sp,n) oldnums(sp)[n]
     25641 # else                         /* !USE_HASHMAP */
     25642-#  define OLDNUM(n)    newscr->_line[n].oldindex
     25643+#  define OLDNUM(sp,n) sp->_newscr->_line[n].oldindex
     25644 # endif                                /* !USE_HASHMAP */
     25645 
     25646-#define OLDNUM_SIZE     SP->_oldnum_size
     25647+#define OLDNUM_SIZE(sp) (sp)->_oldnum_size
     25648 
     25649 #endif /* defined(SCROLLDEBUG) || defined(HASHDEBUG) */
     25650 
     25651 NCURSES_EXPORT(void)
     25652-_nc_scroll_optimize(void)
     25653+NCURSES_SP_NAME(_nc_scroll_optimize) (NCURSES_SP_DCL0)
     25654 /* scroll optimization to transform curscr to newscr */
     25655 {
     25656     int i;
     25657     int start, end, shift;
     25658 
     25659-    TR(TRACE_ICALLS, (T_CALLED("_nc_scroll_optimize")));
     25660+    TR(TRACE_ICALLS, (T_CALLED("_nc_scroll_optimize(%p)"), SP_PARM));
     25661 
     25662 #if !defined(SCROLLDEBUG) && !defined(HASHDEBUG)
     25663 #if USE_HASHMAP
     25664     /* get enough storage */
     25665-    if (OLDNUM_SIZE < screen_lines) {
     25666-       int *new_oldnums = typeRealloc(int, screen_lines, oldnums);
     25667+    if (OLDNUM_SIZE(SP_PARM) < screen_lines(SP_PARM)) {
     25668+       int *new_oldnums = typeRealloc(int, screen_lines(SP_PARM), oldnums(SP_PARM));
     25669        if (!new_oldnums)
     25670            return;
     25671-       oldnums = new_oldnums;
     25672-       OLDNUM_SIZE = screen_lines;
     25673+       oldnums(SP_PARM) = new_oldnums;
     25674+       OLDNUM_SIZE(SP_PARM) = screen_lines(SP_PARM);
     25675     }
     25676     /* calculate the indices */
     25677-    _nc_hash_map();
     25678+    NCURSES_SP_NAME(_nc_hash_map) (NCURSES_SP_ARG);
     25679 #endif
     25680 #endif /* !defined(SCROLLDEBUG) && !defined(HASHDEBUG) */
     25681 
     25682 #ifdef TRACE
     25683     if (USE_TRACEF(TRACE_UPDATE | TRACE_MOVE)) {
     25684-       _nc_linedump();
     25685+       NCURSES_SP_NAME(_nc_linedump) (NCURSES_SP_ARG);
     25686        _nc_unlock_global(tracef);
     25687     }
     25688 #endif /* TRACE */
     25689 
     25690     /* pass 1 - from top to bottom scrolling up */
     25691-    for (i = 0; i < screen_lines;) {
     25692-       while (i < screen_lines && (OLDNUM(i) == _NEWINDEX || OLDNUM(i) <= i))
     25693+    for (i = 0; i < screen_lines(SP_PARM);) {
     25694+       while (i < screen_lines(SP_PARM)
     25695+              && (OLDNUM(SP_PARM, i) == _NEWINDEX || OLDNUM(SP_PARM, i) <= i))
     25696            i++;
     25697-       if (i >= screen_lines)
     25698+       if (i >= screen_lines(SP_PARM))
     25699            break;
     25700 
     25701-       shift = OLDNUM(i) - i;  /* shift > 0 */
     25702+       shift = OLDNUM(SP_PARM, i) - i;         /* shift > 0 */
     25703        start = i;
     25704 
     25705        i++;
     25706-       while (i < screen_lines && OLDNUM(i) != _NEWINDEX && OLDNUM(i) - i
     25707-              == shift)
     25708+       while (i < screen_lines(SP_PARM)
     25709+              && OLDNUM(SP_PARM, i) != _NEWINDEX
     25710+              && OLDNUM(SP_PARM, i) - i == shift)
     25711            i++;
     25712        end = i - 1 + shift;
     25713 
     25714        TR(TRACE_UPDATE | TRACE_MOVE, ("scroll [%d, %d] by %d", start, end, shift));
     25715 #if !defined(SCROLLDEBUG) && !defined(HASHDEBUG)
     25716-       if (_nc_scrolln(shift, start, end, screen_lines - 1) == ERR) {
     25717+       if (NCURSES_SP_NAME(_nc_scrolln) (NCURSES_SP_ARGx
     25718+                                         shift,
     25719+                                         start,
     25720+                                         end,
     25721+                                         screen_lines(SP_PARM) - 1) == ERR) {
     25722            TR(TRACE_UPDATE | TRACE_MOVE, ("unable to scroll"));
     25723            continue;
     25724        }
     25725@@ -238,23 +244,33 @@
     25726     }
     25727 
     25728     /* pass 2 - from bottom to top scrolling down */
     25729-    for (i = screen_lines - 1; i >= 0;) {
     25730-       while (i >= 0 && (OLDNUM(i) == _NEWINDEX || OLDNUM(i) >= i))
     25731+    for (i = screen_lines(SP_PARM) - 1; i >= 0;) {
     25732+       while (i >= 0
     25733+              && (OLDNUM(SP_PARM, i) == _NEWINDEX
     25734+                  || OLDNUM(SP_PARM, i) >= i)) {
     25735            i--;
     25736+       }
     25737        if (i < 0)
     25738            break;
     25739 
     25740-       shift = OLDNUM(i) - i;  /* shift < 0 */
     25741+       shift = OLDNUM(SP_PARM, i) - i;         /* shift < 0 */
     25742        end = i;
     25743 
     25744        i--;
     25745-       while (i >= 0 && OLDNUM(i) != _NEWINDEX && OLDNUM(i) - i == shift)
     25746+       while (i >= 0
     25747+              && OLDNUM(SP_PARM, i) != _NEWINDEX
     25748+              && OLDNUM(SP_PARM, i) - i == shift) {
     25749            i--;
     25750+       }
     25751        start = i + 1 - (-shift);
     25752 
     25753        TR(TRACE_UPDATE | TRACE_MOVE, ("scroll [%d, %d] by %d", start, end, shift));
     25754 #if !defined(SCROLLDEBUG) && !defined(HASHDEBUG)
     25755-       if (_nc_scrolln(shift, start, end, screen_lines - 1) == ERR) {
     25756+       if (NCURSES_SP_NAME(_nc_scrolln) (NCURSES_SP_ARGx
     25757+                                         shift,
     25758+                                         start,
     25759+                                         end,
     25760+                                         screen_lines(SP_PARM) - 1) == ERR) {
     25761            TR(TRACE_UPDATE | TRACE_MOVE, ("unable to scroll"));
     25762            continue;
     25763        }
     25764@@ -263,24 +279,41 @@
     25765     TR(TRACE_ICALLS, (T_RETURN("")));
     25766 }
     25767 
     25768+#if NCURSES_SP_FUNCS
     25769+NCURSES_EXPORT(void)
     25770+_nc_scroll_optimize(void)
     25771+{
     25772+    NCURSES_SP_NAME(_nc_scroll_optimize) (CURRENT_SCREEN);
     25773+}
     25774+#endif
     25775+
     25776 #if defined(TRACE) || defined(SCROLLDEBUG) || defined(HASHDEBUG)
     25777 NCURSES_EXPORT(void)
     25778-_nc_linedump(void)
     25779+NCURSES_SP_NAME(_nc_linedump) (NCURSES_SP_DCL0)
     25780 /* dump the state of the real and virtual oldnum fields */
     25781 {
     25782     int n;
     25783     char *buf = 0;
     25784-    size_t want = (screen_lines + 1) * 4;
     25785+    size_t want = (screen_lines(SP_PARM) + 1) * 4;
     25786 
     25787     if ((buf = typeMalloc(char, want)) != 0) {
     25788 
     25789        (void) strcpy(buf, "virt");
     25790-       for (n = 0; n < screen_lines; n++)
     25791-           (void) sprintf(buf + strlen(buf), " %02d", OLDNUM(n));
     25792+       for (n = 0; n < screen_lines(SP_PARM); n++)
     25793+           (void) sprintf(buf + strlen(buf), " %02d", OLDNUM(SP_PARM, n));
     25794        TR(TRACE_UPDATE | TRACE_MOVE, (buf));
     25795        free(buf);
     25796     }
     25797 }
     25798+
     25799+#if NCURSES_SP_FUNCS
     25800+NCURSES_EXPORT(void)
     25801+_nc_linedump(void)
     25802+{
     25803+    NCURSES_SP_NAME(_nc_linedump) (CURRENT_SCREEN);
     25804+}
     25805+#endif
     25806+
     25807 #endif /* defined(TRACE) || defined(SCROLLDEBUG) */
     25808 
     25809 #ifdef SCROLLDEBUG
     25810diff -Naur ncurses-5.7.orig/ncurses/tty/hashmap.c ncurses-5.7/ncurses/tty/hashmap.c
     25811--- ncurses-5.7.orig/ncurses/tty/hashmap.c      2007-10-13 11:47:25.000000000 -0700
     25812+++ ncurses-5.7/ncurses/tty/hashmap.c   2009-06-05 14:01:51.000000000 -0700
     25813@@ -1,5 +1,5 @@
     25814 /****************************************************************************
     25815- * Copyright (c) 1998-2006,2007 Free Software Foundation, Inc.                   *
     25816+ * Copyright (c) 1998-2007,2009 Free Software Foundation, Inc.              *
     25817  *                                                                          *
     25818  * Permission is hereby granted, free of charge, to any person obtaining a  *
     25819  * copy of this software and associated documentation files (the            *
     25820@@ -68,9 +68,12 @@
     25821 *****************************************************************************/
     25822 
     25823 #include <curses.priv.h>
     25824-#include <term.h>              /* for back_color_erase */
     25825 
     25826-MODULE_ID("$Id: hashmap.c,v 1.56 2007/10/13 18:47:25 Miroslav.Lichvar Exp $")
     25827+#ifndef CUR
     25828+#define CUR SP_TERMTYPE
     25829+#endif
     25830+
     25831+MODULE_ID("$Id: hashmap.c,v 1.59 2009/05/10 00:51:57 tom Exp $")
     25832 
     25833 #ifdef HASHDEBUG
     25834 
     25835@@ -83,25 +86,25 @@
     25836 int oldnums[MAXLINES], reallines[MAXLINES];
     25837 static NCURSES_CH_T oldtext[MAXLINES][TEXTWIDTH];
     25838 static NCURSES_CH_T newtext[MAXLINES][TEXTWIDTH];
     25839-# define OLDNUM(n)     oldnums[n]
     25840-# define OLDTEXT(n)    oldtext[n]
     25841-# define NEWTEXT(m)    newtext[m]
     25842-# define PENDING(n)     1
     25843+# define OLDNUM(sp,n)  oldnums[n]
     25844+# define OLDTEXT(sp,n) oldtext[n]
     25845+# define NEWTEXT(sp,m) newtext[m]
     25846+# define PENDING(sp,n)  1
     25847 
     25848 #else /* !HASHDEBUG */
     25849 
     25850-# define OLDNUM(n)     SP->_oldnum_list[n]
     25851-# define OLDTEXT(n)    curscr->_line[n].text
     25852-# define NEWTEXT(m)    newscr->_line[m].text
     25853-# define TEXTWIDTH     (curscr->_maxx+1)
     25854-# define PENDING(n)     (newscr->_line[n].firstchar != _NOCHANGE)
     25855+# define OLDNUM(sp,n)  (sp)->_oldnum_list[n]
     25856+# define OLDTEXT(sp,n) (sp)->_curscr->_line[n].text
     25857+# define NEWTEXT(sp,m) (sp)->_newscr->_line[m].text
     25858+# define TEXTWIDTH(sp) ((sp)->_curscr->_maxx+1)
     25859+# define PENDING(sp,n)  ((sp)->_newscr->_line[n].firstchar != _NOCHANGE)
     25860 
     25861 #endif /* !HASHDEBUG */
     25862 
     25863-#define oldhash                (SP->oldhash)
     25864-#define newhash                (SP->newhash)
     25865-#define hashtab                (SP->hashtab)
     25866-#define lines_alloc    (SP->hashtab_len)
     25867+#define oldhash(sp)    ((sp)->oldhash)
     25868+#define newhash(sp)    ((sp)->newhash)
     25869+#define hashtab(sp)    ((sp)->hashtab)
     25870+#define lines_alloc(sp)        ((sp)->hashtab_len)
     25871 
     25872 #if USE_WIDEC_SUPPORT
     25873 #define HASH_VAL(ch) (ch.chars[0])
     25874@@ -112,12 +115,12 @@
     25875 static const NCURSES_CH_T blankchar = NewChar(BLANK_TEXT);
     25876 
     25877 static NCURSES_INLINE unsigned long
     25878-hash(NCURSES_CH_T * text)
     25879+hash(SCREEN *sp, NCURSES_CH_T * text)
     25880 {
     25881     int i;
     25882     NCURSES_CH_T ch;
     25883     unsigned long result = 0;
     25884-    for (i = TEXTWIDTH; i > 0; i--) {
     25885+    for (i = TEXTWIDTH(sp); i > 0; i--) {
     25886        ch = *text++;
     25887        result += (result << 5) + HASH_VAL(ch);
     25888     }
     25889@@ -126,12 +129,12 @@
     25890 
     25891 /* approximate update cost */
     25892 static int
     25893-update_cost(NCURSES_CH_T * from, NCURSES_CH_T * to)
     25894+update_cost(SCREEN *sp, NCURSES_CH_T * from, NCURSES_CH_T * to)
     25895 {
     25896     int cost = 0;
     25897     int i;
     25898 
     25899-    for (i = TEXTWIDTH; i > 0; i--, from++, to++)
     25900+    for (i = TEXTWIDTH(sp); i > 0; i--, from++, to++)
     25901        if (!(CharEq(*from, *to)))
     25902            cost++;
     25903 
     25904@@ -139,7 +142,7 @@
     25905 }
     25906 
     25907 static int
     25908-update_cost_from_blank(NCURSES_CH_T * to)
     25909+update_cost_from_blank(SCREEN *sp, NCURSES_CH_T * to)
     25910 {
     25911     int cost = 0;
     25912     int i;
     25913@@ -148,7 +151,7 @@
     25914     if (back_color_erase)
     25915        SetPair(blank, GetPair(stdscr->_nc_bkgd));
     25916 
     25917-    for (i = TEXTWIDTH; i > 0; i--, to++)
     25918+    for (i = TEXTWIDTH(sp); i > 0; i--, to++)
     25919        if (!(CharEq(blank, *to)))
     25920            cost++;
     25921 
     25922@@ -160,14 +163,14 @@
     25923  * effective. 'blank' indicates whether the line 'to' would become blank.
     25924  */
     25925 static NCURSES_INLINE bool
     25926-cost_effective(const int from, const int to, const bool blank)
     25927+cost_effective(SCREEN *sp, const int from, const int to, const bool blank)
     25928 {
     25929     int new_from;
     25930 
     25931     if (from == to)
     25932        return FALSE;
     25933 
     25934-    new_from = OLDNUM(from);
     25935+    new_from = OLDNUM(sp, from);
     25936     if (new_from == _NEWINDEX)
     25937        new_from = from;
     25938 
     25939@@ -175,16 +178,17 @@
     25940      * On the left side of >= is the cost before moving;
     25941      * on the right side -- cost after moving.
     25942      */
     25943-    return (((blank ? update_cost_from_blank(NEWTEXT(to))
     25944-             : update_cost(OLDTEXT(to), NEWTEXT(to)))
     25945-            + update_cost(OLDTEXT(new_from), NEWTEXT(from)))
     25946-           >= ((new_from == from ? update_cost_from_blank(NEWTEXT(from))
     25947-                : update_cost(OLDTEXT(new_from), NEWTEXT(from)))
     25948-               + update_cost(OLDTEXT(from), NEWTEXT(to)))) ? TRUE : FALSE;
     25949+    return (((blank ? update_cost_from_blank(sp, NEWTEXT(sp, to))
     25950+             : update_cost(sp, OLDTEXT(sp, to), NEWTEXT(sp, to)))
     25951+            + update_cost(sp, OLDTEXT(sp, new_from), NEWTEXT(sp, from)))
     25952+           >= ((new_from == from ? update_cost_from_blank(sp, NEWTEXT(sp, from))
     25953+                : update_cost(sp, OLDTEXT(sp, new_from), NEWTEXT(sp, from)))
     25954+               + update_cost(sp, OLDTEXT(sp, from), NEWTEXT(sp, to))))
     25955+       ? TRUE : FALSE;
     25956 }
     25957 
     25958 static void
     25959-grow_hunks(void)
     25960+grow_hunks(SCREEN *sp)
     25961 {
     25962     int start, end, shift;
     25963     int back_limit, forward_limit;     /* limits for cells to fill */
     25964@@ -200,35 +204,36 @@
     25965     back_ref_limit = 0;
     25966 
     25967     i = 0;
     25968-    while (i < screen_lines && OLDNUM(i) == _NEWINDEX)
     25969+    while (i < screen_lines(sp) && OLDNUM(sp, i) == _NEWINDEX)
     25970        i++;
     25971-    for (; i < screen_lines; i = next_hunk) {
     25972+    for (; i < screen_lines(sp); i = next_hunk) {
     25973        start = i;
     25974-       shift = OLDNUM(i) - i;
     25975+       shift = OLDNUM(sp, i) - i;
     25976 
     25977        /* get forward limit */
     25978        i = start + 1;
     25979-       while (i < screen_lines && OLDNUM(i) != _NEWINDEX && OLDNUM(i) - i
     25980-              == shift)
     25981+       while (i < screen_lines(sp)
     25982+              && OLDNUM(sp, i) != _NEWINDEX
     25983+              && OLDNUM(sp, i) - i == shift)
     25984            i++;
     25985        end = i;
     25986-       while (i < screen_lines && OLDNUM(i) == _NEWINDEX)
     25987+       while (i < screen_lines(sp) && OLDNUM(sp, i) == _NEWINDEX)
     25988            i++;
     25989        next_hunk = i;
     25990        forward_limit = i;
     25991-       if (i >= screen_lines || OLDNUM(i) >= i)
     25992+       if (i >= screen_lines(sp) || OLDNUM(sp, i) >= i)
     25993            forward_ref_limit = i;
     25994        else
     25995-           forward_ref_limit = OLDNUM(i);
     25996+           forward_ref_limit = OLDNUM(sp, i);
     25997 
     25998        i = start - 1;
     25999        /* grow back */
     26000        if (shift < 0)
     26001            back_limit = back_ref_limit + (-shift);
     26002        while (i >= back_limit) {
     26003-           if (newhash[i] == oldhash[i + shift]
     26004-               || cost_effective(i + shift, i, shift < 0)) {
     26005-               OLDNUM(i) = i + shift;
     26006+           if (newhash(sp)[i] == oldhash(sp)[i + shift]
     26007+               || cost_effective(sp, i + shift, i, shift < 0)) {
     26008+               OLDNUM(sp, i) = i + shift;
     26009                TR(TRACE_UPDATE | TRACE_MOVE,
     26010                   ("connected new line %d to old line %d (backward continuation)",
     26011                    i, i + shift));
     26012@@ -246,9 +251,9 @@
     26013        if (shift > 0)
     26014            forward_limit = forward_ref_limit - shift;
     26015        while (i < forward_limit) {
     26016-           if (newhash[i] == oldhash[i + shift]
     26017-               || cost_effective(i + shift, i, shift > 0)) {
     26018-               OLDNUM(i) = i + shift;
     26019+           if (newhash(sp)[i] == oldhash(sp)[i + shift]
     26020+               || cost_effective(sp, i + shift, i, shift > 0)) {
     26021+               OLDNUM(sp, i) = i + shift;
     26022                TR(TRACE_UPDATE | TRACE_MOVE,
     26023                   ("connected new line %d to old line %d (forward continuation)",
     26024                    i, i + shift));
     26025@@ -268,51 +273,53 @@
     26026 }
     26027 
     26028 NCURSES_EXPORT(void)
     26029-_nc_hash_map(void)
     26030+NCURSES_SP_NAME(_nc_hash_map) (NCURSES_SP_DCL0)
     26031 {
     26032-    HASHMAP *sp;
     26033+    HASHMAP *hsp;
     26034     register int i;
     26035     int start, shift, size;
     26036 
     26037-    if (screen_lines > lines_alloc) {
     26038-       if (hashtab)
     26039-           free(hashtab);
     26040-       hashtab = typeMalloc(HASHMAP, (screen_lines + 1) * 2);
     26041-       if (!hashtab) {
     26042-           if (oldhash) {
     26043-               FreeAndNull(oldhash);
     26044+    if (screen_lines(SP_PARM) > lines_alloc(SP_PARM)) {
     26045+       if (hashtab(SP_PARM))
     26046+           free(hashtab(SP_PARM));
     26047+       hashtab(SP_PARM) = typeMalloc(HASHMAP, (screen_lines(SP_PARM) + 1) * 2);
     26048+       if (!hashtab(SP_PARM)) {
     26049+           if (oldhash(SP_PARM)) {
     26050+               FreeAndNull(oldhash(SP_PARM));
     26051            }
     26052-           lines_alloc = 0;
     26053+           lines_alloc(SP_PARM) = 0;
     26054            return;
     26055        }
     26056-       lines_alloc = screen_lines;
     26057+       lines_alloc(SP_PARM) = screen_lines(SP_PARM);
     26058     }
     26059 
     26060-    if (oldhash && newhash) {
     26061+    if (oldhash(SP_PARM) && newhash(SP_PARM)) {
     26062        /* re-hash only changed lines */
     26063-       for (i = 0; i < screen_lines; i++) {
     26064-           if (PENDING(i))
     26065-               newhash[i] = hash(NEWTEXT(i));
     26066+       for (i = 0; i < screen_lines(SP_PARM); i++) {
     26067+           if (PENDING(SP_PARM, i))
     26068+               newhash(SP_PARM)[i] = hash(SP_PARM, NEWTEXT(SP_PARM, i));
     26069        }
     26070     } else {
     26071        /* re-hash all */
     26072-       if (oldhash == 0)
     26073-           oldhash = typeCalloc(unsigned long, (unsigned) screen_lines);
     26074-       if (newhash == 0)
     26075-           newhash = typeCalloc(unsigned long, (unsigned) screen_lines);
     26076-       if (!oldhash || !newhash)
     26077+       if (oldhash(SP_PARM) == 0)
     26078+           oldhash(SP_PARM) = typeCalloc(unsigned long,
     26079+                                           (unsigned) screen_lines(SP_PARM));
     26080+       if (newhash(SP_PARM) == 0)
     26081+           newhash(SP_PARM) = typeCalloc(unsigned long,
     26082+                                           (unsigned) screen_lines(SP_PARM));
     26083+       if (!oldhash(SP_PARM) || !newhash(SP_PARM))
     26084            return;             /* malloc failure */
     26085-       for (i = 0; i < screen_lines; i++) {
     26086-           newhash[i] = hash(NEWTEXT(i));
     26087-           oldhash[i] = hash(OLDTEXT(i));
     26088+       for (i = 0; i < screen_lines(SP_PARM); i++) {
     26089+           newhash(SP_PARM)[i] = hash(SP_PARM, NEWTEXT(SP_PARM, i));
     26090+           oldhash(SP_PARM)[i] = hash(SP_PARM, OLDTEXT(SP_PARM, i));
     26091        }
     26092     }
     26093 
     26094 #ifdef HASH_VERIFY
     26095-    for (i = 0; i < screen_lines; i++) {
     26096-       if (newhash[i] != hash(NEWTEXT(i)))
     26097+    for (i = 0; i < screen_lines(SP_PARM); i++) {
     26098+       if (newhash(SP_PARM)[i] != hash(SP_PARM, NEWTEXT(SP_PARM, i)))
     26099            fprintf(stderr, "error in newhash[%d]\n", i);
     26100-       if (oldhash[i] != hash(OLDTEXT(i)))
     26101+       if (oldhash(SP_PARM)[i] != hash(SP_PARM, OLDTEXT(SP_PARM, i)))
     26102            fprintf(stderr, "error in oldhash[%d]\n", i);
     26103     }
     26104 #endif
     26105@@ -320,28 +327,29 @@
     26106     /*
     26107      * Set up and count line-hash values.
     26108      */
     26109-    memset(hashtab, '\0', sizeof(*hashtab) * (screen_lines + 1) * 2);
     26110-    for (i = 0; i < screen_lines; i++) {
     26111-       unsigned long hashval = oldhash[i];
     26112+    memset(hashtab(SP_PARM), '\0',
     26113+          sizeof(*(hashtab(SP_PARM))) * (screen_lines(SP_PARM) + 1) * 2);
     26114+    for (i = 0; i < screen_lines(SP_PARM); i++) {
     26115+       unsigned long hashval = oldhash(SP_PARM)[i];
     26116 
     26117-       for (sp = hashtab; sp->hashval; sp++)
     26118-           if (sp->hashval == hashval)
     26119+       for (hsp = hashtab(SP_PARM); hsp->hashval; hsp++)
     26120+           if (hsp->hashval == hashval)
     26121                break;
     26122-       sp->hashval = hashval;  /* in case this is a new entry */
     26123-       sp->oldcount++;
     26124-       sp->oldindex = i;
     26125+       hsp->hashval = hashval; /* in case this is a new entry */
     26126+       hsp->oldcount++;
     26127+       hsp->oldindex = i;
     26128     }
     26129-    for (i = 0; i < screen_lines; i++) {
     26130-       unsigned long hashval = newhash[i];
     26131+    for (i = 0; i < screen_lines(SP_PARM); i++) {
     26132+       unsigned long hashval = newhash(SP_PARM)[i];
     26133 
     26134-       for (sp = hashtab; sp->hashval; sp++)
     26135-           if (sp->hashval == hashval)
     26136+       for (hsp = hashtab(SP_PARM); hsp->hashval; hsp++)
     26137+           if (hsp->hashval == hashval)
     26138                break;
     26139-       sp->hashval = hashval;  /* in case this is a new entry */
     26140-       sp->newcount++;
     26141-       sp->newindex = i;
     26142+       hsp->hashval = hashval; /* in case this is a new entry */
     26143+       hsp->newcount++;
     26144+       hsp->newindex = i;
     26145 
     26146-       OLDNUM(i) = _NEWINDEX;  /* initialize old indices array */
     26147+       OLDNUM(SP_PARM, i) = _NEWINDEX;         /* initialize old indices array */
     26148     }
     26149 
     26150     /*
     26151@@ -351,16 +359,16 @@
     26152      * extending hunks by cost_effective. Otherwise, it does not
     26153      * have any side effects.
     26154      */
     26155-    for (sp = hashtab; sp->hashval; sp++)
     26156-       if (sp->oldcount == 1 && sp->newcount == 1
     26157-           && sp->oldindex != sp->newindex) {
     26158+    for (hsp = hashtab(SP_PARM); hsp->hashval; hsp++)
     26159+       if (hsp->oldcount == 1 && hsp->newcount == 1
     26160+           && hsp->oldindex != hsp->newindex) {
     26161            TR(TRACE_UPDATE | TRACE_MOVE,
     26162               ("new line %d is hash-identical to old line %d (unique)",
     26163-               sp->newindex, sp->oldindex));
     26164-           OLDNUM(sp->newindex) = sp->oldindex;
     26165+               hsp->newindex, hsp->oldindex));
     26166+           OLDNUM(SP_PARM, hsp->newindex) = hsp->oldindex;
     26167        }
     26168 
     26169-    grow_hunks();
     26170+    grow_hunks(SP_PARM);
     26171 
     26172     /*
     26173      * Eliminate bad or impossible shifts -- this includes removing
     26174@@ -368,58 +376,83 @@
     26175      * those which are to be moved too far, they are likely to destroy
     26176      * more than carry.
     26177      */
     26178-    for (i = 0; i < screen_lines;) {
     26179-       while (i < screen_lines && OLDNUM(i) == _NEWINDEX)
     26180+    for (i = 0; i < screen_lines(SP_PARM);) {
     26181+       while (i < screen_lines(SP_PARM) && OLDNUM(SP_PARM, i) == _NEWINDEX)
     26182            i++;
     26183-       if (i >= screen_lines)
     26184+       if (i >= screen_lines(SP_PARM))
     26185            break;
     26186        start = i;
     26187-       shift = OLDNUM(i) - i;
     26188+       shift = OLDNUM(SP_PARM, i) - i;
     26189        i++;
     26190-       while (i < screen_lines && OLDNUM(i) != _NEWINDEX && OLDNUM(i) - i
     26191-              == shift)
     26192+       while (i < screen_lines(SP_PARM)
     26193+              && OLDNUM(SP_PARM, i) != _NEWINDEX
     26194+              && OLDNUM(SP_PARM, i) - i == shift)
     26195            i++;
     26196        size = i - start;
     26197        if (size < 3 || size + min(size / 8, 2) < abs(shift)) {
     26198            while (start < i) {
     26199-               OLDNUM(start) = _NEWINDEX;
     26200+               OLDNUM(SP_PARM, start) = _NEWINDEX;
     26201                start++;
     26202            }
     26203        }
     26204     }
     26205 
     26206     /* After clearing invalid hunks, try grow the rest. */
     26207-    grow_hunks();
     26208+    grow_hunks(SP_PARM);
     26209 }
     26210 
     26211+#if NCURSES_SP_FUNCS
     26212+NCURSES_EXPORT(void)
     26213+_nc_hash_map(void)
     26214+{
     26215+    NCURSES_SP_NAME(_nc_hash_map) (CURRENT_SCREEN);
     26216+}
     26217+#endif
     26218+
     26219+NCURSES_EXPORT(void)
     26220+NCURSES_SP_NAME(_nc_make_oldhash) (NCURSES_SP_DCLx int i)
     26221+{
     26222+    if (oldhash(SP_PARM))
     26223+       oldhash(SP_PARM)[i] = hash(SP_PARM, OLDTEXT(SP_PARM, i));
     26224+}
     26225+
     26226+#if NCURSES_SP_FUNCS
     26227 NCURSES_EXPORT(void)
     26228 _nc_make_oldhash(int i)
     26229 {
     26230-    if (oldhash)
     26231-       oldhash[i] = hash(OLDTEXT(i));
     26232+    NCURSES_SP_NAME(_nc_make_oldhash) (CURRENT_SCREEN, i);
     26233 }
     26234+#endif
     26235 
     26236 NCURSES_EXPORT(void)
     26237-_nc_scroll_oldhash(int n, int top, int bot)
     26238+NCURSES_SP_NAME(_nc_scroll_oldhash) (NCURSES_SP_DCLx int n, int top, int bot)
     26239 {
     26240     size_t size;
     26241     int i;
     26242 
     26243-    if (!oldhash)
     26244+    if (!oldhash(SP_PARM))
     26245        return;
     26246 
     26247-    size = sizeof(*oldhash) * (bot - top + 1 - abs(n));
     26248+    size = sizeof(*(oldhash(SP_PARM))) * (bot - top + 1 - abs(n));
     26249     if (n > 0) {
     26250-       memmove(oldhash + top, oldhash + top + n, size);
     26251+       memmove(oldhash(SP_PARM) + top, oldhash(SP_PARM) + top + n, size);
     26252        for (i = bot; i > bot - n; i--)
     26253-           oldhash[i] = hash(OLDTEXT(i));
     26254+           oldhash(SP_PARM)[i] = hash(SP_PARM, OLDTEXT(SP_PARM, i));
     26255     } else {
     26256-       memmove(oldhash + top - n, oldhash + top, size);
     26257+       memmove(oldhash(SP_PARM) + top - n, oldhash(SP_PARM) + top, size);
     26258        for (i = top; i < top - n; i++)
     26259-           oldhash[i] = hash(OLDTEXT(i));
     26260+           oldhash(SP_PARM)[i] = hash(SP_PARM, OLDTEXT(SP_PARM, i));
     26261     }
     26262 }
     26263 
     26264+#if NCURSES_SP_FUNCS
     26265+NCURSES_EXPORT(void)
     26266+_nc_scroll_oldhash(int n, int top, int bot)
     26267+{
     26268+    NCURSES_SP_NAME(_nc_scroll_oldhash) (CURRENT_SCREEN, n, top, bot);
     26269+}
     26270+#endif
     26271+
     26272 #ifdef HASHDEBUG
     26273 static void
     26274 usage(void)
    1990126275diff -Naur ncurses-5.7.orig/ncurses/tty/lib_mvcur.c ncurses-5.7/ncurses/tty/lib_mvcur.c
    1990226276--- ncurses-5.7.orig/ncurses/tty/lib_mvcur.c    2008-08-16 12:30:58.000000000 -0700
    19903 +++ ncurses-5.7/ncurses/tty/lib_mvcur.c 2009-02-28 20:38:57.059236485 -0800
     26277+++ ncurses-5.7/ncurses/tty/lib_mvcur.c 2009-06-05 14:01:51.000000000 -0700
    1990426278@@ -1,5 +1,5 @@
    1990526279 /****************************************************************************
     
    1991726291 
    1991826292 /*
    19919 @@ -155,7 +156,7 @@
    19920  #include <term.h>
     26293@@ -109,8 +110,8 @@
     26294  * LONG_DIST and (b) further inward from the right or left edge than LONG_DIST,
     26295  * we'll consider nonlocal.
     26296  */
     26297-#define NOT_LOCAL(fy, fx, ty, tx)      ((tx > LONG_DIST) \
     26298-                && (tx < screen_columns - 1 - LONG_DIST) \
     26299+#define NOT_LOCAL(sp, fy, fx, ty, tx)  ((tx > LONG_DIST) \
     26300+                && (tx < screen_columns(sp) - 1 - LONG_DIST) \
     26301                 && (abs(ty-fy) + abs(tx-fx) > LONG_DIST))
     26302 
     26303 /****************************************************************************
     26304@@ -152,13 +153,16 @@
     26305  */
     26306 
     26307 #include <curses.priv.h>
     26308-#include <term.h>
    1992126309 #include <ctype.h>
    1992226310 
    1992326311-MODULE_ID("$Id: lib_mvcur.c,v 1.113 2008/08/16 19:30:58 tom Exp $")
    19924 +MODULE_ID("$Id: lib_mvcur.c,v 1.114 2009/02/15 00:50:33 tom Exp $")
    19925  
    19926  #define WANT_CHAR(y, x)        SP->_newscr->_line[y].text[x]   /* desired state */
    19927  #define BAUDRATE       cur_term->_baudrate     /* bits per second */
    19928 @@ -853,9 +854,10 @@
     26312+#ifndef CUR
     26313+#define CUR SP_TERMTYPE
     26314+#endif
     26315+
     26316+MODULE_ID("$Id: lib_mvcur.c,v 1.120 2009/05/10 00:52:29 tom Exp $")
     26317 
     26318-#define WANT_CHAR(y, x)        SP->_newscr->_line[y].text[x]   /* desired state */
     26319-#define BAUDRATE       cur_term->_baudrate     /* bits per second */
     26320+#define WANT_CHAR(sp, y, x) (sp)->_newscr->_line[y].text[x]    /* desired state */
     26321+#define BAUDRATE(sp)   cur_term->_baudrate     /* bits per second */
     26322 
     26323 #if defined(MAIN) || defined(NCURSES_TEST)
     26324 #include <sys/time.h>
     26325@@ -169,7 +173,7 @@
     26326 
     26327 #define OPT_SIZE 512
     26328 
     26329-static int normalized_cost(const char *const cap, int affcnt);
     26330+static int normalized_cost(NCURSES_SP_DCLx const char *const cap, int affcnt);
     26331 
     26332 /****************************************************************************
     26333  *
     26334@@ -179,34 +183,34 @@
     26335 
     26336 #ifdef TRACE
     26337 static int
     26338-trace_cost_of(const char *capname, const char *cap, int affcnt)
     26339+trace_cost_of(NCURSES_SP_DCLx const char *capname, const char *cap, int affcnt)
     26340 {
     26341-    int result = _nc_msec_cost(cap, affcnt);
     26342+    int result = NCURSES_SP_NAME(_nc_msec_cost) (NCURSES_SP_ARGx cap, affcnt);
     26343     TR(TRACE_CHARPUT | TRACE_MOVE,
     26344        ("CostOf %s %d %s", capname, result, _nc_visbuf(cap)));
     26345     return result;
     26346 }
     26347-#define CostOf(cap,affcnt) trace_cost_of(#cap,cap,affcnt);
     26348+#define CostOf(cap,affcnt) trace_cost_of(NCURSES_SP_ARGx #cap, cap, affcnt)
     26349 
     26350 static int
     26351-trace_normalized_cost(const char *capname, const char *cap, int affcnt)
     26352+trace_normalized_cost(NCURSES_SP_DCLx const char *capname, const char *cap, int affcnt)
     26353 {
     26354-    int result = normalized_cost(cap, affcnt);
     26355+    int result = normalized_cost(NCURSES_SP_ARGx cap, affcnt);
     26356     TR(TRACE_CHARPUT | TRACE_MOVE,
     26357        ("NormalizedCost %s %d %s", capname, result, _nc_visbuf(cap)));
     26358     return result;
     26359 }
     26360-#define NormalizedCost(cap,affcnt) trace_normalized_cost(#cap,cap,affcnt);
     26361+#define NormalizedCost(cap,affcnt) trace_normalized_cost(NCURSES_SP_ARGx #cap, cap, affcnt)
     26362 
     26363 #else
     26364 
     26365-#define CostOf(cap,affcnt) _nc_msec_cost(cap,affcnt);
     26366-#define NormalizedCost(cap,affcnt) normalized_cost(cap,affcnt);
     26367+#define CostOf(cap,affcnt) NCURSES_SP_NAME(_nc_msec_cost)(NCURSES_SP_ARGx cap, affcnt)
     26368+#define NormalizedCost(cap,affcnt) normalized_cost(NCURSES_SP_ARGx cap, affcnt)
     26369 
     26370 #endif
     26371 
     26372 NCURSES_EXPORT(int)
     26373-_nc_msec_cost(const char *const cap, int affcnt)
     26374+NCURSES_SP_NAME(_nc_msec_cost) (NCURSES_SP_DCLx const char *const cap, int affcnt)
     26375 /* compute the cost of a given operation */
     26376 {
     26377     if (cap == 0)
     26378@@ -230,45 +234,56 @@
     26379                }
     26380 
     26381 #if NCURSES_NO_PADDING
     26382-               if (!GetNoPadding(SP))
     26383+               if (!GetNoPadding(SP_PARM))
     26384 #endif
     26385                    cum_cost += number * 10;
     26386            } else
     26387-               cum_cost += SP->_char_padding;
     26388+               cum_cost += SP_PARM->_char_padding;
     26389        }
     26390 
     26391        return ((int) cum_cost);
     26392     }
     26393 }
     26394 
     26395+#if NCURSES_SP_FUNCS
     26396+NCURSES_EXPORT(int)
     26397+_nc_msec_cost(const char *const cap, int affcnt)
     26398+{
     26399+    return NCURSES_SP_NAME(_nc_msec_cost) (CURRENT_SCREEN, cap, affcnt);
     26400+}
     26401+#endif
     26402+
     26403 static int
     26404-normalized_cost(const char *const cap, int affcnt)
     26405+normalized_cost(NCURSES_SP_DCLx const char *const cap, int affcnt)
     26406 /* compute the effective character-count for an operation (round up) */
     26407 {
     26408-    int cost = _nc_msec_cost(cap, affcnt);
     26409+    int cost = NCURSES_SP_NAME(_nc_msec_cost) (NCURSES_SP_ARGx cap, affcnt);
     26410     if (cost != INFINITY)
     26411-       cost = (cost + SP->_char_padding - 1) / SP->_char_padding;
     26412+       cost = (cost + SP_PARM->_char_padding - 1) / SP_PARM->_char_padding;
     26413     return cost;
     26414 }
     26415 
     26416 static void
     26417-reset_scroll_region(void)
     26418+reset_scroll_region(NCURSES_SP_DCL0)
     26419 /* Set the scroll-region to a known state (the default) */
     26420 {
     26421     if (change_scroll_region) {
     26422-       TPUTS_TRACE("change_scroll_region");
     26423-       putp(TPARM_2(change_scroll_region, 0, screen_lines - 1));
     26424+       NCURSES_SP_NAME(_nc_putp) (NCURSES_SP_ARGx
     26425+                                  "change_scroll_region",
     26426+                                  TPARM_2(change_scroll_region,
     26427+                                          0, screen_lines(SP_PARM) - 1));
     26428     }
     26429 }
     26430 
     26431 NCURSES_EXPORT(void)
     26432-_nc_mvcur_resume(void)
     26433+NCURSES_SP_NAME(_nc_mvcur_resume) (NCURSES_SP_DCL0)
     26434 /* what to do at initialization time and after each shellout */
     26435 {
     26436     /* initialize screen for cursor access */
     26437     if (enter_ca_mode) {
     26438-       TPUTS_TRACE("enter_ca_mode");
     26439-       putp(enter_ca_mode);
     26440+       NCURSES_SP_NAME(_nc_putp) (NCURSES_SP_ARGx
     26441+                                  "enter_ca_mode",
     26442+                                  enter_ca_mode);
     26443     }
     26444 
     26445     /*
     26446@@ -280,53 +295,63 @@
     26447      * they know the screen size.  This is useful when you're running
     26448      * a vt100 emulation through xterm.
     26449      */
     26450-    reset_scroll_region();
     26451-    SP->_cursrow = SP->_curscol = -1;
     26452+    reset_scroll_region(NCURSES_SP_ARG);
     26453+    SP_PARM->_cursrow = SP_PARM->_curscol = -1;
     26454 
     26455     /* restore cursor shape */
     26456-    if (SP->_cursor != -1) {
     26457-       int cursor = SP->_cursor;
     26458-       SP->_cursor = -1;
     26459-       curs_set(cursor);
     26460+    if (SP_PARM->_cursor != -1) {
     26461+       int cursor = SP_PARM->_cursor;
     26462+       SP_PARM->_cursor = -1;
     26463+       NCURSES_SP_NAME(curs_set) (NCURSES_SP_ARGx cursor);
     26464     }
     26465 }
     26466 
     26467+#if NCURSES_SP_FUNCS
     26468 NCURSES_EXPORT(void)
     26469-_nc_mvcur_init(void)
     26470+_nc_mvcur_resume(void)
     26471+{
     26472+    NCURSES_SP_NAME(_nc_mvcur_resume) (CURRENT_SCREEN);
     26473+}
     26474+#endif
     26475+
     26476+NCURSES_EXPORT(void)
     26477+NCURSES_SP_NAME(_nc_mvcur_init) (NCURSES_SP_DCL0)
     26478 /* initialize the cost structure */
     26479 {
     26480-    if (isatty(fileno(SP->_ofp)))
     26481-       SP->_char_padding = ((BAUDBYTE * 1000 * 10)
     26482-                            / (BAUDRATE > 0 ? BAUDRATE : 9600));
     26483+    if (SP_PARM->_ofp && isatty(fileno(SP_PARM->_ofp)))
     26484+       SP_PARM->_char_padding = ((BAUDBYTE * 1000 * 10)
     26485+                                 / (BAUDRATE(SP_PARM) > 0
     26486+                                    ? BAUDRATE(SP_PARM)
     26487+                                    : 9600));
     26488     else
     26489-       SP->_char_padding = 1;  /* must be nonzero */
     26490-    if (SP->_char_padding <= 0)
     26491-       SP->_char_padding = 1;  /* must be nonzero */
     26492-    TR(TRACE_CHARPUT | TRACE_MOVE, ("char_padding %d msecs", SP->_char_padding));
     26493+       SP_PARM->_char_padding = 1;     /* must be nonzero */
     26494+    if (SP_PARM->_char_padding <= 0)
     26495+       SP_PARM->_char_padding = 1;     /* must be nonzero */
     26496+    TR(TRACE_CHARPUT | TRACE_MOVE, ("char_padding %d msecs", SP_PARM->_char_padding));
     26497 
     26498     /* non-parameterized local-motion strings */
     26499-    SP->_cr_cost = CostOf(carriage_return, 0);
     26500-    SP->_home_cost = CostOf(cursor_home, 0);
     26501-    SP->_ll_cost = CostOf(cursor_to_ll, 0);
     26502+    SP_PARM->_cr_cost = CostOf(carriage_return, 0);
     26503+    SP_PARM->_home_cost = CostOf(cursor_home, 0);
     26504+    SP_PARM->_ll_cost = CostOf(cursor_to_ll, 0);
     26505 #if USE_HARD_TABS
     26506     if (getenv("NCURSES_NO_HARD_TABS") == 0) {
     26507-       SP->_ht_cost = CostOf(tab, 0);
     26508-       SP->_cbt_cost = CostOf(back_tab, 0);
     26509+       SP_PARM->_ht_cost = CostOf(tab, 0);
     26510+       SP_PARM->_cbt_cost = CostOf(back_tab, 0);
     26511     } else {
     26512-       SP->_ht_cost = INFINITY;
     26513-       SP->_cbt_cost = INFINITY;
     26514+       SP_PARM->_ht_cost = INFINITY;
     26515+       SP_PARM->_cbt_cost = INFINITY;
     26516     }
     26517 #endif /* USE_HARD_TABS */
     26518-    SP->_cub1_cost = CostOf(cursor_left, 0);
     26519-    SP->_cuf1_cost = CostOf(cursor_right, 0);
     26520-    SP->_cud1_cost = CostOf(cursor_down, 0);
     26521-    SP->_cuu1_cost = CostOf(cursor_up, 0);
     26522-
     26523-    SP->_smir_cost = CostOf(enter_insert_mode, 0);
     26524-    SP->_rmir_cost = CostOf(exit_insert_mode, 0);
     26525-    SP->_ip_cost = 0;
     26526+    SP_PARM->_cub1_cost = CostOf(cursor_left, 0);
     26527+    SP_PARM->_cuf1_cost = CostOf(cursor_right, 0);
     26528+    SP_PARM->_cud1_cost = CostOf(cursor_down, 0);
     26529+    SP_PARM->_cuu1_cost = CostOf(cursor_up, 0);
     26530+
     26531+    SP_PARM->_smir_cost = CostOf(enter_insert_mode, 0);
     26532+    SP_PARM->_rmir_cost = CostOf(exit_insert_mode, 0);
     26533+    SP_PARM->_ip_cost = 0;
     26534     if (insert_padding) {
     26535-       SP->_ip_cost = CostOf(insert_padding, 0);
     26536+       SP_PARM->_ip_cost = CostOf(insert_padding, 0);
     26537     }
     26538 
     26539     /*
     26540@@ -335,7 +360,7 @@
     26541      * can treat it like absolute screen addressing.  This seems to be true
     26542      * for all cursor_mem_address terminal types in the terminfo database.
     26543      */
     26544-    SP->_address_cursor = cursor_address ? cursor_address : cursor_mem_address;
     26545+    SP_PARM->_address_cursor = cursor_address ? cursor_address : cursor_mem_address;
     26546 
     26547     /*
     26548      * Parametrized local-motion strings.  This static cost computation
     26549@@ -361,40 +386,43 @@
     26550      * All these averages depend on the assumption that all parameter values
     26551      * are equally probable.
     26552      */
     26553-    SP->_cup_cost = CostOf(TPARM_2(SP->_address_cursor, 23, 23), 1);
     26554-    SP->_cub_cost = CostOf(TPARM_1(parm_left_cursor, 23), 1);
     26555-    SP->_cuf_cost = CostOf(TPARM_1(parm_right_cursor, 23), 1);
     26556-    SP->_cud_cost = CostOf(TPARM_1(parm_down_cursor, 23), 1);
     26557-    SP->_cuu_cost = CostOf(TPARM_1(parm_up_cursor, 23), 1);
     26558-    SP->_hpa_cost = CostOf(TPARM_1(column_address, 23), 1);
     26559-    SP->_vpa_cost = CostOf(TPARM_1(row_address, 23), 1);
     26560+    SP_PARM->_cup_cost = CostOf(TPARM_2(SP_PARM->_address_cursor, 23, 23), 1);
     26561+    SP_PARM->_cub_cost = CostOf(TPARM_1(parm_left_cursor, 23), 1);
     26562+    SP_PARM->_cuf_cost = CostOf(TPARM_1(parm_right_cursor, 23), 1);
     26563+    SP_PARM->_cud_cost = CostOf(TPARM_1(parm_down_cursor, 23), 1);
     26564+    SP_PARM->_cuu_cost = CostOf(TPARM_1(parm_up_cursor, 23), 1);
     26565+    SP_PARM->_hpa_cost = CostOf(TPARM_1(column_address, 23), 1);
     26566+    SP_PARM->_vpa_cost = CostOf(TPARM_1(row_address, 23), 1);
     26567 
     26568     /* non-parameterized screen-update strings */
     26569-    SP->_ed_cost = NormalizedCost(clr_eos, 1);
     26570-    SP->_el_cost = NormalizedCost(clr_eol, 1);
     26571-    SP->_el1_cost = NormalizedCost(clr_bol, 1);
     26572-    SP->_dch1_cost = NormalizedCost(delete_character, 1);
     26573-    SP->_ich1_cost = NormalizedCost(insert_character, 1);
     26574+    SP_PARM->_ed_cost = NormalizedCost(clr_eos, 1);
     26575+    SP_PARM->_el_cost = NormalizedCost(clr_eol, 1);
     26576+    SP_PARM->_el1_cost = NormalizedCost(clr_bol, 1);
     26577+    SP_PARM->_dch1_cost = NormalizedCost(delete_character, 1);
     26578+    SP_PARM->_ich1_cost = NormalizedCost(insert_character, 1);
     26579 
     26580     /*
     26581      * If this is a bce-terminal, we want to bias the choice so we use clr_eol
     26582      * rather than spaces at the end of a line.
     26583      */
     26584     if (back_color_erase)
     26585-       SP->_el_cost = 0;
     26586+       SP_PARM->_el_cost = 0;
     26587 
     26588     /* parameterized screen-update strings */
     26589-    SP->_dch_cost = NormalizedCost(TPARM_1(parm_dch, 23), 1);
     26590-    SP->_ich_cost = NormalizedCost(TPARM_1(parm_ich, 23), 1);
     26591-    SP->_ech_cost = NormalizedCost(TPARM_1(erase_chars, 23), 1);
     26592-    SP->_rep_cost = NormalizedCost(TPARM_2(repeat_char, ' ', 23), 1);
     26593-
     26594-    SP->_cup_ch_cost = NormalizedCost(TPARM_2(SP->_address_cursor, 23, 23), 1);
     26595-    SP->_hpa_ch_cost = NormalizedCost(TPARM_1(column_address, 23), 1);
     26596-    SP->_cuf_ch_cost = NormalizedCost(TPARM_1(parm_right_cursor, 23), 1);
     26597-    SP->_inline_cost = min(SP->_cup_ch_cost,
     26598-                          min(SP->_hpa_ch_cost,
     26599-                              SP->_cuf_ch_cost));
     26600+    SP_PARM->_dch_cost = NormalizedCost(TPARM_1(parm_dch, 23), 1);
     26601+    SP_PARM->_ich_cost = NormalizedCost(TPARM_1(parm_ich, 23), 1);
     26602+    SP_PARM->_ech_cost = NormalizedCost(TPARM_1(erase_chars, 23), 1);
     26603+    SP_PARM->_rep_cost = NormalizedCost(TPARM_2(repeat_char, ' ', 23), 1);
     26604+
     26605+    SP_PARM->_cup_ch_cost = NormalizedCost(
     26606+                                             TPARM_2(SP_PARM->_address_cursor,
     26607+                                                     23, 23),
     26608+                                             1);
     26609+    SP_PARM->_hpa_ch_cost = NormalizedCost(TPARM_1(column_address, 23), 1);
     26610+    SP_PARM->_cuf_ch_cost = NormalizedCost(TPARM_1(parm_right_cursor, 23), 1);
     26611+    SP_PARM->_inline_cost = min(SP_PARM->_cup_ch_cost,
     26612+                               min(SP_PARM->_hpa_ch_cost,
     26613+                                   SP_PARM->_cuf_ch_cost));
     26614 
     26615     /*
     26616      * If save_cursor is used within enter_ca_mode, we should not use it for
     26617@@ -411,30 +439,40 @@
     26618     }
     26619 
     26620     /*
     26621-     * A different, possibly better way to arrange this would be to set
     26622-     * SP->_endwin = TRUE at window initialization time and let this be
     26623+     * A different, possibly better way to arrange this would be to set the
     26624+     * SCREEN's _endwin to TRUE at window initialization time and let this be
     26625      * called by doupdate's return-from-shellout code.
     26626      */
     26627+    NCURSES_SP_NAME(_nc_mvcur_resume) (NCURSES_SP_ARG);
     26628+}
     26629+
     26630+#if NCURSES_SP_FUNCS
     26631+NCURSES_EXPORT(void)
     26632+_nc_mvcur_init(void)
     26633+{
     26634+    NCURSES_SP_NAME(_nc_mvcur_init) (CURRENT_SCREEN);
     26635     _nc_mvcur_resume();
     26636 }
     26637+#endif
     26638 
     26639 NCURSES_EXPORT(void)
     26640-_nc_mvcur_wrap(void)
     26641+NCURSES_SP_NAME(_nc_mvcur_wrap) (NCURSES_SP_DCL0)
     26642 /* wrap up cursor-addressing mode */
     26643 {
     26644     /* leave cursor at screen bottom */
     26645-    mvcur(-1, -1, screen_lines - 1, 0);
     26646+    mvcur(-1, -1, screen_lines(CURRENT_SCREEN) - 1, 0);
     26647 
     26648     /* set cursor to normal mode */
     26649-    if (SP->_cursor != -1) {
     26650-       int cursor = SP->_cursor;
     26651-       curs_set(1);
     26652-       SP->_cursor = cursor;
     26653+    if (SP_PARM->_cursor != -1) {
     26654+       int cursor = SP_PARM->_cursor;
     26655+       NCURSES_SP_NAME(curs_set) (NCURSES_SP_ARGx 1);
     26656+       SP_PARM->_cursor = cursor;
     26657     }
     26658 
     26659     if (exit_ca_mode) {
     26660-       TPUTS_TRACE("exit_ca_mode");
     26661-       putp(exit_ca_mode);
     26662+       NCURSES_SP_NAME(_nc_putp) (NCURSES_SP_ARGx
     26663+                                  "exit_ca_mode",
     26664+                                  exit_ca_mode);
     26665     }
     26666     /*
     26667      * Reset terminal's tab counter.  There's a long-time bug that
     26668@@ -444,8 +482,16 @@
     26669      * escape sequences that reset things as column positions.
     26670      * Utter a \r to reset this invisibly.
     26671      */
     26672-    _nc_outch('\r');
     26673+    NCURSES_SP_NAME(_nc_outch) (NCURSES_SP_ARGx '\r');
     26674+}
     26675+
     26676+#if NCURSES_SP_FUNCS
     26677+NCURSES_EXPORT(void)
     26678+_nc_mvcur_wrap(void)
     26679+{
     26680+    NCURSES_SP_NAME(_nc_mvcur_wrap) (CURRENT_SCREEN);
     26681 }
     26682+#endif
     26683 
     26684 /****************************************************************************
     26685  *
     26686@@ -486,8 +532,13 @@
     26687 #define LASTTAB(fr)    ((fr > 0) ? ((fr - 1) / init_tabs) * init_tabs : -1)
     26688 
     26689 static int
     26690-relative_move(string_desc * target, int from_y, int from_x, int to_y, int
     26691-             to_x, bool ovw)
     26692+relative_move(NCURSES_SP_DCLx
     26693+             string_desc * target,
     26694+             int from_y,
     26695+             int from_x,
     26696+             int to_y,
     26697+             int to_x,
     26698+             bool ovw)
     26699 /* move via local motions (cuu/cuu1/cud/cud1/cub1/cub/cuf1/cuf/vpa/hpa) */
     26700 {
     26701     string_desc save;
     26702@@ -500,38 +551,38 @@
     26703 
     26704        if (row_address != 0
     26705            && _nc_safe_strcat(target, TPARM_1(row_address, to_y))) {
     26706-           vcost = SP->_vpa_cost;
     26707+           vcost = SP_PARM->_vpa_cost;
     26708        }
     26709 
     26710        if (to_y > from_y) {
     26711            n = (to_y - from_y);
     26712 
     26713            if (parm_down_cursor
     26714-               && SP->_cud_cost < vcost
     26715+               && SP_PARM->_cud_cost < vcost
     26716                && _nc_safe_strcat(_nc_str_copy(target, &save),
     26717                                   TPARM_1(parm_down_cursor, n))) {
     26718-               vcost = SP->_cud_cost;
     26719+               vcost = SP_PARM->_cud_cost;
     26720            }
     26721 
     26722            if (cursor_down
     26723-               && (*cursor_down != '\n' || SP->_nl)
     26724-               && (n * SP->_cud1_cost < vcost)) {
     26725+               && (*cursor_down != '\n' || SP_PARM->_nl)
     26726+               && (n * SP_PARM->_cud1_cost < vcost)) {
     26727                vcost = repeated_append(_nc_str_copy(target, &save), 0,
     26728-                                       SP->_cud1_cost, n, cursor_down);
     26729+                                       SP_PARM->_cud1_cost, n, cursor_down);
     26730            }
     26731        } else {                /* (to_y < from_y) */
     26732            n = (from_y - to_y);
     26733 
     26734            if (parm_up_cursor
     26735-               && SP->_cuu_cost < vcost
     26736+               && SP_PARM->_cuu_cost < vcost
     26737                && _nc_safe_strcat(_nc_str_copy(target, &save),
     26738                                   TPARM_1(parm_up_cursor, n))) {
     26739-               vcost = SP->_cuu_cost;
     26740+               vcost = SP_PARM->_cuu_cost;
     26741            }
     26742 
     26743-           if (cursor_up && (n * SP->_cuu1_cost < vcost)) {
     26744+           if (cursor_up && (n * SP_PARM->_cuu1_cost < vcost)) {
     26745                vcost = repeated_append(_nc_str_copy(target, &save), 0,
     26746-                                       SP->_cuu1_cost, n, cursor_up);
     26747+                                       SP_PARM->_cuu1_cost, n, cursor_up);
     26748            }
     26749        }
     26750 
     26751@@ -550,17 +601,17 @@
     26752        if (column_address
     26753            && _nc_safe_strcat(_nc_str_copy(target, &save),
     26754                               TPARM_1(column_address, to_x))) {
     26755-           hcost = SP->_hpa_cost;
     26756+           hcost = SP_PARM->_hpa_cost;
     26757        }
     26758 
     26759        if (to_x > from_x) {
     26760            n = to_x - from_x;
     26761 
     26762            if (parm_right_cursor
     26763-               && SP->_cuf_cost < hcost
     26764+               && SP_PARM->_cuf_cost < hcost
     26765                && _nc_safe_strcat(_nc_str_copy(target, &save),
     26766                                   TPARM_1(parm_right_cursor, n))) {
     26767-               hcost = SP->_cuf_cost;
     26768+               hcost = SP_PARM->_cuf_cost;
     26769            }
     26770 
     26771            if (cursor_right) {
     26772@@ -575,7 +626,7 @@
     26773 
     26774                    for (fr = from_x; (nxt = NEXTTAB(fr)) <= to_x; fr = nxt) {
     26775                        lhcost = repeated_append(&check, lhcost,
     26776-                                                SP->_ht_cost, 1, tab);
     26777+                                                SP_PARM->_ht_cost, 1, tab);
     26778                        if (lhcost == INFINITY)
     26779                            break;
     26780                    }
     26781@@ -599,7 +650,7 @@
     26782                    && n < (int) check.s_size
     26783                    && vcost == 0
     26784                    && str[0] == '\0') {
     26785-                   int wanted = CharOf(WANT_CHAR(to_y, from_x));
     26786+                   int wanted = CharOf(WANT_CHAR(SP_PARM, to_y, from_x));
     26787                    if (is8bits(wanted) && isdigit(wanted))
     26788                        ovw = FALSE;
     26789                }
     26790@@ -616,8 +667,8 @@
     26791                    int i;
     26792 
     26793                    for (i = 0; i < n; i++) {
     26794-                       NCURSES_CH_T ch = WANT_CHAR(to_y, from_x + i);
     26795-                       if (!SameAttrOf(ch, SCREEN_ATTRS(SP))
     26796+                       NCURSES_CH_T ch = WANT_CHAR(SP_PARM, to_y, from_x + i);
     26797+                       if (!SameAttrOf(ch, SCREEN_ATTRS(SP_PARM))
     26798 #if USE_WIDEC_SUPPORT
     26799                            || !Charable(ch)
     26800 #endif
     26801@@ -631,13 +682,13 @@
     26802                    int i;
     26803 
     26804                    for (i = 0; i < n; i++)
     26805-                       *check.s_tail++ = (char) CharOf(WANT_CHAR(to_y,
     26806+                       *check.s_tail++ = (char) CharOf(WANT_CHAR(SP_PARM, to_y,
     26807                                                                  from_x + i));
     26808                    *check.s_tail = '\0';
     26809                    check.s_size -= n;
     26810-                   lhcost += n * SP->_char_padding;
     26811+                   lhcost += n * SP_PARM->_char_padding;
     26812                } else {
     26813-                   lhcost = repeated_append(&check, lhcost, SP->_cuf1_cost,
     26814+                   lhcost = repeated_append(&check, lhcost, SP_PARM->_cuf1_cost,
     26815                                             n, cursor_right);
     26816                }
     26817 
     26818@@ -650,10 +701,10 @@
     26819            n = from_x - to_x;
     26820 
     26821            if (parm_left_cursor
     26822-               && SP->_cub_cost < hcost
     26823+               && SP_PARM->_cub_cost < hcost
     26824                && _nc_safe_strcat(_nc_str_copy(target, &save),
     26825                                   TPARM_1(parm_left_cursor, n))) {
     26826-               hcost = SP->_cub_cost;
     26827+               hcost = SP_PARM->_cub_cost;
     26828            }
     26829 
     26830            if (cursor_left) {
     26831@@ -667,7 +718,8 @@
     26832 
     26833                    for (fr = from_x; (nxt = LASTTAB(fr)) >= to_x; fr = nxt) {
     26834                        lhcost = repeated_append(&check, lhcost,
     26835-                                                SP->_cbt_cost, 1, back_tab);
     26836+                                                SP_PARM->_cbt_cost,
     26837+                                                1, back_tab);
     26838                        if (lhcost == INFINITY)
     26839                            break;
     26840                    }
     26841@@ -676,7 +728,9 @@
     26842                }
     26843 #endif /* USE_HARD_TABS */
     26844 
     26845-               lhcost = repeated_append(&check, lhcost, SP->_cub1_cost, n, cursor_left);
     26846+               lhcost = repeated_append(&check, lhcost,
     26847+                                        SP_PARM->_cub1_cost,
     26848+                                        n, cursor_left);
     26849 
     26850                if (lhcost < hcost
     26851                    && _nc_safe_strcat(_nc_str_copy(target, &save), str)) {
     26852@@ -705,7 +759,7 @@
     26853  */
     26854 
     26855 static NCURSES_INLINE int
     26856-onscreen_mvcur(int yold, int xold, int ynew, int xnew, bool ovw)
     26857+onscreen_mvcur(NCURSES_SP_DCLx int yold, int xold, int ynew, int xnew, bool ovw)
     26858 /* onscreen move from (yold, xold) to (ynew, xnew) */
     26859 {
     26860     string_desc result;
     26861@@ -723,9 +777,9 @@
     26862 #define InitResult _nc_str_init(&result, buffer, sizeof(buffer))
     26863 
     26864     /* tactic #0: use direct cursor addressing */
     26865-    if (_nc_safe_strcpy(InitResult, TPARM_2(SP->_address_cursor, ynew, xnew))) {
     26866+    if (_nc_safe_strcpy(InitResult, TPARM_2(SP_PARM->_address_cursor, ynew, xnew))) {
     26867        tactic = 0;
     26868-       usecost = SP->_cup_cost;
     26869+       usecost = SP_PARM->_cup_cost;
     26870 
     26871 #if defined(TRACE) || defined(NCURSES_TEST)
     26872        if (!(_nc_optimize_enable & OPTIMIZE_MVCUR))
     26873@@ -740,7 +794,7 @@
     26874         * (like, say, local-movement \n getting mapped to some obscure
     26875         * character because A_ALTCHARSET is on).
     26876         */
     26877-       if (yold == -1 || xold == -1 || NOT_LOCAL(yold, xold, ynew, xnew)) {
     26878+       if (yold == -1 || xold == -1 || NOT_LOCAL(SP_PARM, yold, xold, ynew, xnew)) {
     26879 #if defined(MAIN) || defined(NCURSES_TEST)
     26880            if (!profiling) {
     26881                (void) fputs("nonlocal\n", stderr);
     26882@@ -754,8 +808,10 @@
     26883 #ifndef NO_OPTIMIZE
     26884     /* tactic #1: use local movement */
     26885     if (yold != -1 && xold != -1
     26886-       && ((newcost = relative_move(NullResult, yold, xold, ynew, xnew,
     26887-                                    ovw)) != INFINITY)
     26888+       && ((newcost = relative_move(NCURSES_SP_ARGx
     26889+                                    NullResult,
     26890+                                    yold, xold,
     26891+                                    ynew, xnew, ovw)) != INFINITY)
     26892        && newcost < usecost) {
     26893        tactic = 1;
     26894        usecost = newcost;
     26895@@ -763,42 +819,51 @@
     26896 
     26897     /* tactic #2: use carriage-return + local movement */
     26898     if (yold != -1 && carriage_return
     26899-       && ((newcost = relative_move(NullResult, yold, 0, ynew, xnew, ovw))
     26900-           != INFINITY)
     26901-       && SP->_cr_cost + newcost < usecost) {
     26902+       && ((newcost = relative_move(NCURSES_SP_ARGx
     26903+                                    NullResult,
     26904+                                    yold, 0,
     26905+                                    ynew, xnew, ovw)) != INFINITY)
     26906+       && SP_PARM->_cr_cost + newcost < usecost) {
     26907        tactic = 2;
     26908-       usecost = SP->_cr_cost + newcost;
     26909+       usecost = SP_PARM->_cr_cost + newcost;
     26910     }
     26911 
     26912     /* tactic #3: use home-cursor + local movement */
     26913     if (cursor_home
     26914-       && ((newcost = relative_move(NullResult, 0, 0, ynew, xnew, ovw)) != INFINITY)
     26915-       && SP->_home_cost + newcost < usecost) {
     26916+       && ((newcost = relative_move(NCURSES_SP_ARGx
     26917+                                    NullResult,
     26918+                                    0, 0,
     26919+                                    ynew, xnew, ovw)) != INFINITY)
     26920+       && SP_PARM->_home_cost + newcost < usecost) {
     26921        tactic = 3;
     26922-       usecost = SP->_home_cost + newcost;
     26923+       usecost = SP_PARM->_home_cost + newcost;
     26924     }
     26925 
     26926     /* tactic #4: use home-down + local movement */
     26927     if (cursor_to_ll
     26928-       && ((newcost = relative_move(NullResult, screen_lines - 1, 0, ynew,
     26929-                                    xnew, ovw)) != INFINITY)
     26930-       && SP->_ll_cost + newcost < usecost) {
     26931+       && ((newcost = relative_move(NCURSES_SP_ARGx
     26932+                                    NullResult,
     26933+                                    screen_lines(SP_PARM) - 1, 0,
     26934+                                    ynew, xnew, ovw)) != INFINITY)
     26935+       && SP_PARM->_ll_cost + newcost < usecost) {
     26936        tactic = 4;
     26937-       usecost = SP->_ll_cost + newcost;
     26938+       usecost = SP_PARM->_ll_cost + newcost;
     26939     }
     26940 
     26941     /*
     26942      * tactic #5: use left margin for wrap to right-hand side,
     26943      * unless strange wrap behavior indicated by xenl might hose us.
     26944      */
     26945-    t5_cr_cost = (xold > 0 ? SP->_cr_cost : 0);
     26946+    t5_cr_cost = (xold > 0 ? SP_PARM->_cr_cost : 0);
     26947     if (auto_left_margin && !eat_newline_glitch
     26948        && yold > 0 && cursor_left
     26949-       && ((newcost = relative_move(NullResult, yold - 1, screen_columns -
     26950-                                    1, ynew, xnew, ovw)) != INFINITY)
     26951-       && t5_cr_cost + SP->_cub1_cost + newcost < usecost) {
     26952+       && ((newcost = relative_move(NCURSES_SP_ARGx
     26953+                                    NullResult,
     26954+                                    yold - 1, screen_columns(SP_PARM) - 1,
     26955+                                    ynew, xnew, ovw)) != INFINITY)
     26956+       && t5_cr_cost + SP_PARM->_cub1_cost + newcost < usecost) {
     26957        tactic = 5;
     26958-       usecost = t5_cr_cost + SP->_cub1_cost + newcost;
     26959+       usecost = t5_cr_cost + SP_PARM->_cub1_cost + newcost;
     26960     }
     26961 
     26962     /*
     26963@@ -808,26 +873,39 @@
     26964        InitResult;
     26965     switch (tactic) {
     26966     case 1:
     26967-       (void) relative_move(&result, yold, xold, ynew, xnew, ovw);
     26968+       (void) relative_move(NCURSES_SP_ARGx
     26969+                            &result,
     26970+                            yold, xold,
     26971+                            ynew, xnew, ovw);
     26972        break;
     26973     case 2:
     26974        (void) _nc_safe_strcpy(&result, carriage_return);
     26975-       (void) relative_move(&result, yold, 0, ynew, xnew, ovw);
     26976+       (void) relative_move(NCURSES_SP_ARGx
     26977+                            &result,
     26978+                            yold, 0,
     26979+                            ynew, xnew, ovw);
     26980        break;
     26981     case 3:
     26982        (void) _nc_safe_strcpy(&result, cursor_home);
     26983-       (void) relative_move(&result, 0, 0, ynew, xnew, ovw);
     26984+       (void) relative_move(NCURSES_SP_ARGx
     26985+                            &result, 0, 0,
     26986+                            ynew, xnew, ovw);
     26987        break;
     26988     case 4:
     26989        (void) _nc_safe_strcpy(&result, cursor_to_ll);
     26990-       (void) relative_move(&result, screen_lines - 1, 0, ynew, xnew, ovw);
     26991+       (void) relative_move(NCURSES_SP_ARGx
     26992+                            &result,
     26993+                            screen_lines(SP_PARM) - 1, 0,
     26994+                            ynew, xnew, ovw);
     26995        break;
     26996     case 5:
     26997        if (xold > 0)
     26998            (void) _nc_safe_strcat(&result, carriage_return);
     26999        (void) _nc_safe_strcat(&result, cursor_left);
     27000-       (void) relative_move(&result, yold - 1, screen_columns - 1, ynew,
     27001-                            xnew, ovw);
     27002+       (void) relative_move(NCURSES_SP_ARGx
     27003+                            &result,
     27004+                            yold - 1, screen_columns(SP_PARM) - 1,
     27005+                            ynew, xnew, ovw);
     27006        break;
     27007     }
     27008 #endif /* !NO_OPTIMIZE */
     27009@@ -845,17 +923,19 @@
     27010 
     27011     if (usecost != INFINITY) {
     27012        TPUTS_TRACE("mvcur");
     27013-       tputs(buffer, 1, _nc_outch);
     27014-       SP->_cursrow = ynew;
     27015-       SP->_curscol = xnew;
     27016+       NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     27017+                               buffer, 1, NCURSES_SP_NAME(_nc_outch));
     27018+       SP_PARM->_cursrow = ynew;
     27019+       SP_PARM->_curscol = xnew;
     27020        return (OK);
     27021     } else
    1992927022        return (ERR);
    1993027023 }
     
    1993927032     NCURSES_CH_T oldattr;
    1994027033     int code;
    19941 @@ -863,7 +865,7 @@
     27034@@ -863,7 +943,7 @@
    1994227035     TR(TRACE_CALLS | TRACE_MOVE, (T_CALLED("mvcur(%d,%d,%d,%d)"),
    1994327036                                  yold, xold, ynew, xnew));
     
    1994827041     } else if (yold == ynew && xold == xnew) {
    1994927042        code = OK;
    19950 @@ -884,7 +886,7 @@
     27043@@ -874,9 +954,9 @@
     27044         * column position implied by wraparound or the lack thereof and
     27045         * rolling up the screen to get ynew on the screen.
     27046         */
     27047-       if (xnew >= screen_columns) {
     27048-           ynew += xnew / screen_columns;
     27049-           xnew %= screen_columns;
     27050+       if (xnew >= screen_columns(SP_PARM)) {
     27051+           ynew += xnew / screen_columns(SP_PARM);
     27052+           xnew %= screen_columns(SP_PARM);
     27053        }
     27054 
     27055        /*
     27056@@ -884,38 +964,40 @@
    1995127057         * character set -- these have a strong tendency to screw up the CR &
    1995227058         * LF used for local character motions!
     
    1995727063            || (AttrOf(oldattr) && !move_standout_mode)) {
    1995827064            TR(TRACE_CHARPUT, ("turning off (%#lx) %s before move",
    19959 @@ -896,7 +898,7 @@
    19960         if (xold >= screen_columns) {
     27065                               (unsigned long) AttrOf(oldattr),
     27066                               _traceattr(AttrOf(oldattr))));
     27067-           (void) VIDATTR(A_NORMAL, 0);
     27068+           (void) VIDATTR(SP_PARM, A_NORMAL, 0);
     27069        }
     27070 
     27071-       if (xold >= screen_columns) {
     27072+       if (xold >= screen_columns(SP_PARM)) {
    1996127073            int l;
    1996227074 
    1996327075-           if (SP->_nl) {
     27076-               l = (xold + 1) / screen_columns;
    1996427077+           if (SP_PARM->_nl) {
    19965                 l = (xold + 1) / screen_columns;
     27078+               l = (xold + 1) / screen_columns(SP_PARM);
    1996627079                yold += l;
    19967                 if (yold >= screen_lines)
    19968 @@ -940,7 +942,7 @@
     27080-               if (yold >= screen_lines)
     27081-                   l -= (yold - screen_lines - 1);
     27082+               if (yold >= screen_lines(SP_PARM))
     27083+                   l -= (yold - screen_lines(SP_PARM) - 1);
     27084 
     27085                if (l > 0) {
     27086                    if (carriage_return) {
     27087-                       TPUTS_TRACE("carriage_return");
     27088-                       putp(carriage_return);
     27089+                       NCURSES_SP_NAME(_nc_putp) (NCURSES_SP_ARGx
     27090+                                                  "carriage_return",
     27091+                                                  carriage_return);
     27092                    } else
     27093-                       _nc_outch('\r');
     27094+                       NCURSES_SP_NAME(_nc_outch) (NCURSES_SP_ARGx '\r');
     27095                    xold = 0;
     27096 
     27097                    while (l > 0) {
     27098                        if (newline) {
     27099-                           TPUTS_TRACE("newline");
     27100-                           putp(newline);
     27101+                           NCURSES_SP_NAME(_nc_putp) (NCURSES_SP_ARGx
     27102+                                                      "newline",
     27103+                                                      newline);
     27104                        } else
     27105-                           _nc_outch('\n');
     27106+                           NCURSES_SP_NAME(_nc_outch) (NCURSES_SP_ARGx '\n');
     27107                        l--;
     27108                    }
     27109                }
     27110@@ -929,27 +1011,35 @@
     27111            }
     27112        }
     27113 
     27114-       if (yold > screen_lines - 1)
     27115-           yold = screen_lines - 1;
     27116-       if (ynew > screen_lines - 1)
     27117-           ynew = screen_lines - 1;
     27118+       if (yold > screen_lines(SP_PARM) - 1)
     27119+           yold = screen_lines(SP_PARM) - 1;
     27120+       if (ynew > screen_lines(SP_PARM) - 1)
     27121+           ynew = screen_lines(SP_PARM) - 1;
     27122 
     27123        /* destination location is on screen now */
     27124-       code = onscreen_mvcur(yold, xold, ynew, xnew, TRUE);
     27125+       code = onscreen_mvcur(NCURSES_SP_ARGx yold, xold, ynew, xnew, TRUE);
     27126 
    1996927127        /*
    1997027128         * Restore attributes if we disabled them before moving.
     
    1997527133                               (unsigned long) AttrOf(oldattr),
    1997627134                               _traceattr(AttrOf(oldattr))));
    19977 @@ -950,6 +952,14 @@
     27135-           (void) VIDATTR(AttrOf(oldattr), GetPair(oldattr));
     27136+           (void) VIDATTR(SP_PARM, AttrOf(oldattr), GetPair(oldattr));
     27137        }
     27138     }
    1997827139     returnCode(code);
    1997927140 }
     
    1999027151 NCURSES_EXPORT_VAR(int) _nc_optimize_enable = OPTIMIZE_ALL;
    1999127152 #endif
     27153@@ -1212,25 +1302,25 @@
     27154                           speeds[i], overhead, totalest);
     27155            }
     27156        } else if (buf[0] == 'c') {
     27157-           (void) printf("char padding: %d\n", SP->_char_padding);
     27158-           (void) printf("cr cost: %d\n", SP->_cr_cost);
     27159-           (void) printf("cup cost: %d\n", SP->_cup_cost);
     27160-           (void) printf("home cost: %d\n", SP->_home_cost);
     27161-           (void) printf("ll cost: %d\n", SP->_ll_cost);
     27162+           (void) printf("char padding: %d\n", CURRENT_SCREEN->_char_padding);
     27163+           (void) printf("cr cost: %d\n", CURRENT_SCREEN->_cr_cost);
     27164+           (void) printf("cup cost: %d\n", CURRENT_SCREEN->_cup_cost);
     27165+           (void) printf("home cost: %d\n", CURRENT_SCREEN->_home_cost);
     27166+           (void) printf("ll cost: %d\n", CURRENT_SCREEN->_ll_cost);
     27167 #if USE_HARD_TABS
     27168-           (void) printf("ht cost: %d\n", SP->_ht_cost);
     27169-           (void) printf("cbt cost: %d\n", SP->_cbt_cost);
     27170+           (void) printf("ht cost: %d\n", CURRENT_SCREEN->_ht_cost);
     27171+           (void) printf("cbt cost: %d\n", CURRENT_SCREEN->_cbt_cost);
     27172 #endif /* USE_HARD_TABS */
     27173-           (void) printf("cub1 cost: %d\n", SP->_cub1_cost);
     27174-           (void) printf("cuf1 cost: %d\n", SP->_cuf1_cost);
     27175-           (void) printf("cud1 cost: %d\n", SP->_cud1_cost);
     27176-           (void) printf("cuu1 cost: %d\n", SP->_cuu1_cost);
     27177-           (void) printf("cub cost: %d\n", SP->_cub_cost);
     27178-           (void) printf("cuf cost: %d\n", SP->_cuf_cost);
     27179-           (void) printf("cud cost: %d\n", SP->_cud_cost);
     27180-           (void) printf("cuu cost: %d\n", SP->_cuu_cost);
     27181-           (void) printf("hpa cost: %d\n", SP->_hpa_cost);
     27182-           (void) printf("vpa cost: %d\n", SP->_vpa_cost);
     27183+           (void) printf("cub1 cost: %d\n", CURRENT_SCREEN->_cub1_cost);
     27184+           (void) printf("cuf1 cost: %d\n", CURRENT_SCREEN->_cuf1_cost);
     27185+           (void) printf("cud1 cost: %d\n", CURRENT_SCREEN->_cud1_cost);
     27186+           (void) printf("cuu1 cost: %d\n", CURRENT_SCREEN->_cuu1_cost);
     27187+           (void) printf("cub cost: %d\n", CURRENT_SCREEN->_cub_cost);
     27188+           (void) printf("cuf cost: %d\n", CURRENT_SCREEN->_cuf_cost);
     27189+           (void) printf("cud cost: %d\n", CURRENT_SCREEN->_cud_cost);
     27190+           (void) printf("cuu cost: %d\n", CURRENT_SCREEN->_cuu_cost);
     27191+           (void) printf("hpa cost: %d\n", CURRENT_SCREEN->_hpa_cost);
     27192+           (void) printf("vpa cost: %d\n", CURRENT_SCREEN->_vpa_cost);
     27193        } else if (buf[0] == 'x' || buf[0] == 'q')
     27194            break;
     27195        else
     27196diff -Naur ncurses-5.7.orig/ncurses/tty/lib_tstp.c ncurses-5.7/ncurses/tty/lib_tstp.c
     27197--- ncurses-5.7.orig/ncurses/tty/lib_tstp.c     2008-05-03 09:24:56.000000000 -0700
     27198+++ ncurses-5.7/ncurses/tty/lib_tstp.c  2009-06-05 14:01:51.000000000 -0700
     27199@@ -1,5 +1,5 @@
     27200 /****************************************************************************
     27201- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     27202+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     27203  *                                                                          *
     27204  * Permission is hereby granted, free of charge, to any person obtaining a  *
     27205  * copy of this software and associated documentation files (the            *
     27206@@ -46,7 +46,7 @@
     27207 #define _POSIX_SOURCE
     27208 #endif
     27209 
     27210-MODULE_ID("$Id: lib_tstp.c,v 1.37 2008/05/03 16:24:56 tom Exp $")
     27211+MODULE_ID("$Id: lib_tstp.c,v 1.39 2009/05/09 15:46:20 tom Exp $")
     27212 
     27213 #if defined(SIGTSTP) && (HAVE_SIGACTION || HAVE_SIGVEC)
     27214 #define USE_SIGTSTP 1
     27215@@ -59,16 +59,20 @@
     27216 signal_name(int sig)
     27217 {
     27218     switch (sig) {
     27219+#ifdef SIGALRM
     27220     case SIGALRM:
     27221        return "SIGALRM";
     27222+#endif
     27223 #ifdef SIGCONT
     27224     case SIGCONT:
     27225        return "SIGCONT";
     27226 #endif
     27227     case SIGINT:
     27228        return "SIGINT";
     27229+#ifdef SIGQUIT
     27230     case SIGQUIT:
     27231        return "SIGQUIT";
     27232+#endif
     27233     case SIGTERM:
     27234        return "SIGTERM";
     27235 #ifdef SIGTSTP
     27236@@ -136,6 +140,7 @@
     27237 static void
     27238 tstp(int dummy GCC_UNUSED)
     27239 {
     27240+    SCREEN *sp = CURRENT_SCREEN;
     27241     sigset_t mask, omask;
     27242     sigaction_t act, oact;
     27243 
     27244@@ -154,11 +159,11 @@
     27245      * parent was stopped before us, and we would likely pick up the
     27246      * settings already modified by the shell.
     27247      */
     27248-    if (SP != 0 && !SP->_endwin)       /* don't do this if we're not in curses */
     27249+    if (sp != 0 && !sp->_endwin)       /* don't do this if we're not in curses */
     27250 #if HAVE_TCGETPGRP
     27251        if (tcgetpgrp(STDIN_FILENO) == getpgrp())
     27252 #endif
     27253-           def_prog_mode();
     27254+           NCURSES_SP_NAME(def_prog_mode) (NCURSES_SP_ARG);
     27255 
     27256     /*
     27257      * Block window change and timer signals.  The latter
     27258@@ -166,7 +171,9 @@
     27259      * to repaint the screen.
     27260      */
     27261     (void) sigemptyset(&mask);
     27262+#ifdef SIGALRM
     27263     (void) sigaddset(&mask, SIGALRM);
     27264+#endif
     27265 #if USE_SIGWINCH
     27266     (void) sigaddset(&mask, SIGWINCH);
     27267 #endif
     27268@@ -185,7 +192,7 @@
     27269      * End window mode, which also resets the terminal state to the
     27270      * original (pre-curses) modes.
     27271      */
     27272-    endwin();
     27273+    NCURSES_SP_NAME(endwin) (NCURSES_SP_ARG);
     27274 
     27275     /* Unblock SIGTSTP. */
     27276     (void) sigemptyset(&mask);
     27277@@ -212,19 +219,19 @@
     27278 
     27279     T(("SIGCONT received"));
     27280     sigaction(SIGTSTP, &oact, NULL);
     27281-    flushinp();
     27282+    NCURSES_SP_NAME(flushinp) (NCURSES_SP_ARG);
     27283 
     27284     /*
     27285      * If the user modified the tty state while suspended, he wants
     27286      * those changes to stick.  So save the new "default" terminal state.
     27287      */
     27288-    def_shell_mode();
     27289+    NCURSES_SP_NAME(def_shell_mode) (NCURSES_SP_ARG);
     27290 
     27291     /*
     27292      * This relies on the fact that doupdate() will restore the
     27293      * program-mode tty state, and issue enter_ca_mode if need be.
     27294      */
     27295-    doupdate();
     27296+    NCURSES_SP_NAME(doupdate) (NCURSES_SP_ARG);
     27297 
     27298     /* Reset the signals. */
     27299     (void) sigprocmask(SIG_SETMASK, &omask, NULL);
     27300@@ -234,6 +241,8 @@
     27301 static void
     27302 cleanup(int sig)
     27303 {
     27304+    SCREEN *sp = CURRENT_SCREEN;
     27305+
     27306     /*
     27307      * Actually, doing any sort of I/O from within an signal handler is
     27308      * "unsafe".  But we'll _try_ to clean up the screen and terminal
     27309@@ -241,7 +250,10 @@
     27310      */
     27311     if (!_nc_globals.cleanup_nested++
     27312        && (sig == SIGINT
     27313-           || sig == SIGQUIT)) {
     27314+#ifdef SIGQUIT
     27315+           || sig == SIGQUIT
     27316+#endif
     27317+       )) {
     27318 #if HAVE_SIGACTION || HAVE_SIGVEC
     27319        sigaction_t act;
     27320        sigemptyset(&act.sa_mask);
     27321@@ -257,12 +269,12 @@
     27322                if (scan->_ofp != 0
     27323                    && isatty(fileno(scan->_ofp))) {
     27324                    scan->_cleanup = TRUE;
     27325-                   scan->_outch = _nc_outch;
     27326+                   scan->_outch = NCURSES_SP_NAME(_nc_outch);
     27327                }
     27328                set_term(scan);
     27329-               endwin();
     27330-               if (SP)
     27331-                   SP->_endwin = FALSE;        /* in case we have an atexit! */
     27332+               NCURSES_SP_NAME(endwin) (NCURSES_SP_ARG);
     27333+               if (sp)
     27334+                   sp->_endwin = FALSE;        /* in case we have an atexit! */
     27335            }
     27336        }
     27337     }
     27338diff -Naur ncurses-5.7.orig/ncurses/tty/lib_twait.c ncurses-5.7/ncurses/tty/lib_twait.c
     27339--- ncurses-5.7.orig/ncurses/tty/lib_twait.c    2008-08-30 13:08:19.000000000 -0700
     27340+++ ncurses-5.7/ncurses/tty/lib_twait.c 2009-06-05 14:01:44.000000000 -0700
     27341@@ -1,5 +1,5 @@
     27342 /****************************************************************************
     27343- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     27344+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     27345  *                                                                          *
     27346  * Permission is hereby granted, free of charge, to any person obtaining a  *
     27347  * copy of this software and associated documentation files (the            *
     27348@@ -65,10 +65,12 @@
     27349 #  include <sys/select.h>
     27350 # endif
     27351 #endif
     27352-
     27353+#ifdef __MINGW32__
     27354+#  include <sys/time.h>
     27355+#endif
     27356 #undef CUR
     27357 
     27358-MODULE_ID("$Id: lib_twait.c,v 1.59 2008/08/30 20:08:19 tom Exp $")
     27359+MODULE_ID("$Id: lib_twait.c,v 1.60 2009/04/18 21:01:13 tom Exp $")
     27360 
     27361 static long
     27362 _nc_gettime(TimeType * t0, bool first)
     27363@@ -124,15 +126,27 @@
     27364 }
     27365 #endif /* NCURSES_WGETCH_EVENTS */
     27366 
     27367+#if (USE_FUNC_POLL || HAVE_SELECT)
     27368+#  define MAYBE_UNUSED
     27369+#else
     27370+#  define MAYBE_UNUSED GCC_UNUSED
     27371+#endif
     27372+
     27373+#if (USE_FUNC_POLL || HAVE_SELECT)
     27374+#  define MAYBE_UNUSED
     27375+#else
     27376+#  define MAYBE_UNUSED GCC_UNUSED
     27377+#endif
     27378+
     27379 /*
     27380  * Wait a specified number of milliseconds, returning nonzero if the timer
     27381  * didn't expire before there is activity on the specified file descriptors.
     27382  * The file-descriptors are specified by the mode:
     27383- *     0 - none (absolute time)
     27384- *     1 - ncurses' normal input-descriptor
     27385- *     2 - mouse descriptor, if any
     27386- *     3 - either input or mouse.
     27387- *
     27388+ *     TW_NONE    0 - none (absolute time)
     27389+ *     TW_INPUT   1 - ncurses' normal input-descriptor
     27390+ *     TW_MOUSE   2 - mouse descriptor, if any
     27391+ *     TW_ANY     3 - either input or mouse.
     27392+ *      TW_EVENT   4 -
     27393  * Experimental:  if NCURSES_WGETCH_EVENTS is defined, (mode & 4) determines
     27394  * whether to pay attention to evl argument.  If set, the smallest of
     27395  * millisecond and of timeout of evl is taken.
     27396@@ -143,16 +157,18 @@
     27397  * descriptors.
     27398  */
     27399 NCURSES_EXPORT(int)
     27400-_nc_timed_wait(SCREEN *sp,
     27401-              int mode,
     27402+_nc_timed_wait(SCREEN *sp MAYBE_UNUSED,
     27403+              int mode MAYBE_UNUSED,
     27404               int milliseconds,
     27405               int *timeleft
     27406               EVENTLIST_2nd(_nc_eventlist * evl))
     27407 {
     27408-    int fd;
     27409     int count;
     27410-    int result = 0;
     27411+    int result = TW_NONE;
     27412     TimeType t0;
     27413+#if (USE_FUNC_POLL || HAVE_SELECT)
     27414+    int fd;
     27415+#endif
     27416 
     27417 #ifdef NCURSES_WGETCH_EVENTS
     27418     int timeout_is_event = 0;
     27419@@ -174,7 +190,7 @@
     27420                      milliseconds, mode));
     27421 
     27422 #ifdef NCURSES_WGETCH_EVENTS
     27423-    if (mode & 4) {
     27424+    if (mode & TW_EVENT) {
     27425        int event_delay = _nc_eventlist_timeout(evl);
     27426 
     27427        if (event_delay >= 0
     27428@@ -193,7 +209,7 @@
     27429     count = 0;
     27430 
     27431 #ifdef NCURSES_WGETCH_EVENTS
     27432-    if ((mode & 4) && evl)
     27433+    if ((mode & TW_EVENT) && evl)
     27434        evl->result_flags = 0;
     27435 #endif
     27436 
     27437@@ -201,23 +217,23 @@
     27438     memset(fd_list, 0, sizeof(fd_list));
     27439 
     27440 #ifdef NCURSES_WGETCH_EVENTS
     27441-    if ((mode & 4) && evl)
     27442+    if ((mode & TW_EVENT) && evl)
     27443        fds = typeMalloc(struct pollfd, MIN_FDS + evl->count);
     27444 #endif
     27445 
     27446-    if (mode & 1) {
     27447+    if (mode & TW_INPUT) {
     27448        fds[count].fd = sp->_ifd;
     27449        fds[count].events = POLLIN;
     27450        count++;
     27451     }
     27452-    if ((mode & 2)
     27453+    if ((mode & TW_MOUSE)
     27454        && (fd = sp->_mouse_fd) >= 0) {
     27455        fds[count].fd = fd;
     27456        fds[count].events = POLLIN;
     27457        count++;
     27458     }
     27459 #ifdef NCURSES_WGETCH_EVENTS
     27460-    if ((mode & 4) && evl) {
     27461+    if ((mode & TW_EVENT) && evl) {
     27462        for (n = 0; n < evl->count; ++n) {
     27463            _nc_event *ev = evl->events[n];
     27464 
     27465@@ -234,7 +250,7 @@
     27466     result = poll(fds, (unsigned) count, milliseconds);
     27467 
     27468 #ifdef NCURSES_WGETCH_EVENTS
     27469-    if ((mode & 4) && evl) {
     27470+    if ((mode & TW_EVENT) && evl) {
     27471        int c;
     27472 
     27473        if (!result)
     27474@@ -276,8 +292,8 @@
     27475      *
     27476      * FIXME: this assumes mode&1 if milliseconds < 0 (see lib_getch.c).
     27477      */
     27478-    result = 0;
     27479-    if (mode & 1) {
     27480+    result = TW_NONE;
     27481+    if (mode & TW_INPUT) {
     27482        int step = (milliseconds < 0) ? 0 : 5000;
     27483        bigtime_t d;
     27484        bigtime_t useconds = milliseconds * 1000;
     27485@@ -313,17 +329,17 @@
     27486      */
     27487     FD_ZERO(&set);
     27488 
     27489-    if (mode & 1) {
     27490+    if (mode & TW_INPUT) {
     27491        FD_SET(sp->_ifd, &set);
     27492        count = sp->_ifd + 1;
     27493     }
     27494-    if ((mode & 2)
     27495+    if ((mode & TW_MOUSE)
     27496        && (fd = sp->_mouse_fd) >= 0) {
     27497        FD_SET(fd, &set);
     27498        count = max(fd, count) + 1;
     27499     }
     27500 #ifdef NCURSES_WGETCH_EVENTS
     27501-    if ((mode & 4) && evl) {
     27502+    if ((mode & TW_EVENT) && evl) {
     27503        for (n = 0; n < evl->count; ++n) {
     27504            _nc_event *ev = evl->events[n];
     27505 
     27506@@ -346,7 +362,7 @@
     27507     }
     27508 
     27509 #ifdef NCURSES_WGETCH_EVENTS
     27510-    if ((mode & 4) && evl) {
     27511+    if ((mode & TW_EVENT) && evl) {
     27512        evl->result_flags = 0;
     27513        for (n = 0; n < evl->count; ++n) {
     27514            _nc_event *ev = evl->events[n];
     27515@@ -428,22 +444,22 @@
     27516                }
     27517            }
     27518 #elif defined(__BEOS__)
     27519-           result = 1;         /* redundant, but simple */
     27520+           result = TW_INPUT;  /* redundant, but simple */
     27521 #elif HAVE_SELECT
     27522-           if ((mode & 2)
     27523+           if ((mode & TW_MOUSE)
     27524                && (fd = sp->_mouse_fd) >= 0
     27525                && FD_ISSET(fd, &set))
     27526-               result |= 2;
     27527-           if ((mode & 1)
     27528+               result |= TW_MOUSE;
     27529+           if ((mode & TW_INPUT)
     27530                && FD_ISSET(sp->_ifd, &set))
     27531-               result |= 1;
     27532+               result |= TW_INPUT;
     27533 #endif
     27534        } else
     27535            result = 0;
     27536     }
     27537 #ifdef NCURSES_WGETCH_EVENTS
     27538-    if ((mode & 4) && evl && evl->result_flags)
     27539-       result |= 4;
     27540+    if ((mode & TW_EVENT) && evl && evl->result_flags)
     27541+       result |= TW_EVENT;
     27542 #endif
     27543 
     27544     return (result);
    1999227545diff -Naur ncurses-5.7.orig/ncurses/tty/lib_vidattr.c ncurses-5.7/ncurses/tty/lib_vidattr.c
    1999327546--- ncurses-5.7.orig/ncurses/tty/lib_vidattr.c  2007-06-30 14:58:04.000000000 -0700
    19994 +++ ncurses-5.7/ncurses/tty/lib_vidattr.c       2009-02-28 20:38:58.443328118 -0800
     27547+++ ncurses-5.7/ncurses/tty/lib_vidattr.c       2009-06-05 14:01:51.000000000 -0700
    1999527548@@ -1,5 +1,5 @@
    1999627549 /****************************************************************************
     
    2001027563 
    2001127564 /*
    20012 @@ -65,7 +66,7 @@
     27565@@ -65,9 +66,15 @@
    2001327566 #include <curses.priv.h>
    2001427567 #include <term.h>
    2001527568 
    2001627569-MODULE_ID("$Id: lib_vidattr.c,v 1.49 2007/06/30 21:58:04 tom Exp $")
    20017 +MODULE_ID("$Id: lib_vidattr.c,v 1.51 2009/02/21 21:43:40 tom Exp $")
    20018  
    20019  #define doPut(mode) TPUTS_TRACE(#mode); tputs(mode, 1, outc)
    20020  
    20021 @@ -299,7 +300,7 @@
     27570+#ifndef CUR
     27571+#define CUR SP_TERMTYPE
     27572+#endif
     27573+
     27574+MODULE_ID("$Id: lib_vidattr.c,v 1.56 2009/05/10 00:48:29 tom Exp $")
     27575 
     27576-#define doPut(mode) TPUTS_TRACE(#mode); tputs(mode, 1, outc)
     27577+#define doPut(mode) \
     27578+       TPUTS_TRACE(#mode); \
     27579+       NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx mode, 1, outc)
     27580 
     27581 #define TurnOn(mask,mode) \
     27582        if ((turn_on & mask) && mode) { doPut(mode); }
     27583@@ -83,21 +90,24 @@
     27584                if ((pair != old_pair) \
     27585                 || (fix_pair0 && (pair == 0)) \
     27586                 || (reverse ^ ((old_attr & A_REVERSE) != 0))) { \
     27587-                       _nc_do_color(old_pair, pair, reverse, outc); \
     27588+                    NCURSES_SP_NAME(_nc_do_color) (NCURSES_SP_ARGx \
     27589+                                    old_pair, pair, reverse, outc); \
     27590                } \
     27591        }
     27592 
     27593 #define PreviousAttr _nc_prescreen.previous_attr
     27594 
     27595 NCURSES_EXPORT(int)
     27596-vidputs(chtype newmode, int (*outc) (int))
     27597+NCURSES_SP_NAME(vidputs) (NCURSES_SP_DCLx
     27598+                         chtype newmode,
     27599+                         NCURSES_SP_OUTC outc)
     27600 {
     27601     attr_t turn_on, turn_off;
     27602     int pair;
     27603     bool reverse = FALSE;
     27604-    bool can_color = (SP == 0 || SP->_coloron);
     27605+    bool can_color = (SP_PARM == 0 || SP_PARM->_coloron);
     27606 #if NCURSES_EXT_FUNCS
     27607-    bool fix_pair0 = (SP != 0 && SP->_coloron && !SP->_default_color);
     27608+    bool fix_pair0 = (SP_PARM != 0 && SP_PARM->_coloron && !SP_PARM->_default_color);
     27609 #else
     27610 #define fix_pair0 FALSE
     27611 #endif
     27612@@ -106,12 +116,12 @@
     27613     T((T_CALLED("vidputs(%s)"), _traceattr(newmode)));
     27614 
     27615     /* this allows us to go on whether or not newterm() has been called */
     27616-    if (SP)
     27617-       PreviousAttr = AttrOf(SCREEN_ATTRS(SP));
     27618+    if (SP_PARM)
     27619+       PreviousAttr = AttrOf(SCREEN_ATTRS(SP_PARM));
     27620 
     27621     TR(TRACE_ATTRS, ("previous attribute was %s", _traceattr(PreviousAttr)));
     27622 
     27623-    if ((SP != 0)
     27624+    if ((SP_PARM != 0)
     27625        && (magic_cookie_glitch > 0)) {
     27626 #if USE_XMC_SUPPORT
     27627        static const chtype table[] =
     27628@@ -135,7 +145,7 @@
     27629         * the terminfo max_attributes value.
     27630         */
     27631        for (n = 0; n < SIZEOF(table); ++n) {
     27632-           if ((table[n] & SP->_ok_attributes) == 0) {
     27633+           if ((table[n] & SP_PARM->_ok_attributes) == 0) {
     27634                newmode &= ~table[n];
     27635            } else if ((table[n] & newmode) != 0) {
     27636                if (used++ >= limit) {
     27637@@ -148,7 +158,7 @@
     27638            }
     27639        }
     27640 #else
     27641-       newmode &= ~(SP->_xmc_suppress);
     27642+       newmode &= ~(SP_PARM->_xmc_suppress);
     27643 #endif
     27644        TR(TRACE_ATTRS, ("suppressed attribute is %s", _traceattr(newmode)));
     27645     }
     27646@@ -208,10 +218,10 @@
     27647            if (exit_attribute_mode) {
     27648                doPut(exit_attribute_mode);
     27649            } else {
     27650-               if (!SP || SP->_use_rmul) {
     27651+               if (!SP_PARM || SP_PARM->_use_rmul) {
     27652                    TurnOff(A_UNDERLINE, exit_underline_mode);
     27653                }
     27654-               if (!SP || SP->_use_rmso) {
     27655+               if (!SP_PARM || SP_PARM->_use_rmso) {
     27656                    TurnOff(A_STANDOUT, exit_standout_mode);
     27657                }
     27658            }
     27659@@ -222,16 +232,18 @@
     27660     } else if (set_attributes) {
     27661        if (turn_on || turn_off) {
     27662            TPUTS_TRACE("set_attributes");
     27663-           tputs(tparm(set_attributes,
     27664-                       (newmode & A_STANDOUT) != 0,
     27665-                       (newmode & A_UNDERLINE) != 0,
     27666-                       (newmode & A_REVERSE) != 0,
     27667-                       (newmode & A_BLINK) != 0,
     27668-                       (newmode & A_DIM) != 0,
     27669-                       (newmode & A_BOLD) != 0,
     27670-                       (newmode & A_INVIS) != 0,
     27671-                       (newmode & A_PROTECT) != 0,
     27672-                       (newmode & A_ALTCHARSET) != 0), 1, outc);
     27673+           NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     27674+                                   tparm(set_attributes,
     27675+                                         (newmode & A_STANDOUT) != 0,
     27676+                                         (newmode & A_UNDERLINE) != 0,
     27677+                                         (newmode & A_REVERSE) != 0,
     27678+                                         (newmode & A_BLINK) != 0,
     27679+                                         (newmode & A_DIM) != 0,
     27680+                                         (newmode & A_BOLD) != 0,
     27681+                                         (newmode & A_INVIS) != 0,
     27682+                                         (newmode & A_PROTECT) != 0,
     27683+                                         (newmode & A_ALTCHARSET) != 0),
     27684+                                   1, outc);
     27685            PreviousAttr &= ALL_BUT_COLOR;
     27686        }
     27687        SetColorsIf((pair != 0) || fix_pair0, PreviousAttr);
     27688@@ -241,11 +253,11 @@
     27689 
     27690        TurnOff(A_ALTCHARSET, exit_alt_charset_mode);
     27691 
     27692-       if (!SP || SP->_use_rmul) {
     27693+       if (!SP_PARM || SP_PARM->_use_rmul) {
     27694            TurnOff(A_UNDERLINE, exit_underline_mode);
     27695        }
     27696 
     27697-       if (!SP || SP->_use_rmso) {
     27698+       if (!SP_PARM || SP_PARM->_use_rmso) {
     27699            TurnOff(A_STANDOUT, exit_standout_mode);
     27700        }
     27701 
     27702@@ -282,8 +294,8 @@
     27703     if (reverse)
     27704        newmode |= A_REVERSE;
     27705 
     27706-    if (SP)
     27707-       SetAttr(SCREEN_ATTRS(SP), newmode);
     27708+    if (SP_PARM)
     27709+       SetAttr(SCREEN_ATTRS(SP_PARM), newmode);
     27710     else
     27711        PreviousAttr = newmode;
     27712 
     27713@@ -291,15 +303,33 @@
    2002227714 }
     27715 
     27716 NCURSES_EXPORT(int)
     27717+NCURSES_SP_NAME(vidattr) (NCURSES_SP_DCLx
     27718+                         chtype newmode)
     27719+{
     27720+    return NCURSES_SP_NAME(vidputs) (NCURSES_SP_ARGx
     27721+                                    newmode,
     27722+                                    NCURSES_SP_NAME(_nc_outch));
     27723+}
     27724+
     27725+#if NCURSES_SP_FUNCS
     27726+NCURSES_EXPORT(int)
     27727+vidputs(chtype newmode, NCURSES_OUTC outc)
     27728+{
     27729+    SetSafeOutcWrapper(outc);
     27730+    return NCURSES_SP_NAME(vidputs) (CURRENT_SCREEN, newmode, _nc_outc_wrapper);
     27731+}
     27732+
     27733+NCURSES_EXPORT(int)
     27734 vidattr(chtype newmode)
     27735 {
     27736     T((T_CALLED("vidattr(%s)"), _traceattr(newmode)));
     27737 
     27738     returnCode(vidputs(newmode, _nc_outch));
     27739 }
     27740+#endif
    2002327741 
    2002427742 NCURSES_EXPORT(chtype)
     
    2002827746     chtype attrs = A_NORMAL;
    2002927747 
    20030 @@ -331,8 +332,16 @@
     27748@@ -331,8 +361,16 @@
    2003127749     if (enter_underline_mode)
    2003227750        attrs |= A_UNDERLINE;
     
    2004927767diff -Naur ncurses-5.7.orig/ncurses/tty/tty_update.c ncurses-5.7/ncurses/tty/tty_update.c
    2005027768--- ncurses-5.7.orig/ncurses/tty/tty_update.c   2008-08-30 13:08:19.000000000 -0700
    20051 +++ ncurses-5.7/ncurses/tty/tty_update.c        2009-02-28 20:38:57.059236485 -0800
     27769+++ ncurses-5.7/ncurses/tty/tty_update.c        2009-06-05 14:01:52.000000000 -0700
    2005227770@@ -1,5 +1,5 @@
    2005327771 /****************************************************************************
     
    2006527783 
    2006627784 /*-----------------------------------------------------------------
    20067 @@ -78,7 +79,7 @@
     27785@@ -38,12 +39,16 @@
     27786  *
     27787  *     The routine doupdate() and its dependents.
     27788  *     All physical output is concentrated here (except _nc_outch()
     27789-  *    in lib_tputs.c).
     27790+ *     in lib_tputs.c).
     27791  *
     27792  *-----------------------------------------------------------------*/
     27793 
     27794 #include <curses.priv.h>
     27795 
     27796+#ifndef CUR
     27797+#define CUR SP_TERMTYPE
     27798+#endif
     27799+
     27800 #if defined __HAIKU__ && defined __BEOS__
     27801 #undef __BEOS__
     27802 #endif
     27803@@ -76,9 +81,8 @@
     27804 #endif
     27805 
    2006827806 #include <ctype.h>
    20069  #include <term.h>
     27807-#include <term.h>
    2007027808 
    2007127809-MODULE_ID("$Id: tty_update.c,v 1.246 2008/08/30 20:08:19 tom Exp $")
    20072 +MODULE_ID("$Id: tty_update.c,v 1.248 2009/02/15 00:51:22 tom Exp $")
     27810+MODULE_ID("$Id: tty_update.c,v 1.256 2009/05/17 00:13:49 tom Exp $")
    2007327811 
    2007427812 /*
    2007527813  * This define controls the line-breakout optimization.  Every once in a
    20076 @@ -618,7 +619,7 @@
     27814@@ -91,7 +95,7 @@
     27815  */
     27816 #define CHECK_INTERVAL 5
     27817 
     27818-#define FILL_BCE() (SP->_coloron && !SP->_default_color && !back_color_erase)
     27819+#define FILL_BCE(sp) (sp->_coloron && !sp->_default_color && !back_color_erase)
     27820 
     27821 static const NCURSES_CH_T blankchar = NewChar(BLANK_TEXT);
     27822 static NCURSES_CH_T normal = NewChar(BLANK_TEXT);
     27823@@ -103,13 +107,23 @@
     27824  */
     27825 /* #define POSITION_DEBUG */
     27826 
     27827-static NCURSES_INLINE NCURSES_CH_T ClrBlank(WINDOW *win);
     27828+static NCURSES_INLINE NCURSES_CH_T ClrBlank(NCURSES_SP_DCLx WINDOW *win);
     27829+
     27830+#if NCURSES_SP_FUNCS
     27831+static int ClrBottom(SCREEN *, int total);
     27832+static void ClearScreen(SCREEN *, NCURSES_CH_T blank);
     27833+static void ClrUpdate(SCREEN *);
     27834+static void DelChar(SCREEN *, int count);
     27835+static void InsStr(SCREEN *, NCURSES_CH_T * line, int count);
     27836+static void TransformLine(SCREEN *, int const lineno);
     27837+#else
     27838 static int ClrBottom(int total);
     27839 static void ClearScreen(NCURSES_CH_T blank);
     27840 static void ClrUpdate(void);
     27841 static void DelChar(int count);
     27842 static void InsStr(NCURSES_CH_T * line, int count);
     27843 static void TransformLine(int const lineno);
     27844+#endif
     27845 
     27846 #ifdef POSITION_DEBUG
     27847 /****************************************************************************
     27848@@ -119,7 +133,7 @@
     27849  ****************************************************************************/
     27850 
     27851 static void
     27852-position_check(int expected_y, int expected_x, char *legend)
     27853+position_check(NCURSES_SP_DCLx int expected_y, int expected_x, char *legend)
     27854 /* check to see if the real cursor position matches the virtual */
     27855 {
     27856     char buf[20];
     27857@@ -129,10 +143,10 @@
     27858     if (!_nc_tracing || (expected_y < 0 && expected_x < 0))
     27859        return;
     27860 
     27861-    _nc_flush();
     27862+    NCURSES_SP_NAME(_nc_flush) (NCURSES_SP_ARG);
     27863     memset(buf, '\0', sizeof(buf));
     27864-    putp("\033[6n");           /* only works on ANSI-compatibles */
     27865-    _nc_flush();
     27866+    NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx "\033[6n"); /* only works on ANSI-compatibles */
     27867+    NCURSES_SP_NAME(_nc_flush) (NCURSES_SP_ARG);
     27868     *(s = buf) = 0;
     27869     do {
     27870        int ask = sizeof(buf) - 1 - (s - buf);
     27871@@ -152,8 +166,12 @@
     27872        if (expected_y < 0)
     27873            expected_y = y - 1;
     27874        if (y - 1 != expected_y || x - 1 != expected_x) {
     27875-           beep();
     27876-           tputs(tparm("\033[%d;%dH", expected_y + 1, expected_x + 1), 1, _nc_outch);
     27877+           NCURSES_SP_NAME(beep) (NCURSES_SP_ARG);
     27878+           NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     27879+                                   tparm("\033[%d;%dH",
     27880+                                         expected_y + 1,
     27881+                                         expected_x + 1),
     27882+                                   1, NCURSES_SP_NAME(_nc_outch));
     27883            _tracef("position seen (%d, %d) doesn't match expected one (%d, %d) in %s",
     27884                    y - 1, x - 1, expected_y, expected_x, legend);
     27885        } else {
     27886@@ -162,7 +180,7 @@
     27887     }
     27888 }
     27889 #else
     27890-#define position_check(expected_y, expected_x, legend) /* nothing */
     27891+#define position_check(sp, expected_y, expected_x, legend)     /* nothing */
     27892 #endif /* POSITION_DEBUG */
     27893 
     27894 /****************************************************************************
     27895@@ -172,19 +190,19 @@
     27896  ****************************************************************************/
     27897 
     27898 static NCURSES_INLINE void
     27899-GoTo(int const row, int const col)
     27900+GoTo(NCURSES_SP_DCLx int const row, int const col)
     27901 {
     27902     TR(TRACE_MOVE, ("GoTo(%d, %d) from (%d, %d)",
     27903-                   row, col, SP->_cursrow, SP->_curscol));
     27904+                   row, col, SP_PARM->_cursrow, SP_PARM->_curscol));
     27905 
     27906-    position_check(SP->_cursrow, SP->_curscol, "GoTo");
     27907+    position_check(SP_PARM, SP_PARM->_cursrow, SP_PARM->_curscol, "GoTo");
     27908 
     27909-    mvcur(SP->_cursrow, SP->_curscol, row, col);
     27910-    position_check(SP->_cursrow, SP->_curscol, "GoTo2");
     27911+    mvcur(SP_PARM->_cursrow, SP_PARM->_curscol, row, col);
     27912+    position_check(SP_PARM, SP_PARM->_cursrow, SP_PARM->_curscol, "GoTo2");
     27913 }
     27914 
     27915 static NCURSES_INLINE void
     27916-PutAttrChar(CARG_CH_T ch)
     27917+PutAttrChar(NCURSES_SP_DCLx CARG_CH_T ch)
     27918 {
     27919     int chlen = 1;
     27920     NCURSES_CH_T my_ch;
     27921@@ -194,7 +212,7 @@
     27922 
     27923     TR(TRACE_CHARPUT, ("PutAttrChar(%s) at (%d, %d)",
     27924                       _tracech_t(ch),
     27925-                      SP->_cursrow, SP->_curscol));
     27926+                      SP_PARM->_cursrow, SP_PARM->_curscol));
     27927 #if USE_WIDEC_SUPPORT
     27928     /*
     27929      * If this is not a valid character, there is nothing more to do.
     27930@@ -224,12 +242,12 @@
     27931         */
     27932        if (is8bits(CharOf(CHDEREF(ch)))
     27933            && (isprint(CharOf(CHDEREF(ch)))
     27934-               || (SP->_legacy_coding > 0 && CharOf(CHDEREF(ch)) >= 160)
     27935-               || (SP->_legacy_coding > 1 && CharOf(CHDEREF(ch)) >= 128)
     27936+               || (SP_PARM->_legacy_coding > 0 && CharOf(CHDEREF(ch)) >= 160)
     27937+               || (SP_PARM->_legacy_coding > 1 && CharOf(CHDEREF(ch)) >= 128)
     27938                || (AttrOf(attr) & A_ALTCHARSET
     27939                    && ((CharOfD(ch) < ACS_LEN
     27940-                        && SP->_acs_map != 0
     27941-                        && SP->_acs_map[CharOfD(ch)] != 0)
     27942+                        && SP_PARM->_acs_map != 0
     27943+                        && SP_PARM->_acs_map[CharOfD(ch)] != 0)
     27944                        || (CharOfD(ch) >= 128))))) {
     27945            ;
     27946        } else {
     27947@@ -241,7 +259,7 @@
     27948 #endif
     27949 
     27950     if ((AttrOf(attr) & A_ALTCHARSET)
     27951-       && SP->_acs_map != 0
     27952+       && SP_PARM->_acs_map != 0
     27953        && CharOfD(ch) < ACS_LEN) {
     27954        my_ch = CHDEREF(ch);    /* work around const param */
     27955 #if USE_WIDEC_SUPPORT
     27956@@ -251,8 +269,8 @@
     27957         * character, and uses the wide-character mapping when we expect the
     27958         * normal one to be broken (by mis-design ;-).
     27959         */
     27960-       if (SP->_screen_acs_fix
     27961-           && SP->_screen_acs_map[CharOf(my_ch)]) {
     27962+       if (SP_PARM->_screen_acs_fix
     27963+           && SP_PARM->_screen_acs_map[CharOf(my_ch)]) {
     27964            RemAttr(attr, A_ALTCHARSET);
     27965            my_ch = _nc_wacs[CharOf(my_ch)];
     27966        }
     27967@@ -265,9 +283,9 @@
     27968         */
     27969        if (AttrOf(attr) & A_ALTCHARSET) {
     27970            int j = CharOfD(ch);
     27971-           chtype temp = UChar(SP->_acs_map[j]);
     27972+           chtype temp = UChar(SP_PARM->_acs_map[j]);
     27973 
     27974-           if (!(SP->_screen_acs_map[j])) {
     27975+           if (!(SP_PARM->_screen_acs_map[j])) {
     27976                RemAttr(attr, A_ALTCHARSET);
     27977                if (temp == 0)
     27978                    temp = ' ';
     27979@@ -282,28 +300,28 @@
     27980        ch = CHREF(tilde);
     27981     }
     27982 
     27983-    UpdateAttrs(attr);
     27984+    UpdateAttrs(SP_PARM, attr);
     27985 #if !USE_WIDEC_SUPPORT
     27986     /* FIXME - we do this special case for signal handling, should see how to
     27987      * make it work for wide characters.
     27988      */
     27989-    if (SP->_outch != 0) {
     27990-       SP->_outch(UChar(ch));
     27991+    if (SP_PARM->_outch != 0) {
     27992+       SP_PARM->_outch(NCURSES_SP_ARGx UChar(ch));
     27993     } else
     27994 #endif
     27995     {
     27996-       PUTC(CHDEREF(ch), SP->_ofp);    /* macro's fastest... */
     27997+       PUTC(CHDEREF(ch), SP_PARM->_ofp);       /* macro's fastest... */
     27998        COUNT_OUTCHARS(1);
     27999     }
     28000-    SP->_curscol += chlen;
     28001+    SP_PARM->_curscol += chlen;
     28002     if (char_padding) {
     28003        TPUTS_TRACE("char_padding");
     28004-       putp(char_padding);
     28005+       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx char_padding);
     28006     }
     28007 }
     28008 
     28009 static bool
     28010-check_pending(void)
     28011+check_pending(NCURSES_SP_DCL0)
     28012 /* check for pending input */
     28013 {
     28014     bool have_pending = FALSE;
     28015@@ -313,13 +331,13 @@
     28016      * have the refreshing slow down drastically (or stop) if there's an
     28017      * unread character available.
     28018      */
     28019-    if (SP->_fifohold != 0)
     28020+    if (SP_PARM->_fifohold != 0)
     28021        return FALSE;
     28022 
     28023-    if (SP->_checkfd >= 0) {
     28024+    if (SP_PARM->_checkfd >= 0) {
     28025 #if USE_FUNC_POLL
     28026        struct pollfd fds[1];
     28027-       fds[0].fd = SP->_checkfd;
     28028+       fds[0].fd = SP_PARM->_checkfd;
     28029        fds[0].events = POLLIN;
     28030        if (poll(fds, 1, 0) > 0) {
     28031            have_pending = TRUE;
     28032@@ -347,43 +365,52 @@
     28033            ktimeout.tv_usec = 0;
     28034 
     28035        FD_ZERO(&fdset);
     28036-       FD_SET(SP->_checkfd, &fdset);
     28037-       if (select(SP->_checkfd + 1, &fdset, NULL, NULL, &ktimeout) != 0) {
     28038+       FD_SET(SP_PARM->_checkfd, &fdset);
     28039+       if (select(SP_PARM->_checkfd + 1, &fdset, NULL, NULL, &ktimeout) != 0) {
     28040            have_pending = TRUE;
     28041        }
     28042 #endif
     28043     }
     28044     if (have_pending) {
     28045-       SP->_fifohold = 5;
     28046-       _nc_flush();
     28047+       SP_PARM->_fifohold = 5;
     28048+       NCURSES_SP_NAME(_nc_flush) (NCURSES_SP_ARG);
     28049     }
     28050     return FALSE;
     28051 }
     28052 
     28053 /* put char at lower right corner */
     28054 static void
     28055-PutCharLR(const ARG_CH_T ch)
     28056+PutCharLR(NCURSES_SP_DCLx const ARG_CH_T ch)
     28057 {
     28058     if (!auto_right_margin) {
     28059        /* we can put the char directly */
     28060-       PutAttrChar(ch);
     28061+       PutAttrChar(NCURSES_SP_ARGx ch);
     28062     } else if (enter_am_mode && exit_am_mode) {
     28063        /* we can suppress automargin */
     28064        TPUTS_TRACE("exit_am_mode");
     28065-       putp(exit_am_mode);
     28066+       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx exit_am_mode);
     28067 
     28068-       PutAttrChar(ch);
     28069-       SP->_curscol--;
     28070-       position_check(SP->_cursrow, SP->_curscol, "exit_am_mode");
     28071+       PutAttrChar(NCURSES_SP_ARGx ch);
     28072+       SP_PARM->_curscol--;
     28073+       position_check(SP_PARM,
     28074+                      SP_PARM->_cursrow,
     28075+                      SP_PARM->_curscol,
     28076+                      "exit_am_mode");
     28077 
     28078        TPUTS_TRACE("enter_am_mode");
     28079-       putp(enter_am_mode);
     28080+       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx enter_am_mode);
     28081     } else if ((enter_insert_mode && exit_insert_mode)
     28082               || insert_character || parm_ich) {
     28083-       GoTo(screen_lines - 1, screen_columns - 2);
     28084-       PutAttrChar(ch);
     28085-       GoTo(screen_lines - 1, screen_columns - 2);
     28086-       InsStr(newscr->_line[screen_lines - 1].text + screen_columns - 2, 1);
     28087+       GoTo(NCURSES_SP_ARGx
     28088+            screen_lines(SP_PARM) - 1,
     28089+            screen_columns(SP_PARM) - 2);
     28090+       PutAttrChar(NCURSES_SP_ARGx ch);
     28091+       GoTo(NCURSES_SP_ARGx
     28092+            screen_lines(SP_PARM) - 1,
     28093+            screen_columns(SP_PARM) - 2);
     28094+       InsStr(NCURSES_SP_ARGx
     28095+              NewScreen(SP_PARM)->_line[screen_lines(SP_PARM) - 1].text +
     28096+              screen_columns(SP_PARM) - 2, 1);
     28097     }
     28098 }
     28099 
     28100@@ -391,7 +418,7 @@
     28101  * Wrap the cursor position, i.e., advance to the beginning of the next line.
     28102  */
     28103 static void
     28104-wrap_cursor(void)
     28105+wrap_cursor(NCURSES_SP_DCL0)
     28106 {
     28107     if (eat_newline_glitch) {
     28108        /*
     28109@@ -407,40 +434,45 @@
     28110         * it's safe to just tell the code that the cursor is in hyperspace and
     28111         * let the next mvcur() call straighten things out.
     28112         */
     28113-       SP->_curscol = -1;
     28114-       SP->_cursrow = -1;
     28115+       SP_PARM->_curscol = -1;
     28116+       SP_PARM->_cursrow = -1;
     28117     } else if (auto_right_margin) {
     28118-       SP->_curscol = 0;
     28119-       SP->_cursrow++;
     28120+       SP_PARM->_curscol = 0;
     28121+       SP_PARM->_cursrow++;
     28122        /*
     28123         * We've actually moved - but may have to work around problems with
     28124         * video attributes not working.
     28125         */
     28126-       if (!move_standout_mode && AttrOf(SCREEN_ATTRS(SP))) {
     28127+       if (!move_standout_mode && AttrOf(SCREEN_ATTRS(SP_PARM))) {
     28128            TR(TRACE_CHARPUT, ("turning off (%#lx) %s before wrapping",
     28129-                              (unsigned long) AttrOf(SCREEN_ATTRS(SP)),
     28130-                              _traceattr(AttrOf(SCREEN_ATTRS(SP)))));
     28131-           (void) VIDATTR(A_NORMAL, 0);
     28132+                              (unsigned long) AttrOf(SCREEN_ATTRS(SP_PARM)),
     28133+                              _traceattr(AttrOf(SCREEN_ATTRS(SP_PARM)))));
     28134+           (void) VIDATTR(SP_PARM, A_NORMAL, 0);
     28135        }
     28136     } else {
     28137-       SP->_curscol--;
     28138+       SP_PARM->_curscol--;
     28139     }
     28140-    position_check(SP->_cursrow, SP->_curscol, "wrap_cursor");
     28141+    position_check(SP_PARM,
     28142+                  SP_PARM->_cursrow,
     28143+                  SP_PARM->_curscol,
     28144+                  "wrap_cursor");
     28145 }
     28146 
     28147 static NCURSES_INLINE void
     28148-PutChar(const ARG_CH_T ch)
     28149+PutChar(NCURSES_SP_DCLx const ARG_CH_T ch)
     28150 /* insert character, handling automargin stuff */
     28151 {
     28152-    if (SP->_cursrow == screen_lines - 1 && SP->_curscol == screen_columns - 1)
     28153-       PutCharLR(ch);
     28154-    else
     28155-       PutAttrChar(ch);
     28156+    if (SP_PARM->_cursrow == screen_lines(SP_PARM) - 1 &&
     28157+       SP_PARM->_curscol == screen_columns(SP_PARM) - 1) {
     28158+       PutCharLR(NCURSES_SP_ARGx ch);
     28159+    } else {
     28160+       PutAttrChar(NCURSES_SP_ARGx ch);
     28161+    }
     28162 
     28163-    if (SP->_curscol >= screen_columns)
     28164-       wrap_cursor();
     28165+    if (SP_PARM->_curscol >= screen_columns(SP_PARM))
     28166+       wrap_cursor(NCURSES_SP_ARG);
     28167 
     28168-    position_check(SP->_cursrow, SP->_curscol, "PutChar");
     28169+    position_check(SP_PARM, SP_PARM->_cursrow, SP_PARM->_curscol, "PutChar");
     28170 }
     28171 
     28172 /*
     28173@@ -450,19 +482,19 @@
     28174  * or can be output by clearing (A_COLOR in case of bce-terminal) are excluded.
     28175  */
     28176 static NCURSES_INLINE bool
     28177-can_clear_with(ARG_CH_T ch)
     28178+can_clear_with(NCURSES_SP_DCLx ARG_CH_T ch)
     28179 {
     28180-    if (!back_color_erase && SP->_coloron) {
     28181+    if (!back_color_erase && SP_PARM->_coloron) {
     28182 #if NCURSES_EXT_FUNCS
     28183        int pair;
     28184 
     28185-       if (!SP->_default_color)
     28186+       if (!SP_PARM->_default_color)
     28187            return FALSE;
     28188-       if (SP->_default_fg != C_MASK || SP->_default_bg != C_MASK)
     28189+       if (SP_PARM->_default_fg != C_MASK || SP_PARM->_default_bg != C_MASK)
     28190            return FALSE;
     28191        if ((pair = GetPair(CHDEREF(ch))) != 0) {
     28192            short fg, bg;
     28193-           pair_content(pair, &fg, &bg);
     28194+           NCURSES_SP_NAME(pair_content) (NCURSES_SP_ARGx pair, &fg, &bg);
     28195            if (fg != C_MASK || bg != C_MASK)
     28196                return FALSE;
     28197        }
     28198@@ -488,7 +520,7 @@
     28199  * This code is optimized using ech and rep.
     28200  */
     28201 static int
     28202-EmitRange(const NCURSES_CH_T * ntext, int num)
     28203+EmitRange(NCURSES_SP_DCLx const NCURSES_CH_T * ntext, int num)
     28204 {
     28205     int i;
     28206 
     28207@@ -500,13 +532,13 @@
     28208            NCURSES_CH_T ntext0;
     28209 
     28210            while (num > 1 && !CharEq(ntext[0], ntext[1])) {
     28211-               PutChar(CHREF(ntext[0]));
     28212+               PutChar(NCURSES_SP_ARGx CHREF(ntext[0]));
     28213                ntext++;
     28214                num--;
     28215            }
     28216            ntext0 = ntext[0];
     28217            if (num == 1) {
     28218-               PutChar(CHREF(ntext0));
     28219+               PutChar(NCURSES_SP_ARGx CHREF(ntext0));
     28220                return 0;
     28221            }
     28222            runcount = 2;
     28223@@ -523,10 +555,10 @@
     28224             * which it would be marginally advantageous.
     28225             */
     28226            if (erase_chars
     28227-               && runcount > SP->_ech_cost + SP->_cup_ch_cost
     28228-               && can_clear_with(CHREF(ntext0))) {
     28229-               UpdateAttrs(ntext0);
     28230-               putp(TPARM_1(erase_chars, runcount));
     28231+               && runcount > SP_PARM->_ech_cost + SP_PARM->_cup_ch_cost
     28232+               && can_clear_with(NCURSES_SP_ARGx CHREF(ntext0))) {
     28233+               UpdateAttrs(SP_PARM, ntext0);
     28234+               NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx TPARM_1(erase_chars, runcount));
     28235 
     28236                /*
     28237                 * If this is the last part of the given interval,
     28238@@ -534,27 +566,34 @@
     28239                 * last update on the line.
     28240                 */
     28241                if (runcount < num) {
     28242-                   GoTo(SP->_cursrow, SP->_curscol + runcount);
     28243+                   GoTo(NCURSES_SP_ARGx
     28244+                        SP_PARM->_cursrow,
     28245+                        SP_PARM->_curscol + runcount);
     28246                } else {
     28247                    return 1;   /* cursor stays in the middle */
     28248                }
     28249-           } else if (repeat_char && runcount > SP->_rep_cost) {
     28250-               bool wrap_possible = (SP->_curscol + runcount >= screen_columns);
     28251+           } else if (repeat_char && runcount > SP_PARM->_rep_cost) {
     28252+               bool wrap_possible = (SP_PARM->_curscol + runcount >=
     28253+                                     screen_columns(SP_PARM));
     28254                int rep_count = runcount;
     28255 
     28256                if (wrap_possible)
     28257                    rep_count--;
     28258 
     28259-               UpdateAttrs(ntext0);
     28260-               tputs(TPARM_2(repeat_char, CharOf(ntext0), rep_count),
     28261-                     rep_count, _nc_outch);
     28262-               SP->_curscol += rep_count;
     28263+               UpdateAttrs(SP_PARM, ntext0);
     28264+               NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     28265+                                       TPARM_2(repeat_char,
     28266+                                               CharOf(ntext0),
     28267+                                               rep_count),
     28268+                                       rep_count,
     28269+                                       NCURSES_SP_NAME(_nc_outch));
     28270+               SP_PARM->_curscol += rep_count;
     28271 
     28272                if (wrap_possible)
     28273-                   PutChar(CHREF(ntext0));
     28274+                   PutChar(NCURSES_SP_ARGx CHREF(ntext0));
     28275            } else {
     28276                for (i = 0; i < runcount; i++)
     28277-                   PutChar(CHREF(ntext[i]));
     28278+                   PutChar(NCURSES_SP_ARGx CHREF(ntext[i]));
     28279            }
     28280            ntext += runcount;
     28281            num -= runcount;
     28282@@ -563,7 +602,7 @@
     28283     }
     28284 
     28285     for (i = 0; i < num; i++)
     28286-       PutChar(CHREF(ntext[i]));
     28287+       PutChar(NCURSES_SP_ARGx CHREF(ntext[i]));
     28288     return 0;
     28289 }
     28290 
     28291@@ -576,39 +615,40 @@
     28292  * Returns: same as EmitRange
     28293  */
     28294 static int
     28295-PutRange(const NCURSES_CH_T * otext,
     28296+PutRange(NCURSES_SP_DCLx
     28297+        const NCURSES_CH_T * otext,
     28298         const NCURSES_CH_T * ntext,
     28299         int row,
     28300         int first, int last)
     28301 {
     28302     int i, j, same;
     28303 
     28304-    TR(TRACE_CHARPUT, ("PutRange(%p, %p, %d, %d, %d)",
     28305-                      otext, ntext, row, first, last));
     28306+    TR(TRACE_CHARPUT, ("PutRange(%p, %p, %p, %d, %d, %d)",
     28307+                      SP_PARM, otext, ntext, row, first, last));
     28308 
     28309     if (otext != ntext
     28310-       && (last - first + 1) > SP->_inline_cost) {
     28311+       && (last - first + 1) > SP_PARM->_inline_cost) {
     28312        for (j = first, same = 0; j <= last; j++) {
     28313            if (!same && isWidecExt(otext[j]))
     28314                continue;
     28315            if (CharEq(otext[j], ntext[j])) {
     28316                same++;
     28317            } else {
     28318-               if (same > SP->_inline_cost) {
     28319-                   EmitRange(ntext + first, j - same - first);
     28320-                   GoTo(row, first = j);
     28321+               if (same > SP_PARM->_inline_cost) {
     28322+                   EmitRange(NCURSES_SP_ARGx ntext + first, j - same - first);
     28323+                   GoTo(NCURSES_SP_ARGx row, first = j);
     28324                }
     28325                same = 0;
     28326            }
     28327        }
     28328-       i = EmitRange(ntext + first, j - same - first);
     28329+       i = EmitRange(NCURSES_SP_ARGx ntext + first, j - same - first);
     28330        /*
     28331         * Always return 1 for the next GoTo() after a PutRange() if we found
     28332         * identical characters at end of interval
     28333         */
     28334        return (same == 0 ? i : 1);
     28335     }
     28336-    return EmitRange(ntext + first, last - first + 1);
     28337+    return EmitRange(NCURSES_SP_ARGx ntext + first, last - first + 1);
     28338 }
     28339 
     28340 /* leave unbracketed here so 'indent' works */
     28341@@ -618,7 +658,7 @@
    2007728342                if_USE_SCROLL_HINTS(win->_line[row].oldindex = row)
    2007828343 
     
    2008328348     int i;
    2008428349     int nonempty;
    20085 @@ -645,11 +646,11 @@
     28350@@ -628,28 +668,47 @@
     28351 
     28352     T((T_CALLED("doupdate()")));
     28353 
     28354-    if (curscr == 0
     28355-       || newscr == 0)
     28356+#if !USE_REENTRANT
     28357+    /*
     28358+     * It is "legal" but unlikely that an application could assign a new
     28359+     * value to one of the standard windows.  Check for that possibility
     28360+     * and try to recover.
     28361+     *
     28362+     * We do not allow applications to assign new values in the reentrant
     28363+     * model.
     28364+     */
     28365+#define SyncScreens(internal,exported) \
     28366+       if (internal == 0) internal = exported; \
     28367+       if (internal != exported) exported = internal
     28368+
     28369+    SyncScreens(CurScreen(SP_PARM), curscr);
     28370+    SyncScreens(NewScreen(SP_PARM), newscr);
     28371+    SyncScreens(StdScreen(SP_PARM), stdscr);
     28372+#endif
     28373+
     28374+    if (CurScreen(SP_PARM) == 0
     28375+       || NewScreen(SP_PARM) == 0
     28376+       || StdScreen(SP_PARM) == 0)
     28377        returnCode(ERR);
     28378 
     28379 #ifdef TRACE
     28380     if (USE_TRACEF(TRACE_UPDATE)) {
     28381-       if (curscr->_clear)
     28382+       if (CurScreen(SP_PARM)->_clear)
     28383            _tracef("curscr is clear");
     28384        else
     28385-           _tracedump("curscr", curscr);
     28386-       _tracedump("newscr", newscr);
     28387+           _tracedump("curscr", CurScreen(SP_PARM));
     28388+       _tracedump("newscr", NewScreen(SP_PARM));
     28389        _nc_unlock_global(tracef);
     28390     }
     28391 #endif /* TRACE */
    2008628392 
    2008728393     _nc_signal_handler(FALSE);
     
    2009828404         * This is a transparent extension:  XSI does not address it,
    2009928405         * and applications need not know that ncurses can do it.
    20100 @@ -658,20 +659,20 @@
     28406@@ -658,20 +717,20 @@
    2010128407         * (this can happen in an xterm, for example), and resize the
    2010228408         * ncurses data structures accordingly.
     
    2011128417 
    2011228418        T(("coming back from shell mode"));
    20113         reset_prog_mode();
    20114  
    20115         _nc_mvcur_resume();
    20116         _nc_screen_resume();
     28419-       reset_prog_mode();
     28420+       NCURSES_SP_NAME(reset_prog_mode) (NCURSES_SP_ARG);
     28421 
     28422-       _nc_mvcur_resume();
     28423-       _nc_screen_resume();
    2011728424-       SP->_mouse_resume(SP);
     28425+       NCURSES_SP_NAME(_nc_mvcur_resume) (NCURSES_SP_ARG);
     28426+       NCURSES_SP_NAME(_nc_screen_resume) (NCURSES_SP_ARG);
    2011828427+       SP_PARM->_mouse_resume(SP_PARM);
    2011928428 
     
    2012328432 #if USE_TRACE_TIMES
    2012428433     /* zero the metering machinery */
    20125 @@ -699,7 +700,7 @@
    20126             for (j = 0; j < screen_columns; j++) {
     28434@@ -695,11 +754,11 @@
     28435        int j, k;
     28436        attr_t rattr = A_NORMAL;
     28437 
     28438-       for (i = 0; i < screen_lines; i++) {
     28439-           for (j = 0; j < screen_columns; j++) {
     28440+       for (i = 0; i < screen_lines(SP_PARM); i++) {
     28441+           for (j = 0; j < screen_columns(SP_PARM); j++) {
    2012728442                bool failed = FALSE;
    20128                 NCURSES_CH_T *thisline = newscr->_line[i].text;
     28443-               NCURSES_CH_T *thisline = newscr->_line[i].text;
    2012928444-               attr_t thisattr = AttrOf(thisline[j]) & SP->_xmc_triggers;
     28445+               NCURSES_CH_T *thisline = NewScreen(SP_PARM)->_line[i].text;
    2013028446+               attr_t thisattr = AttrOf(thisline[j]) & SP_PARM->_xmc_triggers;
    2013128447                attr_t turnon = thisattr & ~rattr;
    2013228448 
    2013328449                /* is an attribute turned on here? */
    20134 @@ -717,7 +718,7 @@
     28450@@ -717,8 +776,8 @@
    2013528451                 * there's enough room to set the attribute before the first
    2013628452                 * non-blank in the run.
    2013728453                 */
    2013828454-#define SAFE(a)        (!((a) & SP->_xmc_triggers))
    20139 +#define SAFE(a)        (!((a) & SP_PARM->_xmc_triggers))
    20140                 if (ISBLANK(thisline[j]) && SAFE(turnon)) {
     28455-               if (ISBLANK(thisline[j]) && SAFE(turnon)) {
     28456+#define SAFE(scr,a)    (!((a) & (scr)->_xmc_triggers))
     28457+               if (ISBLANK(thisline[j]) && SAFE(SP_PARM, turnon)) {
    2014128458                    RemAttr(thisline[j], turnon);
    2014228459                    continue;
    20143 @@ -748,7 +749,7 @@
    20144                     for (m = i; m < screen_lines; m++) {
    20145                         for (; n < screen_columns; n++) {
    20146                             attr_t testattr = AttrOf(newscr->_line[m].text[n]);
     28460                }
     28461@@ -727,14 +786,14 @@
     28462                for (k = 1; k <= magic_cookie_glitch; k++) {
     28463                    if (j - k < 0
     28464                        || !ISBLANK(thisline[j - k])
     28465-                       || !SAFE(AttrOf(thisline[j - k]))) {
     28466+                       || !SAFE(SP_PARM, AttrOf(thisline[j - k]))) {
     28467                        failed = TRUE;
     28468                        TR(TRACE_ATTRS, ("No room at start in %d,%d%s%s",
     28469                                         i, j - k,
     28470                                         (ISBLANK(thisline[j - k])
     28471                                          ? ""
     28472                                          : ":nonblank"),
     28473-                                        (SAFE(AttrOf(thisline[j - k]))
     28474+                                        (SAFE(SP_PARM, AttrOf(thisline[j - k]))
     28475                                          ? ""
     28476                                          : ":unsafe")));
     28477                        break;
     28478@@ -745,10 +804,12 @@
     28479                    int m, n = j;
     28480 
     28481                    /* find end of span, if it's onscreen */
     28482-                   for (m = i; m < screen_lines; m++) {
     28483-                       for (; n < screen_columns; n++) {
     28484-                           attr_t testattr = AttrOf(newscr->_line[m].text[n]);
    2014728485-                           if ((testattr & SP->_xmc_triggers) == rattr) {
     28486+                   for (m = i; m < screen_lines(SP_PARM); m++) {
     28487+                       for (; n < screen_columns(SP_PARM); n++) {
     28488+                           attr_t testattr
     28489+                           = AttrOf(NewScreen(SP_PARM)->_line[m].text[n]);
     28490+
    2014828491+                           if ((testattr & SP_PARM->_xmc_triggers) == rattr) {
    2014928492                                end_onscreen = TRUE;
    2015028493                                TR(TRACE_ATTRS,
    2015128494                                   ("Range attributed with %s ends at (%d, %d)",
    20152 @@ -809,7 +810,7 @@
    20153                     for (p = i; p < screen_lines; p++) {
    20154                         for (; q < screen_columns; q++) {
    20155                             attr_t testattr = AttrOf(newscr->_line[p].text[q]);
     28495@@ -764,7 +825,8 @@
     28496                  foundit:;
     28497 
     28498                    if (end_onscreen) {
     28499-                       NCURSES_CH_T *lastline = newscr->_line[m].text;
     28500+                       NCURSES_CH_T *lastline =
     28501+                       NewScreen(SP_PARM)->_line[m].text;
     28502 
     28503                        /*
     28504                         * If there are safely-attributed blanks at the end of
     28505@@ -773,15 +835,15 @@
     28506                         */
     28507                        while (n >= 0
     28508                               && ISBLANK(lastline[n])
     28509-                              && SAFE(AttrOf(lastline[n]))) {
     28510+                              && SAFE(SP_PARM, AttrOf(lastline[n]))) {
     28511                            RemAttr(lastline[n--], turnon);
     28512                        }
     28513 
     28514                        /* check that there's enough room at end of span */
     28515                        for (k = 1; k <= magic_cookie_glitch; k++) {
     28516-                           if (n + k >= screen_columns
     28517+                           if (n + k >= screen_columns(SP_PARM)
     28518                                || !ISBLANK(lastline[n + k])
     28519-                               || !SAFE(AttrOf(lastline[n + k]))) {
     28520+                               || !SAFE(SP_PARM, AttrOf(lastline[n + k]))) {
     28521                                failed = TRUE;
     28522                                TR(TRACE_ATTRS,
     28523                                   ("No room at end in %d,%d%s%s",
     28524@@ -789,7 +851,7 @@
     28525                                    (ISBLANK(lastline[n + k])
     28526                                     ? ""
     28527                                     : ":nonblank"),
     28528-                                   (SAFE(AttrOf(lastline[n + k]))
     28529+                                   (SAFE(SP_PARM, AttrOf(lastline[n + k]))
     28530                                     ? ""
     28531                                     : ":unsafe")));
     28532                                break;
     28533@@ -806,12 +868,13 @@
     28534                        _traceattr(turnon), i, j));
     28535 
     28536                    /* turn off new attributes over span */
     28537-                   for (p = i; p < screen_lines; p++) {
     28538-                       for (; q < screen_columns; q++) {
     28539-                           attr_t testattr = AttrOf(newscr->_line[p].text[q]);
    2015628540-                           if ((testattr & SP->_xmc_triggers) == rattr)
     28541+                   for (p = i; p < screen_lines(SP_PARM); p++) {
     28542+                       for (; q < screen_columns(SP_PARM); q++) {
     28543+                           attr_t testattr =
     28544+                           AttrOf(NewScreen(SP_PARM)->_line[p].text[q]);
    2015728545+                           if ((testattr & SP_PARM->_xmc_triggers) == rattr)
    2015828546                                goto foundend;
    20159                             RemAttr(newscr->_line[p].text[q], turnon);
     28547-                           RemAttr(newscr->_line[p].text[q], turnon);
     28548+                           RemAttr(NewScreen(SP_PARM)->_line[p].text[q], turnon);
    2016028549                        }
    20161 @@ -857,7 +858,7 @@
    20162  
    20163         nonempty = min(screen_lines, newscr->_maxy + 1);
     28550                        q = 0;
     28551                    }
     28552@@ -837,7 +900,7 @@
     28553        /* show altered highlights after magic-cookie check */
     28554        if (USE_TRACEF(TRACE_UPDATE)) {
     28555            _tracef("After magic-cookie check...");
     28556-           _tracedump("newscr", newscr);
     28557+           _tracedump("newscr", NewScreen(SP_PARM));
     28558            _nc_unlock_global(tracef);
     28559        }
     28560 #endif /* TRACE */
     28561@@ -845,23 +908,23 @@
     28562 #endif /* USE_XMC_SUPPORT */
     28563 
     28564     nonempty = 0;
     28565-    if (curscr->_clear || newscr->_clear) {    /* force refresh ? */
     28566-       ClrUpdate();
     28567-       curscr->_clear = FALSE; /* reset flag */
     28568-       newscr->_clear = FALSE; /* reset flag */
     28569+    if (CurScreen(SP_PARM)->_clear || NewScreen(SP_PARM)->_clear) {    /* force refresh ? */
     28570+       ClrUpdate(NCURSES_SP_ARG);
     28571+       CurScreen(SP_PARM)->_clear = FALSE;     /* reset flag */
     28572+       NewScreen(SP_PARM)->_clear = FALSE;     /* reset flag */
     28573     } else {
     28574        int changedlines = CHECK_INTERVAL;
     28575 
     28576-       if (check_pending())
     28577+       if (check_pending(NCURSES_SP_ARG))
     28578            goto cleanup;
     28579 
     28580-       nonempty = min(screen_lines, newscr->_maxy + 1);
     28581+       nonempty = min(screen_lines(SP_PARM), NewScreen(SP_PARM)->_maxy + 1);
    2016428582 
    2016528583-       if (SP->_scrolling) {
     
    2016828586        }
    2016928587 
    20170 @@ -940,6 +941,14 @@
     28588-       nonempty = ClrBottom(nonempty);
     28589+       nonempty = ClrBottom(NCURSES_SP_ARGx nonempty);
     28590 
     28591        TR(TRACE_UPDATE, ("Transforming lines, nonempty %d", nonempty));
     28592        for (i = 0; i < nonempty; i++) {
     28593@@ -869,46 +932,46 @@
     28594             * Here is our line-breakout optimization.
     28595             */
     28596            if (changedlines == CHECK_INTERVAL) {
     28597-               if (check_pending())
     28598+               if (check_pending(NCURSES_SP_ARG))
     28599                    goto cleanup;
     28600                changedlines = 0;
     28601            }
     28602 
     28603            /*
     28604-            * newscr->line[i].firstchar is normally set
     28605-            * by wnoutrefresh.  curscr->line[i].firstchar
     28606+            * newscr.line[i].firstchar is normally set
     28607+            * by wnoutrefresh.  curscr.line[i].firstchar
     28608             * is normally set by _nc_scroll_window in the
     28609             * vertical-movement optimization code,
     28610             */
     28611-           if (newscr->_line[i].firstchar != _NOCHANGE
     28612-               || curscr->_line[i].firstchar != _NOCHANGE) {
     28613-               TransformLine(i);
     28614+           if (NewScreen(SP_PARM)->_line[i].firstchar != _NOCHANGE
     28615+               || CurScreen(SP_PARM)->_line[i].firstchar != _NOCHANGE) {
     28616+               TransformLine(NCURSES_SP_ARGx i);
     28617                changedlines++;
     28618            }
     28619 
     28620            /* mark line changed successfully */
     28621-           if (i <= newscr->_maxy) {
     28622-               MARK_NOCHANGE(newscr, i);
     28623+           if (i <= NewScreen(SP_PARM)->_maxy) {
     28624+               MARK_NOCHANGE(NewScreen(SP_PARM), i);
     28625            }
     28626-           if (i <= curscr->_maxy) {
     28627-               MARK_NOCHANGE(curscr, i);
     28628+           if (i <= CurScreen(SP_PARM)->_maxy) {
     28629+               MARK_NOCHANGE(CurScreen(SP_PARM), i);
     28630            }
     28631        }
     28632     }
     28633 
     28634     /* put everything back in sync */
     28635-    for (i = nonempty; i <= newscr->_maxy; i++) {
     28636-       MARK_NOCHANGE(newscr, i);
     28637+    for (i = nonempty; i <= NewScreen(SP_PARM)->_maxy; i++) {
     28638+       MARK_NOCHANGE(NewScreen(SP_PARM), i);
     28639     }
     28640-    for (i = nonempty; i <= curscr->_maxy; i++) {
     28641-       MARK_NOCHANGE(curscr, i);
     28642+    for (i = nonempty; i <= CurScreen(SP_PARM)->_maxy; i++) {
     28643+       MARK_NOCHANGE(CurScreen(SP_PARM), i);
     28644     }
     28645 
     28646-    if (!newscr->_leaveok) {
     28647-       curscr->_curx = newscr->_curx;
     28648-       curscr->_cury = newscr->_cury;
     28649+    if (!NewScreen(SP_PARM)->_leaveok) {
     28650+       CurScreen(SP_PARM)->_curx = NewScreen(SP_PARM)->_curx;
     28651+       CurScreen(SP_PARM)->_cury = NewScreen(SP_PARM)->_cury;
     28652 
     28653-       GoTo(curscr->_cury, curscr->_curx);
     28654+       GoTo(NCURSES_SP_ARGx CurScreen(SP_PARM)->_cury, CurScreen(SP_PARM)->_curx);
     28655     }
     28656 
     28657   cleanup:
     28658@@ -921,10 +984,10 @@
     28659 #if USE_XMC_SUPPORT
     28660     if (magic_cookie_glitch != 0)
     28661 #endif
     28662-       UpdateAttrs(normal);
     28663+       UpdateAttrs(SP_PARM, normal);
     28664 
     28665-    _nc_flush();
     28666-    WINDOW_ATTRS(curscr) = WINDOW_ATTRS(newscr);
     28667+    NCURSES_SP_NAME(_nc_flush) (NCURSES_SP_ARG);
     28668+    WINDOW_ATTRS(CurScreen(SP_PARM)) = WINDOW_ATTRS(NewScreen(SP_PARM));
     28669 
     28670 #if USE_TRACE_TIMES
     28671     (void) times(&after);
     28672@@ -940,6 +1003,14 @@
    2017128673     returnCode(OK);
    2017228674 }
     
    2018328685  *     ClrBlank(win)
    2018428686  *
    20185 @@ -1165,8 +1174,8 @@
     28687@@ -951,10 +1022,10 @@
     28688  *     in the wbkgd() call.  Assume 'stdscr' for this case.
     28689  */
     28690 #define BCE_ATTRS (A_NORMAL|A_COLOR)
     28691-#define BCE_BKGD(win) (((win) == curscr ? stdscr : (win))->_nc_bkgd)
     28692+#define BCE_BKGD(win) (((win) == CurScreen(SP_PARM) ? StdScreen(SP_PARM) : (win))->_nc_bkgd)
     28693 
     28694 static NCURSES_INLINE NCURSES_CH_T
     28695-ClrBlank(WINDOW *win)
     28696+ClrBlank(NCURSES_SP_DCLx WINDOW *win)
     28697 {
     28698     NCURSES_CH_T blank = blankchar;
     28699     if (back_color_erase)
     28700@@ -970,23 +1041,24 @@
     28701 */
     28702 
     28703 static void
     28704-ClrUpdate(void)
     28705+ClrUpdate(NCURSES_SP_DCL0)
     28706 {
     28707-    int i;
     28708-    NCURSES_CH_T blank = ClrBlank(stdscr);
     28709-    int nonempty = min(screen_lines, newscr->_maxy + 1);
     28710-
     28711     TR(TRACE_UPDATE, (T_CALLED("ClrUpdate")));
     28712+    if (0 != SP_PARM) {
     28713+       int i;
     28714+       NCURSES_CH_T blank = ClrBlank(NCURSES_SP_ARGx StdScreen(SP_PARM));
     28715+       int nonempty = min(screen_lines(SP_PARM),
     28716+                          NewScreen(SP_PARM)->_maxy + 1);
     28717 
     28718-    ClearScreen(blank);
     28719+       ClearScreen(NCURSES_SP_ARGx blank);
     28720 
     28721-    TR(TRACE_UPDATE, ("updating screen from scratch"));
     28722+       TR(TRACE_UPDATE, ("updating screen from scratch"));
     28723 
     28724-    nonempty = ClrBottom(nonempty);
     28725-
     28726-    for (i = 0; i < nonempty; i++)
     28727-       TransformLine(i);
     28728+       nonempty = ClrBottom(NCURSES_SP_ARGx nonempty);
     28729 
     28730+       for (i = 0; i < nonempty; i++)
     28731+           TransformLine(NCURSES_SP_ARGx i);
     28732+    }
     28733     TR(TRACE_UPDATE, (T_RETURN("")));
     28734 }
     28735 
     28736@@ -997,15 +1069,16 @@
     28737 */
     28738 
     28739 static void
     28740-ClrToEOL(NCURSES_CH_T blank, bool needclear)
     28741+ClrToEOL(NCURSES_SP_DCLx NCURSES_CH_T blank, bool needclear)
     28742 {
     28743     int j;
     28744 
     28745-    if (curscr != 0
     28746-       && SP->_cursrow >= 0) {
     28747-       for (j = SP->_curscol; j < screen_columns; j++) {
     28748+    if (CurScreen(SP_PARM) != 0
     28749+       && SP_PARM->_cursrow >= 0) {
     28750+       for (j = SP_PARM->_curscol; j < screen_columns(SP_PARM); j++) {
     28751            if (j >= 0) {
     28752-               NCURSES_CH_T *cp = &(curscr->_line[SP->_cursrow].text[j]);
     28753+               NCURSES_CH_T *cp =
     28754+               &(CurScreen(SP_PARM)->_line[SP_PARM->_cursrow].text[j]);
     28755 
     28756                if (!CharEq(*cp, blank)) {
     28757                    *cp = blank;
     28758@@ -1018,14 +1091,14 @@
     28759     }
     28760 
     28761     if (needclear) {
     28762-       UpdateAttrs(blank);
     28763+       UpdateAttrs(SP_PARM, blank);
     28764        TPUTS_TRACE("clr_eol");
     28765-       if (clr_eol && SP->_el_cost <= (screen_columns - SP->_curscol)) {
     28766-           putp(clr_eol);
     28767+       if (clr_eol && SP_PARM->_el_cost <= (screen_columns(SP_PARM) - SP_PARM->_curscol)) {
     28768+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx clr_eol);
     28769        } else {
     28770-           int count = (screen_columns - SP->_curscol);
     28771+           int count = (screen_columns(SP_PARM) - SP_PARM->_curscol);
     28772            while (count-- > 0)
     28773-               PutChar(CHREF(blank));
     28774+               PutChar(NCURSES_SP_ARGx CHREF(blank));
     28775        }
     28776     }
     28777 }
     28778@@ -1037,23 +1110,29 @@
     28779 */
     28780 
     28781 static void
     28782-ClrToEOS(NCURSES_CH_T blank)
     28783+ClrToEOS(NCURSES_SP_DCLx NCURSES_CH_T blank)
     28784 {
     28785     int row, col;
     28786 
     28787-    row = SP->_cursrow;
     28788-    col = SP->_curscol;
     28789-
     28790-    UpdateAttrs(blank);
     28791-    TPUTS_TRACE("clr_eos");
     28792-    tputs(clr_eos, screen_lines - row, _nc_outch);
     28793+    if (0 == SP_PARM)
     28794+       return;
     28795 
     28796-    while (col < screen_columns)
     28797-       curscr->_line[row].text[col++] = blank;
     28798+    row = SP_PARM->_cursrow;
     28799+    col = SP_PARM->_curscol;
     28800 
     28801-    for (row++; row < screen_lines; row++) {
     28802-       for (col = 0; col < screen_columns; col++)
     28803-           curscr->_line[row].text[col] = blank;
     28804+    UpdateAttrs(SP_PARM, blank);
     28805+    TPUTS_TRACE("clr_eos");
     28806+    NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     28807+                           clr_eos,
     28808+                           screen_lines(SP_PARM) - row,
     28809+                           NCURSES_SP_NAME(_nc_outch));
     28810+
     28811+    while (col < screen_columns(SP_PARM))
     28812+       CurScreen(SP_PARM)->_line[row].text[col++] = blank;
     28813+
     28814+    for (row++; row < screen_lines(SP_PARM); row++) {
     28815+       for (col = 0; col < screen_columns(SP_PARM); col++)
     28816+           CurScreen(SP_PARM)->_line[row].text[col] = blank;
     28817     }
     28818 }
     28819 
     28820@@ -1065,26 +1144,26 @@
     28821  *     screen, checking if each is blank, and one or more are changed.
     28822  */
     28823 static int
     28824-ClrBottom(int total)
     28825+ClrBottom(NCURSES_SP_DCLx int total)
     28826 {
     28827     int row;
     28828     int col;
     28829     int top = total;
     28830-    int last = min(screen_columns, newscr->_maxx + 1);
     28831-    NCURSES_CH_T blank = newscr->_line[total - 1].text[last - 1];
     28832+    int last = min(screen_columns(SP_PARM), NewScreen(SP_PARM)->_maxx + 1);
     28833+    NCURSES_CH_T blank = NewScreen(SP_PARM)->_line[total - 1].text[last - 1];
     28834     bool ok;
     28835 
     28836-    if (clr_eos && can_clear_with(CHREF(blank))) {
     28837+    if (clr_eos && can_clear_with(NCURSES_SP_ARGx CHREF(blank))) {
     28838 
     28839        for (row = total - 1; row >= 0; row--) {
     28840            for (col = 0, ok = TRUE; ok && col < last; col++) {
     28841-               ok = (CharEq(newscr->_line[row].text[col], blank));
     28842+               ok = (CharEq(NewScreen(SP_PARM)->_line[row].text[col], blank));
     28843            }
     28844            if (!ok)
     28845                break;
     28846 
     28847            for (col = 0; ok && col < last; col++) {
     28848-               ok = (CharEq(curscr->_line[row].text[col], blank));
     28849+               ok = (CharEq(CurScreen(SP_PARM)->_line[row].text[col], blank));
     28850            }
     28851            if (!ok)
     28852                top = row;
     28853@@ -1092,11 +1171,11 @@
     28854 
     28855        /* don't use clr_eos for just one line if clr_eol available */
     28856        if (top < total) {
     28857-           GoTo(top, 0);
     28858-           ClrToEOS(blank);
     28859-           if (SP->oldhash && SP->newhash) {
     28860-               for (row = top; row < screen_lines; row++)
     28861-                   SP->oldhash[row] = SP->newhash[row];
     28862+           GoTo(NCURSES_SP_ARGx top, 0);
     28863+           ClrToEOS(NCURSES_SP_ARGx blank);
     28864+           if (SP_PARM->oldhash && SP_PARM->newhash) {
     28865+               for (row = top; row < screen_lines(SP_PARM); row++)
     28866+                   SP_PARM->oldhash[row] = SP_PARM->newhash[row];
     28867            }
     28868        }
     28869     }
     28870@@ -1105,15 +1184,15 @@
     28871 
     28872 #if USE_XMC_SUPPORT
     28873 #if USE_WIDEC_SUPPORT
     28874-#define check_xmc_transition(a, b) \
     28875-    ((((a)->attr ^ (b)->attr) & ~((a)->attr) & SP->_xmc_triggers) != 0)
     28876-#define xmc_turn_on(a,b) check_xmc_transition(&(a), &(b))
     28877+#define check_xmc_transition(sp, a, b)                                 \
     28878+    ((((a)->attr ^ (b)->attr) & ~((a)->attr) & (sp)->_xmc_triggers) != 0)
     28879+#define xmc_turn_on(sp,a,b) check_xmc_transition(sp,&(a), &(b))
     28880 #else
     28881-#define xmc_turn_on(a,b) ((((a)^(b)) & ~(a) & SP->_xmc_triggers) != 0)
     28882+#define xmc_turn_on(sp,a,b) ((((a)^(b)) & ~(a) & (sp)->_xmc_triggers) != 0)
     28883 #endif
     28884 
     28885-#define xmc_new(r,c) newscr->_line[r].text[c]
     28886-#define xmc_turn_off(a,b) xmc_turn_on(b,a)
     28887+#define xmc_new(sp,r,c) NewScreen(SP_PARM)->_line[r].text[c]
     28888+#define xmc_turn_off(sp,a,b) xmc_turn_on(sp,b,a)
     28889 #endif /* USE_XMC_SUPPORT */
     28890 
     28891 /*
     28892@@ -1135,19 +1214,19 @@
     28893 */
     28894 
     28895 static void
     28896-TransformLine(int const lineno)
     28897+TransformLine(NCURSES_SP_DCLx int const lineno)
     28898 {
     28899     int firstChar, oLastChar, nLastChar;
     28900-    NCURSES_CH_T *newLine = newscr->_line[lineno].text;
     28901-    NCURSES_CH_T *oldLine = curscr->_line[lineno].text;
     28902+    NCURSES_CH_T *newLine = NewScreen(SP_PARM)->_line[lineno].text;
     28903+    NCURSES_CH_T *oldLine = CurScreen(SP_PARM)->_line[lineno].text;
     28904     int n;
     28905     bool attrchanged = FALSE;
     28906 
     28907-    TR(TRACE_UPDATE, (T_CALLED("TransformLine(%d)"), lineno));
     28908+    TR(TRACE_UPDATE, (T_CALLED("TransformLine(%p, %d)"), SP_PARM, lineno));
     28909 
     28910     /* copy new hash value to old one */
     28911-    if (SP->oldhash && SP->newhash)
     28912-       SP->oldhash[lineno] = SP->newhash[lineno];
     28913+    if (SP_PARM->oldhash && SP_PARM->newhash)
     28914+       SP_PARM->oldhash[lineno] = SP_PARM->newhash[lineno];
     28915 
     28916     /*
     28917      * If we have colors, there is the possibility of having two color pairs
     28918@@ -1155,19 +1234,20 @@
     28919      * for this case, and update the old line with the new line's colors when
     28920      * they are equivalent.
     28921      */
     28922-    if (SP->_coloron) {
     28923+    if (SP_PARM->_coloron) {
     28924        int oldPair;
     28925        int newPair;
     28926 
     28927-       for (n = 0; n < screen_columns; n++) {
     28928+       for (n = 0; n < screen_columns(SP_PARM); n++) {
     28929            if (!CharEq(newLine[n], oldLine[n])) {
     28930                oldPair = GetPair(oldLine[n]);
    2018628931                newPair = GetPair(newLine[n]);
    2018728932                if (oldPair != newPair
     
    2018928934-                   if (oldPair < COLOR_PAIRS
    2019028935-                       && newPair < COLOR_PAIRS
    20191 +                   if (oldPair < SP->_pair_limit
    20192 +                       && newPair < SP->_pair_limit
    20193                         && SP->_color_pairs[oldPair] == SP->_color_pairs[newPair]) {
     28936-                       && SP->_color_pairs[oldPair] == SP->_color_pairs[newPair]) {
     28937+                   if (oldPair < SP_PARM->_pair_limit
     28938+                       && newPair < SP_PARM->_pair_limit
     28939+                       && (SP_PARM->_color_pairs[oldPair] ==
     28940+                           SP_PARM->_color_pairs[newPair])) {
    2019428941                        SetPair(oldLine[n], GetPair(newLine[n]));
    2019528942                    }
     28943                }
     28944@@ -1177,7 +1257,7 @@
     28945 
     28946     if (ceol_standout_glitch && clr_eol) {
     28947        firstChar = 0;
     28948-       while (firstChar < screen_columns) {
     28949+       while (firstChar < screen_columns(SP_PARM)) {
     28950            if (!SameAttrOf(newLine[firstChar], oldLine[firstChar])) {
     28951                attrchanged = TRUE;
     28952                break;
     28953@@ -1189,9 +1269,13 @@
     28954     firstChar = 0;
     28955 
     28956     if (attrchanged) {         /* we may have to disregard the whole line */
     28957-       GoTo(lineno, firstChar);
     28958-       ClrToEOL(ClrBlank(curscr), FALSE);
     28959-       PutRange(oldLine, newLine, lineno, 0, (screen_columns - 1));
     28960+       GoTo(NCURSES_SP_ARGx lineno, firstChar);
     28961+       ClrToEOL(NCURSES_SP_ARGx
     28962+                ClrBlank(NCURSES_SP_ARGx CurScreen(SP_PARM)),
     28963+                FALSE);
     28964+       PutRange(NCURSES_SP_ARGx
     28965+                oldLine, newLine, lineno, 0,
     28966+                screen_columns(SP_PARM) - 1);
     28967 #if USE_XMC_SUPPORT
     28968 
     28969        /*
     28970@@ -1206,8 +1290,8 @@
     28971         * following operation.
     28972         */
     28973     } else if (magic_cookie_glitch > 0) {
     28974-       GoTo(lineno, firstChar);
     28975-       for (n = 0; n < screen_columns; n++) {
     28976+       GoTo(NCURSES_SP_ARGx lineno, firstChar);
     28977+       for (n = 0; n < screen_columns(SP_PARM); n++) {
     28978            int m = n + magic_cookie_glitch;
     28979 
     28980            /* check for turn-on:
     28981@@ -1216,26 +1300,30 @@
     28982             */
     28983            if (ISBLANK(newLine[n])
     28984                && ((n > 0
     28985-                    && xmc_turn_on(newLine[n - 1], newLine[n]))
     28986+                    && xmc_turn_on(SP_PARM, newLine[n - 1], newLine[n]))
     28987                    || (n == 0
     28988                        && lineno > 0
     28989-                       && xmc_turn_on(xmc_new(lineno - 1, screen_columns - 1),
     28990+                       && xmc_turn_on(SP_PARM,
     28991+                                      xmc_new(SP_PARM, lineno - 1,
     28992+                                              screen_columns(SP_PARM) - 1),
     28993                                       newLine[n])))) {
     28994                n = m;
     28995            }
     28996 
     28997-           PutChar(CHREF(newLine[n]));
     28998+           PutChar(NCURSES_SP_ARGx CHREF(newLine[n]));
     28999 
     29000            /* check for turn-off:
     29001             * If we are writing an attributed non-blank, where the
     29002             * next cell is blank, and not attributed.
     29003             */
     29004            if (!ISBLANK(newLine[n])
     29005-               && ((n + 1 < screen_columns
     29006-                    && xmc_turn_off(newLine[n], newLine[n + 1]))
     29007-                   || (n + 1 >= screen_columns
     29008-                       && lineno + 1 < screen_lines
     29009-                       && xmc_turn_off(newLine[n], xmc_new(lineno + 1, 0))))) {
     29010+               && ((n + 1 < screen_columns(SP_PARM)
     29011+                    && xmc_turn_off(SP_PARM, newLine[n], newLine[n + 1]))
     29012+                   || (n + 1 >= screen_columns(SP_PARM)
     29013+                       && lineno + 1 < screen_lines(SP_PARM)
     29014+                       && xmc_turn_off(SP_PARM,
     29015+                                       newLine[n],
     29016+                                       xmc_new(SP_PARM, lineno + 1, 0))))) {
     29017                n = m;
     29018            }
     29019 
     29020@@ -1246,38 +1334,42 @@
     29021 
     29022        /* it may be cheap to clear leading whitespace with clr_bol */
     29023        blank = newLine[0];
     29024-       if (clr_bol && can_clear_with(CHREF(blank))) {
     29025+       if (clr_bol && can_clear_with(NCURSES_SP_ARGx CHREF(blank))) {
     29026            int oFirstChar, nFirstChar;
     29027 
     29028-           for (oFirstChar = 0; oFirstChar < screen_columns; oFirstChar++)
     29029+           for (oFirstChar = 0;
     29030+                oFirstChar < screen_columns(SP_PARM);
     29031+                oFirstChar++)
     29032                if (!CharEq(oldLine[oFirstChar], blank))
     29033                    break;
     29034-           for (nFirstChar = 0; nFirstChar < screen_columns; nFirstChar++)
     29035+           for (nFirstChar = 0;
     29036+                nFirstChar < screen_columns(SP_PARM);
     29037+                nFirstChar++)
     29038                if (!CharEq(newLine[nFirstChar], blank))
     29039                    break;
     29040 
     29041            if (nFirstChar == oFirstChar) {
     29042                firstChar = nFirstChar;
     29043                /* find the first differing character */
     29044-               while (firstChar < screen_columns
     29045+               while (firstChar < screen_columns(SP_PARM)
     29046                       && CharEq(newLine[firstChar], oldLine[firstChar]))
     29047                    firstChar++;
     29048            } else if (oFirstChar > nFirstChar) {
     29049                firstChar = nFirstChar;
     29050            } else {            /* oFirstChar < nFirstChar */
     29051                firstChar = oFirstChar;
     29052-               if (SP->_el1_cost < nFirstChar - oFirstChar) {
     29053-                   if (nFirstChar >= screen_columns
     29054-                       && SP->_el_cost <= SP->_el1_cost) {
     29055-                       GoTo(lineno, 0);
     29056-                       UpdateAttrs(blank);
     29057+               if (SP_PARM->_el1_cost < nFirstChar - oFirstChar) {
     29058+                   if (nFirstChar >= screen_columns(SP_PARM)
     29059+                       && SP_PARM->_el_cost <= SP_PARM->_el1_cost) {
     29060+                       GoTo(NCURSES_SP_ARGx lineno, 0);
     29061+                       UpdateAttrs(SP_PARM, blank);
     29062                        TPUTS_TRACE("clr_eol");
     29063-                       putp(clr_eol);
     29064+                       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx clr_eol);
     29065                    } else {
     29066-                       GoTo(lineno, nFirstChar - 1);
     29067-                       UpdateAttrs(blank);
     29068+                       GoTo(NCURSES_SP_ARGx lineno, nFirstChar - 1);
     29069+                       UpdateAttrs(SP_PARM, blank);
     29070                        TPUTS_TRACE("clr_bol");
     29071-                       putp(clr_bol);
     29072+                       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx clr_bol);
     29073                    }
     29074 
     29075                    while (firstChar < nFirstChar)
     29076@@ -1286,29 +1378,34 @@
     29077            }
     29078        } else {
     29079            /* find the first differing character */
     29080-           while (firstChar < screen_columns
     29081+           while (firstChar < screen_columns(SP_PARM)
     29082                   && CharEq(newLine[firstChar], oldLine[firstChar]))
     29083                firstChar++;
     29084        }
     29085        /* if there wasn't one, we're done */
     29086-       if (firstChar >= screen_columns) {
     29087+       if (firstChar >= screen_columns(SP_PARM)) {
     29088            TR(TRACE_UPDATE, (T_RETURN("")));
     29089            return;
     29090        }
     29091 
     29092-       blank = newLine[screen_columns - 1];
     29093+       blank = newLine[screen_columns(SP_PARM) - 1];
     29094 
     29095-       if (!can_clear_with(CHREF(blank))) {
     29096+       if (!can_clear_with(NCURSES_SP_ARGx CHREF(blank))) {
     29097            /* find the last differing character */
     29098-           nLastChar = screen_columns - 1;
     29099+           nLastChar = screen_columns(SP_PARM) - 1;
     29100 
     29101            while (nLastChar > firstChar
     29102                   && CharEq(newLine[nLastChar], oldLine[nLastChar]))
     29103                nLastChar--;
     29104 
     29105            if (nLastChar >= firstChar) {
     29106-               GoTo(lineno, firstChar);
     29107-               PutRange(oldLine, newLine, lineno, firstChar, nLastChar);
     29108+               GoTo(NCURSES_SP_ARGx lineno, firstChar);
     29109+               PutRange(NCURSES_SP_ARGx
     29110+                        oldLine,
     29111+                        newLine,
     29112+                        lineno,
     29113+                        firstChar,
     29114+                        nLastChar);
     29115                memcpy(oldLine + firstChar,
     29116                       newLine + firstChar,
     29117                       (nLastChar - firstChar + 1) * sizeof(NCURSES_CH_T));
     29118@@ -1318,32 +1415,43 @@
     29119        }
     29120 
     29121        /* find last non-blank character on old line */
     29122-       oLastChar = screen_columns - 1;
     29123+       oLastChar = screen_columns(SP_PARM) - 1;
     29124        while (oLastChar > firstChar && CharEq(oldLine[oLastChar], blank))
     29125            oLastChar--;
     29126 
     29127        /* find last non-blank character on new line */
     29128-       nLastChar = screen_columns - 1;
     29129+       nLastChar = screen_columns(SP_PARM) - 1;
     29130        while (nLastChar > firstChar && CharEq(newLine[nLastChar], blank))
     29131            nLastChar--;
     29132 
     29133        if ((nLastChar == firstChar)
     29134-           && (SP->_el_cost < (oLastChar - nLastChar))) {
     29135-           GoTo(lineno, firstChar);
     29136+           && (SP_PARM->_el_cost < (oLastChar - nLastChar))) {
     29137+           GoTo(NCURSES_SP_ARGx lineno, firstChar);
     29138            if (!CharEq(newLine[firstChar], blank))
     29139-               PutChar(CHREF(newLine[firstChar]));
     29140-           ClrToEOL(blank, FALSE);
     29141+               PutChar(NCURSES_SP_ARGx CHREF(newLine[firstChar]));
     29142+           ClrToEOL(NCURSES_SP_ARGx blank, FALSE);
     29143        } else if ((nLastChar != oLastChar)
     29144                   && (!CharEq(newLine[nLastChar], oldLine[oLastChar])
     29145                       || !(_nc_idcok && has_ic()))) {
     29146-           GoTo(lineno, firstChar);
     29147-           if ((oLastChar - nLastChar) > SP->_el_cost) {
     29148-               if (PutRange(oldLine, newLine, lineno, firstChar, nLastChar))
     29149-                   GoTo(lineno, nLastChar + 1);
     29150-               ClrToEOL(blank, FALSE);
     29151+           GoTo(NCURSES_SP_ARGx lineno, firstChar);
     29152+           if ((oLastChar - nLastChar) > SP_PARM->_el_cost) {
     29153+               if (PutRange(NCURSES_SP_ARGx
     29154+                            oldLine,
     29155+                            newLine,
     29156+                            lineno,
     29157+                            firstChar,
     29158+                            nLastChar)) {
     29159+                   GoTo(NCURSES_SP_ARGx lineno, nLastChar + 1);
     29160+               }
     29161+               ClrToEOL(NCURSES_SP_ARGx blank, FALSE);
     29162            } else {
     29163                n = max(nLastChar, oLastChar);
     29164-               PutRange(oldLine, newLine, lineno, firstChar, n);
     29165+               PutRange(NCURSES_SP_ARGx
     29166+                        oldLine,
     29167+                        newLine,
     29168+                        lineno,
     29169+                        firstChar,
     29170+                        n);
     29171            }
     29172        } else {
     29173            int nLastNonblank = nLastChar;
     29174@@ -1364,8 +1472,13 @@
     29175 
     29176            n = min(oLastChar, nLastChar);
     29177            if (n >= firstChar) {
     29178-               GoTo(lineno, firstChar);
     29179-               PutRange(oldLine, newLine, lineno, firstChar, n);
     29180+               GoTo(NCURSES_SP_ARGx lineno, firstChar);
     29181+               PutRange(NCURSES_SP_ARGx
     29182+                        oldLine,
     29183+                        newLine,
     29184+                        lineno,
     29185+                        firstChar,
     29186+                        n);
     29187            }
     29188 
     29189            if (oLastChar < nLastChar) {
     29190@@ -1376,21 +1489,26 @@
     29191                    --oLastChar;
     29192                }
     29193 #endif
     29194-               GoTo(lineno, n + 1);
     29195+               GoTo(NCURSES_SP_ARGx lineno, n + 1);
     29196                if ((nLastChar < nLastNonblank)
     29197-                   || InsCharCost(nLastChar - oLastChar) > (m - n)) {
     29198-                   PutRange(oldLine, newLine, lineno, n + 1, m);
     29199+                   || InsCharCost(SP_PARM, nLastChar - oLastChar) > (m - n)) {
     29200+                   PutRange(NCURSES_SP_ARGx
     29201+                            oldLine,
     29202+                            newLine,
     29203+                            lineno,
     29204+                            n + 1,
     29205+                            m);
     29206                } else {
     29207-                   InsStr(&newLine[n + 1], nLastChar - oLastChar);
     29208+                   InsStr(NCURSES_SP_ARGx &newLine[n + 1], nLastChar - oLastChar);
     29209                }
     29210            } else if (oLastChar > nLastChar) {
     29211-               GoTo(lineno, n + 1);
     29212-               if (DelCharCost(oLastChar - nLastChar)
     29213-                   > SP->_el_cost + nLastNonblank - (n + 1)) {
     29214-                   if (PutRange(oldLine, newLine, lineno,
     29215+               GoTo(NCURSES_SP_ARGx lineno, n + 1);
     29216+               if (DelCharCost(SP_PARM, oLastChar - nLastChar)
     29217+                   > SP_PARM->_el_cost + nLastNonblank - (n + 1)) {
     29218+                   if (PutRange(NCURSES_SP_ARGx oldLine, newLine, lineno,
     29219                                 n + 1, nLastNonblank))
     29220-                       GoTo(lineno, nLastNonblank + 1);
     29221-                   ClrToEOL(blank, FALSE);
     29222+                         GoTo(NCURSES_SP_ARGx lineno, nLastNonblank + 1);
     29223+                   ClrToEOL(NCURSES_SP_ARGx blank, FALSE);
     29224                } else {
     29225                    /*
     29226                     * The delete-char sequence will
     29227@@ -1400,18 +1518,18 @@
     29228                     * setting the video attributes from
     29229                     * the last character on the row.
     29230                     */
     29231-                   UpdateAttrs(blank);
     29232-                   DelChar(oLastChar - nLastChar);
     29233+                   UpdateAttrs(SP_PARM, blank);
     29234+                   DelChar(NCURSES_SP_ARGx oLastChar - nLastChar);
     29235                }
     29236            }
     29237        }
     29238     }
     29239 
     29240     /* update the code's internal representation */
     29241-    if (screen_columns > firstChar)
     29242+    if (screen_columns(SP_PARM) > firstChar)
     29243        memcpy(oldLine + firstChar,
     29244               newLine + firstChar,
     29245-              (screen_columns - firstChar) * sizeof(NCURSES_CH_T));
     29246+              (screen_columns(SP_PARM) - firstChar) * sizeof(NCURSES_CH_T));
     29247     TR(TRACE_UPDATE, (T_RETURN("")));
     29248     return;
     29249 }
     29250@@ -1424,7 +1542,7 @@
     29251 */
     29252 
     29253 static void
     29254-ClearScreen(NCURSES_CH_T blank)
     29255+ClearScreen(NCURSES_SP_DCLx NCURSES_CH_T blank)
     29256 {
     29257     int i, j;
     29258     bool fast_clear = (clear_screen || clr_eos || clr_eol);
     29259@@ -1432,9 +1550,13 @@
     29260     TR(TRACE_UPDATE, ("ClearScreen() called"));
     29261 
     29262 #if NCURSES_EXT_FUNCS
     29263-    if (SP->_coloron
     29264-       && !SP->_default_color) {
     29265-       _nc_do_color(GET_SCREEN_PAIR(SP), 0, FALSE, _nc_outch);
     29266+    if (SP_PARM->_coloron
     29267+       && !SP_PARM->_default_color) {
     29268+       NCURSES_SP_NAME(_nc_do_color) (NCURSES_SP_ARGx
     29269+                                      GET_SCREEN_PAIR(SP_PARM),
     29270+                                      0,
     29271+                                      FALSE,
     29272+                                      NCURSES_SP_NAME(_nc_outch));
     29273        if (!back_color_erase) {
     29274            fast_clear = FALSE;
     29275        }
     29276@@ -1443,42 +1565,48 @@
     29277 
     29278     if (fast_clear) {
     29279        if (clear_screen) {
     29280-           UpdateAttrs(blank);
     29281+           UpdateAttrs(SP_PARM, blank);
     29282            TPUTS_TRACE("clear_screen");
     29283-           putp(clear_screen);
     29284-           SP->_cursrow = SP->_curscol = 0;
     29285-           position_check(SP->_cursrow, SP->_curscol, "ClearScreen");
     29286+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx clear_screen);
     29287+           SP_PARM->_cursrow = SP_PARM->_curscol = 0;
     29288+           position_check(SP_PARM,
     29289+                          SP_PARM->_cursrow,
     29290+                          SP_PARM->_curscol,
     29291+                          "ClearScreen");
     29292        } else if (clr_eos) {
     29293-           SP->_cursrow = SP->_curscol = -1;
     29294-           GoTo(0, 0);
     29295+           SP_PARM->_cursrow = SP_PARM->_curscol = -1;
     29296+           GoTo(NCURSES_SP_ARGx 0, 0);
     29297 
     29298-           UpdateAttrs(blank);
     29299+           UpdateAttrs(SP_PARM, blank);
     29300            TPUTS_TRACE("clr_eos");
     29301-           tputs(clr_eos, screen_lines, _nc_outch);
     29302+           NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     29303+                                   clr_eos,
     29304+                                   screen_lines(SP_PARM),
     29305+                                   NCURSES_SP_NAME(_nc_outch));
     29306        } else if (clr_eol) {
     29307-           SP->_cursrow = SP->_curscol = -1;
     29308+           SP_PARM->_cursrow = SP_PARM->_curscol = -1;
     29309 
     29310-           UpdateAttrs(blank);
     29311-           for (i = 0; i < screen_lines; i++) {
     29312-               GoTo(i, 0);
     29313+           UpdateAttrs(SP_PARM, blank);
     29314+           for (i = 0; i < screen_lines(SP_PARM); i++) {
     29315+               GoTo(NCURSES_SP_ARGx i, 0);
     29316                TPUTS_TRACE("clr_eol");
     29317-               putp(clr_eol);
     29318+               NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx clr_eol);
     29319            }
     29320-           GoTo(0, 0);
     29321+           GoTo(NCURSES_SP_ARGx 0, 0);
     29322        }
     29323     } else {
     29324-       UpdateAttrs(blank);
     29325-       for (i = 0; i < screen_lines; i++) {
     29326-           GoTo(i, 0);
     29327-           for (j = 0; j < screen_columns; j++)
     29328-               PutChar(CHREF(blank));
     29329-       }
     29330-       GoTo(0, 0);
     29331+       UpdateAttrs(SP_PARM, blank);
     29332+       for (i = 0; i < screen_lines(SP_PARM); i++) {
     29333+           GoTo(NCURSES_SP_ARGx i, 0);
     29334+           for (j = 0; j < screen_columns(SP_PARM); j++)
     29335+               PutChar(NCURSES_SP_ARGx CHREF(blank));
     29336+       }
     29337+       GoTo(NCURSES_SP_ARGx 0, 0);
     29338     }
     29339 
     29340-    for (i = 0; i < screen_lines; i++) {
     29341-       for (j = 0; j < screen_columns; j++)
     29342-           curscr->_line[i].text[j] = blank;
     29343+    for (i = 0; i < screen_lines(SP_PARM); i++) {
     29344+       for (j = 0; j < screen_columns(SP_PARM); j++)
     29345+           CurScreen(SP_PARM)->_line[i].text[j] = blank;
     29346     }
     29347 
     29348     TR(TRACE_UPDATE, ("screen cleared"));
     29349@@ -1492,49 +1620,52 @@
     29350 */
     29351 
     29352 static void
     29353-InsStr(NCURSES_CH_T * line, int count)
     29354+InsStr(NCURSES_SP_DCLx NCURSES_CH_T * line, int count)
     29355 {
     29356-    TR(TRACE_UPDATE, ("InsStr(%p,%d) called", line, count));
     29357+    TR(TRACE_UPDATE, ("InsStr(%p, %p,%d) called", SP_PARM, line, count));
     29358 
     29359     /* Prefer parm_ich as it has the smallest cost - no need to shift
     29360      * the whole line on each character. */
     29361     /* The order must match that of InsCharCost. */
     29362     if (parm_ich) {
     29363        TPUTS_TRACE("parm_ich");
     29364-       tputs(TPARM_1(parm_ich, count), count, _nc_outch);
     29365+       NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     29366+                               TPARM_1(parm_ich, count),
     29367+                               count,
     29368+                               NCURSES_SP_NAME(_nc_outch));
     29369        while (count) {
     29370-           PutAttrChar(CHREF(*line));
     29371+           PutAttrChar(NCURSES_SP_ARGx CHREF(*line));
     29372            line++;
     29373            count--;
     29374        }
     29375     } else if (enter_insert_mode && exit_insert_mode) {
     29376        TPUTS_TRACE("enter_insert_mode");
     29377-       putp(enter_insert_mode);
     29378+       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx enter_insert_mode);
     29379        while (count) {
     29380-           PutAttrChar(CHREF(*line));
     29381+           PutAttrChar(NCURSES_SP_ARGx CHREF(*line));
     29382            if (insert_padding) {
     29383                TPUTS_TRACE("insert_padding");
     29384-               putp(insert_padding);
     29385+               NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx insert_padding);
     29386            }
     29387            line++;
     29388            count--;
     29389        }
     29390        TPUTS_TRACE("exit_insert_mode");
     29391-       putp(exit_insert_mode);
     29392+       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx exit_insert_mode);
     29393     } else {
     29394        while (count) {
     29395            TPUTS_TRACE("insert_character");
     29396-           putp(insert_character);
     29397-           PutAttrChar(CHREF(*line));
     29398+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx insert_character);
     29399+           PutAttrChar(NCURSES_SP_ARGx CHREF(*line));
     29400            if (insert_padding) {
     29401                TPUTS_TRACE("insert_padding");
     29402-               putp(insert_padding);
     29403+               NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx insert_padding);
     29404            }
     29405            line++;
     29406            count--;
     29407        }
     29408     }
     29409-    position_check(SP->_cursrow, SP->_curscol, "InsStr");
     29410+    position_check(SP_PARM, SP_PARM->_cursrow, SP_PARM->_curscol, "InsStr");
     29411 }
     29412 
     29413 /*
     29414@@ -1545,22 +1676,25 @@
     29415 */
     29416 
     29417 static void
     29418-DelChar(int count)
     29419+DelChar(NCURSES_SP_DCLx int count)
     29420 {
     29421     int n;
     29422 
     29423-    TR(TRACE_UPDATE, ("DelChar(%d) called, position = (%ld,%ld)",
     29424-                     count,
     29425-                     (long) newscr->_cury,
     29426-                     (long) newscr->_curx));
     29427+    TR(TRACE_UPDATE, ("DelChar(%p, %d) called, position = (%ld,%ld)",
     29428+                     SP_PARM, count,
     29429+                     (long) NewScreen(SP_PARM)->_cury,
     29430+                     (long) NewScreen(SP_PARM)->_curx));
     29431 
     29432     if (parm_dch) {
     29433        TPUTS_TRACE("parm_dch");
     29434-       tputs(TPARM_1(parm_dch, count), count, _nc_outch);
     29435+       NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     29436+                               TPARM_1(parm_dch, count),
     29437+                               count,
     29438+                               NCURSES_SP_NAME(_nc_outch));
     29439     } else {
     29440        for (n = 0; n < count; n++) {
     29441            TPUTS_TRACE("delete_character");
     29442-           putp(delete_character);
     29443+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx delete_character);
     29444        }
     29445     }
     29446 }
     29447@@ -1599,54 +1733,66 @@
     29448 
     29449 /* Try to scroll up assuming given csr (miny, maxy). Returns ERR on failure */
     29450 static int
     29451-scroll_csr_forward(int n, int top, int bot, int miny, int maxy, NCURSES_CH_T blank)
     29452+scroll_csr_forward(NCURSES_SP_DCLx
     29453+                  int n,
     29454+                  int top,
     29455+                  int bot,
     29456+                  int miny,
     29457+                  int maxy,
     29458+                  NCURSES_CH_T blank)
     29459 {
     29460     int i;
     29461 
     29462     if (n == 1 && scroll_forward && top == miny && bot == maxy) {
     29463-       GoTo(bot, 0);
     29464-       UpdateAttrs(blank);
     29465+       GoTo(NCURSES_SP_ARGx bot, 0);
     29466+       UpdateAttrs(SP_PARM, blank);
     29467        TPUTS_TRACE("scroll_forward");
     29468-       putp(scroll_forward);
     29469+       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx scroll_forward);
     29470     } else if (n == 1 && delete_line && bot == maxy) {
     29471-       GoTo(top, 0);
     29472-       UpdateAttrs(blank);
     29473+       GoTo(NCURSES_SP_ARGx top, 0);
     29474+       UpdateAttrs(SP_PARM, blank);
     29475        TPUTS_TRACE("delete_line");
     29476-       putp(delete_line);
     29477+       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx delete_line);
     29478     } else if (parm_index && top == miny && bot == maxy) {
     29479-       GoTo(bot, 0);
     29480-       UpdateAttrs(blank);
     29481+       GoTo(NCURSES_SP_ARGx bot, 0);
     29482+       UpdateAttrs(SP_PARM, blank);
     29483        TPUTS_TRACE("parm_index");
     29484-       tputs(TPARM_2(parm_index, n, 0), n, _nc_outch);
     29485+       NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     29486+                               TPARM_2(parm_index, n, 0),
     29487+                               n,
     29488+                               NCURSES_SP_NAME(_nc_outch));
     29489     } else if (parm_delete_line && bot == maxy) {
     29490-       GoTo(top, 0);
     29491-       UpdateAttrs(blank);
     29492+       GoTo(NCURSES_SP_ARGx top, 0);
     29493+       UpdateAttrs(SP_PARM, blank);
     29494        TPUTS_TRACE("parm_delete_line");
     29495-       tputs(TPARM_2(parm_delete_line, n, 0), n, _nc_outch);
     29496+       NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     29497+                               TPARM_2(parm_delete_line, n, 0),
     29498+                               n,
     29499+                               NCURSES_SP_NAME(_nc_outch));
     29500     } else if (scroll_forward && top == miny && bot == maxy) {
     29501-       GoTo(bot, 0);
     29502-       UpdateAttrs(blank);
     29503+       GoTo(NCURSES_SP_ARGx bot, 0);
     29504+       UpdateAttrs(SP_PARM, blank);
     29505        for (i = 0; i < n; i++) {
     29506            TPUTS_TRACE("scroll_forward");
     29507-           putp(scroll_forward);
     29508+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx scroll_forward);
     29509        }
     29510     } else if (delete_line && bot == maxy) {
     29511-       GoTo(top, 0);
     29512-       UpdateAttrs(blank);
     29513+       GoTo(NCURSES_SP_ARGx top, 0);
     29514+       UpdateAttrs(SP_PARM, blank);
     29515        for (i = 0; i < n; i++) {
     29516            TPUTS_TRACE("delete_line");
     29517-           putp(delete_line);
     29518+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx delete_line);
     29519        }
     29520     } else
     29521        return ERR;
     29522 
     29523 #if NCURSES_EXT_FUNCS
     29524-    if (FILL_BCE()) {
     29525+    if (FILL_BCE(SP_PARM)) {
     29526        int j;
     29527        for (i = 0; i < n; i++) {
     29528-           GoTo(bot - i, 0);
     29529-           for (j = 0; j < screen_columns; j++)
     29530-               PutChar(CHREF(blank));
     29531+           GoTo(NCURSES_SP_ARGx bot - i, 0);
     29532+           for (j = 0; j < screen_columns(SP_PARM); j++)
     29533+               PutChar(NCURSES_SP_ARGx CHREF(blank));
     29534        }
     29535     }
     29536 #endif
     29537@@ -1656,55 +1802,66 @@
     29538 /* Try to scroll down assuming given csr (miny, maxy). Returns ERR on failure */
     29539 /* n > 0 */
     29540 static int
     29541-scroll_csr_backward(int n, int top, int bot, int miny, int maxy,
     29542+scroll_csr_backward(NCURSES_SP_DCLx
     29543+                   int n,
     29544+                   int top,
     29545+                   int bot,
     29546+                   int miny,
     29547+                   int maxy,
     29548                    NCURSES_CH_T blank)
     29549 {
     29550     int i;
     29551 
     29552     if (n == 1 && scroll_reverse && top == miny && bot == maxy) {
     29553-       GoTo(top, 0);
     29554-       UpdateAttrs(blank);
     29555+       GoTo(NCURSES_SP_ARGx top, 0);
     29556+       UpdateAttrs(SP_PARM, blank);
     29557        TPUTS_TRACE("scroll_reverse");
     29558-       putp(scroll_reverse);
     29559+       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx scroll_reverse);
     29560     } else if (n == 1 && insert_line && bot == maxy) {
     29561-       GoTo(top, 0);
     29562-       UpdateAttrs(blank);
     29563+       GoTo(NCURSES_SP_ARGx top, 0);
     29564+       UpdateAttrs(SP_PARM, blank);
     29565        TPUTS_TRACE("insert_line");
     29566-       putp(insert_line);
     29567+       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx insert_line);
     29568     } else if (parm_rindex && top == miny && bot == maxy) {
     29569-       GoTo(top, 0);
     29570-       UpdateAttrs(blank);
     29571+       GoTo(NCURSES_SP_ARGx top, 0);
     29572+       UpdateAttrs(SP_PARM, blank);
     29573        TPUTS_TRACE("parm_rindex");
     29574-       tputs(TPARM_2(parm_rindex, n, 0), n, _nc_outch);
     29575+       NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     29576+                               TPARM_2(parm_rindex, n, 0),
     29577+                               n,
     29578+                               NCURSES_SP_NAME(_nc_outch));
     29579     } else if (parm_insert_line && bot == maxy) {
     29580-       GoTo(top, 0);
     29581-       UpdateAttrs(blank);
     29582+       GoTo(NCURSES_SP_ARGx top, 0);
     29583+       UpdateAttrs(SP_PARM, blank);
     29584        TPUTS_TRACE("parm_insert_line");
     29585-       tputs(TPARM_2(parm_insert_line, n, 0), n, _nc_outch);
     29586+       NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     29587+                               TPARM_2(parm_insert_line, n, 0),
     29588+                               n,
     29589+                               NCURSES_SP_NAME(_nc_outch));
     29590     } else if (scroll_reverse && top == miny && bot == maxy) {
     29591-       GoTo(top, 0);
     29592-       UpdateAttrs(blank);
     29593+       GoTo(NCURSES_SP_ARGx top, 0);
     29594+       UpdateAttrs(SP_PARM, blank);
     29595        for (i = 0; i < n; i++) {
     29596            TPUTS_TRACE("scroll_reverse");
     29597-           putp(scroll_reverse);
     29598+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx scroll_reverse);
     29599        }
     29600     } else if (insert_line && bot == maxy) {
     29601-       GoTo(top, 0);
     29602-       UpdateAttrs(blank);
     29603+       GoTo(NCURSES_SP_ARGx top, 0);
     29604+       UpdateAttrs(SP_PARM, blank);
     29605        for (i = 0; i < n; i++) {
     29606            TPUTS_TRACE("insert_line");
     29607-           putp(insert_line);
     29608+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx insert_line);
     29609        }
     29610     } else
     29611        return ERR;
     29612 
     29613 #if NCURSES_EXT_FUNCS
     29614-    if (FILL_BCE()) {
     29615+    if (FILL_BCE(SP_PARM)) {
     29616        int j;
     29617        for (i = 0; i < n; i++) {
     29618-           GoTo(top + i, 0);
     29619-           for (j = 0; j < screen_columns; j++)
     29620-               PutChar(CHREF(blank));
     29621+           GoTo(NCURSES_SP_ARGx top + i, 0);
     29622+           for (j = 0; j < screen_columns(SP_PARM); j++)
     29623+               PutChar(NCURSES_SP_ARGx CHREF(blank));
     29624        }
     29625     }
     29626 #endif
     29627@@ -1714,40 +1871,46 @@
     29628 /* scroll by using delete_line at del and insert_line at ins */
     29629 /* n > 0 */
     29630 static int
     29631-scroll_idl(int n, int del, int ins, NCURSES_CH_T blank)
     29632+scroll_idl(NCURSES_SP_DCLx int n, int del, int ins, NCURSES_CH_T blank)
     29633 {
     29634     int i;
     29635 
     29636     if (!((parm_delete_line || delete_line) && (parm_insert_line || insert_line)))
     29637        return ERR;
     29638 
     29639-    GoTo(del, 0);
     29640-    UpdateAttrs(blank);
     29641+    GoTo(NCURSES_SP_ARGx del, 0);
     29642+    UpdateAttrs(SP_PARM, blank);
     29643     if (n == 1 && delete_line) {
     29644        TPUTS_TRACE("delete_line");
     29645-       putp(delete_line);
     29646+       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx delete_line);
     29647     } else if (parm_delete_line) {
     29648        TPUTS_TRACE("parm_delete_line");
     29649-       tputs(TPARM_2(parm_delete_line, n, 0), n, _nc_outch);
     29650+       NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     29651+                               TPARM_2(parm_delete_line, n, 0),
     29652+                               n,
     29653+                               NCURSES_SP_NAME(_nc_outch));
     29654     } else {                   /* if (delete_line) */
     29655        for (i = 0; i < n; i++) {
     29656            TPUTS_TRACE("delete_line");
     29657-           putp(delete_line);
     29658+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx delete_line);
     29659        }
     29660     }
     29661 
     29662-    GoTo(ins, 0);
     29663-    UpdateAttrs(blank);
     29664+    GoTo(NCURSES_SP_ARGx ins, 0);
     29665+    UpdateAttrs(SP_PARM, blank);
     29666     if (n == 1 && insert_line) {
     29667        TPUTS_TRACE("insert_line");
     29668-       putp(insert_line);
     29669+       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx insert_line);
     29670     } else if (parm_insert_line) {
     29671        TPUTS_TRACE("parm_insert_line");
     29672-       tputs(TPARM_2(parm_insert_line, n, 0), n, _nc_outch);
     29673+       NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     29674+                               TPARM_2(parm_insert_line, n, 0),
     29675+                               n,
     29676+                               NCURSES_SP_NAME(_nc_outch));
     29677     } else {                   /* if (insert_line) */
     29678        for (i = 0; i < n; i++) {
     29679            TPUTS_TRACE("insert_line");
     29680-           putp(insert_line);
     29681+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx insert_line);
     29682        }
     29683     }
     29684 
     29685@@ -1763,10 +1926,14 @@
     29686  * save/restore cursor capabilities if the terminal has them.
     29687  */
     29688 NCURSES_EXPORT(int)
     29689-_nc_scrolln(int n, int top, int bot, int maxy)
     29690+NCURSES_SP_NAME(_nc_scrolln) (NCURSES_SP_DCLx
     29691+                             int n,
     29692+                             int top,
     29693+                             int bot,
     29694+                             int maxy)
     29695 /* scroll region from top to bot by n lines */
     29696 {
     29697-    NCURSES_CH_T blank = ClrBlank(stdscr);
     29698+    NCURSES_CH_T blank = ClrBlank(NCURSES_SP_ARGx StdScreen(SP_PARM));
     29699     int i;
     29700     bool cursor_saved = FALSE;
     29701     int res;
     29702@@ -1787,34 +1954,36 @@
     29703         * Explicitly clear if stuff pushed off top of region might
     29704         * be saved by the terminal.
     29705         */
     29706-       res = scroll_csr_forward(n, top, bot, 0, maxy, blank);
     29707+       res = scroll_csr_forward(NCURSES_SP_ARGx n, top, bot, 0, maxy, blank);
     29708 
     29709        if (res == ERR && change_scroll_region) {
     29710            if ((((n == 1 && scroll_forward) || parm_index)
     29711-                && (SP->_cursrow == bot || SP->_cursrow == bot - 1))
     29712+                && (SP_PARM->_cursrow == bot || SP_PARM->_cursrow == bot - 1))
     29713                && save_cursor && restore_cursor) {
     29714                cursor_saved = TRUE;
     29715                TPUTS_TRACE("save_cursor");
     29716-               putp(save_cursor);
     29717+               NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx save_cursor);
     29718            }
     29719            TPUTS_TRACE("change_scroll_region");
     29720-           putp(TPARM_2(change_scroll_region, top, bot));
     29721+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx
     29722+                                  TPARM_2(change_scroll_region, top, bot));
     29723            if (cursor_saved) {
     29724                TPUTS_TRACE("restore_cursor");
     29725-               putp(restore_cursor);
     29726+               NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx restore_cursor);
     29727            } else {
     29728-               SP->_cursrow = SP->_curscol = -1;
     29729+               SP_PARM->_cursrow = SP_PARM->_curscol = -1;
     29730            }
     29731 
     29732-           res = scroll_csr_forward(n, top, bot, top, bot, blank);
     29733+           res = scroll_csr_forward(NCURSES_SP_ARGx n, top, bot, top, bot, blank);
     29734 
     29735            TPUTS_TRACE("change_scroll_region");
     29736-           putp(TPARM_2(change_scroll_region, 0, maxy));
     29737-           SP->_cursrow = SP->_curscol = -1;
     29738+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx
     29739+                                  TPARM_2(change_scroll_region, 0, maxy));
     29740+           SP_PARM->_cursrow = SP_PARM->_curscol = -1;
     29741        }
     29742 
     29743        if (res == ERR && _nc_idlok)
     29744-           res = scroll_idl(n, top, bot - n + 1, blank);
     29745+           res = scroll_idl(NCURSES_SP_ARGx n, top, bot - n + 1, blank);
     29746 
     29747        /*
     29748         * Clear the newly shifted-in text.
     29749@@ -1823,44 +1992,49 @@
     29750            && (non_dest_scroll_region || (memory_below && bot == maxy))) {
     29751            static const NCURSES_CH_T blank2 = NewChar(BLANK_TEXT);
     29752            if (bot == maxy && clr_eos) {
     29753-               GoTo(bot - n + 1, 0);
     29754-               ClrToEOS(blank2);
     29755+               GoTo(NCURSES_SP_ARGx bot - n + 1, 0);
     29756+               ClrToEOS(NCURSES_SP_ARGx blank2);
     29757            } else {
     29758                for (i = 0; i < n; i++) {
     29759-                   GoTo(bot - i, 0);
     29760-                   ClrToEOL(blank2, FALSE);
     29761+                   GoTo(NCURSES_SP_ARGx bot - i, 0);
     29762+                   ClrToEOL(NCURSES_SP_ARGx blank2, FALSE);
     29763                }
     29764            }
     29765        }
     29766 
     29767     } else {                   /* (n < 0) - scroll down (backward) */
     29768-       res = scroll_csr_backward(-n, top, bot, 0, maxy, blank);
     29769+       res = scroll_csr_backward(NCURSES_SP_ARGx -n, top, bot, 0, maxy, blank);
     29770 
     29771        if (res == ERR && change_scroll_region) {
     29772-           if (top != 0 && (SP->_cursrow == top || SP->_cursrow == top - 1)
     29773+           if (top != 0
     29774+               && (SP_PARM->_cursrow == top ||
     29775+                   SP_PARM->_cursrow == top - 1)
     29776                && save_cursor && restore_cursor) {
     29777                cursor_saved = TRUE;
     29778                TPUTS_TRACE("save_cursor");
     29779-               putp(save_cursor);
     29780+               NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx save_cursor);
     29781            }
     29782            TPUTS_TRACE("change_scroll_region");
     29783-           putp(TPARM_2(change_scroll_region, top, bot));
     29784+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx
     29785+                                  TPARM_2(change_scroll_region, top, bot));
     29786            if (cursor_saved) {
     29787                TPUTS_TRACE("restore_cursor");
     29788-               putp(restore_cursor);
     29789+               NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx restore_cursor);
     29790            } else {
     29791-               SP->_cursrow = SP->_curscol = -1;
     29792+               SP_PARM->_cursrow = SP_PARM->_curscol = -1;
     29793            }
     29794 
     29795-           res = scroll_csr_backward(-n, top, bot, top, bot, blank);
     29796+           res = scroll_csr_backward(NCURSES_SP_ARGx
     29797+                                     -n, top, bot, top, bot, blank);
     29798 
     29799            TPUTS_TRACE("change_scroll_region");
     29800-           putp(TPARM_2(change_scroll_region, 0, maxy));
     29801-           SP->_cursrow = SP->_curscol = -1;
     29802+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx
     29803+                                  TPARM_2(change_scroll_region, 0, maxy));
     29804+           SP_PARM->_cursrow = SP_PARM->_curscol = -1;
     29805        }
     29806 
     29807        if (res == ERR && _nc_idlok)
     29808-           res = scroll_idl(-n, bot + n + 1, top, blank);
     29809+           res = scroll_idl(NCURSES_SP_ARGx -n, bot + n + 1, top, blank);
     29810 
     29811        /*
     29812         * Clear the newly shifted-in text.
     29813@@ -1869,8 +2043,8 @@
     29814            && (non_dest_scroll_region || (memory_above && top == 0))) {
     29815            static const NCURSES_CH_T blank2 = NewChar(BLANK_TEXT);
     29816            for (i = 0; i < -n; i++) {
     29817-               GoTo(i + top, 0);
     29818-               ClrToEOL(blank2, FALSE);
     29819+               GoTo(NCURSES_SP_ARGx i + top, 0);
     29820+               ClrToEOL(NCURSES_SP_ARGx blank2, FALSE);
     29821            }
     29822        }
     29823     }
     29824@@ -1878,99 +2052,156 @@
     29825     if (res == ERR)
     29826        return (ERR);
     29827 
     29828-    _nc_scroll_window(curscr, n, top, bot, blank);
     29829+    _nc_scroll_window(CurScreen(SP_PARM), n, top, bot, blank);
     29830 
     29831     /* shift hash values too - they can be reused */
     29832-    _nc_scroll_oldhash(n, top, bot);
     29833+    NCURSES_SP_NAME(_nc_scroll_oldhash) (NCURSES_SP_ARGx n, top, bot);
     29834 
     29835     return (OK);
     29836 }
     29837 
     29838+#if NCURSES_SP_FUNCS
     29839+NCURSES_EXPORT(int)
     29840+_nc_scrolln(int n, int top, int bot, int maxy)
     29841+{
     29842+    return NCURSES_SP_NAME(_nc_scrolln) (CURRENT_SCREEN, n, top, bot, maxy);
     29843+}
     29844+#endif
     29845+
     29846 NCURSES_EXPORT(void)
     29847-_nc_screen_resume(void)
     29848+NCURSES_SP_NAME(_nc_screen_resume) (NCURSES_SP_DCL0)
     29849 {
     29850+    assert(SP_PARM);
     29851+
     29852     /* make sure terminal is in a sane known state */
     29853-    SetAttr(SCREEN_ATTRS(SP), A_NORMAL);
     29854-    newscr->_clear = TRUE;
     29855+    SetAttr(SCREEN_ATTRS(SP_PARM), A_NORMAL);
     29856+    NewScreen(SP_PARM)->_clear = TRUE;
     29857 
     29858     /* reset color pairs and definitions */
     29859-    if (SP->_coloron || SP->_color_defs)
     29860+    if (SP_PARM->_coloron || SP_PARM->_color_defs)
     29861        _nc_reset_colors();
     29862 
     29863     /* restore user-defined colors, if any */
     29864-    if (SP->_color_defs < 0) {
     29865+    if (SP_PARM->_color_defs < 0) {
     29866        int n;
     29867-       SP->_color_defs = -(SP->_color_defs);
     29868-       for (n = 0; n < SP->_color_defs; ++n) {
     29869-           if (SP->_color_table[n].init) {
     29870-               init_color(n,
     29871-                          SP->_color_table[n].r,
     29872-                          SP->_color_table[n].g,
     29873-                          SP->_color_table[n].b);
     29874+       SP_PARM->_color_defs = -(SP_PARM->_color_defs);
     29875+       for (n = 0; n < SP_PARM->_color_defs; ++n) {
     29876+           if (SP_PARM->_color_table[n].init) {
     29877+               NCURSES_SP_NAME(init_color) (NCURSES_SP_ARGx n,
     29878+                                            SP_PARM->_color_table[n].r,
     29879+                                            SP_PARM->_color_table[n].g,
     29880+                                            SP_PARM->_color_table[n].b);
     29881            }
     29882        }
     29883     }
     29884 
     29885     if (exit_attribute_mode)
     29886-       putp(exit_attribute_mode);
     29887+       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx exit_attribute_mode);
     29888     else {
     29889        /* turn off attributes */
     29890        if (exit_alt_charset_mode)
     29891-           putp(exit_alt_charset_mode);
     29892+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx exit_alt_charset_mode);
     29893        if (exit_standout_mode)
     29894-           putp(exit_standout_mode);
     29895+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx exit_standout_mode);
     29896        if (exit_underline_mode)
     29897-           putp(exit_underline_mode);
     29898+           NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx exit_underline_mode);
     29899     }
     29900     if (exit_insert_mode)
     29901-       putp(exit_insert_mode);
     29902+       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx exit_insert_mode);
     29903     if (enter_am_mode && exit_am_mode)
     29904-       putp(auto_right_margin ? enter_am_mode : exit_am_mode);
     29905+       NCURSES_SP_NAME(putp) (NCURSES_SP_ARGx
     29906+                              (auto_right_margin
     29907+                               ? enter_am_mode
     29908+                               : exit_am_mode));
     29909 }
     29910 
     29911+#if NCURSES_SP_FUNCS
     29912+NCURSES_EXPORT(void)
     29913+_nc_screen_resume(void)
     29914+{
     29915+    NCURSES_SP_NAME(_nc_screen_resume) (CURRENT_SCREEN);
     29916+}
     29917+#endif
     29918+
     29919+NCURSES_EXPORT(void)
     29920+NCURSES_SP_NAME(_nc_screen_init) (NCURSES_SP_DCL0)
     29921+{
     29922+    NCURSES_SP_NAME(_nc_screen_resume) (NCURSES_SP_ARG);
     29923+}
     29924+
     29925+#if NCURSES_SP_FUNCS
     29926 NCURSES_EXPORT(void)
     29927 _nc_screen_init(void)
     29928 {
     29929-    _nc_screen_resume();
     29930+    NCURSES_SP_NAME(_nc_screen_init) (CURRENT_SCREEN);
     29931 }
     29932+#endif
     29933 
     29934 /* wrap up screen handling */
     29935 NCURSES_EXPORT(void)
     29936-_nc_screen_wrap(void)
     29937+NCURSES_SP_NAME(_nc_screen_wrap) (NCURSES_SP_DCL0)
     29938 {
     29939-    UpdateAttrs(normal);
     29940+    if (SP_PARM == 0)
     29941+       return;
     29942+
     29943+    UpdateAttrs(SP_PARM, normal);
     29944 #if NCURSES_EXT_FUNCS
     29945-    if (SP->_coloron
     29946-       && !SP->_default_color) {
     29947+    if (SP_PARM->_coloron
     29948+       && !SP_PARM->_default_color) {
     29949        static const NCURSES_CH_T blank = NewChar(BLANK_TEXT);
     29950-       SP->_default_color = TRUE;
     29951-       _nc_do_color(-1, 0, FALSE, _nc_outch);
     29952-       SP->_default_color = FALSE;
     29953+       SP_PARM->_default_color = TRUE;
     29954+       NCURSES_SP_NAME(_nc_do_color) (NCURSES_SP_ARGx
     29955+                                      -1, 0,
     29956+                                      FALSE,
     29957+                                      NCURSES_SP_NAME(_nc_outch));
     29958+       SP_PARM->_default_color = FALSE;
     29959 
     29960-       mvcur(SP->_cursrow, SP->_curscol, screen_lines - 1, 0);
     29961+       mvcur(SP_PARM->_cursrow,
     29962+             SP_PARM->_curscol,
     29963+             screen_lines(SP_PARM) - 1, 0);
     29964 
     29965-       ClrToEOL(blank, TRUE);
     29966+       ClrToEOL(NCURSES_SP_ARGx blank, TRUE);
     29967     }
     29968 #endif
     29969-    if (SP->_color_defs) {
     29970+    if (SP_PARM->_color_defs) {
     29971        _nc_reset_colors();
     29972     }
     29973 }
     29974 
     29975+#if NCURSES_SP_FUNCS
     29976+NCURSES_EXPORT(void)
     29977+_nc_screen_wrap(void)
     29978+{
     29979+    NCURSES_SP_NAME(_nc_screen_wrap) (CURRENT_SCREEN);
     29980+}
     29981+#endif
     29982+
     29983 #if USE_XMC_SUPPORT
     29984 NCURSES_EXPORT(void)
     29985-_nc_do_xmc_glitch(attr_t previous)
     29986+NCURSES_SP_NAME(_nc_do_xmc_glitch) (NCURSES_SP_DCLx attr_t previous)
     29987 {
     29988-    attr_t chg = XMC_CHANGES(previous ^ AttrOf(SCREEN_ATTRS(SP)));
     29989+    if (SP_PARM != 0) {
     29990+       attr_t chg = XMC_CHANGES(previous ^ AttrOf(SCREEN_ATTRS(SP_PARM)));
     29991 
     29992-    while (chg != 0) {
     29993-       if (chg & 1) {
     29994-           SP->_curscol += magic_cookie_glitch;
     29995-           if (SP->_curscol >= SP->_columns)
     29996-               wrap_cursor();
     29997-           TR(TRACE_UPDATE, ("bumped to %d,%d after cookie", SP->_cursrow, SP->_curscol));
     29998+       while (chg != 0) {
     29999+           if (chg & 1) {
     30000+               SP_PARM->_curscol += magic_cookie_glitch;
     30001+               if (SP_PARM->_curscol >= SP_PARM->_columns)
     30002+                   wrap_cursor(NCURSES_SP_ARG);
     30003+               TR(TRACE_UPDATE, ("bumped to %d,%d after cookie",
     30004+                                 SP_PARM->_cursrow, SP_PARM->_curscol));
     30005+           }
     30006+           chg >>= 1;
     30007        }
     30008-       chg >>= 1;
     30009     }
     30010 }
     30011+
     30012+#if NCURSES_SP_FUNCS
     30013+NCURSES_EXPORT(void)
     30014+_nc_do_xmc_glitch(attr_t previous)
     30015+{
     30016+    NCURSES_SP_NAME(_nc_do_xmc_glitch) (CURRENT_SCREEN, previous);
     30017+}
     30018+#endif
     30019+
     30020 #endif /* USE_XMC_SUPPORT */
    2019630021diff -Naur ncurses-5.7.orig/ncurses/widechar/lib_cchar.c ncurses-5.7/ncurses/widechar/lib_cchar.c
    2019730022--- ncurses-5.7.orig/ncurses/widechar/lib_cchar.c       2007-05-12 12:03:06.000000000 -0700
    20198 +++ ncurses-5.7/ncurses/widechar/lib_cchar.c    2009-02-28 20:38:58.443328118 -0800
     30023+++ ncurses-5.7/ncurses/widechar/lib_cchar.c    2009-06-05 14:01:16.000000000 -0700
    2019930024@@ -1,5 +1,5 @@
    2020030025 /****************************************************************************
     
    2022430049 
    2022530050     TR(TRACE_CCALLS, (T_CALLED("setcchar(%p,%s,%lu,%d,%p)"),
     30051diff -Naur ncurses-5.7.orig/ncurses/widechar/lib_get_wch.c ncurses-5.7/ncurses/widechar/lib_get_wch.c
     30052--- ncurses-5.7.orig/ncurses/widechar/lib_get_wch.c     2008-08-16 12:22:55.000000000 -0700
     30053+++ ncurses-5.7/ncurses/widechar/lib_get_wch.c  2009-06-05 14:01:44.000000000 -0700
     30054@@ -1,5 +1,5 @@
     30055 /****************************************************************************
     30056- * Copyright (c) 2002-2007,2008 Free Software Foundation, Inc.              *
     30057+ * Copyright (c) 2002-2008,2009 Free Software Foundation, Inc.              *
     30058  *                                                                          *
     30059  * Permission is hereby granted, free of charge, to any person obtaining a  *
     30060  * copy of this software and associated documentation files (the            *
     30061@@ -40,7 +40,7 @@
     30062 #include <curses.priv.h>
     30063 #include <ctype.h>
     30064 
     30065-MODULE_ID("$Id: lib_get_wch.c,v 1.17 2008/08/16 19:22:55 tom Exp $")
     30066+MODULE_ID("$Id: lib_get_wch.c,v 1.18 2009/04/18 22:41:33 tom Exp $")
     30067 
     30068 #if HAVE_MBTOWC && HAVE_MBLEN
     30069 #define reset_mbytes(state) mblen(NULL, 0), mbtowc(NULL, NULL, 0)
     30070@@ -95,12 +95,12 @@
     30071                 * whether the improvement would be worth the effort.
     30072                 */
     30073                if (count != 0) {
     30074-                   _nc_ungetch(sp, (int) value);
     30075+                   safe_ungetch (SP_PARM, (int) value);
     30076                    code = ERR;
     30077                }
     30078                break;
     30079            } else if (count + 1 >= sizeof(buffer)) {
     30080-               _nc_ungetch(sp, (int) value);
     30081+               safe_ungetch (SP_PARM, (int) value);
     30082                code = ERR;
     30083                break;
     30084            } else {
     30085@@ -111,7 +111,7 @@
     30086                    reset_mbytes(state);
     30087                    if (check_mbytes(wch, buffer, count, state) != status) {
     30088                        code = ERR;     /* the two calls should match */
     30089-                       _nc_ungetch(sp, (int) value);
     30090+                       safe_ungetch (SP_PARM, (int) value);
     30091                    }
     30092                    value = wch;
     30093                    break;
    2022630094diff -Naur ncurses-5.7.orig/ncurses/widechar/lib_get_wstr.c ncurses-5.7/ncurses/widechar/lib_get_wstr.c
    2022730095--- ncurses-5.7.orig/ncurses/widechar/lib_get_wstr.c    2008-08-16 12:25:33.000000000 -0700
    20228 +++ ncurses-5.7/ncurses/widechar/lib_get_wstr.c 2009-02-28 20:38:58.443328118 -0800
     30096+++ ncurses-5.7/ncurses/widechar/lib_get_wstr.c 2009-06-05 14:01:16.000000000 -0700
    2022930097@@ -38,9 +38,8 @@
    2023030098 */
     
    2023830106 static int
    2023930107 wadd_wint(WINDOW *win, wint_t *src)
     30108diff -Naur ncurses-5.7.orig/ncurses/widechar/lib_ins_wch.c ncurses-5.7/ncurses/widechar/lib_ins_wch.c
     30109--- ncurses-5.7.orig/ncurses/widechar/lib_ins_wch.c     2005-12-03 12:24:19.000000000 -0800
     30110+++ ncurses-5.7/ncurses/widechar/lib_ins_wch.c  2009-06-05 14:01:55.000000000 -0700
     30111@@ -1,5 +1,5 @@
     30112 /****************************************************************************
     30113- * Copyright (c) 2002-2003,2005 Free Software Foundation, Inc.              *
     30114+ * Copyright (c) 2002-2005,2009 Free Software Foundation, Inc.              *
     30115  *                                                                          *
     30116  * Permission is hereby granted, free of charge, to any person obtaining a  *
     30117  * copy of this software and associated documentation files (the            *
     30118@@ -39,7 +39,7 @@
     30119 
     30120 #include <curses.priv.h>
     30121 
     30122-MODULE_ID("$Id: lib_ins_wch.c,v 1.8 2005/12/03 20:24:19 tom Exp $")
     30123+MODULE_ID("$Id: lib_ins_wch.c,v 1.9 2009/05/30 14:52:42 tom Exp $")
     30124 
     30125 /*
     30126  * Insert the given character, updating the current location to simplify
     30127@@ -112,6 +112,8 @@
     30128            n = wcslen(wstr);
     30129        code = OK;
     30130        if (n > 0) {
     30131+           SCREEN *sp = _nc_screen_of(win);
     30132+
     30133            oy = win->_cury;
     30134            ox = win->_curx;
     30135            for (cp = wstr; *cp && ((cp - wstr) < n); cp++) {
     30136@@ -129,7 +131,7 @@
     30137                    code = _nc_insert_wch(win, &tmp_cchar);
     30138                } else {
     30139                    /* tabs, other ASCII stuff */
     30140-                   code = _nc_insert_ch(win, (chtype) (*cp));
     30141+                   code = _nc_insert_ch(sp, win, (chtype) (*cp));
     30142                }
     30143                if (code != OK)
     30144                    break;
     30145diff -Naur ncurses-5.7.orig/ncurses/widechar/lib_unget_wch.c ncurses-5.7/ncurses/widechar/lib_unget_wch.c
     30146--- ncurses-5.7.orig/ncurses/widechar/lib_unget_wch.c   2008-06-07 07:50:37.000000000 -0700
     30147+++ ncurses-5.7/ncurses/widechar/lib_unget_wch.c        2009-06-05 14:01:44.000000000 -0700
     30148@@ -1,5 +1,5 @@
     30149 /****************************************************************************
     30150- * Copyright (c) 2002-2007,2008 Free Software Foundation, Inc.              *
     30151+ * Copyright (c) 2002-2008,2009 Free Software Foundation, Inc.              *
     30152  *                                                                          *
     30153  * Permission is hereby granted, free of charge, to any person obtaining a  *
     30154  * copy of this software and associated documentation files (the            *
     30155@@ -39,7 +39,7 @@
     30156 
     30157 #include <curses.priv.h>
     30158 
     30159-MODULE_ID("$Id: lib_unget_wch.c,v 1.10 2008/06/07 14:50:37 tom Exp $")
     30160+MODULE_ID("$Id: lib_unget_wch.c,v 1.11 2009/04/04 23:57:25 tom Exp $")
     30161 
     30162 /*
     30163  * Wrapper for wcrtomb() which obtains the length needed for the given
     30164@@ -65,14 +65,14 @@
     30165 }
     30166 
     30167 NCURSES_EXPORT(int)
     30168-unget_wch(const wchar_t wch)
     30169+NCURSES_SP_NAME(unget_wch) (NCURSES_SP_DCLx const wchar_t wch)
     30170 {
     30171     int result = OK;
     30172     mbstate_t state;
     30173     size_t length;
     30174     int n;
     30175 
     30176-    T((T_CALLED("unget_wch(%#lx)"), (unsigned long) wch));
     30177+    T((T_CALLED("unget_wch(%p, %#lx)"), SP_PARM, (unsigned long) wch));
     30178 
     30179     init_mb(state);
     30180     length = _nc_wcrtomb(0, wch, &state);
     30181@@ -86,7 +86,7 @@
     30182            wcrtomb(string, wch, &state);
     30183 
     30184            for (n = (int) (length - 1); n >= 0; --n) {
     30185-               if (_nc_ungetch(SP, string[n]) != OK) {
     30186+               if (NCURSES_SP_NAME(ungetch) (NCURSES_SP_ARGx string[n]) != OK) {
     30187                    result = ERR;
     30188                    break;
     30189                }
     30190@@ -101,3 +101,11 @@
     30191 
     30192     returnCode(result);
     30193 }
     30194+
     30195+#if NCURSES_SP_FUNCS
     30196+NCURSES_EXPORT(int)
     30197+unget_wch(const wchar_t wch)
     30198+{
     30199+    return NCURSES_SP_NAME(unget_wch) (CURRENT_SCREEN, wch);
     30200+}
     30201+#endif
     30202diff -Naur ncurses-5.7.orig/ncurses/widechar/lib_vid_attr.c ncurses-5.7/ncurses/widechar/lib_vid_attr.c
     30203--- ncurses-5.7.orig/ncurses/widechar/lib_vid_attr.c    2007-06-30 15:03:02.000000000 -0700
     30204+++ ncurses-5.7/ncurses/widechar/lib_vid_attr.c 2009-06-05 14:01:51.000000000 -0700
     30205@@ -1,5 +1,5 @@
     30206 /****************************************************************************
     30207- * Copyright (c) 2002-2006,2007 Free Software Foundation, Inc.              *
     30208+ * Copyright (c) 2002-2007,2009 Free Software Foundation, Inc.              *
     30209  *                                                                          *
     30210  * Permission is hereby granted, free of charge, to any person obtaining a  *
     30211  * copy of this software and associated documentation files (the            *
     30212@@ -33,9 +33,13 @@
     30213 #include <curses.priv.h>
     30214 #include <term.h>
     30215 
     30216-MODULE_ID("$Id: lib_vid_attr.c,v 1.5 2007/06/30 22:03:02 tom Exp $")
     30217+#ifndef CUR
     30218+#define CUR SP_TERMTYPE
     30219+#endif
     30220+
     30221+MODULE_ID("$Id: lib_vid_attr.c,v 1.11 2009/05/10 00:48:29 tom Exp $")
     30222 
     30223-#define doPut(mode) TPUTS_TRACE(#mode); tputs(mode, 1, outc)
     30224+#define doPut(mode) TPUTS_TRACE(#mode); NCURSES_SP_NAME(tputs)(NCURSES_SP_ARGx mode, 1, outc)
     30225 
     30226 #define TurnOn(mask,mode) \
     30227        if ((turn_on & mask) && mode) { doPut(mode); }
     30228@@ -50,14 +54,20 @@
     30229                if ((pair != old_pair) \
     30230                 || (fix_pair0 && (pair == 0)) \
     30231                 || (reverse ^ ((old_attr & A_REVERSE) != 0))) { \
     30232-                       _nc_do_color(old_pair, pair, reverse, outc); \
     30233+                   NCURSES_SP_NAME(_nc_do_color) (NCURSES_SP_ARGx \
     30234+                                                  old_pair, pair, \
     30235+                                                  reverse, outc); \
     30236                } \
     30237        }
     30238 
     30239 #define set_color(mode, pair) mode &= ALL_BUT_COLOR; mode |= COLOR_PAIR(pair)
     30240 
     30241 NCURSES_EXPORT(int)
     30242-vid_puts(attr_t newmode, short pair, void *opts GCC_UNUSED, int (*outc) (int))
     30243+NCURSES_SP_NAME(vid_puts) (NCURSES_SP_DCLx
     30244+                          attr_t newmode,
     30245+                          short pair,
     30246+                          void *opts GCC_UNUSED,
     30247+                          NCURSES_SP_OUTC outc)
     30248 {
     30249 #if NCURSES_EXT_COLORS
     30250     static attr_t previous_attr = A_NORMAL;
     30251@@ -65,9 +75,9 @@
     30252 
     30253     attr_t turn_on, turn_off;
     30254     bool reverse = FALSE;
     30255-    bool can_color = (SP == 0 || SP->_coloron);
     30256+    bool can_color = (SP_PARM == 0 || SP_PARM->_coloron);
     30257 #if NCURSES_EXT_FUNCS
     30258-    bool fix_pair0 = (SP != 0 && SP->_coloron && !SP->_default_color);
     30259+    bool fix_pair0 = (SP_PARM != 0 && SP_PARM->_coloron && !SP_PARM->_default_color);
     30260 #else
     30261 #define fix_pair0 FALSE
     30262 #endif
     30263@@ -76,18 +86,18 @@
     30264     T((T_CALLED("vid_puts(%s,%d)"), _traceattr(newmode), pair));
     30265 
     30266     /* this allows us to go on whether or not newterm() has been called */
     30267-    if (SP) {
     30268-       previous_attr = AttrOf(SCREEN_ATTRS(SP));
     30269-       previous_pair = GetPair(SCREEN_ATTRS(SP));
     30270+    if (SP_PARM) {
     30271+       previous_attr = AttrOf(SCREEN_ATTRS(SP_PARM));
     30272+       previous_pair = GetPair(SCREEN_ATTRS(SP_PARM));
     30273     }
     30274 
     30275     TR(TRACE_ATTRS, ("previous attribute was %s, %d",
     30276                     _traceattr(previous_attr), previous_pair));
     30277 
     30278 #if !USE_XMC_SUPPORT
     30279-    if ((SP != 0)
     30280+    if ((SP_PARM != 0)
     30281        && (magic_cookie_glitch > 0))
     30282-       newmode &= ~(SP->_xmc_suppress);
     30283+       newmode &= ~(SP_PARM->_xmc_suppress);
     30284 #endif
     30285 
     30286     /*
     30287@@ -144,10 +154,10 @@
     30288            if (exit_attribute_mode) {
     30289                doPut(exit_attribute_mode);
     30290            } else {
     30291-               if (!SP || SP->_use_rmul) {
     30292+               if (!SP_PARM || SP_PARM->_use_rmul) {
     30293                    TurnOff(A_UNDERLINE, exit_underline_mode);
     30294                }
     30295-               if (!SP || SP->_use_rmso) {
     30296+               if (!SP_PARM || SP_PARM->_use_rmso) {
     30297                    TurnOff(A_STANDOUT, exit_standout_mode);
     30298                }
     30299            }
     30300@@ -159,16 +169,18 @@
     30301     } else if (set_attributes) {
     30302        if (turn_on || turn_off) {
     30303            TPUTS_TRACE("set_attributes");
     30304-           tputs(TPARM_9(set_attributes,
     30305-                         (newmode & A_STANDOUT) != 0,
     30306-                         (newmode & A_UNDERLINE) != 0,
     30307-                         (newmode & A_REVERSE) != 0,
     30308-                         (newmode & A_BLINK) != 0,
     30309-                         (newmode & A_DIM) != 0,
     30310-                         (newmode & A_BOLD) != 0,
     30311-                         (newmode & A_INVIS) != 0,
     30312-                         (newmode & A_PROTECT) != 0,
     30313-                         (newmode & A_ALTCHARSET) != 0), 1, outc);
     30314+           NCURSES_SP_NAME(tputs) (NCURSES_SP_ARGx
     30315+                                   TPARM_9(set_attributes,
     30316+                                           (newmode & A_STANDOUT) != 0,
     30317+                                           (newmode & A_UNDERLINE) != 0,
     30318+                                           (newmode & A_REVERSE) != 0,
     30319+                                           (newmode & A_BLINK) != 0,
     30320+                                           (newmode & A_DIM) != 0,
     30321+                                           (newmode & A_BOLD) != 0,
     30322+                                           (newmode & A_INVIS) != 0,
     30323+                                           (newmode & A_PROTECT) != 0,
     30324+                                           (newmode & A_ALTCHARSET) != 0),
     30325+                                   1, outc);
     30326            previous_attr &= ALL_BUT_COLOR;
     30327            previous_pair = 0;
     30328        }
     30329@@ -179,11 +191,11 @@
     30330 
     30331        TurnOff(A_ALTCHARSET, exit_alt_charset_mode);
     30332 
     30333-       if (!SP || SP->_use_rmul) {
     30334+       if (!SP_PARM || SP_PARM->_use_rmul) {
     30335            TurnOff(A_UNDERLINE, exit_underline_mode);
     30336        }
     30337 
     30338-       if (!SP || SP->_use_rmso) {
     30339+       if (!SP_PARM || SP_PARM->_use_rmso) {
     30340            TurnOff(A_STANDOUT, exit_standout_mode);
     30341        }
     30342 
     30343@@ -221,9 +233,9 @@
     30344     if (reverse)
     30345        newmode |= A_REVERSE;
     30346 
     30347-    if (SP) {
     30348-       SetAttr(SCREEN_ATTRS(SP), newmode);
     30349-       SetPair(SCREEN_ATTRS(SP), pair);
     30350+    if (SP_PARM) {
     30351+       SetAttr(SCREEN_ATTRS(SP_PARM), newmode);
     30352+       SetPair(SCREEN_ATTRS(SP_PARM), pair);
     30353     } else {
     30354        previous_attr = newmode;
     30355        previous_pair = pair;
     30356@@ -233,29 +245,60 @@
     30357 #else
     30358     T((T_CALLED("vid_puts(%s,%d)"), _traceattr(newmode), pair));
     30359     set_color(newmode, pair);
     30360-    returnCode(vidputs(newmode, outc));
     30361+    returnCode(NCURSES_SP_NAME(vidputs) (NCURSES_SP_ARGx newmode, outc));
     30362 #endif
     30363 }
     30364 
     30365+#if NCURSES_SP_FUNCS
     30366+NCURSES_EXPORT(int)
     30367+vid_puts(attr_t newmode,
     30368+        short pair,
     30369+        void *opts GCC_UNUSED,
     30370+        NCURSES_OUTC outc)
     30371+{
     30372+    SetSafeOutcWrapper(outc);
     30373+    return NCURSES_SP_NAME(vid_puts) (CURRENT_SCREEN,
     30374+                                     newmode,
     30375+                                     pair,
     30376+                                     opts,
     30377+                                     _nc_outc_wrapper);
     30378+}
     30379+#endif
     30380+
     30381 #undef vid_attr
     30382 NCURSES_EXPORT(int)
     30383-vid_attr(attr_t newmode, short pair, void *opts)
     30384+NCURSES_SP_NAME(vid_attr) (NCURSES_SP_DCLx
     30385+                          attr_t newmode,
     30386+                          short pair,
     30387+                          void *opts)
     30388 {
     30389     T((T_CALLED("vid_attr(%s,%d)"), _traceattr(newmode), pair));
     30390-    returnCode(vid_puts(newmode, pair, opts, _nc_outch));
     30391+    returnCode(NCURSES_SP_NAME(vid_puts) (NCURSES_SP_ARGx
     30392+                                         newmode,
     30393+                                         pair,
     30394+                                         opts,
     30395+                                         NCURSES_SP_NAME(_nc_outch)));
     30396 }
     30397 
     30398+#if NCURSES_SP_FUNCS
     30399+NCURSES_EXPORT(int)
     30400+vid_attr(attr_t newmode, short pair, void *opts)
     30401+{
     30402+    return NCURSES_SP_NAME(vid_attr) (CURRENT_SCREEN, newmode, pair, opts);
     30403+}
     30404+#endif
     30405+
     30406 /*
     30407  * This implementation uses the same mask values for A_xxx and WA_xxx, so
     30408  * we can use termattrs() for part of the logic.
     30409  */
     30410 NCURSES_EXPORT(attr_t)
     30411-term_attrs(void)
     30412+NCURSES_SP_NAME(term_attrs) (NCURSES_SP_DCL0)
     30413 {
     30414     attr_t attrs;
     30415 
     30416     T((T_CALLED("term_attrs()")));
     30417-    attrs = termattrs();
     30418+    attrs = SP_PARM ? NCURSES_SP_NAME(termattrs) (NCURSES_SP_ARG) : 0;
     30419 
     30420     /* these are only supported for wide-character mode */
     30421     if (enter_horizontal_hl_mode)
     30422@@ -273,3 +316,11 @@
     30423 
     30424     returnAttr(attrs);
     30425 }
     30426+
     30427+#if NCURSES_SP_FUNCS
     30428+NCURSES_EXPORT(attr_t)
     30429+term_attrs(void)
     30430+{
     30431+    return NCURSES_SP_NAME(term_attrs) (CURRENT_SCREEN);
     30432+}
     30433+#endif
    2024030434diff -Naur ncurses-5.7.orig/ncurses/widechar/lib_wacs.c ncurses-5.7/ncurses/widechar/lib_wacs.c
    2024130435--- ncurses-5.7.orig/ncurses/widechar/lib_wacs.c        2006-12-17 07:16:17.000000000 -0800
    20242 +++ ncurses-5.7/ncurses/widechar/lib_wacs.c     2009-02-28 20:38:58.443328118 -0800
     30436+++ ncurses-5.7/ncurses/widechar/lib_wacs.c     2009-06-05 14:01:16.000000000 -0700
    2024330437@@ -31,9 +31,8 @@
    2024430438  ****************************************************************************/
     
    2025230446 NCURSES_EXPORT_VAR(cchar_t) * _nc_wacs = 0;
    2025330447 
     30448diff -Naur ncurses-5.7.orig/ncurses/widechar/lib_wunctrl.c ncurses-5.7/ncurses/widechar/lib_wunctrl.c
     30449--- ncurses-5.7.orig/ncurses/widechar/lib_wunctrl.c     2007-06-12 13:22:32.000000000 -0700
     30450+++ ncurses-5.7/ncurses/widechar/lib_wunctrl.c  2009-06-05 14:01:44.000000000 -0700
     30451@@ -1,5 +1,5 @@
     30452 /****************************************************************************
     30453- * Copyright (c) 2001-2005,2007 Free Software Foundation, Inc.              *
     30454+ * Copyright (c) 2001-2007,2009 Free Software Foundation, Inc.              *
     30455  *                                                                          *
     30456  * Permission is hereby granted, free of charge, to any person obtaining a  *
     30457  * copy of this software and associated documentation files (the            *
     30458@@ -35,21 +35,31 @@
     30459 
     30460 #include <curses.priv.h>
     30461 
     30462-MODULE_ID("$Id: lib_wunctrl.c,v 1.12 2007/06/12 20:22:32 tom Exp $")
     30463+MODULE_ID("$Id: lib_wunctrl.c,v 1.13 2009/04/18 19:06:55 tom Exp $")
     30464 
     30465 NCURSES_EXPORT(wchar_t *)
     30466-wunctrl(cchar_t *wc)
     30467+NCURSES_SP_NAME(wunctrl) (NCURSES_SP_DCLx cchar_t *wc)
     30468 {
     30469-    static wchar_t str[CCHARW_MAX + 1], *sp;
     30470+    static wchar_t str[CCHARW_MAX + 1], *wsp;
     30471 
     30472     if (Charable(*wc)) {
     30473-       const char *p = unctrl((unsigned) _nc_to_char((wint_t) CharOf(*wc)));
     30474+       const char *p =
     30475+       NCURSES_SP_NAME(unctrl) (NCURSES_SP_ARGx
     30476+                                (unsigned) _nc_to_char((wint_t)CharOf(*wc)));
     30477 
     30478-       for (sp = str; *p; ++p) {
     30479-           *sp++ = _nc_to_widechar(*p);
     30480+       for (wsp = str; *p; ++p) {
     30481+           *wsp++ = _nc_to_widechar(*p);
     30482        }
     30483-       *sp = 0;
     30484+       *wsp = 0;
     30485        return str;
     30486     } else
     30487        return wc->chars;
     30488 }
     30489+
     30490+#if NCURSES_SP_FUNCS
     30491+NCURSES_EXPORT(wchar_t *)
     30492+wunctrl(cchar_t *wc)
     30493+{
     30494+    return NCURSES_SP_NAME(wunctrl) (CURRENT_SCREEN, wc);
     30495+}
     30496+#endif
    2025430497diff -Naur ncurses-5.7.orig/NEWS ncurses-5.7/NEWS
    2025530498--- ncurses-5.7.orig/NEWS       2008-11-01 17:56:22.000000000 -0700
    20256 +++ ncurses-5.7/NEWS    2009-02-28 20:38:59.855417236 -0800
     30499+++ ncurses-5.7/NEWS    2009-06-05 14:01:55.000000000 -0700
    2025730500@@ -1,5 +1,5 @@
    2025830501 -------------------------------------------------------------------------------
     
    2026730510 -------------------------------------------------------------------------------
    2026830511--- $Id: NEWS,v 1.1320 2008/11/02 00:56:22 tom Exp $
    20269 +-- $Id: NEWS,v 1.1367 2009/02/28 22:38:03 tom Exp $
     30512+-- $Id: NEWS,v 1.1392 2009/05/30 19:19:59 tom Exp $
    2027030513 -------------------------------------------------------------------------------
    2027130514 
    2027230515 This is a log of changes that ncurses has gone through since Zeyd started
    20273 @@ -45,6 +45,158 @@
     30516@@ -45,6 +45,257 @@
    2027430517 Changes through 1.9.9e did not credit all contributions;
    2027530518 it is not possible to add this information.
    2027630519 
     30520+20090530
     30521+       + fix an infinite recursion when adding a legacy-coding 8-bit value
     30522+         using insch() (report by Clemens Ladisch).
     30523+       + free home-terminfo string in del_curterm() (patch by Dan Weber).
     30524+       + continue integrating "sp-funcs" by Juergen Pfeifer (incomplete).
     30525+
     30526+20090523
     30527+       + continue integrating "sp-funcs" by Juergen Pfeifer (incomplete).
     30528+
     30529+20090516
     30530+       + work around antique BSD game's manipulation of stdscr, etc., versus
     30531+         SCREEN's copy of the pointer (Debian #528411).
     30532+       + add a cast to wattrset macro to avoid compiler warning when comparing
     30533+         its result against ERR (adapted from patch by Matt Kraii, Debian
     30534+         #528374).
     30535+
     30536+20090510
     30537+       + continue integrating "sp-funcs" by Juergen Pfeifer (incomplete).
     30538+
     30539+20090502
     30540+       + continue integrating "sp-funcs" by Juergen Pfeifer (incomplete).
     30541+       + add vwmterm terminfo entry (patch by Bryan Christ).
     30542+
     30543+20090425
     30544+       + continue integrating "sp-funcs" by Juergen Pfeifer (incomplete).
     30545+
     30546+20090419
     30547+       + build fix for _nc_free_and_exit() change in 20090418 (report by
     30548+         Christian Ebert).
     30549+
     30550+20090418
     30551+       + continue integrating "sp-funcs" by Juergen Pfeifer (incomplete).
     30552+
     30553+20090411
     30554+       + continue integrating "sp-funcs" by Juergen Pfeifer (incomplete).
     30555+         This change finishes merging for menu and panel libraries, does
     30556+         part of the form library.
     30557+
     30558+20090404
     30559+       + suppress configure check for static/dynamic linker flags for gcc on
     30560+         Darwin (report by Nelson Beebe).
     30561+
     30562+20090328
     30563+       + extend ansi.sys pfkey capability from kf1-kf10 to kf1-kf48, moving
     30564+         function key definitions from emx-base for consistency -TD
     30565+       + correct missing final 'p' in pfkey capability of ansi.sys-old (report
     30566+         by Kalle Olavi Niemitalo).
     30567+       + improve test/ncurses.c 'F' test, show combining characters in color.
     30568+       + quiet a false report by cppcheck in c++/cursesw.cc by eliminating
     30569+         a temporary variable.
     30570+       + use _nc_doalloc() rather than realloc() in a few places in ncurses
     30571+         library to avoid leak in out-of-memory condition (reports by William
     30572+         Egert and Martin Ettl based on cppcheck tool).
     30573+       + add --with-ncurses-wrap-prefix option to test/configure (discussion
     30574+         with Charles Wilson).
     30575+       + use ncurses*-config scripts if available for test/configure.
     30576+       + update test/aclocal.m4 and test/configure
     30577+       > patches by Charles Wilson:
     30578+       + modify CF_WITH_LIBTOOL configure check to allow unreleased libtool
     30579+         version numbers (e.g.  which include alphabetic chars, as well as
     30580+         digits, after the final '.').
     30581+       + improve use of -no-undefined option for libtool by setting an
     30582+         intermediate variable LT_UNDEF in the configure script, and then
     30583+         using that in the libtool link-commands.
     30584+       + fix an missing use of NCURSES_PUBLIC_VAR() in tinfo/MKcodes.awk
     30585+         from 2009031 changes.
     30586+       + improve mk-1st.awk script by writing separate cases for the
     30587+         LIBTOOL_LINK command, depending on which library (ncurses, ticlib,
     30588+         termlib) is to be linked.
     30589+       + modify configure.in to allow broken-linker configurations, not just
     30590+         enable-reentrant, to set public wrap prefix.
     30591+
     30592+20090321
     30593+       + add TICS_LIST and SHLIB_LIST to allow libtool 2.2.6 on Cygwin to
     30594+         build with tic and term libraries (patch by Charles Wilson).
     30595+       + add -no-undefined option to libtool for Cygwin, MinGW, U/Win and AIX
     30596+         (report by Charles Wilson).
     30597+       + fix definition for c++/Makefile.in's SHLIB_LIST, which did not list
     30598+         the form, menu or panel libraries (patch by Charles Wilson).
     30599+       + add configure option --with-wrap-prefix to allow setting the prefix
     30600+         for functions used to wrap global variables to something other than
     30601+         "_nc_" (discussion with Charles Wilson).
     30602+
     30603+20090314
     30604+       + modify scripts to generate ncurses*-config and pc-files to add
     30605+         dependency for tinfo library (patch by Charles Wilson).
     30606+       + improve comparison of program-names when checking for linked flavors
     30607+         such as "reset" by ignoring the executable suffix (reports by Charles
     30608+         Wilson, Samuel Thibault and Cedric Bretaudeau on Cygwin mailing
     30609+         list).
     30610+       + suppress configure check for static/dynamic linker flags for gcc on
     30611+         Solaris 10, since gcc is confused by absence of static libc, and
     30612+         does not switch back to dynamic mode before finishing the libraries
     30613+         (reports by Joel Bertrand, Alan Pae).
     30614+       + minor fixes to Intel compiler warning checks in configure script.
     30615+       + modify _nc_leaks_tinfo() so leak-checking in test/railroad.c works.
     30616+       + modify set_curterm() to make broken-linker configuration work with
     30617+         changes from 20090228 (report by Charles Wilson).
     30618+
    2027730619+20090228
    2027830620+       + continue integrating "sp-funcs" by Juergen Pfeifer (incomplete).
     
    2043230774diff -Naur ncurses-5.7.orig/panel/Makefile.in ncurses-5.7/panel/Makefile.in
    2043330775--- ncurses-5.7.orig/panel/Makefile.in  2007-04-28 07:56:11.000000000 -0700
    20434 +++ ncurses-5.7/panel/Makefile.in       2009-02-28 20:38:46.310547562 -0800
     30776+++ ncurses-5.7/panel/Makefile.in       2009-06-05 14:01:30.000000000 -0700
    2043530777@@ -1,6 +1,6 @@
    2043630778-# $Id: Makefile.in,v 1.52 2007/04/28 14:56:11 tom Exp $
    20437 +# $Id: Makefile.in,v 1.53 2009/01/03 19:09:26 tom Exp $
     30779+# $Id: Makefile.in,v 1.54 2009/03/28 18:22:39 Charles.Wilson Exp $
    2043830780 ##############################################################################
    2043930781-# Copyright (c) 1998-2006,2007 Free Software Foundation, Inc.                #
     
    2044230784 # Permission is hereby granted, free of charge, to any person obtaining a    #
    2044330785 # copy of this software and associated documentation files (the "Software"), #
    20444 @@ -71,7 +71,7 @@
     30786@@ -64,6 +64,7 @@
     30787 LIBTOOL_LINK   = @LIB_LINK@
     30788 LIBTOOL_INSTALL        = @LIB_INSTALL@
     30789 LIBTOOL_UNINSTALL = @LIB_UNINSTALL@
     30790+LT_UNDEF       = @LT_UNDEF@
     30791 
     30792 INSTALL                = @INSTALL@
     30793 INSTALL_LIB    = @INSTALL@ @INSTALL_LIB@
     30794@@ -71,7 +72,7 @@
    2044530795 INSTALL_DATA   = @INSTALL_DATA@
    2044630796 
     
    2045130801 LD             = @LD@
    2045230802 LN_S           = @LN_S@
     30803diff -Naur ncurses-5.7.orig/panel/p_above.c ncurses-5.7/panel/p_above.c
     30804--- ncurses-5.7.orig/panel/p_above.c    2005-02-19 08:44:57.000000000 -0800
     30805+++ ncurses-5.7/panel/p_above.c 2009-06-05 14:01:33.000000000 -0700
     30806@@ -1,5 +1,5 @@
     30807 /****************************************************************************
     30808- * Copyright (c) 1998-2000,2005 Free Software Foundation, Inc.              *
     30809+ * Copyright (c) 1998-2005,2009 Free Software Foundation, Inc.              *
     30810  *                                                                          *
     30811  * Permission is hereby granted, free of charge, to any person obtaining a  *
     30812  * copy of this software and associated documentation files (the            *
     30813@@ -29,24 +29,56 @@
     30814 /****************************************************************************
     30815  *  Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1995                    *
     30816  *     and: Eric S. Raymond <esr@snark.thyrsus.com>                         *
     30817+ *     and: Juergen Pfeifer                         1997-1999,2008          *
     30818  ****************************************************************************/
     30819 
     30820 /* p_above.c
     30821  */
     30822 #include "panel.priv.h"
     30823 
     30824-MODULE_ID("$Id: p_above.c,v 1.6 2005/02/19 16:44:57 tom Exp $")
     30825+MODULE_ID("$Id: p_above.c,v 1.7 2009/04/11 20:03:06 tom Exp $")
     30826+
     30827+#if NCURSES_SP_FUNCS
     30828+NCURSES_EXPORT(PANEL *)
     30829+ground_panel(SCREEN * sp)
     30830+{
     30831+  T((T_CALLED("ground_panel(%p)"), sp));
     30832+  if (sp)
     30833+    {
     30834+      struct panelhook *ph = NCURSES_SP_NAME(_nc_panelhook) (sp);
     30835+
     30836+      if (_nc_bottom_panel)    /* this is the pseudo panel */
     30837+       returnPanel(_nc_bottom_panel->above);
     30838+      else
     30839+       returnPanel(0);
     30840+    }
     30841+  else
     30842+    {
     30843+      if (0 == CURRENT_SCREEN)
     30844+       returnPanel(0);
     30845+      else
     30846+       returnPanel(ground_panel(CURRENT_SCREEN));
     30847+    }
     30848+}
     30849+#endif
     30850 
     30851 NCURSES_EXPORT(PANEL *)
     30852 panel_above(const PANEL * pan)
     30853 {
     30854+  PANEL *result;
     30855+
     30856   T((T_CALLED("panel_above(%p)"), pan));
     30857-  if (!pan)
     30858+  if (pan)
     30859+    result = pan->above;
     30860+  else
     30861     {
     30862+#if NCURSES_SP_FUNCS
     30863+      result = ground_panel(CURRENT_SCREEN);
     30864+#else
     30865       /* if top and bottom are equal, we have no or only the pseudo panel;
     30866          if not, we return the panel above the pseudo panel */
     30867-      returnPanel(EMPTY_STACK()? (PANEL *) 0 : _nc_bottom_panel->above);
     30868+      result = EMPTY_STACK()? (PANEL *) 0 : _nc_bottom_panel->above;
     30869+#endif
     30870     }
     30871-  else
     30872-    returnPanel(pan->above);
     30873+  returnPanel(result);
     30874 }
     30875diff -Naur ncurses-5.7.orig/panel/panel.c ncurses-5.7/panel/panel.c
     30876--- ncurses-5.7.orig/panel/panel.c      2005-02-19 10:04:31.000000000 -0800
     30877+++ ncurses-5.7/panel/panel.c   2009-06-05 14:01:33.000000000 -0700
     30878@@ -1,5 +1,5 @@
     30879 /****************************************************************************
     30880- * Copyright (c) 1998-2004,2005 Free Software Foundation, Inc.              *
     30881+ * Copyright (c) 1998-2005,2009 Free Software Foundation, Inc.              *
     30882  *                                                                          *
     30883  * Permission is hereby granted, free of charge, to any person obtaining a  *
     30884  * copy of this software and associated documentation files (the            *
     30885@@ -29,12 +29,14 @@
     30886 /****************************************************************************
     30887  *  Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1995                    *
     30888  *     and: Eric S. Raymond <esr@snark.thyrsus.com>                         *
     30889+ *     and: Juergen Pfeifer                         1996-1999,2008          *
     30890+ *     and: Thomas E. Dickey                                                *
     30891  ****************************************************************************/
     30892 
     30893 /* panel.c -- implementation of panels library, some core routines */
     30894 #include "panel.priv.h"
     30895 
     30896-MODULE_ID("$Id: panel.c,v 1.23 2005/02/19 18:04:31 tom Exp $")
     30897+MODULE_ID("$Id: panel.c,v 1.24 2009/04/11 21:29:10 tom Exp $")
     30898 
     30899 /*+-------------------------------------------------------------------------
     30900        _nc_retrace_panel (pan)
     30901@@ -91,6 +93,8 @@
     30902 {
     30903   char s80[80];
     30904 
     30905+  GetPanelHook(pan);
     30906+
     30907   sprintf(s80, fmt, num, pan);
     30908   _tracef("%s b=%s t=%s", s80,
     30909          (_nc_bottom_panel) ? USER_PTR(_nc_bottom_panel->user) : "--",
     30910diff -Naur ncurses-5.7.orig/panel/panel.h ncurses-5.7/panel/panel.h
     30911--- ncurses-5.7.orig/panel/panel.h      2006-05-27 12:49:40.000000000 -0700
     30912+++ ncurses-5.7/panel/panel.h   2009-06-05 14:01:33.000000000 -0700
     30913@@ -1,5 +1,5 @@
     30914 /****************************************************************************
     30915- * Copyright (c) 1998-2001,2006 Free Software Foundation, Inc.              *
     30916+ * Copyright (c) 1998-2006,2009 Free Software Foundation, Inc.              *
     30917  *                                                                          *
     30918  * Permission is hereby granted, free of charge, to any person obtaining a  *
     30919  * copy of this software and associated documentation files (the            *
     30920@@ -29,9 +29,10 @@
     30921 /****************************************************************************
     30922  *  Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1995                    *
     30923  *     and: Eric S. Raymond <esr@snark.thyrsus.com>                         *
     30924+ *     and: Juergen Pfeifer                         1996-1999,2008          *
     30925  ****************************************************************************/
     30926 
     30927-/* $Id: panel.h,v 1.10 2006/05/27 19:49:40 tom Exp $ */
     30928+/* $Id: panel.h,v 1.11 2009/04/11 19:50:40 tom Exp $ */
     30929 
     30930 /* panel.h -- interface file for panels library */
     30931 
     30932@@ -68,6 +69,13 @@
     30933 extern NCURSES_EXPORT(int)     replace_panel (PANEL *,WINDOW *);
     30934 extern NCURSES_EXPORT(int)     panel_hidden (const PANEL *);
     30935 
     30936+#if NCURSES_SP_FUNCS
     30937+extern NCURSES_EXPORT(PANEL *) ground_panel(SCREEN *);
     30938+extern NCURSES_EXPORT(PANEL *) ceiling_panel(SCREEN *);
     30939+
     30940+extern NCURSES_EXPORT(void)    NCURSES_SP_NAME(update_panels) (SCREEN*);
     30941+#endif
     30942+
     30943 #if    defined(__cplusplus)
     30944 }
     30945 #endif
     30946diff -Naur ncurses-5.7.orig/panel/panel.priv.h ncurses-5.7/panel/panel.priv.h
     30947--- ncurses-5.7.orig/panel/panel.priv.h 2008-09-27 15:36:11.000000000 -0700
     30948+++ ncurses-5.7/panel/panel.priv.h      2009-06-05 14:01:33.000000000 -0700
     30949@@ -1,5 +1,5 @@
     30950 /****************************************************************************
     30951- * Copyright (c) 1998-2005,2008 Free Software Foundation, Inc.              *
     30952+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     30953  *                                                                          *
     30954  * Permission is hereby granted, free of charge, to any person obtaining a  *
     30955  * copy of this software and associated documentation files (the            *
     30956@@ -26,7 +26,7 @@
     30957  * authorization.                                                           *
     30958  ****************************************************************************/
     30959 
     30960-/* $Id: panel.priv.h,v 1.22 2008/09/27 22:36:11 tom Exp $ */
     30961+/* $Id: panel.priv.h,v 1.23 2009/04/11 20:33:55 tom Exp $ */
     30962 
     30963 #ifndef NCURSES_PANEL_PRIV_H
     30964 #define NCURSES_PANEL_PRIV_H 1
     30965@@ -39,9 +39,11 @@
     30966 #include <string.h>
     30967 #include <assert.h>
     30968 
     30969-#include "curses.priv.h"
     30970+struct screen;              /* forward declaration */
     30971+
     30972+#include "curses.priv.h"    /* includes nc_panel.h */
     30973 #include "panel.h"
     30974-#include <nc_panel.h>
     30975+
     30976 
     30977 #if USE_RCS_IDS
     30978 #  define MODULE_ID(id) static const char Ident[] = id;
     30979@@ -83,14 +85,38 @@
     30980 #  define Touchline(pan,start,count) touchline((pan)->win,start,count)
     30981 #endif
     30982 
     30983+#if NCURSES_SP_FUNCS
     30984+#define GetScreenHook(sp) \
     30985+                       struct panelhook* ph = NCURSES_SP_NAME(_nc_panelhook)(sp)
     30986+#define GetPanelHook(pan) \
     30987+                       GetScreenHook(_nc_screen_of((pan)->win))
     30988+#define GetWindowHook(win) \
     30989+                       SCREEN* sp = _nc_screen_of(win); \
     30990+                       GetScreenHook(sp)
     30991+#define GetHook(pan)   SCREEN* sp = _nc_screen_of(pan->win); \
     30992+                       GetScreenHook(sp)
     30993+
     30994+#define _nc_stdscr_pseudo_panel ((ph)->stdscr_pseudo_panel)
     30995+#define _nc_top_panel           ((ph)->top_panel)
     30996+#define _nc_bottom_panel        ((ph)->bottom_panel)
     30997+
     30998+#else  /* !NCURSES_SP_FUNCS */
     30999+
     31000+#define GetScreenHook(sp) /* nothing */
     31001+#define GetPanelHook(pan) /* nothing */
     31002+#define GetWindowHook(win) /* nothing */
     31003+#define GetHook(pan) /* nothing */
     31004+
     31005 #define _nc_stdscr_pseudo_panel _nc_panelhook()->stdscr_pseudo_panel
     31006-#define _nc_top_panel _nc_panelhook()->top_panel
     31007-#define _nc_bottom_panel _nc_panelhook()->bottom_panel
     31008+#define _nc_top_panel           _nc_panelhook()->top_panel
     31009+#define _nc_bottom_panel        _nc_panelhook()->bottom_panel
     31010 
     31011-#define EMPTY_STACK() (_nc_top_panel==_nc_bottom_panel)
     31012-#define Is_Bottom(p)  (((p)!=(PANEL*)0) && !EMPTY_STACK() && (_nc_bottom_panel->above==(p)))
     31013-#define Is_Top(p) (((p)!=(PANEL*)0) && !EMPTY_STACK() && (_nc_top_panel==(p)))
     31014-#define Is_Pseudo(p) ((p) && ((p)==_nc_bottom_panel))
     31015+#endif /* NCURSES_SP_FUNCS */
     31016+
     31017+#define EMPTY_STACK() (_nc_top_panel == _nc_bottom_panel)
     31018+#define Is_Bottom(p)  (((p) != (PANEL*)0) && !EMPTY_STACK() && (_nc_bottom_panel->above == (p)))
     31019+#define Is_Top(p)     (((p) != (PANEL*)0) && !EMPTY_STACK() && (_nc_top_panel == (p)))
     31020+#define Is_Pseudo(p)  (((p) != (PANEL*)0) && ((p) == _nc_bottom_panel))
     31021 
     31022 /*+-------------------------------------------------------------------------
     31023        IS_LINKED(pan) - check to see if panel is in the stack
     31024@@ -122,7 +148,7 @@
     31025    ix2 = (PENDX(pan1)   < PENDX(pan2))   ? PENDX(pan1)   : PENDX(pan2);\
     31026    iy1 = (PSTARTY(pan1) < PSTARTY(pan2)) ? PSTARTY(pan2) : PSTARTY(pan1);\
     31027    iy2 = (PENDY(pan1)   < PENDY(pan2))   ? PENDY(pan1)   : PENDY(pan2);\
     31028-   assert((ix1<=ix2) && (iy1<=iy2));\
     31029+   assert((ix1<=ix2) && (iy1<=iy2))
     31030 
     31031 
     31032 /*+-------------------------------------------------------------------------
     31033@@ -136,12 +162,12 @@
     31034 {  PANEL* pan2 = ((panstart) ? (panstart) : _nc_bottom_panel);\
     31035    while(pan2) {\
     31036       if ((pan2 != pan) && PANELS_OVERLAPPED(pan,pan2)) {\
     31037-        int y,ix1,ix2,iy1,iy2;\
     31038-        COMPUTE_INTERSECTION(pan,pan2,ix1,ix2,iy1,iy2);\
     31039+        int y, ix1, ix2, iy1, iy2;\
     31040+        COMPUTE_INTERSECTION(pan, pan2, ix1, ix2, iy1, iy2);\
     31041        for(y = iy1; y <= iy2; y++) {\
     31042          if (is_linetouched(pan->win,y - PSTARTY(pan))) {\
     31043             struct ldat* line = &(pan2->win->_line[y - PSTARTY(pan2)]);\
     31044-            CHANGED_RANGE(line,ix1-PSTARTX(pan2),ix2-PSTARTX(pan2));\
     31045+            CHANGED_RANGE(line, ix1 - PSTARTX(pan2), ix2 - PSTARTX(pan2));\
     31046           }\
     31047        }\
     31048       }\
     31049@@ -180,4 +206,9 @@
     31050       err = err_if_unlinked;\
     31051   }
     31052 
     31053+#if NCURSES_SP_FUNCS
     31054+/* These may become later renamed and part of panel.h and the public API */
     31055+extern NCURSES_EXPORT(void) NCURSES_SP_NAME(_nc_update_panels)(SCREEN*);
     31056+#endif
     31057+
     31058 #endif /* NCURSES_PANEL_PRIV_H */
     31059diff -Naur ncurses-5.7.orig/panel/p_below.c ncurses-5.7/panel/p_below.c
     31060--- ncurses-5.7.orig/panel/p_below.c    2005-02-19 08:45:10.000000000 -0800
     31061+++ ncurses-5.7/panel/p_below.c 2009-06-05 14:01:33.000000000 -0700
     31062@@ -1,5 +1,5 @@
     31063 /****************************************************************************
     31064- * Copyright (c) 1998-2000,2005 Free Software Foundation, Inc.              *
     31065+ * Copyright (c) 1998-2005,2009 Free Software Foundation, Inc.              *
     31066  *                                                                          *
     31067  * Permission is hereby granted, free of charge, to any person obtaining a  *
     31068  * copy of this software and associated documentation files (the            *
     31069@@ -29,26 +29,57 @@
     31070 /****************************************************************************
     31071  *  Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1995                    *
     31072  *     and: Eric S. Raymond <esr@snark.thyrsus.com>                         *
     31073+ *     and: Juergen Pfeifer                         1997-1999,2008          *
     31074  ****************************************************************************/
     31075 
     31076 /* p_below.c
     31077  */
     31078 #include "panel.priv.h"
     31079 
     31080-MODULE_ID("$Id: p_below.c,v 1.6 2005/02/19 16:45:10 tom Exp $")
     31081+MODULE_ID("$Id: p_below.c,v 1.7 2009/04/11 20:17:59 tom Exp $")
     31082 
     31083+#if NCURSES_SP_FUNCS
     31084 NCURSES_EXPORT(PANEL *)
     31085-panel_below(const PANEL * pan)
     31086+ceiling_panel(SCREEN * sp)
     31087 {
     31088-  T((T_CALLED("panel_below(%p)"), pan));
     31089-  if (!pan)
     31090+  T((T_CALLED("ceiling_panel(%p)"), sp));
     31091+  if (sp)
     31092     {
     31093+      struct panelhook *ph = NCURSES_SP_NAME(_nc_panelhook) (sp);
     31094+
     31095       /* if top and bottom are equal, we have no or only the pseudo panel */
     31096       returnPanel(EMPTY_STACK()? (PANEL *) 0 : _nc_top_panel);
     31097     }
     31098   else
     31099     {
     31100+      if (0 == CURRENT_SCREEN)
     31101+       returnPanel(0);
     31102+      else
     31103+       returnPanel(ceiling_panel(CURRENT_SCREEN));
     31104+    }
     31105+}
     31106+#endif
     31107+
     31108+NCURSES_EXPORT(PANEL *)
     31109+panel_below(const PANEL * pan)
     31110+{
     31111+  PANEL *result;
     31112+
     31113+  T((T_CALLED("panel_below(%p)"), pan));
     31114+  if (pan)
     31115+    {
     31116+      GetHook(pan);
     31117       /* we must not return the pseudo panel */
     31118-      returnPanel(Is_Pseudo(pan->below) ? (PANEL *) 0 : pan->below);
     31119+      result = Is_Pseudo(pan->below) ? (PANEL *) 0 : pan->below;
     31120+    }
     31121+  else
     31122+    {
     31123+#if NCURSES_SP_FUNCS
     31124+      result = ceiling_panel(CURRENT_SCREEN);
     31125+#else
     31126+      /* if top and bottom are equal, we have no or only the pseudo panel */
     31127+      result = EMPTY_STACK()? (PANEL *) 0 : _nc_top_panel;
     31128+#endif
     31129     }
     31130+  returnPanel(result);
     31131 }
     31132diff -Naur ncurses-5.7.orig/panel/p_bottom.c ncurses-5.7/panel/p_bottom.c
     31133--- ncurses-5.7.orig/panel/p_bottom.c   2005-02-19 08:38:16.000000000 -0800
     31134+++ ncurses-5.7/panel/p_bottom.c        2009-06-05 14:01:33.000000000 -0700
     31135@@ -1,5 +1,5 @@
     31136 /****************************************************************************
     31137- * Copyright (c) 1998-2000,2005 Free Software Foundation, Inc.              *
     31138+ * Copyright (c) 1998-2005,2009 Free Software Foundation, Inc.              *
     31139  *                                                                          *
     31140  * Permission is hereby granted, free of charge, to any person obtaining a  *
     31141  * copy of this software and associated documentation files (the            *
     31142@@ -29,6 +29,7 @@
     31143 /****************************************************************************
     31144  *  Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1995                    *
     31145  *     and: Eric S. Raymond <esr@snark.thyrsus.com>                         *
     31146+ *     and: Juergen Pfeifer                         1997-1999,2008          *
     31147  ****************************************************************************/
     31148 
     31149 /* p_bottom.c
     31150@@ -36,7 +37,7 @@
     31151  */
     31152 #include "panel.priv.h"
     31153 
     31154-MODULE_ID("$Id: p_bottom.c,v 1.11 2005/02/19 16:38:16 tom Exp $")
     31155+MODULE_ID("$Id: p_bottom.c,v 1.12 2008/11/16 00:19:59 juergen Exp $")
     31156 
     31157 NCURSES_EXPORT(int)
     31158 bottom_panel(PANEL * pan)
     31159@@ -46,6 +47,7 @@
     31160   T((T_CALLED("bottom_panel(%p)"), pan));
     31161   if (pan)
     31162     {
     31163+      GetHook(pan);
     31164       if (!Is_Bottom(pan))
     31165        {
     31166 
     31167diff -Naur ncurses-5.7.orig/panel/p_delete.c ncurses-5.7/panel/p_delete.c
     31168--- ncurses-5.7.orig/panel/p_delete.c   2005-02-19 08:38:45.000000000 -0800
     31169+++ ncurses-5.7/panel/p_delete.c        2009-06-05 14:01:33.000000000 -0700
     31170@@ -1,5 +1,5 @@
     31171 /****************************************************************************
     31172- * Copyright (c) 1998-2000,2005 Free Software Foundation, Inc.              *
     31173+ * Copyright (c) 1998-2005,2009 Free Software Foundation, Inc.              *
     31174  *                                                                          *
     31175  * Permission is hereby granted, free of charge, to any person obtaining a  *
     31176  * copy of this software and associated documentation files (the            *
     31177@@ -29,6 +29,7 @@
     31178 /****************************************************************************
     31179  *  Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1995                    *
     31180  *     and: Eric S. Raymond <esr@snark.thyrsus.com>                         *
     31181+ *     and: Juergen Pfeifer                         1999,2008               *
     31182  ****************************************************************************/
     31183 
     31184 /* p_delete.c
     31185@@ -36,7 +37,7 @@
     31186  */
     31187 #include "panel.priv.h"
     31188 
     31189-MODULE_ID("$Id: p_delete.c,v 1.8 2005/02/19 16:38:45 tom Exp $")
     31190+MODULE_ID("$Id: p_delete.c,v 1.9 2009/04/11 18:58:36 tom Exp $")
     31191 
     31192 NCURSES_EXPORT(int)
     31193 del_panel(PANEL * pan)
     31194@@ -47,8 +48,11 @@
     31195   if (pan)
     31196     {
     31197       dBug(("--> del_panel %s", USER_PTR(pan->user)));
     31198-      HIDE_PANEL(pan, err, OK);
     31199-      free((void *)pan);
     31200+      {
     31201+       GetHook(pan);
     31202+       HIDE_PANEL(pan, err, OK);
     31203+       free((void *)pan);
     31204+      }
     31205     }
     31206   else
     31207     err = ERR;
     31208diff -Naur ncurses-5.7.orig/panel/p_hidden.c ncurses-5.7/panel/p_hidden.c
     31209--- ncurses-5.7.orig/panel/p_hidden.c   2005-02-19 08:39:17.000000000 -0800
     31210+++ ncurses-5.7/panel/p_hidden.c        2009-06-05 14:01:33.000000000 -0700
     31211@@ -1,5 +1,5 @@
     31212 /****************************************************************************
     31213- * Copyright (c) 1998-2000,2005 Free Software Foundation, Inc.              *
     31214+ * Copyright (c) 1998-2005,2009 Free Software Foundation, Inc.              *
     31215  *                                                                          *
     31216  * Permission is hereby granted, free of charge, to any person obtaining a  *
     31217  * copy of this software and associated documentation files (the            *
     31218@@ -29,6 +29,7 @@
     31219 /****************************************************************************
     31220  *  Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1995                    *
     31221  *     and: Eric S. Raymond <esr@snark.thyrsus.com>                         *
     31222+ *     and: Juergen Pfeifer                         1997-1999,2008          *
     31223  ****************************************************************************/
     31224 
     31225 /* p_hidden.c
     31226@@ -36,13 +37,18 @@
     31227  */
     31228 #include "panel.priv.h"
     31229 
     31230-MODULE_ID("$Id: p_hidden.c,v 1.7 2005/02/19 16:39:17 tom Exp $")
     31231+MODULE_ID("$Id: p_hidden.c,v 1.8 2009/04/11 19:01:56 tom Exp $")
     31232 
     31233 NCURSES_EXPORT(int)
     31234 panel_hidden(const PANEL * pan)
     31235 {
     31236+  int rc = ERR;
     31237+
     31238   T((T_CALLED("panel_hidden(%p)"), pan));
     31239-  if (!pan)
     31240-    returnCode(ERR);
     31241-  returnCode(IS_LINKED(pan) ? FALSE : TRUE);
     31242+  if (pan)
     31243+    {
     31244+      GetHook(pan);
     31245+      rc = (IS_LINKED(pan) ? FALSE : TRUE);
     31246+    }
     31247+  returnCode(rc);
     31248 }
     31249diff -Naur ncurses-5.7.orig/panel/p_hide.c ncurses-5.7/panel/p_hide.c
     31250--- ncurses-5.7.orig/panel/p_hide.c     2005-02-19 08:39:41.000000000 -0800
     31251+++ ncurses-5.7/panel/p_hide.c  2009-06-05 14:01:33.000000000 -0700
     31252@@ -36,23 +36,27 @@
     31253  */
     31254 #include "panel.priv.h"
     31255 
     31256-MODULE_ID("$Id: p_hide.c,v 1.9 2005/02/19 16:39:41 tom Exp $")
     31257+MODULE_ID("$Id: p_hide.c,v 1.10 2009/02/07 23:11:45 tom Exp $")
     31258 
     31259 NCURSES_EXPORT(int)
     31260 hide_panel(register PANEL * pan)
     31261 {
     31262-  int err = OK;
     31263+  int err = ERR;
     31264 
     31265   T((T_CALLED("hide_panel(%p)"), pan));
     31266-  if (!pan)
     31267-    returnCode(ERR);
     31268 
     31269-  dBug(("--> hide_panel %s", USER_PTR(pan->user)));
     31270-  dStack("<u%d>", 1, pan);
     31271+  if (pan)
     31272+    {
     31273+      GetHook(pan);
     31274 
     31275-  HIDE_PANEL(pan, err, ERR);
     31276+      dBug(("--> hide_panel %s", USER_PTR(pan->user)));
     31277+      dStack("<u%d>", 1, pan);
     31278 
     31279-  dStack("<u%d>", 9, pan);
     31280+      HIDE_PANEL(pan, err, ERR);
     31281 
     31282+      err = OK;
     31283+
     31284+      dStack("<u%d>", 9, pan);
     31285+    }
     31286   returnCode(err);
     31287 }
     31288diff -Naur ncurses-5.7.orig/panel/p_move.c ncurses-5.7/panel/p_move.c
     31289--- ncurses-5.7.orig/panel/p_move.c     2005-02-19 08:46:49.000000000 -0800
     31290+++ ncurses-5.7/panel/p_move.c  2009-06-05 14:01:33.000000000 -0700
     31291@@ -1,5 +1,5 @@
     31292 /****************************************************************************
     31293- * Copyright (c) 1998-2000,2005 Free Software Foundation, Inc.              *
     31294+ * Copyright (c) 1998-2005,2008 Free Software Foundation, Inc.              *
     31295  *                                                                          *
     31296  * Permission is hereby granted, free of charge, to any person obtaining a  *
     31297  * copy of this software and associated documentation files (the            *
     31298@@ -29,6 +29,7 @@
     31299 /****************************************************************************
     31300  *  Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1995                    *
     31301  *     and: Eric S. Raymond <esr@snark.thyrsus.com>                         *
     31302+ *     and: Juergen Pfeifer                         1997-1999,2009          *
     31303  ****************************************************************************/
     31304 
     31305 /* p_move.c
     31306@@ -36,21 +37,24 @@
     31307  */
     31308 #include "panel.priv.h"
     31309 
     31310-MODULE_ID("$Id: p_move.c,v 1.9 2005/02/19 16:46:49 tom Exp $")
     31311+MODULE_ID("$Id: p_move.c,v 1.10 2008/11/16 00:19:59 juergen Exp $")
     31312 
     31313 NCURSES_EXPORT(int)
     31314 move_panel(PANEL * pan, int starty, int startx)
     31315 {
     31316-  T((T_CALLED("move_panel(%p,%d,%d)"), pan, starty, startx));
     31317+  int rc = ERR;
     31318 
     31319-  if (!pan)
     31320-    returnCode(ERR);
     31321+  T((T_CALLED("move_panel(%p,%d,%d)"), pan, starty, startx));
     31322 
     31323-  if (IS_LINKED(pan))
     31324+  if (pan)
     31325     {
     31326-      Touchpan(pan);
     31327-      PANEL_UPDATE(pan, (PANEL *) 0);
     31328+      GetHook(pan);
     31329+      if (IS_LINKED(pan))
     31330+       {
     31331+         Touchpan(pan);
     31332+         PANEL_UPDATE(pan, (PANEL *) 0);
     31333+       }
     31334+      rc = mvwin(pan->win, starty, startx);
     31335     }
     31336-
     31337-  returnCode(mvwin(pan->win, starty, startx));
     31338+  returnCode(rc);
     31339 }
     31340diff -Naur ncurses-5.7.orig/panel/p_new.c ncurses-5.7/panel/p_new.c
     31341--- ncurses-5.7.orig/panel/p_new.c      2008-08-04 11:25:48.000000000 -0700
     31342+++ ncurses-5.7/panel/p_new.c   2009-06-05 14:01:33.000000000 -0700
     31343@@ -1,5 +1,5 @@
     31344 /****************************************************************************
     31345- * Copyright (c) 1998-2005,2008 Free Software Foundation, Inc.              *
     31346+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     31347  *                                                                          *
     31348  * Permission is hereby granted, free of charge, to any person obtaining a  *
     31349  * copy of this software and associated documentation files (the            *
     31350@@ -38,7 +38,7 @@
     31351  */
     31352 #include "panel.priv.h"
     31353 
     31354-MODULE_ID("$Id: p_new.c,v 1.10 2008/08/04 18:25:48 tom Exp $")
     31355+MODULE_ID("$Id: p_new.c,v 1.14 2009/04/11 20:43:04 tom Exp $")
     31356 
     31357 #ifdef TRACE
     31358 static char *stdscr_id;
     31359@@ -50,20 +50,27 @@
     31360   Establish the pseudo panel for stdscr if necessary.
     31361 --------------------------------------------------------------------------*/
     31362 static PANEL *
     31363-root_panel(void)
     31364+root_panel(NCURSES_SP_DCL0)
     31365 {
     31366+#if NCURSES_SP_FUNCS
     31367+  struct panelhook *ph = NCURSES_SP_NAME(_nc_panelhook) (sp);
     31368+
     31369+#elif NO_LEAKS
     31370+  struct panelhook *ph = _nc_panelhook();
     31371+#endif
     31372+
     31373   if (_nc_stdscr_pseudo_panel == (PANEL *) 0)
     31374     {
     31375 
     31376-      assert(stdscr && !_nc_bottom_panel && !_nc_top_panel);
     31377+      assert(SP_PARM && SP_PARM->_stdscr && !_nc_bottom_panel && !_nc_top_panel);
     31378 #if NO_LEAKS
     31379-      _nc_panelhook()->destroy = del_panel;
     31380+      ph->destroy = del_panel;
     31381 #endif
     31382       _nc_stdscr_pseudo_panel = (PANEL *) malloc(sizeof(PANEL));
     31383       if (_nc_stdscr_pseudo_panel != 0)
     31384        {
     31385          PANEL *pan = _nc_stdscr_pseudo_panel;
     31386-         WINDOW *win = stdscr;
     31387+         WINDOW *win = SP_PARM->_stdscr;
     31388 
     31389          pan->win = win;
     31390          pan->below = (PANEL *) 0;
     31391@@ -86,13 +93,15 @@
     31392 {
     31393   PANEL *pan = (PANEL *) 0;
     31394 
     31395+  GetWindowHook(win);
     31396+
     31397   T((T_CALLED("new_panel(%p)"), win));
     31398 
     31399   if (!win)
     31400     returnPanel(pan);
     31401 
     31402   if (!_nc_stdscr_pseudo_panel)
     31403-    (void)root_panel();
     31404+    (void)root_panel(NCURSES_SP_ARG);
     31405   assert(_nc_stdscr_pseudo_panel);
     31406 
     31407   if (!(win->_flags & _ISPAD) && (pan = (PANEL *) malloc(sizeof(PANEL))))
     31408diff -Naur ncurses-5.7.orig/panel/p_replace.c ncurses-5.7/panel/p_replace.c
     31409--- ncurses-5.7.orig/panel/p_replace.c  2005-02-19 08:41:31.000000000 -0800
     31410+++ ncurses-5.7/panel/p_replace.c       2009-06-05 14:01:33.000000000 -0700
     31411@@ -36,23 +36,25 @@
     31412  */
     31413 #include "panel.priv.h"
     31414 
     31415-MODULE_ID("$Id: p_replace.c,v 1.9 2005/02/19 16:41:31 tom Exp $")
     31416+MODULE_ID("$Id: p_replace.c,v 1.10 2009/02/07 23:11:45 tom Exp $")
     31417 
     31418 NCURSES_EXPORT(int)
     31419 replace_panel(PANEL * pan, WINDOW *win)
     31420 {
     31421-  T((T_CALLED("replace_panel(%p,%p)"), pan, win));
     31422+  int rc = ERR;
     31423 
     31424-  if (!pan)
     31425-    returnCode(ERR);
     31426+  T((T_CALLED("replace_panel(%p,%p)"), pan, win));
     31427 
     31428-  if (IS_LINKED(pan))
     31429+  if (pan)
     31430     {
     31431-      Touchpan(pan);
     31432-      PANEL_UPDATE(pan, (PANEL *) 0);
     31433+      GetHook(pan);
     31434+      if (IS_LINKED(pan))
     31435+       {
     31436+         Touchpan(pan);
     31437+         PANEL_UPDATE(pan, (PANEL *) 0);
     31438+       }
     31439+      pan->win = win;
     31440+      rc = OK;
     31441     }
     31442-
     31443-  pan->win = win;
     31444-
     31445-  returnCode(OK);
     31446+  returnCode(rc);
     31447 }
     31448diff -Naur ncurses-5.7.orig/panel/p_show.c ncurses-5.7/panel/p_show.c
     31449--- ncurses-5.7.orig/panel/p_show.c     2005-02-19 08:42:02.000000000 -0800
     31450+++ ncurses-5.7/panel/p_show.c  2009-06-05 14:01:33.000000000 -0700
     31451@@ -36,34 +36,37 @@
     31452  */
     31453 #include "panel.priv.h"
     31454 
     31455-MODULE_ID("$Id: p_show.c,v 1.11 2005/02/19 16:42:02 tom Exp $")
     31456+MODULE_ID("$Id: p_show.c,v 1.12 2009/02/07 23:11:45 tom Exp $")
     31457 
     31458 NCURSES_EXPORT(int)
     31459 show_panel(PANEL * pan)
     31460 {
     31461-  int err = OK;
     31462+  int err = ERR;
     31463 
     31464   T((T_CALLED("show_panel(%p)"), pan));
     31465 
     31466-  if (!pan)
     31467-    returnCode(ERR);
     31468+  if (pan)
     31469+    {
     31470+      GetHook(pan);
     31471 
     31472-  if (Is_Top(pan))
     31473-    returnCode(OK);
     31474+      if (Is_Top(pan))
     31475+       returnCode(OK);
     31476 
     31477-  dBug(("--> show_panel %s", USER_PTR(pan->user)));
     31478+      dBug(("--> show_panel %s", USER_PTR(pan->user)));
     31479 
     31480-  HIDE_PANEL(pan, err, OK);
     31481+      HIDE_PANEL(pan, err, OK);
     31482 
     31483-  dStack("<lt%d>", 1, pan);
     31484-  assert(_nc_bottom_panel == _nc_stdscr_pseudo_panel);
     31485+      dStack("<lt%d>", 1, pan);
     31486+      assert(_nc_bottom_panel == _nc_stdscr_pseudo_panel);
     31487 
     31488-  _nc_top_panel->above = pan;
     31489-  pan->below = _nc_top_panel;
     31490-  pan->above = (PANEL *) 0;
     31491-  _nc_top_panel = pan;
     31492+      _nc_top_panel->above = pan;
     31493+      pan->below = _nc_top_panel;
     31494+      pan->above = (PANEL *) 0;
     31495+      _nc_top_panel = pan;
     31496 
     31497-  dStack("<lt%d>", 9, pan);
     31498+      err = OK;
     31499 
     31500-  returnCode(OK);
     31501+      dStack("<lt%d>", 9, pan);
     31502+    }
     31503+  returnCode(err);
     31504 }
     31505diff -Naur ncurses-5.7.orig/panel/p_update.c ncurses-5.7/panel/p_update.c
     31506--- ncurses-5.7.orig/panel/p_update.c   2005-02-19 08:49:47.000000000 -0800
     31507+++ ncurses-5.7/panel/p_update.c        2009-06-05 14:01:33.000000000 -0700
     31508@@ -1,5 +1,5 @@
     31509 /****************************************************************************
     31510- * Copyright (c) 1998-2000,2005 Free Software Foundation, Inc.              *
     31511+ * Copyright (c) 1998-2005,2009 Free Software Foundation, Inc.              *
     31512  *                                                                          *
     31513  * Permission is hereby granted, free of charge, to any person obtaining a  *
     31514  * copy of this software and associated documentation files (the            *
     31515@@ -29,6 +29,7 @@
     31516 /****************************************************************************
     31517  *  Author: Zeyd M. Ben-Halim <zmbenhal@netcom.com> 1995                    *
     31518  *     and: Eric S. Raymond <esr@snark.thyrsus.com>                         *
     31519+ *     and: Juergen Pfeifer                         1997-1999,2008          *
     31520  ****************************************************************************/
     31521 
     31522 /* p_update.c
     31523@@ -36,28 +37,42 @@
     31524  */
     31525 #include "panel.priv.h"
     31526 
     31527-MODULE_ID("$Id: p_update.c,v 1.9 2005/02/19 16:49:47 tom Exp $")
     31528+MODULE_ID("$Id: p_update.c,v 1.10 2009/04/11 19:48:36 tom Exp $")
     31529 
     31530 NCURSES_EXPORT(void)
     31531-update_panels(void)
     31532+NCURSES_SP_NAME(update_panels) (NCURSES_SP_DCL0)
     31533 {
     31534   PANEL *pan;
     31535 
     31536-  T((T_CALLED("update_panels()")));
     31537+  T((T_CALLED("update_panels(%p)"), SP_PARM));
     31538   dBug(("--> update_panels"));
     31539-  pan = _nc_bottom_panel;
     31540-  while (pan && pan->above)
     31541-    {
     31542-      PANEL_UPDATE(pan, pan->above);
     31543-      pan = pan->above;
     31544-    }
     31545 
     31546-  pan = _nc_bottom_panel;
     31547-  while (pan)
     31548+  if (SP_PARM)
     31549     {
     31550-      Wnoutrefresh(pan);
     31551-      pan = pan->above;
     31552+      GetScreenHook(SP_PARM);
     31553+
     31554+      pan = _nc_bottom_panel;
     31555+      while (pan && pan->above)
     31556+       {
     31557+         PANEL_UPDATE(pan, pan->above);
     31558+         pan = pan->above;
     31559+       }
     31560+
     31561+      pan = _nc_bottom_panel;
     31562+      while (pan)
     31563+       {
     31564+         Wnoutrefresh(pan);
     31565+         pan = pan->above;
     31566+       }
     31567     }
     31568 
     31569   returnVoid;
     31570 }
     31571+
     31572+#if NCURSES_SP_FUNCS
     31573+NCURSES_EXPORT(void)
     31574+update_panels(void)
     31575+{
     31576+  NCURSES_SP_NAME(update_panels) (CURRENT_SCREEN);
     31577+}
     31578+#endif
    2045331579diff -Naur ncurses-5.7.orig/progs/Makefile.in ncurses-5.7/progs/Makefile.in
    2045431580--- ncurses-5.7.orig/progs/Makefile.in  2008-09-07 06:58:55.000000000 -0700
    20455 +++ ncurses-5.7/progs/Makefile.in       2009-02-28 20:38:35.789873445 -0800
     31581+++ ncurses-5.7/progs/Makefile.in       2009-06-05 14:01:30.000000000 -0700
    2045631582@@ -1,6 +1,6 @@
    2045731583-# $Id: Makefile.in,v 1.79 2008/09/07 13:58:55 tom Exp $
    20458 +# $Id: Makefile.in,v 1.80 2008/11/15 19:04:19 tom Exp $
     31584+# $Id: Makefile.in,v 1.82 2009/03/28 20:30:58 tom Exp $
    2045931585 ##############################################################################
    2046031586-# Copyright (c) 1998-2006,2007 Free Software Foundation, Inc.                #
    20461 +# Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.                #
     31587+# Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.                #
    2046231588 #                                                                            #
    2046331589 # Permission is hereby granted, free of charge, to any person obtaining a    #
     
    2048031606 actual_toe       = `echo toe$x|       $(TRANSFORM)`
    2048131607 actual_tput      = `echo tput$x|      $(TRANSFORM)`
    20482 @@ -187,6 +188,7 @@
     31608@@ -171,10 +172,16 @@
     31609 define_reset     = `echo reset|       $(TRANSFORM)`
     31610 
     31611 transform.h :
     31612-       echo "#define PROG_CAPTOINFO \"$(define_captoinfo)\"" >$@
     31613-       echo "#define PROG_INFOTOCAP \"$(define_infotocap)\"" >>$@
     31614-       echo "#define PROG_RESET     \"$(define_reset)\""     >>$@
     31615-       echo "#define PROG_INIT      \"$(define_init)\""      >>$@
     31616+       echo "#ifndef __TRANSFORM_H"                                    >$@
     31617+       echo "#define __TRANSFORM_H 1"                                  >>$@
     31618+       echo "#include <progs.priv.h>"                                  >>$@
     31619+       echo "extern bool same_program(const char *, const char *);"    >>$@
     31620+       -sh -c 'if test -n "$x" ; then echo "#define SUFFIX_IGNORED \"$x\"">>$@; fi'
     31621+       echo "#define PROG_CAPTOINFO \"$(define_captoinfo)\""           >>$@
     31622+       echo "#define PROG_INFOTOCAP \"$(define_infotocap)\""           >>$@
     31623+       echo "#define PROG_RESET     \"$(define_reset)\""               >>$@
     31624+       echo "#define PROG_INIT      \"$(define_init)\""                >>$@
     31625+       echo "#endif /* __TRANSFORM_H */"                               >>$@
     31626 
     31627 install.progs: $(AUTO_SRC) $(PROGS) $(DESTDIR)$(bindir)
     31628 @MAKE_TERMINFO@        $(LIBTOOL_INSTALL) $(INSTALL_PROG) tic$x     $(DESTDIR)$(bindir)/$(actual_tic)
     31629@@ -187,6 +194,7 @@
    2048331630 @MAKE_TERMINFO@        (cd $(DESTDIR)$(bindir) && $(LN_S) $(actual_tic) $(actual_captoinfo))
    2048431631        $(LIBTOOL_INSTALL) $(INSTALL_PROG) infocmp$x $(DESTDIR)$(bindir)/$(actual_infocmp)
     
    2048831635        $(LIBTOOL_INSTALL) $(INSTALL_PROG) tset$x    $(DESTDIR)$(bindir)/$(actual_tset)
    2048931636        @echo "linking $(actual_reset) to $(actual_tset)"
    20490 @@ -200,6 +202,7 @@
     31637@@ -200,6 +208,7 @@
    2049131638 @MAKE_TERMINFO@        -@rm -f $(DESTDIR)$(bindir)/$(actual_infotocap)
    2049231639        -@$(LIBTOOL_CLEAN) rm -f $(DESTDIR)$(bindir)/$(actual_infocmp)
     
    2049631643        -@$(LIBTOOL_CLEAN) rm -f $(DESTDIR)$(bindir)/$(actual_tset)
    2049731644        -@rm -f $(DESTDIR)$(bindir)/$(actual_reset)
    20498 @@ -230,6 +233,12 @@
     31645@@ -213,7 +222,8 @@
     31646 
     31647 DEPS_TIC = \
     31648        $(MODEL)/tic$o \
     31649-       $(MODEL)/dump_entry$o
     31650+       $(MODEL)/dump_entry$o \
     31651+       $(MODEL)/transform$o
     31652 
     31653 tic$x: $(DEPS_TIC) $(DEPS_CURSES) transform.h
     31654        @ECHO_LINK@ $(LINK) $(DEPS_TIC) $(LDFLAGS_TIC) -o $@
     31655@@ -230,8 +240,15 @@
    2049931656 clear$x: $(DEPS_CLEAR) $(DEPS_CURSES)
    2050031657        @ECHO_LINK@ $(LINK) $(DEPS_CLEAR) $(LDFLAGS_TINFO) -o $@
     
    2050731664+
    2050831665 DEPS_TPUT = \
    20509         $(MODEL)/tput$o
    20510  
    20511 @@ -289,6 +298,7 @@
     31666-       $(MODEL)/tput$o
     31667+       $(MODEL)/tput$o \
     31668+       $(MODEL)/transform$o
     31669 
     31670 tput$x: $(DEPS_TPUT) $(DEPS_CURSES) transform.h
     31671        @ECHO_LINK@ $(LINK) $(DEPS_TPUT) $(LDFLAGS_TINFO) -o $@
     31672@@ -244,7 +261,8 @@
     31673        @ECHO_LINK@ $(LINK) $(DEPS_INFOCMP) $(LDFLAGS_TIC) -o $@
     31674 
     31675 DEPS_TSET = \
     31676-       $(MODEL)/tset$o
     31677+       $(MODEL)/tset$o \
     31678+       $(MODEL)/transform$o
     31679 
     31680 tset$x: $(DEPS_TSET) $(DEPS_CURSES) transform.h
     31681        @ECHO_LINK@ $(LINK) $(DEPS_TSET) $(LDFLAGS_TINFO) -o $@
     31682@@ -289,6 +307,7 @@
    2051231683 @MAKE_TERMINFO@        $(LINT) $(LINT_OPTS) $(CPPFLAGS) $(srcdir)/toe.c     $(srcdir)/dump_entry.c $(LINT_LIBS)
    2051331684        $(LINT) $(LINT_OPTS) $(CPPFLAGS) $(srcdir)/clear.c                          $(LINT_LIBS)
     
    2051931690diff -Naur ncurses-5.7.orig/progs/modules ncurses-5.7/progs/modules
    2052031691--- ncurses-5.7.orig/progs/modules      2006-12-23 16:53:21.000000000 -0800
    20521 +++ ncurses-5.7/progs/modules   2009-02-28 20:38:35.789873445 -0800
     31692+++ ncurses-5.7/progs/modules   2009-06-05 14:01:21.000000000 -0700
    2052231693@@ -1,7 +1,7 @@
    2052331694-# $Id: modules,v 1.13 2006/12/24 00:53:21 tom Exp $
    20524 +# $Id: modules,v 1.14 2008/11/15 16:26:48 tom Exp $
     31695+# $Id: modules,v 1.15 2009/03/14 18:45:55 tom Exp $
    2052531696 # Program modules (some are in ncurses lib!)
    2052631697 ##############################################################################
    2052731698-# Copyright (c) 1998-2005,2006 Free Software Foundation, Inc.                #
    20528 +# Copyright (c) 1998-2006,2008 Free Software Foundation, Inc.                #
     31699+# Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.                #
    2052931700 #                                                                            #
    2053031701 # Permission is hereby granted, free of charge, to any person obtaining a    #
    2053131702 # copy of this software and associated documentation files (the "Software"), #
    20532 @@ -37,6 +37,7 @@
     31703@@ -37,7 +37,9 @@
    2053331704 toe            progs           $(srcdir)       $(HEADER_DEPS)             $(srcdir)/dump_entry.h
    2053431705 dump_entry     progs           $(srcdir)       $(HEADER_DEPS)             $(srcdir)/dump_entry.h ../include/parametrized.h $(INCDIR)/capdefaults.c termsort.c
     
    2053731708 tput           progs           $(srcdir)       $(HEADER_DEPS) transform.h termsort.c
    2053831709 tset           progs           $(srcdir)       $(HEADER_DEPS) transform.h $(srcdir)/dump_entry.h ../include/termcap.h
    20539  
     31710+transform      progs           $(srcdir)       $(HEADER_DEPS)
     31711 
     31712 # vile:makemode
    2054031713diff -Naur ncurses-5.7.orig/progs/tabs.c ncurses-5.7/progs/tabs.c
    2054131714--- ncurses-5.7.orig/progs/tabs.c       1969-12-31 16:00:00.000000000 -0800
    20542 +++ ncurses-5.7/progs/tabs.c    2009-02-28 20:38:37.161961447 -0800
     31715+++ ncurses-5.7/progs/tabs.c    2009-06-05 14:00:52.000000000 -0700
    2054331716@@ -0,0 +1,506 @@
    2054431717+/****************************************************************************
     
    2104832221+    ExitProgram(rc);
    2104932222+}
     32223diff -Naur ncurses-5.7.orig/progs/tic.c ncurses-5.7/progs/tic.c
     32224--- ncurses-5.7.orig/progs/tic.c        2008-09-13 09:59:24.000000000 -0700
     32225+++ ncurses-5.7/progs/tic.c     2009-06-05 14:01:21.000000000 -0700
     32226@@ -1,5 +1,5 @@
     32227 /****************************************************************************
     32228- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     32229+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     32230  *                                                                          *
     32231  * Permission is hereby granted, free of charge, to any person obtaining a  *
     32232  * copy of this software and associated documentation files (the            *
     32233@@ -44,7 +44,7 @@
     32234 #include <dump_entry.h>
     32235 #include <transform.h>
     32236 
     32237-MODULE_ID("$Id: tic.c,v 1.137 2008/09/13 16:59:24 tom Exp $")
     32238+MODULE_ID("$Id: tic.c,v 1.138 2009/03/14 18:45:55 tom Exp $")
     32239 
     32240 const char *_nc_progname = "tic";
     32241 
     32242@@ -495,11 +495,11 @@
     32243 
     32244     _nc_progname = _nc_rootname(argv[0]);
     32245 
     32246-    if ((infodump = (strcmp(_nc_progname, PROG_CAPTOINFO) == 0)) != FALSE) {
     32247+    if ((infodump = same_program(_nc_progname, PROG_CAPTOINFO)) != FALSE) {
     32248        outform = F_TERMINFO;
     32249        sortmode = S_TERMINFO;
     32250     }
     32251-    if ((capdump = (strcmp(_nc_progname, PROG_INFOTOCAP) == 0)) != FALSE) {
     32252+    if ((capdump = same_program(_nc_progname, PROG_INFOTOCAP)) != FALSE) {
     32253        outform = F_TERMCAP;
     32254        sortmode = S_TERMCAP;
     32255     }
     32256diff -Naur ncurses-5.7.orig/progs/tput.c ncurses-5.7/progs/tput.c
     32257--- ncurses-5.7.orig/progs/tput.c       2008-07-13 04:05:12.000000000 -0700
     32258+++ ncurses-5.7/progs/tput.c    2009-06-05 14:01:21.000000000 -0700
     32259@@ -1,5 +1,5 @@
     32260 /****************************************************************************
     32261- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     32262+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     32263  *                                                                          *
     32264  * Permission is hereby granted, free of charge, to any person obtaining a  *
     32265  * copy of this software and associated documentation files (the            *
     32266@@ -47,7 +47,7 @@
     32267 #endif
     32268 #include <transform.h>
     32269 
     32270-MODULE_ID("$Id: tput.c,v 1.42 2008/07/13 11:05:12 tom Exp $")
     32271+MODULE_ID("$Id: tput.c,v 1.43 2009/03/14 18:45:55 tom Exp $")
     32272 
     32273 #define PUTS(s)                fputs(s, stdout)
     32274 #define PUTCHAR(c)     putchar(c)
     32275@@ -86,8 +86,8 @@
     32276 static void
     32277 check_aliases(const char *name)
     32278 {
     32279-    is_init = (strcmp(name, PROG_INIT) == 0);
     32280-    is_reset = (strcmp(name, PROG_RESET) == 0);
     32281+    is_init = same_program(name, PROG_INIT);
     32282+    is_reset = same_program(name, PROG_RESET);
     32283 }
     32284 
     32285 /*
     32286diff -Naur ncurses-5.7.orig/progs/transform.c ncurses-5.7/progs/transform.c
     32287--- ncurses-5.7.orig/progs/transform.c  1969-12-31 16:00:00.000000000 -0800
     32288+++ ncurses-5.7/progs/transform.c       2009-06-05 14:01:21.000000000 -0700
     32289@@ -0,0 +1,79 @@
     32290+/****************************************************************************
     32291+ * Copyright (c) 2009 Free Software Foundation, Inc.                        *
     32292+ *                                                                          *
     32293+ * Permission is hereby granted, free of charge, to any person obtaining a  *
     32294+ * copy of this software and associated documentation files (the            *
     32295+ * "Software"), to deal in the Software without restriction, including      *
     32296+ * without limitation the rights to use, copy, modify, merge, publish,      *
     32297+ * distribute, distribute with modifications, sublicense, and/or sell       *
     32298+ * copies of the Software, and to permit persons to whom the Software is    *
     32299+ * furnished to do so, subject to the following conditions:                 *
     32300+ *                                                                          *
     32301+ * The above copyright notice and this permission notice shall be included  *
     32302+ * in all copies or substantial portions of the Software.                   *
     32303+ *                                                                          *
     32304+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS  *
     32305+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF               *
     32306+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.   *
     32307+ * IN NO EVENT SHALL THE ABOVE COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,   *
     32308+ * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR    *
     32309+ * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR    *
     32310+ * THE USE OR OTHER DEALINGS IN THE SOFTWARE.                               *
     32311+ *                                                                          *
     32312+ * Except as contained in this notice, the name(s) of the above copyright   *
     32313+ * holders shall not be used in advertising or otherwise to promote the     *
     32314+ * sale, use or other dealings in this Software without prior written       *
     32315+ * authorization.                                                           *
     32316+ ****************************************************************************/
     32317+
     32318+/****************************************************************************
     32319+ *  Author: Thomas E. Dickey                                                *
     32320+ ****************************************************************************/
     32321+#include <progs.priv.h>
     32322+#include <string.h>
     32323+
     32324+#include <transform.h>
     32325+
     32326+MODULE_ID("$Id: transform.c,v 1.1 2009/03/14 19:08:28 tom Exp $")
     32327+
     32328+#ifdef SUFFIX_IGNORED
     32329+static void
     32330+trim_suffix(const char *a, unsigned *len)
     32331+{
     32332+    const char ignore[] = SUFFIX_IGNORED;
     32333+
     32334+    if (sizeof(ignore) != 0) {
     32335+       bool trim = FALSE;
     32336+       unsigned need = (sizeof(ignore) - 1);
     32337+
     32338+       if (*len > need) {
     32339+           unsigned first = *len - need;
     32340+           unsigned n;
     32341+           trim = TRUE;
     32342+           for (n = first; n < *len; ++n) {
     32343+               if (tolower(a[n]) != tolower(ignore[n - first])) {
     32344+                   trim = FALSE;
     32345+                   break;
     32346+               }
     32347+           }
     32348+           if (trim) {
     32349+               *len -= need;
     32350+           }
     32351+       }
     32352+    }
     32353+}
     32354+#else
     32355+#define trim_suffix(a, len) /* nothing */
     32356+#endif
     32357+
     32358+bool
     32359+same_program(const char *a, const char *b)
     32360+{
     32361+    unsigned len_a = strlen(a);
     32362+    unsigned len_b = strlen(b);
     32363+
     32364+    trim_suffix(a, &len_a);
     32365+    trim_suffix(b, &len_b);
     32366+
     32367+    return (len_a == len_b) && (strncmp(a, b, len_a) == 0);
     32368+}
     32369diff -Naur ncurses-5.7.orig/progs/tset.c ncurses-5.7/progs/tset.c
     32370--- ncurses-5.7.orig/progs/tset.c       2008-10-11 12:26:19.000000000 -0700
     32371+++ ncurses-5.7/progs/tset.c    2009-06-05 14:01:21.000000000 -0700
     32372@@ -1,5 +1,5 @@
     32373 /****************************************************************************
     32374- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     32375+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     32376  *                                                                          *
     32377  * Permission is hereby granted, free of charge, to any person obtaining a  *
     32378  * copy of this software and associated documentation files (the            *
     32379@@ -107,7 +107,7 @@
     32380 #include <dump_entry.h>
     32381 #include <transform.h>
     32382 
     32383-MODULE_ID("$Id: tset.c,v 1.76 2008/10/11 19:26:19 tom Exp $")
     32384+MODULE_ID("$Id: tset.c,v 1.77 2009/03/14 19:08:35 tom Exp $")
     32385 
     32386 /*
     32387  * SCO defines TIOCGSIZE and the corresponding struct.  Other systems (SunOS,
     32388@@ -1247,7 +1247,7 @@
     32389     ospeed = (NCURSES_OSPEED) mode.sg_ospeed;
     32390 #endif
     32391 
     32392-    if (!strcmp(_nc_progname, PROG_RESET)) {
     32393+    if (same_program(_nc_progname, PROG_RESET)) {
     32394        isreset = TRUE;
     32395        reset_mode();
     32396     }
     32397diff -Naur ncurses-5.7.orig/test/aclocal.m4 ncurses-5.7/test/aclocal.m4
     32398--- ncurses-5.7.orig/test/aclocal.m4    2008-02-09 10:22:17.000000000 -0800
     32399+++ ncurses-5.7/test/aclocal.m4 2009-06-05 14:01:30.000000000 -0700
     32400@@ -1,5 +1,5 @@
     32401 dnl***************************************************************************
     32402-dnl Copyright (c) 2003-2007,2008 Free Software Foundation, Inc.              *
     32403+dnl Copyright (c) 2003-2008,2009 Free Software Foundation, Inc.              *
     32404 dnl                                                                          *
     32405 dnl Permission is hereby granted, free of charge, to any person obtaining a  *
     32406 dnl copy of this software and associated documentation files (the            *
     32407@@ -26,7 +26,7 @@
     32408 dnl authorization.                                                           *
     32409 dnl***************************************************************************
     32410 dnl
     32411-dnl $Id: aclocal.m4,v 1.22 2008/02/09 18:22:17 tom Exp $
     32412+dnl $Id: aclocal.m4,v 1.25 2009/03/28 20:09:37 tom Exp $
     32413 dnl
     32414 dnl Author: Thomas E. Dickey
     32415 dnl
     32416@@ -40,7 +40,7 @@
     32417 dnl
     32418 dnl ---------------------------------------------------------------------------
     32419 dnl ---------------------------------------------------------------------------
     32420-dnl CF_ADD_CFLAGS version: 7 updated: 2004/04/25 17:48:30
     32421+dnl CF_ADD_CFLAGS version: 8 updated: 2009/01/06 19:33:30
     32422 dnl -------------
     32423 dnl Copy non-preprocessor flags to $CFLAGS, preprocessor flags to $CPPFLAGS
     32424 dnl The second parameter if given makes this macro verbose.
     32425@@ -110,7 +110,7 @@
     32426 
     32427 if test -n "$cf_new_cppflags" ; then
     32428        ifelse($2,,,[CF_VERBOSE(add to \$CPPFLAGS $cf_new_cppflags)])
     32429-       CPPFLAGS="$cf_new_cppflags $CPPFLAGS"
     32430+       CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
     32431 fi
     32432 
     32433 if test -n "$cf_new_extra_cppflags" ; then
     32434@@ -122,7 +122,7 @@
     32435 
     32436 ])dnl
     32437 dnl ---------------------------------------------------------------------------
     32438-dnl CF_ADD_INCDIR version: 9 updated: 2008/02/09 13:15:34
     32439+dnl CF_ADD_INCDIR version: 12 updated: 2009/01/18 10:00:47
     32440 dnl -------------
     32441 dnl Add an include-directory to $CPPFLAGS.  Don't add /usr/include, since it's
     32442 dnl redundant.  We don't normally need to add -I/usr/local/include for gcc,
     32443@@ -149,7 +149,7 @@
     32444                fi
     32445 
     32446                if test "$cf_have_incdir" = no ; then
     32447-          if test "$cf_add_incdir" = /usr/local/include ; then
     32448+                 if test "$cf_add_incdir" = /usr/local/include ; then
     32449                        if test "$GCC" = yes
     32450                        then
     32451                          cf_save_CPPFLAGS=$CPPFLAGS
     32452@@ -165,11 +165,11 @@
     32453 
     32454                if test "$cf_have_incdir" = no ; then
     32455                  CF_VERBOSE(adding $cf_add_incdir to include-path)
     32456-                 ifelse($2,,CPPFLAGS,$2)="-I$cf_add_incdir $ifelse($2,,CPPFLAGS,[$]$2)"
     32457+                 ifelse($2,,CPPFLAGS,$2)="$ifelse($2,,CPPFLAGS,$2) -I$cf_add_incdir"
     32458 
     32459-          cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     32460-          test "$cf_top_incdir" = "$cf_add_incdir" && break
     32461-          cf_add_incdir="$cf_top_incdir"
     32462+                 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     32463+                 test "$cf_top_incdir" = "$cf_add_incdir" && break
     32464+                 cf_add_incdir="$cf_top_incdir"
     32465                else
     32466                  break
     32467                fi
     32468@@ -179,7 +179,7 @@
     32469 fi
     32470 ])dnl
     32471 dnl ---------------------------------------------------------------------------
     32472-dnl CF_ADD_LIBDIR version: 6 updated: 2008/02/09 13:15:34
     32473+dnl CF_ADD_LIBDIR version: 8 updated: 2009/01/18 10:01:08
     32474 dnl -------------
     32475 dnl    Adds to the library-path
     32476 dnl
     32477@@ -208,7 +208,7 @@
     32478       fi
     32479       if test "$cf_have_libdir" = no ; then
     32480         CF_VERBOSE(adding $cf_add_libdir to library-path)
     32481-        ifelse($2,,LDFLAGS,$2)="-L$cf_add_libdir $ifelse($2,,LDFLAGS,[$]$2)"
     32482+        ifelse($2,,LDFLAGS,$2)="-L$cf_add_libdir $ifelse($2,,LDFLAGS,$2)"
     32483       fi
     32484     fi
     32485   done
     32486@@ -289,7 +289,7 @@
     32487 fi
     32488 ])dnl
     32489 dnl ---------------------------------------------------------------------------
     32490-dnl CF_ANSI_CC_REQD version: 3 updated: 1997/09/06 13:40:44
     32491+dnl CF_ANSI_CC_REQD version: 4 updated: 2008/03/23 14:48:54
     32492 dnl ---------------
     32493 dnl For programs that must use an ANSI compiler, obtain compiler options that
     32494 dnl will make it recognize prototypes.  We'll do preprocessor checks in other
     32495@@ -298,7 +298,7 @@
     32496 AC_DEFUN([CF_ANSI_CC_REQD],
     32497 [AC_REQUIRE([CF_ANSI_CC_CHECK])
     32498 if test "$cf_cv_ansi_cc" = "no"; then
     32499-       AC_ERROR(
     32500+       AC_MSG_ERROR(
     32501 [Your compiler does not appear to recognize prototypes.
     32502 You have the following choices:
     32503        a. adjust your compiler options
     32504@@ -342,7 +342,7 @@
     32505 ])dnl
     32506   ])])dnl
     32507 dnl ---------------------------------------------------------------------------
     32508-dnl CF_CHECK_CACHE version: 10 updated: 2004/05/23 13:03:31
     32509+dnl CF_CHECK_CACHE version: 11 updated: 2008/03/23 14:45:59
     32510 dnl --------------
     32511 dnl Check if we're accidentally using a cache from a different machine.
     32512 dnl Derive the system name, as a check for reusing the autoconf cache.
     32513@@ -373,7 +373,7 @@
     32514 
     32515 if test ".$system_name" != ".$cf_cv_system_name" ; then
     32516        AC_MSG_RESULT(Cached system name ($system_name) does not agree with actual ($cf_cv_system_name))
     32517-       AC_ERROR("Please remove config.cache and try again.")
     32518+       AC_MSG_ERROR("Please remove config.cache and try again.")
     32519 fi
     32520 ])dnl
     32521 dnl ---------------------------------------------------------------------------
     32522@@ -399,14 +399,15 @@
     32523 fi
     32524 ])dnl
     32525 dnl ---------------------------------------------------------------------------
     32526-dnl CF_CURSES_ACS_MAP version: 3 updated: 2003/05/17 22:19:02
     32527+dnl CF_CURSES_ACS_MAP version: 5 updated: 2009/03/28 16:08:10
     32528 dnl -----------------
     32529 dnl Check for likely values of acs_map[]:
     32530 AC_DEFUN([CF_CURSES_ACS_MAP],
     32531 [
     32532+AC_REQUIRE([CF_NCURSES_WRAP_PREFIX])dnl
     32533 AC_CACHE_CHECK(for alternate character set array, cf_cv_curses_acs_map,[
     32534 cf_cv_curses_acs_map=unknown
     32535-for name in acs_map _acs_map __acs_map _nc_acs_map
     32536+for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map
     32537 do
     32538 AC_TRY_LINK([
     32539 #include <${cf_cv_ncurses_header-curses.h}>
     32540@@ -441,7 +442,7 @@
     32541 fi
     32542 ])dnl
     32543 dnl ---------------------------------------------------------------------------
     32544-dnl CF_CURSES_CPPFLAGS version: 9 updated: 2006/02/04 19:44:43
     32545+dnl CF_CURSES_CPPFLAGS version: 10 updated: 2009/01/06 19:34:11
     32546 dnl ------------------
     32547 dnl Look for the curses headers.
     32548 AC_DEFUN([CF_CURSES_CPPFLAGS],[
     32549@@ -460,7 +461,7 @@
     32550        ;;
     32551 esac
     32552 ])
     32553-test "$cf_cv_curses_incdir" != no && CPPFLAGS="$cf_cv_curses_incdir $CPPFLAGS"
     32554+test "$cf_cv_curses_incdir" != no && CPPFLAGS="$CPPFLAGS $cf_cv_curses_incdir"
     32555 
     32556 CF_CURSES_HEADER
     32557 CF_TERM_HEADER
     32558@@ -549,7 +550,7 @@
     32559 AC_CHECK_HEADERS($cf_cv_ncurses_header)
     32560 ])dnl
     32561 dnl ---------------------------------------------------------------------------
     32562-dnl CF_CURSES_LIBS version: 26 updated: 2007/07/29 10:32:40
     32563+dnl CF_CURSES_LIBS version: 29 updated: 2009/01/06 19:34:57
     32564 dnl --------------
     32565 dnl Look for the curses libraries.  Older curses implementations may require
     32566 dnl termcap/termlib to be linked as well.  Call CF_CURSES_CPPFLAGS first.
     32567@@ -576,7 +577,7 @@
     32568     AC_CHECK_LIB(Hcurses,initscr,[
     32569         # HP's header uses __HP_CURSES, but user claims _HP_CURSES.
     32570         LIBS="-lHcurses $LIBS"
     32571-        CPPFLAGS="-D__HP_CURSES -D_HP_CURSES $CPPFLAGS"
     32572+        CPPFLAGS="$CPPFLAGS -D__HP_CURSES -D_HP_CURSES"
     32573         ac_cv_func_initscr=yes
     32574         ])])
     32575     ;;
     32576@@ -615,11 +616,11 @@
     32577 
     32578     # Check for library containing initscr
     32579     test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS"
     32580-    for cf_curs_lib in $cf_check_list xcurses jcurses unknown
     32581+       for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown
     32582     do
     32583         AC_CHECK_LIB($cf_curs_lib,initscr,[break])
     32584     done
     32585-    test $cf_curs_lib = unknown && AC_ERROR(no curses library found)
     32586+    test $cf_curs_lib = unknown && AC_MSG_ERROR(no curses library found)
     32587 
     32588     LIBS="-l$cf_curs_lib $cf_save_LIBS"
     32589     if test "$cf_term_lib" = unknown ; then
     32590@@ -629,7 +630,7 @@
     32591             [cf_result=yes],
     32592             [cf_result=no])
     32593         AC_MSG_RESULT($cf_result)
     32594-        test $cf_result = no && AC_ERROR(Cannot link curses library)
     32595+        test $cf_result = no && AC_MSG_ERROR(Cannot link curses library)
     32596     elif test "$cf_curs_lib" = "$cf_term_lib" ; then
     32597         :
     32598     elif test "$cf_term_lib" != predefined ; then
     32599@@ -772,7 +773,7 @@
     32600 fi
     32601 ])dnl
     32602 dnl ---------------------------------------------------------------------------
     32603-dnl CF_FIND_LIBRARY version: 8 updated: 2004/11/23 20:14:58
     32604+dnl CF_FIND_LIBRARY version: 9 updated: 2008/03/23 14:48:54
     32605 dnl ---------------
     32606 dnl Look for a non-standard library, given parameters for AC_TRY_LINK.  We
     32607 dnl prefer a standard location, and use -L options only if we do not find the
     32608@@ -817,11 +818,124 @@
     32609 eval 'cf_found_library=[$]cf_cv_have_lib_'$1
     32610 ifelse($6,,[
     32611 if test $cf_found_library = no ; then
     32612-       AC_ERROR(Cannot link $1 library)
     32613+       AC_MSG_ERROR(Cannot link $1 library)
     32614 fi
     32615 ])
     32616 ])dnl
     32617 dnl ---------------------------------------------------------------------------
     32618+dnl CF_FIND_LINKAGE version: 13 updated: 2008/12/24 07:59:55
     32619+dnl ---------------
     32620+dnl Find a library (specifically the linkage used in the code fragment),
     32621+dnl searching for it if it is not already in the library path.
     32622+dnl See also CF_ADD_SEARCHPATH.
     32623+dnl
     32624+dnl Parameters (4-on are optional):
     32625+dnl     $1 = headers for library entrypoint
     32626+dnl     $2 = code fragment for library entrypoint
     32627+dnl     $3 = the library name without the "-l" option or ".so" suffix.
     32628+dnl     $4 = action to perform if successful (default: update CPPFLAGS, etc)
     32629+dnl     $5 = action to perform if not successful
     32630+dnl     $6 = module name, if not the same as the library name
     32631+dnl     $7 = extra libraries
     32632+dnl
     32633+dnl Sets these variables:
     32634+dnl     $cf_cv_find_linkage_$3 - yes/no according to whether linkage is found
     32635+dnl     $cf_cv_header_path_$3 - include-directory if needed
     32636+dnl     $cf_cv_library_path_$3 - library-directory if needed
     32637+dnl     $cf_cv_library_file_$3 - library-file if needed, e.g., -l$3
     32638+AC_DEFUN([CF_FIND_LINKAGE],[
     32639+
     32640+# If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
     32641+# will be set on completion of the AC_TRY_LINK below.
     32642+cf_cv_header_path_$3=
     32643+cf_cv_library_path_$3=
     32644+
     32645+CF_MSG_LOG([Starting [FIND_LINKAGE]($3,$6)])
     32646+
     32647+AC_TRY_LINK([$1],[$2],
     32648+    cf_cv_find_linkage_$3=yes,[
     32649+    cf_cv_find_linkage_$3=no
     32650+
     32651+    CF_VERBOSE(find linkage for $3 library)
     32652+    CF_MSG_LOG([Searching for headers in [FIND_LINKAGE]($3,$6)])
     32653+
     32654+    cf_save_CPPFLAGS="$CPPFLAGS"
     32655+    cf_test_CPPFLAGS="$CPPFLAGS"
     32656+
     32657+    CF_HEADER_PATH(cf_search,ifelse([$6],,[$3],[$6]))
     32658+    for cf_cv_header_path_$3 in $cf_search
     32659+    do
     32660+      if test -d $cf_cv_header_path_$3 ; then
     32661+        CF_VERBOSE(... testing $cf_cv_header_path_$3)
     32662+        CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_$3"
     32663+        AC_TRY_COMPILE([$1],[$2],[
     32664+            CF_VERBOSE(... found $3 headers in $cf_cv_header_path_$3)
     32665+            cf_cv_find_linkage_$3=maybe
     32666+            cf_test_CPPFLAGS="$CPPFLAGS"
     32667+            break],[
     32668+            CPPFLAGS="$cf_save_CPPFLAGS"
     32669+            ])
     32670+      fi
     32671+    done
     32672+
     32673+    if test "$cf_cv_find_linkage_$3" = maybe ; then
     32674+
     32675+      CF_MSG_LOG([Searching for $3 library in [FIND_LINKAGE]($3,$6)])
     32676+
     32677+      cf_save_LIBS="$LIBS"
     32678+      cf_save_LDFLAGS="$LDFLAGS"
     32679+
     32680+      ifelse([$6],,,[
     32681+        CPPFLAGS="$cf_test_CPPFLAGS"
     32682+        LIBS="-l$3 $7 $cf_save_LIBS"
     32683+        AC_TRY_LINK([$1],[$2],[
     32684+            CF_VERBOSE(... found $3 library in system)
     32685+            cf_cv_find_linkage_$3=yes])
     32686+            CPPFLAGS="$cf_save_CPPFLAGS"
     32687+            LIBS="$cf_save_LIBS"
     32688+            ])
     32689+
     32690+      if test "$cf_cv_find_linkage_$3" != yes ; then
     32691+        CF_LIBRARY_PATH(cf_search,$3)
     32692+        for cf_cv_library_path_$3 in $cf_search
     32693+        do
     32694+          if test -d $cf_cv_library_path_$3 ; then
     32695+            CF_VERBOSE(... testing $cf_cv_library_path_$3)
     32696+            CPPFLAGS="$cf_test_CPPFLAGS"
     32697+            LIBS="-l$3 $7 $cf_save_LIBS"
     32698+            LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_$3"
     32699+            AC_TRY_LINK([$1],[$2],[
     32700+                CF_VERBOSE(... found $3 library in $cf_cv_library_path_$3)
     32701+                cf_cv_find_linkage_$3=yes
     32702+                cf_cv_library_file_$3="-l$3"
     32703+                break],[
     32704+                CPPFLAGS="$cf_save_CPPFLAGS"
     32705+                LIBS="$cf_save_LIBS"
     32706+                LDFLAGS="$cf_save_LDFLAGS"
     32707+                ])
     32708+          fi
     32709+        done
     32710+        LIBS="$cf_save_LIBS"
     32711+        CPPFLAGS="$cf_save_CPPFLAGS"
     32712+        LDFLAGS="$cf_save_LDFLAGS"
     32713+      fi
     32714+
     32715+    else
     32716+      cf_cv_find_linkage_$3=no
     32717+    fi
     32718+    ],$7)
     32719+
     32720+if test "$cf_cv_find_linkage_$3" = yes ; then
     32721+ifelse([$4],,[
     32722+  CF_ADD_INCDIR($cf_cv_header_path_$3)
     32723+  CF_ADD_LIBDIR($cf_cv_library_path_$3)
     32724+  LIBS="-l$3 $LIBS"
     32725+],[$4])
     32726+else
     32727+ifelse([$5],,AC_MSG_WARN(Cannot find $3 library),[$5])
     32728+fi
     32729+])dnl
     32730+dnl ---------------------------------------------------------------------------
     32731 dnl CF_FUNC_CURSES_VERSION version: 4 updated: 2007/04/28 09:15:55
     32732 dnl ----------------------
     32733 dnl Solaris has a data item 'curses_version', which confuses AC_CHECK_FUNCS.
     32734@@ -933,7 +1047,7 @@
     32735 fi
     32736 ])dnl
     32737 dnl ---------------------------------------------------------------------------
     32738-dnl CF_GCC_WARNINGS version: 22 updated: 2007/07/29 09:55:12
     32739+dnl CF_GCC_WARNINGS version: 24 updated: 2009/02/01 15:21:00
     32740 dnl ---------------
     32741 dnl Check if the compiler supports useful warning options.  There's a few that
     32742 dnl we don't use, simply because they're too noisy:
     32743@@ -966,7 +1080,6 @@
     32744 then
     32745 # The "-wdXXX" options suppress warnings:
     32746 # remark #1419: external declaration in primary source file
     32747-# remark #1682: implicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
     32748 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
     32749 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
     32750 # remark #193: zero used for undefined preprocessing identifier
     32751@@ -974,19 +1087,18 @@
     32752 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
     32753 # remark #869: parameter "tw" was never referenced
     32754 # remark #981: operands are evaluated in unspecified order
     32755-# warning #269: invalid format string conversion
     32756+# warning #279: controlling expression is constant
     32757 
     32758        AC_CHECKING([for $CC warning options])
     32759        cf_save_CFLAGS="$CFLAGS"
     32760        EXTRA_CFLAGS="-Wall"
     32761        for cf_opt in \
     32762                wd1419 \
     32763-               wd1682 \
     32764                wd1683 \
     32765                wd1684 \
     32766                wd193 \
     32767-               wd279 \
     32768                wd593 \
     32769+               wd279 \
     32770                wd810 \
     32771                wd869 \
     32772                wd981
     32773@@ -1028,7 +1140,7 @@
     32774                                ;;
     32775                        Winline) #(vi
     32776                                case $GCC_VERSION in
     32777-                               3.3*)
     32778+                               [[34]].*)
     32779                                        CF_VERBOSE(feature is broken in gcc $GCC_VERSION)
     32780                                        continue;;
     32781                                esac
     32782@@ -1074,11 +1186,31 @@
     32783 test "$cf_cv_gnu_source" = yes && CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
     32784 ])dnl
     32785 dnl ---------------------------------------------------------------------------
     32786-dnl CF_HEADER_PATH version: 8 updated: 2002/11/10 14:46:59
     32787+dnl CF_HEADER_PATH version: 9 updated: 2008/12/07 19:38:31
     32788 dnl --------------
     32789-dnl Construct a search-list for a nonstandard header-file
     32790+dnl Construct a search-list of directories for a nonstandard header-file
     32791+dnl
     32792+dnl Parameters
     32793+dnl    $1 = the variable to return as result
     32794+dnl    $2 = the package name
     32795 AC_DEFUN([CF_HEADER_PATH],
     32796-[CF_SUBDIR_PATH($1,$2,include)
     32797+[
     32798+cf_header_path_list=""
     32799+if test -n "${CFLAGS}${CPPFLAGS}" ; then
     32800+       for cf_header_path in $CPPFLAGS $CFLAGS
     32801+       do
     32802+               case $cf_header_path in #(vi
     32803+               -I*)
     32804+                       cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
     32805+                       CF_ADD_SUBDIR_PATH($1,$2,include,$cf_header_path,NONE)
     32806+                       cf_header_path_list="$cf_header_path_list [$]$1"
     32807+                       ;;
     32808+               esac
     32809+       done
     32810+fi
     32811+
     32812+CF_SUBDIR_PATH($1,$2,include)
     32813+
     32814 test "$includedir" != NONE && \
     32815 test "$includedir" != "/usr/include" && \
     32816 test -d "$includedir" && {
     32817@@ -1093,6 +1225,7 @@
     32818        test -d $oldincludedir/$2 && $1="[$]$1 $oldincludedir/$2"
     32819 }
     32820 
     32821+$1="$cf_header_path_list [$]$1"
     32822 ])dnl
     32823 dnl ---------------------------------------------------------------------------
     32824 dnl CF_INHERIT_SCRIPT version: 2 updated: 2003/03/01 23:50:42
     32825@@ -1140,11 +1273,33 @@
     32826 fi
     32827 ])dnl
     32828 dnl ---------------------------------------------------------------------------
     32829-dnl CF_LIBRARY_PATH version: 7 updated: 2002/11/10 14:46:59
     32830+dnl CF_LIBRARY_PATH version: 8 updated: 2008/12/07 19:38:31
     32831 dnl ---------------
     32832-dnl Construct a search-list for a nonstandard library-file
     32833+dnl Construct a search-list of directories for a nonstandard library-file
     32834+dnl
     32835+dnl Parameters
     32836+dnl    $1 = the variable to return as result
     32837+dnl    $2 = the package name
     32838 AC_DEFUN([CF_LIBRARY_PATH],
     32839-[CF_SUBDIR_PATH($1,$2,lib)])dnl
     32840+[
     32841+cf_library_path_list=""
     32842+if test -n "${LDFLAGS}${LIBS}" ; then
     32843+       for cf_library_path in $LDFLAGS $LIBS
     32844+       do
     32845+               case $cf_library_path in #(vi
     32846+               -L*)
     32847+                       cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
     32848+                       CF_ADD_SUBDIR_PATH($1,$2,lib,$cf_library_path,NONE)
     32849+                       cf_library_path_list="$cf_library_path_list [$]$1"
     32850+                       ;;
     32851+               esac
     32852+       done
     32853+fi
     32854+
     32855+CF_SUBDIR_PATH($1,$2,lib)
     32856+
     32857+$1="$cf_library_path_list [$]$1"
     32858+])dnl
     32859 dnl ---------------------------------------------------------------------------
     32860 dnl CF_MSG_LOG version: 4 updated: 2007/07/29 09:55:12
     32861 dnl ----------
     32862@@ -1187,6 +1342,45 @@
     32863        ,[$1=no])
     32864 ])dnl
     32865 dnl ---------------------------------------------------------------------------
     32866+dnl CF_NCURSES_CONFIG version: 5 updated: 2009/01/11 15:31:22
     32867+dnl -----------------
     32868+dnl Tie together the configure-script macros for ncurses.
     32869+dnl Prefer the "-config" script from ncurses 5.6, to simplify analysis.
     32870+dnl Allow that to be overridden using the $NCURSES_CONFIG environment variable.
     32871+dnl
     32872+dnl $1 is the root library name (default: "ncurses")
     32873+AC_DEFUN([CF_NCURSES_CONFIG],
     32874+[
     32875+cf_ncuconfig_root=ifelse($1,,ncurses,$1)
     32876+
     32877+echo "Looking for ${cf_ncuconfig_root}-config"
     32878+AC_PATH_PROGS(NCURSES_CONFIG,${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config,none)
     32879+
     32880+if test "$NCURSES_CONFIG" != none ; then
     32881+
     32882+cf_cv_ncurses_header=curses.h
     32883+
     32884+CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
     32885+LIBS="`$NCURSES_CONFIG --libs` $LIBS"
     32886+
     32887+dnl like CF_NCURSES_CPPFLAGS
     32888+AC_DEFINE(NCURSES)
     32889+
     32890+dnl like CF_NCURSES_LIBS
     32891+CF_UPPER(cf_nculib_ROOT,HAVE_LIB$cf_ncuconfig_root)
     32892+AC_DEFINE_UNQUOTED($cf_nculib_ROOT)
     32893+
     32894+dnl like CF_NCURSES_VERSION
     32895+cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
     32896+
     32897+else
     32898+
     32899+CF_NCURSES_CPPFLAGS(ifelse($1,,ncurses,$1))
     32900+CF_NCURSES_LIBS(ifelse($1,,ncurses,$1))
     32901+
     32902+fi
     32903+])dnl
     32904+dnl ---------------------------------------------------------------------------
     32905 dnl CF_NCURSES_CPPFLAGS version: 19 updated: 2007/07/29 13:35:20
     32906 dnl -------------------
     32907 dnl Look for the SVr4 curses clone 'ncurses' in the standard places, adjusting
     32908@@ -1238,7 +1432,7 @@
     32909 CF_NCURSES_VERSION
     32910 ])dnl
     32911 dnl ---------------------------------------------------------------------------
     32912-dnl CF_NCURSES_HEADER version: 1 updated: 2005/12/31 13:28:37
     32913+dnl CF_NCURSES_HEADER version: 2 updated: 2008/03/23 14:48:54
     32914 dnl -----------------
     32915 dnl Find a "curses" header file, e.g,. "curses.h", or one of the more common
     32916 dnl variations of ncurses' installs.
     32917@@ -1273,7 +1467,7 @@
     32918                CPPFLAGS="$cf_save2_CPPFLAGS"
     32919                test "$cf_cv_ncurses_h2" != no && break
     32920        done
     32921-       test "$cf_cv_ncurses_h2" = no && AC_ERROR(not found)
     32922+       test "$cf_cv_ncurses_h2" = no && AC_MSG_ERROR(not found)
     32923        ])
     32924 
     32925        CF_DIRNAME(cf_1st_incdir,$cf_cv_ncurses_h2)
     32926@@ -1435,7 +1629,23 @@
     32927 test "$cf_cv_ncurses_version" = no || AC_DEFINE(NCURSES)
     32928 ])dnl
     32929 dnl ---------------------------------------------------------------------------
     32930-dnl CF_PATH_SYNTAX version: 11 updated: 2006/09/02 08:55:46
     32931+dnl CF_NCURSES_WRAP_PREFIX version: 1 updated: 2009/03/28 16:08:10
     32932+dnl ----------------------
     32933+dnl Check for ncurses "wrap-prefix" used for public variables which have been
     32934+dnl wrapped with a function to help with concurrency control.
     32935+AC_DEFUN([CF_NCURSES_WRAP_PREFIX],
     32936+[
     32937+AC_MSG_CHECKING(for ncurses wrap-prefix)
     32938+AC_ARG_WITH(ncurses-wrap-prefix,
     32939+       [  --with-ncurses-wrap-prefix naming-prefix for ncurses wrapped-variables],
     32940+       [NCURSES_WRAP_PREFIX=$withval],
     32941+       [NCURSES_WRAP_PREFIX=_nc_])
     32942+AC_MSG_RESULT($NCURSES_WRAP_PREFIX)
     32943+
     32944+AC_SUBST(NCURSES_WRAP_PREFIX)
     32945+])
     32946+dnl ---------------------------------------------------------------------------
     32947+dnl CF_PATH_SYNTAX version: 12 updated: 2008/03/23 14:45:59
     32948 dnl --------------
     32949 dnl Check the argument to see that it looks like a pathname.  Rewrite it if it
     32950 dnl begins with one of the prefix/exec_prefix variables, and then again if the
     32951@@ -1467,12 +1677,12 @@
     32952   $1=`echo [$]$1 | sed -e s%NONE%$cf_path_syntax%`
     32953   ;;
     32954 *)
     32955-  ifelse($2,,[AC_ERROR([expected a pathname, not \"[$]$1\"])],$2)
     32956+  ifelse($2,,[AC_MSG_ERROR([expected a pathname, not \"[$]$1\"])],$2)
     32957   ;;
     32958 esac
     32959 ])dnl
     32960 dnl ---------------------------------------------------------------------------
     32961-dnl CF_PDCURSES_X11 version: 7 updated: 2006/11/12 17:31:59
     32962+dnl CF_PDCURSES_X11 version: 9 updated: 2009/01/11 15:31:37
     32963 dnl ---------------
     32964 dnl Configure for PDCurses' X11 library
     32965 AC_DEFUN([CF_PDCURSES_X11],[
     32966@@ -1482,7 +1692,7 @@
     32967 
     32968 if test "$XCURSES_CONFIG" != none ; then
     32969 
     32970-CPPFLAGS="`$XCURSES_CONFIG --cflags` $CPPFLAGS"
     32971+CPPFLAGS="$CPPFLAGS `$XCURSES_CONFIG --cflags`"
     32972 LIBS="`$XCURSES_CONFIG --libs` $LIBS"
     32973 
     32974 cf_cv_lib_XCurses=yes
     32975@@ -1511,7 +1721,7 @@
     32976        AC_DEFINE(XCURSES)
     32977        AC_DEFINE(HAVE_XCURSES)
     32978 else
     32979-       AC_ERROR(Cannot link with XCurses)
     32980+       AC_MSG_ERROR(Cannot link with XCurses)
     32981 fi
     32982 ])dnl
     32983 dnl ---------------------------------------------------------------------------
     32984@@ -1790,7 +2000,7 @@
     32985 $1=`echo "$2" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
     32986 ])dnl
     32987 dnl ---------------------------------------------------------------------------
     32988-dnl CF_UTF8_LIB version: 4 updated: 2003/03/01 18:36:42
     32989+dnl CF_UTF8_LIB version: 5 updated: 2008/10/17 19:37:52
     32990 dnl -----------
     32991 dnl Check for multibyte support, and if not found, utf8 compatibility library
     32992 AC_DEFUN([CF_UTF8_LIB],
     32993@@ -1800,18 +2010,18 @@
     32994        AC_TRY_LINK([
     32995 #include <stdlib.h>],[putwc(0,0);],
     32996        [cf_cv_utf8_lib=yes],
     32997-       [LIBS="-lutf8 $LIBS"
     32998-        AC_TRY_LINK([
     32999-#include <libutf8.h>],[putwc(0,0);],
     33000+       [CF_FIND_LINKAGE([
     33001+#include <libutf8.h>],[putwc(0,0);],utf8,
     33002                [cf_cv_utf8_lib=add-on],
     33003                [cf_cv_utf8_lib=no])
     33004-       LIBS="$cf_save_LIBS"
     33005 ])])
     33006 
     33007 # HAVE_LIBUTF8_H is used by ncurses if curses.h is shared between
     33008 # ncurses/ncursesw:
     33009 if test "$cf_cv_utf8_lib" = "add-on" ; then
     33010        AC_DEFINE(HAVE_LIBUTF8_H)
     33011+       CF_ADD_INCDIR($cf_cv_header_path_utf8)
     33012+       CF_ADD_LIBDIR($cf_cv_library_path_utf8)
     33013        LIBS="-lutf8 $LIBS"
     33014 fi
     33015 ])dnl
     33016@@ -1866,7 +2076,7 @@
     33017 test $cf_cv_need_xopen_extension = yes && CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE_EXTENDED"
     33018 ])dnl
     33019 dnl ---------------------------------------------------------------------------
     33020-dnl CF_XOPEN_SOURCE version: 25 updated: 2007/01/29 18:36:38
     33021+dnl CF_XOPEN_SOURCE version: 28 updated: 2008/12/27 12:30:03
     33022 dnl ---------------
     33023 dnl Try to get _XOPEN_SOURCE defined properly that we can use POSIX functions,
     33024 dnl or adapt to the vendor's definitions to get equivalent functionality,
     33025@@ -1883,10 +2093,10 @@
     33026 cf_POSIX_C_SOURCE=ifelse($2,,199506L,$2)
     33027 
     33028 case $host_os in #(vi
     33029-aix[[45]]*) #(vi
     33030+aix[[456]]*) #(vi
     33031        CPPFLAGS="$CPPFLAGS -D_ALL_SOURCE"
     33032        ;;
     33033-freebsd*) #(vi
     33034+freebsd*|dragonfly*) #(vi
     33035        # 5.x headers associate
     33036        #       _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
     33037        #       _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
     33038@@ -1900,7 +2110,7 @@
     33039 irix[[56]].*) #(vi
     33040        CPPFLAGS="$CPPFLAGS -D_SGI_SOURCE"
     33041        ;;
     33042-linux*|gnu*|k*bsd*-gnu) #(vi
     33043+linux*|gnu*|mint*|k*bsd*-gnu) #(vi
     33044        CF_GNU_SOURCE
     33045        ;;
     33046 mirbsd*) #(vi
     33047@@ -2005,7 +2215,7 @@
     33048 CF_X_ATHENA_LIBS($cf_x_athena)
     33049 ])dnl
     33050 dnl ---------------------------------------------------------------------------
     33051-dnl CF_X_ATHENA_CPPFLAGS version: 2 updated: 2002/10/09 20:00:37
     33052+dnl CF_X_ATHENA_CPPFLAGS version: 3 updated: 2009/01/11 15:33:39
     33053 dnl --------------------
     33054 dnl Normally invoked by CF_X_ATHENA, with $1 set to the appropriate flavor of
     33055 dnl the Athena widgets, e.g., Xaw, Xaw3d, neXtaw.
     33056@@ -2024,7 +2234,7 @@
     33057                cf_save="$CPPFLAGS"
     33058                cf_test=X11/$cf_x_athena_root/SimpleMenu.h
     33059                if test $cf_path != default ; then
     33060-                       CPPFLAGS="-I$cf_path/include $cf_save"
     33061+                       CPPFLAGS="$cf_save -I$cf_path/include"
     33062                        AC_MSG_CHECKING(for $cf_test in $cf_path)
     33063                else
     33064                        AC_MSG_CHECKING(for $cf_test)
     33065@@ -2052,7 +2262,7 @@
     33066 fi
     33067 ])
     33068 dnl ---------------------------------------------------------------------------
     33069-dnl CF_X_ATHENA_LIBS version: 6 updated: 2006/11/30 17:57:11
     33070+dnl CF_X_ATHENA_LIBS version: 7 updated: 2008/03/23 14:46:03
     33071 dnl ----------------
     33072 dnl Normally invoked by CF_X_ATHENA, with $1 set to the appropriate flavor of
     33073 dnl the Athena widgets, e.g., Xaw, Xaw3d, neXtaw.
     33074@@ -2096,7 +2306,7 @@
     33075 done
     33076 
     33077 if test -z "$cf_x_athena_lib" ; then
     33078-       AC_ERROR(
     33079+       AC_MSG_ERROR(
     33080 [Unable to successfully link Athena library (-l$cf_x_athena_root) with test program])
     33081 fi
     33082 
     33083@@ -2104,7 +2314,7 @@
     33084 AC_DEFINE_UNQUOTED($cf_x_athena_LIBS)
     33085 ])
     33086 dnl ---------------------------------------------------------------------------
     33087-dnl CF_X_TOOLKIT version: 11 updated: 2006/11/29 19:05:14
     33088+dnl CF_X_TOOLKIT version: 12 updated: 2008/03/23 15:04:54
     33089 dnl ------------
     33090 dnl Check for X Toolkit libraries
     33091 dnl
     33092@@ -2133,7 +2343,7 @@
     33093        [$X_PRE_LIBS $LIBS $X_EXTRA_LIBS])])
     33094 
     33095 if test $cf_have_X_LIBS = no ; then
     33096-       AC_WARN(
     33097+       AC_MSG_WARN(
     33098 [Unable to successfully link X Toolkit library (-lXt) with
     33099 test program.  You will have to check and add the proper libraries by hand
     33100 to makefile.])
    2105033101diff -Naur ncurses-5.7.orig/test/clip_printw.c ncurses-5.7/test/clip_printw.c
    2105133102--- ncurses-5.7.orig/test/clip_printw.c 1969-12-31 16:00:00.000000000 -0800
    21052 +++ ncurses-5.7/test/clip_printw.c      2009-02-28 20:38:42.990334962 -0800
     33103+++ ncurses-5.7/test/clip_printw.c      2009-06-05 14:00:59.000000000 -0700
    2105333104@@ -0,0 +1,360 @@
    2105433105+/****************************************************************************
     
    2141233463+    ExitProgram(EXIT_SUCCESS);
    2141333464+}
     33465diff -Naur ncurses-5.7.orig/test/configure ncurses-5.7/test/configure
     33466--- ncurses-5.7.orig/test/configure     2008-09-06 15:11:48.000000000 -0700
     33467+++ ncurses-5.7/test/configure  2009-06-05 14:01:30.000000000 -0700
     33468@@ -194,6 +194,7 @@
     33469   --with-Xaw3d            link with Xaw 3d library
     33470   --with-neXtaw           link with neXT Athena library
     33471   --with-XawPlus          link with Athena-Plus library
     33472+  --with-ncurses-wrap-prefix naming-prefix for ncurses wrapped-variables
     33473 EOF
     33474     exit 0 ;;
     33475 
     33476@@ -536,7 +537,7 @@
     33477 # Uses ac_ vars as temps to allow command line to override cache and checks.
     33478 # --without-x overrides everything else, but does not touch the cache.
     33479 echo $ac_n "checking for X""... $ac_c" 1>&6
     33480-echo "configure:540: checking for X" >&5
     33481+echo "configure:541: checking for X" >&5
     33482 
     33483 
     33484 # Check whether --with-x or --without-x was given.
     33485@@ -599,12 +600,12 @@
     33486 
     33487   # First, try using that file with no special directory specified.
     33488 cat > conftest.$ac_ext <<EOF
     33489-#line 603 "configure"
     33490+#line 604 "configure"
     33491 #include "confdefs.h"
     33492 #include <$x_direct_test_include>
     33493 EOF
     33494 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
     33495-{ (eval echo configure:608: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     33496+{ (eval echo configure:609: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     33497 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
     33498 if test -z "$ac_err"; then
     33499   rm -rf conftest*
     33500@@ -673,14 +674,14 @@
     33501   ac_save_LIBS="$LIBS"
     33502   LIBS="-l$x_direct_test_library $LIBS"
     33503 cat > conftest.$ac_ext <<EOF
     33504-#line 677 "configure"
     33505+#line 678 "configure"
     33506 #include "confdefs.h"
     33507 
     33508 int main() {
     33509 ${x_direct_test_function}()
     33510 ; return 0; }
     33511 EOF
     33512-if { (eval echo configure:684: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     33513+if { (eval echo configure:685: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     33514   rm -rf conftest*
     33515   LIBS="$ac_save_LIBS"
     33516 # We can link X programs with no special library path.
     33517@@ -803,7 +804,7 @@
     33518 fi
     33519 
     33520 echo $ac_n "checking host system type""... $ac_c" 1>&6
     33521-echo "configure:807: checking host system type" >&5
     33522+echo "configure:808: checking host system type" >&5
     33523 
     33524 host_alias=$host
     33525 case "$host_alias" in
     33526@@ -851,7 +852,7 @@
     33527 
     33528 
     33529 echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
     33530-echo "configure:855: checking whether ${MAKE-make} sets \${MAKE}" >&5
     33531+echo "configure:856: checking whether ${MAKE-make} sets \${MAKE}" >&5
     33532 set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
     33533 if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
     33534   echo $ac_n "(cached) $ac_c" 1>&6
     33535@@ -880,7 +881,7 @@
     33536 # Extract the first word of "gcc", so it can be a program name with args.
     33537 set dummy gcc; ac_word=$2
     33538 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
     33539-echo "configure:884: checking for $ac_word" >&5
     33540+echo "configure:885: checking for $ac_word" >&5
     33541 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
     33542   echo $ac_n "(cached) $ac_c" 1>&6
     33543 else
     33544@@ -910,7 +911,7 @@
     33545   # Extract the first word of "cc", so it can be a program name with args.
     33546 set dummy cc; ac_word=$2
     33547 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
     33548-echo "configure:914: checking for $ac_word" >&5
     33549+echo "configure:915: checking for $ac_word" >&5
     33550 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
     33551   echo $ac_n "(cached) $ac_c" 1>&6
     33552 else
     33553@@ -961,7 +962,7 @@
     33554       # Extract the first word of "cl", so it can be a program name with args.
     33555 set dummy cl; ac_word=$2
     33556 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
     33557-echo "configure:965: checking for $ac_word" >&5
     33558+echo "configure:966: checking for $ac_word" >&5
     33559 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
     33560   echo $ac_n "(cached) $ac_c" 1>&6
     33561 else
     33562@@ -993,7 +994,7 @@
     33563 fi
     33564 
     33565 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
     33566-echo "configure:997: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
     33567+echo "configure:998: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
     33568 
     33569 ac_ext=c
     33570 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
     33571@@ -1004,12 +1005,12 @@
     33572 
     33573 cat > conftest.$ac_ext << EOF
     33574 
     33575-#line 1008 "configure"
     33576+#line 1009 "configure"
     33577 #include "confdefs.h"
     33578 
     33579 main(){return(0);}
     33580 EOF
     33581-if { (eval echo configure:1013: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     33582+if { (eval echo configure:1014: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     33583   ac_cv_prog_cc_works=yes
     33584   # If we can't run a trivial program, we are probably using a cross compiler.
     33585   if (./conftest; exit) 2>/dev/null; then
     33586@@ -1035,12 +1036,12 @@
     33587   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
     33588 fi
     33589 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
     33590-echo "configure:1039: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
     33591+echo "configure:1040: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
     33592 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
     33593 cross_compiling=$ac_cv_prog_cc_cross
     33594 
     33595 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
     33596-echo "configure:1044: checking whether we are using GNU C" >&5
     33597+echo "configure:1045: checking whether we are using GNU C" >&5
     33598 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
     33599   echo $ac_n "(cached) $ac_c" 1>&6
     33600 else
     33601@@ -1049,7 +1050,7 @@
     33602   yes;
     33603 #endif
     33604 EOF
     33605-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1053: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
     33606+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1054: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
     33607   ac_cv_prog_gcc=yes
     33608 else
     33609   ac_cv_prog_gcc=no
     33610@@ -1068,7 +1069,7 @@
     33611 ac_save_CFLAGS="$CFLAGS"
     33612 CFLAGS=
     33613 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
     33614-echo "configure:1072: checking whether ${CC-cc} accepts -g" >&5
     33615+echo "configure:1073: checking whether ${CC-cc} accepts -g" >&5
     33616 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
     33617   echo $ac_n "(cached) $ac_c" 1>&6
     33618 else
     33619@@ -1100,7 +1101,7 @@
     33620 fi
     33621 
     33622 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
     33623-echo "configure:1104: checking how to run the C preprocessor" >&5
     33624+echo "configure:1105: checking how to run the C preprocessor" >&5
     33625 # On Suns, sometimes $CPP names a directory.
     33626 if test -n "$CPP" && test -d "$CPP"; then
     33627   CPP=
     33628@@ -1115,13 +1116,13 @@
     33629   # On the NeXT, cc -E runs the code through the compiler's parser,
     33630   # not just through cpp.
     33631   cat > conftest.$ac_ext <<EOF
     33632-#line 1119 "configure"
     33633+#line 1120 "configure"
     33634 #include "confdefs.h"
     33635 #include <assert.h>
     33636 Syntax Error
     33637 EOF
     33638 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
     33639-{ (eval echo configure:1125: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     33640+{ (eval echo configure:1126: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     33641 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
     33642 if test -z "$ac_err"; then
     33643   :
     33644@@ -1132,13 +1133,13 @@
     33645   rm -rf conftest*
     33646   CPP="${CC-cc} -E -traditional-cpp"
     33647   cat > conftest.$ac_ext <<EOF
     33648-#line 1136 "configure"
     33649+#line 1137 "configure"
     33650 #include "confdefs.h"
     33651 #include <assert.h>
     33652 Syntax Error
     33653 EOF
     33654 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
     33655-{ (eval echo configure:1142: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     33656+{ (eval echo configure:1143: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     33657 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
     33658 if test -z "$ac_err"; then
     33659   :
     33660@@ -1149,13 +1150,13 @@
     33661   rm -rf conftest*
     33662   CPP="${CC-cc} -nologo -E"
     33663   cat > conftest.$ac_ext <<EOF
     33664-#line 1153 "configure"
     33665+#line 1154 "configure"
     33666 #include "confdefs.h"
     33667 #include <assert.h>
     33668 Syntax Error
     33669 EOF
     33670 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
     33671-{ (eval echo configure:1159: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     33672+{ (eval echo configure:1160: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     33673 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
     33674 if test -z "$ac_err"; then
     33675   :
     33676@@ -1184,7 +1185,7 @@
     33677 # Extract the first word of "$ac_prog", so it can be a program name with args.
     33678 set dummy $ac_prog; ac_word=$2
     33679 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
     33680-echo "configure:1188: checking for $ac_word" >&5
     33681+echo "configure:1189: checking for $ac_word" >&5
     33682 if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
     33683   echo $ac_n "(cached) $ac_c" 1>&6
     33684 else
     33685@@ -1246,12 +1247,12 @@
     33686 cf_cv_libtype=
     33687 
     33688 echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
     33689-echo "configure:1250: checking for Cygwin environment" >&5
     33690+echo "configure:1251: checking for Cygwin environment" >&5
     33691 if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
     33692   echo $ac_n "(cached) $ac_c" 1>&6
     33693 else
     33694   cat > conftest.$ac_ext <<EOF
     33695-#line 1255 "configure"
     33696+#line 1256 "configure"
     33697 #include "confdefs.h"
     33698 
     33699 int main() {
     33700@@ -1262,7 +1263,7 @@
     33701 return __CYGWIN__;
     33702 ; return 0; }
     33703 EOF
     33704-if { (eval echo configure:1266: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33705+if { (eval echo configure:1267: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33706   rm -rf conftest*
     33707   ac_cv_cygwin=yes
     33708 else
     33709@@ -1279,19 +1280,19 @@
     33710 CYGWIN=
     33711 test "$ac_cv_cygwin" = yes && CYGWIN=yes
     33712 echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
     33713-echo "configure:1283: checking for mingw32 environment" >&5
     33714+echo "configure:1284: checking for mingw32 environment" >&5
     33715 if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
     33716   echo $ac_n "(cached) $ac_c" 1>&6
     33717 else
     33718   cat > conftest.$ac_ext <<EOF
     33719-#line 1288 "configure"
     33720+#line 1289 "configure"
     33721 #include "confdefs.h"
     33722 
     33723 int main() {
     33724 return __MINGW32__;
     33725 ; return 0; }
     33726 EOF
     33727-if { (eval echo configure:1295: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33728+if { (eval echo configure:1296: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33729   rm -rf conftest*
     33730   ac_cv_mingw32=yes
     33731 else
     33732@@ -1310,7 +1311,7 @@
     33733 
     33734 
     33735 echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
     33736-echo "configure:1314: checking for executable suffix" >&5
     33737+echo "configure:1315: checking for executable suffix" >&5
     33738 if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
     33739   echo $ac_n "(cached) $ac_c" 1>&6
     33740 else
     33741@@ -1320,7 +1321,7 @@
     33742   rm -f conftest*
     33743   echo 'int main () { return 0; }' > conftest.$ac_ext
     33744   ac_cv_exeext=
     33745-  if { (eval echo configure:1324: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
     33746+  if { (eval echo configure:1325: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
     33747     for file in conftest.*; do
     33748       case $file in
     33749       *.c | *.o | *.obj) ;;
     33750@@ -1341,13 +1342,13 @@
     33751 ac_exeext=$EXEEXT
     33752 
     33753 echo $ac_n "checking for object suffix""... $ac_c" 1>&6
     33754-echo "configure:1345: checking for object suffix" >&5
     33755+echo "configure:1346: checking for object suffix" >&5
     33756 if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
     33757   echo $ac_n "(cached) $ac_c" 1>&6
     33758 else
     33759   rm -f conftest*
     33760 echo 'int i = 1;' > conftest.$ac_ext
     33761-if { (eval echo configure:1351: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33762+if { (eval echo configure:1352: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33763   for ac_file in conftest.*; do
     33764     case $ac_file in
     33765     *.c) ;;
     33766@@ -1367,7 +1368,7 @@
     33767 
     33768 
     33769 echo $ac_n "checking for ${CC-cc} option to accept ANSI C""... $ac_c" 1>&6
     33770-echo "configure:1371: checking for ${CC-cc} option to accept ANSI C" >&5
     33771+echo "configure:1372: checking for ${CC-cc} option to accept ANSI C" >&5
     33772 if eval "test \"`echo '$''{'cf_cv_ansi_cc'+set}'`\" = set"; then
     33773   echo $ac_n "(cached) $ac_c" 1>&6
     33774 else
     33775@@ -1451,7 +1452,7 @@
     33776 
     33777 if test -n "$cf_new_cppflags" ; then
     33778       
     33779-       CPPFLAGS="$cf_new_cppflags $CPPFLAGS"
     33780+       CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
     33781 fi
     33782 
     33783 if test -n "$cf_new_extra_cppflags" ; then
     33784@@ -1463,7 +1464,7 @@
     33785 
     33786 
     33787        cat > conftest.$ac_ext <<EOF
     33788-#line 1467 "configure"
     33789+#line 1468 "configure"
     33790 #include "confdefs.h"
     33791 
     33792 #ifndef CC_HAS_PROTOS
     33793@@ -1479,7 +1480,7 @@
     33794        struct s2 {int (*f) (double a);};
     33795 ; return 0; }
     33796 EOF
     33797-if { (eval echo configure:1483: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33798+if { (eval echo configure:1484: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33799   rm -rf conftest*
     33800   cf_cv_ansi_cc="$cf_arg"; break
     33801 else
     33802@@ -1558,7 +1559,7 @@
     33803 
     33804 if test -n "$cf_new_cppflags" ; then
     33805       
     33806-       CPPFLAGS="$cf_new_cppflags $CPPFLAGS"
     33807+       CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
     33808 fi
     33809 
     33810 if test -n "$cf_new_extra_cppflags" ; then
     33811@@ -1606,9 +1607,9 @@
     33812 if test "$GCC" = yes
     33813 then
     33814        echo "checking for $CC __attribute__ directives" 1>&6
     33815-echo "configure:1610: checking for $CC __attribute__ directives" >&5
     33816+echo "configure:1611: checking for $CC __attribute__ directives" >&5
     33817 cat > conftest.$ac_ext <<EOF
     33818-#line 1612 "${as_me-configure}"
     33819+#line 1613 "${as_me-configure}"
     33820 #include "confdefs.h"
     33821 #include "conftest.h"
     33822 #include "conftest.i"
     33823@@ -1646,7 +1647,7 @@
     33824 EOF
     33825                        ;;
     33826                esac
     33827-               if { (eval echo configure:1650: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33828+               if { (eval echo configure:1651: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33829                        test -n "$verbose" && echo "$ac_t""... $cf_attribute" 1>&6
     33830                        cat conftest.h >>confdefs.h
     33831                fi
     33832@@ -1659,7 +1660,7 @@
     33833 
     33834 
     33835 echo $ac_n "checking if $CC -U and -D options work together""... $ac_c" 1>&6
     33836-echo "configure:1663: checking if $CC -U and -D options work together" >&5
     33837+echo "configure:1664: checking if $CC -U and -D options work together" >&5
     33838 if eval "test \"`echo '$''{'cf_cv_cc_u_d_options'+set}'`\" = set"; then
     33839   echo $ac_n "(cached) $ac_c" 1>&6
     33840 else
     33841@@ -1667,7 +1668,7 @@
     33842        cf_save_CPPFLAGS="$CPPFLAGS"
     33843        CPPFLAGS="-UU_D_OPTIONS -DU_D_OPTIONS -DD_U_OPTIONS -UD_U_OPTIONS"
     33844        cat > conftest.$ac_ext <<EOF
     33845-#line 1671 "configure"
     33846+#line 1672 "configure"
     33847 #include "confdefs.h"
     33848 
     33849 int main() {
     33850@@ -1681,7 +1682,7 @@
     33851       
     33852 ; return 0; }
     33853 EOF
     33854-if { (eval echo configure:1685: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33855+if { (eval echo configure:1686: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33856   rm -rf conftest*
     33857   
     33858        cf_cv_cc_u_d_options=yes
     33859@@ -1707,10 +1708,10 @@
     33860 cf_POSIX_C_SOURCE=199506L
     33861 
     33862 case $host_os in #(vi
     33863-aix[45]*) #(vi
     33864+aix[456]*) #(vi
     33865        CPPFLAGS="$CPPFLAGS -D_ALL_SOURCE"
     33866        ;;
     33867-freebsd*) #(vi
     33868+freebsd*|dragonfly*) #(vi
     33869        # 5.x headers associate
     33870        #       _XOPEN_SOURCE=600 with _POSIX_C_SOURCE=200112L
     33871        #       _XOPEN_SOURCE=500 with _POSIX_C_SOURCE=199506L
     33872@@ -1724,16 +1725,16 @@
     33873 irix[56].*) #(vi
     33874        CPPFLAGS="$CPPFLAGS -D_SGI_SOURCE"
     33875        ;;
     33876-linux*|gnu*|k*bsd*-gnu) #(vi
     33877+linux*|gnu*|mint*|k*bsd*-gnu) #(vi
     33878       
     33879 echo $ac_n "checking if we must define _GNU_SOURCE""... $ac_c" 1>&6
     33880-echo "configure:1731: checking if we must define _GNU_SOURCE" >&5
     33881+echo "configure:1732: checking if we must define _GNU_SOURCE" >&5
     33882 if eval "test \"`echo '$''{'cf_cv_gnu_source'+set}'`\" = set"; then
     33883   echo $ac_n "(cached) $ac_c" 1>&6
     33884 else
     33885   
     33886 cat > conftest.$ac_ext <<EOF
     33887-#line 1737 "configure"
     33888+#line 1738 "configure"
     33889 #include "confdefs.h"
     33890 #include <sys/types.h>
     33891 int main() {
     33892@@ -1743,7 +1744,7 @@
     33893 #endif
     33894 ; return 0; }
     33895 EOF
     33896-if { (eval echo configure:1747: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33897+if { (eval echo configure:1748: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33898   rm -rf conftest*
     33899   cf_cv_gnu_source=no
     33900 else
     33901@@ -1753,7 +1754,7 @@
     33902   cf_save="$CPPFLAGS"
     33903         CPPFLAGS="$CPPFLAGS -D_GNU_SOURCE"
     33904         cat > conftest.$ac_ext <<EOF
     33905-#line 1757 "configure"
     33906+#line 1758 "configure"
     33907 #include "confdefs.h"
     33908 #include <sys/types.h>
     33909 int main() {
     33910@@ -1763,7 +1764,7 @@
     33911 #endif
     33912 ; return 0; }
     33913 EOF
     33914-if { (eval echo configure:1767: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33915+if { (eval echo configure:1768: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33916   rm -rf conftest*
     33917   cf_cv_gnu_source=no
     33918 else
     33919@@ -1807,13 +1808,13 @@
     33920        ;;
     33921 *)
     33922        echo $ac_n "checking if we should define _XOPEN_SOURCE""... $ac_c" 1>&6
     33923-echo "configure:1811: checking if we should define _XOPEN_SOURCE" >&5
     33924+echo "configure:1812: checking if we should define _XOPEN_SOURCE" >&5
     33925 if eval "test \"`echo '$''{'cf_cv_xopen_source'+set}'`\" = set"; then
     33926   echo $ac_n "(cached) $ac_c" 1>&6
     33927 else
     33928   
     33929        cat > conftest.$ac_ext <<EOF
     33930-#line 1817 "configure"
     33931+#line 1818 "configure"
     33932 #include "confdefs.h"
     33933 #include <sys/types.h>
     33934 int main() {
     33935@@ -1823,7 +1824,7 @@
     33936 #endif
     33937 ; return 0; }
     33938 EOF
     33939-if { (eval echo configure:1827: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33940+if { (eval echo configure:1828: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33941   rm -rf conftest*
     33942   cf_cv_xopen_source=no
     33943 else
     33944@@ -1833,7 +1834,7 @@
     33945   cf_save="$CPPFLAGS"
     33946         CPPFLAGS="$CPPFLAGS -D_XOPEN_SOURCE=$cf_XOPEN_SOURCE"
     33947         cat > conftest.$ac_ext <<EOF
     33948-#line 1837 "configure"
     33949+#line 1838 "configure"
     33950 #include "confdefs.h"
     33951 #include <sys/types.h>
     33952 int main() {
     33953@@ -1843,7 +1844,7 @@
     33954 #endif
     33955 ; return 0; }
     33956 EOF
     33957-if { (eval echo configure:1847: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33958+if { (eval echo configure:1848: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33959   rm -rf conftest*
     33960   cf_cv_xopen_source=no
     33961 else
     33962@@ -1898,16 +1899,16 @@
     33963 
     33964 
     33965 echo $ac_n "checking if we should define _POSIX_C_SOURCE""... $ac_c" 1>&6
     33966-echo "configure:1902: checking if we should define _POSIX_C_SOURCE" >&5
     33967+echo "configure:1903: checking if we should define _POSIX_C_SOURCE" >&5
     33968 if eval "test \"`echo '$''{'cf_cv_posix_c_source'+set}'`\" = set"; then
     33969   echo $ac_n "(cached) $ac_c" 1>&6
     33970 else
     33971   
     33972       
     33973-echo "${as_me-configure}:1908: testing if the symbol is already defined go no further ..." 1>&5
     33974+echo "${as_me-configure}:1909: testing if the symbol is already defined go no further ..." 1>&5
     33975 
     33976        cat > conftest.$ac_ext <<EOF
     33977-#line 1911 "configure"
     33978+#line 1912 "configure"
     33979 #include "confdefs.h"
     33980 #include <sys/types.h>
     33981 int main() {
     33982@@ -1917,7 +1918,7 @@
     33983 #endif
     33984 ; return 0; }
     33985 EOF
     33986-if { (eval echo configure:1921: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33987+if { (eval echo configure:1922: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     33988   rm -rf conftest*
     33989   cf_cv_posix_c_source=no
     33990 else
     33991@@ -1939,7 +1940,7 @@
     33992         esac
     33993         if test "$cf_want_posix_source" = yes ; then
     33994                cat > conftest.$ac_ext <<EOF
     33995-#line 1943 "configure"
     33996+#line 1944 "configure"
     33997 #include "confdefs.h"
     33998 #include <sys/types.h>
     33999 int main() {
     34000@@ -1949,7 +1950,7 @@
     34001 #endif
     34002 ; return 0; }
     34003 EOF
     34004-if { (eval echo configure:1953: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34005+if { (eval echo configure:1954: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34006   :
     34007 else
     34008   echo "configure: failed program was:" >&5
     34009@@ -1960,15 +1961,15 @@
     34010 rm -f conftest*
     34011         fi
     34012         
     34013-echo "${as_me-configure}:1964: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
     34014+echo "${as_me-configure}:1965: testing ifdef from value $cf_POSIX_C_SOURCE ..." 1>&5
     34015 
     34016         CFLAGS="$cf_trim_CFLAGS"
     34017         CPPFLAGS="$cf_trim_CPPFLAGS $cf_cv_posix_c_source"
     34018         
     34019-echo "${as_me-configure}:1969: testing if the second compile does not leave our definition intact error ..." 1>&5
     34020+echo "${as_me-configure}:1970: testing if the second compile does not leave our definition intact error ..." 1>&5
     34021 
     34022         cat > conftest.$ac_ext <<EOF
     34023-#line 1972 "configure"
     34024+#line 1973 "configure"
     34025 #include "confdefs.h"
     34026 #include <sys/types.h>
     34027 int main() {
     34028@@ -1978,7 +1979,7 @@
     34029 #endif
     34030 ; return 0; }
     34031 EOF
     34032-if { (eval echo configure:1982: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34033+if { (eval echo configure:1983: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34034   :
     34035 else
     34036   echo "configure: failed program was:" >&5
     34037@@ -2013,12 +2014,12 @@
     34038 esac
     34039 
     34040 echo $ac_n "checking for working const""... $ac_c" 1>&6
     34041-echo "configure:2017: checking for working const" >&5
     34042+echo "configure:2018: checking for working const" >&5
     34043 if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
     34044   echo $ac_n "(cached) $ac_c" 1>&6
     34045 else
     34046   cat > conftest.$ac_ext <<EOF
     34047-#line 2022 "configure"
     34048+#line 2023 "configure"
     34049 #include "confdefs.h"
     34050 
     34051 int main() {
     34052@@ -2067,7 +2068,7 @@
     34053 
     34054 ; return 0; }
     34055 EOF
     34056-if { (eval echo configure:2071: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34057+if { (eval echo configure:2072: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34058   rm -rf conftest*
     34059   ac_cv_c_const=yes
     34060 else
     34061@@ -2089,7 +2090,7 @@
     34062 
     34063 
     34064 echo $ac_n "checking for signal global datatype""... $ac_c" 1>&6
     34065-echo "configure:2093: checking for signal global datatype" >&5
     34066+echo "configure:2094: checking for signal global datatype" >&5
     34067 if eval "test \"`echo '$''{'cf_cv_sig_atomic_t'+set}'`\" = set"; then
     34068   echo $ac_n "(cached) $ac_c" 1>&6
     34069 else
     34070@@ -2100,7 +2101,7 @@
     34071                "int"
     34072        do
     34073        cat > conftest.$ac_ext <<EOF
     34074-#line 2104 "configure"
     34075+#line 2105 "configure"
     34076 #include "confdefs.h"
     34077 
     34078 #include <sys/types.h>
     34079@@ -2118,7 +2119,7 @@
     34080                 x = 1
     34081 ; return 0; }
     34082 EOF
     34083-if { (eval echo configure:2122: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34084+if { (eval echo configure:2123: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34085   rm -rf conftest*
     34086   cf_cv_sig_atomic_t=$cf_type
     34087 else
     34088@@ -2142,7 +2143,7 @@
     34089 
     34090 
     34091 echo $ac_n "checking if you want to see long compiling messages""... $ac_c" 1>&6
     34092-echo "configure:2146: checking if you want to see long compiling messages" >&5
     34093+echo "configure:2147: checking if you want to see long compiling messages" >&5
     34094 
     34095 # Check whether --enable-echo or --disable-echo was given.
     34096 if test "${enable_echo+set}" = set; then
     34097@@ -2189,7 +2190,7 @@
     34098 GCC_VERSION=none
     34099 if test "$GCC" = yes ; then
     34100        echo $ac_n "checking version of $CC""... $ac_c" 1>&6
     34101-echo "configure:2193: checking version of $CC" >&5
     34102+echo "configure:2194: checking version of $CC" >&5
     34103        GCC_VERSION="`${CC} --version| sed -e '2,$d' -e 's/^.*(GCC) //' -e 's/^[^0-9.]*//' -e 's/[^0-9.].*//'`"
     34104        test -z "$GCC_VERSION" && GCC_VERSION=unknown
     34105        echo "$ac_t""$GCC_VERSION" 1>&6
     34106@@ -2199,7 +2200,7 @@
     34107 if ( test "$GCC" = yes || test "$GXX" = yes )
     34108 then
     34109 echo $ac_n "checking if you want to turn on gcc warnings""... $ac_c" 1>&6
     34110-echo "configure:2203: checking if you want to turn on gcc warnings" >&5
     34111+echo "configure:2204: checking if you want to turn on gcc warnings" >&5
     34112 
     34113 # Check whether --enable-warnings or --disable-warnings was given.
     34114 if test "${enable_warnings+set}" = set; then
     34115@@ -2228,11 +2229,11 @@
     34116        case $host_os in
     34117        linux*|gnu*)
     34118                echo $ac_n "checking if this is really Intel C compiler""... $ac_c" 1>&6
     34119-echo "configure:2232: checking if this is really Intel C compiler" >&5
     34120+echo "configure:2233: checking if this is really Intel C compiler" >&5
     34121                cf_save_CFLAGS="$CFLAGS"
     34122                CFLAGS="$CFLAGS -no-gcc"
     34123                cat > conftest.$ac_ext <<EOF
     34124-#line 2236 "configure"
     34125+#line 2237 "configure"
     34126 #include "confdefs.h"
     34127 
     34128 int main() {
     34129@@ -2244,7 +2245,7 @@
     34130 
     34131 ; return 0; }
     34132 EOF
     34133-if { (eval echo configure:2248: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34134+if { (eval echo configure:2249: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34135   rm -rf conftest*
     34136   INTEL_COMPILER=yes
     34137 cf_save_CFLAGS="$cf_save_CFLAGS -we147 -no-gcc"
     34138@@ -2262,7 +2263,7 @@
     34139 
     34140 
     34141 cat > conftest.$ac_ext <<EOF
     34142-#line 2266 "${as_me-configure}"
     34143+#line 2267 "${as_me-configure}"
     34144 int main(int argc, char *argv[]) { return (argv[argc-1] == 0) ; }
     34145 EOF
     34146 
     34147@@ -2270,7 +2271,6 @@
     34148 then
     34149 # The "-wdXXX" options suppress warnings:
     34150 # remark #1419: external declaration in primary source file
     34151-# remark #1682: implicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
     34152 # remark #1683: explicit conversion of a 64-bit integral type to a smaller integral type (potential portability problem)
     34153 # remark #1684: conversion from pointer to same-sized integral type (potential portability problem)
     34154 # remark #193: zero used for undefined preprocessing identifier
     34155@@ -2278,7 +2278,7 @@
     34156 # remark #810: conversion from "int" to "Dimension={unsigned short}" may lose significant bits
     34157 # remark #869: parameter "tw" was never referenced
     34158 # remark #981: operands are evaluated in unspecified order
     34159-# warning #269: invalid format string conversion
     34160+# warning #279: controlling expression is constant
     34161 
     34162        echo "checking for $CC warning options" 1>&6
     34163 echo "configure:2285: checking for $CC warning options" >&5
     34164@@ -2286,18 +2286,17 @@
     34165        EXTRA_CFLAGS="-Wall"
     34166        for cf_opt in \
     34167                wd1419 \
     34168-               wd1682 \
     34169                wd1683 \
     34170                wd1684 \
     34171                wd193 \
     34172-               wd279 \
     34173                wd593 \
     34174+               wd279 \
     34175                wd810 \
     34176                wd869 \
     34177                wd981
     34178        do
     34179                CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
     34180-               if { (eval echo configure:2301: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34181+               if { (eval echo configure:2300: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34182                        test -n "$verbose" && echo "$ac_t""... -$cf_opt" 1>&6
     34183                        EXTRA_CFLAGS="$EXTRA_CFLAGS -$cf_opt"
     34184                fi
     34185@@ -2307,7 +2306,7 @@
     34186 elif test "$GCC" = yes
     34187 then
     34188        echo "checking for $CC warning options" 1>&6
     34189-echo "configure:2311: checking for $CC warning options" >&5
     34190+echo "configure:2310: checking for $CC warning options" >&5
     34191        cf_save_CFLAGS="$CFLAGS"
     34192        EXTRA_CFLAGS="-W -Wall"
     34193        cf_warn_CONST=""
     34194@@ -2326,7 +2325,7 @@
     34195                Wundef $cf_warn_CONST
     34196        do
     34197                CFLAGS="$cf_save_CFLAGS $EXTRA_CFLAGS -$cf_opt"
     34198-               if { (eval echo configure:2330: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34199+               if { (eval echo configure:2329: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34200                        test -n "$verbose" && echo "$ac_t""... -$cf_opt" 1>&6
     34201                        case $cf_opt in #(vi
     34202                        Wcast-qual) #(vi
     34203@@ -2334,10 +2333,10 @@
     34204                                ;;
     34205                        Winline) #(vi
     34206                                case $GCC_VERSION in
     34207-                               3.3*)
     34208+                               [34].*)
     34209                                        test -n "$verbose" && echo "    feature is broken in gcc $GCC_VERSION" 1>&6
     34210 
     34211-echo "${as_me-configure}:2341: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
     34212+echo "${as_me-configure}:2340: testing feature is broken in gcc $GCC_VERSION ..." 1>&5
     34213 
     34214 
     34215                                        continue;;
     34216@@ -2441,7 +2440,7 @@
     34217       
     34218 
     34219 echo $ac_n "checking for extra include directories""... $ac_c" 1>&6
     34220-echo "configure:2445: checking for extra include directories" >&5
     34221+echo "configure:2444: checking for extra include directories" >&5
     34222 if eval "test \"`echo '$''{'cf_cv_curses_incdir'+set}'`\" = set"; then
     34223   echo $ac_n "(cached) $ac_c" 1>&6
     34224 else
     34225@@ -2462,11 +2461,11 @@
     34226 fi
     34227 
     34228 echo "$ac_t""$cf_cv_curses_incdir" 1>&6
     34229-test "$cf_cv_curses_incdir" != no && CPPFLAGS="$cf_cv_curses_incdir $CPPFLAGS"
     34230+test "$cf_cv_curses_incdir" != no && CPPFLAGS="$CPPFLAGS $cf_cv_curses_incdir"
     34231 
     34232 
     34233 echo $ac_n "checking if we have identified curses headers""... $ac_c" 1>&6
     34234-echo "configure:2470: checking if we have identified curses headers" >&5
     34235+echo "configure:2469: checking if we have identified curses headers" >&5
     34236 if eval "test \"`echo '$''{'cf_cv_ncurses_header'+set}'`\" = set"; then
     34237   echo $ac_n "(cached) $ac_c" 1>&6
     34238 else
     34239@@ -2479,14 +2478,14 @@
     34240        ncurses/ncurses.h
     34241 do
     34242 cat > conftest.$ac_ext <<EOF
     34243-#line 2483 "configure"
     34244+#line 2482 "configure"
     34245 #include "confdefs.h"
     34246 #include <${cf_header}>
     34247 int main() {
     34248 initscr(); tgoto("?", 0,0)
     34249 ; return 0; }
     34250 EOF
     34251-if { (eval echo configure:2490: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34252+if { (eval echo configure:2489: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34253   rm -rf conftest*
     34254   cf_cv_ncurses_header=$cf_header; break
     34255 else
     34256@@ -2509,17 +2508,17 @@
     34257 do
     34258 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
     34259 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
     34260-echo "configure:2513: checking for $ac_hdr" >&5
     34261+echo "configure:2512: checking for $ac_hdr" >&5
     34262 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
     34263   echo $ac_n "(cached) $ac_c" 1>&6
     34264 else
     34265   cat > conftest.$ac_ext <<EOF
     34266-#line 2518 "configure"
     34267+#line 2517 "configure"
     34268 #include "confdefs.h"
     34269 #include <$ac_hdr>
     34270 EOF
     34271 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
     34272-{ (eval echo configure:2523: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     34273+{ (eval echo configure:2522: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     34274 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
     34275 if test -z "$ac_err"; then
     34276   rm -rf conftest*
     34277@@ -2548,7 +2547,7 @@
     34278 
     34279 
     34280 echo $ac_n "checking for terminfo header""... $ac_c" 1>&6
     34281-echo "configure:2552: checking for terminfo header" >&5
     34282+echo "configure:2551: checking for terminfo header" >&5
     34283 if eval "test \"`echo '$''{'cf_cv_term_header'+set}'`\" = set"; then
     34284   echo $ac_n "(cached) $ac_c" 1>&6
     34285 else
     34286@@ -2565,7 +2564,7 @@
     34287 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
     34288 do
     34289 cat > conftest.$ac_ext <<EOF
     34290-#line 2569 "configure"
     34291+#line 2568 "configure"
     34292 #include "confdefs.h"
     34293 #include <stdio.h>
     34294 #include <${cf_cv_ncurses_header-curses.h}>
     34295@@ -2575,7 +2574,7 @@
     34296 int x = auto_left_margin
     34297 ; return 0; }
     34298 EOF
     34299-if { (eval echo configure:2579: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34300+if { (eval echo configure:2578: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34301   rm -rf conftest*
     34302   
     34303        cf_cv_term_header="$cf_test"
     34304@@ -2624,7 +2623,7 @@
     34305 
     34306       
     34307 echo $ac_n "checking for ncurses version""... $ac_c" 1>&6
     34308-echo "configure:2628: checking for ncurses version" >&5
     34309+echo "configure:2627: checking for ncurses version" >&5
     34310 if eval "test \"`echo '$''{'cf_cv_ncurses_version'+set}'`\" = set"; then
     34311   echo $ac_n "(cached) $ac_c" 1>&6
     34312 else
     34313@@ -2650,7 +2649,7 @@
     34314 #endif
     34315 EOF
     34316        cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
     34317-       { (eval echo configure:2654: \"$cf_try\") 1>&5; (eval $cf_try) 2>&5; }
     34318+       { (eval echo configure:2653: \"$cf_try\") 1>&5; (eval $cf_try) 2>&5; }
     34319        if test -f conftest.out ; then
     34320                cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
     34321                test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
     34322@@ -2659,7 +2658,7 @@
     34323 
     34324 else
     34325   cat > conftest.$ac_ext <<EOF
     34326-#line 2663 "configure"
     34327+#line 2662 "configure"
     34328 #include "confdefs.h"
     34329 
     34330 #include <${cf_cv_ncurses_header-curses.h}>
     34331@@ -2683,7 +2682,7 @@
     34332        ${cf_cv_main_return-return}(0);
     34333 }
     34334 EOF
     34335-if { (eval echo configure:2687: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     34336+if { (eval echo configure:2686: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     34337 then
     34338   
     34339        cf_cv_ncurses_version=`cat $cf_tempfile`
     34340@@ -2707,16 +2706,16 @@
     34341       
     34342 
     34343 echo $ac_n "checking if we have identified curses libraries""... $ac_c" 1>&6
     34344-echo "configure:2711: checking if we have identified curses libraries" >&5
     34345+echo "configure:2710: checking if we have identified curses libraries" >&5
     34346 cat > conftest.$ac_ext <<EOF
     34347-#line 2713 "configure"
     34348+#line 2712 "configure"
     34349 #include "confdefs.h"
     34350 #include <${cf_cv_ncurses_header-curses.h}>
     34351 int main() {
     34352 initscr(); tgoto("?", 0,0)
     34353 ; return 0; }
     34354 EOF
     34355-if { (eval echo configure:2720: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34356+if { (eval echo configure:2719: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34357   rm -rf conftest*
     34358   cf_result=yes
     34359 else
     34360@@ -2732,7 +2731,7 @@
     34361 case $host_os in #(vi
     34362 freebsd*) #(vi
     34363     echo $ac_n "checking for tgoto in -lmytinfo""... $ac_c" 1>&6
     34364-echo "configure:2736: checking for tgoto in -lmytinfo" >&5
     34365+echo "configure:2735: checking for tgoto in -lmytinfo" >&5
     34366 ac_lib_var=`echo mytinfo'_'tgoto | sed 'y%./+-%__p_%'`
     34367 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     34368   echo $ac_n "(cached) $ac_c" 1>&6
     34369@@ -2740,7 +2739,7 @@
     34370   ac_save_LIBS="$LIBS"
     34371 LIBS="-lmytinfo  $LIBS"
     34372 cat > conftest.$ac_ext <<EOF
     34373-#line 2744 "configure"
     34374+#line 2743 "configure"
     34375 #include "confdefs.h"
     34376 /* Override any gcc2 internal prototype to avoid an error.  */
     34377 /* We use char because int might match the return type of a gcc2
     34378@@ -2751,7 +2750,7 @@
     34379 tgoto()
     34380 ; return 0; }
     34381 EOF
     34382-if { (eval echo configure:2755: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34383+if { (eval echo configure:2754: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34384   rm -rf conftest*
     34385   eval "ac_cv_lib_$ac_lib_var=yes"
     34386 else
     34387@@ -2774,7 +2773,7 @@
     34388     ;;
     34389 hpux10.*) #(vi
     34390     echo $ac_n "checking for initscr in -lcur_colr""... $ac_c" 1>&6
     34391-echo "configure:2778: checking for initscr in -lcur_colr" >&5
     34392+echo "configure:2777: checking for initscr in -lcur_colr" >&5
     34393 ac_lib_var=`echo cur_colr'_'initscr | sed 'y%./+-%__p_%'`
     34394 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     34395   echo $ac_n "(cached) $ac_c" 1>&6
     34396@@ -2782,7 +2781,7 @@
     34397   ac_save_LIBS="$LIBS"
     34398 LIBS="-lcur_colr  $LIBS"
     34399 cat > conftest.$ac_ext <<EOF
     34400-#line 2786 "configure"
     34401+#line 2785 "configure"
     34402 #include "confdefs.h"
     34403 /* Override any gcc2 internal prototype to avoid an error.  */
     34404 /* We use char because int might match the return type of a gcc2
     34405@@ -2793,7 +2792,7 @@
     34406 initscr()
     34407 ; return 0; }
     34408 EOF
     34409-if { (eval echo configure:2797: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34410+if { (eval echo configure:2796: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34411   rm -rf conftest*
     34412   eval "ac_cv_lib_$ac_lib_var=yes"
     34413 else
     34414@@ -2816,7 +2815,7 @@
     34415   echo "$ac_t""no" 1>&6
     34416 
     34417     echo $ac_n "checking for initscr in -lHcurses""... $ac_c" 1>&6
     34418-echo "configure:2820: checking for initscr in -lHcurses" >&5
     34419+echo "configure:2819: checking for initscr in -lHcurses" >&5
     34420 ac_lib_var=`echo Hcurses'_'initscr | sed 'y%./+-%__p_%'`
     34421 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     34422   echo $ac_n "(cached) $ac_c" 1>&6
     34423@@ -2824,7 +2823,7 @@
     34424   ac_save_LIBS="$LIBS"
     34425 LIBS="-lHcurses  $LIBS"
     34426 cat > conftest.$ac_ext <<EOF
     34427-#line 2828 "configure"
     34428+#line 2827 "configure"
     34429 #include "confdefs.h"
     34430 /* Override any gcc2 internal prototype to avoid an error.  */
     34431 /* We use char because int might match the return type of a gcc2
     34432@@ -2835,7 +2834,7 @@
     34433 initscr()
     34434 ; return 0; }
     34435 EOF
     34436-if { (eval echo configure:2839: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34437+if { (eval echo configure:2838: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34438   rm -rf conftest*
     34439   eval "ac_cv_lib_$ac_lib_var=yes"
     34440 else
     34441@@ -2853,7 +2852,7 @@
     34442   
     34443         # HP's header uses __HP_CURSES, but user claims _HP_CURSES.
     34444         LIBS="-lHcurses $LIBS"
     34445-        CPPFLAGS="-D__HP_CURSES -D_HP_CURSES $CPPFLAGS"
     34446+        CPPFLAGS="$CPPFLAGS -D__HP_CURSES -D_HP_CURSES"
     34447         ac_cv_func_initscr=yes
     34448         
     34449 else
     34450@@ -2884,7 +2883,7 @@
     34451       if test "$cf_have_libdir" = no ; then
     34452         test -n "$verbose" && echo "   adding $cf_add_libdir to library-path" 1>&6
     34453 
     34454-echo "${as_me-configure}:2888: testing adding $cf_add_libdir to library-path ..." 1>&5
     34455+echo "${as_me-configure}:2887: testing adding $cf_add_libdir to library-path ..." 1>&5
     34456 
     34457 
     34458         LDFLAGS="-L$cf_add_libdir $LDFLAGS"
     34459@@ -2916,7 +2915,7 @@
     34460       if test "$cf_have_libdir" = no ; then
     34461         test -n "$verbose" && echo "   adding $cf_add_libdir to library-path" 1>&6
     34462 
     34463-echo "${as_me-configure}:2920: testing adding $cf_add_libdir to library-path ..." 1>&5
     34464+echo "${as_me-configure}:2919: testing adding $cf_add_libdir to library-path ..." 1>&5
     34465 
     34466 
     34467         LDFLAGS="-L$cf_add_libdir $LDFLAGS"
     34468@@ -2946,12 +2945,12 @@
     34469     # Check for library containing tgoto.  Do this before curses library
     34470     # because it may be needed to link the test-case for initscr.
     34471     echo $ac_n "checking for tgoto""... $ac_c" 1>&6
     34472-echo "configure:2950: checking for tgoto" >&5
     34473+echo "configure:2949: checking for tgoto" >&5
     34474 if eval "test \"`echo '$''{'ac_cv_func_tgoto'+set}'`\" = set"; then
     34475   echo $ac_n "(cached) $ac_c" 1>&6
     34476 else
     34477   cat > conftest.$ac_ext <<EOF
     34478-#line 2955 "configure"
     34479+#line 2954 "configure"
     34480 #include "confdefs.h"
     34481 /* System header to define __stub macros and hopefully few prototypes,
     34482     which can conflict with char tgoto(); below.  */
     34483@@ -2974,7 +2973,7 @@
     34484 
     34485 ; return 0; }
     34486 EOF
     34487-if { (eval echo configure:2978: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34488+if { (eval echo configure:2977: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34489   rm -rf conftest*
     34490   eval "ac_cv_func_tgoto=yes"
     34491 else
     34492@@ -2995,7 +2994,7 @@
     34493         for cf_term_lib in $cf_check_list termcap termlib unknown
     34494         do
     34495             echo $ac_n "checking for tgoto in -l$cf_term_lib""... $ac_c" 1>&6
     34496-echo "configure:2999: checking for tgoto in -l$cf_term_lib" >&5
     34497+echo "configure:2998: checking for tgoto in -l$cf_term_lib" >&5
     34498 ac_lib_var=`echo $cf_term_lib'_'tgoto | sed 'y%./+-%__p_%'`
     34499 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     34500   echo $ac_n "(cached) $ac_c" 1>&6
     34501@@ -3003,7 +3002,7 @@
     34502   ac_save_LIBS="$LIBS"
     34503 LIBS="-l$cf_term_lib  $LIBS"
     34504 cat > conftest.$ac_ext <<EOF
     34505-#line 3007 "configure"
     34506+#line 3006 "configure"
     34507 #include "confdefs.h"
     34508 /* Override any gcc2 internal prototype to avoid an error.  */
     34509 /* We use char because int might match the return type of a gcc2
     34510@@ -3014,7 +3013,7 @@
     34511 tgoto()
     34512 ; return 0; }
     34513 EOF
     34514-if { (eval echo configure:3018: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34515+if { (eval echo configure:3017: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34516   rm -rf conftest*
     34517   eval "ac_cv_lib_$ac_lib_var=yes"
     34518 else
     34519@@ -3041,10 +3040,10 @@
     34520 
     34521     # Check for library containing initscr
     34522     test "$cf_term_lib" != predefined && test "$cf_term_lib" != unknown && LIBS="-l$cf_term_lib $cf_save_LIBS"
     34523-    for cf_curs_lib in $cf_check_list xcurses jcurses unknown
     34524+       for cf_curs_lib in $cf_check_list xcurses jcurses pdcurses unknown
     34525     do
     34526         echo $ac_n "checking for initscr in -l$cf_curs_lib""... $ac_c" 1>&6
     34527-echo "configure:3048: checking for initscr in -l$cf_curs_lib" >&5
     34528+echo "configure:3047: checking for initscr in -l$cf_curs_lib" >&5
     34529 ac_lib_var=`echo $cf_curs_lib'_'initscr | sed 'y%./+-%__p_%'`
     34530 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     34531   echo $ac_n "(cached) $ac_c" 1>&6
     34532@@ -3052,7 +3051,7 @@
     34533   ac_save_LIBS="$LIBS"
     34534 LIBS="-l$cf_curs_lib  $LIBS"
     34535 cat > conftest.$ac_ext <<EOF
     34536-#line 3056 "configure"
     34537+#line 3055 "configure"
     34538 #include "confdefs.h"
     34539 /* Override any gcc2 internal prototype to avoid an error.  */
     34540 /* We use char because int might match the return type of a gcc2
     34541@@ -3063,7 +3062,7 @@
     34542 initscr()
     34543 ; return 0; }
     34544 EOF
     34545-if { (eval echo configure:3067: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34546+if { (eval echo configure:3066: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34547   rm -rf conftest*
     34548   eval "ac_cv_lib_$ac_lib_var=yes"
     34549 else
     34550@@ -3089,16 +3088,16 @@
     34551     LIBS="-l$cf_curs_lib $cf_save_LIBS"
     34552     if test "$cf_term_lib" = unknown ; then
     34553         echo $ac_n "checking if we can link with $cf_curs_lib library""... $ac_c" 1>&6
     34554-echo "configure:3093: checking if we can link with $cf_curs_lib library" >&5
     34555+echo "configure:3092: checking if we can link with $cf_curs_lib library" >&5
     34556         cat > conftest.$ac_ext <<EOF
     34557-#line 3095 "configure"
     34558+#line 3094 "configure"
     34559 #include "confdefs.h"
     34560 #include <${cf_cv_ncurses_header-curses.h}>
     34561 int main() {
     34562 initscr()
     34563 ; return 0; }
     34564 EOF
     34565-if { (eval echo configure:3102: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34566+if { (eval echo configure:3101: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34567   rm -rf conftest*
     34568   cf_result=yes
     34569 else
     34570@@ -3114,16 +3113,16 @@
     34571         :
     34572     elif test "$cf_term_lib" != predefined ; then
     34573         echo $ac_n "checking if we need both $cf_curs_lib and $cf_term_lib libraries""... $ac_c" 1>&6
     34574-echo "configure:3118: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
     34575+echo "configure:3117: checking if we need both $cf_curs_lib and $cf_term_lib libraries" >&5
     34576         cat > conftest.$ac_ext <<EOF
     34577-#line 3120 "configure"
     34578+#line 3119 "configure"
     34579 #include "confdefs.h"
     34580 #include <${cf_cv_ncurses_header-curses.h}>
     34581 int main() {
     34582 initscr(); tgoto((char *)0, 0, 0);
     34583 ; return 0; }
     34584 EOF
     34585-if { (eval echo configure:3127: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34586+if { (eval echo configure:3126: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34587   rm -rf conftest*
     34588   cf_result=no
     34589 else
     34590@@ -3133,14 +3132,14 @@
     34591   
     34592             LIBS="-l$cf_curs_lib -l$cf_term_lib $cf_save_LIBS"
     34593             cat > conftest.$ac_ext <<EOF
     34594-#line 3137 "configure"
     34595+#line 3136 "configure"
     34596 #include "confdefs.h"
     34597 #include <${cf_cv_ncurses_header-curses.h}>
     34598 int main() {
     34599 initscr()
     34600 ; return 0; }
     34601 EOF
     34602-if { (eval echo configure:3144: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34603+if { (eval echo configure:3143: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     34604   rm -rf conftest*
     34605   cf_result=yes
     34606 else
     34607@@ -3162,6 +3161,76 @@
     34608        ;;
     34609 ncurses)
     34610       
     34611+cf_ncuconfig_root=ncurses
     34612+
     34613+echo "Looking for ${cf_ncuconfig_root}-config"
     34614+for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
     34615+do
     34616+# Extract the first word of "$ac_prog", so it can be a program name with args.
     34617+set dummy $ac_prog; ac_word=$2
     34618+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
     34619+echo "configure:3173: checking for $ac_word" >&5
     34620+if eval "test \"`echo '$''{'ac_cv_path_NCURSES_CONFIG'+set}'`\" = set"; then
     34621+  echo $ac_n "(cached) $ac_c" 1>&6
     34622+else
     34623+  case "$NCURSES_CONFIG" in
     34624+  /*)
     34625+  ac_cv_path_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test with a path.
     34626+  ;;
     34627+  ?:/*)                         
     34628+  ac_cv_path_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test with a dos path.
     34629+  ;;
     34630+  *)
     34631+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
     34632+  ac_dummy="$PATH"
     34633+  for ac_dir in $ac_dummy; do
     34634+    test -z "$ac_dir" && ac_dir=.
     34635+    if test -f $ac_dir/$ac_word; then
     34636+      ac_cv_path_NCURSES_CONFIG="$ac_dir/$ac_word"
     34637+      break
     34638+    fi
     34639+  done
     34640+  IFS="$ac_save_ifs"
     34641+  ;;
     34642+esac
     34643+fi
     34644+NCURSES_CONFIG="$ac_cv_path_NCURSES_CONFIG"
     34645+if test -n "$NCURSES_CONFIG"; then
     34646+  echo "$ac_t""$NCURSES_CONFIG" 1>&6
     34647+else
     34648+  echo "$ac_t""no" 1>&6
     34649+fi
     34650+
     34651+test -n "$NCURSES_CONFIG" && break
     34652+done
     34653+test -n "$NCURSES_CONFIG" || NCURSES_CONFIG="none"
     34654+
     34655+
     34656+if test "$NCURSES_CONFIG" != none ; then
     34657+
     34658+cf_cv_ncurses_header=curses.h
     34659+
     34660+CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
     34661+LIBS="`$NCURSES_CONFIG --libs` $LIBS"
     34662+
     34663+cat >> confdefs.h <<\EOF
     34664+#define NCURSES 1
     34665+EOF
     34666+
     34667+
     34668+
     34669+cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
     34670+
     34671+cat >> confdefs.h <<EOF
     34672+#define $cf_nculib_ROOT 1
     34673+EOF
     34674+
     34675+
     34676+cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
     34677+
     34678+else
     34679+
     34680+
     34681 
     34682 cf_ncuhdr_root=ncurses
     34683 
     34684@@ -3186,20 +3255,20 @@
     34685                fi
     34686 
     34687                if test "$cf_have_incdir" = no ; then
     34688-          if test "$cf_add_incdir" = /usr/local/include ; then
     34689+                 if test "$cf_add_incdir" = /usr/local/include ; then
     34690                        if test "$GCC" = yes
     34691                        then
     34692                          cf_save_CPPFLAGS=$CPPFLAGS
     34693                          CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
     34694                          cat > conftest.$ac_ext <<EOF
     34695-#line 3196 "configure"
     34696+#line 3265 "configure"
     34697 #include "confdefs.h"
     34698 #include <stdio.h>
     34699 int main() {
     34700 printf("Hello")
     34701 ; return 0; }
     34702 EOF
     34703-if { (eval echo configure:3203: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34704+if { (eval echo configure:3272: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34705   :
     34706 else
     34707   echo "configure: failed program was:" >&5
     34708@@ -3216,14 +3285,14 @@
     34709                if test "$cf_have_incdir" = no ; then
     34710                  test -n "$verbose" && echo "  adding $cf_add_incdir to include-path" 1>&6
     34711 
     34712-echo "${as_me-configure}:3220: testing adding $cf_add_incdir to include-path ..." 1>&5
     34713+echo "${as_me-configure}:3289: testing adding $cf_add_incdir to include-path ..." 1>&5
     34714 
     34715 
     34716-                 CPPFLAGS="-I$cf_add_incdir $CPPFLAGS"
     34717+                 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
     34718 
     34719-          cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     34720-          test "$cf_top_incdir" = "$cf_add_incdir" && break
     34721-          cf_add_incdir="$cf_top_incdir"
     34722+                 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     34723+                 test "$cf_top_incdir" = "$cf_add_incdir" && break
     34724+                 cf_add_incdir="$cf_top_incdir"
     34725                else
     34726                  break
     34727                fi
     34728@@ -3235,7 +3304,7 @@
     34729 }
     34730 
     34731 echo $ac_n "checking for $cf_ncuhdr_root header in include-path""... $ac_c" 1>&6
     34732-echo "configure:3239: checking for $cf_ncuhdr_root header in include-path" >&5
     34733+echo "configure:3308: checking for $cf_ncuhdr_root header in include-path" >&5
     34734 if eval "test \"`echo '$''{'cf_cv_ncurses_h'+set}'`\" = set"; then
     34735   echo $ac_n "(cached) $ac_c" 1>&6
     34736 else
     34737@@ -3246,7 +3315,7 @@
     34738        do
     34739               
     34740        cat > conftest.$ac_ext <<EOF
     34741-#line 3250 "configure"
     34742+#line 3319 "configure"
     34743 #include "confdefs.h"
     34744 
     34745 
     34746@@ -3267,7 +3336,7 @@
     34747       
     34748 ; return 0; }
     34749 EOF
     34750-if { (eval echo configure:3271: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34751+if { (eval echo configure:3340: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34752   rm -rf conftest*
     34753   cf_cv_ncurses_h=$cf_header
     34754       
     34755@@ -3293,13 +3362,39 @@
     34756 else
     34757 
     34758 echo $ac_n "checking for $cf_ncuhdr_root include-path""... $ac_c" 1>&6
     34759-echo "configure:3297: checking for $cf_ncuhdr_root include-path" >&5
     34760+echo "configure:3366: checking for $cf_ncuhdr_root include-path" >&5
     34761 if eval "test \"`echo '$''{'cf_cv_ncurses_h2'+set}'`\" = set"; then
     34762   echo $ac_n "(cached) $ac_c" 1>&6
     34763 else
     34764   
     34765        test -n "$verbose" && echo
     34766-       cf_search=""
     34767+       
     34768+cf_header_path_list=""
     34769+if test -n "${CFLAGS}${CPPFLAGS}" ; then
     34770+       for cf_header_path in $CPPFLAGS $CFLAGS
     34771+       do
     34772+               case $cf_header_path in #(vi
     34773+               -I*)
     34774+                       cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
     34775+                       
     34776+test "$cf_header_path" != "NONE" && \
     34777+test -d "$cf_header_path" && \
     34778+ {
     34779+       test -n "$verbose" && echo "    ... testing for include-directories under $cf_header_path"
     34780+       test -d $cf_header_path/include &&          cf_search="$cf_search $cf_header_path/include"
     34781+       test -d $cf_header_path/include/$cf_ncuhdr_root &&       cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
     34782+       test -d $cf_header_path/include/$cf_ncuhdr_root/include &&    cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
     34783+       test -d $cf_header_path/$cf_ncuhdr_root/include &&       cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
     34784+       test -d $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root &&    cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
     34785+}
     34786+
     34787+                       cf_header_path_list="$cf_header_path_list $cf_search"
     34788+                       ;;
     34789+               esac
     34790+       done
     34791+fi
     34792+
     34793+cf_search=""
     34794 
     34795 
     34796 test "/usr" != "$prefix" && \
     34797@@ -3362,6 +3457,7 @@
     34798 }
     34799 
     34800 
     34801+
     34802 test "$includedir" != NONE && \
     34803 test "$includedir" != "/usr/include" && \
     34804 test -d "$includedir" && {
     34805@@ -3376,6 +3472,7 @@
     34806        test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
     34807 }
     34808 
     34809+cf_search="$cf_header_path_list $cf_search"
     34810 
     34811        test -n "$verbose" && echo search path $cf_search
     34812        cf_save2_CPPFLAGS="$CPPFLAGS"
     34813@@ -3400,20 +3497,20 @@
     34814                fi
     34815 
     34816                if test "$cf_have_incdir" = no ; then
     34817-          if test "$cf_add_incdir" = /usr/local/include ; then
     34818+                 if test "$cf_add_incdir" = /usr/local/include ; then
     34819                        if test "$GCC" = yes
     34820                        then
     34821                          cf_save_CPPFLAGS=$CPPFLAGS
     34822                          CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
     34823                          cat > conftest.$ac_ext <<EOF
     34824-#line 3410 "configure"
     34825+#line 3507 "configure"
     34826 #include "confdefs.h"
     34827 #include <stdio.h>
     34828 int main() {
     34829 printf("Hello")
     34830 ; return 0; }
     34831 EOF
     34832-if { (eval echo configure:3417: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34833+if { (eval echo configure:3514: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34834   :
     34835 else
     34836   echo "configure: failed program was:" >&5
     34837@@ -3430,14 +3527,14 @@
     34838                if test "$cf_have_incdir" = no ; then
     34839                  test -n "$verbose" && echo "  adding $cf_add_incdir to include-path" 1>&6
     34840 
     34841-echo "${as_me-configure}:3434: testing adding $cf_add_incdir to include-path ..." 1>&5
     34842+echo "${as_me-configure}:3531: testing adding $cf_add_incdir to include-path ..." 1>&5
     34843 
     34844 
     34845-                 CPPFLAGS="-I$cf_add_incdir $CPPFLAGS"
     34846+                 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
     34847 
     34848-          cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     34849-          test "$cf_top_incdir" = "$cf_add_incdir" && break
     34850-          cf_add_incdir="$cf_top_incdir"
     34851+                 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     34852+                 test "$cf_top_incdir" = "$cf_add_incdir" && break
     34853+                 cf_add_incdir="$cf_top_incdir"
     34854                else
     34855                  break
     34856                fi
     34857@@ -3452,7 +3549,7 @@
     34858                do
     34859                       
     34860        cat > conftest.$ac_ext <<EOF
     34861-#line 3456 "configure"
     34862+#line 3553 "configure"
     34863 #include "confdefs.h"
     34864 
     34865 
     34866@@ -3473,7 +3570,7 @@
     34867       
     34868 ; return 0; }
     34869 EOF
     34870-if { (eval echo configure:3477: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34871+if { (eval echo configure:3574: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34872   rm -rf conftest*
     34873   cf_cv_ncurses_h2=$cf_header
     34874       
     34875@@ -3525,20 +3622,20 @@
     34876                fi
     34877 
     34878                if test "$cf_have_incdir" = no ; then
     34879-          if test "$cf_add_incdir" = /usr/local/include ; then
     34880+                 if test "$cf_add_incdir" = /usr/local/include ; then
     34881                        if test "$GCC" = yes
     34882                        then
     34883                          cf_save_CPPFLAGS=$CPPFLAGS
     34884                          CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
     34885                          cat > conftest.$ac_ext <<EOF
     34886-#line 3535 "configure"
     34887+#line 3632 "configure"
     34888 #include "confdefs.h"
     34889 #include <stdio.h>
     34890 int main() {
     34891 printf("Hello")
     34892 ; return 0; }
     34893 EOF
     34894-if { (eval echo configure:3542: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34895+if { (eval echo configure:3639: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34896   :
     34897 else
     34898   echo "configure: failed program was:" >&5
     34899@@ -3555,14 +3652,14 @@
     34900                if test "$cf_have_incdir" = no ; then
     34901                  test -n "$verbose" && echo "  adding $cf_add_incdir to include-path" 1>&6
     34902 
     34903-echo "${as_me-configure}:3559: testing adding $cf_add_incdir to include-path ..." 1>&5
     34904+echo "${as_me-configure}:3656: testing adding $cf_add_incdir to include-path ..." 1>&5
     34905 
     34906 
     34907-                 CPPFLAGS="-I$cf_add_incdir $CPPFLAGS"
     34908+                 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
     34909 
     34910-          cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     34911-          test "$cf_top_incdir" = "$cf_add_incdir" && break
     34912-          cf_add_incdir="$cf_top_incdir"
     34913+                 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     34914+                 test "$cf_top_incdir" = "$cf_add_incdir" && break
     34915+                 cf_add_incdir="$cf_top_incdir"
     34916                else
     34917                  break
     34918                fi
     34919@@ -3603,7 +3700,7 @@
     34920 
     34921 
     34922 echo $ac_n "checking for terminfo header""... $ac_c" 1>&6
     34923-echo "configure:3607: checking for terminfo header" >&5
     34924+echo "configure:3704: checking for terminfo header" >&5
     34925 if eval "test \"`echo '$''{'cf_cv_term_header'+set}'`\" = set"; then
     34926   echo $ac_n "(cached) $ac_c" 1>&6
     34927 else
     34928@@ -3620,7 +3717,7 @@
     34929 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
     34930 do
     34931 cat > conftest.$ac_ext <<EOF
     34932-#line 3624 "configure"
     34933+#line 3721 "configure"
     34934 #include "confdefs.h"
     34935 #include <stdio.h>
     34936 #include <${cf_cv_ncurses_header-curses.h}>
     34937@@ -3630,7 +3727,7 @@
     34938 int x = auto_left_margin
     34939 ; return 0; }
     34940 EOF
     34941-if { (eval echo configure:3634: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34942+if { (eval echo configure:3731: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     34943   rm -rf conftest*
     34944   
     34945        cf_cv_term_header="$cf_test"
     34946@@ -3685,7 +3782,7 @@
     34947 
     34948 
     34949 echo $ac_n "checking for ncurses version""... $ac_c" 1>&6
     34950-echo "configure:3689: checking for ncurses version" >&5
     34951+echo "configure:3786: checking for ncurses version" >&5
     34952 if eval "test \"`echo '$''{'cf_cv_ncurses_version'+set}'`\" = set"; then
     34953   echo $ac_n "(cached) $ac_c" 1>&6
     34954 else
     34955@@ -3711,7 +3808,7 @@
     34956 #endif
     34957 EOF
     34958        cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
     34959-       { (eval echo configure:3715: \"$cf_try\") 1>&5; (eval $cf_try) 2>&5; }
     34960+       { (eval echo configure:3812: \"$cf_try\") 1>&5; (eval $cf_try) 2>&5; }
     34961        if test -f conftest.out ; then
     34962                cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
     34963                test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
     34964@@ -3720,7 +3817,7 @@
     34965 
     34966 else
     34967   cat > conftest.$ac_ext <<EOF
     34968-#line 3724 "configure"
     34969+#line 3821 "configure"
     34970 #include "confdefs.h"
     34971 
     34972 #include <${cf_cv_ncurses_header-curses.h}>
     34973@@ -3744,7 +3841,7 @@
     34974        ${cf_cv_main_return-return}(0);
     34975 }
     34976 EOF
     34977-if { (eval echo configure:3748: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     34978+if { (eval echo configure:3845: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     34979 then
     34980   
     34981        cf_cv_ncurses_version=`cat $cf_tempfile`
     34982@@ -3766,7 +3863,7 @@
     34983 
     34984 
     34985 
     34986-       
     34987+
     34988 
     34989 cf_nculib_root=ncurses
     34990        # This works, except for the special case where we find gpm, but
     34991@@ -3775,7 +3872,7 @@
     34992 cf_ncurses_LIBS=""
     34993 cf_ncurses_SAVE="$LIBS"
     34994 echo $ac_n "checking for Gpm_Open in -lgpm""... $ac_c" 1>&6
     34995-echo "configure:3779: checking for Gpm_Open in -lgpm" >&5
     34996+echo "configure:3876: checking for Gpm_Open in -lgpm" >&5
     34997 ac_lib_var=`echo gpm'_'Gpm_Open | sed 'y%./+-%__p_%'`
     34998 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     34999   echo $ac_n "(cached) $ac_c" 1>&6
     35000@@ -3783,7 +3880,7 @@
     35001   ac_save_LIBS="$LIBS"
     35002 LIBS="-lgpm  $LIBS"
     35003 cat > conftest.$ac_ext <<EOF
     35004-#line 3787 "configure"
     35005+#line 3884 "configure"
     35006 #include "confdefs.h"
     35007 /* Override any gcc2 internal prototype to avoid an error.  */
     35008 /* We use char because int might match the return type of a gcc2
     35009@@ -3794,7 +3891,7 @@
     35010 Gpm_Open()
     35011 ; return 0; }
     35012 EOF
     35013-if { (eval echo configure:3798: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35014+if { (eval echo configure:3895: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35015   rm -rf conftest*
     35016   eval "ac_cv_lib_$ac_lib_var=yes"
     35017 else
     35018@@ -3810,7 +3907,7 @@
     35019 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
     35020   echo "$ac_t""yes" 1>&6
     35021   echo $ac_n "checking for initscr in -lgpm""... $ac_c" 1>&6
     35022-echo "configure:3814: checking for initscr in -lgpm" >&5
     35023+echo "configure:3911: checking for initscr in -lgpm" >&5
     35024 ac_lib_var=`echo gpm'_'initscr | sed 'y%./+-%__p_%'`
     35025 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     35026   echo $ac_n "(cached) $ac_c" 1>&6
     35027@@ -3818,7 +3915,7 @@
     35028   ac_save_LIBS="$LIBS"
     35029 LIBS="-lgpm  $LIBS"
     35030 cat > conftest.$ac_ext <<EOF
     35031-#line 3822 "configure"
     35032+#line 3919 "configure"
     35033 #include "confdefs.h"
     35034 /* Override any gcc2 internal prototype to avoid an error.  */
     35035 /* We use char because int might match the return type of a gcc2
     35036@@ -3829,7 +3926,7 @@
     35037 initscr()
     35038 ; return 0; }
     35039 EOF
     35040-if { (eval echo configure:3833: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35041+if { (eval echo configure:3930: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35042   rm -rf conftest*
     35043   eval "ac_cv_lib_$ac_lib_var=yes"
     35044 else
     35045@@ -3861,7 +3958,7 @@
     35046        # version of ncurses (but it should do no harm, since it's static).
     35047        if test "$cf_nculib_root" = ncurses ; then
     35048                echo $ac_n "checking for tgoto in -lmytinfo""... $ac_c" 1>&6
     35049-echo "configure:3865: checking for tgoto in -lmytinfo" >&5
     35050+echo "configure:3962: checking for tgoto in -lmytinfo" >&5
     35051 ac_lib_var=`echo mytinfo'_'tgoto | sed 'y%./+-%__p_%'`
     35052 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     35053   echo $ac_n "(cached) $ac_c" 1>&6
     35054@@ -3869,7 +3966,7 @@
     35055   ac_save_LIBS="$LIBS"
     35056 LIBS="-lmytinfo  $LIBS"
     35057 cat > conftest.$ac_ext <<EOF
     35058-#line 3873 "configure"
     35059+#line 3970 "configure"
     35060 #include "confdefs.h"
     35061 /* Override any gcc2 internal prototype to avoid an error.  */
     35062 /* We use char because int might match the return type of a gcc2
     35063@@ -3880,7 +3977,7 @@
     35064 tgoto()
     35065 ; return 0; }
     35066 EOF
     35067-if { (eval echo configure:3884: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35068+if { (eval echo configure:3981: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35069   rm -rf conftest*
     35070   eval "ac_cv_lib_$ac_lib_var=yes"
     35071 else
     35072@@ -3928,7 +4025,7 @@
     35073       if test "$cf_have_libdir" = no ; then
     35074         test -n "$verbose" && echo "   adding $cf_add_libdir to library-path" 1>&6
     35075 
     35076-echo "${as_me-configure}:3932: testing adding $cf_add_libdir to library-path ..." 1>&5
     35077+echo "${as_me-configure}:4029: testing adding $cf_add_libdir to library-path ..." 1>&5
     35078 
     35079 
     35080         LDFLAGS="-L$cf_add_libdir $LDFLAGS"
     35081@@ -3943,12 +4040,12 @@
     35082        eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
     35083        cf_libdir=""
     35084        echo $ac_n "checking for initscr""... $ac_c" 1>&6
     35085-echo "configure:3947: checking for initscr" >&5
     35086+echo "configure:4044: checking for initscr" >&5
     35087 if eval "test \"`echo '$''{'ac_cv_func_initscr'+set}'`\" = set"; then
     35088   echo $ac_n "(cached) $ac_c" 1>&6
     35089 else
     35090   cat > conftest.$ac_ext <<EOF
     35091-#line 3952 "configure"
     35092+#line 4049 "configure"
     35093 #include "confdefs.h"
     35094 /* System header to define __stub macros and hopefully few prototypes,
     35095     which can conflict with char initscr(); below.  */
     35096@@ -3971,7 +4068,7 @@
     35097 
     35098 ; return 0; }
     35099 EOF
     35100-if { (eval echo configure:3975: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35101+if { (eval echo configure:4072: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35102   rm -rf conftest*
     35103   eval "ac_cv_func_initscr=yes"
     35104 else
     35105@@ -3991,17 +4088,17 @@
     35106 
     35107                cf_save_LIBS="$LIBS"
     35108                echo $ac_n "checking for initscr in -l$cf_nculib_root""... $ac_c" 1>&6
     35109-echo "configure:3995: checking for initscr in -l$cf_nculib_root" >&5
     35110+echo "configure:4092: checking for initscr in -l$cf_nculib_root" >&5
     35111                LIBS="-l$cf_nculib_root $LIBS"
     35112                cat > conftest.$ac_ext <<EOF
     35113-#line 3998 "configure"
     35114+#line 4095 "configure"
     35115 #include "confdefs.h"
     35116 #include <${cf_cv_ncurses_header-curses.h}>
     35117 int main() {
     35118 initscr()
     35119 ; return 0; }
     35120 EOF
     35121-if { (eval echo configure:4005: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35122+if { (eval echo configure:4102: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35123   rm -rf conftest*
     35124   echo "$ac_t""yes" 1>&6
     35125                         eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
     35126@@ -4011,7 +4108,33 @@
     35127   cat conftest.$ac_ext >&5
     35128   rm -rf conftest*
     35129   echo "$ac_t""no" 1>&6
     35130-                       cf_search=""
     35131+                       
     35132+cf_library_path_list=""
     35133+if test -n "${LDFLAGS}${LIBS}" ; then
     35134+       for cf_library_path in $LDFLAGS $LIBS
     35135+       do
     35136+               case $cf_library_path in #(vi
     35137+               -L*)
     35138+                       cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
     35139+                       
     35140+test "$cf_library_path" != "NONE" && \
     35141+test -d "$cf_library_path" && \
     35142+ {
     35143+       test -n "$verbose" && echo "    ... testing for lib-directories under $cf_library_path"
     35144+       test -d $cf_library_path/lib &&          cf_search="$cf_search $cf_library_path/lib"
     35145+       test -d $cf_library_path/lib/$cf_nculib_root &&       cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
     35146+       test -d $cf_library_path/lib/$cf_nculib_root/lib &&    cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
     35147+       test -d $cf_library_path/$cf_nculib_root/lib &&       cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
     35148+       test -d $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root &&    cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root"
     35149+}
     35150+
     35151+                       cf_library_path_list="$cf_library_path_list $cf_search"
     35152+                       ;;
     35153+               esac
     35154+       done
     35155+fi
     35156+
     35157+cf_search=""
     35158 
     35159 
     35160 test "/usr" != "$prefix" && \
     35161@@ -4074,20 +4197,23 @@
     35162 }
     35163 
     35164 
     35165+
     35166+cf_search="$cf_library_path_list $cf_search"
     35167+
     35168                        for cf_libdir in $cf_search
     35169                        do
     35170                                echo $ac_n "checking for -l$cf_nculib_root in $cf_libdir""... $ac_c" 1>&6
     35171-echo "configure:4081: checking for -l$cf_nculib_root in $cf_libdir" >&5
     35172+echo "configure:4207: checking for -l$cf_nculib_root in $cf_libdir" >&5
     35173                                LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
     35174                                cat > conftest.$ac_ext <<EOF
     35175-#line 4084 "configure"
     35176+#line 4210 "configure"
     35177 #include "confdefs.h"
     35178 #include <${cf_cv_ncurses_header-curses.h}>
     35179 int main() {
     35180 initscr()
     35181 ; return 0; }
     35182 EOF
     35183-if { (eval echo configure:4091: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35184+if { (eval echo configure:4217: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35185   rm -rf conftest*
     35186   echo "$ac_t""yes" 1>&6
     35187                                         eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
     35188@@ -4118,7 +4244,7 @@
     35189 
     35190 if test -n "$cf_ncurses_LIBS" ; then
     35191        echo $ac_n "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS""... $ac_c" 1>&6
     35192-echo "configure:4122: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
     35193+echo "configure:4248: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
     35194        cf_ncurses_SAVE="$LIBS"
     35195        for p in $cf_ncurses_LIBS ; do
     35196                q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
     35197@@ -4127,14 +4253,14 @@
     35198                fi
     35199        done
     35200        cat > conftest.$ac_ext <<EOF
     35201-#line 4131 "configure"
     35202+#line 4257 "configure"
     35203 #include "confdefs.h"
     35204 #include <${cf_cv_ncurses_header-curses.h}>
     35205 int main() {
     35206 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
     35207 ; return 0; }
     35208 EOF
     35209-if { (eval echo configure:4138: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35210+if { (eval echo configure:4264: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35211   rm -rf conftest*
     35212   echo "$ac_t""yes" 1>&6
     35213 else
     35214@@ -4155,19 +4281,22 @@
     35215 EOF
     35216 
     35217 
     35218+
     35219+fi
     35220+
     35221        ;;
     35222 ncursesw)
     35223        cf_cv_libtype=w
     35224       
     35225 echo $ac_n "checking for multibyte character support""... $ac_c" 1>&6
     35226-echo "configure:4164: checking for multibyte character support" >&5
     35227+echo "configure:4293: checking for multibyte character support" >&5
     35228 if eval "test \"`echo '$''{'cf_cv_utf8_lib'+set}'`\" = set"; then
     35229   echo $ac_n "(cached) $ac_c" 1>&6
     35230 else
     35231   
     35232        cf_save_LIBS="$LIBS"
     35233        cat > conftest.$ac_ext <<EOF
     35234-#line 4171 "configure"
     35235+#line 4300 "configure"
     35236 #include "confdefs.h"
     35237 
     35238 #include <stdlib.h>
     35239@@ -4175,16 +4304,26 @@
     35240 putwc(0,0);
     35241 ; return 0; }
     35242 EOF
     35243-if { (eval echo configure:4179: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35244+if { (eval echo configure:4308: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35245   rm -rf conftest*
     35246   cf_cv_utf8_lib=yes
     35247 else
     35248   echo "configure: failed program was:" >&5
     35249   cat conftest.$ac_ext >&5
     35250   rm -rf conftest*
     35251-  LIBS="-lutf8 $LIBS"
     35252-        cat > conftest.$ac_ext <<EOF
     35253-#line 4188 "configure"
     35254
     35255+
     35256+# If the linkage is not already in the $CPPFLAGS/$LDFLAGS configuration, these
     35257+# will be set on completion of the AC_TRY_LINK below.
     35258+cf_cv_header_path_utf8=
     35259+cf_cv_library_path_utf8=
     35260+
     35261+
     35262+echo "${as_me-configure}:4323: testing Starting FIND_LINKAGE(utf8,) ..." 1>&5
     35263+
     35264+
     35265+cat > conftest.$ac_ext <<EOF
     35266+#line 4327 "configure"
     35267 #include "confdefs.h"
     35268 
     35269 #include <libutf8.h>
     35270@@ -4192,17 +4331,341 @@
     35271 putwc(0,0);
     35272 ; return 0; }
     35273 EOF
     35274-if { (eval echo configure:4196: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35275+if { (eval echo configure:4335: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35276   rm -rf conftest*
     35277-  cf_cv_utf8_lib=add-on
     35278+  cf_cv_find_linkage_utf8=yes
     35279 else
     35280   echo "configure: failed program was:" >&5
     35281   cat conftest.$ac_ext >&5
     35282   rm -rf conftest*
     35283-  cf_cv_utf8_lib=no
     35284
     35285+    cf_cv_find_linkage_utf8=no
     35286+
     35287+    test -n "$verbose" && echo "       find linkage for utf8 library" 1>&6
     35288+
     35289+echo "${as_me-configure}:4347: testing find linkage for utf8 library ..." 1>&5
     35290+
     35291+
     35292+   
     35293+echo "${as_me-configure}:4351: testing Searching for headers in FIND_LINKAGE(utf8,) ..." 1>&5
     35294+
     35295+
     35296+    cf_save_CPPFLAGS="$CPPFLAGS"
     35297+    cf_test_CPPFLAGS="$CPPFLAGS"
     35298+
     35299+   
     35300+cf_header_path_list=""
     35301+if test -n "${CFLAGS}${CPPFLAGS}" ; then
     35302+       for cf_header_path in $CPPFLAGS $CFLAGS
     35303+       do
     35304+               case $cf_header_path in #(vi
     35305+               -I*)
     35306+                       cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
     35307+                       
     35308+test "$cf_header_path" != "NONE" && \
     35309+test -d "$cf_header_path" && \
     35310+ {
     35311+       test -n "$verbose" && echo "    ... testing for include-directories under $cf_header_path"
     35312+       test -d $cf_header_path/include &&          cf_search="$cf_search $cf_header_path/include"
     35313+       test -d $cf_header_path/include/utf8 &&       cf_search="$cf_search $cf_header_path/include/utf8"
     35314+       test -d $cf_header_path/include/utf8/include &&    cf_search="$cf_search $cf_header_path/include/utf8/include"
     35315+       test -d $cf_header_path/utf8/include &&       cf_search="$cf_search $cf_header_path/utf8/include"
     35316+       test -d $cf_header_path/utf8/include/utf8 &&    cf_search="$cf_search $cf_header_path/utf8/include/utf8"
     35317+}
     35318+
     35319+                       cf_header_path_list="$cf_header_path_list $cf_search"
     35320+                       ;;
     35321+               esac
     35322+       done
     35323+fi
     35324+
     35325+cf_search=""
     35326+
     35327+
     35328+test "/usr" != "$prefix" && \
     35329+test -d "/usr" && \
     35330+(test $prefix = NONE || test -d $prefix) && {
     35331+       test -n "$verbose" && echo "    ... testing for include-directories under /usr"
     35332+       test -d /usr/include &&          cf_search="$cf_search /usr/include"
     35333+       test -d /usr/include/utf8 &&       cf_search="$cf_search /usr/include/utf8"
     35334+       test -d /usr/include/utf8/include &&    cf_search="$cf_search /usr/include/utf8/include"
     35335+       test -d /usr/utf8/include &&       cf_search="$cf_search /usr/utf8/include"
     35336+       test -d /usr/utf8/include/utf8 &&    cf_search="$cf_search /usr/utf8/include/utf8"
     35337+}
     35338+
     35339+
     35340+test "$prefix" != "NONE" && \
     35341+test -d "$prefix" && \
     35342+ {
     35343+       test -n "$verbose" && echo "    ... testing for include-directories under $prefix"
     35344+       test -d $prefix/include &&          cf_search="$cf_search $prefix/include"
     35345+       test -d $prefix/include/utf8 &&       cf_search="$cf_search $prefix/include/utf8"
     35346+       test -d $prefix/include/utf8/include &&    cf_search="$cf_search $prefix/include/utf8/include"
     35347+       test -d $prefix/utf8/include &&       cf_search="$cf_search $prefix/utf8/include"
     35348+       test -d $prefix/utf8/include/utf8 &&    cf_search="$cf_search $prefix/utf8/include/utf8"
     35349+}
     35350+
     35351+
     35352+test "/usr/local" != "$prefix" && \
     35353+test -d "/usr/local" && \
     35354+(test $prefix = NONE || test -d $prefix) && {
     35355+       test -n "$verbose" && echo "    ... testing for include-directories under /usr/local"
     35356+       test -d /usr/local/include &&          cf_search="$cf_search /usr/local/include"
     35357+       test -d /usr/local/include/utf8 &&       cf_search="$cf_search /usr/local/include/utf8"
     35358+       test -d /usr/local/include/utf8/include &&    cf_search="$cf_search /usr/local/include/utf8/include"
     35359+       test -d /usr/local/utf8/include &&       cf_search="$cf_search /usr/local/utf8/include"
     35360+       test -d /usr/local/utf8/include/utf8 &&    cf_search="$cf_search /usr/local/utf8/include/utf8"
     35361+}
     35362+
     35363+
     35364+test "/opt" != "$prefix" && \
     35365+test -d "/opt" && \
     35366+(test $prefix = NONE || test -d $prefix) && {
     35367+       test -n "$verbose" && echo "    ... testing for include-directories under /opt"
     35368+       test -d /opt/include &&          cf_search="$cf_search /opt/include"
     35369+       test -d /opt/include/utf8 &&       cf_search="$cf_search /opt/include/utf8"
     35370+       test -d /opt/include/utf8/include &&    cf_search="$cf_search /opt/include/utf8/include"
     35371+       test -d /opt/utf8/include &&       cf_search="$cf_search /opt/utf8/include"
     35372+       test -d /opt/utf8/include/utf8 &&    cf_search="$cf_search /opt/utf8/include/utf8"
     35373+}
     35374+
     35375+
     35376+test "$HOME" != "$prefix" && \
     35377+test -d "$HOME" && \
     35378+(test $prefix = NONE || test -d $prefix) && {
     35379+       test -n "$verbose" && echo "    ... testing for include-directories under $HOME"
     35380+       test -d $HOME/include &&          cf_search="$cf_search $HOME/include"
     35381+       test -d $HOME/include/utf8 &&       cf_search="$cf_search $HOME/include/utf8"
     35382+       test -d $HOME/include/utf8/include &&    cf_search="$cf_search $HOME/include/utf8/include"
     35383+       test -d $HOME/utf8/include &&       cf_search="$cf_search $HOME/utf8/include"
     35384+       test -d $HOME/utf8/include/utf8 &&    cf_search="$cf_search $HOME/utf8/include/utf8"
     35385+}
     35386+
     35387+
     35388+
     35389+test "$includedir" != NONE && \
     35390+test "$includedir" != "/usr/include" && \
     35391+test -d "$includedir" && {
     35392+       test -d $includedir &&    cf_search="$cf_search $includedir"
     35393+       test -d $includedir/utf8 && cf_search="$cf_search $includedir/utf8"
     35394+}
     35395+
     35396+test "$oldincludedir" != NONE && \
     35397+test "$oldincludedir" != "/usr/include" && \
     35398+test -d "$oldincludedir" && {
     35399+       test -d $oldincludedir    && cf_search="$cf_search $oldincludedir"
     35400+       test -d $oldincludedir/utf8 && cf_search="$cf_search $oldincludedir/utf8"
     35401+}
     35402+
     35403+cf_search="$cf_header_path_list $cf_search"
     35404+
     35405+    for cf_cv_header_path_utf8 in $cf_search
     35406+    do
     35407+      if test -d $cf_cv_header_path_utf8 ; then
     35408+        test -n "$verbose" && echo "   ... testing $cf_cv_header_path_utf8" 1>&6
     35409+
     35410+echo "${as_me-configure}:4468: testing ... testing $cf_cv_header_path_utf8 ..." 1>&5
     35411+
     35412+
     35413+        CPPFLAGS="$cf_save_CPPFLAGS -I$cf_cv_header_path_utf8"
     35414+        cat > conftest.$ac_ext <<EOF
     35415+#line 4473 "configure"
     35416+#include "confdefs.h"
     35417+
     35418+#include <libutf8.h>
     35419+int main() {
     35420+putwc(0,0);
     35421+; return 0; }
     35422+EOF
     35423+if { (eval echo configure:4481: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     35424+  rm -rf conftest*
     35425
     35426+            test -n "$verbose" && echo "       ... found utf8 headers in $cf_cv_header_path_utf8" 1>&6
     35427+
     35428+echo "${as_me-configure}:4486: testing ... found utf8 headers in $cf_cv_header_path_utf8 ..." 1>&5
     35429+
     35430+
     35431+            cf_cv_find_linkage_utf8=maybe
     35432+            cf_test_CPPFLAGS="$CPPFLAGS"
     35433+            break
     35434+else
     35435+  echo "configure: failed program was:" >&5
     35436+  cat conftest.$ac_ext >&5
     35437+  rm -rf conftest*
     35438
     35439+            CPPFLAGS="$cf_save_CPPFLAGS"
     35440+           
     35441 fi
     35442 rm -f conftest*
     35443-       LIBS="$cf_save_LIBS"
     35444+      fi
     35445+    done
     35446+
     35447+    if test "$cf_cv_find_linkage_utf8" = maybe ; then
     35448+
     35449+     
     35450+echo "${as_me-configure}:4507: testing Searching for utf8 library in FIND_LINKAGE(utf8,) ..." 1>&5
     35451+
     35452+
     35453+      cf_save_LIBS="$LIBS"
     35454+      cf_save_LDFLAGS="$LDFLAGS"
     35455+
     35456+     
     35457+
     35458+      if test "$cf_cv_find_linkage_utf8" != yes ; then
     35459+       
     35460+cf_library_path_list=""
     35461+if test -n "${LDFLAGS}${LIBS}" ; then
     35462+       for cf_library_path in $LDFLAGS $LIBS
     35463+       do
     35464+               case $cf_library_path in #(vi
     35465+               -L*)
     35466+                       cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
     35467+                       
     35468+test "$cf_library_path" != "NONE" && \
     35469+test -d "$cf_library_path" && \
     35470+ {
     35471+       test -n "$verbose" && echo "    ... testing for lib-directories under $cf_library_path"
     35472+       test -d $cf_library_path/lib &&          cf_search="$cf_search $cf_library_path/lib"
     35473+       test -d $cf_library_path/lib/utf8 &&       cf_search="$cf_search $cf_library_path/lib/utf8"
     35474+       test -d $cf_library_path/lib/utf8/lib &&    cf_search="$cf_search $cf_library_path/lib/utf8/lib"
     35475+       test -d $cf_library_path/utf8/lib &&       cf_search="$cf_search $cf_library_path/utf8/lib"
     35476+       test -d $cf_library_path/utf8/lib/utf8 &&    cf_search="$cf_search $cf_library_path/utf8/lib/utf8"
     35477+}
     35478+
     35479+                       cf_library_path_list="$cf_library_path_list $cf_search"
     35480+                       ;;
     35481+               esac
     35482+       done
     35483+fi
     35484+
     35485+cf_search=""
     35486+
     35487+
     35488+test "/usr" != "$prefix" && \
     35489+test -d "/usr" && \
     35490+(test $prefix = NONE || test -d $prefix) && {
     35491+       test -n "$verbose" && echo "    ... testing for lib-directories under /usr"
     35492+       test -d /usr/lib &&          cf_search="$cf_search /usr/lib"
     35493+       test -d /usr/lib/utf8 &&       cf_search="$cf_search /usr/lib/utf8"
     35494+       test -d /usr/lib/utf8/lib &&    cf_search="$cf_search /usr/lib/utf8/lib"
     35495+       test -d /usr/utf8/lib &&       cf_search="$cf_search /usr/utf8/lib"
     35496+       test -d /usr/utf8/lib/utf8 &&    cf_search="$cf_search /usr/utf8/lib/utf8"
     35497+}
     35498+
     35499+
     35500+test "$prefix" != "NONE" && \
     35501+test -d "$prefix" && \
     35502+ {
     35503+       test -n "$verbose" && echo "    ... testing for lib-directories under $prefix"
     35504+       test -d $prefix/lib &&          cf_search="$cf_search $prefix/lib"
     35505+       test -d $prefix/lib/utf8 &&       cf_search="$cf_search $prefix/lib/utf8"
     35506+       test -d $prefix/lib/utf8/lib &&    cf_search="$cf_search $prefix/lib/utf8/lib"
     35507+       test -d $prefix/utf8/lib &&       cf_search="$cf_search $prefix/utf8/lib"
     35508+       test -d $prefix/utf8/lib/utf8 &&    cf_search="$cf_search $prefix/utf8/lib/utf8"
     35509+}
     35510+
     35511+
     35512+test "/usr/local" != "$prefix" && \
     35513+test -d "/usr/local" && \
     35514+(test $prefix = NONE || test -d $prefix) && {
     35515+       test -n "$verbose" && echo "    ... testing for lib-directories under /usr/local"
     35516+       test -d /usr/local/lib &&          cf_search="$cf_search /usr/local/lib"
     35517+       test -d /usr/local/lib/utf8 &&       cf_search="$cf_search /usr/local/lib/utf8"
     35518+       test -d /usr/local/lib/utf8/lib &&    cf_search="$cf_search /usr/local/lib/utf8/lib"
     35519+       test -d /usr/local/utf8/lib &&       cf_search="$cf_search /usr/local/utf8/lib"
     35520+       test -d /usr/local/utf8/lib/utf8 &&    cf_search="$cf_search /usr/local/utf8/lib/utf8"
     35521+}
     35522+
     35523+
     35524+test "/opt" != "$prefix" && \
     35525+test -d "/opt" && \
     35526+(test $prefix = NONE || test -d $prefix) && {
     35527+       test -n "$verbose" && echo "    ... testing for lib-directories under /opt"
     35528+       test -d /opt/lib &&          cf_search="$cf_search /opt/lib"
     35529+       test -d /opt/lib/utf8 &&       cf_search="$cf_search /opt/lib/utf8"
     35530+       test -d /opt/lib/utf8/lib &&    cf_search="$cf_search /opt/lib/utf8/lib"
     35531+       test -d /opt/utf8/lib &&       cf_search="$cf_search /opt/utf8/lib"
     35532+       test -d /opt/utf8/lib/utf8 &&    cf_search="$cf_search /opt/utf8/lib/utf8"
     35533+}
     35534+
     35535+
     35536+test "$HOME" != "$prefix" && \
     35537+test -d "$HOME" && \
     35538+(test $prefix = NONE || test -d $prefix) && {
     35539+       test -n "$verbose" && echo "    ... testing for lib-directories under $HOME"
     35540+       test -d $HOME/lib &&          cf_search="$cf_search $HOME/lib"
     35541+       test -d $HOME/lib/utf8 &&       cf_search="$cf_search $HOME/lib/utf8"
     35542+       test -d $HOME/lib/utf8/lib &&    cf_search="$cf_search $HOME/lib/utf8/lib"
     35543+       test -d $HOME/utf8/lib &&       cf_search="$cf_search $HOME/utf8/lib"
     35544+       test -d $HOME/utf8/lib/utf8 &&    cf_search="$cf_search $HOME/utf8/lib/utf8"
     35545+}
     35546+
     35547+
     35548+
     35549+cf_search="$cf_library_path_list $cf_search"
     35550+
     35551+        for cf_cv_library_path_utf8 in $cf_search
     35552+        do
     35553+          if test -d $cf_cv_library_path_utf8 ; then
     35554+            test -n "$verbose" && echo "       ... testing $cf_cv_library_path_utf8" 1>&6
     35555+
     35556+echo "${as_me-configure}:4613: testing ... testing $cf_cv_library_path_utf8 ..." 1>&5
     35557+
     35558+
     35559+            CPPFLAGS="$cf_test_CPPFLAGS"
     35560+            LIBS="-lutf8  $cf_save_LIBS"
     35561+            LDFLAGS="$cf_save_LDFLAGS -L$cf_cv_library_path_utf8"
     35562+            cat > conftest.$ac_ext <<EOF
     35563+#line 4620 "configure"
     35564+#include "confdefs.h"
     35565+
     35566+#include <libutf8.h>
     35567+int main() {
     35568+putwc(0,0);
     35569+; return 0; }
     35570+EOF
     35571+if { (eval echo configure:4628: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     35572+  rm -rf conftest*
     35573
     35574+                test -n "$verbose" && echo "   ... found utf8 library in $cf_cv_library_path_utf8" 1>&6
     35575+
     35576+echo "${as_me-configure}:4633: testing ... found utf8 library in $cf_cv_library_path_utf8 ..." 1>&5
     35577+
     35578+
     35579+                cf_cv_find_linkage_utf8=yes
     35580+                cf_cv_library_file_utf8="-lutf8"
     35581+                break
     35582+else
     35583+  echo "configure: failed program was:" >&5
     35584+  cat conftest.$ac_ext >&5
     35585+  rm -rf conftest*
     35586
     35587+                CPPFLAGS="$cf_save_CPPFLAGS"
     35588+                LIBS="$cf_save_LIBS"
     35589+                LDFLAGS="$cf_save_LDFLAGS"
     35590+               
     35591+fi
     35592+rm -f conftest*
     35593+          fi
     35594+        done
     35595+        LIBS="$cf_save_LIBS"
     35596+        CPPFLAGS="$cf_save_CPPFLAGS"
     35597+        LDFLAGS="$cf_save_LDFLAGS"
     35598+      fi
     35599+
     35600+    else
     35601+      cf_cv_find_linkage_utf8=no
     35602+    fi
     35603+   
     35604+fi
     35605+rm -f conftest*
     35606+
     35607+if test "$cf_cv_find_linkage_utf8" = yes ; then
     35608+cf_cv_utf8_lib=add-on
     35609+else
     35610+cf_cv_utf8_lib=no
     35611+fi
     35612+
     35613 
     35614 fi
     35615 rm -f conftest*
     35616@@ -4217,10 +4680,174 @@
     35617 #define HAVE_LIBUTF8_H 1
     35618 EOF
     35619 
     35620+       
     35621+if test -n "$cf_cv_header_path_utf8" ; then
     35622+  for cf_add_incdir in $cf_cv_header_path_utf8
     35623+  do
     35624+       while test $cf_add_incdir != /usr/include
     35625+       do
     35626+         if test -d $cf_add_incdir
     35627+         then
     35628+               cf_have_incdir=no
     35629+               if test -n "$CFLAGS$CPPFLAGS" ; then
     35630+                 # a loop is needed to ensure we can add subdirs of existing dirs
     35631+                 for cf_test_incdir in $CFLAGS $CPPFLAGS ; do
     35632+                       if test ".$cf_test_incdir" = ".-I$cf_add_incdir" ; then
     35633+                         cf_have_incdir=yes; break
     35634+                       fi
     35635+                 done
     35636+               fi
     35637+
     35638+               if test "$cf_have_incdir" = no ; then
     35639+                 if test "$cf_add_incdir" = /usr/local/include ; then
     35640+                       if test "$GCC" = yes
     35641+                       then
     35642+                         cf_save_CPPFLAGS=$CPPFLAGS
     35643+                         CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
     35644+                         cat > conftest.$ac_ext <<EOF
     35645+#line 4709 "configure"
     35646+#include "confdefs.h"
     35647+#include <stdio.h>
     35648+int main() {
     35649+printf("Hello")
     35650+; return 0; }
     35651+EOF
     35652+if { (eval echo configure:4716: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     35653+  :
     35654+else
     35655+  echo "configure: failed program was:" >&5
     35656+  cat conftest.$ac_ext >&5
     35657+  rm -rf conftest*
     35658+  cf_have_incdir=yes
     35659+fi
     35660+rm -f conftest*
     35661+                         CPPFLAGS=$cf_save_CPPFLAGS
     35662+                       fi
     35663+                 fi
     35664+               fi
     35665+
     35666+               if test "$cf_have_incdir" = no ; then
     35667+                 test -n "$verbose" && echo "  adding $cf_add_incdir to include-path" 1>&6
     35668+
     35669+echo "${as_me-configure}:4733: testing adding $cf_add_incdir to include-path ..." 1>&5
     35670+
     35671+
     35672+                 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
     35673+
     35674+                 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     35675+                 test "$cf_top_incdir" = "$cf_add_incdir" && break
     35676+                 cf_add_incdir="$cf_top_incdir"
     35677+               else
     35678+                 break
     35679+               fi
     35680+         fi
     35681+       done
     35682+  done
     35683+fi
     35684+
     35685+       
     35686+if test -n "$cf_cv_library_path_utf8" ; then
     35687+  for cf_add_libdir in $cf_cv_library_path_utf8
     35688+  do
     35689+    if test $cf_add_libdir = /usr/lib ; then
     35690+      :
     35691+    elif test -d $cf_add_libdir
     35692+    then
     35693+      cf_have_libdir=no
     35694+      if test -n "$LDFLAGS$LIBS" ; then
     35695+        # a loop is needed to ensure we can add subdirs of existing dirs
     35696+        for cf_test_libdir in $LDFLAGS $LIBS ; do
     35697+          if test ".$cf_test_libdir" = ".-L$cf_add_libdir" ; then
     35698+            cf_have_libdir=yes; break
     35699+          fi
     35700+        done
     35701+      fi
     35702+      if test "$cf_have_libdir" = no ; then
     35703+        test -n "$verbose" && echo "   adding $cf_add_libdir to library-path" 1>&6
     35704+
     35705+echo "${as_me-configure}:4769: testing adding $cf_add_libdir to library-path ..." 1>&5
     35706+
     35707+
     35708+        LDFLAGS="-L$cf_add_libdir $LDFLAGS"
     35709+      fi
     35710+    fi
     35711+  done
     35712+fi
     35713+
     35714        LIBS="-lutf8 $LIBS"
     35715 fi
     35716 
     35717       
     35718+cf_ncuconfig_root=ncursesw
     35719+
     35720+echo "Looking for ${cf_ncuconfig_root}-config"
     35721+for ac_prog in ${cf_ncuconfig_root}6-config ${cf_ncuconfig_root}5-config
     35722+do
     35723+# Extract the first word of "$ac_prog", so it can be a program name with args.
     35724+set dummy $ac_prog; ac_word=$2
     35725+echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
     35726+echo "configure:4790: checking for $ac_word" >&5
     35727+if eval "test \"`echo '$''{'ac_cv_path_NCURSES_CONFIG'+set}'`\" = set"; then
     35728+  echo $ac_n "(cached) $ac_c" 1>&6
     35729+else
     35730+  case "$NCURSES_CONFIG" in
     35731+  /*)
     35732+  ac_cv_path_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test with a path.
     35733+  ;;
     35734+  ?:/*)                         
     35735+  ac_cv_path_NCURSES_CONFIG="$NCURSES_CONFIG" # Let the user override the test with a dos path.
     35736+  ;;
     35737+  *)
     35738+  IFS="${IFS=  }"; ac_save_ifs="$IFS"; IFS=":"
     35739+  ac_dummy="$PATH"
     35740+  for ac_dir in $ac_dummy; do
     35741+    test -z "$ac_dir" && ac_dir=.
     35742+    if test -f $ac_dir/$ac_word; then
     35743+      ac_cv_path_NCURSES_CONFIG="$ac_dir/$ac_word"
     35744+      break
     35745+    fi
     35746+  done
     35747+  IFS="$ac_save_ifs"
     35748+  ;;
     35749+esac
     35750+fi
     35751+NCURSES_CONFIG="$ac_cv_path_NCURSES_CONFIG"
     35752+if test -n "$NCURSES_CONFIG"; then
     35753+  echo "$ac_t""$NCURSES_CONFIG" 1>&6
     35754+else
     35755+  echo "$ac_t""no" 1>&6
     35756+fi
     35757+
     35758+test -n "$NCURSES_CONFIG" && break
     35759+done
     35760+test -n "$NCURSES_CONFIG" || NCURSES_CONFIG="none"
     35761+
     35762+
     35763+if test "$NCURSES_CONFIG" != none ; then
     35764+
     35765+cf_cv_ncurses_header=curses.h
     35766+
     35767+CPPFLAGS="$CPPFLAGS `$NCURSES_CONFIG --cflags`"
     35768+LIBS="`$NCURSES_CONFIG --libs` $LIBS"
     35769+
     35770+cat >> confdefs.h <<\EOF
     35771+#define NCURSES 1
     35772+EOF
     35773+
     35774+
     35775+
     35776+cf_nculib_ROOT=`echo "HAVE_LIB$cf_ncuconfig_root" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
     35777+
     35778+cat >> confdefs.h <<EOF
     35779+#define $cf_nculib_ROOT 1
     35780+EOF
     35781+
     35782+
     35783+cf_cv_ncurses_version=`$NCURSES_CONFIG --version`
     35784+
     35785+else
     35786+
     35787+
     35788 
     35789 cf_ncuhdr_root=ncursesw
     35790 
     35791@@ -4245,20 +4872,20 @@
     35792                fi
     35793 
     35794                if test "$cf_have_incdir" = no ; then
     35795-          if test "$cf_add_incdir" = /usr/local/include ; then
     35796+                 if test "$cf_add_incdir" = /usr/local/include ; then
     35797                        if test "$GCC" = yes
     35798                        then
     35799                          cf_save_CPPFLAGS=$CPPFLAGS
     35800                          CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
     35801                          cat > conftest.$ac_ext <<EOF
     35802-#line 4255 "configure"
     35803+#line 4882 "configure"
     35804 #include "confdefs.h"
     35805 #include <stdio.h>
     35806 int main() {
     35807 printf("Hello")
     35808 ; return 0; }
     35809 EOF
     35810-if { (eval echo configure:4262: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     35811+if { (eval echo configure:4889: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     35812   :
     35813 else
     35814   echo "configure: failed program was:" >&5
     35815@@ -4275,14 +4902,14 @@
     35816                if test "$cf_have_incdir" = no ; then
     35817                  test -n "$verbose" && echo "  adding $cf_add_incdir to include-path" 1>&6
     35818 
     35819-echo "${as_me-configure}:4279: testing adding $cf_add_incdir to include-path ..." 1>&5
     35820+echo "${as_me-configure}:4906: testing adding $cf_add_incdir to include-path ..." 1>&5
     35821 
     35822 
     35823-                 CPPFLAGS="-I$cf_add_incdir $CPPFLAGS"
     35824+                 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
     35825 
     35826-          cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     35827-          test "$cf_top_incdir" = "$cf_add_incdir" && break
     35828-          cf_add_incdir="$cf_top_incdir"
     35829+                 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     35830+                 test "$cf_top_incdir" = "$cf_add_incdir" && break
     35831+                 cf_add_incdir="$cf_top_incdir"
     35832                else
     35833                  break
     35834                fi
     35835@@ -4294,7 +4921,7 @@
     35836 }
     35837 
     35838 echo $ac_n "checking for $cf_ncuhdr_root header in include-path""... $ac_c" 1>&6
     35839-echo "configure:4298: checking for $cf_ncuhdr_root header in include-path" >&5
     35840+echo "configure:4925: checking for $cf_ncuhdr_root header in include-path" >&5
     35841 if eval "test \"`echo '$''{'cf_cv_ncurses_h'+set}'`\" = set"; then
     35842   echo $ac_n "(cached) $ac_c" 1>&6
     35843 else
     35844@@ -4305,7 +4932,7 @@
     35845        do
     35846               
     35847        cat > conftest.$ac_ext <<EOF
     35848-#line 4309 "configure"
     35849+#line 4936 "configure"
     35850 #include "confdefs.h"
     35851 
     35852 
     35853@@ -4334,7 +4961,7 @@
     35854       
     35855 ; return 0; }
     35856 EOF
     35857-if { (eval echo configure:4338: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     35858+if { (eval echo configure:4965: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     35859   rm -rf conftest*
     35860   cf_cv_ncurses_h=$cf_header
     35861       
     35862@@ -4360,13 +4987,39 @@
     35863 else
     35864 
     35865 echo $ac_n "checking for $cf_ncuhdr_root include-path""... $ac_c" 1>&6
     35866-echo "configure:4364: checking for $cf_ncuhdr_root include-path" >&5
     35867+echo "configure:4991: checking for $cf_ncuhdr_root include-path" >&5
     35868 if eval "test \"`echo '$''{'cf_cv_ncurses_h2'+set}'`\" = set"; then
     35869   echo $ac_n "(cached) $ac_c" 1>&6
     35870 else
     35871   
     35872        test -n "$verbose" && echo
     35873-       cf_search=""
     35874+       
     35875+cf_header_path_list=""
     35876+if test -n "${CFLAGS}${CPPFLAGS}" ; then
     35877+       for cf_header_path in $CPPFLAGS $CFLAGS
     35878+       do
     35879+               case $cf_header_path in #(vi
     35880+               -I*)
     35881+                       cf_header_path=`echo ".$cf_header_path" |sed -e 's/^...//' -e 's,/include$,,'`
     35882+                       
     35883+test "$cf_header_path" != "NONE" && \
     35884+test -d "$cf_header_path" && \
     35885+ {
     35886+       test -n "$verbose" && echo "    ... testing for include-directories under $cf_header_path"
     35887+       test -d $cf_header_path/include &&          cf_search="$cf_search $cf_header_path/include"
     35888+       test -d $cf_header_path/include/$cf_ncuhdr_root &&       cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root"
     35889+       test -d $cf_header_path/include/$cf_ncuhdr_root/include &&    cf_search="$cf_search $cf_header_path/include/$cf_ncuhdr_root/include"
     35890+       test -d $cf_header_path/$cf_ncuhdr_root/include &&       cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include"
     35891+       test -d $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root &&    cf_search="$cf_search $cf_header_path/$cf_ncuhdr_root/include/$cf_ncuhdr_root"
     35892+}
     35893+
     35894+                       cf_header_path_list="$cf_header_path_list $cf_search"
     35895+                       ;;
     35896+               esac
     35897+       done
     35898+fi
     35899+
     35900+cf_search=""
     35901 
     35902 
     35903 test "/usr" != "$prefix" && \
     35904@@ -4429,6 +5082,7 @@
     35905 }
     35906 
     35907 
     35908+
     35909 test "$includedir" != NONE && \
     35910 test "$includedir" != "/usr/include" && \
     35911 test -d "$includedir" && {
     35912@@ -4443,6 +5097,7 @@
     35913        test -d $oldincludedir/$cf_ncuhdr_root && cf_search="$cf_search $oldincludedir/$cf_ncuhdr_root"
     35914 }
     35915 
     35916+cf_search="$cf_header_path_list $cf_search"
     35917 
     35918        test -n "$verbose" && echo search path $cf_search
     35919        cf_save2_CPPFLAGS="$CPPFLAGS"
     35920@@ -4467,20 +5122,20 @@
     35921                fi
     35922 
     35923                if test "$cf_have_incdir" = no ; then
     35924-          if test "$cf_add_incdir" = /usr/local/include ; then
     35925+                 if test "$cf_add_incdir" = /usr/local/include ; then
     35926                        if test "$GCC" = yes
     35927                        then
     35928                          cf_save_CPPFLAGS=$CPPFLAGS
     35929                          CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
     35930                          cat > conftest.$ac_ext <<EOF
     35931-#line 4477 "configure"
     35932+#line 5132 "configure"
     35933 #include "confdefs.h"
     35934 #include <stdio.h>
     35935 int main() {
     35936 printf("Hello")
     35937 ; return 0; }
     35938 EOF
     35939-if { (eval echo configure:4484: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     35940+if { (eval echo configure:5139: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     35941   :
     35942 else
     35943   echo "configure: failed program was:" >&5
     35944@@ -4497,14 +5152,14 @@
     35945                if test "$cf_have_incdir" = no ; then
     35946                  test -n "$verbose" && echo "  adding $cf_add_incdir to include-path" 1>&6
     35947 
     35948-echo "${as_me-configure}:4501: testing adding $cf_add_incdir to include-path ..." 1>&5
     35949+echo "${as_me-configure}:5156: testing adding $cf_add_incdir to include-path ..." 1>&5
     35950 
     35951 
     35952-                 CPPFLAGS="-I$cf_add_incdir $CPPFLAGS"
     35953+                 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
     35954 
     35955-          cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     35956-          test "$cf_top_incdir" = "$cf_add_incdir" && break
     35957-          cf_add_incdir="$cf_top_incdir"
     35958+                 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     35959+                 test "$cf_top_incdir" = "$cf_add_incdir" && break
     35960+                 cf_add_incdir="$cf_top_incdir"
     35961                else
     35962                  break
     35963                fi
     35964@@ -4519,7 +5174,7 @@
     35965                do
     35966                       
     35967        cat > conftest.$ac_ext <<EOF
     35968-#line 4523 "configure"
     35969+#line 5178 "configure"
     35970 #include "confdefs.h"
     35971 
     35972 
     35973@@ -4540,7 +5195,7 @@
     35974       
     35975 ; return 0; }
     35976 EOF
     35977-if { (eval echo configure:4544: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     35978+if { (eval echo configure:5199: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     35979   rm -rf conftest*
     35980   cf_cv_ncurses_h2=$cf_header
     35981       
     35982@@ -4592,20 +5247,20 @@
     35983                fi
     35984 
     35985                if test "$cf_have_incdir" = no ; then
     35986-          if test "$cf_add_incdir" = /usr/local/include ; then
     35987+                 if test "$cf_add_incdir" = /usr/local/include ; then
     35988                        if test "$GCC" = yes
     35989                        then
     35990                          cf_save_CPPFLAGS=$CPPFLAGS
     35991                          CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
     35992                          cat > conftest.$ac_ext <<EOF
     35993-#line 4602 "configure"
     35994+#line 5257 "configure"
     35995 #include "confdefs.h"
     35996 #include <stdio.h>
     35997 int main() {
     35998 printf("Hello")
     35999 ; return 0; }
     36000 EOF
     36001-if { (eval echo configure:4609: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     36002+if { (eval echo configure:5264: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     36003   :
     36004 else
     36005   echo "configure: failed program was:" >&5
     36006@@ -4622,14 +5277,14 @@
     36007                if test "$cf_have_incdir" = no ; then
     36008                  test -n "$verbose" && echo "  adding $cf_add_incdir to include-path" 1>&6
     36009 
     36010-echo "${as_me-configure}:4626: testing adding $cf_add_incdir to include-path ..." 1>&5
     36011+echo "${as_me-configure}:5281: testing adding $cf_add_incdir to include-path ..." 1>&5
     36012 
     36013 
     36014-                 CPPFLAGS="-I$cf_add_incdir $CPPFLAGS"
     36015+                 CPPFLAGS="$CPPFLAGS -I$cf_add_incdir"
     36016 
     36017-          cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     36018-          test "$cf_top_incdir" = "$cf_add_incdir" && break
     36019-          cf_add_incdir="$cf_top_incdir"
     36020+                 cf_top_incdir=`echo $cf_add_incdir | sed -e 's%/include/.*$%/include%'`
     36021+                 test "$cf_top_incdir" = "$cf_add_incdir" && break
     36022+                 cf_add_incdir="$cf_top_incdir"
     36023                else
     36024                  break
     36025                fi
     36026@@ -4670,7 +5325,7 @@
     36027 
     36028 
     36029 echo $ac_n "checking for terminfo header""... $ac_c" 1>&6
     36030-echo "configure:4674: checking for terminfo header" >&5
     36031+echo "configure:5329: checking for terminfo header" >&5
     36032 if eval "test \"`echo '$''{'cf_cv_term_header'+set}'`\" = set"; then
     36033   echo $ac_n "(cached) $ac_c" 1>&6
     36034 else
     36035@@ -4687,7 +5342,7 @@
     36036 for cf_test in $cf_term_header "ncurses/term.h" "ncursesw/term.h"
     36037 do
     36038 cat > conftest.$ac_ext <<EOF
     36039-#line 4691 "configure"
     36040+#line 5346 "configure"
     36041 #include "confdefs.h"
     36042 #include <stdio.h>
     36043 #include <${cf_cv_ncurses_header-curses.h}>
     36044@@ -4697,7 +5352,7 @@
     36045 int x = auto_left_margin
     36046 ; return 0; }
     36047 EOF
     36048-if { (eval echo configure:4701: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     36049+if { (eval echo configure:5356: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     36050   rm -rf conftest*
     36051   
     36052        cf_cv_term_header="$cf_test"
     36053@@ -4752,7 +5407,7 @@
     36054 
     36055 
     36056 echo $ac_n "checking for ncurses version""... $ac_c" 1>&6
     36057-echo "configure:4756: checking for ncurses version" >&5
     36058+echo "configure:5411: checking for ncurses version" >&5
     36059 if eval "test \"`echo '$''{'cf_cv_ncurses_version'+set}'`\" = set"; then
     36060   echo $ac_n "(cached) $ac_c" 1>&6
     36061 else
     36062@@ -4778,7 +5433,7 @@
     36063 #endif
     36064 EOF
     36065        cf_try="$ac_cpp conftest.$ac_ext 2>&5 | grep '^Autoconf ' >conftest.out"
     36066-       { (eval echo configure:4782: \"$cf_try\") 1>&5; (eval $cf_try) 2>&5; }
     36067+       { (eval echo configure:5437: \"$cf_try\") 1>&5; (eval $cf_try) 2>&5; }
     36068        if test -f conftest.out ; then
     36069                cf_out=`cat conftest.out | sed -e 's%^Autoconf %%' -e 's%^[^"]*"%%' -e 's%".*%%'`
     36070                test -n "$cf_out" && cf_cv_ncurses_version="$cf_out"
     36071@@ -4787,7 +5442,7 @@
     36072 
     36073 else
     36074   cat > conftest.$ac_ext <<EOF
     36075-#line 4791 "configure"
     36076+#line 5446 "configure"
     36077 #include "confdefs.h"
     36078 
     36079 #include <${cf_cv_ncurses_header-curses.h}>
     36080@@ -4811,7 +5466,7 @@
     36081        ${cf_cv_main_return-return}(0);
     36082 }
     36083 EOF
     36084-if { (eval echo configure:4815: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     36085+if { (eval echo configure:5470: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     36086 then
     36087   
     36088        cf_cv_ncurses_version=`cat $cf_tempfile`
     36089@@ -4833,7 +5488,7 @@
     36090 
     36091 
     36092 
     36093-       
     36094+
     36095 
     36096 cf_nculib_root=ncursesw
     36097        # This works, except for the special case where we find gpm, but
     36098@@ -4842,7 +5497,7 @@
     36099 cf_ncurses_LIBS=""
     36100 cf_ncurses_SAVE="$LIBS"
     36101 echo $ac_n "checking for Gpm_Open in -lgpm""... $ac_c" 1>&6
     36102-echo "configure:4846: checking for Gpm_Open in -lgpm" >&5
     36103+echo "configure:5501: checking for Gpm_Open in -lgpm" >&5
     36104 ac_lib_var=`echo gpm'_'Gpm_Open | sed 'y%./+-%__p_%'`
     36105 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     36106   echo $ac_n "(cached) $ac_c" 1>&6
     36107@@ -4850,7 +5505,7 @@
     36108   ac_save_LIBS="$LIBS"
     36109 LIBS="-lgpm  $LIBS"
     36110 cat > conftest.$ac_ext <<EOF
     36111-#line 4854 "configure"
     36112+#line 5509 "configure"
     36113 #include "confdefs.h"
     36114 /* Override any gcc2 internal prototype to avoid an error.  */
     36115 /* We use char because int might match the return type of a gcc2
     36116@@ -4861,7 +5516,7 @@
     36117 Gpm_Open()
     36118 ; return 0; }
     36119 EOF
     36120-if { (eval echo configure:4865: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36121+if { (eval echo configure:5520: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36122   rm -rf conftest*
     36123   eval "ac_cv_lib_$ac_lib_var=yes"
     36124 else
     36125@@ -4877,7 +5532,7 @@
     36126 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
     36127   echo "$ac_t""yes" 1>&6
     36128   echo $ac_n "checking for initscr in -lgpm""... $ac_c" 1>&6
     36129-echo "configure:4881: checking for initscr in -lgpm" >&5
     36130+echo "configure:5536: checking for initscr in -lgpm" >&5
     36131 ac_lib_var=`echo gpm'_'initscr | sed 'y%./+-%__p_%'`
     36132 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     36133   echo $ac_n "(cached) $ac_c" 1>&6
     36134@@ -4885,7 +5540,7 @@
     36135   ac_save_LIBS="$LIBS"
     36136 LIBS="-lgpm  $LIBS"
     36137 cat > conftest.$ac_ext <<EOF
     36138-#line 4889 "configure"
     36139+#line 5544 "configure"
     36140 #include "confdefs.h"
     36141 /* Override any gcc2 internal prototype to avoid an error.  */
     36142 /* We use char because int might match the return type of a gcc2
     36143@@ -4896,7 +5551,7 @@
     36144 initscr()
     36145 ; return 0; }
     36146 EOF
     36147-if { (eval echo configure:4900: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36148+if { (eval echo configure:5555: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36149   rm -rf conftest*
     36150   eval "ac_cv_lib_$ac_lib_var=yes"
     36151 else
     36152@@ -4928,7 +5583,7 @@
     36153        # version of ncurses (but it should do no harm, since it's static).
     36154        if test "$cf_nculib_root" = ncurses ; then
     36155                echo $ac_n "checking for tgoto in -lmytinfo""... $ac_c" 1>&6
     36156-echo "configure:4932: checking for tgoto in -lmytinfo" >&5
     36157+echo "configure:5587: checking for tgoto in -lmytinfo" >&5
     36158 ac_lib_var=`echo mytinfo'_'tgoto | sed 'y%./+-%__p_%'`
     36159 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     36160   echo $ac_n "(cached) $ac_c" 1>&6
     36161@@ -4936,7 +5591,7 @@
     36162   ac_save_LIBS="$LIBS"
     36163 LIBS="-lmytinfo  $LIBS"
     36164 cat > conftest.$ac_ext <<EOF
     36165-#line 4940 "configure"
     36166+#line 5595 "configure"
     36167 #include "confdefs.h"
     36168 /* Override any gcc2 internal prototype to avoid an error.  */
     36169 /* We use char because int might match the return type of a gcc2
     36170@@ -4947,7 +5602,7 @@
     36171 tgoto()
     36172 ; return 0; }
     36173 EOF
     36174-if { (eval echo configure:4951: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36175+if { (eval echo configure:5606: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36176   rm -rf conftest*
     36177   eval "ac_cv_lib_$ac_lib_var=yes"
     36178 else
     36179@@ -4995,7 +5650,7 @@
     36180       if test "$cf_have_libdir" = no ; then
     36181         test -n "$verbose" && echo "   adding $cf_add_libdir to library-path" 1>&6
     36182 
     36183-echo "${as_me-configure}:4999: testing adding $cf_add_libdir to library-path ..." 1>&5
     36184+echo "${as_me-configure}:5654: testing adding $cf_add_libdir to library-path ..." 1>&5
     36185 
     36186 
     36187         LDFLAGS="-L$cf_add_libdir $LDFLAGS"
     36188@@ -5010,12 +5665,12 @@
     36189        eval 'cf_cv_have_lib_'$cf_nculib_root'=no'
     36190        cf_libdir=""
     36191        echo $ac_n "checking for initscr""... $ac_c" 1>&6
     36192-echo "configure:5014: checking for initscr" >&5
     36193+echo "configure:5669: checking for initscr" >&5
     36194 if eval "test \"`echo '$''{'ac_cv_func_initscr'+set}'`\" = set"; then
     36195   echo $ac_n "(cached) $ac_c" 1>&6
     36196 else
     36197   cat > conftest.$ac_ext <<EOF
     36198-#line 5019 "configure"
     36199+#line 5674 "configure"
     36200 #include "confdefs.h"
     36201 /* System header to define __stub macros and hopefully few prototypes,
     36202     which can conflict with char initscr(); below.  */
     36203@@ -5038,7 +5693,7 @@
     36204 
     36205 ; return 0; }
     36206 EOF
     36207-if { (eval echo configure:5042: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36208+if { (eval echo configure:5697: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36209   rm -rf conftest*
     36210   eval "ac_cv_func_initscr=yes"
     36211 else
     36212@@ -5058,17 +5713,17 @@
     36213 
     36214                cf_save_LIBS="$LIBS"
     36215                echo $ac_n "checking for initscr in -l$cf_nculib_root""... $ac_c" 1>&6
     36216-echo "configure:5062: checking for initscr in -l$cf_nculib_root" >&5
     36217+echo "configure:5717: checking for initscr in -l$cf_nculib_root" >&5
     36218                LIBS="-l$cf_nculib_root $LIBS"
     36219                cat > conftest.$ac_ext <<EOF
     36220-#line 5065 "configure"
     36221+#line 5720 "configure"
     36222 #include "confdefs.h"
     36223 #include <${cf_cv_ncurses_header-curses.h}>
     36224 int main() {
     36225 initscr()
     36226 ; return 0; }
     36227 EOF
     36228-if { (eval echo configure:5072: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36229+if { (eval echo configure:5727: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36230   rm -rf conftest*
     36231   echo "$ac_t""yes" 1>&6
     36232                         eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
     36233@@ -5078,7 +5733,33 @@
     36234   cat conftest.$ac_ext >&5
     36235   rm -rf conftest*
     36236   echo "$ac_t""no" 1>&6
     36237-                       cf_search=""
     36238+                       
     36239+cf_library_path_list=""
     36240+if test -n "${LDFLAGS}${LIBS}" ; then
     36241+       for cf_library_path in $LDFLAGS $LIBS
     36242+       do
     36243+               case $cf_library_path in #(vi
     36244+               -L*)
     36245+                       cf_library_path=`echo ".$cf_library_path" |sed -e 's/^...//' -e 's,/lib$,,'`
     36246+                       
     36247+test "$cf_library_path" != "NONE" && \
     36248+test -d "$cf_library_path" && \
     36249+ {
     36250+       test -n "$verbose" && echo "    ... testing for lib-directories under $cf_library_path"
     36251+       test -d $cf_library_path/lib &&          cf_search="$cf_search $cf_library_path/lib"
     36252+       test -d $cf_library_path/lib/$cf_nculib_root &&       cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root"
     36253+       test -d $cf_library_path/lib/$cf_nculib_root/lib &&    cf_search="$cf_search $cf_library_path/lib/$cf_nculib_root/lib"
     36254+       test -d $cf_library_path/$cf_nculib_root/lib &&       cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib"
     36255+       test -d $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root &&    cf_search="$cf_search $cf_library_path/$cf_nculib_root/lib/$cf_nculib_root"
     36256+}
     36257+
     36258+                       cf_library_path_list="$cf_library_path_list $cf_search"
     36259+                       ;;
     36260+               esac
     36261+       done
     36262+fi
     36263+
     36264+cf_search=""
     36265 
     36266 
     36267 test "/usr" != "$prefix" && \
     36268@@ -5141,20 +5822,23 @@
     36269 }
     36270 
     36271 
     36272+
     36273+cf_search="$cf_library_path_list $cf_search"
     36274+
     36275                        for cf_libdir in $cf_search
     36276                        do
     36277                                echo $ac_n "checking for -l$cf_nculib_root in $cf_libdir""... $ac_c" 1>&6
     36278-echo "configure:5148: checking for -l$cf_nculib_root in $cf_libdir" >&5
     36279+echo "configure:5832: checking for -l$cf_nculib_root in $cf_libdir" >&5
     36280                                LIBS="-L$cf_libdir -l$cf_nculib_root $cf_save_LIBS"
     36281                                cat > conftest.$ac_ext <<EOF
     36282-#line 5151 "configure"
     36283+#line 5835 "configure"
     36284 #include "confdefs.h"
     36285 #include <${cf_cv_ncurses_header-curses.h}>
     36286 int main() {
     36287 initscr()
     36288 ; return 0; }
     36289 EOF
     36290-if { (eval echo configure:5158: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36291+if { (eval echo configure:5842: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36292   rm -rf conftest*
     36293   echo "$ac_t""yes" 1>&6
     36294                                         eval 'cf_cv_have_lib_'$cf_nculib_root'=yes'
     36295@@ -5185,7 +5869,7 @@
     36296 
     36297 if test -n "$cf_ncurses_LIBS" ; then
     36298        echo $ac_n "checking if we can link $cf_nculib_root without $cf_ncurses_LIBS""... $ac_c" 1>&6
     36299-echo "configure:5189: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
     36300+echo "configure:5873: checking if we can link $cf_nculib_root without $cf_ncurses_LIBS" >&5
     36301        cf_ncurses_SAVE="$LIBS"
     36302        for p in $cf_ncurses_LIBS ; do
     36303                q=`echo $LIBS | sed -e "s%$p %%" -e "s%$p$%%"`
     36304@@ -5194,14 +5878,14 @@
     36305                fi
     36306        done
     36307        cat > conftest.$ac_ext <<EOF
     36308-#line 5198 "configure"
     36309+#line 5882 "configure"
     36310 #include "confdefs.h"
     36311 #include <${cf_cv_ncurses_header-curses.h}>
     36312 int main() {
     36313 initscr(); mousemask(0,0); tgoto((char *)0, 0, 0);
     36314 ; return 0; }
     36315 EOF
     36316-if { (eval echo configure:5205: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36317+if { (eval echo configure:5889: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36318   rm -rf conftest*
     36319   echo "$ac_t""yes" 1>&6
     36320 else
     36321@@ -5222,6 +5906,9 @@
     36322 EOF
     36323 
     36324 
     36325+
     36326+fi
     36327+
     36328        ;;
     36329 pdcurses) #(vi
     36330        if test "$no_x" = yes; then
     36331@@ -5244,17 +5931,17 @@
     36332     case "`(uname -sr) 2>/dev/null`" in
     36333     "SunOS 5"*)
     36334       echo $ac_n "checking whether -R must be followed by a space""... $ac_c" 1>&6
     36335-echo "configure:5248: checking whether -R must be followed by a space" >&5
     36336+echo "configure:5935: checking whether -R must be followed by a space" >&5
     36337       ac_xsave_LIBS="$LIBS"; LIBS="$LIBS -R$x_libraries"
     36338       cat > conftest.$ac_ext <<EOF
     36339-#line 5251 "configure"
     36340+#line 5938 "configure"
     36341 #include "confdefs.h"
     36342 
     36343 int main() {
     36344 
     36345 ; return 0; }
     36346 EOF
     36347-if { (eval echo configure:5258: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36348+if { (eval echo configure:5945: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36349   rm -rf conftest*
     36350   ac_R_nospace=yes
     36351 else
     36352@@ -5270,14 +5957,14 @@
     36353       else
     36354        LIBS="$ac_xsave_LIBS -R $x_libraries"
     36355        cat > conftest.$ac_ext <<EOF
     36356-#line 5274 "configure"
     36357+#line 5961 "configure"
     36358 #include "confdefs.h"
     36359 
     36360 int main() {
     36361 
     36362 ; return 0; }
     36363 EOF
     36364-if { (eval echo configure:5281: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36365+if { (eval echo configure:5968: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36366   rm -rf conftest*
     36367   ac_R_space=yes
     36368 else
     36369@@ -5309,7 +5996,7 @@
     36370     # libraries were built with DECnet support.  And karl@cs.umb.edu says
     36371     # the Alpha needs dnet_stub (dnet does not exist).
     36372     echo $ac_n "checking for dnet_ntoa in -ldnet""... $ac_c" 1>&6
     36373-echo "configure:5313: checking for dnet_ntoa in -ldnet" >&5
     36374+echo "configure:6000: checking for dnet_ntoa in -ldnet" >&5
     36375 ac_lib_var=`echo dnet'_'dnet_ntoa | sed 'y%./+-%__p_%'`
     36376 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     36377   echo $ac_n "(cached) $ac_c" 1>&6
     36378@@ -5317,7 +6004,7 @@
     36379   ac_save_LIBS="$LIBS"
     36380 LIBS="-ldnet  $LIBS"
     36381 cat > conftest.$ac_ext <<EOF
     36382-#line 5321 "configure"
     36383+#line 6008 "configure"
     36384 #include "confdefs.h"
     36385 /* Override any gcc2 internal prototype to avoid an error.  */
     36386 /* We use char because int might match the return type of a gcc2
     36387@@ -5328,7 +6015,7 @@
     36388 dnet_ntoa()
     36389 ; return 0; }
     36390 EOF
     36391-if { (eval echo configure:5332: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36392+if { (eval echo configure:6019: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36393   rm -rf conftest*
     36394   eval "ac_cv_lib_$ac_lib_var=yes"
     36395 else
     36396@@ -5350,7 +6037,7 @@
     36397 
     36398     if test $ac_cv_lib_dnet_dnet_ntoa = no; then
     36399       echo $ac_n "checking for dnet_ntoa in -ldnet_stub""... $ac_c" 1>&6
     36400-echo "configure:5354: checking for dnet_ntoa in -ldnet_stub" >&5
     36401+echo "configure:6041: checking for dnet_ntoa in -ldnet_stub" >&5
     36402 ac_lib_var=`echo dnet_stub'_'dnet_ntoa | sed 'y%./+-%__p_%'`
     36403 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     36404   echo $ac_n "(cached) $ac_c" 1>&6
     36405@@ -5358,7 +6045,7 @@
     36406   ac_save_LIBS="$LIBS"
     36407 LIBS="-ldnet_stub  $LIBS"
     36408 cat > conftest.$ac_ext <<EOF
     36409-#line 5362 "configure"
     36410+#line 6049 "configure"
     36411 #include "confdefs.h"
     36412 /* Override any gcc2 internal prototype to avoid an error.  */
     36413 /* We use char because int might match the return type of a gcc2
     36414@@ -5369,7 +6056,7 @@
     36415 dnet_ntoa()
     36416 ; return 0; }
     36417 EOF
     36418-if { (eval echo configure:5373: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36419+if { (eval echo configure:6060: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36420   rm -rf conftest*
     36421   eval "ac_cv_lib_$ac_lib_var=yes"
     36422 else
     36423@@ -5398,12 +6085,12 @@
     36424     # The nsl library prevents programs from opening the X display
     36425     # on Irix 5.2, according to dickey@clark.net.
     36426     echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
     36427-echo "configure:5402: checking for gethostbyname" >&5
     36428+echo "configure:6089: checking for gethostbyname" >&5
     36429 if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
     36430   echo $ac_n "(cached) $ac_c" 1>&6
     36431 else
     36432   cat > conftest.$ac_ext <<EOF
     36433-#line 5407 "configure"
     36434+#line 6094 "configure"
     36435 #include "confdefs.h"
     36436 /* System header to define __stub macros and hopefully few prototypes,
     36437     which can conflict with char gethostbyname(); below.  */
     36438@@ -5426,7 +6113,7 @@
     36439 
     36440 ; return 0; }
     36441 EOF
     36442-if { (eval echo configure:5430: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36443+if { (eval echo configure:6117: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36444   rm -rf conftest*
     36445   eval "ac_cv_func_gethostbyname=yes"
     36446 else
     36447@@ -5447,7 +6134,7 @@
     36448 
     36449     if test $ac_cv_func_gethostbyname = no; then
     36450       echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
     36451-echo "configure:5451: checking for gethostbyname in -lnsl" >&5
     36452+echo "configure:6138: checking for gethostbyname in -lnsl" >&5
     36453 ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
     36454 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     36455   echo $ac_n "(cached) $ac_c" 1>&6
     36456@@ -5455,7 +6142,7 @@
     36457   ac_save_LIBS="$LIBS"
     36458 LIBS="-lnsl  $LIBS"
     36459 cat > conftest.$ac_ext <<EOF
     36460-#line 5459 "configure"
     36461+#line 6146 "configure"
     36462 #include "confdefs.h"
     36463 /* Override any gcc2 internal prototype to avoid an error.  */
     36464 /* We use char because int might match the return type of a gcc2
     36465@@ -5466,7 +6153,7 @@
     36466 gethostbyname()
     36467 ; return 0; }
     36468 EOF
     36469-if { (eval echo configure:5470: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36470+if { (eval echo configure:6157: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36471   rm -rf conftest*
     36472   eval "ac_cv_lib_$ac_lib_var=yes"
     36473 else
     36474@@ -5496,12 +6183,12 @@
     36475     # -lsocket must be given before -lnsl if both are needed.
     36476     # We assume that if connect needs -lnsl, so does gethostbyname.
     36477     echo $ac_n "checking for connect""... $ac_c" 1>&6
     36478-echo "configure:5500: checking for connect" >&5
     36479+echo "configure:6187: checking for connect" >&5
     36480 if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
     36481   echo $ac_n "(cached) $ac_c" 1>&6
     36482 else
     36483   cat > conftest.$ac_ext <<EOF
     36484-#line 5505 "configure"
     36485+#line 6192 "configure"
     36486 #include "confdefs.h"
     36487 /* System header to define __stub macros and hopefully few prototypes,
     36488     which can conflict with char connect(); below.  */
     36489@@ -5524,7 +6211,7 @@
     36490 
     36491 ; return 0; }
     36492 EOF
     36493-if { (eval echo configure:5528: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36494+if { (eval echo configure:6215: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36495   rm -rf conftest*
     36496   eval "ac_cv_func_connect=yes"
     36497 else
     36498@@ -5545,7 +6232,7 @@
     36499 
     36500     if test $ac_cv_func_connect = no; then
     36501       echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
     36502-echo "configure:5549: checking for connect in -lsocket" >&5
     36503+echo "configure:6236: checking for connect in -lsocket" >&5
     36504 ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
     36505 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     36506   echo $ac_n "(cached) $ac_c" 1>&6
     36507@@ -5553,7 +6240,7 @@
     36508   ac_save_LIBS="$LIBS"
     36509 LIBS="-lsocket $X_EXTRA_LIBS $LIBS"
     36510 cat > conftest.$ac_ext <<EOF
     36511-#line 5557 "configure"
     36512+#line 6244 "configure"
     36513 #include "confdefs.h"
     36514 /* Override any gcc2 internal prototype to avoid an error.  */
     36515 /* We use char because int might match the return type of a gcc2
     36516@@ -5564,7 +6251,7 @@
     36517 connect()
     36518 ; return 0; }
     36519 EOF
     36520-if { (eval echo configure:5568: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36521+if { (eval echo configure:6255: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36522   rm -rf conftest*
     36523   eval "ac_cv_lib_$ac_lib_var=yes"
     36524 else
     36525@@ -5588,12 +6275,12 @@
     36526 
     36527     # gomez@mi.uni-erlangen.de says -lposix is necessary on A/UX.
     36528     echo $ac_n "checking for remove""... $ac_c" 1>&6
     36529-echo "configure:5592: checking for remove" >&5
     36530+echo "configure:6279: checking for remove" >&5
     36531 if eval "test \"`echo '$''{'ac_cv_func_remove'+set}'`\" = set"; then
     36532   echo $ac_n "(cached) $ac_c" 1>&6
     36533 else
     36534   cat > conftest.$ac_ext <<EOF
     36535-#line 5597 "configure"
     36536+#line 6284 "configure"
     36537 #include "confdefs.h"
     36538 /* System header to define __stub macros and hopefully few prototypes,
     36539     which can conflict with char remove(); below.  */
     36540@@ -5616,7 +6303,7 @@
     36541 
     36542 ; return 0; }
     36543 EOF
     36544-if { (eval echo configure:5620: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36545+if { (eval echo configure:6307: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36546   rm -rf conftest*
     36547   eval "ac_cv_func_remove=yes"
     36548 else
     36549@@ -5637,7 +6324,7 @@
     36550 
     36551     if test $ac_cv_func_remove = no; then
     36552       echo $ac_n "checking for remove in -lposix""... $ac_c" 1>&6
     36553-echo "configure:5641: checking for remove in -lposix" >&5
     36554+echo "configure:6328: checking for remove in -lposix" >&5
     36555 ac_lib_var=`echo posix'_'remove | sed 'y%./+-%__p_%'`
     36556 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     36557   echo $ac_n "(cached) $ac_c" 1>&6
     36558@@ -5645,7 +6332,7 @@
     36559   ac_save_LIBS="$LIBS"
     36560 LIBS="-lposix  $LIBS"
     36561 cat > conftest.$ac_ext <<EOF
     36562-#line 5649 "configure"
     36563+#line 6336 "configure"
     36564 #include "confdefs.h"
     36565 /* Override any gcc2 internal prototype to avoid an error.  */
     36566 /* We use char because int might match the return type of a gcc2
     36567@@ -5656,7 +6343,7 @@
     36568 remove()
     36569 ; return 0; }
     36570 EOF
     36571-if { (eval echo configure:5660: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36572+if { (eval echo configure:6347: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36573   rm -rf conftest*
     36574   eval "ac_cv_lib_$ac_lib_var=yes"
     36575 else
     36576@@ -5680,12 +6367,12 @@
     36577 
     36578     # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay.
     36579     echo $ac_n "checking for shmat""... $ac_c" 1>&6
     36580-echo "configure:5684: checking for shmat" >&5
     36581+echo "configure:6371: checking for shmat" >&5
     36582 if eval "test \"`echo '$''{'ac_cv_func_shmat'+set}'`\" = set"; then
     36583   echo $ac_n "(cached) $ac_c" 1>&6
     36584 else
     36585   cat > conftest.$ac_ext <<EOF
     36586-#line 5689 "configure"
     36587+#line 6376 "configure"
     36588 #include "confdefs.h"
     36589 /* System header to define __stub macros and hopefully few prototypes,
     36590     which can conflict with char shmat(); below.  */
     36591@@ -5708,7 +6395,7 @@
     36592 
     36593 ; return 0; }
     36594 EOF
     36595-if { (eval echo configure:5712: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36596+if { (eval echo configure:6399: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36597   rm -rf conftest*
     36598   eval "ac_cv_func_shmat=yes"
     36599 else
     36600@@ -5729,7 +6416,7 @@
     36601 
     36602     if test $ac_cv_func_shmat = no; then
     36603       echo $ac_n "checking for shmat in -lipc""... $ac_c" 1>&6
     36604-echo "configure:5733: checking for shmat in -lipc" >&5
     36605+echo "configure:6420: checking for shmat in -lipc" >&5
     36606 ac_lib_var=`echo ipc'_'shmat | sed 'y%./+-%__p_%'`
     36607 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     36608   echo $ac_n "(cached) $ac_c" 1>&6
     36609@@ -5737,7 +6424,7 @@
     36610   ac_save_LIBS="$LIBS"
     36611 LIBS="-lipc  $LIBS"
     36612 cat > conftest.$ac_ext <<EOF
     36613-#line 5741 "configure"
     36614+#line 6428 "configure"
     36615 #include "confdefs.h"
     36616 /* Override any gcc2 internal prototype to avoid an error.  */
     36617 /* We use char because int might match the return type of a gcc2
     36618@@ -5748,7 +6435,7 @@
     36619 shmat()
     36620 ; return 0; }
     36621 EOF
     36622-if { (eval echo configure:5752: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36623+if { (eval echo configure:6439: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36624   rm -rf conftest*
     36625   eval "ac_cv_lib_$ac_lib_var=yes"
     36626 else
     36627@@ -5781,7 +6468,7 @@
     36628   # libraries we check for below, so use a different variable.
     36629   #  --interran@uluru.Stanford.EDU, kb@cs.umb.edu.
     36630   echo $ac_n "checking for IceConnectionNumber in -lICE""... $ac_c" 1>&6
     36631-echo "configure:5785: checking for IceConnectionNumber in -lICE" >&5
     36632+echo "configure:6472: checking for IceConnectionNumber in -lICE" >&5
     36633 ac_lib_var=`echo ICE'_'IceConnectionNumber | sed 'y%./+-%__p_%'`
     36634 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     36635   echo $ac_n "(cached) $ac_c" 1>&6
     36636@@ -5789,7 +6476,7 @@
     36637   ac_save_LIBS="$LIBS"
     36638 LIBS="-lICE $X_EXTRA_LIBS $LIBS"
     36639 cat > conftest.$ac_ext <<EOF
     36640-#line 5793 "configure"
     36641+#line 6480 "configure"
     36642 #include "confdefs.h"
     36643 /* Override any gcc2 internal prototype to avoid an error.  */
     36644 /* We use char because int might match the return type of a gcc2
     36645@@ -5800,7 +6487,7 @@
     36646 IceConnectionNumber()
     36647 ; return 0; }
     36648 EOF
     36649-if { (eval echo configure:5804: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36650+if { (eval echo configure:6491: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36651   rm -rf conftest*
     36652   eval "ac_cv_lib_$ac_lib_var=yes"
     36653 else
     36654@@ -5836,7 +6523,7 @@
     36655 
     36656 test -n "$verbose" && echo "   checking additions to CFLAGS" 1>&6
     36657 
     36658-echo "${as_me-configure}:5840: testing checking additions to CFLAGS ..." 1>&5
     36659+echo "${as_me-configure}:6527: testing checking additions to CFLAGS ..." 1>&5
     36660 
     36661 
     36662 cf_check_cflags="$CFLAGS"
     36663@@ -5898,7 +6585,7 @@
     36664 if test -n "$cf_new_cflags" ; then
     36665        test -n "$verbose" && echo "    add to \$CFLAGS $cf_new_cflags" 1>&6
     36666 
     36667-echo "${as_me-configure}:5902: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
     36668+echo "${as_me-configure}:6589: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
     36669 
     36670 
     36671        CFLAGS="$CFLAGS $cf_new_cflags"
     36672@@ -5907,16 +6594,16 @@
     36673 if test -n "$cf_new_cppflags" ; then
     36674        test -n "$verbose" && echo "    add to \$CPPFLAGS $cf_new_cppflags" 1>&6
     36675 
     36676-echo "${as_me-configure}:5911: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
     36677+echo "${as_me-configure}:6598: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
     36678 
     36679 
     36680-       CPPFLAGS="$cf_new_cppflags $CPPFLAGS"
     36681+       CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
     36682 fi
     36683 
     36684 if test -n "$cf_new_extra_cppflags" ; then
     36685        test -n "$verbose" && echo "    add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
     36686 
     36687-echo "${as_me-configure}:5920: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
     36688+echo "${as_me-configure}:6607: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
     36689 
     36690 
     36691        EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
     36692@@ -5927,14 +6614,14 @@
     36693 
     36694 if test "$cf_check_cflags" != "$CFLAGS" ; then
     36695 cat > conftest.$ac_ext <<EOF
     36696-#line 5931 "configure"
     36697+#line 6618 "configure"
     36698 #include "confdefs.h"
     36699 #include <stdio.h>
     36700 int main() {
     36701 printf("Hello world");
     36702 ; return 0; }
     36703 EOF
     36704-if { (eval echo configure:5938: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36705+if { (eval echo configure:6625: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36706   :
     36707 else
     36708   echo "configure: failed program was:" >&5
     36709@@ -5942,13 +6629,13 @@
     36710   rm -rf conftest*
     36711   test -n "$verbose" && echo " test-compile failed.  Undoing change to \$CFLAGS" 1>&6
     36712 
     36713-echo "${as_me-configure}:5946: testing test-compile failed.  Undoing change to \$CFLAGS ..." 1>&5
     36714+echo "${as_me-configure}:6633: testing test-compile failed.  Undoing change to \$CFLAGS ..." 1>&5
     36715 
     36716 
     36717         if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
     36718                 test -n "$verbose" && echo "   but keeping change to \$CPPFLAGS" 1>&6
     36719 
     36720-echo "${as_me-configure}:5952: testing but keeping change to \$CPPFLAGS ..." 1>&5
     36721+echo "${as_me-configure}:6639: testing but keeping change to \$CPPFLAGS ..." 1>&5
     36722 
     36723 
     36724         fi
     36725@@ -5959,12 +6646,12 @@
     36726 
     36727 
     36728 echo $ac_n "checking for XOpenDisplay""... $ac_c" 1>&6
     36729-echo "configure:5963: checking for XOpenDisplay" >&5
     36730+echo "configure:6650: checking for XOpenDisplay" >&5
     36731 if eval "test \"`echo '$''{'ac_cv_func_XOpenDisplay'+set}'`\" = set"; then
     36732   echo $ac_n "(cached) $ac_c" 1>&6
     36733 else
     36734   cat > conftest.$ac_ext <<EOF
     36735-#line 5968 "configure"
     36736+#line 6655 "configure"
     36737 #include "confdefs.h"
     36738 /* System header to define __stub macros and hopefully few prototypes,
     36739     which can conflict with char XOpenDisplay(); below.  */
     36740@@ -5987,7 +6674,7 @@
     36741 
     36742 ; return 0; }
     36743 EOF
     36744-if { (eval echo configure:5991: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36745+if { (eval echo configure:6678: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36746   rm -rf conftest*
     36747   eval "ac_cv_func_XOpenDisplay=yes"
     36748 else
     36749@@ -6006,7 +6693,7 @@
     36750   echo "$ac_t""no" 1>&6
     36751 
     36752 echo $ac_n "checking for XOpenDisplay in -lX11""... $ac_c" 1>&6
     36753-echo "configure:6010: checking for XOpenDisplay in -lX11" >&5
     36754+echo "configure:6697: checking for XOpenDisplay in -lX11" >&5
     36755 ac_lib_var=`echo X11'_'XOpenDisplay | sed 'y%./+-%__p_%'`
     36756 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     36757   echo $ac_n "(cached) $ac_c" 1>&6
     36758@@ -6014,7 +6701,7 @@
     36759   ac_save_LIBS="$LIBS"
     36760 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
     36761 cat > conftest.$ac_ext <<EOF
     36762-#line 6018 "configure"
     36763+#line 6705 "configure"
     36764 #include "confdefs.h"
     36765 /* Override any gcc2 internal prototype to avoid an error.  */
     36766 /* We use char because int might match the return type of a gcc2
     36767@@ -6025,7 +6712,7 @@
     36768 XOpenDisplay()
     36769 ; return 0; }
     36770 EOF
     36771-if { (eval echo configure:6029: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36772+if { (eval echo configure:6716: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36773   rm -rf conftest*
     36774   eval "ac_cv_lib_$ac_lib_var=yes"
     36775 else
     36776@@ -6049,12 +6736,12 @@
     36777 
     36778 
     36779 echo $ac_n "checking for XtAppInitialize""... $ac_c" 1>&6
     36780-echo "configure:6053: checking for XtAppInitialize" >&5
     36781+echo "configure:6740: checking for XtAppInitialize" >&5
     36782 if eval "test \"`echo '$''{'ac_cv_func_XtAppInitialize'+set}'`\" = set"; then
     36783   echo $ac_n "(cached) $ac_c" 1>&6
     36784 else
     36785   cat > conftest.$ac_ext <<EOF
     36786-#line 6058 "configure"
     36787+#line 6745 "configure"
     36788 #include "confdefs.h"
     36789 /* System header to define __stub macros and hopefully few prototypes,
     36790     which can conflict with char XtAppInitialize(); below.  */
     36791@@ -6077,7 +6764,7 @@
     36792 
     36793 ; return 0; }
     36794 EOF
     36795-if { (eval echo configure:6081: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36796+if { (eval echo configure:6768: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36797   rm -rf conftest*
     36798   eval "ac_cv_func_XtAppInitialize=yes"
     36799 else
     36800@@ -6096,7 +6783,7 @@
     36801   echo "$ac_t""no" 1>&6
     36802 
     36803 echo $ac_n "checking for XtAppInitialize in -lXt""... $ac_c" 1>&6
     36804-echo "configure:6100: checking for XtAppInitialize in -lXt" >&5
     36805+echo "configure:6787: checking for XtAppInitialize in -lXt" >&5
     36806 ac_lib_var=`echo Xt'_'XtAppInitialize | sed 'y%./+-%__p_%'`
     36807 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     36808   echo $ac_n "(cached) $ac_c" 1>&6
     36809@@ -6104,7 +6791,7 @@
     36810   ac_save_LIBS="$LIBS"
     36811 LIBS="-lXt $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
     36812 cat > conftest.$ac_ext <<EOF
     36813-#line 6108 "configure"
     36814+#line 6795 "configure"
     36815 #include "confdefs.h"
     36816 /* Override any gcc2 internal prototype to avoid an error.  */
     36817 /* We use char because int might match the return type of a gcc2
     36818@@ -6115,7 +6802,7 @@
     36819 XtAppInitialize()
     36820 ; return 0; }
     36821 EOF
     36822-if { (eval echo configure:6119: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36823+if { (eval echo configure:6806: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36824   rm -rf conftest*
     36825   eval "ac_cv_lib_$ac_lib_var=yes"
     36826 else
     36827@@ -6153,7 +6840,7 @@
     36828 cf_x_athena=${cf_x_athena-Xaw}
     36829 
     36830 echo $ac_n "checking if you want to link with Xaw 3d library""... $ac_c" 1>&6
     36831-echo "configure:6157: checking if you want to link with Xaw 3d library" >&5
     36832+echo "configure:6844: checking if you want to link with Xaw 3d library" >&5
     36833 withval=
     36834 
     36835 # Check whether --with-Xaw3d or --without-Xaw3d was given.
     36836@@ -6170,7 +6857,7 @@
     36837 fi
     36838 
     36839 echo $ac_n "checking if you want to link with neXT Athena library""... $ac_c" 1>&6
     36840-echo "configure:6174: checking if you want to link with neXT Athena library" >&5
     36841+echo "configure:6861: checking if you want to link with neXT Athena library" >&5
     36842 withval=
     36843 
     36844 # Check whether --with-neXtaw or --without-neXtaw was given.
     36845@@ -6187,7 +6874,7 @@
     36846 fi
     36847 
     36848 echo $ac_n "checking if you want to link with Athena-Plus library""... $ac_c" 1>&6
     36849-echo "configure:6191: checking if you want to link with Athena-Plus library" >&5
     36850+echo "configure:6878: checking if you want to link with Athena-Plus library" >&5
     36851 withval=
     36852 
     36853 # Check whether --with-XawPlus or --without-XawPlus was given.
     36854@@ -6204,7 +6891,7 @@
     36855 fi
     36856 
     36857 echo $ac_n "checking for XextCreateExtension in -lXext""... $ac_c" 1>&6
     36858-echo "configure:6208: checking for XextCreateExtension in -lXext" >&5
     36859+echo "configure:6895: checking for XextCreateExtension in -lXext" >&5
     36860 ac_lib_var=`echo Xext'_'XextCreateExtension | sed 'y%./+-%__p_%'`
     36861 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     36862   echo $ac_n "(cached) $ac_c" 1>&6
     36863@@ -6212,7 +6899,7 @@
     36864   ac_save_LIBS="$LIBS"
     36865 LIBS="-lXext  $LIBS"
     36866 cat > conftest.$ac_ext <<EOF
     36867-#line 6216 "configure"
     36868+#line 6903 "configure"
     36869 #include "confdefs.h"
     36870 /* Override any gcc2 internal prototype to avoid an error.  */
     36871 /* We use char because int might match the return type of a gcc2
     36872@@ -6223,7 +6910,7 @@
     36873 XextCreateExtension()
     36874 ; return 0; }
     36875 EOF
     36876-if { (eval echo configure:6227: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36877+if { (eval echo configure:6914: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36878   rm -rf conftest*
     36879   eval "ac_cv_lib_$ac_lib_var=yes"
     36880 else
     36881@@ -6260,15 +6947,15 @@
     36882                cf_save="$CPPFLAGS"
     36883                cf_test=X11/$cf_x_athena_root/SimpleMenu.h
     36884                if test $cf_path != default ; then
     36885-                       CPPFLAGS="-I$cf_path/include $cf_save"
     36886+                       CPPFLAGS="$cf_save -I$cf_path/include"
     36887                        echo $ac_n "checking for $cf_test in $cf_path""... $ac_c" 1>&6
     36888-echo "configure:6266: checking for $cf_test in $cf_path" >&5
     36889+echo "configure:6953: checking for $cf_test in $cf_path" >&5
     36890                else
     36891                        echo $ac_n "checking for $cf_test""... $ac_c" 1>&6
     36892-echo "configure:6269: checking for $cf_test" >&5
     36893+echo "configure:6956: checking for $cf_test" >&5
     36894                fi
     36895                cat > conftest.$ac_ext <<EOF
     36896-#line 6272 "configure"
     36897+#line 6959 "configure"
     36898 #include "confdefs.h"
     36899 
     36900 #include <X11/Intrinsic.h>
     36901@@ -6277,7 +6964,7 @@
     36902 
     36903 ; return 0; }
     36904 EOF
     36905-if { (eval echo configure:6281: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     36906+if { (eval echo configure:6968: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     36907   rm -rf conftest*
     36908   cf_result=yes
     36909 else
     36910@@ -6324,21 +7011,21 @@
     36911                        if test $cf_path != default ; then
     36912                                LIBS="-L$cf_path/lib $cf_lib $LIBS"
     36913                                echo $ac_n "checking for $cf_lib in $cf_path""... $ac_c" 1>&6
     36914-echo "configure:6328: checking for $cf_lib in $cf_path" >&5
     36915+echo "configure:7015: checking for $cf_lib in $cf_path" >&5
     36916                        else
     36917                                LIBS="$cf_lib $LIBS"
     36918                                echo $ac_n "checking for $cf_test in $cf_lib""... $ac_c" 1>&6
     36919-echo "configure:6332: checking for $cf_test in $cf_lib" >&5
     36920+echo "configure:7019: checking for $cf_test in $cf_lib" >&5
     36921                        fi
     36922                        cat > conftest.$ac_ext <<EOF
     36923-#line 6335 "configure"
     36924+#line 7022 "configure"
     36925 #include "confdefs.h"
     36926 
     36927 int main() {
     36928 $cf_test()
     36929 ; return 0; }
     36930 EOF
     36931-if { (eval echo configure:6342: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36932+if { (eval echo configure:7029: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     36933   rm -rf conftest*
     36934   cf_result=yes
     36935 else
     36936@@ -6379,7 +7066,7 @@
     36937 # Extract the first word of "$ac_prog", so it can be a program name with args.
     36938 set dummy $ac_prog; ac_word=$2
     36939 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
     36940-echo "configure:6383: checking for $ac_word" >&5
     36941+echo "configure:7070: checking for $ac_word" >&5
     36942 if eval "test \"`echo '$''{'ac_cv_path_XCURSES_CONFIG'+set}'`\" = set"; then
     36943   echo $ac_n "(cached) $ac_c" 1>&6
     36944 else
     36945@@ -6418,7 +7105,7 @@
     36946 
     36947 if test "$XCURSES_CONFIG" != none ; then
     36948 
     36949-CPPFLAGS="`$XCURSES_CONFIG --cflags` $CPPFLAGS"
     36950+CPPFLAGS="$CPPFLAGS `$XCURSES_CONFIG --cflags`"
     36951 LIBS="`$XCURSES_CONFIG --libs` $LIBS"
     36952 
     36953 cf_cv_lib_XCurses=yes
     36954@@ -6429,7 +7116,7 @@
     36955 
     36956 test -n "$verbose" && echo "   checking additions to CFLAGS" 1>&6
     36957 
     36958-echo "${as_me-configure}:6433: testing checking additions to CFLAGS ..." 1>&5
     36959+echo "${as_me-configure}:7120: testing checking additions to CFLAGS ..." 1>&5
     36960 
     36961 
     36962 cf_check_cflags="$CFLAGS"
     36963@@ -6491,7 +7178,7 @@
     36964 if test -n "$cf_new_cflags" ; then
     36965        test -n "$verbose" && echo "    add to \$CFLAGS $cf_new_cflags" 1>&6
     36966 
     36967-echo "${as_me-configure}:6495: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
     36968+echo "${as_me-configure}:7182: testing add to \$CFLAGS $cf_new_cflags ..." 1>&5
     36969 
     36970 
     36971        CFLAGS="$CFLAGS $cf_new_cflags"
     36972@@ -6500,16 +7187,16 @@
     36973 if test -n "$cf_new_cppflags" ; then
     36974        test -n "$verbose" && echo "    add to \$CPPFLAGS $cf_new_cppflags" 1>&6
     36975 
     36976-echo "${as_me-configure}:6504: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
     36977+echo "${as_me-configure}:7191: testing add to \$CPPFLAGS $cf_new_cppflags ..." 1>&5
     36978 
     36979 
     36980-       CPPFLAGS="$cf_new_cppflags $CPPFLAGS"
     36981+       CPPFLAGS="$CPPFLAGS $cf_new_cppflags"
     36982 fi
     36983 
     36984 if test -n "$cf_new_extra_cppflags" ; then
     36985        test -n "$verbose" && echo "    add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags" 1>&6
     36986 
     36987-echo "${as_me-configure}:6513: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
     36988+echo "${as_me-configure}:7200: testing add to \$EXTRA_CPPFLAGS $cf_new_extra_cppflags ..." 1>&5
     36989 
     36990 
     36991        EXTRA_CPPFLAGS="$cf_new_extra_cppflags $EXTRA_CPPFLAGS"
     36992@@ -6520,14 +7207,14 @@
     36993 
     36994 if test "$cf_check_cflags" != "$CFLAGS" ; then
     36995 cat > conftest.$ac_ext <<EOF
     36996-#line 6524 "configure"
     36997+#line 7211 "configure"
     36998 #include "confdefs.h"
     36999 #include <stdio.h>
     37000 int main() {
     37001 printf("Hello world");
     37002 ; return 0; }
     37003 EOF
     37004-if { (eval echo configure:6531: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37005+if { (eval echo configure:7218: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37006   :
     37007 else
     37008   echo "configure: failed program was:" >&5
     37009@@ -6535,13 +7222,13 @@
     37010   rm -rf conftest*
     37011   test -n "$verbose" && echo " test-compile failed.  Undoing change to \$CFLAGS" 1>&6
     37012 
     37013-echo "${as_me-configure}:6539: testing test-compile failed.  Undoing change to \$CFLAGS ..." 1>&5
     37014+echo "${as_me-configure}:7226: testing test-compile failed.  Undoing change to \$CFLAGS ..." 1>&5
     37015 
     37016 
     37017         if test "$cf_check_cppflags" != "$CPPFLAGS" ; then
     37018                 test -n "$verbose" && echo "   but keeping change to \$CPPFLAGS" 1>&6
     37019 
     37020-echo "${as_me-configure}:6545: testing but keeping change to \$CPPFLAGS ..." 1>&5
     37021+echo "${as_me-configure}:7232: testing but keeping change to \$CPPFLAGS ..." 1>&5
     37022 
     37023 
     37024         fi
     37025@@ -6551,7 +7238,7 @@
     37026 fi
     37027 
     37028 echo $ac_n "checking for XOpenDisplay in -lX11""... $ac_c" 1>&6
     37029-echo "configure:6555: checking for XOpenDisplay in -lX11" >&5
     37030+echo "configure:7242: checking for XOpenDisplay in -lX11" >&5
     37031 ac_lib_var=`echo X11'_'XOpenDisplay | sed 'y%./+-%__p_%'`
     37032 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     37033   echo $ac_n "(cached) $ac_c" 1>&6
     37034@@ -6559,7 +7246,7 @@
     37035   ac_save_LIBS="$LIBS"
     37036 LIBS="-lX11 $X_PRE_LIBS $LIBS $X_EXTRA_LIBS $LIBS"
     37037 cat > conftest.$ac_ext <<EOF
     37038-#line 6563 "configure"
     37039+#line 7250 "configure"
     37040 #include "confdefs.h"
     37041 /* Override any gcc2 internal prototype to avoid an error.  */
     37042 /* We use char because int might match the return type of a gcc2
     37043@@ -6570,7 +7257,7 @@
     37044 XOpenDisplay()
     37045 ; return 0; }
     37046 EOF
     37047-if { (eval echo configure:6574: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37048+if { (eval echo configure:7261: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37049   rm -rf conftest*
     37050   eval "ac_cv_lib_$ac_lib_var=yes"
     37051 else
     37052@@ -6591,14 +7278,14 @@
     37053 fi
     37054 
     37055 echo $ac_n "checking for XCurses library""... $ac_c" 1>&6
     37056-echo "configure:6595: checking for XCurses library" >&5
     37057+echo "configure:7282: checking for XCurses library" >&5
     37058 if eval "test \"`echo '$''{'cf_cv_lib_XCurses'+set}'`\" = set"; then
     37059   echo $ac_n "(cached) $ac_c" 1>&6
     37060 else
     37061   
     37062 LIBS="-lXCurses $LIBS"
     37063 cat > conftest.$ac_ext <<EOF
     37064-#line 6602 "configure"
     37065+#line 7289 "configure"
     37066 #include "confdefs.h"
     37067 
     37068 #include <xcurses.h>
     37069@@ -6608,7 +7295,7 @@
     37070 XCursesExit();
     37071 ; return 0; }
     37072 EOF
     37073-if { (eval echo configure:6612: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37074+if { (eval echo configure:7299: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37075   rm -rf conftest*
     37076   cf_cv_lib_XCurses=yes
     37077 else
     37078@@ -6653,7 +7340,7 @@
     37079 *)
     37080        # look for curses-related libraries
     37081        echo $ac_n "checking for new_panel in -lpanel$cf_cv_libtype""... $ac_c" 1>&6
     37082-echo "configure:6657: checking for new_panel in -lpanel$cf_cv_libtype" >&5
     37083+echo "configure:7344: checking for new_panel in -lpanel$cf_cv_libtype" >&5
     37084 ac_lib_var=`echo panel$cf_cv_libtype'_'new_panel | sed 'y%./+-%__p_%'`
     37085 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     37086   echo $ac_n "(cached) $ac_c" 1>&6
     37087@@ -6661,7 +7348,7 @@
     37088   ac_save_LIBS="$LIBS"
     37089 LIBS="-lpanel$cf_cv_libtype  $LIBS"
     37090 cat > conftest.$ac_ext <<EOF
     37091-#line 6665 "configure"
     37092+#line 7352 "configure"
     37093 #include "confdefs.h"
     37094 /* Override any gcc2 internal prototype to avoid an error.  */
     37095 /* We use char because int might match the return type of a gcc2
     37096@@ -6672,7 +7359,7 @@
     37097 new_panel()
     37098 ; return 0; }
     37099 EOF
     37100-if { (eval echo configure:6676: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37101+if { (eval echo configure:7363: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37102   rm -rf conftest*
     37103   eval "ac_cv_lib_$ac_lib_var=yes"
     37104 else
     37105@@ -6700,7 +7387,7 @@
     37106 fi
     37107 
     37108        echo $ac_n "checking for menu_driver in -lmenu$cf_cv_libtype""... $ac_c" 1>&6
     37109-echo "configure:6704: checking for menu_driver in -lmenu$cf_cv_libtype" >&5
     37110+echo "configure:7391: checking for menu_driver in -lmenu$cf_cv_libtype" >&5
     37111 ac_lib_var=`echo menu$cf_cv_libtype'_'menu_driver | sed 'y%./+-%__p_%'`
     37112 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     37113   echo $ac_n "(cached) $ac_c" 1>&6
     37114@@ -6708,7 +7395,7 @@
     37115   ac_save_LIBS="$LIBS"
     37116 LIBS="-lmenu$cf_cv_libtype  $LIBS"
     37117 cat > conftest.$ac_ext <<EOF
     37118-#line 6712 "configure"
     37119+#line 7399 "configure"
     37120 #include "confdefs.h"
     37121 /* Override any gcc2 internal prototype to avoid an error.  */
     37122 /* We use char because int might match the return type of a gcc2
     37123@@ -6719,7 +7406,7 @@
     37124 menu_driver()
     37125 ; return 0; }
     37126 EOF
     37127-if { (eval echo configure:6723: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37128+if { (eval echo configure:7410: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37129   rm -rf conftest*
     37130   eval "ac_cv_lib_$ac_lib_var=yes"
     37131 else
     37132@@ -6747,7 +7434,7 @@
     37133 fi
     37134 
     37135        echo $ac_n "checking for form_driver in -lform$cf_cv_libtype""... $ac_c" 1>&6
     37136-echo "configure:6751: checking for form_driver in -lform$cf_cv_libtype" >&5
     37137+echo "configure:7438: checking for form_driver in -lform$cf_cv_libtype" >&5
     37138 ac_lib_var=`echo form$cf_cv_libtype'_'form_driver | sed 'y%./+-%__p_%'`
     37139 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
     37140   echo $ac_n "(cached) $ac_c" 1>&6
     37141@@ -6755,7 +7442,7 @@
     37142   ac_save_LIBS="$LIBS"
     37143 LIBS="-lform$cf_cv_libtype  $LIBS"
     37144 cat > conftest.$ac_ext <<EOF
     37145-#line 6759 "configure"
     37146+#line 7446 "configure"
     37147 #include "confdefs.h"
     37148 /* Override any gcc2 internal prototype to avoid an error.  */
     37149 /* We use char because int might match the return type of a gcc2
     37150@@ -6766,7 +7453,7 @@
     37151 form_driver()
     37152 ; return 0; }
     37153 EOF
     37154-if { (eval echo configure:6770: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37155+if { (eval echo configure:7457: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37156   rm -rf conftest*
     37157   eval "ac_cv_lib_$ac_lib_var=yes"
     37158 else
     37159@@ -6805,17 +7492,17 @@
     37160 do
     37161 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
     37162 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
     37163-echo "configure:6809: checking for $ac_hdr" >&5
     37164+echo "configure:7496: checking for $ac_hdr" >&5
     37165 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
     37166   echo $ac_n "(cached) $ac_c" 1>&6
     37167 else
     37168   cat > conftest.$ac_ext <<EOF
     37169-#line 6814 "configure"
     37170+#line 7501 "configure"
     37171 #include "confdefs.h"
     37172 #include <$ac_hdr>
     37173 EOF
     37174 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
     37175-{ (eval echo configure:6819: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     37176+{ (eval echo configure:7506: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     37177 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
     37178 if test -z "$ac_err"; then
     37179   rm -rf conftest*
     37180@@ -6845,12 +7532,12 @@
     37181 esac
     37182 
     37183 echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
     37184-echo "configure:6849: checking return type of signal handlers" >&5
     37185+echo "configure:7536: checking return type of signal handlers" >&5
     37186 if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
     37187   echo $ac_n "(cached) $ac_c" 1>&6
     37188 else
     37189   cat > conftest.$ac_ext <<EOF
     37190-#line 6854 "configure"
     37191+#line 7541 "configure"
     37192 #include "confdefs.h"
     37193 #include <sys/types.h>
     37194 #include <signal.h>
     37195@@ -6867,7 +7554,7 @@
     37196 int i;
     37197 ; return 0; }
     37198 EOF
     37199-if { (eval echo configure:6871: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     37200+if { (eval echo configure:7558: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     37201   rm -rf conftest*
     37202   ac_cv_type_signal=void
     37203 else
     37204@@ -6887,12 +7574,12 @@
     37205 
     37206 
     37207 echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
     37208-echo "configure:6891: checking for ANSI C header files" >&5
     37209+echo "configure:7578: checking for ANSI C header files" >&5
     37210 if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
     37211   echo $ac_n "(cached) $ac_c" 1>&6
     37212 else
     37213   cat > conftest.$ac_ext <<EOF
     37214-#line 6896 "configure"
     37215+#line 7583 "configure"
     37216 #include "confdefs.h"
     37217 #include <stdlib.h>
     37218 #include <stdarg.h>
     37219@@ -6900,7 +7587,7 @@
     37220 #include <float.h>
     37221 EOF
     37222 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
     37223-{ (eval echo configure:6904: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     37224+{ (eval echo configure:7591: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     37225 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
     37226 if test -z "$ac_err"; then
     37227   rm -rf conftest*
     37228@@ -6917,7 +7604,7 @@
     37229 if test $ac_cv_header_stdc = yes; then
     37230   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
     37231 cat > conftest.$ac_ext <<EOF
     37232-#line 6921 "configure"
     37233+#line 7608 "configure"
     37234 #include "confdefs.h"
     37235 #include <string.h>
     37236 EOF
     37237@@ -6935,7 +7622,7 @@
     37238 if test $ac_cv_header_stdc = yes; then
     37239   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
     37240 cat > conftest.$ac_ext <<EOF
     37241-#line 6939 "configure"
     37242+#line 7626 "configure"
     37243 #include "confdefs.h"
     37244 #include <stdlib.h>
     37245 EOF
     37246@@ -6956,7 +7643,7 @@
     37247   :
     37248 else
     37249   cat > conftest.$ac_ext <<EOF
     37250-#line 6960 "configure"
     37251+#line 7647 "configure"
     37252 #include "confdefs.h"
     37253 #include <ctype.h>
     37254 #define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
     37255@@ -6967,7 +7654,7 @@
     37256 exit (0); }
     37257 
     37258 EOF
     37259-if { (eval echo configure:6971: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     37260+if { (eval echo configure:7658: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     37261 then
     37262   :
     37263 else
     37264@@ -6991,12 +7678,12 @@
     37265 fi
     37266 
     37267 echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
     37268-echo "configure:6995: checking whether time.h and sys/time.h may both be included" >&5
     37269+echo "configure:7682: checking whether time.h and sys/time.h may both be included" >&5
     37270 if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
     37271   echo $ac_n "(cached) $ac_c" 1>&6
     37272 else
     37273   cat > conftest.$ac_ext <<EOF
     37274-#line 7000 "configure"
     37275+#line 7687 "configure"
     37276 #include "confdefs.h"
     37277 #include <sys/types.h>
     37278 #include <sys/time.h>
     37279@@ -7005,7 +7692,7 @@
     37280 struct tm *tp;
     37281 ; return 0; }
     37282 EOF
     37283-if { (eval echo configure:7009: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     37284+if { (eval echo configure:7696: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     37285   rm -rf conftest*
     37286   ac_cv_header_time=yes
     37287 else
     37288@@ -7038,17 +7725,17 @@
     37289 do
     37290 ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
     37291 echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
     37292-echo "configure:7042: checking for $ac_hdr" >&5
     37293+echo "configure:7729: checking for $ac_hdr" >&5
     37294 if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
     37295   echo $ac_n "(cached) $ac_c" 1>&6
     37296 else
     37297   cat > conftest.$ac_ext <<EOF
     37298-#line 7047 "configure"
     37299+#line 7734 "configure"
     37300 #include "confdefs.h"
     37301 #include <$ac_hdr>
     37302 EOF
     37303 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
     37304-{ (eval echo configure:7052: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     37305+{ (eval echo configure:7739: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
     37306 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
     37307 if test -z "$ac_err"; then
     37308   rm -rf conftest*
     37309@@ -7089,12 +7776,12 @@
     37310 
     37311 do
     37312 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
     37313-echo "configure:7093: checking for $ac_func" >&5
     37314+echo "configure:7780: checking for $ac_func" >&5
     37315 if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
     37316   echo $ac_n "(cached) $ac_c" 1>&6
     37317 else
     37318   cat > conftest.$ac_ext <<EOF
     37319-#line 7098 "configure"
     37320+#line 7785 "configure"
     37321 #include "confdefs.h"
     37322 /* System header to define __stub macros and hopefully few prototypes,
     37323     which can conflict with char $ac_func(); below.  */
     37324@@ -7117,7 +7804,7 @@
     37325 
     37326 ; return 0; }
     37327 EOF
     37328-if { (eval echo configure:7121: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37329+if { (eval echo configure:7808: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37330   rm -rf conftest*
     37331   eval "ac_cv_func_$ac_func=yes"
     37332 else
     37333@@ -7144,13 +7831,13 @@
     37334 
     37335 
     37336 echo $ac_n "checking if we must define _XOPEN_SOURCE_EXTENDED""... $ac_c" 1>&6
     37337-echo "configure:7148: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5
     37338+echo "configure:7835: checking if we must define _XOPEN_SOURCE_EXTENDED" >&5
     37339 if eval "test \"`echo '$''{'cf_cv_need_xopen_extension'+set}'`\" = set"; then
     37340   echo $ac_n "(cached) $ac_c" 1>&6
     37341 else
     37342   
     37343 cat > conftest.$ac_ext <<EOF
     37344-#line 7154 "configure"
     37345+#line 7841 "configure"
     37346 #include "confdefs.h"
     37347 
     37348 #include <stdlib.h>
     37349@@ -7162,7 +7849,7 @@
     37350        getbegyx(stdscr, y1, x1)
     37351 ; return 0; }
     37352 EOF
     37353-if { (eval echo configure:7166: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37354+if { (eval echo configure:7853: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37355   rm -rf conftest*
     37356   cf_cv_need_xopen_extension=no
     37357 else
     37358@@ -7170,7 +7857,7 @@
     37359   cat conftest.$ac_ext >&5
     37360   rm -rf conftest*
     37361   cat > conftest.$ac_ext <<EOF
     37362-#line 7174 "configure"
     37363+#line 7861 "configure"
     37364 #include "confdefs.h"
     37365 
     37366 #define _XOPEN_SOURCE_EXTENDED
     37367@@ -7183,7 +7870,7 @@
     37368        getbegyx(stdscr, y1, x1)
     37369 ; return 0; }
     37370 EOF
     37371-if { (eval echo configure:7187: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37372+if { (eval echo configure:7874: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37373   rm -rf conftest*
     37374   cf_cv_need_xopen_extension=yes
     37375 else
     37376@@ -7202,7 +7889,7 @@
     37377 
     37378 
     37379 echo $ac_n "checking for term.h""... $ac_c" 1>&6
     37380-echo "configure:7206: checking for term.h" >&5
     37381+echo "configure:7893: checking for term.h" >&5
     37382 if eval "test \"`echo '$''{'cf_cv_term_header'+set}'`\" = set"; then
     37383   echo $ac_n "(cached) $ac_c" 1>&6
     37384 else
     37385@@ -7215,7 +7902,7 @@
     37386        term.h
     37387 do
     37388        cat > conftest.$ac_ext <<EOF
     37389-#line 7219 "configure"
     37390+#line 7906 "configure"
     37391 #include "confdefs.h"
     37392 
     37393 #include <${cf_cv_ncurses_header-curses.h}>
     37394@@ -7224,7 +7911,7 @@
     37395 WINDOW *x
     37396 ; return 0; }
     37397 EOF
     37398-if { (eval echo configure:7228: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     37399+if { (eval echo configure:7915: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     37400   rm -rf conftest*
     37401   cf_cv_term_header=$cf_header
     37402         break
     37403@@ -7301,9 +7988,9 @@
     37404 cf_tr_func=`echo "$cf_func" | sed y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%`
     37405 
     37406        echo $ac_n "checking for ${cf_func}""... $ac_c" 1>&6
     37407-echo "configure:7305: checking for ${cf_func}" >&5
     37408+echo "configure:7992: checking for ${cf_func}" >&5
     37409       
     37410-echo "${as_me-configure}:7307: testing ${cf_func} ..." 1>&5
     37411+echo "${as_me-configure}:7994: testing ${cf_func} ..." 1>&5
     37412 
     37413        if eval "test \"`echo '$''{'cf_cv_func_$cf_func'+set}'`\" = set"; then
     37414   echo $ac_n "(cached) $ac_c" 1>&6
     37415@@ -7312,7 +7999,7 @@
     37416                eval cf_result='$ac_cv_func_'$cf_func
     37417                if test ".$cf_result" != ".no"; then
     37418                        cat > conftest.$ac_ext <<EOF
     37419-#line 7316 "configure"
     37420+#line 8003 "configure"
     37421 #include "confdefs.h"
     37422 
     37423 #ifdef HAVE_XCURSES
     37424@@ -7341,7 +8028,7 @@
     37425                       
     37426 ; return 0; }
     37427 EOF
     37428-if { (eval echo configure:7345: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37429+if { (eval echo configure:8032: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37430   rm -rf conftest*
     37431   cf_result=yes
     37432 else
     37433@@ -7369,13 +8056,13 @@
     37434 
     37435 
     37436 echo $ac_n "checking for ncurses extended functions""... $ac_c" 1>&6
     37437-echo "configure:7373: checking for ncurses extended functions" >&5
     37438+echo "configure:8060: checking for ncurses extended functions" >&5
     37439 if eval "test \"`echo '$''{'cf_cv_ncurses_ext_funcs'+set}'`\" = set"; then
     37440   echo $ac_n "(cached) $ac_c" 1>&6
     37441 else
     37442   
     37443 cat > conftest.$ac_ext <<EOF
     37444-#line 7379 "configure"
     37445+#line 8066 "configure"
     37446 #include "confdefs.h"
     37447 
     37448 #include <${cf_cv_ncurses_header-curses.h}>
     37449@@ -7395,7 +8082,7 @@
     37450        (void) wresize (0, 0, 0);
     37451 ; return 0; }
     37452 EOF
     37453-if { (eval echo configure:7399: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37454+if { (eval echo configure:8086: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37455   rm -rf conftest*
     37456   cf_cv_ncurses_ext_funcs=yes
     37457 else
     37458@@ -7415,13 +8102,13 @@
     37459 
     37460 
     37461 echo $ac_n "checking for wide-character functions""... $ac_c" 1>&6
     37462-echo "configure:7419: checking for wide-character functions" >&5
     37463+echo "configure:8106: checking for wide-character functions" >&5
     37464 if eval "test \"`echo '$''{'cf_cv_widechar_funcs'+set}'`\" = set"; then
     37465   echo $ac_n "(cached) $ac_c" 1>&6
     37466 else
     37467   
     37468 cat > conftest.$ac_ext <<EOF
     37469-#line 7425 "configure"
     37470+#line 8112 "configure"
     37471 #include "confdefs.h"
     37472 
     37473 #include <${cf_cv_ncurses_header-curses.h}>
     37474@@ -7433,7 +8120,7 @@
     37475       
     37476 ; return 0; }
     37477 EOF
     37478-if { (eval echo configure:7437: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37479+if { (eval echo configure:8124: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37480   rm -rf conftest*
     37481   cf_cv_widechar_funcs=yes
     37482 else
     37483@@ -7461,13 +8148,13 @@
     37484 
     37485 
     37486 echo $ac_n "checking if sys/time.h works with sys/select.h""... $ac_c" 1>&6
     37487-echo "configure:7465: checking if sys/time.h works with sys/select.h" >&5
     37488+echo "configure:8152: checking if sys/time.h works with sys/select.h" >&5
     37489 if eval "test \"`echo '$''{'cf_cv_sys_time_select'+set}'`\" = set"; then
     37490   echo $ac_n "(cached) $ac_c" 1>&6
     37491 else
     37492   
     37493 cat > conftest.$ac_ext <<EOF
     37494-#line 7471 "configure"
     37495+#line 8158 "configure"
     37496 #include "confdefs.h"
     37497 
     37498 #include <sys/types.h>
     37499@@ -7482,7 +8169,7 @@
     37500 
     37501 ; return 0; }
     37502 EOF
     37503-if { (eval echo configure:7486: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     37504+if { (eval echo configure:8173: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     37505   rm -rf conftest*
     37506   cf_cv_sys_time_select=yes
     37507 else
     37508@@ -7503,7 +8190,7 @@
     37509 
     37510 
     37511 echo $ac_n "checking for function curses_version""... $ac_c" 1>&6
     37512-echo "configure:7507: checking for function curses_version" >&5
     37513+echo "configure:8194: checking for function curses_version" >&5
     37514 if eval "test \"`echo '$''{'cf_cv_func_curses_version'+set}'`\" = set"; then
     37515   echo $ac_n "(cached) $ac_c" 1>&6
     37516 else
     37517@@ -7512,7 +8199,7 @@
     37518   cf_cv_func_curses_version=unknown
     37519 else
     37520   cat > conftest.$ac_ext <<EOF
     37521-#line 7516 "configure"
     37522+#line 8203 "configure"
     37523 #include "confdefs.h"
     37524 
     37525 #include <${cf_cv_ncurses_header-curses.h}>
     37526@@ -7524,7 +8211,7 @@
     37527 }
     37528 
     37529 EOF
     37530-if { (eval echo configure:7528: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     37531+if { (eval echo configure:8215: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
     37532 then
     37533   cf_cv_func_curses_version=yes
     37534 
     37535@@ -7548,17 +8235,33 @@
     37536 
     37537 
     37538 
     37539+echo $ac_n "checking for ncurses wrap-prefix""... $ac_c" 1>&6
     37540+echo "configure:8240: checking for ncurses wrap-prefix" >&5
     37541+
     37542+# Check whether --with-ncurses-wrap-prefix or --without-ncurses-wrap-prefix was given.
     37543+if test "${with_ncurses_wrap_prefix+set}" = set; then
     37544+  withval="$with_ncurses_wrap_prefix"
     37545+  NCURSES_WRAP_PREFIX=$withval
     37546+else
     37547+  NCURSES_WRAP_PREFIX=_nc_
     37548+fi
     37549+
     37550+echo "$ac_t""$NCURSES_WRAP_PREFIX" 1>&6
     37551+
     37552+
     37553+
     37554+
     37555 echo $ac_n "checking for alternate character set array""... $ac_c" 1>&6
     37556-echo "configure:7553: checking for alternate character set array" >&5
     37557+echo "configure:8256: checking for alternate character set array" >&5
     37558 if eval "test \"`echo '$''{'cf_cv_curses_acs_map'+set}'`\" = set"; then
     37559   echo $ac_n "(cached) $ac_c" 1>&6
     37560 else
     37561   
     37562 cf_cv_curses_acs_map=unknown
     37563-for name in acs_map _acs_map __acs_map _nc_acs_map
     37564+for name in acs_map _acs_map __acs_map ${NCURSES_WRAP_PREFIX}acs_map
     37565 do
     37566 cat > conftest.$ac_ext <<EOF
     37567-#line 7562 "configure"
     37568+#line 8265 "configure"
     37569 #include "confdefs.h"
     37570 
     37571 #include <${cf_cv_ncurses_header-curses.h}>
     37572@@ -7569,7 +8272,7 @@
     37573 
     37574 ; return 0; }
     37575 EOF
     37576-if { (eval echo configure:7573: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37577+if { (eval echo configure:8276: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37578   rm -rf conftest*
     37579   cf_cv_curses_acs_map=$name; break
     37580 else
     37581@@ -7590,7 +8293,7 @@
     37582 
     37583 
     37584 echo $ac_n "checking for wide alternate character set array""... $ac_c" 1>&6
     37585-echo "configure:7594: checking for wide alternate character set array" >&5
     37586+echo "configure:8297: checking for wide alternate character set array" >&5
     37587 if eval "test \"`echo '$''{'cf_cv_curses_wacs_map'+set}'`\" = set"; then
     37588   echo $ac_n "(cached) $ac_c" 1>&6
     37589 else
     37590@@ -7599,7 +8302,7 @@
     37591        for name in wacs_map _wacs_map __wacs_map _nc_wacs
     37592        do
     37593        cat > conftest.$ac_ext <<EOF
     37594-#line 7603 "configure"
     37595+#line 8306 "configure"
     37596 #include "confdefs.h"
     37597 
     37598 #ifndef _XOPEN_SOURCE_EXTENDED
     37599@@ -7610,7 +8313,7 @@
     37600 $name['k'] = *WACS_PLUS
     37601 ; return 0; }
     37602 EOF
     37603-if { (eval echo configure:7614: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37604+if { (eval echo configure:8317: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
     37605   rm -rf conftest*
     37606   cf_cv_curses_wacs_map=$name
     37607         break
     37608@@ -7626,9 +8329,9 @@
     37609 
     37610 
     37611 echo $ac_n "checking for type attr_t in ${cf_cv_ncurses_header-curses.h}""... $ac_c" 1>&6
     37612-echo "configure:7630: checking for type attr_t in ${cf_cv_ncurses_header-curses.h}" >&5
     37613+echo "configure:8333: checking for type attr_t in ${cf_cv_ncurses_header-curses.h}" >&5
     37614 cat > conftest.$ac_ext <<EOF
     37615-#line 7632 "configure"
     37616+#line 8335 "configure"
     37617 #include "confdefs.h"
     37618 
     37619 #ifndef _XOPEN_SOURCE_EXTENDED
     37620@@ -7641,7 +8344,7 @@
     37621 
     37622 ; return 0; }
     37623 EOF
     37624-if { (eval echo configure:7645: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     37625+if { (eval echo configure:8348: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     37626   rm -rf conftest*
     37627   cf_result=yes
     37628 else
     37629@@ -7669,9 +8372,9 @@
     37630 
     37631 
     37632 echo $ac_n "checking for type mbstate_t in ${cf_cv_ncurses_header-curses.h}""... $ac_c" 1>&6
     37633-echo "configure:7673: checking for type mbstate_t in ${cf_cv_ncurses_header-curses.h}" >&5
     37634+echo "configure:8376: checking for type mbstate_t in ${cf_cv_ncurses_header-curses.h}" >&5
     37635 cat > conftest.$ac_ext <<EOF
     37636-#line 7675 "configure"
     37637+#line 8378 "configure"
     37638 #include "confdefs.h"
     37639 
     37640 #ifndef _XOPEN_SOURCE_EXTENDED
     37641@@ -7684,7 +8387,7 @@
     37642 
     37643 ; return 0; }
     37644 EOF
     37645-if { (eval echo configure:7688: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     37646+if { (eval echo configure:8391: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
     37647   rm -rf conftest*
     37648   cf_result=yes
     37649 else
     37650@@ -7891,11 +8594,13 @@
     37651 s%@SHOW_CC@%$SHOW_CC%g
     37652 s%@ECHO_CC@%$ECHO_CC%g
     37653 s%@EXTRA_CFLAGS@%$EXTRA_CFLAGS%g
     37654+s%@NCURSES_CONFIG@%$NCURSES_CONFIG%g
     37655 s%@X_CFLAGS@%$X_CFLAGS%g
     37656 s%@X_PRE_LIBS@%$X_PRE_LIBS%g
     37657 s%@X_LIBS@%$X_LIBS%g
     37658 s%@X_EXTRA_LIBS@%$X_EXTRA_LIBS%g
     37659 s%@XCURSES_CONFIG@%$XCURSES_CONFIG%g
     37660+s%@NCURSES_WRAP_PREFIX@%$NCURSES_WRAP_PREFIX%g
     37661 
     37662 CEOF
     37663 EOF
     37664diff -Naur ncurses-5.7.orig/test/configure.in ncurses-5.7/test/configure.in
     37665--- ncurses-5.7.orig/test/configure.in  2008-09-06 15:10:23.000000000 -0700
     37666+++ ncurses-5.7/test/configure.in       2009-06-05 14:01:30.000000000 -0700
     37667@@ -28,7 +28,7 @@
     37668 dnl
     37669 dnl Author: Thomas E. Dickey 1996, etc.
     37670 dnl
     37671-dnl $Id: configure.in,v 1.67 2008/09/06 22:10:23 tom Exp $
     37672+dnl $Id: configure.in,v 1.68 2009/03/28 19:49:55 tom Exp $
     37673 dnl This is a simple configuration-script for the ncurses test programs that
     37674 dnl allows the test-directory to be separately configured against a reference
     37675 dnl system (i.e., sysvr4 curses)
     37676@@ -125,14 +125,12 @@
     37677        CF_CURSES_LIBS
     37678        ;;
     37679 ncurses)
     37680-       CF_NCURSES_CPPFLAGS
     37681-       CF_NCURSES_LIBS
     37682+       CF_NCURSES_CONFIG
     37683        ;;
     37684 ncursesw)
     37685        cf_cv_libtype=w
     37686        CF_UTF8_LIB
     37687-       CF_NCURSES_CPPFLAGS(ncursesw)
     37688-       CF_NCURSES_LIBS(ncursesw)
     37689+       CF_NCURSES_CONFIG(ncursesw)
     37690        ;;
     37691 pdcurses) #(vi
     37692        CF_PDCURSES_X11
    2141437693diff -Naur ncurses-5.7.orig/test/demo_forms.c ncurses-5.7/test/demo_forms.c
    2141537694--- ncurses-5.7.orig/test/demo_forms.c  2008-10-18 13:38:20.000000000 -0700
    21416 +++ ncurses-5.7/test/demo_forms.c       2009-02-28 20:38:42.990334962 -0800
     37695+++ ncurses-5.7/test/demo_forms.c       2009-06-05 14:01:55.000000000 -0700
     37696@@ -1,5 +1,5 @@
     37697 /****************************************************************************
     37698- * Copyright (c) 2003-2007,2008 Free Software Foundation, Inc.              *
     37699+ * Copyright (c) 2003-2008,2009 Free Software Foundation, Inc.              *
     37700  *                                                                          *
     37701  * Permission is hereby granted, free of charge, to any person obtaining a  *
     37702  * copy of this software and associated documentation files (the            *
    2141737703@@ -26,7 +26,7 @@
    2141837704  * authorization.                                                           *
     
    2142037706 /*
    2142137707- * $Id: demo_forms.c,v 1.30 2008/10/18 20:38:20 tom Exp $
    21422 + * $Id: demo_forms.c,v 1.31 2008/12/20 19:23:00 tom Exp $
     37708+ * $Id: demo_forms.c,v 1.32 2009/05/30 16:52:42 tom Exp $
    2142337709  *
    2142437710  * Demonstrate a variety of functions from the form library.
     
    2144737733            set_field_buffer(f, 0, t_value);
    2144837734     }
     37735@@ -444,8 +451,11 @@
     37736 
     37737        free_form(form);
     37738     }
     37739-    for (c = 0; f[c] != 0; c++)
     37740+    for (c = 0; f[c] != 0; c++) {
     37741+       void *ptr = field_userptr(f[c]);
     37742+       free(ptr);
     37743        free_field(f[c]);
     37744+    }
     37745     noraw();
     37746     nl();
     37747 
     37748diff -Naur ncurses-5.7.orig/test/ditto.c ncurses-5.7/test/ditto.c
     37749--- ncurses-5.7.orig/test/ditto.c       2008-08-04 06:21:41.000000000 -0700
     37750+++ ncurses-5.7/test/ditto.c    2009-06-05 14:01:49.000000000 -0700
     37751@@ -29,7 +29,7 @@
     37752 /*
     37753  * Author: Thomas E. Dickey (1998-on)
     37754  *
     37755- * $Id: ditto.c,v 1.32 2008/08/04 13:21:41 tom Exp $
     37756+ * $Id: ditto.c,v 1.33 2008/11/16 00:19:59 juergen Exp $
     37757  *
     37758  * The program illustrates how to set up multiple screens from a single
     37759  * program.
     37760@@ -137,8 +137,8 @@
     37761 {
     37762     int result = -1;
     37763     if (peek->sequence < fifo->sequence) {
     37764-       peek->sequence += 1;
     37765        result = fifo->data[THIS_FIFO(peek->sequence)];
     37766+       peek->sequence += 1;
     37767     }
     37768     return result;
     37769 }
     37770@@ -188,7 +188,11 @@
     37771 }
     37772 
     37773 static void
     37774-init_screen(SCREEN *sp GCC_UNUSED, void *arg)
     37775+init_screen(
     37776+#if HAVE_USE_WINDOW
     37777+              SCREEN *sp GCC_UNUSED,
     37778+#endif
     37779+              void *arg)
     37780 {
     37781     DITTO *target = (DITTO *) arg;
     37782     int high, wide;
     37783@@ -237,6 +241,7 @@
     37784     target->which1 = which1;
     37785     target->titles = source;
     37786     target->length = length;
     37787+    target->fifo.head = -1;
     37788     target->screen = newterm((char *) 0,       /* assume $TERM is the same */
     37789                             target->output,
     37790                             target->input);
     37791@@ -248,7 +253,11 @@
     37792 }
     37793 
     37794 static int
     37795-close_screen(SCREEN *sp GCC_UNUSED, void *arg GCC_UNUSED)
     37796+close_screen(
     37797+#if HAVE_USE_WINDOW
     37798+               SCREEN *sp GCC_UNUSED,
     37799+#endif
     37800+               void *arg GCC_UNUSED)
     37801 {
     37802     (void) sp;
     37803     (void) arg;
     37804@@ -259,7 +268,11 @@
     37805  * Read data from the 'source' screen.
     37806  */
     37807 static int
     37808-read_screen(SCREEN *sp GCC_UNUSED, void *arg)
     37809+read_screen(
     37810+#if HAVE_USE_WINDOW
     37811+              SCREEN *sp GCC_UNUSED,
     37812+#endif
     37813+              void *arg)
     37814 {
     37815     DDATA *data = (DDATA *) arg;
     37816     DITTO *ditto = &(data->ditto[data->source]);
     37817@@ -278,7 +291,11 @@
     37818  * Write all of the data that's in fifos for the 'target' screen.
     37819  */
     37820 static int
     37821-write_screen(SCREEN *sp GCC_UNUSED, void *arg GCC_UNUSED)
     37822+write_screen(
     37823+#if HAVE_USE_WINDOW
     37824+               SCREEN *sp GCC_UNUSED,
     37825+#endif
     37826+               void *arg GCC_UNUSED)
     37827 {
     37828     DDATA *data = (DDATA *) arg;
     37829     DITTO *ditto = &(data->ditto[data->target]);
     37830@@ -360,7 +377,7 @@
     37831 
     37832     if (argc <= 1)
     37833        usage();
     37834-
     37835+   
     37836     if ((data = typeCalloc(DITTO, (size_t) argc)) == 0)
     37837        failed("calloc data");
     37838 
    2144937839diff -Naur ncurses-5.7.orig/test/edit_field.c ncurses-5.7/test/edit_field.c
    2145037840--- ncurses-5.7.orig/test/edit_field.c  2008-10-18 13:40:20.000000000 -0700
    21451 +++ ncurses-5.7/test/edit_field.c       2009-02-28 20:38:42.990334962 -0800
     37841+++ ncurses-5.7/test/edit_field.c       2009-06-05 14:00:59.000000000 -0700
    2145237842@@ -26,7 +26,7 @@
    2145337843  * authorization.                                                           *
     
    2147237862diff -Naur ncurses-5.7.orig/test/edit_field.h ncurses-5.7/test/edit_field.h
    2147337863--- ncurses-5.7.orig/test/edit_field.h  2006-06-03 09:38:57.000000000 -0700
    21474 +++ ncurses-5.7/test/edit_field.h       2009-02-28 20:38:42.990334962 -0800
     37864+++ ncurses-5.7/test/edit_field.h       2009-06-05 14:00:59.000000000 -0700
    2147537865@@ -1,5 +1,5 @@
    2147637866 /****************************************************************************
     
    2150237892diff -Naur ncurses-5.7.orig/test/filter.c ncurses-5.7/test/filter.c
    2150337893--- ncurses-5.7.orig/test/filter.c      2006-12-09 08:53:47.000000000 -0800
    21504 +++ ncurses-5.7/test/filter.c   2009-02-28 20:38:39.770130185 -0800
     37894+++ ncurses-5.7/test/filter.c   2009-06-05 14:00:55.000000000 -0700
    2150537895@@ -1,5 +1,5 @@
    2150637896 /****************************************************************************
     
    2157437964diff -Naur ncurses-5.7.orig/test/insdelln.c ncurses-5.7/test/insdelln.c
    2157537965--- ncurses-5.7.orig/test/insdelln.c    1969-12-31 16:00:00.000000000 -0800
    21576 +++ ncurses-5.7/test/insdelln.c 2009-02-28 20:38:42.990334962 -0800
     37966+++ ncurses-5.7/test/insdelln.c 2009-06-05 14:00:59.000000000 -0700
    2157737967@@ -0,0 +1,380 @@
    2157837968+/****************************************************************************
     
    2195838348diff -Naur ncurses-5.7.orig/test/modules ncurses-5.7/test/modules
    2195938349--- ncurses-5.7.orig/test/modules       2007-08-18 10:57:08.000000000 -0700
    21960 +++ ncurses-5.7/test/modules    2009-02-28 20:38:42.990334962 -0800
     38350+++ ncurses-5.7/test/modules    2009-06-05 14:00:59.000000000 -0700
    2196138351@@ -1,4 +1,4 @@
    2196238352-# $Id: modules,v 1.36 2007/08/18 17:57:08 tom Exp $
     
    2198338373diff -Naur ncurses-5.7.orig/test/ncurses.c ncurses-5.7/test/ncurses.c
    2198438374--- ncurses-5.7.orig/test/ncurses.c     2008-09-27 07:34:58.000000000 -0700
    21985 +++ ncurses-5.7/test/ncurses.c  2009-02-28 20:38:53.018977231 -0800
     38375+++ ncurses-5.7/test/ncurses.c  2009-06-05 14:01:49.000000000 -0700
     38376@@ -1,5 +1,5 @@
     38377 /****************************************************************************
     38378- * Copyright (c) 1998-2007,2008 Free Software Foundation, Inc.              *
     38379+ * Copyright (c) 1998-2008,2009 Free Software Foundation, Inc.              *
     38380  *                                                                          *
     38381  * Permission is hereby granted, free of charge, to any person obtaining a  *
     38382  * copy of this software and associated documentation files (the            *
    2198638383@@ -40,7 +40,7 @@
    2198738384    Author: Eric S. Raymond <esr@snark.thyrsus.com> 1993
     
    2198938386 
    2199038387-$Id: ncurses.c,v 1.329 2008/09/27 14:34:58 tom Exp $
    21991 +$Id: ncurses.c,v 1.336 2009/01/25 00:39:14 tom Exp $
     38388+$Id: ncurses.c,v 1.339 2009/04/04 22:46:11 juergen Exp $
    2199238389 
    2199338390 ***************************************************************************/
    2199438391 
    21995 @@ -569,8 +569,11 @@
     38392@@ -483,7 +483,11 @@
     38393        addstr("Shelling out...");
     38394     def_prog_mode();
     38395     endwin();
     38396+#ifdef __MINGW32__
     38397+    system("cmd.exe");
     38398+#else
     38399     system("sh");
     38400+#endif
     38401     if (message)
     38402        addstr("returned from shellout.\n");
     38403     refresh();
     38404@@ -569,8 +573,11 @@
    2199638405  *
    2199738406  ****************************************************************************/
     
    2200638415     keypad(win, flags['k']);   /* should be redundant, but for testing */
    2200738416     meta(win, flags['m']);     /* force this to a known state */
    22008 @@ -581,7 +584,17 @@
     38417@@ -581,7 +588,17 @@
    2200938418 }
    2201038419 
     
    2202538434     static const char *help[] =
    2202638435     {
    22027 @@ -731,13 +744,10 @@
     38436@@ -731,13 +748,10 @@
    2202838437     int first_y, first_x;
    2202938438     int c;
     
    2204138450     getyx(win, first_y, first_x);
    2204238451 
    22043 @@ -835,12 +845,18 @@
     38452@@ -835,12 +849,18 @@
    2204438453                }
    2204538454 #endif
     
    2206538474            } else {
    2206638475                if (isprint(c))
    22067 @@ -854,6 +870,9 @@
     38476@@ -854,6 +874,9 @@
    2206838477     }
    2206938478 
     
    2207538484 
    2207638485 static int
    22077 @@ -978,15 +997,12 @@
     38486@@ -905,6 +928,7 @@
     38487     wgetch_test(0, stdscr, delay);
     38488     forget_boxes();
     38489     finish_getch_test();
     38490+    slk_clear();
     38491 }
     38492 
     38493 #if USE_WIDEC_SUPPORT
     38494@@ -978,15 +1002,12 @@
    2207838495     int first_y, first_x;
    2207938496     wint_t c;
     
    2209338510     getyx(win, first_y, first_x);
    2209438511 
    22095 @@ -1096,14 +1112,14 @@
     38512@@ -1096,14 +1117,14 @@
    2209638513                    resize_wide_boxes(level, win);
    2209738514                }
     
    2211338530            }
    2211438531            wgetch_wrap(win, first_y);
    22115 @@ -1111,6 +1127,9 @@
     38532@@ -1111,6 +1132,9 @@
    2211638533     }
    2211738534 
     
    2212338540 
    2212438541 static void
    22125 @@ -1840,6 +1859,8 @@
     38542@@ -1122,6 +1146,7 @@
     38543     wget_wch_test(0, stdscr, delay);
     38544     forget_boxes();
     38545     finish_getch_test();
     38546+    slk_clear();
     38547 }
     38548 #endif
     38549 
     38550@@ -1840,6 +1865,8 @@
    2212638551            width = 4;
    2212738552        } else if (color >= 8) {
     
    2213238557            strcpy(temp, the_color_names[color]);
    2213338558        }
    22134 @@ -1874,6 +1895,8 @@
     38559@@ -1874,6 +1901,8 @@
    2213538560     mvwprintw(helpwin, row++, col,
    2213638561              "  n/N     toggle text/number on/off");
     
    2214138566 #if USE_WIDEC_SUPPORT
    2214238567     if (wide) {
    22143 @@ -1906,12 +1929,19 @@
     38568@@ -1906,12 +1935,19 @@
    2214438569     bool done = FALSE;
    2214538570     bool opt_acsc = FALSE;
     
    2216438589     while (!done) {
    2216538590        int shown = 0;
    22166 @@ -1926,12 +1956,14 @@
     38591@@ -1926,12 +1962,14 @@
    2216738592            hello = "Hello";
    2216838593            per_row = 8;
     
    2218138606        clrtobot();
    2218238607        (void) mvprintw(top + 1, 0,
    22183 @@ -1942,7 +1974,7 @@
     38608@@ -1942,7 +1980,7 @@
    2218438609 
    2218538610        /* show color names/numbers across the top */
     
    2219038615        /* show a grid of colors, with color names/ numbers on the left */
    2219138616        for (i = (short) (base_row * per_row); i < pairs_max; i++) {
    22192 @@ -1950,9 +1982,11 @@
     38617@@ -1950,9 +1988,11 @@
    2219338618            int col = (i % per_row + 1) * width;
    2219438619            short pair = i;
     
    2220438629                init_pair(pair, fg, bg);
    2220538630                attron((attr_t) COLOR_PAIR(pair));
    22206 @@ -1960,6 +1994,8 @@
     38631@@ -1960,6 +2000,8 @@
    2220738632                    attron((attr_t) A_ALTCHARSET);
    2220838633                if (opt_bold)
     
    2221338638                if (opt_nums) {
    2221438639                    sprintf(numbered, "{%02X}", i);
    22215 @@ -1968,8 +2004,8 @@
     38640@@ -1968,8 +2010,8 @@
    2221638641                printw("%-*.*s", width, width, hello);
    2221738642                attrset(A_NORMAL);
     
    2222438649                ++shown;
    2222538650            } else if (shown) {
    22226 @@ -1996,6 +2032,12 @@
     38651@@ -1996,6 +2038,12 @@
    2222738652        case 'N':
    2222838653            opt_nums = TRUE;
     
    2223738662            done = TRUE;
    2223838663            continue;
    22239 @@ -2073,7 +2115,7 @@
     38664@@ -2073,7 +2121,7 @@
    2224038665     int base_row = 0;
    2224138666     int grid_top = top + 3;
     
    2224638671     int per_row;
    2224738672     char numbered[80];
    22248 @@ -2081,12 +2123,22 @@
     38673@@ -2081,12 +2129,22 @@
    2224938674     bool done = FALSE;
    2225038675     bool opt_acsc = FALSE;
     
    2226938694        int shown = 0;
    2227038695 
    22271 @@ -2100,6 +2152,8 @@
     38696@@ -2100,6 +2158,8 @@
    2227238697            hello = "Hello";
    2227338698            per_row = 8;
     
    2227838703            make_fullwidth_text(buffer, hello);
    2227938704            width *= 2;
    22280 @@ -2111,8 +2165,9 @@
     38705@@ -2111,8 +2171,9 @@
    2228138706        row_limit = (pairs_max + per_row - 1) / per_row;
    2228238707 
     
    2229038715        clrtobot();
    2229138716        (void) mvprintw(top + 1, 0,
    22292 @@ -2123,7 +2178,7 @@
     38717@@ -2123,7 +2184,7 @@
    2229338718 
    2229438719        /* show color names/numbers across the top */
     
    2229938724        /* show a grid of colors, with color names/ numbers on the left */
    2230038725        for (i = (base_row * per_row); i < pairs_max; i++) {
    22301 @@ -2132,12 +2187,14 @@
     38726@@ -2132,12 +2193,14 @@
    2230238727            short pair = (short) i;
    2230338728 
     
    2231538740                if (opt_nums) {
    2231638741                    sprintf(numbered, "{%02X}", i);
    22317 @@ -2150,8 +2207,8 @@
     38742@@ -2150,8 +2213,8 @@
    2231838743                addnwstr(buffer, width);
    2231938744                attr_set(A_NORMAL, 0, NULL);
     
    2232638751                ++shown;
    2232738752            } else if (shown) {
    22328 @@ -2178,6 +2235,12 @@
     38753@@ -2178,6 +2241,12 @@
    2232938754        case 'N':
    2233038755            opt_nums = TRUE;
     
    2233938764            done = TRUE;
    2234038765            continue;
    22341 @@ -2802,6 +2865,7 @@
     38766@@ -2802,6 +2871,7 @@
    2234238767 } attrs_to_cycle[] = {
    2234338768     { A_NORMAL,                "normal" },
     
    2234738772     { A_UNDERLINE,     "underline" },
    2234838773 };
    22349 @@ -2902,7 +2966,7 @@
     38774@@ -2902,7 +2972,7 @@
    2235038775        do {
    2235138776            if (C1)
     
    2235638781                /* (yes, this _is_ crude) */
    2235738782                while ((reply = Getchar()) != ERR) {
    22358 @@ -2951,7 +3015,7 @@
     38783@@ -2951,7 +3021,7 @@
    2235938784                 */
    2236038785                break;
     
    2236538790            }
    2236638791        } while (--count > 0);
    22367 @@ -2969,15 +3033,23 @@
     38792@@ -2969,15 +3039,23 @@
    2236838793     mvaddstr(0, 20, "Display of the ACS Line-Drawing Set");
    2236938794     attroff(A_BOLD);
     
    2239738822 
    2239838823 }
    22399 @@ -3002,7 +3074,7 @@
     38824@@ -3002,7 +3080,7 @@
    2240038825 {
    2240138826     int n;
     
    2240638831     erase();
    2240738832     attron(A_BOLD);
    22408 @@ -3238,7 +3310,7 @@
     38833@@ -3212,7 +3290,7 @@
     38834             * the display.
     38835             */
     38836            if (wcwidth(code) == 0)
     38837-               addch(space | A_REVERSE);
     38838+               addch(space | (A_REVERSE ^ attr) | COLOR_PAIR(pair));
     38839            /*
     38840             * This could use add_wch(), but is done for comparison with the
     38841             * normal 'f' test (and to make a test-case for echo_wchar()).
     38842@@ -3238,7 +3316,7 @@
    2240938843     int col = (n / height) * COLS / 2;
    2241038844 
     
    2241538849     }
    2241638850     return n + 1;
    22417 @@ -3307,12 +3379,12 @@
     38851@@ -3307,12 +3385,12 @@
    2241838852 
    2241938853 #undef MERGE_ATTR
     
    2243038864     (void) repeat;
    2243138865     erase();
    22432 @@ -3321,17 +3393,23 @@
     38866@@ -3321,17 +3399,23 @@
    2243338867     attroff(A_BOLD);
    2243438868     refresh();
     
    2246438898 
    2246538899 }
    22466 @@ -5804,7 +5882,7 @@
     38900@@ -5804,7 +5888,7 @@
    2246738901        break;
    2246838902     case 2:
     
    2247538909diff -Naur ncurses-5.7.orig/test/programs ncurses-5.7/test/programs
    2247638910--- ncurses-5.7.orig/test/programs      2008-08-16 14:47:39.000000000 -0700
    22477 +++ ncurses-5.7/test/programs   2009-02-28 20:38:42.994335242 -0800
     38911+++ ncurses-5.7/test/programs   2009-06-05 14:00:59.000000000 -0700
    2247838912@@ -1,4 +1,4 @@
    2247938913-# $Id: programs,v 1.14 2008/08/16 21:47:39 tom Exp $
     
    2250038934diff -Naur ncurses-5.7.orig/test/railroad.c ncurses-5.7/test/railroad.c
    2250138935--- ncurses-5.7.orig/test/railroad.c    2008-02-09 10:08:43.000000000 -0800
    22502 +++ ncurses-5.7/test/railroad.c 2009-02-28 20:38:59.863415840 -0800
     38936+++ ncurses-5.7/test/railroad.c 2009-06-05 14:01:18.000000000 -0700
    2250338937@@ -29,7 +29,7 @@
    2250438938 /*
     
    2254738981diff -Naur ncurses-5.7.orig/test/README ncurses-5.7/test/README
    2254838982--- ncurses-5.7.orig/test/README        2008-10-18 14:02:45.000000000 -0700
    22549 +++ ncurses-5.7/test/README     2009-02-28 20:38:42.990334962 -0800
     38983+++ ncurses-5.7/test/README     2009-06-05 14:00:59.000000000 -0700
    2255038984@@ -25,7 +25,7 @@
    2255138985 -- sale, use or other dealings in this Software without prior written        --
     
    2284339277diff -Naur ncurses-5.7.orig/test/test.priv.h ncurses-5.7/test/test.priv.h
    2284439278--- ncurses-5.7.orig/test/test.priv.h   2008-10-04 14:53:41.000000000 -0700
    22845 +++ ncurses-5.7/test/test.priv.h        2009-02-28 20:38:42.994335242 -0800
     39279+++ ncurses-5.7/test/test.priv.h        2009-06-05 14:01:49.000000000 -0700
    2284639280@@ -29,7 +29,7 @@
    2284739281 /****************************************************************************
     
    2284939283  ****************************************************************************/
    2285039284-/* $Id: test.priv.h,v 1.79 2008/10/04 21:53:41 tom Exp $ */
    22851 +/* $Id: test.priv.h,v 1.80 2008/12/20 16:37:20 tom Exp $ */
     39285+/* $Id: test.priv.h,v 1.81 2008/12/28 20:20:39 juergen Exp $ */
    2285239286 
    2285339287 #ifndef __TEST_PRIV_H
     
    2286339297  * Workaround for HPUX
    2286439298  */
     39299@@ -464,6 +467,14 @@
     39300 #define EXIT_FAILURE 1
     39301 #endif
     39302 
     39303+#ifdef __MINGW32__
     39304+#include <nc_mingw.h>
     39305+/* conflicts in test/firstlast.c */
     39306+#undef large
     39307+#undef small
     39308+
     39309+#endif
     39310+
     39311 /* Use this to quiet gcc's -Wwrite-strings warnings, but accommodate SVr4
     39312  * curses which doesn't have const parameters declared (so far) in the places
     39313  * that XSI shows.
     39314@@ -560,7 +571,7 @@
     39315 #define USING_SCREEN(s,func,data) use_screen(s, (NCURSES_SCREEN_CB) func, data)
     39316 #define WANT_USE_SCREEN() extern void _nc_want_use_screen(void)
     39317 #else
     39318-#define USING_SCREEN(s,func,data) func(s,data)
     39319+#define USING_SCREEN(s,func,data) func(data)
     39320 #define WANT_USE_SCREEN() extern void _nc_want_use_screen(void)
     39321 #endif
     39322 
     39323diff -Naur ncurses-5.7.orig/test/view.c ncurses-5.7/test/view.c
     39324--- ncurses-5.7.orig/test/view.c        2008-09-06 15:10:50.000000000 -0700
     39325+++ ncurses-5.7/test/view.c     2009-06-05 14:01:49.000000000 -0700
     39326@@ -50,7 +50,7 @@
     39327  * scroll operation worked, and the refresh() code only had to do a
     39328  * partial repaint.
     39329  *
     39330- * $Id: view.c,v 1.69 2008/09/06 22:10:50 tom Exp $
     39331+ * $Id: view.c,v 1.70 2008/11/16 00:19:59 juergen Exp $
     39332  */
     39333 
     39334 #include <test.priv.h>
     39335@@ -62,8 +62,10 @@
     39336 #if HAVE_TERMIOS_H
     39337 # include <termios.h>
     39338 #else
     39339+#if !defined(__MINGW32__)
     39340 # include <sgtty.h>
     39341 #endif
     39342+#endif
     39343 
     39344 #if !defined(sun) || !HAVE_TERMIOS_H
     39345 # if HAVE_SYS_IOCTL_H
     39346diff -Naur ncurses-5.7.orig/test/worm.c ncurses-5.7/test/worm.c
     39347--- ncurses-5.7.orig/test/worm.c        2008-10-04 14:54:09.000000000 -0700
     39348+++ ncurses-5.7/test/worm.c     2009-06-05 14:01:49.000000000 -0700
     39349@@ -61,7 +61,7 @@
     39350   traces will be dumped.  The program stops and waits for one character of
     39351   input at the beginning and end of the interval.
     39352 
     39353-  $Id: worm.c,v 1.58 2008/10/04 21:54:09 tom Exp $
     39354+  $Id: worm.c,v 1.59 2008/11/16 00:19:59 juergen Exp $
     39355 */
     39356 
     39357 #include <test.priv.h>
     39358@@ -330,7 +330,11 @@
     39359     while (!quit_worm(((struct worm *) arg) - worm)) {
     39360        while (compare < sequence) {
     39361            ++compare;
     39362+#if HAVE_USE_WINDOW
     39363            use_window(stdscr, draw_worm, arg);
     39364+#else
     39365+           draw_worm(stdscr, arg);
     39366+#endif
     39367        }
     39368     }
     39369     Trace(("...start_worm (done)"));
     39370@@ -356,7 +360,13 @@
     39371     }
     39372 #else
     39373     for (n = 0, w = &worm[0]; n < number; n++, w++) {
     39374-       if (USING_WINDOW2(stdscr, draw_worm, w))
     39375+       if (
     39376+#if HAVE_USE_WINDOW
     39377+              USING_WINDOW2(stdscr, draw_worm, w)
     39378+#else
     39379+              draw_worm(stdscr, w)
     39380+#endif
     39381+           )
     39382            done = TRUE;
     39383     }
     39384 #endif
    2286539385diff -Naur ncurses-5.7.orig/TO-DO ncurses-5.7/TO-DO
    2286639386--- ncurses-5.7.orig/TO-DO      2008-10-11 12:22:27.000000000 -0700
    22867 +++ ncurses-5.7/TO-DO   2009-02-28 20:38:38.454044419 -0800
     39387+++ ncurses-5.7/TO-DO   2009-06-05 14:00:53.000000000 -0700
    2286839388@@ -25,7 +25,7 @@
    2286939389 -- sale, use or other dealings in this Software without prior written        --
Note: See TracChangeset for help on using the changeset viewer.