(Replaced by #8469)
[p5sagit/p5-mst-13.2.git] / Configure
index 677338c..b607c32 100755 (executable)
--- a/Configure
+++ b/Configure
 
 # $Id: Head.U,v 3.0.1.9 1997/02/28 15:02:09 ram Exp $
 #
-# Generated on Thu Nov  9 15:20:17 EET 2000 [metaconfig 3.0 PL70]
+# Generated on Wed Jan 17 05:17:19 EET 2001 [metaconfig 3.0 PL70]
 # (with additional metaconfig patches by perlbug@perl.org)
 
-cat >/tmp/c1$$ <<EOF
+cat >c1$$ <<EOF
 ARGGGHHHH!!!!!
 
 SCO csh still thinks true is false.  Write to SCO today and tell them that next
@@ -34,18 +34,18 @@ we'd have to do is go in and swap the && and || tokens, wherever they are.)
 
 [End of diatribe. We now return you to your regularly scheduled programming...]
 EOF
-cat >/tmp/c2$$ <<EOF
+cat >c2$$ <<EOF
 
 OOPS!  You naughty creature!  You didn't run Configure with sh!
 I will attempt to remedy the situation by running sh for you...
 EOF
 
-true || cat /tmp/c1$$ /tmp/c2$$
+true || cat c1$$ c2$$
 true || exec sh $0 $argv:q
 
-(exit $?0) || cat /tmp/c2$$
+(exit $?0) || cat c2$$
 (exit $?0) || exec sh $0 $argv:q
-rm -f /tmp/c1$$ /tmp/c2$$
+rm -f c1$$ c2$$
 
 : compute my invocation name
 me=$0
@@ -308,6 +308,7 @@ cppminus=''
 cpprun=''
 cppstdin=''
 crosscompile=''
+d__fwalk=''
 d_access=''
 d_accessx=''
 d_alarm=''
@@ -362,6 +363,7 @@ d_fs_data_s=''
 d_fseeko=''
 d_fsetpos=''
 d_fstatfs=''
+d_fsync=''
 d_ftello=''
 d_ftime=''
 d_gettimeod=''
@@ -386,6 +388,7 @@ d_getnbyaddr=''
 d_getnbyname=''
 d_getnent=''
 d_getnetprotos=''
+d_getpagsz=''
 d_getpent=''
 d_getpgid=''
 d_getpgrp2=''
@@ -475,6 +478,7 @@ d_rmdir=''
 d_safebcpy=''
 d_safemcpy=''
 d_sanemcmp=''
+d_sbrkproto=''
 d_select=''
 d_sem=''
 d_semctl=''
@@ -515,6 +519,7 @@ d_shmctl=''
 d_shmdt=''
 d_shmget=''
 d_sigaction=''
+d_sigprocmask=''
 d_sigsetjmp=''
 d_msg_ctrunc=''
 d_msg_dontroute=''
@@ -558,6 +563,7 @@ d_strtod=''
 d_strtol=''
 d_strtold=''
 d_strtoll=''
+d_strtoq=''
 d_strtoul=''
 d_strtoull=''
 d_strtouq=''
@@ -717,6 +723,7 @@ installusrbinperl=''
 intsize=''
 longsize=''
 shortsize=''
+issymlink=''
 libc=''
 ldlibpthname=''
 libperl=''
@@ -776,6 +783,7 @@ d_eofnblk=''
 eagain=''
 o_nonblock=''
 rd_nodata=''
+need_va_copy=''
 netdb_hlen_type=''
 netdb_host_type=''
 netdb_name_type=''
@@ -876,6 +884,7 @@ sig_name=''
 sig_name_init=''
 sig_num=''
 sig_num_init=''
+sig_size=''
 installsitearch=''
 sitearch=''
 sitearchexp=''
@@ -1427,6 +1436,7 @@ case "$src" in
     */*) src=`echo $0 | sed -e 's%/[^/][^/]*$%%'`
          case "$src" in
         /*)    ;;
+        .)     ;;
          *)    src=`cd ../$src && pwd` ;;
         esac
          ;;
@@ -2162,6 +2172,93 @@ else
 fi
 $rm -f blurfl sym
 
+: determine whether symbolic links are supported
+echo " "
+case "$lns" in
+*"ln -s")
+       echo "Checking how to test for symbolic links..." >&4
+       $lns blurfl sym
+       if $test "X$issymlink" = X; then
+               sh -c "PATH= test -h sym" >/dev/null 2>&1
+               if test $? = 0; then
+                       issymlink="test -h"
+               fi              
+       fi
+       if $test "X$issymlink" = X; then
+               if  $test -h >/dev/null 2>&1; then
+                       issymlink="$test -h"
+                       echo "Your builtin 'test -h' may be broken, I'm using external '$test -h'." >&4
+               fi              
+       fi
+       if $test "X$issymlink" = X; then
+               if $test -L sym 2>/dev/null; then
+                       issymlink="$test -L"
+               fi
+       fi
+       if $test "X$issymlink" != X; then
+               echo "You can test for symbolic links with '$issymlink'." >&4
+       else
+               echo "I do not know how you can test for symbolic links." >&4
+       fi
+       $rm -f blurfl sym
+       ;;
+*)     echo "No symbolic links, so not testing for their testing..." >&4
+       ;;
+esac
+echo " "
+
+
+case "$mksymlinks" in
+$define|true|[yY]*)
+       case "$src" in
+       ''|'.') echo "Cannot create symlinks in the original directory." >&4
+               exit 1
+               ;;
+       *)      case "$lns:$issymlink" in
+               *"ln -s:"*"test -"?)
+                       echo "Creating the symbolic links..." >&4
+                       echo "(First creating the subdirectories...)" >&4
+                       cd ..
+                       awk '{print $1}' $src/MANIFEST | grep / | sed 's:/[^/]*$::' | sort -u | while true; do
+                               read directory
+                               test -z "$directory" && break
+                               mkdir -p $directory
+                       done
+                       # Sanity check 1.
+                       if test ! -d t/base; then
+                               echo "Failed to create the subdirectories.  Aborting." >&4
+                               exit 1
+                       fi
+                       echo "(Then creating the symlinks...)" >&4
+                       awk '{print $1}' $src/MANIFEST | while true; do
+                               read filename
+                               test -z "$filename" && break
+                               if test -f $filename; then
+                                       if $issymlink $filename; then
+                                               rm -f $filename
+                                       fi
+                               fi
+                               if test -f $filename; then
+                                       echo "$filename already exists, not symlinking."
+                               else
+                                       ln -s $src/$filename $filename
+                               fi
+                       done
+                       # Sanity check 2.
+                       if test ! -f t/base/commonsense.t; then
+                               echo "Failed to create the symlinks.  Aborting." >&4
+                               exit 1
+                       fi
+                       cd UU
+                       ;;
+               *)      echo "(I cannot figure out how to do symbolic links, ignoring mksymlinks)." >&4
+                       ;;
+               esac
+               ;;
+       esac
+       ;;
+esac
+
 : see whether [:lower:] and [:upper:] are supported character classes
 echo " "
 case "`echo AbyZ | $tr '[:lower:]' '[:upper:]' 2>/dev/null`" in
@@ -3668,7 +3765,8 @@ esac
 cat <<EOM
 
 Perl can be built to use the SOCKS proxy protocol library.  To do so,
-Configure must be run with -Dusesocks.
+Configure must be run with -Dusesocks.  If you use SOCKS you also need
+to use the PerlIO abstraction layer, this will be implicitly selected.
 
 If this doesn't make any sense to you, just accept the default '$dflt'.
 EOM
@@ -3681,6 +3779,10 @@ esac
 set usesocks
 eval $setvar
 
+case "$usesocks" in
+$define|true|[yY]*) useperlio="$define";;
+esac
+
 : Looking for optional libraries
 echo " "
 echo "Checking for optional libraries..." >&4
@@ -4046,8 +4148,8 @@ and I got the following output:
 
 EOM
 dflt=y
-if sh -c "$cc -o try $optimize $ccflags $ldflags try.c $libs" >>try.msg 2>&1; then
-       if sh -c './try' >>try.msg 2>&1; then
+if $sh -c "$cc -o try $optimize $ccflags $ldflags try.c $libs" >>try.msg 2>&1; then
+       if $sh -c './try' >>try.msg 2>&1; then
                xxx=`./try`
                case "$xxx" in
                "Ok") dflt=n ;;
@@ -7423,13 +7525,12 @@ $define|true|[yY]*)     dflt='y';;
 esac
 cat <<EOM
 
-Previous version of $package used the standard IO mechanisms as defined
-in <stdio.h>.  Versions 5.003_02 and later of perl allow alternate IO
-mechanisms via a "PerlIO" abstraction, but the stdio mechanism is still
-the default.  This abstraction layer can use AT&T's sfio (if you already
-have sfio installed) or regular stdio.  Using PerlIO with sfio may cause
-problems with some extension modules.  Using PerlIO with stdio is safe,
-but it is slower than plain stdio and therefore is not the default.
+Previous version of $package used the standard IO mechanisms as
+defined in <stdio.h>.  Versions 5.003_02 and later of perl allow
+alternate IO mechanisms via the PerlIO abstraction layer, but the
+stdio mechanism is still the default.  This abstraction layer can
+use AT&T's sfio (if you already have sfio installed) or regular stdio.
+Using PerlIO with sfio may cause problems with some extension modules.
 
 If this doesn't make any sense to you, just accept the default '$dflt'.
 EOM
@@ -7440,13 +7541,29 @@ y|Y)
        val="$define"
        ;;     
 *)      
-       echo "Ok, doing things the stdio way"
+       echo "Ok, doing things the stdio way."
        val="$undef"
        ;;
 esac
 set useperlio
 eval $setvar 
 
+case "$usesocks" in
+$define|true|[yY]*)
+       case "$useperlio" in
+       $define|true|[yY]*) ;;
+       *)      cat >&4 <<EOM
+
+You are using the SOCKS proxy protocol library which means that you
+should also use the PerlIO layer.  You may be headed for trouble.
+
+EOM
+               ;;
+       esac
+       ;;
+esac
+
+       
 case "$vendorprefix" in
 '')    d_vendorbin="$undef"
        vendorbin=''
@@ -7752,6 +7869,10 @@ qgcvt) d_Gconvert='qgcvt((x),(n),(b))' ;;
    ;;  
 esac
 
+: see if _fwalk exists
+set fwalk d__fwalk
+eval $inlibc
+
 : Initialize h_fcntl
 h_fcntl=false
 
@@ -9275,6 +9396,10 @@ set fstatvfs d_fstatvfs
 eval $inlibc
 
 
+: see if fsync exists
+set fsync d_fsync
+eval $inlibc
+
 : see if ftello exists
 set ftello d_ftello
 eval $inlibc
@@ -9434,6 +9559,10 @@ echo " "
 set d_getnetprotos getnetent $i_netdb netdb.h
 eval $hasproto
 
+: see if getpagesize exists
+set getpagesize d_getpagsz
+eval $inlibc
+
 
 : see if getprotobyname exists
 set getprotobyname d_getpbyname
@@ -10880,6 +11009,11 @@ $rm -f try.* try core
 set d_sanemcmp
 eval $setvar
 
+: see if prototype for sbrk is available
+echo " "
+set d_sbrkproto sbrk $i_unistd unistd.h
+eval $hasproto
+
 : see if select exists
 set select d_select
 eval $inlibc
 set d_sigaction; eval $setvar
 $rm -f try try$_o try.c
 
+: see if sigprocmask exists
+set sigprocmask d_sigprocmask
+eval $inlibc
+
 : see if sigsetjmp exists
 echo " "
 case "$d_sigsetjmp" in
@@ -11885,10 +12023,87 @@ EOM
        ;;
 esac
 
+: see if strtoq exists
+set strtoq d_strtoq
+eval $inlibc
+
 : see if strtoul exists
 set strtoul d_strtoul
 eval $inlibc
 
+case "$d_strtoul" in
+"$define")
+       $cat <<EOM
+Checking whether your strtoul() works okay...
+EOM
+       $cat >try.c <<'EOCP'
+#include <errno.h>
+#include <stdio.h>
+extern unsigned long int strtoul(char *s, char **, int); 
+static int bad = 0;
+void check(char *s, unsigned long eul, int een) {
+       unsigned long gul;
+       errno = 0;
+       gul = strtoul(s, 0, 10);
+       if (!((gul == eul) && (errno == een)))
+               bad++;
+}
+int main() {
+       check(" 1", 1L, 0);
+       check(" 0", 0L, 0);
+EOCP
+       case "$longsize" in
+       8)
+           $cat >>try.c <<'EOCP'
+       check("18446744073709551615", 18446744073709551615UL, 0);
+       check("18446744073709551616", 18446744073709551615UL, ERANGE);
+#if 0 /* strtoul() for /^-/ strings is undefined. */
+       check("-1", 18446744073709551615UL, 0);
+       check("-18446744073709551614", 2, 0);
+       check("-18446744073709551615", 1, 0);
+               check("-18446744073709551616", 18446744073709551615UL, ERANGE);
+       check("-18446744073709551617", 18446744073709551615UL, ERANGE);
+#endif
+EOCP
+               ;;
+       4)
+                   $cat >>try.c <<'EOCP'
+       check("4294967295", 4294967295UL, 0);
+       check("4294967296", 4294967295UL, ERANGE);
+#if 0 /* strtoul() for /^-/ strings is undefined. */
+       check("-1", 4294967295UL, 0);
+       check("-4294967294", 2, 0);
+       check("-4294967295", 1, 0);
+               check("-4294967296", 4294967295UL, ERANGE);
+       check("-4294967297", 4294967295UL, ERANGE);
+#endif
+EOCP
+               ;;
+       *)
+: Should we write these tests to be more portable by sprintf-ing
+: ~0 and then manipulating that char string as input for strtol?
+               ;;
+       esac
+       $cat >>try.c <<'EOCP'
+       if (!bad)
+               printf("ok\n");
+       return 0;
+}
+EOCP
+       set try
+       if eval $compile; then
+               case "`./try`" in
+               ok) echo "Your strtoul() seems to be working okay." ;;
+               *) cat <<EOM >&4
+Your strtoul() doesn't seem to be working okay.
+EOM
+                  d_strtoul="$undef"
+                  ;;
+               esac
+       fi
+       ;;
+esac
+
 : see if strtoull exists
 set strtoull d_strtoull
 eval $inlibc
@@ -11914,10 +12129,17 @@ int check(char *s, long long eull, int een) {
                bad++;
 }
 int main() {
-       check(" 1",                                       1LL, 0);
-       check(" 0",                                       0LL, 0);
-       check("18446744073709551615", 18446744073709551615ULL, 0);
-       check("18446744073709551616", 18446744073709551615ULL, ERANGE);
+       check(" 1",                                        1LL, 0);
+       check(" 0",                                        0LL, 0);
+       check("18446744073709551615",  18446744073709551615ULL, 0);
+       check("18446744073709551616",  18446744073709551615ULL, ERANGE);
+#if 0 /* strtoull() for /^-/ strings is undefined. */
+       check("-1",                    18446744073709551615ULL, 0);
+       check("-18446744073709551614",                     2LL, 0);
+       check("-18446744073709551615",                     1LL, 0);
+               check("-18446744073709551616", 18446744073709551615ULL, ERANGE);
+       check("-18446744073709551617", 18446744073709551615ULL, ERANGE);
+#endif
        if (!bad)
                printf("ok\n");
 }
@@ -11940,6 +12162,54 @@ esac
 set strtouq d_strtouq
 eval $inlibc
 
+case "$d_strtouq" in
+"$define")
+       $cat <<EOM
+Checking whether your strtouq() works okay...
+EOM
+       $cat >try.c <<'EOCP'
+#include <errno.h>
+#include <stdio.h>
+extern unsigned long long int strtouq(char *s, char **, int); 
+static int bad = 0;
+void check(char *s, unsigned long long eull, int een) {
+       unsigned long long gull;
+       errno = 0;
+       gull = strtouq(s, 0, 10);
+       if (!((gull == eull) && (errno == een)))
+               bad++;
+}
+int main() {
+       check(" 1",                                        1LL, 0);
+       check(" 0",                                        0LL, 0);
+       check("18446744073709551615",  18446744073709551615ULL, 0);
+       check("18446744073709551616",  18446744073709551615ULL, ERANGE);
+#if 0 /* strtouq() for /^-/ strings is undefined. */
+       check("-1",                    18446744073709551615ULL, 0);
+       check("-18446744073709551614",                     2LL, 0);
+       check("-18446744073709551615",                     1LL, 0);
+               check("-18446744073709551616", 18446744073709551615ULL, ERANGE);
+       check("-18446744073709551617", 18446744073709551615ULL, ERANGE);
+#endif
+       if (!bad)
+               printf("ok\n");
+       return 0;
+}
+EOCP
+       set try
+       if eval $compile; then
+               case "`./try`" in
+               ok) echo "Your strtouq() seems to be working okay." ;;
+               *) cat <<EOM >&4
+Your strtouq() doesn't seem to be working okay.
+EOM
+                  d_strtouq="$undef"
+                  ;;
+               esac
+       fi
+       ;;
+esac
+
 : see if strxfrm exists
 set strxfrm d_strxfrm
 eval $inlibc
@@ -13440,6 +13710,168 @@ rp="What is the type used for file modes for system calls (e.g. fchmod())?"
 set mode_t modetype int stdio.h sys/types.h
 eval $typedef_ask
 
+: see if stdarg is available
+echo " "
+if $test `./findhdr stdarg.h`; then
+       echo "<stdarg.h> found." >&4
+       valstd="$define"
+else
+       echo "<stdarg.h> NOT found." >&4
+       valstd="$undef"
+fi
+
+: see if varags is available
+echo " "
+if $test `./findhdr varargs.h`; then
+       echo "<varargs.h> found." >&4
+else
+       echo "<varargs.h> NOT found, but that's ok (I hope)." >&4
+fi
+
+: set up the varargs testing programs
+$cat > varargs.c <<EOP
+#ifdef I_STDARG
+#include <stdarg.h>
+#endif
+#ifdef I_VARARGS
+#include <varargs.h>
+#endif
+
+#ifdef I_STDARG
+int f(char *p, ...)
+#else
+int f(va_alist)
+va_dcl
+#endif
+{
+       va_list ap;
+#ifndef I_STDARG
+       char *p;
+#endif
+#ifdef I_STDARG
+       va_start(ap,p);
+#else
+       va_start(ap);
+       p = va_arg(ap, char *);
+#endif
+       va_end(ap);
+}
+EOP
+$cat > varargs <<EOP
+$startsh
+if $cc -c $ccflags -D\$1 varargs.c >/dev/null 2>&1; then
+       echo "true"
+else
+       echo "false"
+fi
+$rm -f varargs$_o
+EOP
+chmod +x varargs
+
+: now check which varargs header should be included
+echo " "
+i_varhdr=''
+case "$valstd" in
+"$define")
+       if `./varargs I_STDARG`; then
+               val='stdarg.h'
+       elif `./varargs I_VARARGS`; then
+               val='varargs.h'
+       fi
+       ;;
+*)
+       if `./varargs I_VARARGS`; then
+               val='varargs.h'
+       fi
+       ;;
+esac
+case "$val" in
+'')
+echo "I could not find the definition for va_dcl... You have problems..." >&4
+       val="$undef"; set i_stdarg; eval $setvar
+       val="$undef"; set i_varargs; eval $setvar
+       ;;
+*) 
+       set i_varhdr
+       eval $setvar
+       case "$i_varhdr" in
+       stdarg.h)
+               val="$define"; set i_stdarg; eval $setvar
+               val="$undef"; set i_varargs; eval $setvar
+               ;;
+       varargs.h)
+               val="$undef"; set i_stdarg; eval $setvar
+               val="$define"; set i_varargs; eval $setvar
+               ;;
+       esac
+       echo "We'll include <$i_varhdr> to get va_dcl definition." >&4;;
+esac
+$rm -f varargs*
+
+: see if we need va_copy
+echo " "
+case "$i_stdarg" in
+"$define")
+       $cat >try.c <<EOCP
+#include <stdarg.h>
+#include <stdio.h>
+#$i_stdlib I_STDLIB
+#ifdef I_STDLIB
+#include <stdlib.h>
+#endif
+#include <signal.h>
+
+int
+ivfprintf(FILE *f, const char *fmt, va_list *valp)
+{
+  return vfprintf(f, fmt, *valp);
+}
+int    
+myvfprintf(FILE *f, const  char *fmt, va_list val)
+{
+  return ivfprintf(f, fmt, &val);
+}
+      
+int
+myprintf(char *fmt, ...) 
+{
+  va_list val;
+  va_start(val, fmt);
+  return myvfprintf(stdout, fmt, val); 
+}         
+
+int
+main(int ac, char **av)
+{
+  signal(SIGSEGV, exit);
+
+  myprintf("%s%cs all right, then\n", "that", '\'');                            
+  exit(0);      
+}
+EOCP
+       set try
+       if eval $compile && ./try 2>&1 >/dev/null; then
+               case "`./try`" in
+               "that's all right, then")
+                       okay=yes
+                       ;;
+               esac
+       fi
+       case "$okay" in
+       yes)    echo "It seems that you don't need va_copy()." >&4
+               need_va_copy="$undef"
+               ;;
+       *)      echo "It seems that va_copy() or similar will be needed." >&4
+               need_va_copy="$define"
+               ;;
+       esac
+       $rm -f try.* core core.* *.core *.core.*
+       ;;
+*)     echo "You don't have <stdarg.h>, not checking for va_copy()." >&4
+       ;;
+esac
+
 : define a fucntion to check prototypes
 $cat > protochk <<EOSH
 $startsh
@@ -14138,6 +14570,7 @@ echo $sig_name | $awk \
        }
        printf "\n"
 }'
+sig_size=`echo $sig_name | awk '{print NF}'`
 $rm -f signal signal.c signal.awk signal.lst signal_cmd 
 
 echo " "
@@ -14197,6 +14630,10 @@ $rm -f try try.*
 set d_socklen_t
 eval $setvar
 
+: see if this is a socks.h system
+set socks.h i_socks
+eval $inhdr
+
 : check for type of the size argument to socket calls
 case "$d_socket" in
 "$define")
@@ -14204,7 +14641,6 @@ case "$d_socket" in
 
 Checking to see what type is the last argument of accept().
 EOM
-       hdrs="$define sys/types.h $d_socket sys/socket.h" 
        yyy=''
        case "$d_socklen_t" in
        "$define") yyy="$yyy socklen_t"
@@ -14213,10 +14649,19 @@ EOM
        for xxx in $yyy; do
                case "$socksizetype" in
                '')     try="extern int accept(int, struct sockaddr *, $xxx *);"
-                       if ./protochk "$try" $hdrs; then
-                               echo "Your system accepts '$xxx *' for the last argument of accept()."
-                               socksizetype="$xxx"
-                       fi
+                       case "$usesocks" in
+                       "$define")
+                               if ./protochk "$try" $i_systypes sys/types.h $d_socket sys/socket.h literal '#define INCLUDE_PROTOTYPES' $i_socks socks.h.; then
+                                       echo "Your system accepts '$xxx *' for the last argument of accept()."
+                                       socksizetype="$xxx"
+                               fi
+                               ;;
+                       *)      if ./protochk "$try"  $i_systypes sys/types.h $d_socket sys/socket.h; then
+                                       echo "Your system accepts '$xxx *' for the last argument of accept()."
+                                       socksizetype="$xxx"
+                               fi
+                               ;;
+                       esac
                        ;;
                esac
        done
@@ -14277,13 +14722,17 @@ $rm -f ssize ssize.*
 
 : see what type of char stdio uses.
 echo " "
-if $contains 'unsigned.*char.*_ptr;' `./findhdr stdio.h` >/dev/null 2>&1 ; then
+echo '#include <stdio.h>' | $cppstdin $cppminus > stdioh
+if $contains 'unsigned.*char.*_ptr;' stdioh >/dev/null 2>&1 ; then
        echo "Your stdio uses unsigned chars." >&4
        stdchar="unsigned char"
 else
        echo "Your stdio uses signed chars." >&4
        stdchar="char"
 fi
+$rm -f stdioh
+
+
 
 : see if time exists
 echo " "
@@ -14863,108 +15312,6 @@ val=$val3; set i_termios; eval $setvar
 set shadow.h i_shadow
 eval $inhdr
 
-: see if this is a socks.h system
-set socks.h i_socks
-eval $inhdr
-
-: see if stdarg is available
-echo " "
-if $test `./findhdr stdarg.h`; then
-       echo "<stdarg.h> found." >&4
-       valstd="$define"
-else
-       echo "<stdarg.h> NOT found." >&4
-       valstd="$undef"
-fi
-
-: see if varags is available
-echo " "
-if $test `./findhdr varargs.h`; then
-       echo "<varargs.h> found." >&4
-else
-       echo "<varargs.h> NOT found, but that's ok (I hope)." >&4
-fi
-
-: set up the varargs testing programs
-$cat > varargs.c <<EOP
-#ifdef I_STDARG
-#include <stdarg.h>
-#endif
-#ifdef I_VARARGS
-#include <varargs.h>
-#endif
-
-#ifdef I_STDARG
-int f(char *p, ...)
-#else
-int f(va_alist)
-va_dcl
-#endif
-{
-       va_list ap;
-#ifndef I_STDARG
-       char *p;
-#endif
-#ifdef I_STDARG
-       va_start(ap,p);
-#else
-       va_start(ap);
-       p = va_arg(ap, char *);
-#endif
-       va_end(ap);
-}
-EOP
-$cat > varargs <<EOP
-$startsh
-if $cc -c $ccflags -D\$1 varargs.c >/dev/null 2>&1; then
-       echo "true"
-else
-       echo "false"
-fi
-$rm -f varargs$_o
-EOP
-chmod +x varargs
-
-: now check which varargs header should be included
-echo " "
-i_varhdr=''
-case "$valstd" in
-"$define")
-       if `./varargs I_STDARG`; then
-               val='stdarg.h'
-       elif `./varargs I_VARARGS`; then
-               val='varargs.h'
-       fi
-       ;;
-*)
-       if `./varargs I_VARARGS`; then
-               val='varargs.h'
-       fi
-       ;;
-esac
-case "$val" in
-'')
-echo "I could not find the definition for va_dcl... You have problems..." >&4
-       val="$undef"; set i_stdarg; eval $setvar
-       val="$undef"; set i_varargs; eval $setvar
-       ;;
-*) 
-       set i_varhdr
-       eval $setvar
-       case "$i_varhdr" in
-       stdarg.h)
-               val="$define"; set i_stdarg; eval $setvar
-               val="$undef"; set i_varargs; eval $setvar
-               ;;
-       varargs.h)
-               val="$undef"; set i_stdarg; eval $setvar
-               val="$define"; set i_varargs; eval $setvar
-               ;;
-       esac
-       echo "We'll include <$i_varhdr> to get va_dcl definition." >&4;;
-esac
-$rm -f varargs*
-
 : see if stddef is available
 set stddef.h i_stddef
 eval $inhdr
@@ -15509,6 +15856,7 @@ d_PRIo64='$d_PRIo64'
 d_PRIu64='$d_PRIu64'
 d_PRIx64='$d_PRIx64'
 d_SCNfldbl='$d_SCNfldbl'
+d__fwalk='$d__fwalk'
 d_access='$d_access'
 d_accessx='$d_accessx'
 d_alarm='$d_alarm'
@@ -15571,6 +15919,7 @@ d_fseeko='$d_fseeko'
 d_fsetpos='$d_fsetpos'
 d_fstatfs='$d_fstatfs'
 d_fstatvfs='$d_fstatvfs'
+d_fsync='$d_fsync'
 d_ftello='$d_ftello'
 d_ftime='$d_ftime'
 d_getcwd='$d_getcwd'
@@ -15590,6 +15939,7 @@ d_getnbyaddr='$d_getnbyaddr'
 d_getnbyname='$d_getnbyname'
 d_getnent='$d_getnent'
 d_getnetprotos='$d_getnetprotos'
+d_getpagsz='$d_getpagsz'
 d_getpbyname='$d_getpbyname'
 d_getpbynumber='$d_getpbynumber'
 d_getpent='$d_getpent'
@@ -15693,6 +16043,7 @@ d_rmdir='$d_rmdir'
 d_safebcpy='$d_safebcpy'
 d_safemcpy='$d_safemcpy'
 d_sanemcmp='$d_sanemcmp'
+d_sbrkproto='$d_sbrkproto'
 d_sched_yield='$d_sched_yield'
 d_scm_rights='$d_scm_rights'
 d_seekdir='$d_seekdir'
@@ -15735,6 +16086,7 @@ d_shmctl='$d_shmctl'
 d_shmdt='$d_shmdt'
 d_shmget='$d_shmget'
 d_sigaction='$d_sigaction'
+d_sigprocmask='$d_sigprocmask'
 d_sigsetjmp='$d_sigsetjmp'
 d_socket='$d_socket'
 d_socklen_t='$d_socklen_t'
@@ -15761,6 +16113,7 @@ d_strtod='$d_strtod'
 d_strtol='$d_strtol'
 d_strtold='$d_strtold'
 d_strtoll='$d_strtoll'
+d_strtoq='$d_strtoq'
 d_strtoul='$d_strtoul'
 d_strtoull='$d_strtoull'
 d_strtouq='$d_strtouq'
@@ -15952,6 +16305,7 @@ installvendorarch='$installvendorarch'
 installvendorbin='$installvendorbin'
 installvendorlib='$installvendorlib'
 intsize='$intsize'
+issymlink='$issymlink'
 ivdformat='$ivdformat'
 ivsize='$ivsize'
 ivtype='$ivtype'
@@ -16014,6 +16368,7 @@ mydomain='$mydomain'
 myhostname='$myhostname'
 myuname='$myuname'
 n='$n'
+need_va_copy='$need_va_copy'
 netdb_hlen_type='$netdb_hlen_type'
 netdb_host_type='$netdb_host_type'
 netdb_name_type='$netdb_name_type'
@@ -16106,6 +16461,7 @@ sig_name='$sig_name'
 sig_name_init='$sig_name_init'
 sig_num='$sig_num'
 sig_num_init='$sig_num_init'
+sig_size='$sig_size'
 signal_t='$signal_t'
 sitearch='$sitearch'
 sitearchexp='$sitearchexp'