ac_help="$ac_help
--with-coss-membuf-size COSS membuf size (default 1048576 bytes) "
ac_help="$ac_help
- --enable-poll Enable poll() instead of select(). Normally poll
- is preferred over select, but configure knows poll
- is broken on some platforms. If you think you are
- smarter than the configure script, you may enable
- poll with this option.
- --disable-poll Disable the use of poll()."
+ --enable-poll Enable poll() support.
+ --disable-poll Disable poll() support. "
+ac_help="$ac_help
+ --enable-select Enable select() support.
+ --disable-select Disable select() support. "
+ac_help="$ac_help
+ --enable-kqueue Enable kqueue() support.
+ --disable-kqueue Disable kqueue() support. "
ac_help="$ac_help
--disable-http-violations
This allows you to remove code which is known to
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:749: checking for a BSD compatible install" >&5
+echo "configure:751: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
-echo "configure:802: checking whether build environment is sane" >&5
+echo "configure:804: checking whether build environment is sane" >&5
# Just in case
sleep 1
echo timestamp > conftest.file
# Extract the first word of "$ac_prog", so it can be a program name with args.
set dummy $ac_prog; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:873: checking for $ac_word" >&5
+echo "configure:875: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
done
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
-echo "configure:903: checking whether ${MAKE-make} sets \${MAKE}" >&5
+echo "configure:905: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
-# From configure.in Revision: 1.251
+# From configure.in Revision: 1.252
echo $ac_n "checking whether to enable maintainer-specific portions of Makefiles""... $ac_c" 1>&6
-echo "configure:1024: checking whether to enable maintainer-specific portions of Makefiles" >&5
+echo "configure:1026: checking whether to enable maintainer-specific portions of Makefiles" >&5
# Check whether --enable-maintainer-mode or --disable-maintainer-mode was given.
if test "${enable_maintainer_mode+set}" = set; then
enableval="$enable_maintainer_mode"
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1056: checking for $ac_word" >&5
+echo "configure:1058: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1086: checking for $ac_word" >&5
+echo "configure:1088: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:1137: checking for $ac_word" >&5
+echo "configure:1139: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
-echo "configure:1169: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
+echo "configure:1171: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
cat > conftest.$ac_ext << EOF
-#line 1180 "configure"
+#line 1182 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
-if { (eval echo configure:1185: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:1187: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
-echo "configure:1211: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
+echo "configure:1213: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
-echo "configure:1216: checking whether we are using GNU C" >&5
+echo "configure:1218: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
yes;
#endif
EOF
-if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1225: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
+if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1227: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
-echo "configure:1244: checking whether ${CC-cc} accepts -g" >&5
+echo "configure:1246: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
END
# If we don't find an include directive, just comment out the code.
echo $ac_n "checking for style of include used by $am_make""... $ac_c" 1>&6
-echo "configure:1283: checking for style of include used by $am_make" >&5
+echo "configure:1285: checking for style of include used by $am_make" >&5
am__include='#'
am__quote=
_am_result=none
depcc="$CC" am_compiler_list=
echo $ac_n "checking dependency style of $depcc""... $ac_c" 1>&6
-echo "configure:1317: checking dependency style of $depcc" >&5
+echo "configure:1319: checking dependency style of $depcc" >&5
if eval "test \"`echo '$''{'am_cv_CC_dependencies_compiler_type'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
if test "x$CC" != xcc; then
echo $ac_n "checking whether $CC and cc understand -c and -o together""... $ac_c" 1>&6
-echo "configure:1385: checking whether $CC and cc understand -c and -o together" >&5
+echo "configure:1387: checking whether $CC and cc understand -c and -o together" >&5
else
echo $ac_n "checking whether cc understands -c and -o together""... $ac_c" 1>&6
-echo "configure:1388: checking whether cc understands -c and -o together" >&5
+echo "configure:1390: checking whether cc understands -c and -o together" >&5
fi
set dummy $CC; ac_cc="`echo $2 |
sed -e 's/[^a-zA-Z0-9_]/_/g' -e 's/^[0-9]/_/'`"
# We do the test twice because some compilers refuse to overwrite an
# existing .o file with -o, though they will create one.
ac_try='${CC-cc} -c conftest.c -o conftest.o 1>&5'
-if { (eval echo configure:1400: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
- test -f conftest.o && { (eval echo configure:1401: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
+if { (eval echo configure:1402: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
+ test -f conftest.o && { (eval echo configure:1403: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
then
eval ac_cv_prog_cc_${ac_cc}_c_o=yes
if test "x$CC" != xcc; then
# Test first that cc exists at all.
- if { ac_try='cc -c conftest.c 1>&5'; { (eval echo configure:1406: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
+ if { ac_try='cc -c conftest.c 1>&5'; { (eval echo configure:1408: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; }; then
ac_try='cc -c conftest.c -o conftest.o 1>&5'
- if { (eval echo configure:1408: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
- test -f conftest.o && { (eval echo configure:1409: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
+ if { (eval echo configure:1410: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } &&
+ test -f conftest.o && { (eval echo configure:1411: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; };
then
# cc works too.
:
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
-echo "configure:1455: checking host system type" >&5
+echo "configure:1457: checking host system type" >&5
host_alias=$host
case "$host_alias" in
LIBREGEX='' # libregex.a
echo $ac_n "checking for Cygwin environment""... $ac_c" 1>&6
-echo "configure:1482: checking for Cygwin environment" >&5
+echo "configure:1484: checking for Cygwin environment" >&5
if eval "test \"`echo '$''{'ac_cv_cygwin'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1487 "configure"
+#line 1489 "configure"
#include "confdefs.h"
int main() {
return __CYGWIN__;
; return 0; }
EOF
-if { (eval echo configure:1498: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1500: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_cygwin=yes
else
CYGWIN=
test "$ac_cv_cygwin" = yes && CYGWIN=yes
echo $ac_n "checking for mingw32 environment""... $ac_c" 1>&6
-echo "configure:1515: checking for mingw32 environment" >&5
+echo "configure:1517: checking for mingw32 environment" >&5
if eval "test \"`echo '$''{'ac_cv_mingw32'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1520 "configure"
+#line 1522 "configure"
#include "confdefs.h"
int main() {
return __MINGW32__;
; return 0; }
EOF
-if { (eval echo configure:1527: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1529: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_mingw32=yes
else
echo $ac_n "checking for executable suffix""... $ac_c" 1>&6
-echo "configure:1546: checking for executable suffix" >&5
+echo "configure:1548: checking for executable suffix" >&5
if eval "test \"`echo '$''{'ac_cv_exeext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int main () { return 0; }' > conftest.$ac_ext
ac_cv_exeext=
- if { (eval echo configure:1556: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
+ if { (eval echo configure:1558: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; }; then
for file in conftest.*; do
case $file in
- *.c | *.o | *.obj) ;;
+ *.c | *.C | *.o | *.obj) ;;
*) ac_cv_exeext=`echo $file | sed -e s/conftest//` ;;
esac
done
ac_exeext=$EXEEXT
echo $ac_n "checking for object suffix""... $ac_c" 1>&6
-echo "configure:1577: checking for object suffix" >&5
+echo "configure:1579: checking for object suffix" >&5
if eval "test \"`echo '$''{'ac_cv_objext'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
rm -f conftest*
echo 'int i = 1;' > conftest.$ac_ext
-if { (eval echo configure:1583: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1585: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
for ac_file in conftest.*; do
case $ac_file in
*.c) ;;
# Check whether --enable-poll or --disable-poll was given.
if test "${enable_poll+set}" = set; then
enableval="$enable_poll"
-
+
case "$enableval" in
yes)
echo "Forcing poll() to be enabled"
fi
+# Check whether --enable-select or --disable-select was given.
+if test "${enable_select+set}" = set; then
+ enableval="$enable_select"
+
+ case "$enableval" in
+ yes)
+ echo "Forcing select() to be enabled"
+ ac_cv_func_select='yes'
+ ;;
+ no)
+ echo "Forcing select() to be disabled"
+ ac_cv_func_select='no'
+ ;;
+ esac
+
+fi
+
+
+# Check whether --enable-kqueue or --disable-kqueue was given.
+if test "${enable_kqueue+set}" = set; then
+ enableval="$enable_kqueue"
+
+ case "$enableval" in
+ yes)
+ echo "Forcing kqueue() to be enabled"
+ ac_cv_func_kqueue='yes'
+ ;;
+ no)
+ echo "Forcing kqueue() to be disabled"
+ ac_cv_func_kqueue='no'
+ ;;
+esac
+
+fi
+
+
# Check whether --enable-http-violations or --disable-http-violations was given.
if test "${enable_http_violations+set}" = set; then
enableval="$enable_http_violations"
esac
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
-echo "configure:2889: checking how to run the C preprocessor" >&5
+echo "configure:2927: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
-#line 2904 "configure"
+#line 2942 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2910: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2948: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
-#line 2921 "configure"
+#line 2959 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2927: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2965: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
-#line 2938 "configure"
+#line 2976 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:2944: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:2982: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
:
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
-echo "configure:2980: checking for a BSD compatible install" >&5
+echo "configure:3018: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
# Extract the first word of "ranlib", so it can be a program name with args.
set dummy ranlib; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3035: checking for $ac_word" >&5
+echo "configure:3073: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
fi
echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
-echo "configure:3063: checking whether ln -s works" >&5
+echo "configure:3101: checking whether ln -s works" >&5
if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "sh", so it can be a program name with args.
set dummy sh; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3086: checking for $ac_word" >&5
+echo "configure:3124: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SH'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "false", so it can be a program name with args.
set dummy false; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3122: checking for $ac_word" >&5
+echo "configure:3160: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_FALSE'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "true", so it can be a program name with args.
set dummy true; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3158: checking for $ac_word" >&5
+echo "configure:3196: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_TRUE'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "rm", so it can be a program name with args.
set dummy rm; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3194: checking for $ac_word" >&5
+echo "configure:3232: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_RM'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "mv", so it can be a program name with args.
set dummy mv; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3230: checking for $ac_word" >&5
+echo "configure:3268: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MV'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "mkdir", so it can be a program name with args.
set dummy mkdir; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3266: checking for $ac_word" >&5
+echo "configure:3304: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_MKDIR'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "ln", so it can be a program name with args.
set dummy ln; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3302: checking for $ac_word" >&5
+echo "configure:3340: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_LN'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "perl", so it can be a program name with args.
set dummy perl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3338: checking for $ac_word" >&5
+echo "configure:3376: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_PERL'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
# Extract the first word of "ar", so it can be a program name with args.
set dummy ar; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
-echo "configure:3374: checking for $ac_word" >&5
+echo "configure:3412: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_AR'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
-echo "configure:3434: checking for $ac_hdr that defines DIR" >&5
+echo "configure:3472: checking for $ac_hdr that defines DIR" >&5
if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3439 "configure"
+#line 3477 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <$ac_hdr>
DIR *dirp = 0;
; return 0; }
EOF
-if { (eval echo configure:3447: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3485: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
eval "ac_cv_header_dirent_$ac_safe=yes"
else
# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
if test $ac_header_dirent = dirent.h; then
echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
-echo "configure:3472: checking for opendir in -ldir" >&5
+echo "configure:3510: checking for opendir in -ldir" >&5
ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-ldir $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3480 "configure"
+#line 3518 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
opendir()
; return 0; }
EOF
-if { (eval echo configure:3491: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3529: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
else
echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
-echo "configure:3513: checking for opendir in -lx" >&5
+echo "configure:3551: checking for opendir in -lx" >&5
ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lx $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3521 "configure"
+#line 3559 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
opendir()
; return 0; }
EOF
-if { (eval echo configure:3532: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:3570: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
fi
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
-echo "configure:3555: checking for ANSI C header files" >&5
+echo "configure:3593: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3560 "configure"
+#line 3598 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3568: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3606: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 3585 "configure"
+#line 3623 "configure"
#include "confdefs.h"
#include <string.h>
EOF
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
-#line 3603 "configure"
+#line 3641 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
:
else
cat > conftest.$ac_ext <<EOF
-#line 3624 "configure"
+#line 3662 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
exit (0); }
EOF
-if { (eval echo configure:3635: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3673: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
-echo "configure:3740: checking for $ac_hdr" >&5
+echo "configure:3778: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3745 "configure"
+#line 3783 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
-{ (eval echo configure:3750: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+{ (eval echo configure:3788: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:3778: checking for working const" >&5
+echo "configure:3816: checking for working const" >&5
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3783 "configure"
+#line 3821 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
-if { (eval echo configure:3832: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3870: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_const=yes
else
fi
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
-echo "configure:3853: checking whether byte ordering is bigendian" >&5
+echo "configure:3891: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_bigendian=unknown
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
-#line 3860 "configure"
+#line 3898 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/param.h>
#endif
; return 0; }
EOF
-if { (eval echo configure:3871: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3909: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
-#line 3875 "configure"
+#line 3913 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/param.h>
#endif
; return 0; }
EOF
-if { (eval echo configure:3886: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3924: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 3906 "configure"
+#line 3944 "configure"
#include "confdefs.h"
main () {
/* Are we little or big endian? From Harbison&Steele. */
exit (u.c[sizeof (long) - 1] == 1);
}
EOF
-if { (eval echo configure:3919: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3957: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
else
echo $ac_n "checking if ANSI prototypes work""... $ac_c" 1>&6
-echo "configure:3944: checking if ANSI prototypes work" >&5
+echo "configure:3982: checking if ANSI prototypes work" >&5
if eval "test \"`echo '$''{'ac_cv_have_ansi_prototypes'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3950 "configure"
+#line 3988 "configure"
#include "confdefs.h"
int foo(char *); int foo (char *bar) {return 1;}
int main() {
foo("bar")
; return 0; }
EOF
-if { (eval echo configure:3957: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3995: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_have_ansi_prototypes="yes"
else
fi
echo $ac_n "checking for tm->tm_gmtoff""... $ac_c" 1>&6
-echo "configure:3979: checking for tm->tm_gmtoff" >&5
+echo "configure:4017: checking for tm->tm_gmtoff" >&5
if eval "test \"`echo '$''{'ac_cv_have_tm_gmoff'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3985 "configure"
+#line 4023 "configure"
#include "confdefs.h"
#include <time.h>
#include <sys/time.h>
foo.tm_gmtoff = 0;
; return 0; }
EOF
-if { (eval echo configure:3994: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4032: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_have_tm_gmoff="yes"
else
fi
echo $ac_n "checking for struct mallinfo""... $ac_c" 1>&6
-echo "configure:4016: checking for struct mallinfo" >&5
+echo "configure:4054: checking for struct mallinfo" >&5
if eval "test \"`echo '$''{'ac_cv_have_struct_mallinfo'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4022 "configure"
+#line 4060 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if HAVE_MALLOC_H
foo.keepcost = 0;
; return 0; }
EOF
-if { (eval echo configure:4040: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4078: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_have_struct_mallinfo="yes"
else
fi
echo $ac_n "checking for extended mallinfo""... $ac_c" 1>&6
-echo "configure:4062: checking for extended mallinfo" >&5
+echo "configure:4100: checking for extended mallinfo" >&5
if eval "test \"`echo '$''{'ac_cv_have_ext_mallinfo'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4068 "configure"
+#line 4106 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <malloc.h>
foo.mxfast = 0;
; return 0; }
EOF
-if { (eval echo configure:4077: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4115: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_have_ext_mallinfo="yes"
else
fi
echo $ac_n "checking for struct rusage""... $ac_c" 1>&6
-echo "configure:4099: checking for struct rusage" >&5
+echo "configure:4137: checking for struct rusage" >&5
if eval "test \"`echo '$''{'ac_cv_have_struct_rusage'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4105 "configure"
+#line 4143 "configure"
#include "confdefs.h"
#if HAVE_SYS_TIME_H
struct rusage R;
; return 0; }
EOF
-if { (eval echo configure:4118: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4156: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_have_struct_rusage="yes"
else
fi
echo $ac_n "checking for ip->ip_hl""... $ac_c" 1>&6
-echo "configure:4140: checking for ip->ip_hl" >&5
+echo "configure:4178: checking for ip->ip_hl" >&5
if eval "test \"`echo '$''{'ac_cv_have_ip_hl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4146 "configure"
+#line 4184 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <netinet/in.h>
ip.ip_hl= 0;
; return 0; }
EOF
-if { (eval echo configure:4165: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:4203: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_have_ip_hl="yes"
else
fi
echo $ac_n "checking size of void *""... $ac_c" 1>&6
-echo "configure:4187: checking size of void *" >&5
+echo "configure:4225: checking size of void *" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_void_p'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4195 "configure"
+#line 4233 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4206: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4244: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_void_p=`cat conftestval`
else
echo $ac_n "checking size of short""... $ac_c" 1>&6
-echo "configure:4226: checking size of short" >&5
+echo "configure:4264: checking size of short" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4234 "configure"
+#line 4272 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4245: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4283: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_short=`cat conftestval`
else
echo $ac_n "checking size of int""... $ac_c" 1>&6
-echo "configure:4265: checking size of int" >&5
+echo "configure:4303: checking size of int" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4273 "configure"
+#line 4311 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4284: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4322: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_int=`cat conftestval`
else
echo $ac_n "checking size of long""... $ac_c" 1>&6
-echo "configure:4304: checking size of long" >&5
+echo "configure:4342: checking size of long" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4312 "configure"
+#line 4350 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4323: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4361: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_long=`cat conftestval`
else
echo $ac_n "checking size of long long""... $ac_c" 1>&6
-echo "configure:4343: checking size of long long" >&5
+echo "configure:4381: checking size of long long" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_long_long'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4351 "configure"
+#line 4389 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4362: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4400: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_long_long=`cat conftestval`
else
echo $ac_n "checking size of __int64""... $ac_c" 1>&6
-echo "configure:4382: checking size of __int64" >&5
+echo "configure:4420: checking size of __int64" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof___int64'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4390 "configure"
+#line 4428 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4401: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4439: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof___int64=`cat conftestval`
else
echo $ac_n "checking size of int16_t""... $ac_c" 1>&6
-echo "configure:4421: checking size of int16_t" >&5
+echo "configure:4459: checking size of int16_t" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_int16_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4429 "configure"
+#line 4467 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4440: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4478: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_int16_t=`cat conftestval`
else
echo $ac_n "checking size of uint16_t""... $ac_c" 1>&6
-echo "configure:4460: checking size of uint16_t" >&5
+echo "configure:4498: checking size of uint16_t" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_uint16_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4468 "configure"
+#line 4506 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4479: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4517: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_uint16_t=`cat conftestval`
else
echo $ac_n "checking size of u_int16_t""... $ac_c" 1>&6
-echo "configure:4499: checking size of u_int16_t" >&5
+echo "configure:4537: checking size of u_int16_t" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_u_int16_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4507 "configure"
+#line 4545 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4518: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4556: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_u_int16_t=`cat conftestval`
else
echo $ac_n "checking size of int32_t""... $ac_c" 1>&6
-echo "configure:4538: checking size of int32_t" >&5
+echo "configure:4576: checking size of int32_t" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_int32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4546 "configure"
+#line 4584 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4557: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4595: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_int32_t=`cat conftestval`
else
echo $ac_n "checking size of uint32_t""... $ac_c" 1>&6
-echo "configure:4577: checking size of uint32_t" >&5
+echo "configure:4615: checking size of uint32_t" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_uint32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4585 "configure"
+#line 4623 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4596: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4634: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_uint32_t=`cat conftestval`
else
echo $ac_n "checking size of u_int32_t""... $ac_c" 1>&6
-echo "configure:4616: checking size of u_int32_t" >&5
+echo "configure:4654: checking size of u_int32_t" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_u_int32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4624 "configure"
+#line 4662 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4635: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4673: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_u_int32_t=`cat conftestval`
else
echo $ac_n "checking size of int64_t""... $ac_c" 1>&6
-echo "configure:4655: checking size of int64_t" >&5
+echo "configure:4693: checking size of int64_t" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_int64_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4663 "configure"
+#line 4701 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4674: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4712: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_int64_t=`cat conftestval`
else
echo $ac_n "checking size of uint64_t""... $ac_c" 1>&6
-echo "configure:4694: checking size of uint64_t" >&5
+echo "configure:4732: checking size of uint64_t" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_uint64_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4702 "configure"
+#line 4740 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4713: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4751: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_uint64_t=`cat conftestval`
else
echo $ac_n "checking size of u_int64_t""... $ac_c" 1>&6
-echo "configure:4733: checking size of u_int64_t" >&5
+echo "configure:4771: checking size of u_int64_t" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_u_int64_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4741 "configure"
+#line 4779 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
exit(0);
}
EOF
-if { (eval echo configure:4752: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4790: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_u_int64_t=`cat conftestval`
else
if test "x$ac_cv_sizeof_short" = "x2"; then
echo $ac_n "checking for int16_t""... $ac_c" 1>&6
-echo "configure:4774: checking for int16_t" >&5
+echo "configure:4812: checking for int16_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_int16_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4779 "configure"
+#line 4817 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
elif test "x$ac_cv_sizeof_int" = "x2"; then
echo $ac_n "checking for int16_t""... $ac_c" 1>&6
-echo "configure:4808: checking for int16_t" >&5
+echo "configure:4846: checking for int16_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_int16_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4813 "configure"
+#line 4851 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
fi
if test "x$ac_cv_sizeof_uint16_t" = "x2"; then
echo $ac_n "checking for u_int16_t""... $ac_c" 1>&6
-echo "configure:4843: checking for u_int16_t" >&5
+echo "configure:4881: checking for u_int16_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_u_int16_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4848 "configure"
+#line 4886 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
elif test "x$ac_cv_sizeof_short" = "x2"; then
echo $ac_n "checking for u_int16_t""... $ac_c" 1>&6
-echo "configure:4877: checking for u_int16_t" >&5
+echo "configure:4915: checking for u_int16_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_u_int16_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4882 "configure"
+#line 4920 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
elif test "x$ac_cv_sizeof_int" = "x2"; then
echo $ac_n "checking for u_int16_t""... $ac_c" 1>&6
-echo "configure:4911: checking for u_int16_t" >&5
+echo "configure:4949: checking for u_int16_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_u_int16_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4916 "configure"
+#line 4954 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
fi
if test "x$ac_cv_sizeof_int" = "x4"; then
echo $ac_n "checking for int32_t""... $ac_c" 1>&6
-echo "configure:4946: checking for int32_t" >&5
+echo "configure:4984: checking for int32_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_int32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4951 "configure"
+#line 4989 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
elif "x$ac_cv_sizeof_long" = "x4"; then
echo $ac_n "checking for int32_t""... $ac_c" 1>&6
-echo "configure:4980: checking for int32_t" >&5
+echo "configure:5018: checking for int32_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_int32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4985 "configure"
+#line 5023 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
fi
if test "x$ac_cv_sizeof_uint32_t" = "x4"; then
echo $ac_n "checking for u_int32_t""... $ac_c" 1>&6
-echo "configure:5015: checking for u_int32_t" >&5
+echo "configure:5053: checking for u_int32_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_u_int32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5020 "configure"
+#line 5058 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
elif test "x$ac_cv_sizeof_int" = "x4"; then
echo $ac_n "checking for u_int32_t""... $ac_c" 1>&6
-echo "configure:5049: checking for u_int32_t" >&5
+echo "configure:5087: checking for u_int32_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_u_int32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5054 "configure"
+#line 5092 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
elif test "x$ac_cv_sizeof_long" = "x4"; then
echo $ac_n "checking for u_int32_t""... $ac_c" 1>&6
-echo "configure:5083: checking for u_int32_t" >&5
+echo "configure:5121: checking for u_int32_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_u_int32_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5088 "configure"
+#line 5126 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
fi
if test "x$ac_cv_sizeof_long" = "x8"; then
echo $ac_n "checking for int64_t""... $ac_c" 1>&6
-echo "configure:5118: checking for int64_t" >&5
+echo "configure:5156: checking for int64_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_int64_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5123 "configure"
+#line 5161 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
elif test "x$ac_cv_sizeof_long_long" = "x8"; then
echo $ac_n "checking for int64_t""... $ac_c" 1>&6
-echo "configure:5152: checking for int64_t" >&5
+echo "configure:5190: checking for int64_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_int64_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5157 "configure"
+#line 5195 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
elif test "x$ac_cv_sizeof___int64" = "x8"; then
echo $ac_n "checking for int64_t""... $ac_c" 1>&6
-echo "configure:5186: checking for int64_t" >&5
+echo "configure:5224: checking for int64_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_int64_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5191 "configure"
+#line 5229 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
fi
if test "x$ac_cv_sizeof_uint64_t" = "x8"; then
echo $ac_n "checking for u_int64_t""... $ac_c" 1>&6
-echo "configure:5221: checking for u_int64_t" >&5
+echo "configure:5259: checking for u_int64_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_u_int64_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5226 "configure"
+#line 5264 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
elif test "x$ac_cv_sizeof_long" = "x8"; then
echo $ac_n "checking for u_int64_t""... $ac_c" 1>&6
-echo "configure:5255: checking for u_int64_t" >&5
+echo "configure:5293: checking for u_int64_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_u_int64_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5260 "configure"
+#line 5298 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
elif test "x$ac_cv_sizeof_long_long" = "x8"; then
echo $ac_n "checking for u_int64_t""... $ac_c" 1>&6
-echo "configure:5289: checking for u_int64_t" >&5
+echo "configure:5327: checking for u_int64_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_u_int64_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5294 "configure"
+#line 5332 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
elif test "x$ac_cv_sizeof___int64" = "x8"; then
echo $ac_n "checking for int64_t""... $ac_c" 1>&6
-echo "configure:5323: checking for int64_t" >&5
+echo "configure:5361: checking for int64_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_int64_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5328 "configure"
+#line 5366 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
fi
echo $ac_n "checking for pid_t""... $ac_c" 1>&6
-echo "configure:5358: checking for pid_t" >&5
+echo "configure:5396: checking for pid_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5363 "configure"
+#line 5401 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
fi
echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:5391: checking for size_t" >&5
+echo "configure:5429: checking for size_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5396 "configure"
+#line 5434 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
fi
echo $ac_n "checking for ssize_t""... $ac_c" 1>&6
-echo "configure:5424: checking for ssize_t" >&5
+echo "configure:5462: checking for ssize_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_ssize_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5429 "configure"
+#line 5467 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
fi
echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:5457: checking for off_t" >&5
+echo "configure:5495: checking for off_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5462 "configure"
+#line 5500 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
fi
echo $ac_n "checking for mode_t""... $ac_c" 1>&6
-echo "configure:5490: checking for mode_t" >&5
+echo "configure:5528: checking for mode_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5495 "configure"
+#line 5533 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
fi
echo $ac_n "checking for fd_mask""... $ac_c" 1>&6
-echo "configure:5523: checking for fd_mask" >&5
+echo "configure:5561: checking for fd_mask" >&5
if eval "test \"`echo '$''{'ac_cv_type_fd_mask'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5528 "configure"
+#line 5566 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
# The Ultrix 4.2 mips builtin alloca declared by alloca.h only works
# for constant arguments. Useless!
echo $ac_n "checking for working alloca.h""... $ac_c" 1>&6
-echo "configure:5559: checking for working alloca.h" >&5
+echo "configure:5597: checking for working alloca.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_alloca_h'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5564 "configure"
+#line 5602 "configure"
#include "confdefs.h"
#include <alloca.h>
int main() {
char *p = alloca(2 * sizeof(int));
; return 0; }
EOF
-if { (eval echo configure:5571: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5609: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_header_alloca_h=yes
else
fi
echo $ac_n "checking for alloca""... $ac_c" 1>&6
-echo "configure:5592: checking for alloca" >&5
+echo "configure:5630: checking for alloca" >&5
if eval "test \"`echo '$''{'ac_cv_func_alloca_works'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5597 "configure"
+#line 5635 "configure"
#include "confdefs.h"
#ifdef __GNUC__
char *p = (char *) alloca(1);
; return 0; }
EOF
-if { (eval echo configure:5625: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5663: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
ac_cv_func_alloca_works=yes
else
echo $ac_n "checking whether alloca needs Cray hooks""... $ac_c" 1>&6
-echo "configure:5657: checking whether alloca needs Cray hooks" >&5
+echo "configure:5695: checking whether alloca needs Cray hooks" >&5
if eval "test \"`echo '$''{'ac_cv_os_cray'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5662 "configure"
+#line 5700 "configure"
#include "confdefs.h"
#if defined(CRAY) && ! defined(CRAY2)
webecray
if test $ac_cv_os_cray = yes; then
for ac_func in _getb67 GETB67 getb67; do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:5687: checking for $ac_func" >&5
+echo "configure:5725: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5692 "configure"
+#line 5730 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:5715: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5753: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
fi
echo $ac_n "checking stack direction for C alloca""... $ac_c" 1>&6
-echo "configure:5742: checking stack direction for C alloca" >&5
+echo "configure:5780: checking stack direction for C alloca" >&5
if eval "test \"`echo '$''{'ac_cv_c_stack_direction'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_stack_direction=0
else
cat > conftest.$ac_ext <<EOF
-#line 5750 "configure"
+#line 5788 "configure"
#include "confdefs.h"
find_stack_direction ()
{
exit (find_stack_direction() < 0);
}
EOF
-if { (eval echo configure:5769: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:5807: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_stack_direction=1
else
echo $ac_n "checking for socklen_t""... $ac_c" 1>&6
-echo "configure:5793: checking for socklen_t" >&5
+echo "configure:5831: checking for socklen_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_socklen_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5799 "configure"
+#line 5837 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/socket.h>
fi
echo $ac_n "checking for mtyp_t""... $ac_c" 1>&6
-echo "configure:5830: checking for mtyp_t" >&5
+echo "configure:5868: checking for mtyp_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_mtyp_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5836 "configure"
+#line 5874 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/ipc.h>
fi
echo $ac_n "checking for main in -lnsl""... $ac_c" 1>&6
-echo "configure:5864: checking for main in -lnsl" >&5
+echo "configure:5902: checking for main in -lnsl" >&5
ac_lib_var=`echo nsl'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lnsl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 5872 "configure"
+#line 5910 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
-if { (eval echo configure:5879: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5917: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
fi
echo $ac_n "checking for main in -lsocket""... $ac_c" 1>&6
-echo "configure:5907: checking for main in -lsocket" >&5
+echo "configure:5945: checking for main in -lsocket" >&5
ac_lib_var=`echo socket'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lsocket $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 5915 "configure"
+#line 5953 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
-if { (eval echo configure:5922: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:5960: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
echo $ac_n "checking for unix domain sockets""... $ac_c" 1>&6
-echo "configure:5951: checking for unix domain sockets" >&5
+echo "configure:5989: checking for unix domain sockets" >&5
if eval "test \"`echo '$''{'squid_cv_unixsocket'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 5957 "configure"
+#line 5995 "configure"
#include "confdefs.h"
#include <sys/types.h>
; return 0; }
EOF
-if { (eval echo configure:5972: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:6010: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
squid_cv_unixsocket=yes
else
echo "skipping libmalloc check (--enable-dlmalloc specified)"
else
echo $ac_n "checking for main in -lgnumalloc""... $ac_c" 1>&6
-echo "configure:5996: checking for main in -lgnumalloc" >&5
+echo "configure:6034: checking for main in -lgnumalloc" >&5
ac_lib_var=`echo gnumalloc'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lgnumalloc $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6004 "configure"
+#line 6042 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
-if { (eval echo configure:6011: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6049: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
*)
echo $ac_n "checking for main in -lmalloc""... $ac_c" 1>&6
-echo "configure:6054: checking for main in -lmalloc" >&5
+echo "configure:6092: checking for main in -lmalloc" >&5
ac_lib_var=`echo malloc'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lmalloc $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6062 "configure"
+#line 6100 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
-if { (eval echo configure:6069: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6107: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
fi
echo $ac_n "checking for main in -lbsd""... $ac_c" 1>&6
-echo "configure:6102: checking for main in -lbsd" >&5
+echo "configure:6140: checking for main in -lbsd" >&5
ac_lib_var=`echo bsd'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lbsd $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6110 "configure"
+#line 6148 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
-if { (eval echo configure:6117: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6155: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
fi
echo $ac_n "checking for main in -lregex""... $ac_c" 1>&6
-echo "configure:6145: checking for main in -lregex" >&5
+echo "configure:6183: checking for main in -lregex" >&5
ac_lib_var=`echo regex'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lregex $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6153 "configure"
+#line 6191 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
-if { (eval echo configure:6160: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6198: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
fi
echo $ac_n "checking for gethostbyname in -lbind""... $ac_c" 1>&6
-echo "configure:6181: checking for gethostbyname in -lbind" >&5
+echo "configure:6219: checking for gethostbyname in -lbind" >&5
ac_lib_var=`echo bind'_'gethostbyname | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lbind $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6189 "configure"
+#line 6227 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
gethostbyname()
; return 0; }
EOF
-if { (eval echo configure:6200: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6238: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
;;
*)
echo $ac_n "checking for inet_aton in -lresolv""... $ac_c" 1>&6
-echo "configure:6234: checking for inet_aton in -lresolv" >&5
+echo "configure:6272: checking for inet_aton in -lresolv" >&5
ac_lib_var=`echo resolv'_'inet_aton | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lresolv $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6242 "configure"
+#line 6280 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
inet_aton()
; return 0; }
EOF
-if { (eval echo configure:6253: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6291: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for inet_aton in -l44bsd""... $ac_c" 1>&6
-echo "configure:6269: checking for inet_aton in -l44bsd" >&5
+echo "configure:6307: checking for inet_aton in -l44bsd" >&5
ac_lib_var=`echo 44bsd'_'inet_aton | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-l44bsd $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6277 "configure"
+#line 6315 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
inet_aton()
; return 0; }
EOF
-if { (eval echo configure:6288: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6326: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
fi
echo $ac_n "checking for main in -lresolv""... $ac_c" 1>&6
-echo "configure:6320: checking for main in -lresolv" >&5
+echo "configure:6358: checking for main in -lresolv" >&5
ac_lib_var=`echo resolv'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lresolv $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6328 "configure"
+#line 6366 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
-if { (eval echo configure:6335: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6373: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
esac
fi
echo $ac_n "checking for main in -lm""... $ac_c" 1>&6
-echo "configure:6366: checking for main in -lm" >&5
+echo "configure:6404: checking for main in -lm" >&5
ac_lib_var=`echo m'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lm $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6374 "configure"
+#line 6412 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
-if { (eval echo configure:6381: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6419: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6
-echo "configure:6410: checking for crypt in -lcrypt" >&5
+echo "configure:6448: checking for crypt in -lcrypt" >&5
ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lcrypt $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6418 "configure"
+#line 6456 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
crypt()
; return 0; }
EOF
-if { (eval echo configure:6429: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6467: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
-echo "configure:6452: checking for dlopen in -ldl" >&5
+echo "configure:6490: checking for dlopen in -ldl" >&5
ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-ldl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6460 "configure"
+#line 6498 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
dlopen()
; return 0; }
EOF
-if { (eval echo configure:6471: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6509: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
echo $ac_n "checking for main in -lpthread""... $ac_c" 1>&6
-echo "configure:6494: checking for main in -lpthread" >&5
+echo "configure:6532: checking for main in -lpthread" >&5
ac_lib_var=`echo pthread'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lpthread $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6502 "configure"
+#line 6540 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
-if { (eval echo configure:6509: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6547: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
echo $ac_n "checking for aio_read in -lrt""... $ac_c" 1>&6
-echo "configure:6532: checking for aio_read in -lrt" >&5
+echo "configure:6570: checking for aio_read in -lrt" >&5
ac_lib_var=`echo rt'_'aio_read | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lrt $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6540 "configure"
+#line 6578 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
aio_read()
; return 0; }
EOF
-if { (eval echo configure:6551: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6589: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
case "$host" in
*-pc-sco3.2*)
echo $ac_n "checking for strftime in -lintl""... $ac_c" 1>&6
-echo "configure:6576: checking for strftime in -lintl" >&5
+echo "configure:6614: checking for strftime in -lintl" >&5
ac_lib_var=`echo intl'_'strftime | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
ac_save_LIBS="$LIBS"
LIBS="-lintl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 6584 "configure"
+#line 6622 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
strftime()
; return 0; }
EOF
-if { (eval echo configure:6595: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6633: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:6780: checking for $ac_func" >&5
+echo "configure:6818: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 6785 "configure"
+#line 6823 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:6808: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:6846: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
done
+
+
+if test "$ac_cv_func_poll" = "yes" ; then
+ SELECT_TYPE="poll"
+ cat >> confdefs.h <<\EOF
+#define USE_POLL 1
+EOF
+
+elif test "$ac_cv_func_select" = "yes" ; then
+ SELECT_TYPE="select"
+ cat >> confdefs.h <<\EOF
+#define USE_SELECT 1
+EOF
+
+else
+ echo "Eep! Can't find poll or select!"
+ echo "I'll try select and hope for the best."
+ SELECT_TYPE="select"
+ cat >> confdefs.h <<\EOF
+#define USE_SELECT 1
+EOF
+
+fi
+echo "Using ${SELECT_TYPE} for select loop."
+cat >> confdefs.h <<EOF
+#define SELECT_TYPE "$SELECT_TYPE"
+EOF
+
+
+
echo $ac_n "checking if setresuid is implemented""... $ac_c" 1>&6
-echo "configure:6834: checking if setresuid is implemented" >&5
+echo "configure:6902: checking if setresuid is implemented" >&5
if eval "test \"`echo '$''{'ac_cv_func_setresuid'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 6842 "configure"
+#line 6910 "configure"
#include "confdefs.h"
#include <stdlib.h>
}
EOF
-if { (eval echo configure:6855: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:6923: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_setresuid="yes"
else
if test "$IPF_TRANSPARENT" ; then
echo $ac_n "checking if IP-Filter header files are installed""... $ac_c" 1>&6
-echo "configure:6901: checking if IP-Filter header files are installed" >&5
+echo "configure:6969: checking if IP-Filter header files are installed" >&5
# hold on to your hats...
if test "$ac_cv_header_ip_compat_h" = "yes" ||
test "$ac_cv_header_ip_fil_compat_h" = "yes" ||
if test "$LINUX_NETFILTER" ; then
echo $ac_n "checking if Linux 2.4 kernel header files are installed""... $ac_c" 1>&6
-echo "configure:6942: checking if Linux 2.4 kernel header files are installed" >&5
+echo "configure:7010: checking if Linux 2.4 kernel header files are installed" >&5
# hold on to your hats...
if test "$ac_cv_header_linux_netfilter_ipv4_h" = "yes"; then
LINUX_NETFILTER="yes"
esac
fi
echo $ac_n "checking if GNUregex needs to be compiled""... $ac_c" 1>&6
-echo "configure:6976: checking if GNUregex needs to be compiled" >&5
+echo "configure:7044: checking if GNUregex needs to be compiled" >&5
if test -z "$USE_GNUREGEX"; then
if test "$ac_cv_func_regcomp" = "no" || test "$USE_GNUREGEX" = "yes" ; then
USE_GNUREGEX="yes"
else
cat > conftest.$ac_ext <<EOF
-#line 6982 "configure"
+#line 7050 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <regex.h>
regex_t t; regcomp(&t,"",0);
; return 0; }
EOF
-if { (eval echo configure:6990: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:7058: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
USE_GNUREGEX="no"
else
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:7021: checking for $ac_func" >&5
+echo "configure:7089: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 7026 "configure"
+#line 7094 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
; return 0; }
EOF
-if { (eval echo configure:7049: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7117: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
echo $ac_n "checking Default FD_SETSIZE value""... $ac_c" 1>&6
-echo "configure:7077: checking Default FD_SETSIZE value" >&5
+echo "configure:7145: checking Default FD_SETSIZE value" >&5
if test "$cross_compiling" = yes; then
DEFAULT_FD_SETSIZE=256
else
cat > conftest.$ac_ext <<EOF
-#line 7082 "configure"
+#line 7150 "configure"
#include "confdefs.h"
#if HAVE_STDIO_H
}
EOF
-if { (eval echo configure:7107: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:7175: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
DEFAULT_FD_SETSIZE=`cat conftestval`
else
echo $ac_n "checking Maximum number of filedescriptors we can open""... $ac_c" 1>&6
-echo "configure:7126: checking Maximum number of filedescriptors we can open" >&5
+echo "configure:7194: checking Maximum number of filedescriptors we can open" >&5
TLDFLAGS="$LDFLAGS"
case $host in
i386-unknown-freebsd*)
SQUID_MAXFD=256
else
cat > conftest.$ac_ext <<EOF
-#line 7138 "configure"
+#line 7206 "configure"
#include "confdefs.h"
#include <stdio.h>
}
EOF
-if { (eval echo configure:7198: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:7266: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
SQUID_MAXFD=`cat conftestval`
else
LDFLAGS="$TLDFLAGS"
echo $ac_n "checking Default UDP send buffer size""... $ac_c" 1>&6
-echo "configure:7225: checking Default UDP send buffer size" >&5
+echo "configure:7293: checking Default UDP send buffer size" >&5
if test "$cross_compiling" = yes; then
SQUID_UDP_SO_SNDBUF=16384
else
cat > conftest.$ac_ext <<EOF
-#line 7230 "configure"
+#line 7298 "configure"
#include "confdefs.h"
#include <stdlib.h>
}
EOF
-if { (eval echo configure:7251: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:7319: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
SQUID_UDP_SO_SNDBUF=`cat conftestval`
else
echo $ac_n "checking Default UDP receive buffer size""... $ac_c" 1>&6
-echo "configure:7270: checking Default UDP receive buffer size" >&5
+echo "configure:7338: checking Default UDP receive buffer size" >&5
if test "$cross_compiling" = yes; then
SQUID_UDP_SO_RCVBUF=16384
else
cat > conftest.$ac_ext <<EOF
-#line 7275 "configure"
+#line 7343 "configure"
#include "confdefs.h"
#include <stdlib.h>
}
EOF
-if { (eval echo configure:7296: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:7364: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
SQUID_UDP_SO_RCVBUF=`cat conftestval`
else
echo $ac_n "checking Default TCP send buffer size""... $ac_c" 1>&6
-echo "configure:7315: checking Default TCP send buffer size" >&5
+echo "configure:7383: checking Default TCP send buffer size" >&5
if test "$cross_compiling" = yes; then
SQUID_TCP_SO_SNDBUF=16384
else
cat > conftest.$ac_ext <<EOF
-#line 7320 "configure"
+#line 7388 "configure"
#include "confdefs.h"
#include <stdlib.h>
}
EOF
-if { (eval echo configure:7341: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:7409: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
SQUID_TCP_SO_SNDBUF=`cat conftestval`
else
echo $ac_n "checking Default TCP receive buffer size""... $ac_c" 1>&6
-echo "configure:7360: checking Default TCP receive buffer size" >&5
+echo "configure:7428: checking Default TCP receive buffer size" >&5
if test "$cross_compiling" = yes; then
SQUID_TCP_SO_RCVBUF=16384
else
cat > conftest.$ac_ext <<EOF
-#line 7365 "configure"
+#line 7433 "configure"
#include "confdefs.h"
#include <stdlib.h>
}
EOF
-if { (eval echo configure:7386: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:7454: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
SQUID_TCP_SO_RCVBUF=`cat conftestval`
else
echo $ac_n "checking if sys_errlist is already defined""... $ac_c" 1>&6
-echo "configure:7405: checking if sys_errlist is already defined" >&5
+echo "configure:7473: checking if sys_errlist is already defined" >&5
if eval "test \"`echo '$''{'ac_cv_needs_sys_errlist'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 7410 "configure"
+#line 7478 "configure"
#include "confdefs.h"
#include <stdio.h>
int main() {
char *s = sys_errlist;
; return 0; }
EOF
-if { (eval echo configure:7417: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:7485: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_needs_sys_errlist="no"
else
fi
echo $ac_n "checking for libresolv _dns_ttl_ hack""... $ac_c" 1>&6
-echo "configure:7439: checking for libresolv _dns_ttl_ hack" >&5
+echo "configure:7507: checking for libresolv _dns_ttl_ hack" >&5
cat > conftest.$ac_ext <<EOF
-#line 7441 "configure"
+#line 7509 "configure"
#include "confdefs.h"
extern int _dns_ttl_;
int main() {
return _dns_ttl_;
; return 0; }
EOF
-if { (eval echo configure:7448: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
+if { (eval echo configure:7516: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
echo "$ac_t""yes" 1>&6
cat >> confdefs.h <<\EOF
rm -f conftest*
echo $ac_n "checking if inet_ntoa() actually works""... $ac_c" 1>&6
-echo "configure:7464: checking if inet_ntoa() actually works" >&5
+echo "configure:7532: checking if inet_ntoa() actually works" >&5
if test "$cross_compiling" = yes; then
INET_NTOA_RESULT="broken"
else
cat > conftest.$ac_ext <<EOF
-#line 7469 "configure"
+#line 7537 "configure"
#include "confdefs.h"
#include <stdlib.h>
}
EOF
-if { (eval echo configure:7488: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:7556: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
INET_NTOA_RESULT=`cat conftestval`
else
if test "$ac_cv_header_sys_statvfs_h" = "yes" ; then
echo $ac_n "checking for working statvfs() interface""... $ac_c" 1>&6
-echo "configure:7514: checking for working statvfs() interface" >&5
+echo "configure:7582: checking for working statvfs() interface" >&5
cat > conftest.$ac_ext <<EOF
-#line 7516 "configure"
+#line 7584 "configure"
#include "confdefs.h"
#include <stdlib.h>
; return 0; }
EOF
-if { (eval echo configure:7533: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:7601: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_func_statvfs=yes
else
fi
echo $ac_n "checking for _res.nsaddr_list""... $ac_c" 1>&6
-echo "configure:7553: checking for _res.nsaddr_list" >&5
+echo "configure:7621: checking for _res.nsaddr_list" >&5
if eval "test \"`echo '$''{'ac_cv_have_res_nsaddr_list'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 7558 "configure"
+#line 7626 "configure"
#include "confdefs.h"
#if HAVE_SYS_TYPES_H
_res.nsaddr_list[0];
; return 0; }
EOF
-if { (eval echo configure:7581: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:7649: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_have_res_nsaddr_list="yes"
else
if test $ac_cv_have_res_nsaddr_list = "no" ; then
echo $ac_n "checking for _res.ns_list""... $ac_c" 1>&6
-echo "configure:7603: checking for _res.ns_list" >&5
+echo "configure:7671: checking for _res.ns_list" >&5
if eval "test \"`echo '$''{'ac_cv_have_res_ns_list'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 7608 "configure"
+#line 7676 "configure"
#include "confdefs.h"
#if HAVE_SYS_TYPES_H
_res.ns_list[0].addr;
; return 0; }
EOF
-if { (eval echo configure:7631: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:7699: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_have_res_ns_list="yes"
else
--- /dev/null
+
+/*
+ * $Id: comm_poll.cc,v 1.1 2001/12/24 15:33:42 adrian Exp $
+ *
+ * DEBUG: section 5 Socket Functions
+ *
+ * SQUID Web Proxy Cache http://www.squid-cache.org/
+ * ----------------------------------------------------------
+ *
+ * Squid is the result of efforts by numerous individuals from
+ * the Internet community; see the CONTRIBUTORS file for full
+ * details. Many organizations have provided support for Squid's
+ * development; see the SPONSORS file for full details. Squid is
+ * Copyrighted (C) 2001 by the Regents of the University of
+ * California; see the COPYRIGHT file for full details. Squid
+ * incorporates software developed and/or copyrighted by other
+ * sources; see the CREDITS file for full details.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111, USA.
+ *
+ */
+
+#include "squid.h"
+
+#ifdef USE_POLL
+
+static int MAX_POLL_TIME = 1000; /* see also comm_quick_poll_required() */
+
+#ifndef howmany
+#define howmany(x, y) (((x)+((y)-1))/(y))
+#endif
+#ifndef NBBY
+#define NBBY 8
+#endif
+#define FD_MASK_BYTES sizeof(fd_mask)
+#define FD_MASK_BITS (FD_MASK_BYTES*NBBY)
+
+/* STATIC */
+static int fdIsHttp(int fd);
+static int fdIsIcp(int fd);
+static int fdIsDns(int fd);
+static OBJH commIncomingStats;
+static int comm_check_incoming_poll_handlers(int nfds, int *fds);
+static void comm_poll_dns_incoming(void);
+static void commUpdateReadBits(int fd, PF * handler);
+static void commUpdateWriteBits(int fd, PF * handler);
+
+static fd_set global_readfds;
+static fd_set global_writefds;
+static int nreadfds;
+static int nwritefds;
+
+/*
+ * Automatic tuning for incoming requests:
+ *
+ * INCOMING sockets are the ICP and HTTP ports. We need to check these
+ * fairly regularly, but how often? When the load increases, we
+ * want to check the incoming sockets more often. If we have a lot
+ * of incoming ICP, then we need to check these sockets more than
+ * if we just have HTTP.
+ *
+ * The variables 'incoming_icp_interval' and 'incoming_http_interval'
+ * determine how many normal I/O events to process before checking
+ * incoming sockets again. Note we store the incoming_interval
+ * multipled by a factor of (2^INCOMING_FACTOR) to have some
+ * pseudo-floating point precision.
+ *
+ * The variable 'icp_io_events' and 'http_io_events' counts how many normal
+ * I/O events have been processed since the last check on the incoming
+ * sockets. When io_events > incoming_interval, its time to check incoming
+ * sockets.
+ *
+ * Every time we check incoming sockets, we count how many new messages
+ * or connections were processed. This is used to adjust the
+ * incoming_interval for the next iteration. The new incoming_interval
+ * is calculated as the current incoming_interval plus what we would
+ * like to see as an average number of events minus the number of
+ * events just processed.
+ *
+ * incoming_interval = incoming_interval + target_average - number_of_events_processed
+ *
+ * There are separate incoming_interval counters for both HTTP and ICP events
+ *
+ * You can see the current values of the incoming_interval's, as well as
+ * a histogram of 'incoming_events' by asking the cache manager
+ * for 'comm_incoming', e.g.:
+ *
+ * % ./client mgr:comm_incoming
+ *
+ * Caveats:
+ *
+ * - We have MAX_INCOMING_INTEGER as a magic upper limit on
+ * incoming_interval for both types of sockets. At the
+ * largest value the cache will effectively be idling.
+ *
+ * - The higher the INCOMING_FACTOR, the slower the algorithm will
+ * respond to load spikes/increases/decreases in demand. A value
+ * between 3 and 8 is recommended.
+ */
+
+#define MAX_INCOMING_INTEGER 256
+#define INCOMING_FACTOR 5
+#define MAX_INCOMING_INTERVAL (MAX_INCOMING_INTEGER << INCOMING_FACTOR)
+static int icp_io_events = 0;
+static int dns_io_events = 0;
+static int http_io_events = 0;
+static int incoming_icp_interval = 16 << INCOMING_FACTOR;
+static int incoming_dns_interval = 16 << INCOMING_FACTOR;
+static int incoming_http_interval = 16 << INCOMING_FACTOR;
+#define commCheckICPIncoming (++icp_io_events > (incoming_icp_interval>> INCOMING_FACTOR))
+#define commCheckDNSIncoming (++dns_io_events > (incoming_dns_interval>> INCOMING_FACTOR))
+#define commCheckHTTPIncoming (++http_io_events > (incoming_http_interval>> INCOMING_FACTOR))
+
+
+void
+commSetSelect(int fd, unsigned int type, PF * handler, void *client_data,
+ time_t timeout)
+{
+ fde *F = &fd_table[fd];
+ assert(fd >= 0);
+ assert(F->flags.open);
+ debug(5, 5) ("commSetSelect: FD %d type %d\n", fd, type);
+ if (type & COMM_SELECT_READ) {
+ F->read_handler = handler;
+ F->read_data = client_data;
+ commUpdateReadBits(fd, handler);
+ }
+ if (type & COMM_SELECT_WRITE) {
+ F->write_handler = handler;
+ F->write_data = client_data;
+ commUpdateWriteBits(fd, handler);
+ }
+ if (timeout)
+ F->timeout = squid_curtime + timeout;
+}
+
+static int
+fdIsIcp(int fd)
+{
+ if (fd == theInIcpConnection)
+ return 1;
+ if (fd == theOutIcpConnection)
+ return 1;
+ return 0;
+}
+
+static int
+fdIsDns(int fd)
+{
+ if (fd == DnsSocket)
+ return 1;
+ return 0;
+}
+
+static int
+fdIsHttp(int fd)
+{
+ int j;
+ for (j = 0; j < NHttpSockets; j++) {
+ if (fd == HttpSockets[j])
+ return 1;
+ }
+ return 0;
+}
+
+#if DELAY_POOLS
+static int slowfdcnt = 0;
+static int slowfdarr[SQUID_MAXFD];
+
+static void
+commAddSlowFd(int fd)
+{
+ assert(slowfdcnt < SQUID_MAXFD);
+ slowfdarr[slowfdcnt++] = fd;
+}
+
+static int
+commGetSlowFd(void)
+{
+ int whichfd, retfd;
+
+ if (!slowfdcnt)
+ return -1;
+ whichfd = squid_random() % slowfdcnt;
+ retfd = slowfdarr[whichfd];
+ slowfdarr[whichfd] = slowfdarr[--slowfdcnt];
+ return retfd;
+}
+#endif
+
+static int
+comm_check_incoming_poll_handlers(int nfds, int *fds)
+{
+ int i;
+ int fd;
+ PF *hdl = NULL;
+ int npfds;
+ struct pollfd pfds[3 + MAXHTTPPORTS];
+ incoming_sockets_accepted = 0;
+ for (i = npfds = 0; i < nfds; i++) {
+ int events;
+ fd = fds[i];
+ events = 0;
+ if (fd_table[fd].read_handler)
+ events |= POLLRDNORM;
+ if (fd_table[fd].write_handler)
+ events |= POLLWRNORM;
+ if (events) {
+ pfds[npfds].fd = fd;
+ pfds[npfds].events = events;
+ pfds[npfds].revents = 0;
+ npfds++;
+ }
+ }
+ if (!nfds)
+ return -1;
+#if !ALARM_UPDATES_TIME
+ getCurrentTime();
+#endif
+ statCounter.syscalls.polls++;
+ if (poll(pfds, npfds, 0) < 1)
+ return incoming_sockets_accepted;
+ for (i = 0; i < npfds; i++) {
+ int revents;
+ if (((revents = pfds[i].revents) == 0) || ((fd = pfds[i].fd) == -1))
+ continue;
+ if (revents & (POLLRDNORM | POLLIN | POLLHUP | POLLERR)) {
+ if ((hdl = fd_table[fd].read_handler)) {
+ fd_table[fd].read_handler = NULL;
+ hdl(fd, fd_table[fd].read_data);
+ } else if (pfds[i].events & POLLRDNORM)
+ debug(5, 1) ("comm_poll_incoming: FD %d NULL read handler\n",
+ fd);
+ }
+ if (revents & (POLLWRNORM | POLLOUT | POLLHUP | POLLERR)) {
+ if ((hdl = fd_table[fd].write_handler)) {
+ fd_table[fd].write_handler = NULL;
+ hdl(fd, fd_table[fd].write_data);
+ } else if (pfds[i].events & POLLWRNORM)
+ debug(5, 1) ("comm_poll_incoming: FD %d NULL write_handler\n",
+ fd);
+ }
+ }
+ return incoming_sockets_accepted;
+}
+
+static void
+comm_poll_icp_incoming(void)
+{
+ int nfds = 0;
+ int fds[2];
+ int nevents;
+ icp_io_events = 0;
+ if (theInIcpConnection >= 0)
+ fds[nfds++] = theInIcpConnection;
+ if (theInIcpConnection != theOutIcpConnection)
+ if (theOutIcpConnection >= 0)
+ fds[nfds++] = theOutIcpConnection;
+ if (nfds == 0)
+ return;
+ nevents = comm_check_incoming_poll_handlers(nfds, fds);
+ incoming_icp_interval += Config.comm_incoming.icp_average - nevents;
+ if (incoming_icp_interval < Config.comm_incoming.icp_min_poll)
+ incoming_icp_interval = Config.comm_incoming.icp_min_poll;
+ if (incoming_icp_interval > MAX_INCOMING_INTERVAL)
+ incoming_icp_interval = MAX_INCOMING_INTERVAL;
+ if (nevents > INCOMING_ICP_MAX)
+ nevents = INCOMING_ICP_MAX;
+ statHistCount(&statCounter.comm_icp_incoming, nevents);
+}
+
+static void
+comm_poll_http_incoming(void)
+{
+ int nfds = 0;
+ int fds[MAXHTTPPORTS];
+ int j;
+ int nevents;
+ http_io_events = 0;
+ for (j = 0; j < NHttpSockets; j++) {
+ if (HttpSockets[j] < 0)
+ continue;
+ if (commDeferRead(HttpSockets[j]))
+ continue;
+ fds[nfds++] = HttpSockets[j];
+ }
+ nevents = comm_check_incoming_poll_handlers(nfds, fds);
+ incoming_http_interval = incoming_http_interval
+ + Config.comm_incoming.http_average - nevents;
+ if (incoming_http_interval < Config.comm_incoming.http_min_poll)
+ incoming_http_interval = Config.comm_incoming.http_min_poll;
+ if (incoming_http_interval > MAX_INCOMING_INTERVAL)
+ incoming_http_interval = MAX_INCOMING_INTERVAL;
+ if (nevents > INCOMING_HTTP_MAX)
+ nevents = INCOMING_HTTP_MAX;
+ statHistCount(&statCounter.comm_http_incoming, nevents);
+}
+
+/* poll all sockets; call handlers for those that are ready. */
+int
+comm_select(int msec)
+{
+ struct pollfd pfds[SQUID_MAXFD];
+#if DELAY_POOLS
+ fd_set slowfds;
+#endif
+ PF *hdl = NULL;
+ int fd;
+ int i;
+ int maxfd;
+ unsigned long nfds;
+ unsigned long npending;
+ int num;
+ int callicp = 0, callhttp = 0;
+ int calldns = 0;
+ static time_t last_timeout = 0;
+ double timeout = current_dtime + (msec / 1000.0);
+ do {
+#if !ALARM_UPDATES_TIME
+ double start;
+ getCurrentTime();
+ start = current_dtime;
+#endif
+ /* Handle any fs callbacks that need doing */
+ storeDirCallback();
+#if DELAY_POOLS
+ FD_ZERO(&slowfds);
+#endif
+ if (commCheckICPIncoming)
+ comm_poll_icp_incoming();
+ if (commCheckDNSIncoming)
+ comm_poll_dns_incoming();
+ if (commCheckHTTPIncoming)
+ comm_poll_http_incoming();
+ callicp = calldns = callhttp = 0;
+ nfds = 0;
+ npending = 0;
+ maxfd = Biggest_FD + 1;
+ for (i = 0; i < maxfd; i++) {
+ int events;
+ events = 0;
+ /* Check each open socket for a handler. */
+ if (fd_table[i].read_handler) {
+ switch (commDeferRead(i)) {
+ case 0:
+ events |= POLLRDNORM;
+ break;
+ case 1:
+ break;
+#if DELAY_POOLS
+ case -1:
+ events |= POLLRDNORM;
+ FD_SET(i, &slowfds);
+ break;
+#endif
+ default:
+ fatalf("bad return value from commDeferRead(FD %d)\n", i);
+ }
+ }
+ if (fd_table[i].write_handler)
+ events |= POLLWRNORM;
+ if (events) {
+ pfds[nfds].fd = i;
+ pfds[nfds].events = events;
+ pfds[nfds].revents = 0;
+ nfds++;
+ if ((events & POLLRDNORM) && fd_table[i].flags.read_pending)
+ npending++;
+ }
+ }
+ if (nfds == 0) {
+ assert(shutting_down);
+ return COMM_SHUTDOWN;
+ }
+ if (npending)
+ msec = 0;
+ if (msec > MAX_POLL_TIME)
+ msec = MAX_POLL_TIME;
+ for (;;) {
+ statCounter.syscalls.polls++;
+ num = poll(pfds, nfds, msec);
+ statCounter.select_loops++;
+ if (num >= 0 || npending >= 0)
+ break;
+ if (ignoreErrno(errno))
+ continue;
+ debug(5, 0) ("comm_poll: poll failure: %s\n", xstrerror());
+ assert(errno != EINVAL);
+ return COMM_ERROR;
+ /* NOTREACHED */
+ }
+ debug(5, num ? 5 : 8) ("comm_poll: %d+%ld FDs ready\n", num, npending);
+ statHistCount(&statCounter.select_fds_hist, num);
+ /* Check timeout handlers ONCE each second. */
+ if (squid_curtime > last_timeout) {
+ last_timeout = squid_curtime;
+ checkTimeouts();
+ }
+ if (num == 0 && npending == 0)
+ continue;
+ /* scan each socket but the accept socket. Poll this
+ * more frequently to minimize losses due to the 5 connect
+ * limit in SunOS */
+ for (i = 0; i < nfds; i++) {
+ fde *F;
+ int revents = pfds[i].revents;
+ fd = pfds[i].fd;
+ if (fd == -1)
+ continue;
+ if (fd_table[fd].flags.read_pending)
+ revents |= POLLIN;
+ if (revents == 0)
+ continue;
+ if (fdIsIcp(fd)) {
+ callicp = 1;
+ continue;
+ }
+ if (fdIsDns(fd)) {
+ calldns = 1;
+ continue;
+ }
+ if (fdIsHttp(fd)) {
+ callhttp = 1;
+ continue;
+ }
+ F = &fd_table[fd];
+ if (revents & (POLLRDNORM | POLLIN | POLLHUP | POLLERR)) {
+ debug(5, 6) ("comm_poll: FD %d ready for reading\n", fd);
+ if (NULL == (hdl = F->read_handler))
+ (void) 0;
+#if DELAY_POOLS
+ else if (FD_ISSET(fd, &slowfds))
+ commAddSlowFd(fd);
+#endif
+ else {
+ F->read_handler = NULL;
+ hdl(fd, F->read_data);
+ statCounter.select_fds++;
+ if (commCheckICPIncoming)
+ comm_poll_icp_incoming();
+ if (commCheckDNSIncoming)
+ comm_poll_dns_incoming();
+ if (commCheckHTTPIncoming)
+ comm_poll_http_incoming();
+ }
+ }
+ if (revents & (POLLWRNORM | POLLOUT | POLLHUP | POLLERR)) {
+ debug(5, 5) ("comm_poll: FD %d ready for writing\n", fd);
+ if ((hdl = F->write_handler)) {
+ F->write_handler = NULL;
+ hdl(fd, F->write_data);
+ statCounter.select_fds++;
+ if (commCheckICPIncoming)
+ comm_poll_icp_incoming();
+ if (commCheckDNSIncoming)
+ comm_poll_dns_incoming();
+ if (commCheckHTTPIncoming)
+ comm_poll_http_incoming();
+ }
+ }
+ if (revents & POLLNVAL) {
+ close_handler *ch;
+ debug(5, 0) ("WARNING: FD %d has handlers, but it's invalid.\n", fd);
+ debug(5, 0) ("FD %d is a %s\n", fd, fdTypeStr[F->type]);
+ debug(5, 0) ("--> %s\n", F->desc);
+ debug(5, 0) ("tmout:%p read:%p write:%p\n",
+ F->timeout_handler,
+ F->read_handler,
+ F->write_handler);
+ for (ch = F->close_handler; ch; ch = ch->next)
+ debug(5, 0) (" close handler: %p\n", ch->handler);
+ if (F->close_handler) {
+ commCallCloseHandlers(fd);
+ } else if (F->timeout_handler) {
+ debug(5, 0) ("comm_poll: Calling Timeout Handler\n");
+ F->timeout_handler(fd, F->timeout_data);
+ }
+ F->close_handler = NULL;
+ F->timeout_handler = NULL;
+ F->read_handler = NULL;
+ F->write_handler = NULL;
+ if (F->flags.open)
+ fd_close(fd);
+ }
+ }
+ if (callicp)
+ comm_poll_icp_incoming();
+ if (calldns)
+ comm_poll_dns_incoming();
+ if (callhttp)
+ comm_poll_http_incoming();
+#if DELAY_POOLS
+ while ((fd = commGetSlowFd()) != -1) {
+ fde *F = &fd_table[fd];
+ debug(5, 6) ("comm_select: slow FD %d selected for reading\n", fd);
+ if ((hdl = F->read_handler)) {
+ F->read_handler = NULL;
+ hdl(fd, F->read_data);
+ statCounter.select_fds++;
+ if (commCheckICPIncoming)
+ comm_poll_icp_incoming();
+ if (commCheckDNSIncoming)
+ comm_poll_dns_incoming();
+ if (commCheckHTTPIncoming)
+ comm_poll_http_incoming();
+ }
+ }
+#endif
+#if !ALARM_UPDATES_TIME
+ getCurrentTime();
+ statCounter.select_time += (current_dtime - start);
+#endif
+ return COMM_OK;
+ }
+ while (timeout > current_dtime);
+ debug(5, 8) ("comm_poll: time out: %ld.\n", (long int) squid_curtime);
+ return COMM_TIMEOUT;
+}
+
+
+static void
+comm_poll_dns_incoming(void)
+{
+ int nfds = 0;
+ int fds[2];
+ int nevents;
+ dns_io_events = 0;
+ if (DnsSocket < 0)
+ return;
+ fds[nfds++] = DnsSocket;
+ nevents = comm_check_incoming_poll_handlers(nfds, fds);
+ if (nevents < 0)
+ return;
+ incoming_dns_interval += Config.comm_incoming.dns_average - nevents;
+ if (incoming_dns_interval < Config.comm_incoming.dns_min_poll)
+ incoming_dns_interval = Config.comm_incoming.dns_min_poll;
+ if (incoming_dns_interval > MAX_INCOMING_INTERVAL)
+ incoming_dns_interval = MAX_INCOMING_INTERVAL;
+ if (nevents > INCOMING_DNS_MAX)
+ nevents = INCOMING_DNS_MAX;
+ statHistCount(&statCounter.comm_dns_incoming, nevents);
+}
+
+void
+comm_select_init(void)
+{
+ cachemgrRegister("comm_incoming",
+ "comm_incoming() stats",
+ commIncomingStats, 0, 1);
+ FD_ZERO(&global_readfds);
+ FD_ZERO(&global_writefds);
+ nreadfds = nwritefds = 0;
+}
+
+
+static void
+commIncomingStats(StoreEntry * sentry)
+{
+ StatCounters *f = &statCounter;
+ storeAppendPrintf(sentry, "Current incoming_icp_interval: %d\n",
+ incoming_icp_interval >> INCOMING_FACTOR);
+ storeAppendPrintf(sentry, "Current incoming_dns_interval: %d\n",
+ incoming_dns_interval >> INCOMING_FACTOR);
+ storeAppendPrintf(sentry, "Current incoming_http_interval: %d\n",
+ incoming_http_interval >> INCOMING_FACTOR);
+ storeAppendPrintf(sentry, "\n");
+ storeAppendPrintf(sentry, "Histogram of events per incoming socket type\n");
+ storeAppendPrintf(sentry, "ICP Messages handled per comm_poll_icp_incoming() call:\n");
+ statHistDump(&f->comm_icp_incoming, sentry, statHistIntDumper);
+ storeAppendPrintf(sentry, "DNS Messages handled per comm_poll_dns_incoming() call:\n");
+ statHistDump(&f->comm_dns_incoming, sentry, statHistIntDumper);
+ storeAppendPrintf(sentry, "HTTP Messages handled per comm_poll_http_incoming() call:\n");
+ statHistDump(&f->comm_http_incoming, sentry, statHistIntDumper);
+}
+
+void
+commUpdateReadBits(int fd, PF * handler)
+{
+ if (handler && !FD_ISSET(fd, &global_readfds)) {
+ FD_SET(fd, &global_readfds);
+ nreadfds++;
+ } else if (!handler && FD_ISSET(fd, &global_readfds)) {
+ FD_CLR(fd, &global_readfds);
+ nreadfds--;
+ }
+}
+
+void
+commUpdateWriteBits(int fd, PF * handler)
+{
+ if (handler && !FD_ISSET(fd, &global_writefds)) {
+ FD_SET(fd, &global_writefds);
+ nwritefds++;
+ } else if (!handler && FD_ISSET(fd, &global_writefds)) {
+ FD_CLR(fd, &global_writefds);
+ nwritefds--;
+ }
+}
+
+/* Called by async-io or diskd to speed up the polling */
+void
+comm_quick_poll_required(void)
+{
+ MAX_POLL_TIME = 10;
+}
+
+#endif /* USE_POLL */
/*
- * $Id: comm_select.cc,v 1.53 2001/10/24 06:55:44 hno Exp $
+ * $Id: comm_select.cc,v 1.54 2001/12/24 15:33:42 adrian Exp $
*
* DEBUG: section 5 Socket Functions
*
#include "squid.h"
+#ifdef USE_SELECT
+
static int MAX_POLL_TIME = 1000; /* see also comm_quick_poll_required() */
#ifndef howmany
#define FD_MASK_BITS (FD_MASK_BYTES*NBBY)
/* STATIC */
-#if !HAVE_POLL
static int examine_select(fd_set *, fd_set *);
-#endif
static int fdIsHttp(int fd);
static int fdIsIcp(int fd);
static int fdIsDns(int fd);
-static int commDeferRead(int fd);
-static void checkTimeouts(void);
static OBJH commIncomingStats;
-#if HAVE_POLL
-static int comm_check_incoming_poll_handlers(int nfds, int *fds);
-static void comm_poll_dns_incoming(void);
-#else
static int comm_check_incoming_select_handlers(int nfds, int *fds);
static void comm_select_dns_incoming(void);
-#endif
+static void commUpdateReadBits(int fd, PF * handler);
+static void commUpdateWriteBits(int fd, PF * handler);
+
-#if !HAVE_POLL
static struct timeval zero_tv;
-#endif
static fd_set global_readfds;
static fd_set global_writefds;
static int nreadfds;
#define commCheckDNSIncoming (++dns_io_events > (incoming_dns_interval>> INCOMING_FACTOR))
#define commCheckHTTPIncoming (++http_io_events > (incoming_http_interval>> INCOMING_FACTOR))
-static int
-commDeferRead(int fd)
+void
+commSetSelect(int fd, unsigned int type, PF * handler, void *client_data,
+ time_t timeout)
{
fde *F = &fd_table[fd];
- if (F->defer_check == NULL)
- return 0;
- return F->defer_check(fd, F->defer_data);
+ assert(fd >= 0);
+ assert(F->flags.open);
+ debug(5, 5) ("commSetSelect: FD %d type %d\n", fd, type);
+ if (type & COMM_SELECT_READ) {
+ F->read_handler = handler;
+ F->read_data = client_data;
+ commUpdateReadBits(fd, handler);
+ }
+ if (type & COMM_SELECT_WRITE) {
+ F->write_handler = handler;
+ F->write_data = client_data;
+ commUpdateWriteBits(fd, handler);
+ }
+ if (timeout)
+ F->timeout = squid_curtime + timeout;
}
+
static int
fdIsIcp(int fd)
{
}
#endif
-#if HAVE_POLL
-static int
-comm_check_incoming_poll_handlers(int nfds, int *fds)
-{
- int i;
- int fd;
- PF *hdl = NULL;
- int npfds;
- struct pollfd pfds[3 + MAXHTTPPORTS];
- incoming_sockets_accepted = 0;
- for (i = npfds = 0; i < nfds; i++) {
- int events;
- fd = fds[i];
- events = 0;
- if (fd_table[fd].read_handler)
- events |= POLLRDNORM;
- if (fd_table[fd].write_handler)
- events |= POLLWRNORM;
- if (events) {
- pfds[npfds].fd = fd;
- pfds[npfds].events = events;
- pfds[npfds].revents = 0;
- npfds++;
- }
- }
- if (!nfds)
- return -1;
-#if !ALARM_UPDATES_TIME
- getCurrentTime();
-#endif
- statCounter.syscalls.polls++;
- if (poll(pfds, npfds, 0) < 1)
- return incoming_sockets_accepted;
- for (i = 0; i < npfds; i++) {
- int revents;
- if (((revents = pfds[i].revents) == 0) || ((fd = pfds[i].fd) == -1))
- continue;
- if (revents & (POLLRDNORM | POLLIN | POLLHUP | POLLERR)) {
- if ((hdl = fd_table[fd].read_handler)) {
- fd_table[fd].read_handler = NULL;
- hdl(fd, fd_table[fd].read_data);
- } else if (pfds[i].events & POLLRDNORM)
- debug(5, 1) ("comm_poll_incoming: FD %d NULL read handler\n",
- fd);
- }
- if (revents & (POLLWRNORM | POLLOUT | POLLHUP | POLLERR)) {
- if ((hdl = fd_table[fd].write_handler)) {
- fd_table[fd].write_handler = NULL;
- hdl(fd, fd_table[fd].write_data);
- } else if (pfds[i].events & POLLWRNORM)
- debug(5, 1) ("comm_poll_incoming: FD %d NULL write_handler\n",
- fd);
- }
- }
- return incoming_sockets_accepted;
-}
-
-static void
-comm_poll_icp_incoming(void)
-{
- int nfds = 0;
- int fds[2];
- int nevents;
- icp_io_events = 0;
- if (theInIcpConnection >= 0)
- fds[nfds++] = theInIcpConnection;
- if (theInIcpConnection != theOutIcpConnection)
- if (theOutIcpConnection >= 0)
- fds[nfds++] = theOutIcpConnection;
- if (nfds == 0)
- return;
- nevents = comm_check_incoming_poll_handlers(nfds, fds);
- incoming_icp_interval += Config.comm_incoming.icp_average - nevents;
- if (incoming_icp_interval < Config.comm_incoming.icp_min_poll)
- incoming_icp_interval = Config.comm_incoming.icp_min_poll;
- if (incoming_icp_interval > MAX_INCOMING_INTERVAL)
- incoming_icp_interval = MAX_INCOMING_INTERVAL;
- if (nevents > INCOMING_ICP_MAX)
- nevents = INCOMING_ICP_MAX;
- statHistCount(&statCounter.comm_icp_incoming, nevents);
-}
-
-static void
-comm_poll_http_incoming(void)
-{
- int nfds = 0;
- int fds[MAXHTTPPORTS];
- int j;
- int nevents;
- http_io_events = 0;
- for (j = 0; j < NHttpSockets; j++) {
- if (HttpSockets[j] < 0)
- continue;
- if (commDeferRead(HttpSockets[j]))
- continue;
- fds[nfds++] = HttpSockets[j];
- }
- nevents = comm_check_incoming_poll_handlers(nfds, fds);
- incoming_http_interval = incoming_http_interval
- + Config.comm_incoming.http_average - nevents;
- if (incoming_http_interval < Config.comm_incoming.http_min_poll)
- incoming_http_interval = Config.comm_incoming.http_min_poll;
- if (incoming_http_interval > MAX_INCOMING_INTERVAL)
- incoming_http_interval = MAX_INCOMING_INTERVAL;
- if (nevents > INCOMING_HTTP_MAX)
- nevents = INCOMING_HTTP_MAX;
- statHistCount(&statCounter.comm_http_incoming, nevents);
-}
-
-/* poll all sockets; call handlers for those that are ready. */
-int
-comm_poll(int msec)
-{
- struct pollfd pfds[SQUID_MAXFD];
-#if DELAY_POOLS
- fd_set slowfds;
-#endif
- PF *hdl = NULL;
- int fd;
- int i;
- int maxfd;
- unsigned long nfds;
- unsigned long npending;
- int num;
- int callicp = 0, callhttp = 0;
- int calldns = 0;
- static time_t last_timeout = 0;
- double timeout = current_dtime + (msec / 1000.0);
- do {
-#if !ALARM_UPDATES_TIME
- double start;
- getCurrentTime();
- start = current_dtime;
-#endif
- /* Handle any fs callbacks that need doing */
- storeDirCallback();
-#if DELAY_POOLS
- FD_ZERO(&slowfds);
-#endif
- if (commCheckICPIncoming)
- comm_poll_icp_incoming();
- if (commCheckDNSIncoming)
- comm_poll_dns_incoming();
- if (commCheckHTTPIncoming)
- comm_poll_http_incoming();
- callicp = calldns = callhttp = 0;
- nfds = 0;
- npending = 0;
- maxfd = Biggest_FD + 1;
- for (i = 0; i < maxfd; i++) {
- int events;
- events = 0;
- /* Check each open socket for a handler. */
- if (fd_table[i].read_handler) {
- switch (commDeferRead(i)) {
- case 0:
- events |= POLLRDNORM;
- break;
- case 1:
- break;
-#if DELAY_POOLS
- case -1:
- events |= POLLRDNORM;
- FD_SET(i, &slowfds);
- break;
-#endif
- default:
- fatalf("bad return value from commDeferRead(FD %d)\n", i);
- }
- }
- if (fd_table[i].write_handler)
- events |= POLLWRNORM;
- if (events) {
- pfds[nfds].fd = i;
- pfds[nfds].events = events;
- pfds[nfds].revents = 0;
- nfds++;
- if ((events & POLLRDNORM) && fd_table[i].flags.read_pending)
- npending++;
- }
- }
- if (nfds == 0) {
- assert(shutting_down);
- return COMM_SHUTDOWN;
- }
- if (npending)
- msec = 0;
- if (msec > MAX_POLL_TIME)
- msec = MAX_POLL_TIME;
- for (;;) {
- statCounter.syscalls.polls++;
- num = poll(pfds, nfds, msec);
- statCounter.select_loops++;
- if (num >= 0 || npending >= 0)
- break;
- if (ignoreErrno(errno))
- continue;
- debug(5, 0) ("comm_poll: poll failure: %s\n", xstrerror());
- assert(errno != EINVAL);
- return COMM_ERROR;
- /* NOTREACHED */
- }
- debug(5, num ? 5 : 8) ("comm_poll: %d+%ld FDs ready\n", num, npending);
- statHistCount(&statCounter.select_fds_hist, num);
- /* Check timeout handlers ONCE each second. */
- if (squid_curtime > last_timeout) {
- last_timeout = squid_curtime;
- checkTimeouts();
- }
- if (num == 0 && npending == 0)
- continue;
- /* scan each socket but the accept socket. Poll this
- * more frequently to minimize losses due to the 5 connect
- * limit in SunOS */
- for (i = 0; i < nfds; i++) {
- fde *F;
- int revents = pfds[i].revents;
- fd = pfds[i].fd;
- if (fd == -1)
- continue;
- if (fd_table[fd].flags.read_pending)
- revents |= POLLIN;
- if (revents == 0)
- continue;
- if (fdIsIcp(fd)) {
- callicp = 1;
- continue;
- }
- if (fdIsDns(fd)) {
- calldns = 1;
- continue;
- }
- if (fdIsHttp(fd)) {
- callhttp = 1;
- continue;
- }
- F = &fd_table[fd];
- if (revents & (POLLRDNORM | POLLIN | POLLHUP | POLLERR)) {
- debug(5, 6) ("comm_poll: FD %d ready for reading\n", fd);
- if (NULL == (hdl = F->read_handler))
- (void) 0;
-#if DELAY_POOLS
- else if (FD_ISSET(fd, &slowfds))
- commAddSlowFd(fd);
-#endif
- else {
- F->read_handler = NULL;
- hdl(fd, F->read_data);
- statCounter.select_fds++;
- if (commCheckICPIncoming)
- comm_poll_icp_incoming();
- if (commCheckDNSIncoming)
- comm_poll_dns_incoming();
- if (commCheckHTTPIncoming)
- comm_poll_http_incoming();
- }
- }
- if (revents & (POLLWRNORM | POLLOUT | POLLHUP | POLLERR)) {
- debug(5, 5) ("comm_poll: FD %d ready for writing\n", fd);
- if ((hdl = F->write_handler)) {
- F->write_handler = NULL;
- hdl(fd, F->write_data);
- statCounter.select_fds++;
- if (commCheckICPIncoming)
- comm_poll_icp_incoming();
- if (commCheckDNSIncoming)
- comm_poll_dns_incoming();
- if (commCheckHTTPIncoming)
- comm_poll_http_incoming();
- }
- }
- if (revents & POLLNVAL) {
- close_handler *ch;
- debug(5, 0) ("WARNING: FD %d has handlers, but it's invalid.\n", fd);
- debug(5, 0) ("FD %d is a %s\n", fd, fdTypeStr[F->type]);
- debug(5, 0) ("--> %s\n", F->desc);
- debug(5, 0) ("tmout:%p read:%p write:%p\n",
- F->timeout_handler,
- F->read_handler,
- F->write_handler);
- for (ch = F->close_handler; ch; ch = ch->next)
- debug(5, 0) (" close handler: %p\n", ch->handler);
- if (F->close_handler) {
- commCallCloseHandlers(fd);
- } else if (F->timeout_handler) {
- debug(5, 0) ("comm_poll: Calling Timeout Handler\n");
- F->timeout_handler(fd, F->timeout_data);
- }
- F->close_handler = NULL;
- F->timeout_handler = NULL;
- F->read_handler = NULL;
- F->write_handler = NULL;
- if (F->flags.open)
- fd_close(fd);
- }
- }
- if (callicp)
- comm_poll_icp_incoming();
- if (calldns)
- comm_poll_dns_incoming();
- if (callhttp)
- comm_poll_http_incoming();
-#if DELAY_POOLS
- while ((fd = commGetSlowFd()) != -1) {
- fde *F = &fd_table[fd];
- debug(5, 6) ("comm_select: slow FD %d selected for reading\n", fd);
- if ((hdl = F->read_handler)) {
- F->read_handler = NULL;
- hdl(fd, F->read_data);
- statCounter.select_fds++;
- if (commCheckICPIncoming)
- comm_poll_icp_incoming();
- if (commCheckDNSIncoming)
- comm_poll_dns_incoming();
- if (commCheckHTTPIncoming)
- comm_poll_http_incoming();
- }
- }
-#endif
-#if !ALARM_UPDATES_TIME
- getCurrentTime();
- statCounter.select_time += (current_dtime - start);
-#endif
- return COMM_OK;
- }
- while (timeout > current_dtime);
- debug(5, 8) ("comm_poll: time out: %ld.\n", (long int) squid_curtime);
- return COMM_TIMEOUT;
-}
-
-#else
static int
comm_check_incoming_select_handlers(int nfds, int *fds)
debug(5, 8) ("comm_select: time out: %d\n", (int) squid_curtime);
return COMM_TIMEOUT;
}
-#endif
static void
-#if HAVE_POLL
-comm_poll_dns_incoming(void)
-#else
comm_select_dns_incoming(void)
-#endif
{
int nfds = 0;
int fds[2];
if (DnsSocket < 0)
return;
fds[nfds++] = DnsSocket;
-#if HAVE_POLL
- nevents = comm_check_incoming_poll_handlers(nfds, fds);
-#else
nevents = comm_check_incoming_select_handlers(nfds, fds);
-#endif
if (nevents < 0)
return;
incoming_dns_interval += Config.comm_incoming.dns_average - nevents;
void
comm_select_init(void)
{
-#if !HAVE_POLL
zero_tv.tv_sec = 0;
zero_tv.tv_usec = 0;
-#endif
cachemgrRegister("comm_incoming",
"comm_incoming() stats",
commIncomingStats, 0, 1);
nreadfds = nwritefds = 0;
}
-#if !HAVE_POLL
/*
* examine_select - debug routine.
*
}
return 0;
}
-#endif
-static void
-checkTimeouts(void)
-{
- int fd;
- fde *F = NULL;
- PF *callback;
- for (fd = 0; fd <= Biggest_FD; fd++) {
- F = &fd_table[fd];
- if (!F->flags.open)
- continue;
- if (F->timeout == 0)
- continue;
- if (F->timeout > squid_curtime)
- continue;
- debug(5, 5) ("checkTimeouts: FD %d Expired\n", fd);
- if (F->timeout_handler) {
- debug(5, 5) ("checkTimeouts: FD %d: Call timeout handler\n", fd);
- callback = F->timeout_handler;
- F->timeout_handler = NULL;
- callback(fd, F->timeout_data);
- } else {
- debug(5, 5) ("checkTimeouts: FD %d: Forcing comm_close()\n", fd);
- comm_close(fd);
- }
- }
-}
static void
commIncomingStats(StoreEntry * sentry)
incoming_http_interval >> INCOMING_FACTOR);
storeAppendPrintf(sentry, "\n");
storeAppendPrintf(sentry, "Histogram of events per incoming socket type\n");
-#ifdef HAVE_POLL
- storeAppendPrintf(sentry, "ICP Messages handled per comm_poll_icp_incoming() call:\n");
-#else
storeAppendPrintf(sentry, "ICP Messages handled per comm_select_icp_incoming() call:\n");
-#endif
statHistDump(&f->comm_icp_incoming, sentry, statHistIntDumper);
-#ifdef HAVE_POLL
- storeAppendPrintf(sentry, "DNS Messages handled per comm_poll_dns_incoming() call:\n");
-#else
storeAppendPrintf(sentry, "DNS Messages handled per comm_select_dns_incoming() call:\n");
-#endif
statHistDump(&f->comm_dns_incoming, sentry, statHistIntDumper);
-#ifdef HAVE_POLL
- storeAppendPrintf(sentry, "HTTP Messages handled per comm_poll_http_incoming() call:\n");
-#else
storeAppendPrintf(sentry, "HTTP Messages handled per comm_select_http_incoming() call:\n");
-#endif
statHistDump(&f->comm_http_incoming, sentry, statHistIntDumper);
}
{
MAX_POLL_TIME = 10;
}
+
+#endif /* USE_SELECT */